1 2009-07-15 Pavel Roskin <proski@gnu.org>
3 * boot/i386/pc/boot.S (kernel_segment): Remove.
4 (copy_buffer): Use GRUB_BOOT_MACHINE_KERNEL_ADDR in segment 0
7 * boot/i386/pc/boot.S (boot_version): Remove.
8 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_VER_MAJ):
11 * include/grub/i386/pc/boot.h: Sort all offsets.
12 (GRUB_BOOT_MACHINE_KERNEL_ADDRESS): Remove, it's unused.
13 (GRUB_BOOT_MACHINE_KERNEL_SEGMENT): Likewise.
14 * boot/i386/pc/boot.S: Assert location of every offset listed in
15 include/grub/i386/pc/boot.h.
17 2009-07-13 Pavel Roskin <proski@gnu.org>
19 * include/grub/i386/coreboot/machine.h: Rename
20 GRUB_MACHINE_LINUXBIOS to GRUB_MACHINE_COREBOOT.
21 * loader/multiboot_loader.c (grub_cmd_multiboot_loader): Allow
22 multiboot 1 for GRUB_MACHINE_COREBOOT and GRUB_MACHINE_QEMU.
24 * kern/dl.c: Force native word size to suppress warnings when
27 * kern/device.c (grub_device_iterate): Change struct part_ent to
28 hold the name, not a pointer to it. Use one grub_malloc() per
29 partition, not two. Free partition_name if grub_malloc() fails.
30 Set ents to NULL only before grub_partition_iterate() is called.
32 2009-07-11 Bean <bean123ch@gmail.com>
34 * kern/ieee1275/openfw.c (grub_children_iterate): Fix size of
37 2009-07-10 Bean <bean123ch@gmail.com>
38 2009-07-10 Robert Millan <rmh.grub@aybabtu.com>
40 * kern/ieee1275/openfw.c (grub_children_iterate)
41 (grub_devalias_iterate): Fix size evaluation for property or path
42 strings, which was broken since r2132.
44 2009-07-07 Pavel Roskin <proski@gnu.org>
46 * commands/search.c (search_file): Merge into ...
47 (search_fs): ... this. Accept search type as argument.
48 (grub_cmd_search): Pass search type to search_fs().
50 * include/grub/util/console.h: New file.
51 * util/console.c: Use it instead of grub/machine/console.h.
52 * util/grub-emu.c: Likewise.
54 * lib/arg.c (find_long_option): Remove.
55 (find_long): Add `len' argument, make `s' const char *.
56 (grub_arg_parse): Parse long options in place, not in a
59 2009-07-06 Pavel Roskin <proski@gnu.org>
61 * commands/search.c (search_fs): Fix potential NULL pointer
64 * commands/search.c (search_fs): Replace QUID macro with quid_fn
67 2009-07-06 Daniel Mierswa <impulze@impulze.org>
69 * commands/search.c (search_fs): Use grub_strcasecmp() for UUID
72 2009-07-05 Pavel Roskin <proski@gnu.org>
74 * include/grub/i386/linux.h (struct linux_kernel_params):
75 Restore padding3, it's still needed.
77 * util/grub.d/10_freebsd.in: Fix spelling of `device.hints' on
79 * util/osdetect.lua: Likewise.
81 2009-07-05 Bean <bean123ch@gmail.com>
83 * conf/common.rmk (lua_mode_SOURCES): Add script/lua/lstrlib.c.
85 * script/lua/grub_lib.c (grub_lua_run): Check input parameter.
86 (grub_lua_getenv): Likewise.
87 (grub_lua_setenv): Likewise.
88 (save_errno): New function.
89 (push_result): Likewise.
90 (grub_lua_enum_device): Likewise.
91 (grub_lua_enum_file): Likewise.
92 (grub_lua_file_open): Likewise.
93 (grub_lua_file_close): Likewise.
94 (grub_lua_file_seek): Likewise.
95 (grub_lua_file_read): Likewise.
96 (grub_lua_file_getline): Likewise.
97 (grub_lua_file_getsize): Likewise.
98 (grub_lua_file_getpos): Likewise.
99 (grub_lua_file_eof): Likewise.
100 (grub_lua_file_exist): Likewise.
101 (grub_lua_add_menu): Likewise.
103 * script/lua/grub_lua.h (isupper): New inline function.
106 (isxdigit): Likewise.
107 (strcspn): Change to normal function.
108 (strpbkr): New function declaration.
111 * script/lua/grub_main.c (scan_str): New function.
116 * script/lua/linit.c (lualibs): Enable the string library.
118 * util/osdetect.lua: New file.
120 2009-07-04 Robert Millan <rmh.grub@aybabtu.com>
122 * include/grub/i386/linux.h (struct linux_kernel_params): Add
123 `capabilities' member.
125 2009-07-02 Pavel Roskin <proski@gnu.org>
127 * genparttoollist.sh: Add missing newline at the end.
129 2009-07-01 Pavel Roskin <proski@gnu.org>
131 * kern/x86_64/efi/callwrap.S: Add missing newline at the end.
133 * util/hostdisk.c (open_device): Remove `const' from
134 `sysctl_size', as sysctlbyname() can change it (in this case it
135 doesn't actually happen).
137 * include/grub/types.h: Define GRUB_LONG_MAX and GRUB_LONG_MIN
138 using signed long int constants.
140 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): Make `p'
141 constant to avoid a warning on FreeBSD.
143 * util/hostdisk.c (device_is_wholedisk): Compile only on systems
146 * Makefile.in: Install include/grub/machine symlink.
148 * Makefile.in: When installing symlinks, use "cp -fR", which
149 works on FreeBSD and MacOSX.
150 From Yves Blusseau <cl7m42e02@sneakemail.com>
152 * kern/dl.c (grub_dl_resolve_symbol): Make static.
153 * include/grub/dl.h: Remove grub_dl_resolve_symbol().
155 * util/misc.c: Move grub_reboot() and grub_halt() ...
156 * util/grub-emu.c: ... here. Make main_env static.
157 * include/grub/util/misc.h: Remove main_env.
159 * kern/mm.c: Use correct format to print size_t.
161 * include/grub/elf.h: Define Elf_Sword and Elf_Xword.
162 * kern/i386/dl.c: Use ELF symbols without "32" or "64".
163 * kern/powerpc/dl.c: Likewise.
164 * kern/sparc64/dl.c: Likewise.
165 * kern/x86_64/dl.c: Likewise.
167 2009-07-01 Robert Millan <rmh.grub@aybabtu.com>
169 Fix grub-emu build on sparc64-ieee1275.
171 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Syncronize with ...
172 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): ... this.
174 2009-07-01 Robert Millan <rmh.grub@aybabtu.com>
176 * util/misc.c: Include `<setjmp.h>' and `<grub/machine/machine.h>'.
177 (grub_reboot, grub_halt): New functions.
179 * util/i386/pc/misc.c: Delete. Update all users.
180 * util/sparc64/ieee1275/misc.c: Likewise.
181 * util/powerpc/ieee1275/misc.c: Likewise.
183 2009-07-01 Robert Millan <rmh.grub@aybabtu.com>
185 * conf/i386.rmk (setjmp_mod_SOURCES)
186 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): Move to ...
187 * conf/common.rmk (setjmp_mod_SOURCES)
188 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): ... here, and modify
189 to use $(target_cpu).
190 * conf/x86_64-efi.rmk (setjmp_mod_SOURCES)
191 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): Remove.
192 * conf/powerpc-ieee1275.rmk: Likewise.
193 * conf/sparc64-ieee1275.rmk: Likewise.
195 * conf/i386-pc.rmk (kernel_img_SOURCES): Use
196 $(target_cpu) for kern/$(target_cpu)/dl.c.
197 * conf/i386-efi.rmk: Likewise.
198 * conf/i386-ieee1275.rmk: Likewise.
199 * conf/x86_64-efi.rmk: Likewise.
200 * conf/i386-coreboot.rmk: Likewise.
201 * conf/powerpc-ieee1275.rmk (kernel_img_SOURCES): Use
202 $(target_cpu) for kern/$(target_cpu)/dl.c and for
203 kern/$(target_cpu)/cache.S.
204 * conf/sparc64-ieee1275.rmk: Likewise.
206 2009-07-01 Robert Millan <rmh.grub@aybabtu.com>
208 * include/grub/i386/linux.h (linux_kernel_params): Change `mmap_size'
209 type to `grub_uint8_t', and adjust `padding9' accordingly.
211 2009-06-29 Robert Millan <rmh.grub@aybabtu.com>
213 * include/grub/i386/linux.h (GRUB_VIDEO_TYPE_TEXT): New macro.
215 * loader/i386/linux.c [__i386__] (grub_linux_boot): Simplify inline
216 assembly in final jump, using register constraints.
218 (grub_linux_boot): For text mode, initialize `have_vga' using
219 GRUB_VIDEO_TYPE_TEXT rather than 0 (this changes its value to 1).
221 Initialize `video_cursor_x' and `video_cursor_y' as late as possible,
222 right before the final jump.
224 Set `video_mode' to 0x3.
226 Document initialization of `video_page', `video_mode' and
229 2009-06-29 Robert Millan <rmh.grub@aybabtu.com>
231 * include/grub/i386/linux.h (GRUB_LINUX_FLAG_QUIET): New macro.
232 * loader/i386/linux.c (grub_cmd_linux): Recognize "quiet" option,
233 and set GRUB_LINUX_FLAG_QUIET appropiately.
235 2009-06-29 Robert Millan <rmh.grub@aybabtu.com>
237 Fix build on Debian / sparc.
239 * configure.ac: Recognize `sparc' target_cpu (as sparc64).
241 2009-06-28 Pavel Roskin <proski@gnu.org>
243 * kern/i386/qemu/mmap.c (grub_machine_mmap_iterate): Use cast to
246 * util/grub.d/10_linux.in: Match SUSE style initrd names.
248 2009-06-27 Robert Millan <rmh.grub@aybabtu.com>
250 * loader/i386/linux.c (grub_linux_boot): Fix uninitialized use of
253 2009-06-27 Robert Millan <rmh.grub@aybabtu.com>
257 * loader/i386/linux.c (grub_cmd_linux): Don't call grub_error when
258 file can't be opened. grub_file_open() is already supposed to set
259 grub_errno / grub_errmsg appropiately.
260 * loader/i386/pc/linux.c (grub_cmd_linux): Likewise.
262 2009-06-27 Pavel Roskin <proski@gnu.org>
263 2009-06-27 Robert Millan <rmh.grub@aybabtu.com>
265 * include/grub/dl.h: Include grub/elf.h.
266 (struct grub_dl): Add symtab field.
267 * kern/dl.c [GRUB_MACHINE_QEMU]: Define
268 GRUB_MODULES_MACHINE_READONLY.
269 (grub_dl_resolve_symbols): Populate mod->symtab, making a copy
270 of the header for read-only modules.
271 (grub_dl_unload): Free mod->symtab for read-only modules.
272 * kern/i386/dl.c: Use mod->symtab.
273 * kern/powerpc/dl.c: Likewise.
274 * kern/sparc64/dl.c: Likewise.
275 * kern/x86_64/dl.c: Likewise.
277 * conf/i386-qemu.rmk: New file.
278 * kern/i386/qemu/startup.S: Likewise.
279 * kern/i386/qemu/mmap.c: Likewise.
280 * boot/i386/qemu/boot.S: Likewise.
281 * include/grub/i386/qemu/time.h: Likewise.
282 * include/grub/i386/qemu/serial.h: Likewise.
283 * include/grub/i386/qemu/kernel.h: Likewise.
284 * include/grub/i386/qemu/console.h: Likewise.
285 * include/grub/i386/qemu/boot.h: Likewise.
286 * include/grub/i386/qemu/init.h: Likewise.
287 * include/grub/i386/qemu/machine.h: Likewise.
288 * include/grub/i386/qemu/loader.h: Likewise.
289 * include/grub/i386/qemu/memory.h: Likewise.
291 * conf/i386-coreboot.rmk (GRUB_BOOT_MACHINE_LINK_ADDR)
292 (GRUB_KERNEL_MACHINE_LINK_ADDR): New variables.
293 [qemu] (pkglib_IMAGES): Add `boot.img'.
294 [qemu] (boot_img_SOURCES, boot_img_ASFLAGS, boot_img_LDFLAGS)
295 [qemu] (boot_img_FORMAT): New variables.
296 [qemu] (bin_UTILITIES): Add `grub-mkimage'.
297 [qemu] (grub_mkimage_SOURCES, grub_mkimage_CFLAGS): New variables.
298 [qemu] (kernel_img_SOURCES, kernel_img_HEADERS, kernel_img_CFLAGS)
299 [qemu] (kernel_img_ASFLAGS, kernel_img_LDFLAGS)
300 [qemu] (kernel_img_FORMAT): New variables.
302 * configure.ac: Recognise `i386-qemu'.
304 * util/i386/pc/grub-mkimage.c (compress_kernel): Add dummy variant
305 (for no compression).
306 [GRUB_MACHINE_QEMU] (generate_image): Misc adjustments to produce
307 a valid i386 ROM image. Make `GRUB_KERNEL_MACHINE_COMPRESSED_SIZE',
308 `GRUB_KERNEL_MACHINE_INSTALL_DOS_PART' and
309 `GRUB_KERNEL_MACHINE_INSTALL_BSD_PART' optional features (with
312 2009-06-27 Pavel Roskin <proski@gnu.org>
314 * efiemu/prepare.c: Eliminate TYPE macro, it makes code hard to
316 * efiemu/prepare32.c: Likewise.
317 * efiemu/prepare64.c: Likewise.
319 2009-06-26 Pavel Roskin <proski@gnu.org>
321 * include/grub/types.h: Define GRUB_TARGET_WORDSIZE.
322 * include/grub/elf.h: Define symbols without "32" or "64" based
323 on GRUB_TARGET_WORDSIZE.
324 * include/grub/multiboot2.h: Use GRUB_TARGET_WORDSIZE.
325 * efiemu/loadcore32.c: Redefine GRUB_TARGET_WORDSIZE, remove own
327 * efiemu/loadcore64.c: Likewise.
328 * loader/i386/bsd32.c: Likewise.
329 * loader/i386/bsd64.c: Likewise.
330 * kern/dl.c: Remove own ELF definitions.
331 * util/i386/efi/grub-mkimage.c: Likewise.
333 2009-06-23 Robert Millan <rmh.grub@aybabtu.com>
335 * kern/i386/pc/startup.S (real_to_prot): Access `gdtdesc' using
336 segment 0x0 unconditionally, because the reference generated by
337 GAS is an absolute address.
339 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
341 * include/grub/i386/kernel.h: Include `<grub/machine/machine.h>'.
342 [! GRUB_MACHINE_IEEE1275]: Set `GRUB_MOD_ALIGN' to 0x1.
344 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
346 * commands/search.c (grub_cmd_search): Macroify hardcoded args[]
347 indexes. Check for -f explicitly.
348 (search_file): Improve error message.
349 (GRUB_MOD_INIT(search)): Add missing `-n' to help output.
351 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
353 * conf/i386-pc.rmk (GRUB_MEMORY_MACHINE_LINK_ADDR): Rename to ...
354 (GRUB_KERNEL_MACHINE_LINK_ADDR): ... this. Update all users.
356 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
358 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/misc.S'.
359 * conf/i386-ieee1275.rmk: Likewise.
360 * conf/i386-coreboot.rmk: Likewise.
362 * kern/i386/pc/startup.S (grub_stop): Remove function.
363 * kern/i386/ieee1275/startup.S: Likewise.
364 * kern/i386/coreboot/startup.S: Likewise.
365 * kern/i386/misc.S (grub_stop): New function.
367 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
369 * kern/i386/pc/startup.S (real_to_prot): Move from here ...
370 * kern/i386/realmode.S (real_to_prot): ... to here.
372 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
374 * conf/i386-ieee1275.rmk (pkglib_PROGRAMS): Replace `kernel.elf'
376 (kernel_elf_SOURCES): Rename to ...
377 (kernel_img_SOURCES): ... this.
378 (kernel_elf_HEADERS): Rename to ...
379 (kernel_img_HEADERS): ... this. Update all users.
380 (kernel_elf_ASFLAGS): Rename to ...
381 (kernel_img_ASFLAGS): ... this.
382 (kernel_elf_CFLAGS): Rename to ...
383 (kernel_img_CFLAGS): ... this.
384 (kernel_elf_LDFLAGS): Rename to ...
385 (kernel_img_LDFLAGS): ... this.
386 * conf/i386-coreboot.rmk: Likewise.
387 * conf/powerpc-ieee1275.rmk: Likewise.
389 * util/elf/grub-mkimage.c (add_segments): Replace "kernel.elf"
392 2009-06-21 Pavel Roskin <proski@gnu.org>
394 * loader/powerpc/ieee1275/linux.c (offset_phdr): Fix prototypes
395 to match nested functions.
396 * loader/sparc64/ieee1275/linux.c: Likewise.
398 * conf/i386-ieee1275.rmk: Define kernel_elf_ASFLAGS.
400 2009-06-21 Robert Millan <rmh.grub@aybabtu.com>
402 * configure.ac: Enable `END_SYMBOL' / `BSS_START_SYMBOL' test on
405 2009-06-21 Robert Millan <rmh.grub@aybabtu.com>
407 Fix asm file handling on ELF, and remove workarounds.
409 * genmk.rb (class Programs): Detect assembly files, and set ASFLAGS
410 and -DASM_FILE=1 appropiately (copied from `class Images' stanza).
411 * kern/i386/ieee1275/startup.S (ASM_FILE): Remove macro.
412 * kern/i386/coreboot/startup.S (ASM_FILE): Likewise.
414 2009-06-21 Vladimir Serbinenko <phcoder@gmail.com>
418 * conf/i386-pc.rmk (bsd_mod_SOURCES): Add loader/i386/bsd32.c
419 and loader/i386/bsd64.c
420 * include/grub/i386/bsd.h (FREEBSD_MODTYPE_MODULE): Remove
421 (FREEBSD_MODTYPE_ELF_MODULE): New definition
422 (FREEBSD_MODTYPE_ELF_MODULE_OBJ): Likewise
423 (grub_freebsd_load_elfmodule32): New declaration
424 (grub_freebsd_load_elfmoduleobj64): Likewise
425 (grub_freebsd_load_elf_meta32): Likewise
426 (grub_freebsd_load_elf_meta64): Likewise
427 (grub_freebsd_add_meta): Likewise
428 (grub_freebsd_add_meta_module): Likewise
429 * loader/i386/bsd.c (grub_freebsd_add_meta): Make global
430 (grub_freebsd_add_meta_module): Likewise and move module-specific
431 parts to grub_cmd_freebsd and grub_cmd_freebsd_module
432 (grub_cmd_freebsd): Add elf-kernel specific parts
433 based on grub_freebsd_add_meta_module
434 (grub_cmd_freebsd_module): Add type parsing moved from
435 grub_freebsd_add_meta_module
436 (grub_cmd_freebsd_module_elf): New function
437 (cmd_freebsd_module_elf): New variable
438 (GRUB_MOD_INIT): Register freebsd_module_elf
439 * loader/i386/bsd32.c: New file
440 * loader/i386/bsd64.c: Likewise
441 * loader/i386/bsdXX.c: Likewise
442 * kern/elf.c (grub_elf32_load): Let hook decide which pheaders to load
443 (grub_elf64_load): Likewise
444 * include/grub/elfload.h (grub_elf32_load_hook_t): New parameter do_load
446 (grub_elf64_load_hook_t): Likewise
448 2009-06-21 Colin Watson <cjwatson@ubuntu.com>
450 * util/grub-mkconfig.in (GRUB_DISABLE_LINUX_RECOVERY): Export
452 * util/grub.d/10_linux.in: If GRUB_DISABLE_LINUX_RECOVERY is true,
453 don't write a menu entry for recovery mode.
455 2009-06-20 Robert Millan <rmh.grub@aybabtu.com>
457 * util/i386/pc/grub-mkimage.c (main): Oops, free `output' only
458 after it's no longer needed.
460 2009-06-20 Robert Millan <rmh.grub@aybabtu.com>
462 * include/grub/i386/loader.h (grub_linux_prot_size)
463 (grub_linux_tmp_addr, grub_linux_real_addr)
464 (grub_linux_is_bzimage, grub_linux16_boot): Declare only on
466 * util/i386/pc/grub-mkimage.c (compress_kernel): Move
467 common grub_util_info() call to ...
468 (generate_image): ... here.
469 Fix use of uninitialized memory, comparison of signed with
470 unsigned integers and memory leak.
471 Remove bogus module address message.
473 2009-06-20 Vladimir Serbinenko <phcoder@gmail.com>
475 * disk/mdraid_linux.c (GRUB_MOD_FINI): use grub_raid_unregister and not
477 * disk/dmraid_nvidia.c (GRUB_MOD_FINI): likewise
479 2009-06-19 Pavel Roskin <proski@gnu.org>
481 * configure.ac: Remove stray AC_MSG_CHECKING.
483 2009-06-19 Vladimir Serbinenko <phcoder@gmail.com>
485 * disk/scsi.c (grub_scsi_open): use continue instead of big if
487 2009-06-18 Pavel Roskin <proski@gnu.org>
489 * conf/common.rmk: Add fs_file.mod.
490 * disk/fs_file.c: New file.
491 * include/grub/disk.h (enum grub_disk_dev_id): Add
492 GRUB_DISK_DEVICE_FILE_ID.
494 2009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
496 Fix build with Apple's toolchain. Part 2
498 * aclocal.m4 (grub_PROG_TARGET_CC): add missing prototype for main and
501 2009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
503 Fix build with Apple's toolchain. Part 1
505 * commands/i386/pc/drivemap_int13h.S: use assembly-time constants
507 * configure.ac: remove a leftover AC_MSG_RESULT
508 (CFLAGS): don't add -Wl,--defsym,___main=0x8100 when building with
511 2009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
515 * fs/ntfscomp.c (decomp_get16): initialize c1 and c2
516 (decomp_block): initialize ch
517 use grub_memcpy instead of memcpy
519 2009-06-17 Pavel Roskin <proski@gnu.org>
521 * include/grub/i386/coreboot/console.h: Don't use the i386-pc
522 version, use declarations needed to use vga_text as the startup
525 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Remove
526 term/i386/pc/at_keyboard.c, it doesn't need to be compiled into
528 * kern/i386/coreboot/init.c: Don't call grub_at_keyboard_init()
529 and grub_at_keyboard_fini(), it's done on module load and
532 2009-06-17 Felix Zielcke <fzielcke@z-51.de>
534 * loader/i386/linux.c (grub_cmd_linux): Set grub_error if the
536 * loader/i386/pc/linux.c (grub_cmd_linux): Likewise.
538 2009-06-17 Vladimir Serbinenko <phcoder@gmail.com>
542 * include/grub/script_sh.h (grub_lexer_param): new field was_newline
543 * script/sh/lexer.c (grub_script_lexer_init): initialize was_newline
544 (grub_script_yylex): don't segfault on unterminated script
545 newline terminates command and variable
547 2009-06-17 Vladimir Serbinenko <phcoder@gmail.com>
549 avoid double grub_adjust_range call. Bug reported by David Simner
551 * kern/disk.c (grub_disk_write): change to raw disk access before
554 2009-06-17 Colin Watson <cjwatson@ubuntu.com>
556 * util/elf/grub-mkimage.c (usage): Prefix each option line with two
557 spaces, for the benefit of help2man.
558 * util/i386/efi/grub-mkimage.c (usage): Likewise.
560 2009-06-16 Pavel Roskin <proski@gnu.org>
562 * kern/i386/halt.c: Include grub/machine/init.h.
563 * kern/i386/reboot.c: Include grub/cpu/reboot.h.
565 2009-06-16 Felix Zielcke <fzielcke@z-51.de>
567 * util/grub.d/30_os-prober.in: Use ${root} in the generated
570 2009-06-16 James Jarvis <James.Jarvis@ed.ac.uk>
572 * commands/help.c GRUB_MOD_INIT(echo): Fix the help output of
575 2009-06-16 Pavel Roskin <proski@gnu.org>
577 * boot/i386/pc/boot.S: Remove root_drive. Assert offset of
578 boot_drive_check by using GRUB_BOOT_MACHINE_DRIVE_CHECK. Don't
579 save %dx, we only need %dl and we never change it.
580 * boot/i386/pc/cdboot.S: Don't set the root drive.
581 * boot/i386/pc/pxeboot.S: Likewise.
582 * include/grub/i386/pc/boot.h: Remove
583 GRUB_BOOT_MACHINE_ROOT_DRIVE, adjust
584 GRUB_BOOT_MACHINE_DRIVE_CHECK.
585 * include/grub/i386/pc/kernel.h: Remove grub_root_drive.
586 * kern/i386/pc/init.c (make_install_device): Remove references
588 * kern/i386/pc/startup.S: Likewise.
589 * util/i386/pc/grub-setup.c (setup): Don't set root_drive.
591 2009-06-16 Vladimir Serbinenko <phcoder@gmail.com>
595 * commands/xnu_uuid.c: new file
596 * conf/common.rmk (pkglib_MODULES): add xnu_uuid.mod
597 (xnu_uuid_mod_SOURCES): new variable
598 (xnu_uuid_mod_CFLAGS): likewise
599 (xnu_uuid_mod_LDFLAGS): likewise
600 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/probe.c
601 * conf/i386-ieee1275.rmk: likewise
602 * conf/i386-pc.rmk: likewise
603 * conf/powerpc-ieee1275.rmk: likewise
604 * conf/sparc64-ieee1275.rmk: likewise
605 * util/grub.d/30_os-prober.in: use UUID for Mac OS X/Darwin
607 2009-06-16 Pavel Roskin <proski@gnu.org>
609 * configure.ac: Avoid '==' in test command, it's not portable.
611 2009-06-16 Vladimir Serbinenko <phcoder@gmail.com>
615 * commands/probe.c: new file
616 * conf/common.rmk (pkglib_MODULES): add probe.mod
617 (probe_mod_SOURCES): new variable
618 (probe_mod_CFLAGS): likewise
619 (probe_mod_LDFLAGS): likewise
620 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/probe.c
621 * conf/i386-ieee1275.rmk: likewise
622 * conf/i386-pc.rmk: likewise
623 * conf/powerpc-ieee1275.rmk: likewise
624 * conf/sparc64-ieee1275.rmk: likewise
626 2009-06-15 Vladimir Serbinenko <phcoder@gmail.com>
628 Fix handling of string like \"hello\" and "a
631 * script/sh/lexer.c (check_textstate): accept GRUB_PARSER_STATE_ESC
632 (grub_script_yylex): fix parsing of quoting, escaping and newline
634 2009-06-13 Vladimir Serbinenko <phcoder@gmail.com>
636 * loader/i386/multiboot.c (grub_multiboot_get_bootdev): fix partition
639 2009-06-13 Jun Inoue <jun.lambda@gmail.com>
641 * util/grub-mkconfig.in: Fix parsing of --output option.
643 2009-06-12 Pavel Roskin <proski@gnu.org>
645 * Makefile.in (pkgdata_SRCDIR): Remove. genmodsrc.sh and
646 genmk.rb don't need to be generated or installed.
648 2009-06-12 Vladimir Serbinenko <phcoder@gmail.com>
650 * commands/i386/pc/drivemap_int13h.S: add more comments
652 2009-06-11 Pavel Roskin <proski@gnu.org>
654 * Makefile.in (uninstall): Uninstall manuals.
656 * Makefile.in: Rename lib_DATA to lib_SCRIPTS, move it from
657 PKGLIB to SCRIPTS. This fixes installation of grub-mkconfig_lib
658 and update-grub_lib in two places.
659 * conf/common.rmk: Rename lib_DATA to lib_SCRIPTS.
661 * disk/usbms.c (grub_usbms_transfer): Initialize `err' to fix
664 * loader/i386/bsd.c (grub_freebsd_boot): Rename `entry' to
665 `entry_lo' to fix variable shadowing.
667 2009-06-11 Christian Franke <franke@computer.org>
669 * kern/misc.c (__enable_execute_stack): Add missing return type
670 to prevent gcc warning.
672 2009-06-11 Felix Zielcke <fzielcke@z-51.de>
674 * conf/i386-ieee1275.rmk (COMMON_LDFLAGS): Remove `-static -lgcc'.
676 2009-06-11 Pavel Roskin <proski@gnu.org>
678 * Makefile.in: Don't rely on any scripts being executable.
679 Always use $(SHELL) to run shell scripts.
681 * configure.ac: Always define ___main if using -nostdlib. This
682 fixes tests on Cygwin.
684 2009-06-11 Giuseppe Caizzone <acaizzo@gmail.com>
688 * fs/udf.c (grub_udf_read_block): handle the fact that ad->length
689 is in bytes and not in blocks
691 2009-06-11 Pavel Roskin <proski@gnu.org>
693 * kern/i386/halt.c (grub_halt): Make `i' unsigned to fix a
696 2009-06-11 Felix Zielcke <fzielcke@z-51.de>
698 * util/grub.d/30_os-prober.in: Fix a comment. Source
699 ${libdir}/grub/grub-mkconfig_lib. Use prepare_grub_to_access_device
700 to set the root device. Place drivemap command in the generated
703 2009-06-11 Pavel Roskin <proski@gnu.org>
705 * configure.ac: Remove host_m32. Issues with 64-bit utilities
706 have long been resolved.
708 2009-06-11 Colin Watson <cjwatson@ubuntu.com>
710 * util/grub.d/10_linux.in: Capitalise "Linux".
712 * util/grub-pe2elf.c (usage): Fix references to grub-editenv.
714 2009-06-11 Pavel Roskin <proski@gnu.org>
716 * kern/efi/efi.c (grub_exit): Add infinite loop at the end to
717 fix a gcc warning and ensure that the function won't ever exit.
719 * kern/i386/ieee1275/init.c: Add missing prototype for
722 * loader/ieee1275/multiboot2.c [__i386__]: Include
723 grub/cpu/multiboot.h.
725 * term/i386/pc/serial.c (serial_translate_key_sequence): Avoid
726 casts to short - they are not portable and cause warnings. Fix
727 use of uninitialized values in input_buf. Use ARRAY_SIZE.
729 2009-06-11 Vladimir Serbinenko <phcoder@gmail.com>
733 * commands/i386/pc/drivemap.c (grub_get_root_biosnumber_drivemap):
735 (grub_get_root_biosnumber_saved): new variable
736 (GRUB_MOD_INIT): register grub_get_root_biosnumber_drivemap
737 (GRUB_MOD_FINI): unregister grub_get_root_biosnumber_drivemap
738 * commands/i386/pc/drivemap_int13h.S (grub_drivemap_handler): restore
739 %dx after the call if necessary
740 * conf/common.rmk (pkglib_MODULES): remove boot.mod
741 (boot_mod_SOURCES): remove
742 (boot_mod_CFLAGS): remove
743 (boot_mod_LDFLAGS): remove
744 * conf/i386-coreboot.rmk (pkglib_MODULES): add boot.mod
745 (boot_mod_SOURCES): new variable
746 (boot_mod_CFLAGS): likewise
747 (boot_mod_LDFLAGS): likewise
748 * conf/i386-efi.rmk: likewise
749 * conf/i386-ieee1275.rmk: likewise
750 * conf/i386-pc.rmk: likewise
751 * conf/powerpc-ieee1275.rmk: likewise
752 * conf/sparc64-ieee1275.rmk: likewise
753 * conf/x86_64-efi.rmk: likewise
754 * include/grub/i386/pc/biosnum.h: new file
755 * lib/i386/pc/biosnum.c: likewise
756 * loader/i386/bsd.c (grub_bsd_get_device): use grub_get_root_biosnumber
757 * loader/i386/multiboot.c (grub_multiboot_get_bootdev): likewise
758 * loader/i386/pc/chainloader.c (grub_chainloader_cmd): likewise
760 2009-06-10 Pavel Roskin <proski@gnu.org>
762 * io/gzio.c (test_header): Don't reuse one buffer for all data.
763 Use separate variables. Read only the file size at the end, but
764 not the checksum that we don't use.
766 * kern/file.c (grub_file_read): Use void pointer for the buffer.
769 * kern/ieee1275/openfw.c: Remove libc includes.
770 * kern/ieee1275/cmain.c: Likewise.
771 * include/grub/ieee1275/ieee1275.h: Likewise.
773 * kern/i386/coreboot/init.c: Include grub/cpu/tsc.h to fix
776 2009-06-10 Felix Zielcke <fzielcke@z-51.de>
778 * gendistlist.sh (EXTRA_DISTFILES): Add `genhandlerlist.sh' and
779 `genparttoollist.sh'.
780 (DISTDIRS): Add `efiemu', `mmap', `parttool' and `script'.
781 Add `*.sh' to the list find searches for and change `mdate.sh'
784 2009-06-10 Pavel Roskin <proski@gnu.org>
786 * include/grub/multiboot2.h: Provide compatibility defines for
788 * include/multiboot2.h: Include stdint.h only if needed, using
790 * loader/i386/pc/multiboot2.c: Include multiboot2.h after
792 * loader/ieee1275/multiboot2.c: Likewise.
793 * loader/multiboot2.c: Likewise.
794 * loader/multiboot_loader.c: Likewise.
796 * configure.ac: Use -nostdlib when probing for the target. It
797 should not be required to have libc for the target.
799 * configure.ac: Remove checks for __bswapsi2 and __bswapdi2,
800 they fail without libc headers for the target.
801 * include/grub/powerpc/libgcc.h: Use weak attribute for all
803 * include/grub/sparc64/libgcc.h: Likewise. Don't use
804 preprocessor conditionals.
806 * conf/common.rmk: Compile tar.mod from tar.c, not cpio.c. The
807 build system doesn't need to be aware of the tar.c internals.
809 2009-06-09 Michel Hermier <michel.hermier@gmail.com>
811 * fs/i386/pc/pxe.c (grub_pxefs_read): Fix returned values.
813 2009-06-09 Robert Millan <rmh.grub@aybabtu.com>
815 * util/deviceiter.c (grub_util_iterate_devices): Increase number of
816 disk limit to 26 for IDE, Virtio, Xen and SCSI.
818 2009-06-09 Felix Zielcke <fzielcke@z-51.de>
820 * util/i386/pc/grub-install.in: Change the error message if UUIDs
821 aren't available if ata.mod gets used.
823 2009-06-09 Oliver Henshaw <oliver.henshaw@gmail.com>
825 * bus/usb/ohci.c (grub_ohci_pci_iter): Link struct only after
826 initialising controller.
827 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
829 2009-06-08 Felix Zielcke <fzielcke@z-51.de>
831 * util/i386/pc/grub-install.in: Add a parameter --disk-module
832 to choose between ata and biosdisk module on i386-pc.
834 2009-06-08 Oliver Henshaw <oliver.henshaw@gmail.com>
836 * bus/usb/ohci.c (grub_ohci_pci_iter): Define the Class,
837 Subclass and Programming Interface fields in terms of the 3 byte
839 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
841 * bus/usb/ohci.c (grub_ohci_pci_iter): Check that programming
842 interface is OHCI. Add grub_dprintf for symmetry with
844 * bus/usb/uhci.c (grub_uhci_pci_iter): Check that programming
845 interface is UHCI. Add interf variable for programming
846 interface. Print interface with class/subclass.
848 * bus/usb/ohci.c: Set interf with correct field.
850 * bus/usb/uhci.c: Remove unneeded doubled lines.
851 * bus/usb/ohci.c: Likewise. Change interf to grub_uint32_t.
852 Remove whitespace inside comment.
854 2009-06-08 Robert Millan <rmh.grub@aybabtu.com>
856 * loader/i386/linux.c (grub_cmd_linux): When processing `vga=', use
857 as fallback an equivalent option without depth.
859 2009-06-08 Vladimir Serbinenko <phcoder@gmail.com>
861 Not fail if unable to retrieve C/H/S on LBA disks
863 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): behave gracefully
864 if unable to retrieve C/H/S on LBA disks
866 2009-06-08 Pavel Roskin <proski@gnu.org>
868 * fs/hfs.c (grub_hfs_find_dir): Use union to avoid a warning
871 2009-06-08 Felix Zielcke <fzielcke@z-51.de>
873 * Makefile.in (uninstall): Remove all $lib_DATA files.
875 2009-06-08 Vladimir Serbinenko <phcoder@gmail.com>
877 Bugfix: install on partitionless device
879 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): check if os_dev
882 2009-06-08 Felix Zielcke <fzielcke@z-51.de>
884 * Makefile.in (uninstall): Remove all $include_DATA files.
886 2009-06-08 Felix Zielcke <fzielcke@z-51.de>
888 * commands/true.c: New file. Implement the true and false commands.
889 * conf/common.rmk.c (pkglib_MODULES): Add `true.mod'.
890 (true_mod_SOURCES): New variable.
891 (true_mod_CFLAGS): Likewise.
892 (true_mod_LDFLAGS): Likewise.
894 2009-06-05 Colin D Bennett <colin@gibibit.com>
896 Optimized font character lookup using binary search instead of linear
897 search. Fonts now are required to have the character index ordered by
900 * font/font.c (load_font_index): Verify that fonts have ordered
902 (find_glyph): Use binary search instead of linear search to find a
905 2009-06-05 Michael Scherer <misc@mandriva.org>
907 * fs/hfsplus.c (grub_hfsplus_mount): Determine if the filesystem
908 uses case sensitive btree.
909 (grub_hfsplus_iterate_dir): Use GRUB_FSHELP_CASE_INSENSITIVE
910 only for case insensitive filesystems.
912 2009-06-05 Vladimir Serbinenko <phcoder@gmail.com>
914 * conf/i386-pc.rmk (efiemu_mod_CFLAGS): remove -Werror -Wall
915 * conf/common.rmk (search_mod_CFLAGS): likewise
917 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
919 * kern/i386/pc/startup.S [APPLE_CC]: block of nops to
920 compensate a compiler bug
922 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
924 * include/grub/term.h (GRUB_TERM_BACKSPACE): explicitly define as 8
927 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
929 Definitions for creating asm symbols with Apple's CC
931 * include/grub/symbol.h [APPLE_CC] (FUNCTION): new macro
932 [APPLE_CC] (VARIABLE): likewise
934 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
936 Disable lnxboot.img when compiled
939 * conf/i386-pc.rmk (pkglib_IMAGES): remove lnxboot.img
940 pkglib_IMAGES [! TARGET_APPLE_CC] (pkglib_IMAGES): add lnxboot.img
941 * boot/i386/pc/lnxboot.S [APPLE_CC]: define an #error
942 [! APPLE_CC] (CODE_LENG): skip
943 [! APPLE_CC] (setup_sects): likewise
944 [! APPLE_CC]: skip filling
946 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
948 Address in trampolines based on 32-bit registers when compiled
951 * loader/i386/xnu_helper.S [APPLE_CC]: use 32-bit registers
953 * loader/i386/linux_trampoline.S [APPLE_CC]: likewise
955 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
957 Avoid aliases when compiling with Apple's CC for PCBIOS machine
959 * kern/misc.c [APPLE_CC] (memcpy): new function
960 [APPLE_CC] (memmove): likewise
961 [APPLE_CC && !GRUB_UTIL] (grub_err_printf): likewise
962 (memcpy): define alias conditionally on !APPLE_CC
965 * include/grub/misc.h (memove): don't define when both GRUB_UTIL and
967 * include/grub/list.h [APPLE_CC] (grub_assert_fail): new function
968 (grub_assert_fail): make prototype conditional
970 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
972 Use grub-macho2img when compiling with Apple's CC for PCBIOS machine
974 * conf/common.rmk (bin_UTILITIES): add (on false on condition)
976 (CLEANFILES): add grub-macho2img
977 (grub_macho2img_SOURCES): new variable
978 * kern/i386/pc/startup.S (bss_start): new variable
980 * genmk.rb: use grub-macho2img for *.img when compiled with Apple's CC
981 * util/grub-macho2img.c: new file
983 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
985 Use objconv when compiling with Apple's CC
987 * conf/i386-pc.rmk (efiemu32.o): use OBJCONV if defined
988 (efiemu64.o): likewise
989 (efiemu64_c.o): omit -mcmodel=large and add -DAPPLE_CC=1
990 when compiling with Apple's CC
991 (efiemu64_s.o): likewise
992 * configure.ac: check for objconv when compiling with Apple's CC
993 * genmk.rb: use objconv for modules when compiled with Apple's CC
995 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
997 Define segment as well as section when compiling with
1000 * efiemu/runtime/efiemu.c (PHYSICAL_ATTRIBUTE): new definition
1001 (efiemu_set_virtual_address_map): declare with PHYSICAL_ATTRIBUTE
1002 (efiemu_convert_pointer): likewise
1003 (efiemu_set_virtual_address_map): likewise
1004 (efiemu_convert_pointer): likewise
1005 (efiemu_getcrc32): likewise
1006 (init_crc32_table): likewise
1008 * include/grub/dl.h (GRUB_MOD_NAME): define segment with Apple's CC
1009 (GRUB_MOD_DEP): likewise
1011 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1013 Allow a compilation without -mcmodel=large
1015 * kern/efi/mm.c (grub_efi_allocate_pages): don't allocate >4GiB
1016 when compiled without -mcmodel=large
1017 (filter_memory_map): remove memory post 4 GiB when compiled
1018 without -mcmodel=large
1019 * configure.ac: fail gracefully and add -DMCMODEL_SMALL=1 to
1020 TARGET_CFLAGS when -mcmodel=large isn't supported
1022 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1024 Remove nested functions in efiemu core
1026 * efiemu/runtime/efiemu.c (reflect): make static instead of nested
1028 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1030 Avoid clobbering %ebx/%rbx in inline assembly with Apple's CC
1032 * efiemu/runtime/efiemu.c (write_cmos): use %cl instead of %bl as
1034 * include/grub/i386/tsc.h (grub_get_tsc): restore %rbx/%ebx when
1036 (grub_cpu_is_tsc_supported): likewise
1037 * loader/i386/xnu.c (guessfsb): restore %rbx/%ebx in inline assembly
1039 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1041 Absolute addressing through constant with Apple's cc
1043 * kern/i386/pc/startup.S: Define necessary constants
1044 and address through it when using ABS with Apple's CC
1045 * boot/i386/pc/diskboot.S: likewise
1046 * boot/i386/pc/boot.S: likewise
1047 * boot/i386/pc/lnxboot.S: likewise
1048 * boot/i386/pc/cdboot.S: likewise
1049 * mmap/i386/pc/mmap_helper.S: likewise
1050 * commands/i386/pc/drivemap_int13h.S: likewise
1052 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1054 Check if compiler is apple cc
1056 * Makefile.in (ASFLAGS): new variable
1057 (TARGET_ASFLAGS): likewise
1058 (TARGET_MODULE_FORMAT): likewise
1059 (TARGET_APPLE_CC): likewise
1061 (TARGET_IMG_CFLAGS): likewise
1062 (TARGET_CPPFLAGS): add includedir
1063 * configure.ac: call grub_apple_cc and grub_apple_target_cc
1064 (TARGET_IMG_LDFLAGS): Add -Wl,-Ttext,. All users updated
1065 Check for linker script only if compiler isn't Apple's CC
1066 (TARGET_MODULE_FORMAT): set
1067 (TARGET_APPLE_CC): likewise
1068 (TARGET_ASFLAGS): likewise
1070 Check for objcopy only if compiler isn't Apple's CC
1071 Check for BSS symbol only if compiler isn't Apple's CC
1072 * genmk.rb: adapt nm options if we use Apple's utils
1073 * aclocal.m4 (grub_apple_cc): new test
1074 (grub_apple_target_cc): likewise
1076 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1078 Simplify sed expressions and improve awk
1080 * Makefile.in (install-local): simplify sed expression
1081 * gencmdlist.sh: likewise
1082 * genmoddep.awk: avoid adding module as a dependency of itself
1084 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1086 Add missing start symbols
1088 * boot/i386/pc/boot.S: add start
1089 * boot/i386/pc/pxeboot.S: likewise
1091 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1093 Fix wrong assumptions with grub-mkimage on EFI
1095 * i386/efi/grub-mkimage.c (read_kernel_module): don't write prefix here
1096 (relocate_addresses): consider both r_addend and value at offset
1097 (make_mods_section): zerofill modinfo and header
1098 (convert_elf): write prefix here
1100 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1102 Use .asciz instead of .string
1104 * i386/pc/diskboot.S: use .asciz instead of .string
1105 * i386/pc/boot.S: likewise
1106 * include/grub/dl.h (GRUB_MOD_DEP): likewise
1107 (GRUB_MOD_NAME): likewise
1109 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1113 * commands/videotest.c (grub_cmd_videotest): use grub_video_set_mode
1114 * include/grub/video.h (GRUB_VIDEO_MODE_TYPE_PURE_TEXT): new definition
1115 (grub_video_setup): remove
1116 (grub_video_set_mode): new prototype
1117 * loader/i386/linux.c (DEFAULT_VIDEO_MODE): new definition
1119 (linux_vesafb_res): compile only on PCBIOS
1120 (grub_linux_boot): support gfxpayload
1121 * loader/i386/pc/xnu.c (video_hook): new function
1122 (grub_xnu_set_video): support gfxpayload
1123 * term/gfxterm.c (DEFAULT_VIDEO_WIDTH): removed
1124 (DEFAULT_VIDEO_HEIGHT): likewise
1125 (DEFAULT_VIDEO_FLAGS): likewise
1126 (DEFAULT_VIDEO_MODE): new definition
1127 (video_hook): new function
1128 (grub_gfxterm_init): use grub_video_set_mode
1129 * util/grub.d/30_os-prober.in: remove explicit modesetting before
1131 * video/video.c (grub_video_setup): removed
1132 (grub_video_set_mode): new function based on grub_gfxterm_init and
1135 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1137 Avoid calling biosdisk in drivemap
1139 * commands/i386/pc/drivemap.c (parse_biosdisk): remove
1140 (revparse_biosdisk): likewise
1141 (list_mappings): derive name from id directly
1142 (grub_cmd_drivemap): use tryparse_diskstring
1144 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1148 * include/grub/script_sh.h (grub_script_cmdline): remove cmdline
1149 (grub_lexer_param): add tokenonhold
1150 (grub_script_create_cmdline): remove cmdline. All callers updated
1151 (grub_script_function_create): make functionname
1152 grub_script_arg. All callers updated
1153 (grub_script_execute_argument_to_string): new prototype
1154 * kern/parser.c (state_transitions): reorder
1155 (grub_parser_cmdline_state): fix a bug and make more compact
1156 * script/sh/execute.c (grub_script_execute_argument_to_string):
1158 (grub_script_execute_cmdline): use new format
1159 * script/sh/function.c (grub_script_function_create): make functionname
1160 grub_script_arg. All callers updated
1161 * script/sh/lexer.c (grub_script_lexer_init): initialize tokenonhold
1162 (grub_script_yylex): remove
1163 (grub_script_yylex2): renamed to ...
1164 (grub_script_yylex): ...renamed
1165 parse the expressions like a${b}c
1166 * script/sh/parser.y (GRUB_PARSER_TOKEN_ARG): new typed terminal
1167 (GRUB_PARSER_TOKEN_VAR): remove
1168 (GRUB_PARSER_TOKEN_NAME): likewise
1169 ("if"): declare as typeless
1171 ("function"): likewise
1176 (argument): likewise
1177 (script): accept empty scripts and make exit on error
1178 (arguments): use GRUB_PARSER_TOKEN_ARG
1179 (function): likewise
1180 (command): move error handling to script
1181 (menuentry): move grub_script_lexer_ref before
1182 * script/sh/script.c (grub_script_create_cmdline): remove cmdline
1183 argument. All callers updated
1185 2009-06-04 Robert Millan <rmh.grub@aybabtu.com>
1187 Prevent GRUB from probing floppies during boot.
1189 * conf/common.rmk (search_mod_CFLAGS): Use `-Werror -Wall'.
1190 * commands/search.c (options): Add --no-floppy.
1191 (search_fs, search_file, grub_cmd_search): Support --no-floppy.
1192 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Use
1193 --no-floppy when searching for UUIDs.
1195 2009-06-04 Robert Millan <rmh.grub@aybabtu.com>
1197 Simplify the code duplication in commands/search.c.
1199 * commands/search.c (search_label, search_fs_uuid): Merge into ...
1200 (search_fs): ... this. Update all users.
1202 2009-06-03 Felix Zielcke <fzielcke@z-51.de>
1204 * util/grub-mkconfig.in (update_grub_dir): Rename to grub_mkconfig_dir.
1206 2009-05-28 Pavel Roskin <proski@gnu.org>
1208 * Makefile.in: Don't use "cp -d", it doesn't work on FreeBSD.
1209 Remove the original symlink explicitly.
1211 * fs/hfs.c (grub_hfs_find_dir): Skip sequences of slashes, not
1212 just one slash. That's how grub_fshelp_find_file() does it.
1214 2009-05-26 Pavel Roskin <proski@gnu.org>
1216 * genmk.rb: Avoid shadowing variable `s', rename the outer `s'
1219 * util/getroot.c (grub_util_get_dev_abstraction): Mark os_dev as
1222 2009-05-25 Christian Franke <franke@computer.org>
1224 * disk/ata.c (grub_ata_wait_not_busy): Add debug output of status
1226 (grub_atapi_identify): Add wait after drive select.
1227 (grub_ata_identify): Do more strict status register check before
1228 calling grub_atapi_identify (). Suppress error message if status
1229 register is 0x00 after command failure. Add status register
1230 check after PIO read to avoid bogus identify due to stuck DRQ.
1231 Thanks to Pavel Roskin for testing.
1232 (grub_device_initialize): Remove unsafe status register check.
1233 Thanks to 'phcoder' for problem report and patch.
1234 Prevent sign extension in debug message.
1236 2009-05-23 Colin D Bennett <colin@gibibit.com>
1238 Cleaned up `include/grub/normal.h'. Grouped prototypes by
1239 definition file, and functions defined in `normal/menu.c' have had
1240 their prototypes moved to `include/grub/menu.h' for consistency.
1242 * include/grub/menu.h (grub_menu_execute_callback): Added; moved
1244 (grub_menu_get_entry): Likewise.
1245 (grub_menu_get_timeout): Likewise.
1246 (grub_menu_set_timeout): Likewise.
1247 (grub_menu_execute_entry): Likewise.
1248 (grub_menu_execute_with_fallback): Likewise.
1249 (grub_menu_entry_run): Likewise.
1251 * include/grub/normal.h: Re-ordered and grouped function
1252 prototypes by file that the function is defined in.
1253 (grub_menu_execute_callback): Removed; moved to menu.h.
1254 (grub_menu_get_entry): Likewise.
1255 (grub_menu_get_timeout): Likewise.
1256 (grub_menu_set_timeout): Likewise.
1257 (grub_menu_execute_entry): Likewise.
1258 (grub_menu_execute_with_fallback): Likewise.
1259 (grub_menu_entry_run): Likewise.
1260 (grub_menu_addentry): Renamed from this ...
1261 (grub_normal_add_menu_entry): ... to this.
1263 * normal/main.c (grub_menu_addentry): Renamed from this ...
1264 (grub_normal_add_menu_entry): ... to this.
1266 * script/sh/execute.c (grub_script_execute_menuentry): Update
1267 reference to renamed grub_menu_addentry function.
1269 2009-05-23 Felix Zielcke <fzielcke@z-51.de>
1271 * commands/i386/pc/drivemap.c (MODNAME): Remove. Update all users.
1273 2009-05-22 Pavel Roskin <proski@gnu.org>
1275 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Remove.
1276 * configure.ac: Don't call grub_I386_CHECK_REGPARM_BUG. Define
1277 NESTED_FUNC_ATTR using AH_BOTTOM. Use regparm(1) only when
1278 compiling for the i386 targets, but not for the utilities.
1280 * include/grub/i386/pc/kernel.h (grub_boot_drive): Change type
1282 (grub_root_drive): Likewise.
1283 * kern/i386/pc/startup.S (grub_boot_drive): Change size to byte,
1285 (grub_root_drive): Change size to byte.
1286 (grub_start_addr): Remove.
1287 (grub_end_addr): Likewise.
1288 (grub_apm_bios_info): Likewise.
1290 2009-05-21 Felix Zielcke <fzielcke@z-51.de>
1292 * normal/i386: Remove.
1293 * normal/powerpc: Likewise.
1294 * normal/sparc64: Likewise.
1295 * normal/x86_64: Likewise.
1297 2009-05-19 Vladimir Serbinenko <phcoder@gmail.com>
1299 * conf/x86_64-efi.rmk (linux_mod_ASFLAGS): Add missing variable
1300 * loader/i386/linux_trampoline.S: Fix indentation
1301 * loader/i386/xnu_helper.S: Likewise
1303 2009-05-18 Colin D Bennett <colin@gibibit.com>
1305 Display error messages when parsing a Lua statement fails.
1306 Previously, executing a syntactically invalid statement like
1307 ")foo" or "bar;" would silently fail.
1309 * script/lua/grub_main.c (handle_lua_error): New function.
1310 (grub_lua_parse_line): Improved reporting of Lua parser and
1313 2009-05-17 Vladimir Serbinenko <phcoder@gmail.com>
1315 Remove -Werror which causes build to fail on some systems
1317 * conf/i386-pc.rmk (xnu_mod_CFLAGS): Remove -Werror -Wall
1318 * conf/i386-efi.rmk (xnu_mod_CFLAGS): Likewise
1319 * conf/x86_64-efi.rmk (xnu_mod_CFLAGS): Likewise
1321 2009-05-17 Vladimir Serbinenko <phcoder@gmail.com>
1323 trampoline for linux on 64-bit platform
1325 * conf/x86_64-efi.rmk (linux_mod_SOURCES): added
1326 loader/i386/efi/linux_trampoline.S
1327 * include/grub/x86_64/efi/loader.h (grub_linux_real_boot): removed
1329 * kern/x86_64/efi/startup.S (grub_linux_real_boot): moved from
1331 * loader/i386/linux_trampoline.S: moved here
1332 * loader/i386/efi/linux.c (allocate_pages): reserve space for
1334 (jumpvector): removed
1335 (grub_linux_trampoline_start): new declaration
1336 (grub_linux_trampoline_end): likewise
1337 (grub_linux_boot): use trampoline when on 64-bit platform
1338 * loader/i386/linux.c: likewise
1340 2009-05-16 Pavel Roskin <proski@gnu.org>
1342 * script/lua/grub_lib.c (grub_lua_getenv): Make name and value
1343 const to avoid a warning.
1344 (grub_lua_setenv): Likewise.
1345 * script/lua/grub_main.c (grub_lua_parse_line): Use size_t for
1346 lmsg to fix a warning.
1348 2009-05-16 Felix Zielcke <fzielcke@z-51.de>
1350 * conf/i386.rmk (setjmp_mod_CFLAGS): Rename to ...
1351 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
1352 * conf/x86_64-efi.rmk (setjmp_mod_CFLAGS): Rename to ...
1353 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
1354 * conf/powerpc-ieee1275.rmk (setjmp_mod_CFLAGS): Rename to ...
1355 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
1356 * conf/sparc64-ieee1275.rmk (setjmp_mod_CFLAGS): Rename to ...
1357 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
1359 2009-05-16 Felix Zielcke <fzielcke@z-51.de>
1361 * util/grub-mkconfig.in: Export GRUB_TERMINAL_INPUT.
1363 2009-05-16 Bean <bean123ch@gmail.com>
1365 * conf/common.rmk (pkglib_MODULES): Add lua.mod.
1366 (lua_mod_SOURCES): New variable.
1367 (lua_mod_CFLAGS): Likewise.
1368 (lua_mod_LDFLAGS): Likewise.
1370 * conf/i386.rmk (pkglib_MODULES): Add setjmp.mod.
1371 (setjmp_mod_SOURCES): New variable.
1372 (setjmp_mod_CFLAGS): Likewise.
1373 (setjmp_LDFLAGS): Likewise.
1375 * conf/x86_64-efi.rmk (pkglib_MODULES): Add setjmp.mod.
1376 (setjmp_mod_SOURCES): New variable.
1377 (setjmp_mod_CFLAGS): Likewise.
1378 (setjmp_LDFLAGS): Likewise.
1380 * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add setjmp.mod.
1381 (setjmp_mod_SOURCES): New variable.
1382 (setjmp_mod_CFLAGS): Likewise.
1383 (setjmp_LDFLAGS): Likewise.
1385 * conf/sparc64-ieee1275.rmk (pkglib_MODULES): Add setjmp.mod.
1386 (setjmp_mod_SOURCES): New variable.
1387 (setjmp_mod_CFLAGS): Likewise.
1388 (setjmp_LDFLAGS): Likewise.
1390 * normal/i386/setjmp.S: Moved from here ...
1391 * lib/i386/setjmp.S: ... Moved here
1392 * normal/x86_64/setjmp.S: Moved from here ...
1393 * lib/x86_64/setjmp.S: ... Moved here
1394 * normal/powerpc/setjmp.S: Moved from here ...
1395 * lib/powerpc/setjmp.S: ... Moved here
1396 * normal/sparc64/setjmp.S: Moved from here ...
1397 * lib/sparc64/setjmp.S: ... Moved here
1399 * include/grub/i386/setjmp.h (grub_setjmp): Don't use attribute
1400 returns_twice in mingw.
1402 * script/lua/grub_lib.c: New file.
1403 * script/lua/grub_lib.h: Likewise.
1404 * script/lua/grub_lua.h: Likewise.
1405 * script/lua/grub_main.c: Likewise.
1406 * script/lua/lapi.c: Likewise.
1407 * script/lua/lapi.h: Likewise.
1408 * script/lua/lauxlib.c: Likewise.
1409 * script/lua/lauxlib.h: Likewise.
1410 * script/lua/lbaselib.c: Likewise.
1411 * script/lua/lcode.c: Likewise.
1412 * script/lua/lcode.h: Likewise.
1413 * script/lua/ldblib.c: Likewise.
1414 * script/lua/ldebug.c: Likewise.
1415 * script/lua/ldebug.h: Likewise.
1416 * script/lua/ldo.c: Likewise.
1417 * script/lua/ldo.h: Likewise.
1418 * script/lua/ldump.c: Likewise.
1419 * script/lua/lfunc.c: Likewise.
1420 * script/lua/lfunc.h: Likewise.
1421 * script/lua/lgc.c: Likewise.
1422 * script/lua/lgc.h: Likewise.
1423 * script/lua/linit.c: Likewise.
1424 * script/lua/liolib.c: Likewise.
1425 * script/lua/llex.c: Likewise.
1426 * script/lua/llex.h: Likewise.
1427 * script/lua/llimits.h: Likewise.
1428 * script/lua/lmathlib.c: Likewise.
1429 * script/lua/lmem.c: Likewise.
1430 * script/lua/lmem.h: Likewise.
1431 * script/lua/loadlib.c: Likewise.
1432 * script/lua/lobject.c: Likewise.
1433 * script/lua/lobject.h: Likewise.
1434 * script/lua/lopcodes.c: Likewise.
1435 * script/lua/lopcodes.h: Likewise.
1436 * script/lua/loslib.c: Likewise.
1437 * script/lua/lparser.c: Likewise.
1438 * script/lua/lparser.h: Likewise.
1439 * script/lua/lstate.c: Likewise.
1440 * script/lua/lstate.h: Likewise.
1441 * script/lua/lstring.c: Likewise.
1442 * script/lua/lstring.h: Likewise.
1443 * script/lua/lstrlib.c: Likewise.
1444 * script/lua/ltable.c: Likewise.
1445 * script/lua/ltable.h: Likewise.
1446 * script/lua/ltablib.c: Likewise.
1447 * script/lua/ltm.c: Likewise.
1448 * script/lua/ltm.h: Likewise.
1449 * script/lua/lua.h: Likewise.
1450 * script/lua/luaconf.h: Likewise.
1451 * script/lua/lualib.h: Likewise.
1452 * script/lua/lundump.c: Likewise.
1453 * script/lua/lundump.h: Likewise.
1454 * script/lua/lvm.c: Likewise.
1455 * script/lua/lvm.h: Likewise.
1456 * script/lua/lzio.c: Likewise.
1457 * script/lua/lzio.h: Likewise.
1459 2009-05-16 Bean <bean123ch@gmail.com>
1461 * include/grub/kernel.h (grub_module_header_types): Add type
1464 * kern/main.c (grub_load_config): New function.
1465 (grub_main): Call grub_load_config to read boot config.
1467 * grub-mkimage (generate_image): New parameter config_path.
1468 (options): New option --config.
1469 (main): Parse --config option, and pass it to generate_image.
1471 2009-05-14 Christian Franke <franke@computer.org>
1473 * commands/i386/pc/drivemap_int13h.S: Add missing EXT_C for symbols.
1474 This fixes build on Cygwin.
1476 2009-05-14 Pavel Roskin <proski@gnu.org>
1478 * commands/i386/pc/drivemap_int13h.S: Eliminate unconditional
1479 jump. This saves two bytes, so the typical case of 2 swapped
1480 drives would fit 32 bytes.
1482 2009-05-13 Pavel Roskin <proski@gnu.org>
1484 * loader/i386/multiboot.c (grub_multiboot): Cast mmap_addr to
1485 grub_uint32_t to avoid a warning.
1487 * loader/i386/linux.c (allocate_pages): When assigning
1488 real_mode_mem, cast through grub_size_t to fix a warning. The
1489 code already makes sure that the value would fit a pointer.
1490 (grub_linux_setup_video): Cast render_target->data to
1491 grub_size_t to fix a warning.
1493 2009-05-13 Javier MartÃn <lordhabbit@gmail.com>
1495 * commands/i386/pc/drivemap.c: New file - implement drivemap
1497 * commands/i386/pc/drivemap_int13h.S: New file - int13 handler.
1498 * conf/i386-pc.rmk: Add drivemap.c and drivemap_int13h.S.
1500 2009-05-13 Pavel Roskin <proski@gnu.org>
1502 * util/i386/pc/grub-setup.c (setup): Remove unused variable
1503 embedding_area_exists.
1505 2009-05-13 Robert Millan <rmh.grub@aybabtu.com>
1507 * util/i386/pc/grub-setup.c (setup): Restructure code flow to make
1508 it easier to understand / work with.
1509 Improve warning messages for cases where there's no embedding area,
1510 or when it is too small (or core.img too large).
1512 2009-05-13 Pavel Roskin <proski@gnu.org>
1514 * loader/i386/pc/multiboot2.c: Add necessary includes for
1515 grub_multiboot2_real_boot().
1517 * fs/iso9660.c (grub_iso9660_iterate_dir): The file mode in the
1518 PX record is always little-endian. We only need the lower 2
1521 * fs/cpio.c: Use the same name "struct head" for tar and cpio to
1522 facilitate code reuse.
1523 (grub_cpio_mount): Use "struct head", not a char buffer. This
1524 fixes a warning reported by gcc 4.4.
1526 * kernel/disk.c (grub_disk_read): Use void pointer for the
1528 (grub_disk_write): Use const void pointer for the buffer.
1529 Adjust all callers. Remove unnecessary casts.
1531 2009-05-10 Robert Millan <rmh.grub@aybabtu.com>
1533 * util/i386/pc/grub-install.in: Update copyright year.
1535 2009-05-09 Vladimir Serbinenko <phcoder@gmail.com>
1539 * commands/gptsync.c: new file
1540 * conf/common.rmk (pkglib_MODULES): add gptsync.mod
1541 (gptsync_mod_SOURCES): new variable
1542 (gptsync_mod_CFLAGS): likewise
1543 (gptsync_mod_LDFLAGS): likewise
1544 * include/grub/pc_partition.h (GRUB_PC_PARTITION_TYPE_NTFS):
1546 (GRUB_PC_PARTITION_TYPE_HFS): likewise
1547 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/gptsync.c
1548 * conf/i386-ieee1275.rmk: likewise
1549 * conf/i386-pc.rmk: likewise
1550 * conf/powerpc-ieee1275.rmk: likewise
1552 2009-05-09 Vladimir Serbinenko <phcoder@gmail.com>
1556 * kern/dl.c (grub_dl_ref): omit when compiling grub-emu
1557 (grub_dl_ref): likewise
1559 2009-05-08 Robert Millan <rmh.grub@aybabtu.com>
1561 * util/i386/pc/grub-setup.c (setup): Factorize find_usable_region(),
1562 split in two functions (one for msdos and one for gpt).
1564 2009-05-08 Pavel Roskin <proski@gnu.org>
1566 * disk/raid.c (grub_raid_block_xor): Make buf2 constant, it's
1569 * disk/raid6_recover.c (grub_raid6_recover): Fix warnings about
1570 uninitialized err[0] and err[1]. Rename them to bad1 and bad2.
1571 Initialize them with -1. Add sanity check for bad1. Eliminate
1574 2009-05-08 David S. Miller <davem@davemloft.net>
1576 * util/sparc64/ieee1275/grub-ofpathname.c (main): Set progname.
1578 2009-05-06 Robert Millan <rmh.grub@aybabtu.com>
1580 * util/i386/pc/grub-setup.c (setup): Fix check for embed region
1583 2009-05-05 Felix Zielcke <fzielcke@z-51.de>
1585 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
1586 `kern/rescue_reader.c', `kern/rescue_parser.c' and `normal/autofs.c'.
1588 2009-05-05 David S. Miller <davem@davemloft.net>
1590 * util/sparc64/ieee1275/grub-install.in: Fix sed arg quoting.
1592 2009-05-05 Pavel Roskin <proski@gnu.org>
1594 * include/grub/dl.h [GRUB_UTIL]: Provide inline implementations
1595 of grub_dl_ref() and grub_dl_unref().
1596 * commands/parttool.c: Remove preprocessor conditionals around
1597 grub_dl_ref() and grub_dl_unref().
1598 * fs/affs.c: Likewise.
1599 * fs/afs.c: Likewise.
1600 * fs/cpio.c: Likewise.
1601 * fs/ext2.c: Likewise.
1602 * fs/fat.c: Likewise.
1603 * fs/hfs.c: Likewise.
1604 * fs/hfsplus.c: Likewise.
1605 * fs/iso9660.c: Likewise.
1606 * fs/jfs.c: Likewise.
1607 * fs/minix.c: Likewise.
1608 * fs/ntfs.c: Likewise.
1609 * fs/reiserfs.c: Likewise.
1610 * fs/sfs.c: Likewise.
1611 * fs/udf.c: Likewise.
1612 * fs/ufs.c: Likewise.
1613 * fs/xfs.c: Likewise.
1614 * include/grub/dl.h: Likewise.
1615 * loader/xnu.c: Likewise.
1617 2009-05-04 Pavel Roskin <proski@gnu.org>
1619 * commands/acpi.c: Remove unused variable my_mod.
1620 * partmap/amiga.c: Likewise.
1621 * partmap/apple.c: Likewise.
1622 * partmap/gpt.c: Likewise.
1623 * partmap/pc.c: Likewise.
1624 * partmap/sun.c: Likewise.
1625 * term/gfxterm.c: Likewise.
1626 * term/i386/pc/vesafb.c: Likewise.
1627 * term/i386/pc/vga.c: Likewise.
1629 2009-05-04 David S. Miller <davem@davemloft.net>
1631 * kern/ieee1275/openfw.c (grub_children_iterate): Fix string
1632 pointer args to grub_ieee1275_get_property().
1634 * conf/sparc64-ieee1275.rmk: Fix build due to missing '\'.
1636 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Bypass cdrom
1637 devices, and do not traverse down under controller nodes.
1639 * disk/ieee1275/ofdisk.c (compute_dev_path): New.
1640 (grub_ofdisk_open): Use it to un-escape "," characters.
1641 * kern/disk.c (find_part_sep): New.
1642 (grub_disk_open): Use it to find the first non-escaped ','
1643 character in the disk name.
1644 * util/ieee1275/devicemap.c (escape_of_path): New.
1645 (grub_util_emit_devicemap_entry): Use it.
1646 * util/sparc64/ieee1275/grub-install.in: Update script to
1647 strip partition specifiers properly by not triggering on
1648 '\' escaped ',' characters.
1650 2009-05-04 Robert Millan <rmh.grub@aybabtu.com>
1652 * include/grub/i386/linux.h (GRUB_LINUX_VID_MODE_VESA_START): Set
1654 * loader/i386/linux.c (vga_modes, linux_vesafb_res): Add a few
1656 (linux_vesafb_modes): Add a lot of additional modes to the list (based
1657 on documentation from Wikipedia).
1659 2009-05-04 Pavel Roskin <proski@gnu.org>
1661 * disk/ata.c: Spelling fixes.
1662 * disk/raid.c: Likewise.
1663 * disk/usbms.c: Likewise.
1664 * disk/dmraid_nvidia.c: Likewise.
1665 * kern/ieee1275/openfw.c: Likewise.
1666 * kern/ieee1275/init.c: Likewise.
1667 * kern/ieee1275/cmain.c: Likewise.
1668 * boot/i386/pc/cdboot.S: Likewise.
1669 * video/readers/png.c: Likewise.
1670 * video/i386/pc/vbe.c: Likewise.
1671 * fs/udf.c: Likewise.
1672 * fs/hfs.c: Likewise.
1673 * fs/reiserfs.c: Likewise.
1674 * efiemu/runtime/efiemu.c: Likewise.
1675 * efiemu/main.c: Likewise.
1676 * efiemu/mm.c: Likewise.
1677 * include/grub/elf.h: Likewise.
1678 * include/grub/xnu.h: Likewise.
1679 * include/grub/usbdesc.h: Likewise.
1680 * include/grub/usb.h: Likewise.
1681 * include/grub/script_sh.h: Likewise.
1682 * include/grub/lib/LzmaEnc.h: Likewise.
1683 * include/grub/efiemu/efiemu.h: Likewise.
1684 * include/grub/command.h: Likewise.
1685 * normal/menu.c: Likewise.
1686 * normal/main.c: Likewise.
1687 * normal/datetime.c: Likewise.
1688 * bus/usb/uhci.c: Likewise.
1689 * mmap/i386/uppermem.c: Likewise.
1690 * mmap/mmap.c: Likewise.
1691 * commands/acpi.c: Likewise.
1692 * commands/test.c: Likewise.
1693 * partmap/apple.c: Likewise.
1694 * font/font.c: Likewise.
1695 * loader/sparc64/ieee1275/linux.c: Likewise.
1696 * loader/macho.c: Likewise.
1697 * loader/i386/bsd_trampoline.S: Likewise.
1698 * loader/i386/bsd.c: Likewise.
1699 * loader/xnu.c: Likewise.
1700 * term/i386/pc/vesafb.c: Likewise.
1701 * term/usb_keyboard.c: Likewise.
1702 * util/resolve.c: Likewise.
1703 * util/getroot.c: Likewise.
1705 2009-05-04 Felix Zielcke <fzielcke@z-51.de>
1707 * conf/i386-pc.rmk (libpkg_DATA): Rename to pkglib_DATA.
1709 2009-05-04 Robert Millan <rmh.grub@aybabtu.com>
1711 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS] (grub_cmd_linux): Fix
1714 2009-05-04 Robert Millan <rmh.grub@aybabtu.com>
1716 * loader/i386/linux.c (grub_cmd_linux): Make "vga=" compatibility
1717 parameter only available on BIOS.
1719 2009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
1721 Removed wrong semicolon in declaration
1723 * grub/misc.h (grub_dprintf): remove semicolon
1725 2009-05-04 Robert Millan <rmh.grub@aybabtu.com>
1727 * loader/i386/linux.c (GRUB_ASSUME_LINUX_HAS_FB_SUPPORT): New macro.
1728 (grub_linux_boot): Don't check for `linux_vesafb_modes' bounds (this
1729 is done by grub_cmd_linux() now).
1730 [! GRUB_ASSUME_LINUX_HAS_FB_SUPPORT]: If "vga=" parameter wasn't set,
1731 restore video to text mode.
1732 (grub_cmd_linux): Default `vid_mode' initialization to 0, which
1733 indicates lack of "vga=" parameter. "vga=0" is mapped to
1734 `GRUB_LINUX_VID_MODE_NORMAL'.
1736 2009-05-04 Felix Zielcke <fzielcke@z-51.de>
1738 * conf/i386-efi.rmk (grub_emu_SOURCES): Remove `normal/execute.c',
1739 `normal/lexer.c', `kern/rescue.c', `normal/function.c', `normal/misc.c'
1740 and `normal/script.c'. Add `kern/rescue_reader.c',
1741 `kern/rescue_parser.c', `script/sh/main.c', `script/sh/execute.c',
1742 `script/sh/function.c', `script/sh/lexer.c', `script/sh/script.c' and
1743 `grub_script.tab.c'.
1745 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1746 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
1747 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1748 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
1749 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1751 * Makefile.in: Remove duplicated 2008 in Copyright line.
1753 2009-05-04 Robert Millan <rmh.grub@aybabtu.com>
1755 * util/misc.c (grub_util_warn): New function. Emits a warning
1757 * include/grub/util/misc.h (grub_util_warn): New declaration.
1759 * util/i386/pc/grub-install.in: Understand --force and pass it down
1762 * util/i386/pc/grub-setup.c (main): Understand --force and pass it
1764 (setup): Improve error messages and add warnings when requested to
1765 install in odd layouts. Refuse to install using blocklists unless
1768 2009-05-04 martin f. krafft <madduck@madduck.net>
1770 * disk/raid.c (grub_raid_scan_device): Improve debug message.
1772 2009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
1774 Updated copyright year
1776 * fs/hfsplus.c: updated copyright year
1778 2009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
1782 * fs/hfsplus.c (grub_hfsplus_volheader): added num_serial field
1783 in the space previously used by unused3
1784 (grub_hfsplus_uuid): new function
1785 (grub_hfsplus_fs): added uuid field
1787 2009-05-03 Pavel Roskin <proski@gnu.org>
1789 * disk/ata.c: Don't cast mod to void in GRUB_MOD_INIT to
1790 suppress warnings. It's no longer needed.
1791 * disk/host.c: Likewise.
1792 * disk/ata_pthru.c: Likewise.
1793 * disk/loopback.c: Likewise.
1794 * hook/datehook.c: Likewise.
1795 * parttool/pcpart.c: Likewise.
1796 * fs/i386/pc/pxe.c: Likewise.
1797 * fs/ntfscomp.c: Likewise.
1798 * efiemu/main.c: Likewise.
1799 * mmap/mmap.c: Likewise.
1800 * commands/crc.c: Likewise.
1801 * commands/hexdump.c: Likewise.
1802 * commands/hdparm.c: Likewise.
1803 * commands/acpi.c: Likewise.
1804 * commands/echo.c: Likewise.
1805 * commands/minicmd.c: Likewise.
1806 * commands/blocklist.c: Likewise.
1807 * commands/memrw.c: Likewise.
1808 * commands/loadenv.c: Likewise.
1809 * commands/usbtest.c: Likewise.
1810 * commands/lsmmap.c: Likewise.
1811 * commands/boot.c: Likewise.
1812 * commands/parttool.c: Likewise.
1813 * commands/configfile.c: Likewise.
1814 * commands/search.c: Likewise.
1815 * commands/ieee1275/suspend.c: Likewise.
1816 * commands/cat.c: Likewise.
1817 * commands/i386/pc/pxecmd.c: Likewise.
1818 * commands/i386/pc/play.c: Likewise.
1819 * commands/i386/pc/halt.c: Likewise.
1820 * commands/i386/pc/vbeinfo.c: Likewise.
1821 * commands/i386/pc/vbetest.c: Likewise.
1822 * commands/lspci.c: Likewise.
1823 * commands/date.c: Likewise.
1824 * commands/handler.c: Likewise.
1825 * commands/ls.c: Likewise.
1826 * commands/test.c: Likewise.
1827 * commands/cmp.c: Likewise.
1828 * commands/efi/loadbios.c: Likewise.
1829 * commands/efi/fixvideo.c: Likewise.
1830 * commands/halt.c: Likewise.
1831 * commands/help.c: Likewise.
1832 * commands/reboot.c: Likewise.
1833 * hello/hello.c: Likewise.
1834 * script/sh/main.c: Likewise.
1835 * loader/xnu.c: Likewise.
1836 * term/terminfo.c: Likewise.
1837 * term/i386/pc/serial.c: Likewise.
1838 * term/usb_keyboard.c: Likewise.
1840 2009-05-03 David S. Miller <davem@davemloft.net>
1842 * normal/menu.c: Include grub/parser.h
1844 2009-05-03 Pavel Roskin <proski@gnu.org>
1846 * mmap/efi/mmap.c (grub_mmap_malign_and_register): Return void*,
1848 * mmap/i386/mmap.c (grub_mmap_malign_and_register): Likewise.
1849 Suggested by Javier MartÃn <lordhabbit@gmail.com>
1851 * util/i386/pc/grub-mkrescue.in: Allow for the case when
1852 efiemu??.o doesn't exist.
1853 * util/i386/pc/grub-install.in: Likewise. Use "cp -f" for
1856 2009-05-03 Bean <bean123ch@gmail.com> Vladimir Serbinenko <phcoder@gmail.com>
1858 FreeBSD 64-bit support
1860 * conf/i386-pc.rmk (bsd_mod_SOURCES): add loader/i386/bsd_helper.S
1861 and loader/i386/bsd_trampoline.S
1862 (bsd_mod_ASFLAGS): new variable
1863 * include/grub/i386/bsd.h (FREEBSD_MODINFOMD_SMAP): new definition
1864 (FREEBSD_MODTYPE_KERNEL64): likewise
1865 (grub_bsd64_trampoline_start): likewise
1866 (grub_bsd64_trampoline_end): likewise
1867 (grub_bsd64_trampoline_selfjump): likewise
1868 (grub_bsd64_trampoline_gdt): likewise
1869 * include/grub/i386/loader.h (grub_unix_real_boot): moved from here ...
1870 * include/grub/i386/bsd.h (grub_unix_real_boot): ... moved here
1871 * kern/i386/loader.S (grub_unix_real_boot): moved from here ...
1872 * loader/i386/bsd_helper.S (grub_unix_real_boot): moved here
1873 * include/grub/gpt_partition.h (grub_gpt_partentry): Corrected the type
1875 * loader/i386/bsd_pagetable.c: new file
1876 * loader/i386/bsd_trampoline.S: likewise
1877 * loader/i386/bsd.c (ALIGN_QWORD): new macro
1878 (ALIGN_VAR): likewise
1879 (entry_hi): new variable
1880 (kern_end_mdofs): likewise
1881 (is_64bit): likewise
1882 (grub_freebsd_add_meta): use ALIGN_VAR
1883 (grub_e820_mmap): new declaration
1884 (grub_freebsd_add_mmap): new function
1885 (grub_freebsd_add_meta_module): support 64 bit kernels
1886 (grub_freebsd_list_modules): use ALIGN_VAR
1887 (gdt_descriptor): new declaration
1888 (grub_freebsd_boot): support 64 bit kernels
1889 (grub_bsd_elf64_hook): new function
1890 (grub_bsd_load_elf): support elf64
1892 2009-05-03 Bean <bean123ch@gmail.com>
1894 * script/sh/execute.c (grub_script_execute_cmdif): Reset grub_errno
1895 after we get the result of if statement.
1897 2009-05-03 Bean <bean123ch@gmail.com>
1899 * Makefile.in (enable_efiemu): New variable.
1901 * conf/i386-pc.rmk: Only compile efiemu runtimes when enable_efiemu is
1903 (efiemu32.o): Use macro $< for source file, add $(srcdir) to include
1905 (efi64_c.o): Use macro $< for source file, add $(srcdir) to include
1906 path, add -mno-red-zone option.
1907 (efiemu64_s.o): Likewise.
1908 (efiemu64.o): Use macro $^ for source file.
1910 * configure.ac (--enable-efiemu): New option.
1912 2009-05-03 Vladimir Serbinenko <phcoder@gmail.com>
1916 * conf/i386-efi.rmk (kernel_mod_HEADERS): added i386/pit.h
1917 (pkglib_MODULES): add xnu.mod
1918 (xnu_mod_SOURCES): new variable
1919 (xnu_mod_CFLAGS): likewise
1920 (xnu_mod_LDFLAGS): likewise
1921 (xnu_mod_ASFLAGS): likewise
1922 * conf/i386-pc.rmk: likewise
1923 * conf/x86_64-efi.rmk: likewise
1924 * include/grub/efi/efi.h (grub_efi_finish_boot_services):
1926 * include/grub/i386/macho.h: new file
1927 * include/grub/i386/xnu.h: likewise
1928 * include/grub/macho.h: likewise
1929 * include/grub/machoload.h: likewise
1930 * include/grub/x86_64/macho.h: likewise
1931 * include/grub/x86_64/xnu.h: likewise
1932 * include/grub/xnu.h: likewise
1933 * kern/efi/efi.c (grub_efi_finish_boot_services): new function
1934 * kern/efi/mm.c (MAX_HEAP_SIZE): increase
1935 * loader/i386/efi/xnu.c: new file
1936 * loader/i386/pc/xnu.c: likewise
1937 * loader/i386/xnu.c: likewise
1938 * loader/i386/xnu_helper.S: likewise
1939 * loader/macho.c: likewise
1940 * loader/xnu.c: likewise
1941 * loader/xnu_resume.c: likewise
1942 * util/grub-dumpdevtree: likewise
1943 * include/grub/i386/pit.h: include grub/err.h
1944 (grub_pit_wait): export
1945 * util/grub.d/30_os-prober.in: support Darwin/Mac OS X
1947 2009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
1951 * conf/i386-pc.rmk: new modules efiemu, efiemu_acpi, efiemu_pnvram,
1952 _linux_efi, linux_efi.
1953 new files in grub-emu
1954 new targets efiemu32.o and efiemu64.o
1955 * loader/linux_normal_efiemu.c: likewise
1956 * loader/i386/efi/linux.c: added preliminary efiemu support
1957 * util/i386/pc/grub-install.in: add efiemu??.o to the list of
1959 * include/grub/autoefi.h: new file
1960 * include/grub/i386/efiemu.h: likewise
1961 * include/grub/i386/pc/efiemu.h: likewise
1962 * include/grub/efi/api.h: add LL suffix when necessary
1963 new definitions relating to tables
1964 * include/grub/efiemu/efiemu.h: new file
1965 * include/grub/efiemu/runtime.h: likewise
1966 * efiemu/prepare.c: likewise
1967 * efiemu/loadcore_common.c: likewise
1968 * efiemu/loadcore64.c: likewise
1969 * efiemu/runtime/efiemu.sh: likewise
1970 * efiemu/runtime/efiemu.S: likewise
1971 * efiemu/runtime/efiemu.c: likewise
1972 * efiemu/runtime/config.h: likewise
1973 * efiemu/prepare32.c: likewise
1974 * efiemu/main.c: likewise
1975 * efiemu/modules/pnvram.c: likewise
1976 * efiemu/modules/i386: likewise
1977 * efiemu/modules/i386/pc: likewise
1978 * efiemu/modules/acpi.c: likewise
1979 * efiemu/i386/pc/cfgtables.c: likewise
1980 * efiemu/i386/loadcore64.c: likewise
1981 * efiemu/i386/loadcore32.c: likewise
1982 * efiemu/prepare64.c: likewise
1983 * efiemu/loadcore.c: likewise
1984 * efiemu/symbols.c: likewise
1985 * efiemu/mm.c: likewise
1986 * efiemu/loadcore32.c: likewise
1988 2009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
1992 * commands/acpi.c: new file
1993 * commands/i386/pc/acpi.c: likewise
1994 * commands/efi/acpi.c: likewise
1995 * include/grub/acpi.h: likewise
1996 * conf/i386-pc.rmk (pkglib_MODULES): added acpi.mod
1997 (acpi_mod_SOURCES): new variable
1998 (acpi_mod_CFLAGS): likewise
1999 (acpi_mod_LDFLAGS): likewise
2000 * conf/i386-efi.rmk: likewise
2001 * conf/x86_64-efi.rmk: likewise
2003 2009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
2005 Missing part from mmap patch
2007 * mmap/efi/mmap.c (grub_machine_mmap_unregister): renamed to
2008 (grub_mmap_unregister)
2009 (grub_mmap_free_and_unregister): use grub_mmap_register
2011 2009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
2015 * loader/i386/efi/linux.c (grub_linux_boot): use grub_mmap_iterate
2016 * loader/i386/linux.c (find_mmap_size): likewise
2017 (allocate_pages): likewise
2018 * loader/i386/multiboot.c (grub_get_multiboot_mmap_len): likewise
2019 (grub_fill_multiboot_mmap): likewise
2020 (grub_multiboot): use grub_mmap_get_lower and grub_mmap_get_upper
2021 * loader/i386/pc/linux.c (grub_cmd_linux): use grub_mmap_get_lower
2022 * include/grub/i386/bsd.h (OPENBSD_MMAP_AVAILABLE): new definition
2023 (OPENBSD_MMAP_RESERVED): likewise
2024 * include/grub/i386/pc/memory.h: include grub/memory.h
2025 (grub_lower_mem): removed
2026 (grub_upper_mem): likewise
2027 (GRUB_MACHINE_MEMORY_ACPI): new definition
2028 (GRUB_MACHINE_MEMORY_NVS): likewise
2029 (GRUB_MACHINE_MEMORY_MAX_TYPE): likewise
2030 (GRUB_MACHINE_MEMORY_HOLE): likewise
2031 (grub_machine_mmap_register): likewise
2032 (grub_machine_mmap_unregister): likewise
2033 (grub_machine_get_upper): likewise
2034 (grub_machine_get_lower): likewise
2035 (grub_machine_get_post64): likewise
2036 * include/grub/i386/efi/memory.h: new file
2037 * include/grub/x86_64/efi/memory.h: likewise
2038 * include/grub/efi/memory.h: likewise
2039 * conf/i386-pc.rmk (pkglib_MODULES): added mmap.mod
2040 (mmap_mod_SOURCES): new variable
2041 (mmap_mod_LDFLAGS): likewise
2042 (mmap_mod_ASFLAGS): likewise
2043 * conf/i386-coreboot.rmk: likewise
2044 * conf/i386-ieee1275.rmk: likewise
2045 * conf/i386-efi.rmk: likewise
2046 * conf/x86_64-efi.rmk: likewise
2047 * include/grub/types.h (UINT_TO_PTR): new macro
2048 (PTR_TO_UINT32): likewise
2049 (PTR_TO_UINT64): likewise
2050 * include/grub/memory.h: new file
2051 * mmap/i386/pc/mmap.c: likewise
2052 * mmap/i386/pc/mmap_helper.S: likewise
2053 * mmap/i386/uppermem.c: likewise
2054 * mmap/mmap.c: likewise
2055 * mmap/efi/mmap.c: likewise
2056 * kern/i386/coreboot/init.c (grub_machine_init): don't use
2058 * kern/i386/pc/init.c (grub_lower_mem): removed variable
2059 (grub_upper_mem): likewise
2060 (grub_machine_init): don't use grub_upper_mem,
2061 make grub_lower_mem local
2062 * loader/i386/bsd.c (grub_openbsd_boot): use grub_mmap_get_lower,
2063 grub_mmap_iterate and grub_mmap_get_upper
2064 (grub_netbsd_boot): use grub_mmap_get_lower and grub_mmap_get_upper
2066 2009-05-02 Bean <bean123ch@gmail.com>
2068 * conf/common.rmk (grub_script.tab.c): Change normal/parser.y to
2070 (pkglib_MODULES): Add normal.mod and sh.mod.
2071 (normal_SOURCES): New variable.
2072 (normal_mod_CFLAGS): Likewise.
2073 (normal_mod_LDFLAGS): Likewise.
2074 (sh_mod_SOURCES): Likewise.
2075 (sh_mod_CFLAGS): Likewise.
2076 (sh_mod_LDFLAGS): Likewise.
2078 * conf/i386-pc.rmk (normal/lexer.c_DEPENDENCIES): Changed to
2079 script/sh/lexer.c_DEPENDENCIES.
2080 (kernel_img_SOURCES): Remove kern/rescue.c, and kern/reader.c,
2081 kern/rescue_reader.c and kern/rescue_parser.c.
2082 (kernel_img_HEADERS): Remove rescue.h, add reader.h.
2083 (grub_emu_SOURCES): Change source files.
2084 (pkglib_MODULES): Remove normal.mod.
2085 (normal_SOURCES): Removed.
2086 (normal_mod_CFLAGS): Likewise.
2087 (normal_mod_LDFLAGS): Likewise.
2088 * conf/i386-coreboot.rmk: Likewise.
2089 * conf/i386-efi.rmk: Likewise.
2090 * conf/i386-ieee1276.rmk: Likewise.
2091 * conf/powerpc-ieee1275.rmk: Likewise.
2092 * conf/sparc64-ieee1275.rmk: Likewise.
2093 * conf/x86_64-efi.rmk: Likewise.
2095 * include/grub/command.h (grub_command_execute): New inline function.
2097 * include/grub/menu.h (grub_menu_entry): Removed commands field.
2099 * include/grub/normal.h: Remove <grub/setjmp.h>.
2100 (grub_fs_module_list): Moved to normal/autofs.c.
2101 (grub_exit_env): Removed.
2102 (grub_command_execute): Likewise.
2103 (grub_normal_menu_addentry): Renamed to grub_menu_addentry, removed
2105 (read_command_list): New function declaration.
2106 (read_fs_list): Likewise.
2108 * include/parser.h: Include <grub/reader.h>.
2109 (grub_parser_split_cmdline): Change type of getline parameter.
2110 (grub_parser): New structure.
2111 (grub_parser_class): New variable.
2112 (grub_parser_execute): New function declaration.
2113 (grub_register_rescue_parser): Likewise.
2114 (grub_parser_register): New inline function.
2115 (grub_parser_unregister): Likewise.
2116 (grub_parser_get_current): Likewise.
2117 (grub_parser_set_current): Likewise.
2119 * include/grub/reader.h: New file.
2120 * kern/reader.c: Likewise.
2121 * kern/rescue_parser.c: Likewise.
2122 * kern/rescue_reader.c: Likewise.
2123 * normal/autofs.c: Likewise.
2124 * normal/dyncmd.c: Likewise.
2126 * include/grub/rescue.h: Removed.
2127 * normal/command.h: Likewise.
2129 * include/grub/script.h: Moved to ...
2130 * include/grub/script_sh.h: ... Moved here.
2131 * normal/execute.c: Moved to ...
2132 * script/sh/execute.c: ... Moved here.
2133 * normal/function.c: Moved to ...
2134 * script/sh/function.c: ... Moved here.
2135 * normal/lexer.c: Moved to ...
2136 * script/sh/lexer.c: ... Moved here.
2137 * normal/parser.y: Moved to ...
2138 * script/sh/parser.y: ... Moved here.
2139 * normal/script.c: Moved to ...
2140 * script/sh/script.c: ... Moved here.
2142 * normal/main.c: Remove <grub/rescue.h> and <grub/script.h>, include
2144 (grub_exit_env): Removed.
2145 (fs_module_list): Moved to normal/autofs.c.
2146 (grub_file_getline): Don't handle comment here.
2147 (free_menu): Skip removed field entry->commands.
2148 (grub_normal_menu_addentry): Removed as grub_menu_entry, removed
2150 (read_config_file): Removed nested parameter, change getline function.
2151 (grub_enter_normal_mode): Removed.
2152 (grub_dyncmd_dispatcher): Moved to normal/dyncmd.c.
2153 (read_command_list): Likewise.
2154 (autoload_fs_module): Moved to normal/autofs.c.
2155 (read_fs_list): Likewise.
2156 (reader_nested): New variable.
2157 (grub_normal_execute): Run parser.sh to switch to sh parser.
2158 (grub_cmd_rescue): Removed.
2159 (cmd_normal): Removed.
2160 (grub_cmd_normal): Unregister itself at the beginning. Don't register
2162 (grub_cmdline_run): New function.
2163 (grub_normal_reader_init): Likewise.
2164 (grub_normal_read_line): Likewise.
2165 (grub_env_write_pager): Likewise.
2166 (cmdline): New variable.
2167 (grub_normal_reader): Likewise.
2168 (GRUB_MOD_INIT): Register normal reader and set as current, register
2169 pager hook, register normal command with grub_register_command_prio,
2170 so that it won't show up in command.lst.
2171 (GRUB_MOD_FINI): Unregister normal reader, unhook pager, clear
2172 grub_fs_autoload_hook.
2174 * normal/menu.c: Remove <grub/script.h>, add <grub/command.h>.
2175 (grub_menu_execute_entry): Replace grub_script_execute with
2176 grub_parser_execute, change parameter to grub_command_execute.
2178 * normal/menu_text.c: Remove <grub/script.h>.
2180 * normal/menu_entry.c: Remove <grub/script.h>, add <grub/command.h>
2181 and <grub/parser.h>.
2182 (run): Change editor_getline to use new parser interface. Change
2183 parameter to grub_command_execute.
2185 * kern/main.c: Remove <grub/rescue.h>, include <grub/command.h>,
2186 <grub/reader.h> and <grub/parser.h>.
2187 (grub_load_normal_mode): Execute normal command.
2188 (grub_main): Call grub_register_core_commands,
2189 grub_register_rescue_parser and grub_register_rescue_reader, use
2190 grub_reader_loop to enter input loop.
2192 * kern/parser.c (grub_parser_split_cmdline): Change type of
2194 (grub_parser_class): New variable.
2195 (grub_parser_execute): New function.
2197 * loader/i386/multiboot.c: Remove <grub/rescue.h>.
2198 * loader/multiboot2.c: Likewise.
2199 * loader/sparc64/ieee1275/linux.c: Likewise.
2201 * util/grub-emu.c (read_command_list): New dummy function.
2203 2009-05-02 Robert Millan <rmh.grub@aybabtu.com>
2205 * util/deviceiter.c (grub_util_iterate_devices): Increase max drive
2206 count to 16 for CCISS and IDA.
2208 2009-05-02 Robert Millan <rmh.grub@aybabtu.com>
2210 * normal/menu_text.c (grub_wait_after_message): Print a newline
2211 after waiting for user input.
2213 * loader/i386/linux.c: Include `<grub/normal.h>'.
2214 (grub_cmd_linux): Improve the error message about `ask' mode, by
2215 waiting for user input so it's not missed (we can do this, since
2216 user requested interaction).
2218 2009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
2220 Added missing lst to grub-mkrescue
2222 * util/i386/pc/grub-mkrescue.in: added ${input_dir}/handler.lst
2223 and ${input_dir}/parttool.lst
2225 2009-04-30 David S. Miller <davem@davemloft.net>
2227 * util/hostdisk.c (device_is_wholedisk): New function.
2228 (grub_util_biosdisk_get_grub_dev): Shortcut when hdg.start is
2229 zero only if device_is_wholedisk() returns true.
2231 * util/hostdisk.c (convert_system_partition_to_system_disk):
2232 Handle virtual disk devices named /dev/vdiskX as found on sparc
2235 * kern/sparc64/ieee1275/init.c (grub_machine_set_prefix): If
2236 lettered partition specifier is found, convert to numbered.
2238 2009-04-29 David S. Miller <davem@davemloft.net>
2240 * include/grub/powerpc/ieee1275/memory.h: Include ieee1275.h.
2241 * include/grub/sparc64/ieee1275/memory.h: Likewise.
2243 * normal/command.c: Add missing newline at end of file.
2245 * commands/lsmmap.c (grub_cmd_lsmmap): Add casts to avoid printf
2247 * kern/ieee1275/openfw.c (grub_claimmap): Likewise.
2248 * disk/ieee1275/ofdisk.c (grub_ofdisk_open, grub_ofdisk_close,
2249 grub_ofdisk_read): Likewise, and deal similarly with the fact that
2250 ihandles have a 32-bit type but need to be stored in a "void *".
2252 2009-04-28 Pavel Roskin <proski@gnu.org>
2254 * disk/fs_uuid.c (grub_fs_uuid_open): Use parent->data for dev,
2255 not disk. Adjust all dependencies.
2256 (grub_fs_uuid_close): Use grub_device_close(), not
2259 * disk/fs_uuid.c (grub_fs_uuid_open): Allocate memory to copy
2260 parent's partition, don't copy it by reference, as it gets freed
2263 2009-04-27 Vladimir Serbinenko <phcoder@gmail.com>
2265 Preboot hooks support
2267 * commands/boot.c (struct grub_preboot_t): new declaration
2268 (preboots_head): new variable
2269 (preboots_tail): likewise
2270 (grub_loader_register_preboot_hook): new function
2271 (grub_loader_unregister_preboot_hook): likewise
2272 (grub_loader_set): launch preboot hooks
2273 * include/grub/loader.h (grub_loader_preboot_hook_prio_t): new type
2274 (grub_loader_register_preboot_hook): new declaration
2275 (grub_loader_unregister_preboot_hook): likewise
2277 2009-04-27 Vladimir Serbinenko <phcoder@gmail.com>
2281 * disk/scsi.c (grub_scsi_open): added missing cast when
2282 calling grub_dprintf
2284 2009-04-26 Vladimir Serbinenko <phcoder@gmail.com>
2286 Bug and warning fixes
2288 * include/grub/i386/pc/init.h (grub_stop_floppy): added missing
2290 * commands/test.c (test_parse): fixed bug with file tests and corrected
2291 declaration of find_file
2293 2009-04-26 Pavel Roskin <proski@gnu.org>
2295 * Makefile.in: Don't install empty manual pages if help2man is
2296 missing. Use help2man option for output, not shell redirection.
2298 2009-04-26 David S. Miller <davem@davemloft.net>
2300 * util/grub-mkdevicemap.c (make_device_map): Add missing
2301 NESTED_FUNC_ATTR to process_device().
2303 2009-04-25 Vladimir Serbinenko <phcoder@gmail.com>
2307 * commands/test.c: rewritten to use bash-like test
2309 2009-04-25 Vladimir Serbinenko <phcoder@gmail.com>
2311 Parttool autoloading and improvements
2313 * Makefile.in (pkglib_DATA): add parttool.lst
2314 (parttool.lst): new target
2315 * genmk.rb: generate parttool-*
2316 (CLEANFILES): add #{parttool}
2317 (PARTTOOLFILES): new variable
2318 * genparttoollist.sh: new file
2319 * parttool/pcpart.c (grub_pcpart_boot): more feedback
2320 (grub_pcpart_type): likewise
2321 * commands/parttool.c (helpmsg): new variable
2322 (grub_cmd_parttool): output help if not enough arguments are supplied
2324 (GRUB_MOD_INIT(parttool)): use helpmsg
2326 2009-04-24 David S. Miller <davem@davemloft.net>
2328 Avoiding opening same device multiple times in device iterator.
2330 * kern/device.c: (grub_device_iterate): Define struct part_ent,
2331 and use it to build a list of partitions in iterate_disk() and
2332 iterate_partition().
2334 * disk/fs_uuid.c (grub_fs_uuid_close): Call grub_disk_close()
2337 * disk/ieee1275/nand.c (grub_nand_iterate): Return
2338 grub_devalias_iterate() result instead of unconditional 0.
2339 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Likewise.
2340 Also, capture hook return value, either directly or via
2341 grub_children_iterate(), and propagate to caller.
2342 * include/grub/ieee1275/ieee1275.h (grub_devalias_iterate,
2343 grub_children_iterate): Return value is now 'int' instead of
2345 * kern/ieee1275/openfw.c (grub_children_iterate): Fix to behave
2346 like a proper iterator, stopping when hooks return non-zero.
2347 (grub_devalias_iterate): Likewise.
2349 2009-04-23 David S. Miller <davem@davemloft.net>
2351 * kern/sparc64/ieee1275/openfw.c: Unused, delete.
2353 2009-04-22 David S. Miller <davem@davemloft.net>
2355 * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): If size_cells
2356 is larger than address_cells, use that value for address_cells too.
2358 * include/grub/ieee1275/ieee1275.h (IEEE1275_MAX_PROP_LEN,
2359 IEEE1275_MAX_PATH_LEN): Define.
2360 * kern/ieee1275/openfw.c (grub_children_iterate): Dynamically
2361 allocate 'childtype', 'childpath', 'childname', and 'fullname'.
2362 (grub_devalias_iterate): Dynamically allocate 'aliasname' and
2363 'devtype'. Explicitly NULL terminate devalias expansion.
2365 * util/sparc64/ieee1275/misc.c: New file.
2366 * util/sparc64/ieee1275/grub-setup.c: New file.
2367 * util/sparc64/ieee1275/grub-ofpathname.c: New file.
2368 * util/sparc64/ieee1275/grub-mkimage.c: New file.
2369 * util/sparc64/ieee1275/grub-install.in: New file.
2370 * util/ieee1275/ofpath.c: New file.
2371 * util/ieee1275/devicemap.c: New file.
2372 * util/devicemap.c: New file.
2373 * util/deviceiter.c: New file.
2374 * kern/sparc64/ieee1275/init.c: New file.
2375 * include/grub/util/ofpath.h: New file.
2376 * include/grub/util/deviceiter.h: New file.
2377 * util/grub-mkdevicemap.c: Include deviceiter.h.
2378 Implement using grub_util_emit_devicemap_entry and
2379 grub_util_iterate_devices.
2380 * conf/i386-corebook.rmk: Build util/deviceiter.c and
2381 util/devicemap.c into grub-mkdevicemap
2382 * conf/i386-efi.rmk: Likewise.
2383 * conf/i386-ieee1275.rmk: Likewise.
2384 * conf/i386-pc.rmk: Likewise.
2385 * conf/powerpc-ieee1275.rmk: Likewise.
2386 * conf/sparc64-ieee1275.rmk: Add rules to build boot block
2387 images and installation utilities. Build kernel as image
2388 instead of as elf binary. Use common rules as much as possible.
2390 2009-04-19 Vladimir Serbinenko <phcoder@gmail.com>
2392 Correct GPT definition
2394 * include/grub/gpt_partition.h (grub_gpt_partentry): Corrected the type
2397 2009-04-19 Felix Zielcke <fzielcke@z-51.de>
2399 * INSTALL: Replace `autogen.sh' with `./autogen.sh'.
2401 2009-04-19 David S. Miller <davem@davemloft.net>
2403 * loader/sparc64/ieee1275/linux.c: Include grub/command.h
2404 (grub_rescue_cmd_linux): Rename to...
2405 (grub_cmd_linux): and fix prototype.
2406 (grub_rescue_cmd_initrd): Rename to...
2407 (grub_cmd_initrd): and fix prototype.
2408 (cmd_linux, cmd_initrd): New.
2409 (GRUB_MOD_INIT(linux)): Use grub_register_command().
2410 (GRUB_MOD_FINI(linux): Use grub_unregister_command().
2412 2009-04-17 Pavel Roskin <proski@gnu.org>
2414 * bus/usb/ohci.c (grub_ohci_transaction): Fix incorrect printf
2416 (grub_ohci_transfer): Likewise.
2418 * bus/usb/usbtrans.c (grub_usb_control_msg): Warning fix.
2420 * loader/multiboot_loader.c (grub_cmd_multiboot_loader): Fix
2421 return without a value. Fix inconsistent indentation.
2423 * fs/i386/pc/pxe.c (grub_pxefs_dir): Fix function prototype to
2424 match struct grub_fs.
2426 * disk/ata.c (grub_ata_pciinit): Use NESTED_FUNC_ATTR.
2427 * bus/usb/ohci.c (grub_ohci_pci_iter): Likewise.
2428 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
2429 * commands/lspci.c (grub_lspci_iter): Likewise.
2431 2009-04-16 Bean <bean123ch@gmail.com>
2433 * commands/efi/loadbios.c (grub_cmd_fakebios): Add missing return
2436 2009-04-15 Pavel Roskin <proski@gnu.org>
2438 * include/grub/types.h: Rename ULONG_MAX to GRUB_ULONG_MAX and
2439 LONG_MAX to GRUB_LONG_MAX. Introduce GRUB_LONG_MIN. Update all
2440 users of ULONG_MAX, LONG_MAX and LONG_MIN to use the new
2443 2009-04-15 Felix Zielcke <fzielcke@z-51.de>
2445 * disk/lvm.c (grub_lvm_scan_device): Add `LVM' to the error messages,
2446 that no multiple data or metadata areas are supported and `Unknown
2449 2009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
2451 Move loader out of the kernel
2453 * kern/loader.c: moved to ...
2454 * commands/boot.c: ... moved here
2455 * commands/minicmd.c (grub_mini_cmd_boot): moved to ...
2456 * commands/boot.c (grub_cmd_boot): moved here. All users updated
2457 * include/grub/kernel.h (grub_machine_fini): export
2458 * include/grub/loader.h (grub_loader_is_loaded): update declaration
2459 (grub_loader_set): likewise
2460 (grub_loader_unset): likewise
2461 (grub_loader_boot): likewise
2462 * conf/common.rmk: new module boot.mod
2463 (pkglib_MODULES): add boot.mod
2464 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): remove kern/loader.c
2465 (grub_emu_SOURCES): likewise
2466 * conf/i386-efi.rmk (kernel_elf_SOURCES): likewise
2467 (grub_emu_SOURCES): likewise
2468 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): likewise
2469 (grub_emu_SOURCES): likewise
2470 * conf/i386-pc.rmk (kernel_elf_SOURCES): likewise
2471 (grub_emu_SOURCES): likewise
2472 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): likewise
2473 (grub_emu_SOURCES): likewise
2474 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): likewise
2475 (grub_emu_SOURCES): likewise
2476 * conf/x86_64-efi.rmk (kernel_elf_SOURCES): likewise
2477 (grub_emu_SOURCES): likewise
2479 2009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
2481 use grub_lltoa instead of grub_itoa and grub_ltoa for all purposes
2483 * kern/misc.c (grub_itoa): Removed function
2484 (grub_ltoa): likewise
2485 (grub_vsprintf): use grub_lltoa
2487 2009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
2491 * conf/i386-pc.rmk (grub_emu_SOURCES): add normal/handler.c
2492 * conf/i386-coreboot.rmk: likewise
2493 * conf/i386-ieee1275.rmk: likewise
2494 * conf/powerpc-ieee1275.rmk: likewise
2496 2009-04-15 Felix Zielcke <fzielcke@z-51.de>
2498 * INSTALL: Add that `./autogen.sh' needs to be run before
2501 2009-04-14 Bean <bean123ch@gmail.com>
2503 * Makefile.in (pkglib_DATA): Add handler.lst.
2504 (handler.lst): New rule.
2506 * conf/i386-pc.rmk (normal_mod_SOURCES): Add normal/handler.c.
2507 * conf/i386-coreboot.rmk: Likewise.
2508 * conf/i386-ieee1275.rmk: Likewise.
2509 * conf/i386-efi.rmk: Likewise.
2510 * conf/x86_64-efi.rmk: Likewise.
2511 * conf/powerpc-ieee1275.rmk: Likewise.
2512 * conf/sparc64-ieee1275.rmk: Likewise.
2514 * genhandlerlist.sh: New file.
2516 * genmk.rb: Add rules to generate handler.lst.
2518 * include/grub/normal.h (grub_file_getline): New function definition.
2519 (read_handler_list): Likewise.
2520 (free_handler_list): Likewise.
2522 * include/grub/term.h (grub_term_register_input): Add name parameter
2523 for auto generation of handler.lst.
2524 (grub_term_register_output): Likewise.
2526 * normal/handler.c: New file.
2528 * normal/main.c (get_line): Renamed to grub_file_getline.
2529 (read_config_file): Use the newly renamed grub_file_getline.
2530 (read_command_list): Likewise.
2531 (read_fs_list): Likewise.
2532 (grub_normal_execute): Call read_handler_list to parse handler.lst.
2533 (GRUB_MOD_FINI): Call free_handler_list to free handler list.
2535 * term/efi/console.c (grub_console_init): Add name parameter for auto
2536 generation of handler.lst.
2537 * term/gfxterm.c: Likewise.
2538 * term/i386/pc/at_keyboard.c: Likewise.
2539 * term/i386/pc/console.c: Likewise.
2540 * term/i386/pc/serial.c: Likewise.
2541 * term/i386/pc/vesafb.c: Likewise.
2542 * term/i386/pc/vga.c: Likewise.
2543 * term/i386/pc/vga_text.c: Likewise.
2544 * term/ieee1275/ofconsole.c: Likewise.
2545 * term/usb_keyboard.c: Likewise.
2547 2009-04-14 Bean <bean123ch@gmail.com>
2549 * util/grub-pe2elf.c (write_symbol_table): Terminate short name symbol
2550 properly with null character.
2552 2009-04-14 Felix Zielcke <fzielcke@z-51.de>
2554 * configure: Remove.
2555 * config.h.in: Likewise.
2556 * stamp-h.in: Likewise.
2557 * DISTLIST: Likewise.
2558 * conf/common.mk: Likewise.
2559 * conf/i386-coreboot.mk: Likewise.
2560 * conf/i386-efi.mk: Likewise.
2561 * conf/i386-ieee1275.mk: Likewise.
2562 * conf/i386.mk: Likewise.
2563 * conf/i386-pc.mk: Likewise.
2564 * conf/powerpc-ieee1275.mk: Likewise.
2565 * conf/sparc64-ieee1275.mk: Likewise.
2566 * conf/x86_64-efi.mk: Likewise.
2568 * INSTALL: Remove the sentence that Ruby and autoconf are only required if you
2571 2009-04-14 John Stanley <jpsinthemix@verizon.net>
2572 David S. Miller <davem@davemloft.net>
2574 * util/hostdisk.c (make_device_name): Fix buffer length
2577 2009-04-14 Felix Zielcke <fzielcke@z-51.de>
2579 * util/hostdisk.c [__FreeBSD__ || __FreeBSD_kernel__]: Include
2580 <sys/param.h> and <sys/sysctl.h>.
2581 (open_device) [__FreeBSD__ || __FreeBSD_kernel_]: Use sysctlgetbyname()
2582 to add 0x10 to `kern.geom.debugflags' if it's not already set, before
2583 opening the device and reset them afterwards.
2585 2009-04-13 Pavel Roskin <proski@gnu.org>
2587 * conf/common.rmk (grub_fstest_SOURCES): Add normal/datetime.c.
2588 Reported by John Stanley <jpsinthemix@verizon.net>
2590 2009-04-13 Robert Millan <rmh@aybabtu.com>
2592 * util/grub.d/10_freebsd.in: Detect Debian GNU/kFreeBSD and use
2593 that name for menuentries when appropriate.
2595 2009-04-13 Felix Zielcke <fzielcke@z-51.de>
2597 * util/grub.d/10_freebsd.in: Add a missing `fi'.
2599 2009-04-13 Robert Millan <rmh@aybabtu.com>
2601 * loader/i386/linux.c (grub_cmd_linux): Don't pass `vga=ask' parameter
2602 to Linux, simply abort telling the user it's no longer supported.
2604 2009-04-13 Felix Zielcke <fzielcke@z-51.de>
2606 * util/grub.d/10_freebsd.in: Don't exit if /boot/devices.hints
2607 doesn't exist. Check also for /boot/kernel/kernel.gz. Print
2608 `freebsd_loadenv' only when devices.hints exist.
2610 2009-04-13 Pavel Roskin <proski@gnu.org>
2612 * term/usb_keyboard.c (grub_usb_keyboard_getkey): Warning fixes.
2614 2009-04-13 Felix Zielcke <fzielcke@z-51.de>
2616 * util/i386/pc/grub-install.in (install_drive): Remove the BSD
2618 (grub_drive): Likewise.
2620 2009-04-13 David S. Miller <davem@davemloft.net>
2622 * kern/sparc64/ieee1275/ieee1275.c: New file.
2623 * include/grub/sparc64/ieee1275/ieee1275.h (IEEE1275_MAP_WRITE,
2624 IEEE1275_MAP_READ, IEEE1275_MAP_EXEC, IEEE1275_MAP_LOCKED,
2625 IEEE1275_MAP_CACHED, IEEE1275_MAP_SE, IEEE1275_MAP_GLOBAL,
2626 IEEE1275_MAP_IE, IEEE1275_MAP_DEFAULT): Define.
2627 (grub_ieee1275_map_physical, grub_ieee1275_claim_vaddr,
2628 grub_ieee1275_alloc_physmem): Declare new exported functions.
2630 * include/grub/sparc64/ieee1275/loader.h: New file.
2631 * include/grub/sparc64/ieee1275/memory.h: Likewise.
2632 * include/grub/sparc64/kernel.h: Likewise.
2633 * loader/sparc64/ieee1275/linux.c: Likewise.
2635 * conf/common.rmk (grub_probe_SOURCES): Add Sun partition module.
2636 (grub_fstest_SOURCES): Likewise.
2638 * util/hostdisk.c (make_device_name): Do not make any assumptions
2639 about the length of drive names.
2641 * kern/dl.c (grub_dl_load_file): Close file immediately when
2642 we are done using it.
2644 2009-04-12 David S. Miller <davem@davemloft.net>
2646 * kern/misc.c (grub_ltoa): Fix cast when handling negative
2647 values. Noticed by Pavel Roskin.
2649 * configure.ac: Check for __bswapsi2 and__bswapdi2 using
2652 * genmk.rb: Add more flexible image type specification, also
2653 pass --strip-unneeded to objcopy.
2654 * conf/i386-pc.rmk: Use *_FORMAT.
2655 * conf/i386-pc.mk: Rebuilt.
2657 * disk/ieee1275/ofdisk.c (struct ofdisk_hash_ent): New struct.
2658 (OFDISK_HASH_SZ): Define.
2659 (ofdisk_hash): New hash table.
2660 (ofdisk_hash_fn, ofdisk_hash_find, ofdisk_hash_add): New functions.
2661 (grub_ofdisk_open): Use ofdisk_hash_ent address as disk->id
2662 instead of device phandle which is not unique.
2664 * kern/sparc64/ieee1275/init.c: Delete, replace with...
2665 * kern/sparc64/ieee1275/crt0.S: assembler implementation.
2666 * include/grub/sparc64/ieee1275/kernel.h: Declare grub_prefix[].
2667 (GRUB_MOD_ALIGN, GRUB_MOD_GAP, GRUB_KERNEL_MACHINE_TOTAL_MODULE_SIZE,
2668 GRUB_KERNEL_MACHINE_KERNEL_IMAGE_SIZE,
2669 GRUB_KERNEL_MACHINE_COMPRESSED_SIZE, GRUB_KERNEL_MACHINE_PREFIX,
2670 GRUB_KERNEL_MACHINE_DATA_END): Define.
2671 (grub_kernel_image_size, grub_total_module_size): Declare.
2673 2009-04-12 Pavel Roskin <proski@gnu.org>
2675 * configure.ac: Change the logic when we check for target tools.
2676 Do it when the target is specified and it's different from the
2677 specified value of the host.
2679 2009-04-11 Felix Zielcke <fzielcke@z-51.de>
2681 * util/hostdisk.c [__FreeBSD_kernel__]: Include sys/disk.h.
2682 (grub_util_biosdisk_open) [__FreeBSD_kernel__]: Add support for
2683 GNU/kFreeBSD. Check if a device is a character device. Use
2684 DIOCGMEDIASIZE to get the size.
2685 (convert_system_partition_to_system_disk) [__FreeBSD_kernel__]: Add
2686 support for GNU/kFreeBSD.
2687 (grub_util_biosdisk_get_grub_dev) [__FreeBSD_kernel__]: Check if OS_DEV
2688 is a character device instead of a block device. Add support for
2689 FreeBSD device names.
2691 * util/getroot.c (find_root_device) [__FreeBSD_kernel__]: Check if ENT
2692 is a character device instead of a block device.
2694 * util/grub-probe.c (probe) [__FreeBSD_kernel__]: Check if DEVICE_NAME
2695 is a character device instead of a block device.
2697 2009-04-11 Andrey Shuvikov <mr_hyro@yahoo.com>
2699 * util/hostdisk.c [__FreeBSD__]: Include sys/disk.h.
2700 (grub_util_biosdisk_open) [__FreeBSD__]: Add support for
2701 FreeBSD. Check if a device is a character device. Use
2702 DIOCGMEDIASIZE to get the size.
2703 (convert_system_partition_to_system_disk) [__FreeBSD__]: Add
2704 support for FreeBSD.
2705 (grub_util_biosdisk_get_grub_dev) [__FreeBSD__]: Check if OS_DEV
2706 is a character device instead of a block device. Add support for
2707 FreeBSD device names.
2709 * util/getroot.c (find_root_device) [__FreeBSD__]: Check if ENT is
2710 a character device instead of a block device.
2711 (grub_util_check_char_device): New function.
2713 * util/grub-probe.c (probe) [__FreeBSD__]: Check if DEVICE_NAME is
2714 a character device instead of a block device.
2716 * include/grub/util/getroot.h (grub_util_check_char_device): New
2719 2009-04-11 David S. Miller <davem@davemloft.net>
2721 * conf/sparc64-ieee1275.rmk (kernel_img_LDFLAGS): Link with
2723 * configure.ac: Check for __bswapsi2 and __bswapdi2 presence.
2724 * include/grub/sparc64/libgcc.h (__bswapsi2): Export libgcc
2725 function, if present.
2726 (__bswapdi2): Likewise.
2728 * include/grub/sparc64/ieee1275/boot.h: New file.
2729 * boot/sparc64/ieee1275/boot.S: Likewise.
2730 * boot/sparc64/ieee1275/diskboot.S: Likewise.
2732 * kern/misc.c (grub_ltoa): New function.
2733 (grub_vsprintf): Use it to format 'long' integers.
2735 2009-04-10 David S. Miller <davem@davemloft.net>
2737 * disk/ieee1275/nand.c (grub_nand_open): All ieee1275 call arg
2738 slots are of type grub_ieee1275_cell_t.
2739 (grub_nand_read): Likewise.
2740 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_INVALID,
2741 IEEE1275_IHANDLE_INVALID): Use grub_ieee1275_cell_t since these
2742 macros are used to compare values in arg/ret block of the call.
2743 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
2744 grub_ieee1275_next_property, grub_ieee1275_get_property_length,
2745 grub_ieee1275_instance_to_package, grub_ieee1275_package_to_path,
2746 grub_ieee1275_instance_to_path, grub_ieee1275_write,
2747 grub_ieee1275_read, grub_ieee1275_seek, grub_ieee1275_peer,
2748 grub_ieee1275_child, grub_ieee1275_parent, grub_ieee1275_open,
2749 grub_ieee1275_close, grub_ieee1275_set_property,
2750 grub_ieee1275_set_color): All ieee1275 call arg slots are of type
2751 grub_ieee1275_cell_t.
2752 * kern/ieee1275/openfw.c (grub_map): Likewise.
2753 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_ihandle_t,
2754 grub_ieee1275_phandle_t): Define as grub_unit32_t type.
2756 * kern/ieee1275/init.c (grub_machine_init): Make 'actual' grub_ssize_t.
2757 * kern/ieee1275/openfw.c (grub_children_iterate): Likewise.
2758 (grub_devalias_iterate): Likewise.
2760 2009-04-10 Vladimir Serbinenko <phcoder@gmail.com>
2764 * fs/ufs.c (INODE_NBLOCKS): new definition
2765 (struct grub_ufs_dirent): added fields for non-BSD dirents
2766 (grub_ufs_get_file_block): fixed double indirect handling
2767 (grub_ufs_lookup_symlink): use more robust way to determine whether
2769 (grub_ufs_find_file): support for non-BSD dirents
2770 (grub_ufs_dir): support for non-BSD dirents
2772 2009-04-10 Bean <bean123ch@gnail.com>
2774 * include/grub/efi/api.h (grub_efi_configuration_table): Add packed
2775 attribute, otherwise the size would be wrong for i386 platform.
2777 * include/grub/pci.h (grub_pci_read_word): New inline function.
2778 (grub_pci_read_byte): Likewise.
2779 (grub_pci_write): Likewise.
2780 (grub_pci_write_word): Likewise.
2781 (grub_pci_write_byte): Likewise.
2783 * include/grub/pci.h (grub_pci_iteratefunc_t): Add NESTED_FUNC_ATTR.
2785 * loader/i386/efi/linux.c (fake_bios_data): Moved to loadbios module.
2786 (find_framebuf): Scan pci to locate the frame buffer address.
2788 * commands/efi/fixvideo.c: New file.
2790 * commands/efi/loadbios.c: Likewise.
2792 * commands/memrw.c: Likewise.
2794 * util/grub-dumpbios.in: Likewise.
2796 * conf/common.rmk (grub-dumpbios): New utility.
2797 (pkglib_MODULES): New module memrw.mod.
2798 (memrw_mod_SOURCE): New macro.
2799 (memrw_mod_CFLAGS): Likewise.
2800 (memrw_mod_LDFLAGS): Likewise.
2802 * conf/i386-efi.rmk (pkglib_MODULES): New module loadbios.mod and
2804 (loadbios_mod_SOURCE): New macro.
2805 (loadbios_mod_CFLAGS): Likewise.
2806 (loadbios_mod_LDFLAGS): Likewise.
2807 (fixvideo_mod_SOURCE): Likewise.
2808 (fixvideo_mod_CFLAGS): Likewise.
2809 (fixvideo_mod_LDFLAGS): Likewise.
2811 * conf/x86_64.rmk (pkglib_MODULES): New module loadbios.mod and
2813 (loadbios_mod_SOURCE): New macro.
2814 (loadbios_mod_CFLAGS): Likewise.
2815 (loadbios_mod_LDFLAGS): Likewise.
2816 (fixvideo_mod_SOURCE): Likewise.
2817 (fixvideo_mod_CFLAGS): Likewise.
2818 (fixvideo_mod_LDFLAGS): Likewise.
2820 2009-04-08 Felix Zielcke <fzielcke@z-51.de>
2822 * disk/lvm.c (grub_lvm_scan_device): Add a missing NULL check.
2824 2009-04-07 David S. Miller <davem@davemloft.net>
2826 * kern/sparc64/dl.c (grub_arch_dl_relocate_symbols): Add
2827 support for R_SPARC_OLO10 relocations. Fix compile warning for
2828 R_SPARC_WDISP30 case.
2829 * kern/sparc64/cache.S: Fix grub_arch_sync_caches implementation.
2831 2009-04-06 Pavel Roskin <proski@gnu.org>
2833 * include/grub/misc.h (ARRAY_SIZE): New macro.
2834 * include/grub/i386/linux.h (GRUB_LINUX_VID_MODE_VESA_START):
2836 * loader/i386/linux.c (allocate_pages): Use free_pages().
2837 (grub_linux_unload): Don't use free_pages().
2838 (grub_linux_boot): Prevent accessing linux_vesafb_modes with a
2839 wrong index. Treat all other modes as text modes.
2840 (grub_cmd_linux): Initialize vid_mode unconditionally to
2841 GRUB_LINUX_VID_MODE_NORMAL. Recognize and support "vga=ask".
2843 * commands/help.c (print_command_help): Use cmd->prio, not
2844 cmd->flags to check for GRUB_PRIO_LIST_FLAG_ACTIVE.
2846 2009-04-06 Vladimir Serbinenko <phcoder@gmail.com>
2850 * parttool/pcpart.c: new file
2851 * commands/parttool.c: likewise
2852 * conf/common.rmk (pkglib_MODULES): Added parttool.mod and pcpart.mod
2853 (parttool_mod_SOURCES): new variable
2854 (parttool_mod_CFLAGS): likewise
2855 (parttool_mod_LDFLAGS): likewise
2856 (pcpart_mod_SOURCES): likewise
2857 (pcpart_mod_CFLAGS): likewise
2858 (pcpart_mod_LDFLAGS): likewise
2859 * conf/i386-coreboot.rmk (grub_emu_SOURCES): added commands/parttool.c
2860 and parttool/pcpart.c
2861 * conf/i386-efi.rmk: likewise
2862 * conf/i386-ieee1275.rmk: likewise
2863 * conf/i386-pc.rmk: likewise
2864 * conf/powerpc-ieee1275.rmk: likewise
2865 * conf/sparc64-ieee1275.rmk: likewise
2866 * conf/x86_64-ieee1275.rmk: likewise
2868 2009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
2870 Support for mtime and further expandability of dir command
2872 * include/grub/lib/datetime.h: moved to ...
2873 * include/grub/datetime.h: ... moved here and added
2874 declaration of grub_unixtime2datetime. All users updated
2875 * include/grub/fs.h: new syntax for dir and mtime functions in
2877 * include/grub/fshelp.h: new declarations of GRUB_FSHELP_TYPE_MASK
2878 and GRUB_FSHELP_FLAGS_MASK
2879 * commands/ls.c (grub_ls_list_files): Write mtime in long format
2880 * fs/ext2.c (grub_ext2_dir): use new dir syntax and supply mtime
2881 (grub_ext2_mtime): new function
2882 * fs/hfsplus.c (grub_hfsplus_dir): use new dir syntax and supply mtime
2883 (grub_hfsplus_mtime): new function
2884 * fs/ufs.c (GRUB_UFS_ATTR_TYPE): new definition
2885 (GRUB_UFS_ATTR_FILE): likewise
2886 (GRUB_UFS_ATTR_LNK): likewise
2887 (struct grub_ufs_sblock): new fields mtime
2888 (grub_ufs_read_inode): new parameter to read inode to a separate buffer
2890 (grub_ufs_dir): mtime support
2891 (grub_ufs_mtime): new function
2892 * fs/affs.c (grub_affs_dir): use new dir syntax
2893 * fs/afs.c (grub_afs_dir): likewise
2894 * fs/cpio.c (grub_cpio_dir): likewise
2895 * fs/fat.c (grub_fat_find_dir): likewise
2896 * fs/hfs.c (grub_hfs_dir): likewise
2897 * fs/iso9660.c (grub_iso9660_dir): likewise
2898 * fs/jfs.c (grub_jfs_dir): likewise
2899 * fs/minix.c (grub_minix_dir): likewise
2900 * fs/ntfs.c (grub_ntfs_dir): likewise
2901 * fs/reiserfs.c (grub_reiserfs_dir): likewise
2902 * fs/sfs.c (grub_sfs_dir): likewise
2903 * fs/xfs.c (grub_xfs_dir): likewise
2904 * util/hostfs.c (grub_hostfs_dir): likewise
2905 * lib/datetime.c: moved to ...
2906 * normal/datetime.c: ... moved here
2907 (grub_unixtime2datetime): new function
2908 * kern/rescue.c (grub_rescue_print_files): use new dir syntax
2909 * normal/completion.c (iterate_dir): use new dir syntax
2910 * normal/misc.c (grub_normal_print_device_info): tell the
2911 last modification time of a volume
2912 * kern/fs.c (grub_fs_probe): updated dummy function to use new syntax
2913 * conf/common.rmk: added lib/datetime.c to ls.mod
2914 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add normal/datetime.c
2915 (normal_mod_SOURCES): likewise
2916 (datetime_mod_SOURCES): Removed lib/datetime.c
2917 * conf/i386-efi.rmk: likewise
2918 * conf/i386-ieee1275.rmk: likewise
2919 * conf/i386-pc.rmk: likewise
2920 * conf/powerpc-ieee1275.rmk: likewise
2921 * conf/sparc64-ieee1275.rmk: likewise
2922 * conf/x86_64-efi.rmk: likewise
2924 2009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
2926 Trim trailing spaces in FAT label and support mtools-like labels
2928 * fs/fat.c (grub_fat_iterate_dir): New function based
2929 on grub_fat_find_dir
2930 (grub_fat_find_dir): use grub_fat_iterate_dir
2931 (grub_fat_label): likewise
2933 2009-04-04 Vladimir Serbinenko <phcoder@gmail.com>
2935 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): add list.h
2937 remove extraneous kernel_elf_HEADERS
2939 2009-04-04 Bean <bean123ch@gnail.com>
2941 * include/grub/util/misc.h: Add dummy function fsync for mingw.
2943 * util/misc.c: Likewise.
2945 2009-04-04 Yoshinori K. Okuji <okuji@enbug.org>
2947 * loader/i386/efi/linux.c (fake_bios_data): Use grub_dprintf
2948 instead of grub_printf.
2950 2009-04-03 Robert Millan <rmh@aybabtu.com>
2952 * loader/i386/linux.c (grub_linux_setup_video): Fill
2953 `params->{red,green,blue,reserved}_{mask_size,field_pos}' with
2954 values from `mode info' structure instead of hardcoded
2957 2009-04-01 Pavel Roskin <proski@gnu.org>
2959 * Makefile.in: Remove all references to MODULE_LDFLAGS, it's
2961 * genmk.rb: Likewise.
2962 * configure.ac: Likewise.
2964 2009-04-01 Manoel Abranches <mrabran@linux.vnet.ibm.com>
2966 * aclocal.m4: Move --build-id=none from MODULE_LDFLAGS to
2967 TARGET_LDFLAGS. This corrects a problem with grub-mkelfimage.
2969 2009-04-01 David S. Miller <davem@davemloft.net>
2971 * normal/sparc64/setjmp.S: Fix setjmp implementation.
2972 * include/grub/sparc64/setjmp.h (grub_jmp_buf): Update.
2973 (grub_setjmp): Mark with 'returns_twice' attribute.
2974 * include/grub/i386/setjmp.h (grub_setjmp): Likewise
2975 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise.
2976 * include/grub/x86_64/setjmp.h (grub_setjmp): Likewise.
2978 2009-04-01 Robert Millan <rmh@aybabtu.com>
2980 Reapply fix from 2008-07-28 which was accidentally reverted; also
2981 perform the same fix to a similar check in same function.
2983 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
2984 with the same number are found, just use issue a warning with
2985 grub_dprintf(), as this error has been reported to be non-fatal.
2987 2009-03-31 Pavel Roskin <proski@gnu.org>
2989 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Provide safe default
2990 for cross-compilation.
2992 2009-03-30 Robert Millan <rmh@aybabtu.com>
2994 Fix i386-ieee1275 build.
2996 * include/grub/i386/ieee1275/loader.h (grub_multiboot2_real_boot):
2999 2009-03-30 Pavel Roskin <proski@gnu.org>
3001 * fs/hfs.c (grub_hfs_strncasecmp): Integrate into ...
3002 (grub_hfs_cmp_catkeys): ... this. Don't assume strings to be
3003 zero-terminated, rely only on the strlen value. Fix comparison
3004 of strings differing in length.
3006 2009-03-30 Robert Millan <rmh@aybabtu.com>
3008 * loader/i386/linux.c (grub_cmd_linux): Check for zImage before
3009 checking for abi version. Improve error messages on BIOS to notify
3010 user about `linux16' command.
3012 2009-03-29 Vladimir Serbinenko <phcoder@gmail.com>
3016 * kern/disk.c (grub_disk_cache_store): Invalidate previous cache
3017 in case of collision
3018 * disk/scsi.c (grub_scsi_open): free scsi in case of error
3020 2009-03-29 Robert Millan <rmh@aybabtu.com>
3022 * loader/i386/linux.c (grub_cmd_linux): Parse "vga=" parameter and
3023 set `vid_mode' accordingly.
3024 (grub_linux_boot): Process `vid_mode' and set video mode.
3026 2009-03-29 Robert Millan <rmh@aybabtu.com>
3028 * util/grub.d/10_linux.in (linux_entry): New function.
3029 Factorize generation of Linux boot entries.
3031 2009-03-29 Yoshinori K. Okuji <okuji@enbug.org>
3033 Make the format of Environment Block plain text. The boot loader
3034 part is not tested well yet.
3036 * util/grub-editenv.c (DEFAULT_ENVBLK_SIZE): New macro.
3039 (usage): Remove "info" and "clear". Add "unset". Update the
3040 description of "set", as this does not delete variables any
3042 (create_envblk_file): Complete rewrite.
3043 (open_envblk_file): Likewise.
3044 (cmd_info): Removed.
3045 (cmd_list): Likewise.
3046 (cmd_set): Likewise.
3047 (cmd_clear): Likewise.
3048 (list_variables): New function.
3049 (write_envblk): Likewise.
3050 (set_variables): Likewise.
3051 (unset_variables): Likewise.
3052 (main): Complete rewrite.
3054 * commands/loadenv.c (buffer): Removed.
3056 (open_envblk_file): New function.
3057 (read_envblk_file): Complete rewrite.
3058 (grub_cmd_load_env): Likewise.
3059 (grub_cmd_list_env): Likewise.
3060 (struct blocklist): New struct.
3061 (free_blocklists): New function.
3062 (check_blocklists): Likewise.
3063 (write_blocklists): Likewise.
3064 (grub_cmd_save_env): Complete rewrite.
3066 * include/grub/lib/envblk.h (GRUB_ENVBLK_SIGNATURE): Replaced with
3067 a plain text signature.
3068 (GRUB_ENVBLK_MAXLEN): Removed.
3069 (struct grub_envblk): Complete rewrite.
3070 (grub_envblk_find): Removed.
3071 (grub_envblk_insert): Likewise.
3072 (grub_envblk_open): New prototype.
3073 (grub_envblk_set): Likewise.
3074 (grub_envblk_delete): Put const to VALUE.
3075 (grub_envblk_iterate): Put const to NAME and VALUE.
3076 (grub_envblk_close): New prototype.
3077 (grub_envblk_buffer): New inline function.
3078 (grub_envblk_size): Likewise.
3080 * lib/envblk.c: Include grub/mm.h.
3081 (grub_env_find): Removed.
3082 (grub_envblk_open): New function.
3083 (grub_envblk_close): Likewise.
3084 (escaped_value_len): Likewise.
3085 (find_next_line): Likewise.
3086 (grub_envblk_insert): Removed.
3087 (grub_envblk_set): New function.
3088 (grub_envblk_delete): Complete rewrite.
3089 (grub_envblk_iterate): Likewise.
3091 2009-03-28 Robert Millan <rmh@aybabtu.com>
3093 * conf/i386-pc.rmk (pkglib_MODULES): Add `linux16.mod'.
3094 (linux16_mod_SOURCES, linux16_mod_CFLAGS, linux16_mod_LDFLAGS): New
3095 variables. Use 16-bit loader.
3096 (linux_mod_SOURCES, linux_mod_CFLAGS, linux_mod_LDFLAGS): Use 32-bit
3098 * kern/i386/loader.S (grub_linux_boot): Rename to ...
3099 (grub_linux16_boot): ... this. Update all users.
3100 * loader/i386/linux.c (grub_linux32_boot): Rename to ...
3101 (grub_linux_boot): ... this. Update all users.
3103 * loader/i386/pc/linux.c (GRUB_MOD_INIT(linux)): Rename to ...
3104 (GRUB_MOD_INIT(linux16)): ... this. Rename `linux' and `initrd'
3105 commands to `linux16' and `initrd16'.
3106 (GRUB_MOD_FINI(linux)): Rename to ...
3107 (GRUB_MOD_FINI(linux16)): ... this.
3109 2009-03-24 Pavel Roskin <proski@gnu.org>
3111 * genmk.rb: Define ASM_FILE for *.S files for *.lst generation,
3112 not just for compilation.
3114 2009-03-22 Vladimir Serbinenko <phcoder@gmail.com>
3116 Move multiboot helper out of kernel
3118 * conf/i386-pc.rmk (multiboot_mod_SOURCES): Add
3119 `loader/i386/multiboot_helper.S'.
3120 * conf/i386-coreboot.rmk: Likewise
3121 * conf/i386-ieee1275.rmk: Likewise
3123 * kern/i386/loader.S: Move multiboot helpers from here...
3124 * loader/i386/multiboot_helper.S: ...moved here
3125 * include/grub/i386/loader.h: Move declarations of multiboot
3126 helpers from here...
3127 * include/grub/i386/multiboot.h: ...moved here
3128 * loader/i386/multiboot.c: Added include of grub/cpu/multiboot.h
3130 2009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
3132 * kern/env.c (grub_env_context_open): Added an argument to specify
3133 whether a new context inherits exported variables from current
3134 one. This is useful when making a sandbox to interpret a config
3136 All callers updated.
3138 * include/grub/env.h (grub_env_context_open): Updated the prototype.
3140 2009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
3142 * kern/env.c (grub_env_context_close): Fix memory leaks.
3144 2009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
3146 * normal/main.c (grub_normal_execute): Added an argument
3147 BATCH to specify if an interactive interface should be provided
3148 after reading a config file.
3149 All callers updated.
3150 (read_command_list): Prevent being executed twice.
3151 (read_fs_list): Likewise.
3153 * include/grub/normal.h (grub_normal_execute): Updated the
3156 2009-03-22 Pavel Roskin <proski@gno.org>
3158 * kern/powerpc/ieee1275/startup.S: Replace EXT_C(start) with
3160 * kern/i386/pc/startup.S: Likewise.
3161 * kern/i386/efi/startup.S: Likewise.
3162 * kern/i386/ieee1275/startup.S: Likewise.
3163 * kern/i386/coreboot/startup.S: Likewise.
3164 * kern/x86_64/efi/startup.S: Likewise.
3166 * aclocal.m4 (grub_CHECK_START_SYMBOL): Remove.
3167 * configure.ac: Don't call grub_CHECK_START_SYMBOL.
3168 * kern/i386/pc/startup.S: Use _start instead of START_SYMBOL.
3170 2009-03-21 Vladimir Serbinenko <phcoder@gmail.com>
3172 Bugfixes in multiboot for bugs uncovered by solaris kernel.
3174 * loader/i386/multiboot_elfxx.c (grub_multiboot_load_elf): Corrected
3176 Use vaddr of correct segment for entry_point.
3178 2009-03-21 Bean <bean123ch@gmail.com>
3180 * commands/blocklist.c: Add include file <grub/command.h>, remove
3181 <grub/normal.h> and <grub/arg.h>.
3182 (grub_cmd_blocklist): Use the new command interface.
3183 (GRUB_MOD_INIT): Likewise.
3184 (GRUB_MOD_FINI): Likewise.
3185 * commands/boot.c: Likewise.
3186 * commands/cat.c: Likewise.
3187 * commands/cmp.c: Likewise.
3188 * commands/configfile.c: Likewise.
3189 * commands/crc.c: Likewise.
3190 * commands/echo.c: Likewise.
3191 * commands/halt.c: Likewise.
3192 * commands/handler.c: Likewise.
3193 * commands/hdparm.c: Likewise.
3194 * commands/help.c: Likewise.
3195 * commands/hexdump.c: Likewise.
3196 * commands/loadenv.c: Likewise.
3197 * commands/ls.c: Likewise.
3198 * commands/lsmmap.c: Likewise.
3199 * commands/lspci.c: Likewise.
3200 * commands/loadenv.c: Likewise.
3201 * commands/read.c: Likewise.
3202 * commands/reboot.c: Likewise.
3203 * commands/search.c: Likewise.
3204 * commands/sleep.c: Likewise.
3205 * commands/test.c: Likewise.
3206 * commands/usbtest.c: Likewise.
3207 * commands/videotest.c: Likewise.
3208 * commands/i386/cpuid.c: Likewise.
3209 * commands/i386/pc/halt.c: Likewise.
3210 * commands/i386/pc/play.c: Likewise.
3211 * commands/i386/pc/pxecmd.c: Likewise.
3212 * commands/i386/pc/vbeinfo.c: Likewise.
3213 * commands/i386/pc/vbetest.c: Likewise.
3214 * commands/ieee1275/suspend.c: Likewise.
3215 * disk/loopback.c: Likewise.
3216 * font/font_cmd.c: Likewise.
3217 * hello/hello.c: Likewise.
3218 * loader/efi/appleloader.c: Likewise.
3219 * loader/efi/chainloader.c: Likewise.
3220 * loader/i386/bsd.c: Likewise.
3221 * loader/i386/efi/linux.c: Likewise.
3222 * loader/i386/ieee1275/linux.c: Likewise.
3223 * loader/i386/linux.c: Likewise.
3224 * loader/i386/pc/chainloader.c: Likewise.
3225 * loader/i386/pc/linux.c: Likewise.
3226 * loader/powerpc/ieee1275/linux.c: Likewise.
3227 * loader/multiboot_loader.c: Likewise.
3228 * term/gfxterm.c: Likewise.
3229 * term/i386/pc/serial.c: Likewise.
3230 * term/terminfo.c: Likewise.
3232 * term/i386/pc/vesafb.c: Removed <grub/arg.h>.
3233 * term/i386/pc/vga.c: Likewise.
3234 * video/readers/jpeg.c: Likewise.
3235 * video/readers/png.c: Likewise.
3236 * video/readers/tga.c: Likewise.
3238 * util/grub-fstest (cmd_loopback): Removed.
3239 (cmd_blocklist): Likewise.
3241 (grub_register_command): Likewise.
3242 (grub_unregister_command): Likewise.
3243 (execute_command): Use grub_command_find to locate command and execute
3246 * include/grub/efi/chainloader.h: Removed.
3247 * loader/efi/chainloader_normal.c: Likewise.
3248 * loader/i386/bsd_normal.c: Likewise.
3249 * loader/i386/pc/chainloader_normal.c: Likewise.
3250 * loader/i386/pc/multiboot_normal.c: Likewise.
3251 * loader/linux_normal.c: Likewise.
3252 * loader/multiboot_loader_normal.c: Likewise.
3253 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
3255 * gencmdlist.sh: Scan new registration command grub_register_extcmd
3256 and grub_register_command_p1.
3258 * conf/common.rmk (grub_fstest_SOURCES): Add kern/list.c,
3259 kern/command.c, lib/arg.c and commands/extcmd.c.
3260 (pkglib_MODULES): Remove boot.mod, and minicmd.mod and extcmd.mod.
3261 (minicmd_mod_SOURCES): New variable.
3262 (minicmd_mod_CFLAGS): Likewise.
3263 (minicmd_mod_LDFLAGS): Likewise.
3264 (extcmd_mod_SOURCES): Likewise.
3265 (extcmd_mod_CFLAGS): Likewise.
3266 (extcmd_mod_LDFLAGS): Likewise.
3267 (boot_mod_SOURCES): Removed.
3268 (boot_mod_CFLAGS): Likewise.
3269 (boot_mod_LDFLAGS): Likewise.
3271 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/command.c and
3273 (kernel_img_HEADERS): Add command.h.
3274 (grub_emu_SOURCES): Remove commands/boot.c and normal/arg.c, add
3275 commands/minicmd.c, kern/command.c, kern/corecmd.c, commands/extcmd.c
3277 (pkglib_MODULES): Change _linux.mod, _chain.mod, _bsd.mod and
3278 _multiboot.mod as linux.mod, chain.mod, bsd.mod and multiboot.mod,
3279 remove the corresponding normal mode command.
3280 (normal_mod_SOURCES): Remove normal/arg.c.
3281 * conf/i386-coreboot.rmk: Likewise.
3282 * conf/i386-efi.rmk: Likewise.
3283 * conf/i386-ieee1275.rmk: Likewise.
3284 * conf/powerpc-ieee1275.rmk: Likewise.
3285 * conf/x86_64-efi.rmk: Likewise.
3287 * include/grub/arg.h: Move from here ...
3288 * include/grub/lib/arg.h: ... to here.
3290 * normal/arg.c: Move from here ...
3291 * lib/arg.c: ... to here.
3293 * commands/extcmd.c: New file.
3294 * commands/minicmd.c: Likewise.
3295 * include/grub/command.h: Likewise.
3296 * include/grub/extcmd.h: Likewise.
3297 * kern/command.c: Likewise.
3298 * kern/corecmd.c: Likewise.
3300 * kern/list.c (grub_list_iterate): Return int instead of void.
3301 (grub_list_insert): New function.
3302 (grub_prio_list_insert): Likewise.
3304 * kern/rescue.c (grub_rescue_command): Removed.
3305 (grub_rescue_command_list): Likewise.
3306 (grub_rescue_register_command): Likewise.
3307 (grub_rescue_unregister_command): Likewise.
3308 (grub_rescue_cmd_boot): Move to minicmd.c
3309 (grub_rescue_cmd_help): Likewise.
3310 (grub_rescue_cmd_info): Likewise.
3311 (grub_rescue_cmd_boot): Likewise.
3312 (grub_rescue_cmd_testload): Likewise.
3313 (grub_rescue_cmd_dump): Likewise.
3314 (grub_rescue_cmd_rmmod): Likewise.
3315 (grub_rescue_cmd_lsmod): Likewise.
3316 (grub_rescue_cmd_exit): Likewise.
3317 (grub_rescue_print_devices): Moved to corecmd.c.
3318 (grub_rescue_print_files): Likewise.
3319 (grub_rescue_cmd_ls): Likewise.
3320 (grub_rescue_cmd_insmod): Likewise.
3321 (grub_rescue_cmd_set): Likewise.
3322 (grub_rescue_cmd_unset): Likewise.
3323 (attempt_normal_mode): Use grub_command_find to get normal module.
3324 (grub_enter_rescue_mode): Use grub_register_core_commands to register
3325 commands, remove grub_rescue_register_command calls.
3327 * normal/command.c (grub_register_command): Removed.
3328 (grub_unregister_command): Likewise.
3329 (grub_command_find): Likewise.
3330 (grub_iterate_commands): Likewise.
3331 (rescue_command): Likewise.
3332 (export_command): Moved to corecmd.c.
3333 (set_command): Removed.
3334 (unset_command): Likewise.
3335 (insmod_command): Likewise.
3336 (rmmod_command): Likewise.
3337 (lsmod_command): Likewise.
3338 (grub_command_init): Likewise.
3340 * normal/completion.c (iterate_command): Use cmd->prio to check for
3342 (complete_arguments): Use grub_extcmd_t structure to find options.
3343 (grub_normal_do_completion): Change function grub_iterate_commands to
3344 grub_command_iterate.
3346 * normal/execute.c (grub_script_execute_cmd): No need to parse
3349 * normal/main.c (grub_dyncmd_dispatcher): New function.
3350 (read_command_list): Register unload commands as dyncmd.
3351 (grub_cmd_normal): Use new command interface, register rescue,
3352 unregister normal at entry, register normal, unregister rescue at exit.
3354 * include/grub/list.h (grub_list_test_t): New type.
3355 (grub_list_iterate): Return int instead of void.
3356 (grub_list_insert): New function.
3357 (GRUB_AS_NAMED_LIST_P): New macro.
3358 (GRUB_AS_PRIO_LIST): Likewise.
3359 (GRUB_AS_PRIO_LIST_P): Likewise.
3360 (GRUB_PRIO_LIST_PRIO_MASK): New constant.
3361 (GRUB_PRIO_LIST_FLAG_ACTIVE): Likewise.
3362 (grub_prio_list): New structure.
3363 (grub_prio_list_insert): New function.
3364 (grub_prio_list_remove): New inline function.
3366 * include/grub/normal.h: Remove <grub/arg.h>, add <grub/command.h>.
3367 (GRUB_COMMAND_FLAG_CMDLINE): Moved to command.h.
3368 (GRUB_COMMAND_FLAG_MENU): Likewise.
3369 (GRUB_COMMAND_FLAG_BOTH): Likewise.
3370 (GRUB_COMMAND_FLAG_TITLE): Likewise.
3371 (GRUB_COMMAND_FLAG_NO_ECHO): Likewise.
3372 (GRUB_COMMAND_FLAG_NO_ARG_PARSE): Removed.
3373 (GRUB_COMMAND_FLAG_NOT_LOADED): Likewise.
3374 (grub_command): Likewise.
3375 (grub_register_command): Likewise.
3376 (grub_command_find): Likewise.
3377 (grub_iterate_commands): Likewise.
3378 (grub_command_init): Likewise.
3379 (grub_arg_parse): Likewise.
3380 (grub_arg_show_help): Likewise.
3382 * include/grub/rescue.h (grub_rescue_register_command): Removed.
3383 (grub_rescue_unregister_command): Likewise.
3385 * include/grub/i386/bsd.h: Remove grub_rescue_cmd_freebsd,
3386 grub_rescue_cmd_openbsd, grub_rescue_cmd_netbsd,
3387 grub_rescue_cmd_freebsd_loadenv and grub_rescue_cmd_freebsd_module.
3389 * include/grub/i386/efi/loader.h: Remove grub_rescue_cmd_linux and
3390 grub_rescue_cmd_initrd.
3391 * include/grub/i386/loader.h: Likewise.
3392 * include/grub/x86_64/loader.h: Likewise.
3394 * include/grub/i386/pc/chainloader.h: Remove grub_chainloader_cmd.
3396 2009-03-21 Bean <bean123ch@gmail.com>
3398 * util/hostdisk.c (read_device_map): Use grub_util_get_disk_size
3399 instead of stat in mingw environment.
3401 * util/misc.c (grub_millisleep): Use Sleep in mingw environment.
3403 * aclocal.m4 (grub_CHECK_LINK_DIR): New function.
3405 * configure.ac: Use grub_CHECK_LINK_DIR to determine whether to use
3408 2009-03-21 Bean <bean123ch@gmail.com>
3410 * fs/ext2.c (grub_ext2_mount): Change errno to GRUB_ERR_BAD_FS for
3413 2009-03-18 Michel Dänzer <michel@daenzer.net>
3415 * fs/ext2.c (grub_ext2_read_block): Take endianness into account when
3416 checking inode flags for EXT4_EXTENTS_FLAG.
3418 2009-03-18 Robert Millan <rmh@aybabtu.com>
3420 * loader/i386/linux.c: Include `<grub/video.h>' and
3421 `<grub/i386/pc/vbe.h>'..
3422 (grub_linux_setup_video): New function. Loosely based on the EFI one.
3423 (grub_linux32_boot): Attempt to configure video settings with
3424 grub_linux_setup_video().
3425 (grub_rescue_cmd_linux): Set noreturn=0 in grub_loader_set, in order
3426 to avoid grub_console_fini() which would step out of graphical mode
3429 2009-03-14 Robert Millan <rmh@aybabtu.com>
3431 Fix build on powerpc.
3432 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Add `handler.h'.
3434 2009-03-12 Vladimir Serbinenko <phcoder@gmail.com>
3436 * term/gfxterm.c (GRUB_MOD_FINI(term_gfxterm)): Correct name of
3437 background image command.
3439 2009-03-12 Colin D Bennett <colin@gibibit.com>
3441 * term/gfxterm.c (draw_cursor): Ensure character is redrawn.
3442 (grub_gfxterm_putchar): Extract pairs of identical calls to
3443 draw_cursor out of conditional blocks.
3445 2009-03-11 Pavel Roskin <proski@gnu.org>
3447 * fs/hfs.c (grub_hfs_strncasecmp): New function.
3448 (grub_hfs_cmp_catkeys): Use HFS specific string comparison.
3450 2009-03-11 Robert Millan <rmh@aybabtu.com>
3452 * loader/i386/multiboot_elfxx.c
3453 (CONCAT(grub_multiboot_load_elf, XX)): Do not reject ET_DYN files.
3455 2009-03-11 Felix Zielcke <fzielcke@z-51.de>
3457 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add `kern/list.c' and
3460 2009-03-11 Robert Millan <rmh@aybabtu.com>
3462 * loader/i386/multiboot.c (code_size): New variable.
3463 (grub_multiboot): Define offsets by adding to `code_size' rather
3464 than subtracting from `grub_multiboot_payload_size'. Provide
3465 4-byte alignment to MBI and others by increasing
3466 `boot_loader_name_length' appropriately.
3468 * loader/i386/multiboot_elfxx.c
3469 (CONCAT(grub_multiboot_load_elf, XX)): Initialize `code_size'.
3471 2009-03-09 Felix Zielcke <fzielcke@z-51.de>
3473 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove duplicated
3476 2009-03-08 Robert Millan <rmh@aybabtu.com>
3478 Make loader/i386/linux.c usable on i386-pc again.
3480 * kern/i386/pc/init.c (grub_machine_init): Disable addition of low
3482 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS] (allocate_pages): Remove
3485 2009-03-07 Bean <bean123ch@gmail.com>
3487 * loader/i386/efi/linux.c (grub_rescue_cmd_initrd): Fix a bug in initrd
3490 2009-03-06 Robert Millan <rmh@aybabtu.com>
3492 Fix display issue on terminals with screen size other than 80x25
3493 (e.g. gfxterm with resolution higher than 640x480).
3495 * normal/main.c (grub_normal_init_page): Display title text in a
3496 position relative to the center of the terminal instead of relying
3497 on a hardcoded offset.
3499 2009-03-04 Robert Millan <rmh@aybabtu.com>
3501 Filter /etc/grub.d/10_* so that only add-ons for native kernels are
3504 * Makefile.in (host_kernel): New variable.
3505 * conf/common.rmk (grub-mkconfig_SCRIPTS): Conditionalize all 10_*.in
3506 scripts instead of just the windows one.
3507 * configure.ac: Initialize and AC_SUBST `host_kernel'.
3509 2009-03-04 Felix Zielcke <fzielcke@z-51.de>
3511 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `kern/list.c' and
3513 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
3514 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
3515 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
3516 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3517 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3518 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3520 2009-03-04 Felix Zielcke <fzielcke@z-51.de>
3522 * partmap/pc.c (pc_partition_map_iterate): Skip over invalid BSD partitions
3523 or if there's no space for the disk label and print the partition number on a
3526 2009-03-04 Felix Zielcke <fzielcke@z-51.de>
3528 * util/misc.c: Include <time.h>.
3529 (grub_millisleep): New function.
3531 2009-03-04 Bean <bean123ch@gmail.com>
3533 * configure.ac: Only test -mcmodel=large option in x86_64-efi, also add
3534 another option -mno-red-zone.
3536 * commands/handler.c: Change module description.
3538 * kern/handler.c: Add missing space at the end of description line.
3540 * kern/list.c: Likewise.
3542 2009-03-03 Robert Millan <rmh@aybabtu.com>
3544 Move more components to the relocation area, and fix mbi pointer
3545 handling to use the destination rather than the origin (thanks to
3546 Vladimir Serbinenko for spotting).
3548 * loader/i386/multiboot.c (mbi_dest): New variable.
3549 (grub_multiboot_boot): Use `mbi_dest' instead of `mbi'.
3550 (grub_multiboot): Put cmdline, boot_loader_name and mbi in the
3553 2009-03-01 Bean <bean123ch@gmail.com>
3555 * include/grub/efi/api.h (GRUB_EFI_MPS_TABLE_GUID): New constant.
3556 (GRUB_EFI_ACPI_TABLE_GUID): Likewise.
3557 (GRUB_EFI_ACPI_20_TABLE_GUID): Likewise.
3558 (GRUB_EFI_SMBIOS_TABLE_GUID): Likewise.
3560 * loader/i386/efi/linux.c (acpi_guid): New variable.
3561 (acpi_guid): Likewise.
3562 (EBDA_SEG_ADDR): New constant.
3563 (LOW_MEM_ADDR): Likewise.
3564 (FAKE_EBDA_SEG): Likewise.
3565 (fake_bios_data): New function.
3566 (grub_linux_boot): Call fake_bios_data.
3568 2009-03-01 Bean <bean123ch@gmail.com>
3570 * commands/terminal.c: Removed.
3572 * commands/handler.c: New file.
3574 * include/grub/list.h: Likewise.
3576 * include/grub/handler.h: Likewise.
3578 * kern/list.c: Likewise.
3580 * kern/handler.c: Likewise.
3582 * kern/term.h: Include header file <grub/handler.h>.
3583 (grub_term_input): Move next field to the beginning.
3584 (grub_term_output): Likewise.
3585 (grub_term_input_class): New variable.
3586 (grub_term_output_class): Likewise.
3587 (grub_term_register_input): Changed to inline function.
3588 (grub_term_register_output): Likewise.
3589 (grub_term_unregister_input): Likewise.
3590 (grub_term_unregister_output): Likewise.
3591 (grub_term_set_current_input): Likewise.
3592 (grub_term_set_current_output): Likewise.
3593 (grub_term_get_current_input): Likewise.
3594 (grub_term_get_current_output): Likewise.
3595 (grub_term_iterate_input): Removed.
3596 (grub_term_iterate_output): Likewise.
3598 * kern/term.c (grub_term_list_input): Removed.
3599 (grub_term_list_output): Likewise.
3600 (grub_term_input_class): New variable.
3601 (grub_term_output_class): Likewise.
3602 (grub_cur_term_input): Change variable as macro.
3603 (grub_cur_term_output): Likewise.
3604 (grub_term_register_input): Removed.
3605 (grub_term_register_output): Likewise.
3606 (grub_term_unregister_input): Likewise.
3607 (grub_term_unregister_output): Likewise.
3608 (grub_term_set_current_input): Likewise.
3609 (grub_term_set_current_output): Likewise.
3610 (grub_term_iterate_input): Likewise.
3611 (grub_term_iterate_output): Likewise.
3612 (grub_term_get_current_input): Likewise.
3613 (grub_term_get_current_output): Likewise.
3615 * util/grub-editenv.c: Include header file <grub/handler.h>.
3616 (grub_term_get_current_input): Removed.
3617 (grub_term_get_current_output): Likewise.
3618 (grub_term_input_class): New variable.
3619 (grub_term_output_class): Likewise.
3621 * util/grub-fstest.c (grub_term_get_current_input): Removed.
3622 (grub_term_get_current_output): Likewise.
3623 (grub_term_input_class): New variable.
3624 (grub_term_output_class): Likewise.
3626 * util/grub-probe.c (grub_term_get_current_input): Removed.
3627 (grub_term_get_current_output): Likewise.
3628 (grub_term_input_class): New variable.
3629 (grub_term_output_class): Likewise.
3631 * util/i386/pc/grub-setup.c (grub_term_get_current_input): Removed.
3632 (grub_term_get_current_output): Likewise.
3633 (grub_term_input_class): New variable.
3634 (grub_term_output_class): Likewise.
3636 * conf/common.rmk (pkglib_MODULES): Replace terminal with handler.
3637 (terminal_mod_SOURCES): Likewise.
3638 (terminal_mod_CFLAGS): Likewise.
3639 (terminal_mod_LDFLAGS): Likewise.
3641 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace terminal.c with
3643 (kernel_img_SOURCES): Add list.c and handler.c.
3644 (kernel_img_HEADERS): Add list.h and handler.h.
3646 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
3648 (kernel_mod_SOURCES): Add list.c and handler.c.
3649 (kernel_mod_HEADERS): Add list.h and handler.h.
3651 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Replace terminal.c with
3653 (kernel_elf_SOURCES): Add list.c and handler.c.
3654 (kernel_elf_HEADERS): Add list.h and handler.h.
3656 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
3658 (kernel_elf_SOURCES): Add list.c and handler.c.
3659 (kernel_elf_HEADERS): Add list.h and handler.h.
3661 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
3663 (kernel_mod_SOURCES): Add list.c and handler.c.
3664 (kernel_mod_HEADERS): Add list.h and handler.h.
3666 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
3668 (kernel_elf_SOURCES): Add list.c and handler.c.
3669 (kernel_elf_HEADERS): Add list.h and handler.h.
3671 2009-02-27 Robert Millan <rmh@aybabtu.com>
3673 Factorize elf32 / elf64 code in Multiboot loader. This will
3674 prevent it from getting out of sync again.
3676 * loader/i386/multiboot.c (grub_multiboot_is_elf32,
3677 grub_multiboot_load_elf32, grub_multiboot_is_elf64,
3678 grub_multiboot_load_elf64): Move from here ...
3679 * loader/i386/multiboot_elfxx.c (grub_multiboot_is_elf,
3680 grub_multiboot_load_elf): ... to here (new file).
3682 2009-02-27 Robert Millan <rmh@aybabtu.com>
3684 * util/grub.d/10_linux.in: Rename "single-user mode" to
3687 2009-02-27 Vladimir Serbinenko <phcoder@gmail.com>
3689 Don't leak in SCSI code.
3690 * disk/scsi.c (grub_scsi_close): free `scsi'.
3692 2009-02-27 Robert Millan <rmh@aybabtu.com>
3694 * loader/i386/pc/multiboot.c: Move from here ...
3695 * loader/i386/multiboot.c: ... to here. Update all users.
3697 2009-02-27 Robert Millan <rmh@aybabtu.com>
3699 Patch from Alexandre Bique <bique.alexandre@gmail.com>
3700 * util/i386/pc/grub-setup.c (setup): Fix directory path.
3702 2009-02-27 Krzysztof Smiechowicz <deadwood@wp.pl>
3704 * fs/sfs.c (grub_sfs_read_extent): Correction to traversing extent
3707 2009-02-27 Robert Millan <rmh@aybabtu.com>
3709 * kern/misc.c (grub_strtoull): Fix bug (it mistakenly parsed the
3710 `0x' qualifier as 0 when base is specified as parameter).
3712 2009-02-24 Bean <bean123ch@gmail.com>
3714 * configure.ac: Check for -mcmodel=large in x86_64 target.
3716 * include/grub/efi/api.h (efi_call_10): New macro.
3717 (efi_wrap_10): New function.
3719 * include/grub/efi/pe32.h (GRUB_PE32_REL_BASE_HIGH): New macro.
3720 (GRUB_PE32_REL_BASED_HIGH): Likewise.
3721 (GRUB_PE32_REL_BASED_LOW): Likewise.
3722 (GRUB_PE32_REL_BASED_HIGHLOW): Likewise.
3723 (GRUB_PE32_REL_BASED_HIGHADJ): Likewise.
3724 (GRUB_PE32_REL_BASED_MIPS_JMPADDR): Likewise.
3725 (GRUB_PE32_REL_BASED_SECTION): Likewise.
3726 (GRUB_PE32_REL_BASED_REL): Likewise.
3727 (GRUB_PE32_REL_BASED_IA64_IMM64): Likewise.
3728 (GRUB_PE32_REL_BASED_DIR64): Likewise.
3729 (GRUB_PE32_REL_BASED_HIGH3ADJ): Likewise.
3731 * kern/x86_64/dl.c (grub_arch_dl_relocate_symbols): Fixed relocation
3734 * kern/x86_64/efi/callwrap.S (efi_wrap_6): Bug fix.
3735 (efi_wrap_10): New function.
3737 * kern/x86_64/efi/startup.S (codestart): Use relative addressing.
3739 * loader/efi/appleloader.c (devpath_5): Add support for late 2008
3740 MB/MBP model (NV chipset).
3741 (devdata_devs): Add devpath_5 to the list.
3743 * load/i386/efi/linux.c (video_base): Remove variable.
3744 (RGB_MASK): New macro.
3745 (RGB_MAGIC): Likewise.
3746 (LINE_MIN): Likewise.
3747 (LINE_MAX): Likewise.
3748 (FBTEST_STEP): Likewise.
3749 (FBTEST_COUNT): Likewise.
3750 (fb_list): New variable.
3751 (grub_find_video_card): Remove function.
3752 (find_framebuf): New function.
3753 (grub_linux_setup_video): Use find_framebuf to get frame buffer and
3756 * util/i386/efi/grub-mkimage.c (grub_reloc_section): Fix relocation
3759 2009-02-22 Vesa Jääskeläinen <chaac@nic.fi>
3761 Patch #25624 by Kevin Lacquement <kevin@lacqui>.
3763 * util/grub-mkconfig.in: Use ${grub_mkdevicemap} instead of hard
3766 2009-02-22 Robert Millan <rmh@aybabtu.com>
3768 * include/multiboot.h (MULTIBOOT_INFO_ALIGN): New macro.
3769 * loader/i386/pc/multiboot.c (grub_multiboot): Include the MBI
3770 in our relocation, instead of using it directly from heap. Also
3771 use `MULTIBOOT_INFO_ALIGN' to ensure it is aligned.
3773 2009-02-21 Robert Millan <rmh@aybabtu.com>
3775 Implement USB keyboard support (based on patch by Marco Gerards)
3777 * conf/i386-pc.rmk (pkglib_MODULES): Add `usb_keyboard.mod'.
3778 (usb_keyboard_mod_SOURCES, usb_keyboard_mod_CFLAGS)
3779 (usb_keyboard_mod_LDFLAGS): New variables.
3781 * term/usb_keyboard.c: New file.
3783 2009-02-14 Vladimir Serbinenko <phcoder@gmail.com>
3785 Corrected wrong declaration
3787 * kern/disk.c: corrected declaration of grub_disk_ata_pass_through.
3789 2009-02-14 Christian Franke <franke@computer.org>
3791 * commands/lspci.c (grub_pci_classes): Add `SATA Controller'.
3792 (grub_lspci_iter): Print class code and programming interface byte.
3794 2009-02-14 Christian Franke <franke@computer.org>
3796 * gendistlist.sh: Ignore `.svn' directories.
3798 2009-02-14 Felix Zielcke <fzielcke@z-51.de>
3800 * fs/fat.c: Add 2009 to Copyright line.
3802 2009-02-14 Christian Franke <franke@computer.org>
3804 * commands/hdparm.c: New file. Provides `hdparm' command
3805 which sends ATA commands via grub_disk_ata_pass_through ().
3807 * conf/i386-pc.rmk: Add ata_pthru.mod and hdparm.mod.
3809 * disk/ata.c: Include <grub/ata.h>. Move <grub/misc.h>
3810 and <grub/cpu/io.h> to include/grub/ata.h.
3811 (enum grub_ata_addressing_t): Move to include/grub/ata.h.
3812 (GRUB_CDROM_SECTOR_SIZE): Remove.
3813 (GRUB_ATA_*): Move to include/grub/ata.h.
3814 (GRUB_ATAPI_*): Likewise.
3815 (enum grub_ata_commands): Likewise.
3816 (enum grub_ata_timeout_milliseconds): Likewise.
3817 (struct grub_ata_device): Likewise.
3818 (grub_ata_regset): Likewise.
3819 (grub_ata_regget): Likewise.
3820 (grub_ata_regset2): Likewise.
3821 (grub_ata_regget2): Likewise.
3822 (grub_ata_check_ready): Likewise.
3823 (grub_ata_wait_not_busy): Remove static, exported in
3825 (grub_ata_wait_drq): Likewise.
3826 (grub_ata_pio_read): Likewise.
3828 * disk/ata_pthru.c: New file. Provides grub_ata_pass_through ()
3829 function for hdparm.mod.
3831 * include/grub/ata.h: New file, contains declarations from
3833 (enum grub_ata_commands): Add new commands for commands/hdparm.c.
3835 * include/grub/disk.h (grub_disk_ata_pass_through_parms): New struct.
3836 (grub_disk_ata_pass_through): New exported variable.
3838 * kern/disk.c (grub_disk_ata_pass_through): New variable.
3840 2009-02-13 Colin D Bennett <colin@gibibit.com>
3842 Support multiple fallback entries, and provide an API to support
3843 executing default+fallback menu entries. Renamed the `terminal' menu
3846 * include/grub/normal.h (grub_normal_text_menu_viewer): New global
3847 variable declaration.
3848 (grub_menu_execute_callback): New structure declaration.
3849 (grub_menu_execute_callback_t): New typedef.
3850 (grub_menu_execute_with_fallback): New function declaration.
3851 (grub_menu_get_entry): Likewise.
3852 (grub_menu_get_timeout): Likewise.
3853 (grub_menu_set_timeout): Likewise.
3855 * normal/main.c (GRUB_MOD_INIT(normal)): Refer to new variable name.
3857 * normal/menu.c (grub_wait_after_message): Moved to
3858 `normal/menu_text.c'.
3859 (draw_border): Likewise.
3860 (print_message): Likewise.
3861 (print_entry): Likewise.
3862 (print_entries): Likewise.
3863 (grub_menu_init_page): Likewise.
3864 (get_entry_number): Likewise.
3865 (print_timeout): Likewise.
3866 (run_menu): Likewise.
3867 (grub_menu_execute_entry): Likewise.
3868 (show_text_menu): Likewise.
3869 (get_and_remove_first_entry_number): New function.
3870 (grub_menu_execute_with_fallback): Likewise.
3871 (get_entry): Renamed to ...
3872 (grub_menu_get_entry): .. this and made it global.
3873 (get_timeout): Renamed to ...
3874 (grub_menu_get_timeout): ... this and made it global.
3875 (set_timeout): Renamed to ...
3876 (grub_menu_set_timeout): ... this and made it global.
3877 (grub_normal_terminal_menu_viewer): Renamed to ...
3878 (grub_normal_text_menu_viewer): ... this.
3880 * normal/menu_text.c: New file. Extracted text-menu-specific code
3883 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add `normal/menu_text.c'.
3884 (normal_mod_SOURCES): Likewise.
3886 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
3887 (normal_mod_SOURCES): Likewise.
3889 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3890 (normal_mod_SOURCES): Likewise.
3892 * conf/i386-pc.rmk, (grub_emu_SOURCES): Likewise.
3893 (normal_mod_SOURCES): Likewise.
3895 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3896 (normal_mod_SOURCES): Likewise.
3898 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3899 (normal_mod_SOURCES): Likewise.
3901 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
3902 (normal_mod_SOURCES): Likewise.
3904 2009-02-11 Robert Millan <rmh@aybabtu.com>
3906 * util/grub.d/00_header.in: Update old reference to `font' command.
3908 2009-02-10 Felix Zielcke <fzielcke@z-51.de>
3910 * fs/fat.c (grub_fat_mount): Fix wrong comparison.
3912 Based on patch from Javier MartÃn.
3914 2009-02-09 Felix Zielcke <fzielcke@z-51.de>
3916 * conf/common.rmk (grub_probe_SOURCES): Move fs/ext2.c before fs/fat.c
3917 to avoid false positives with FAT.
3918 (grub_fstest_SOURCES): Likewise.
3919 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
3920 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
3921 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3922 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
3923 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3924 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3926 2009-02-09 Felix Zielcke <fzielcke@z-51.de>
3928 * fs/fat.c (grub_fat_mount): Try to avoid false positives by checking
3929 bpb.version_specific.fat12_or_fat16.fstype and
3930 bpb.version_specific.fat32.fstype.
3932 2009-02-08 Robert Millan <rmh@aybabtu.com>
3934 * fs/tar.c: Replace "fs/cpio.c" with "cpio.c".
3936 2009-02-08 Robert Millan <rmh@aybabtu.com>
3938 * Makefile.in (host_os, host_cpu): New variables.
3939 (target_os): Remove. Update all users.
3941 2009-02-08 Marco Gerards <marco@gnu.org>
3943 * Makefile.in (enable_grub_emu_usb): New variable.
3944 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/scsi.c'.
3945 (grub_emu_SOURCES) [grub_emu_SOURCES]: Add `disk/usbms.c',
3946 `util/usb.c', `bus/usb/usb.c' and `commands/usbtest.c'.
3947 (grub_emu_LDFLAGS): Add `$(LIBUSB)'.
3948 (pkglib_MODULES): Add `usb.mod', `uhci.mod', `ohci.mod',
3949 `usbtest.mod' and `usbms.mod'.
3950 (usb_mod_SOURCES, usb_mod_CFLAGS, usb_mod_LDFLAGS)
3951 (usbtest_mod_SOURCES, usbtest_mod_CFLAGS, usbtest_mod_LDFLAGS)
3952 (uhci_mod_SOURCES, uhci_mod_CFLAGS, uhci_mod_LDFLAGS,
3953 (ohci_mod_SOURCES, ohci_mod_CFLAGS, ohci_mod_LDFLAGS)
3954 (usbms_mod_SOURCES, usbms_mod_CFLAGS, usbms_mod_LDFLAGS): New
3957 * disk/usbms.c: New file.
3959 * include/grub/usb.h: Likewise.
3961 * include/grub/usbtrans.h: Likewise.
3963 * include/grub/usbdesc.h: Likewise.
3965 * bus/usb/usbtrans.c: Likewise.
3967 * bus/usb/ohci.c: Likewise.
3969 * bus/usb/uhci.c: Likewise.
3971 * bus/usb/usbhub.c: Likewise.
3973 * bus/usb/usb.c: Likewise.
3975 * commands/usbtest.c: Likewise.
3977 * util/usb.c: Likewise.
3979 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_IO'.
3981 * configure.ac: Test for libusb presence.
3983 * util/grub-emu.c (main) [HAVE_LIBUSB_H]: Call `grub_libusb_init'.
3985 2009-02-08 Vesa Jääskeläinen <chaac@nic.fi>
3987 * kern/mm.c: Add more comments.
3989 2009-02-08 Robert Millan <rmh@aybabtu.com>
3991 Patch from Javier MartÃn.
3992 * fs/ext2.c (EXT2_DRIVER_SUPPORTED_INCOMPAT): Add
3993 `EXT4_FEATURE_INCOMPAT_FLEX_BG'.
3995 2009-02-08 Robert Millan <rmh@aybabtu.com>
3997 * fs/cpio.c: Split tar functionality to ...
3998 * fs/tar.c: ... here (new file). Update all users.
4000 2009-02-07 Robert Millan <rmh@aybabtu.com>
4002 * fs/ext2.c (grub_ext2_mount): Avoid mounting filesystems with
4003 backward-incompatible features.
4005 Based on patch from Javier MartÃn, with some adjustments.
4007 2009-02-07 Michael Scherer <misc@mandriva.org>
4009 * fs/hfs.c (grub_hfsplus_iterate_dir): Treat hfs+ as case insensitive.
4011 2009-02-07 Robert Millan <rmh@aybabtu.com>
4013 * conf/common.rmk (grub_probe_SOURCES, grub_fstest_SOURCES): Move
4014 position of `disk/lvm.c' to ensure grub_init_all() always picks it
4015 after the RAID stuff.
4017 2009-02-05 Vesa Jääskeläinen <chaac@nic.fi>
4019 Fixes problem when running vbetest command as reported by
4020 Vladimir Serbinenko <phcoder@gmail.com>.
4022 * (grub_vbe_set_video_mode): Fixed problem with text modes.
4024 2009-02-04 Felix Zielcke <fzielcke@z-51.de>
4026 util/getroot.c (grub_util_get_grub_dev): Add support for /dev/mdNpN and
4027 /dev/md/NpN style mdraid devices.
4029 2009-02-03 Felix Zielcke <fzielcke@z-51.de>
4031 * util/unifont2pff.rb: Remove.
4033 2009-02-03 Felix Zielcke <fzielcke@z-51.de>
4035 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add a missing trailing
4038 2009-02-03 Felix Zielcke <fzielcke@z-51.de>
4040 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/menu_viewer.c'.
4041 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
4042 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
4043 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
4044 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
4045 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
4046 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
4048 2009-02-02 Christian Franke <franke@computer.org>
4050 * lib/hexdump.c (hexdump): Print at most 3 lines if data is identical.
4052 2009-02-01 Felix Zielcke <fzielcke@z-51.de>
4054 * INSTALL: Note that we now require at least autoconf 2.59 and
4055 that LZO is optional.
4057 2009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
4059 Base on patch on bug #24154 created by Tomas Tintera
4062 * video/i386/pc/vbe.c (grub_video_vbe_scroll): Fix downward scrolling.
4064 2009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
4066 Based on patch on bug #25318 created by Bernhard Rosenkraenzer
4067 <bero@arklinux.org>.
4069 * normal/parser.y (script_init): Add missing semicolon.
4071 2009-01-31 Colin D Bennett <colin@gibibit.com>
4073 * normal/main.c: Add include to grub/menu_viewer.h.
4074 (free_menu_entry_classes): Added.
4075 (grub_normal_menu_addentry): Added class property handling.
4076 (grub_normal_execute): Changed to use new menu viewer for menu viewing.
4077 (GRUB_MOD_INIT(normal)): Added register for text based menu viewer.
4079 * normal/menu_viewer.c: New file.
4081 * normal/menu.c (run_menu_entry): Renamed to ...
4082 (grub_menu_execute_entry): ... this and made it as global.
4083 (grub_menu_run): Renamed to ...
4084 (show_text_menu): ... this and made it local.
4085 (show_text_menu): Adapt to new function names.
4086 (grub_normal_terminal_menu_viewer): New global variable.
4088 * include/grub/menu.h: New file.
4090 * include/grub/menu_viewer.h: New file.
4092 * include/grub/normal.h: Added include to grub/menu.h.
4093 (grub_menu_entry): Moved to include/grub/menu.h.
4094 (grub_menu_entry_t): Likewise.
4095 (grub_menu): Likewise.
4096 (grub_menu_t): Likewise.
4097 (grub_normal_terminal_menu_viewer): Added.
4098 (grub_menu_execute_entry): Likewise.
4099 (grub_menu_run): Removed.
4101 * DISTLIST: Added include/grub/menu.h.
4102 Added include/grub/menu_viewer.h.
4103 Added normal/menu_viewer.c.
4105 2009-01-31 Vesa Jääskeläinen <chaac@nic.fi>
4107 * normal/execute.c (grub_script_execute_menuentry): Changed to use
4108 arglist for menutitle arguments.
4110 * normal/main.c (grub_normal_menu_addentry): Likewise.
4112 * normal/parser.y (menuentry): Likewise.
4114 * normal/script.c (grub_script_create_cmdmenu): Likewise.
4116 * include/grub/script.h (grub_script_cmd_menuentry): Likewise.
4117 (grub_script_create_cmdmenu): Likewise.
4119 * include/grub/normal.h (grub_normal_menu_addentry): Likewise.
4121 * conf/i386-pc.rmk (normal_mod_SOURCES): Adapt Colin D Bennett's
4124 * conf/x86_64-efi.rmk (normal_mod_SOURCES): Likewise.
4126 * conf/i386-coreboot.rmk (normal_mod_SOURCES): Likewise.
4128 * conf/i386-efi.rmk (normal_mod_SOURCES): Likewise.
4130 * conf/i386-ieee1275.rmk (normal_mod_SOURCES): Likewise.
4132 * conf/powerpc-ieee1275.rmk (normal_mod_SOURCES): Likewise.
4134 * conf/sparc64-ieee1275.rmk (normal_mod_SOURCES): Likewise.
4136 2009-01-30 Christian Franke <franke@computer.org>
4138 * normal/arg.c (grub_arg_show_help): Add indentation if '\n' appears
4139 in option help text.
4141 2009-01-27 Pavel Roskin <proski@gnu.org>
4143 * disk/fs_uuid.c (search_fs_uuid): Ignore case of the UUID.
4145 2009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
4147 * commands/lsmmap.c: Add include to grub/machine/memory.h.
4149 * fs/i386/pc/pxe.c (grub_pxefs_open): Fix sign problem.
4151 * term/i386/pc/at_keyboard.c (GRUB_MOD_FINI(at_keyboard)): Use proper
4152 unregister function.
4154 2009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
4156 * disk/scsi.c (grub_scsi_read): Fix sign problem.
4158 * term/i386/pc/vga_text.c (grub_vga_text_init_fini). Fix declaration.
4160 * util/grub-mkfont.c (usage): Fix typo.
4162 * util/elf/grub-mkimage.c (load_modules): Fix warning.
4164 2009-01-26 Daniel Mierswa <impulze@impulze.org>
4166 * fs/fat.c (grub_fat_uuid): Fix shift of the first two bytes.
4168 * commands/search.c (search_fs_uuid): Ignore case of the UUID.
4170 * kern/misc.c (grub_strcasecmp): New function.
4171 (grub_strcasecmp): Use grub_size_t instead of int for length.
4173 * include/grub/misc.h: Update function prototypes.
4175 2009-01-26 Robert Millan <rmh@aybabtu.com>
4177 * configure.ac: Fix cross-compilation check.
4179 2009-01-22 Christian Franke <franke@computer.org>
4181 * kern/misc.c (grub_vsprintf): Fix size and termination of `format2'
4182 (precision) digit string. Allow `.format2' without `format1' (width).
4183 Limit input chars for `%s' output to `format2' if specified. This is
4184 compatible with standard printf ().
4186 2009-01-22 Christian Franke <franke@computer.org>
4188 * disk/ata.c (grub_ata_wait_status): Replace by ...
4189 (grub_ata_wait_not_busy): ... this function. Checks only BSY bit,
4190 other status bits may be invalid while BSY is asserted.
4191 (grub_ata_check_ready): New function.
4192 (grub_ata_cmd): Removed.
4193 (grub_ata_wait_drq): New function.
4194 (grub_ata_strncpy): Remove inline.
4195 (grub_ata_pio_read): Reduce to actual block transfer. BSY wait
4196 and error check now done by grub_ata_wait_drq ().
4197 (grub_ata_pio_write): Likewise.
4198 (grub_atapi_identify): Set DEV before check for !BSY. Use
4199 grub_ata_wait_drq () to wait for data.
4200 (grub_ata_device_initialize): Add status register check to
4201 detect missing SATA slave devices. Add debug messages.
4202 (grub_atapi_wait_drq): Use grub_ata_wait_not_busy ().
4203 (grub_atapi_packet): Set DEV before check for !BSY. Replace
4204 transfer loop by grub_ata_pio_write ().
4205 (grub_ata_identify): Set DEV before check for !BSY. Use
4206 grub_ata_wait_drq () to wait for data.
4207 (grub_ata_setaddress): Set DEV before check for !BSY.
4208 (grub_ata_readwrite): Remove duplicate code, handle batch/rest and
4209 read/write in one loop. Fix invalid command on write. Fix incomplete
4210 command on (size % batch) == 0. Add missing error check after write of
4211 last block. Add debug messages.
4212 (grub_atapi_read): Replace transfer loop by grub_ata_pio_read ().
4214 2009-01-19 Christian Franke <franke@computer.org>
4216 * disk/ata.c (GRUB_ATAPI_REG_*): New defines.
4217 (GRUB_ATAPI_IREASON_*): Likewise.
4218 (grub_ata_pio_write): Fix timeout error return.
4219 (grub_atapi_identify): Add grub_ata_wait () after cmd.
4220 (grub_atapi_wait_drq): New function.
4221 (grub_atapi_packet): New parameter `size'.
4222 Use grub_atapi_wait_drq () and direct write instead of
4223 grub_ata_pio_write ().
4224 (grub_atapi_read): Replace grub_ata_pio_read () by a loop which
4225 reads the number of bytes requested by the device for each DRQ
4227 (grub_atapi_write): Remove old implementation, return not
4228 implemented instead.
4230 2009-01-19 Christian Franke <franke@computer.org>
4232 * disk/scsi.c (grub_scsi_read10): Use scsi->blocksize instead
4233 of 512 to calculate data size.
4234 (grub_scsi_read12): Likewise.
4235 (grub_scsi_write10): Likewise.
4236 (grub_scsi_write12): Likewise.
4237 (grub_scsi_read): Adjust size according to blocksize.
4238 Add checks for invalid blocksize and unaligned transfer.
4240 2009-01-19 Vesa Jääskeläinen <chaac@nic.fi>
4242 * font/font.c (grub_font_loader_init): Re-position unknown glyph.
4244 * term/gfxterm.c (write_char): Fix background rendering for wide
4247 2009-01-19 Robert Millan <rmh@aybabtu.com>
4249 * config.guess: Update to latest version from config git.
4250 * config.sub: Likewise.
4252 2009-01-17 Felix Zielcke <fzielcke@z-51.de>
4254 * Makefile.in: Change font compilation to use new grub-mkfont instead
4257 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: Remove.
4258 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
4259 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
4260 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
4261 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
4262 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
4263 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
4264 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
4265 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
4267 2009-01-16 Christian Franke <franke@computer.org>
4269 * disk/ata.c (enum grub_ata_commands): Remove EXEC_DEV_DIAGNOSTICS.
4270 (enum grub_ata_timeout_milliseconds): New enum.
4271 (grub_ata_wait_status): Add parameter milliseconds.
4272 (grub_ata_cmd): Remove variable `err'. Remove wait for !DRQ to allow
4273 recovery from timed-out commands.
4274 (grub_ata_pio_read): Add parameter milliseconds. Fix error return,
4275 return grub_errno instead of REG_ERROR.
4276 (grub_ata_pio_write): Add parameter milliseconds.
4277 (grub_atapi_identify): Fix size of ATAPI IDENTIFY sector.
4278 Pass milliseconds to grub_ata_wait_status () and
4279 grub_ata_pio_read ().
4280 (grub_atapi_packet): Pass milliseconds to grub_ata_pio_write ().
4281 (grub_ata_identify): Remove variable `ataerr'. Pass milliseconds to
4282 grub_ata_wait_status (). Fix IDENTIFY timeout check.
4283 (grub_ata_device_initialize): Remove EXECUTE DEVICE DIAGNOSTICS.
4284 It is not suitable for device detection, because DEV bit is ignored,
4285 the command may run too long, and not all devices set the signature
4287 (grub_ata_pciinit): Clear grub_errno before grub_ata_device_initialize ().
4288 (grub_ata_setaddress): Pass milliseconds to grub_ata_wait_status ().
4289 Fix device selection, DEV bit must be set first to address the registers
4290 of the correct device.
4291 (grub_ata_readwrite): Pass milliseconds to grub_ata_wait_status () and
4292 grub_ata_pio_read/write ().
4293 (grub_atapi_read): Pass milliseconds to grub_ata_pio_read ().
4294 (grub_atapi_write): Pass milliseconds to grub_ata_pio_write ().
4296 2009-01-13 Carles Pina i Estany <carles@pina.cat>
4298 * util/grub-editenv.c (main): Use fseeko(), not fseek().
4300 2009-01-13 Bean <bean123ch@gmail.com>
4302 * util/grub-mkfont.c (write_font): forget to remove some debug code.
4304 2009-01-13 Bean <bean123ch@gmail.com>
4306 * Makefile.in: (enable_grub_mkfont): New variable.
4307 (freetype_cflags): Likewise.
4308 (freetype_libs): Likewise.
4310 * common.rmk (bin_UTILITIES): Add `grub-mkfont' if requested.
4311 (grub_mkfont_SOURCES): New variable.
4312 (grub_mkfont_CFLAGS): Likewise.
4313 (grub_mkfont_LDFLAGS): Likewise.
4315 * configure.ac (--enable-grub-mkfont): New option. Check for freetype2
4316 library if `--enable-grub-mkfont' is requested.
4317 (enable_grub_mkfont): New variable.
4318 (freetype_cflags): Likewise.
4319 (freetype_libs): Likewise.
4321 * util/grub-mkfont.c: New file.
4323 2009-01-12 Christian Franke <franke@computer.org>
4325 * disk/ata.c (grub_ata_pciinit): Fix bit numbers of compatibility
4326 mode check. Fix setting of compat_use[].
4328 2009-01-10 Robert Millan <rmh@aybabtu.com>
4330 Update a few copyright years which we forgot to do in 2008 (only for
4331 files whose changes made in 2008 were copyright-significant)
4333 * Makefile.in: Add 2008 to Copyright line.
4334 * disk/ieee1275/ofdisk.c: Likewise.
4335 * disk/efi/efidisk.c: Likewise.
4336 * kern/dl.c: Likewise.
4337 * kern/sparc64/ieee1275/init.c: Likewise.
4338 * kern/mm.c: Likewise.
4339 * kern/efi/mm.c: Likewise.
4340 * boot/i386/pc/boot.S: Likewise.
4341 * genfslist.sh: Likewise.
4342 * fs/iso9660.c: Likewise.
4343 * fs/hfs.c: Likewise.
4344 * fs/jfs.c: Likewise.
4345 * fs/minix.c: Likewise.
4346 * fs/ufs.c: Likewise.
4347 * gensymlist.sh.in: Likewise.
4348 * genkernsyms.sh.in: Likewise.
4349 * include/grub/misc.h: Likewise.
4350 * include/grub/types.h: Likewise.
4351 * include/grub/symbol.h: Likewise.
4352 * include/grub/elf.h: Likewise.
4353 * include/grub/kernel.h: Likewise.
4354 * include/grub/disk.h: Likewise.
4355 * include/grub/dl.h: Likewise.
4356 * include/grub/i386/linux.h: Likewise.
4357 * include/grub/i386/pc/biosdisk.h: Likewise.
4358 * include/grub/efi/api.h: Likewise.
4359 * include/grub/efi/pe32.h: Likewise.
4360 * include/grub/util/misc.h: Likewise.
4361 * normal/execute.c: Likewise.
4362 * normal/arg.c: Likewise.
4363 * normal/completion.c: Likewise.
4364 * normal/lexer.c: Likewise.
4365 * normal/parser.y: Likewise.
4366 * normal/misc.c: Likewise.
4367 * commands/i386/pc/vbeinfo.c: Likewise.
4368 * commands/hexdump.c: Likewise.
4369 * commands/terminal.c: Likewise.
4370 * commands/ls.c: Likewise.
4371 * commands/help.c: Likewise.
4372 * partmap/pc.c: Likewise.
4373 * loader/efi/chainloader.c: Likewise.
4374 * loader/multiboot_loader.c: Likewise.
4375 * loader/i386/pc/multiboot2.c: Likewise.
4376 * term/efi/console.c: Likewise.
4377 * term/i386/pc/serial.c: Likewise.
4378 * util/lvm.c: Likewise.
4379 * util/console.c: Likewise.
4380 * util/i386/efi/grub-mkimage.c: Likewise.
4381 * util/raid.c: Likewise.
4383 2009-01-06 Vesa Jääskeläinen <chaac@nic.fi>
4385 * commands/videotest.c: Removed include to grub/machine/memory.h.
4387 * conf/i386-pc.rmk (pkglib_MODULES): Removed video.mod, gfxterm.mod,
4388 videotest.mod, bitmap.mod, tga.mod, jpeg.mod, png.mod.
4389 (video_mod_SOURCES): Removed.
4390 (video_mod_CFLAGS): Likewise.
4391 (video_mod_LDFLAGS): Likewise.
4392 (gfxterm_mod_SOURCES): Likewise.
4393 (gfxterm_mod_CFLAGS): Likewise.
4394 (gfxterm_mod_LDFLAGS): Likewise.
4395 (videotest_mod_SOURCES): Likewise.
4396 (videotest_mod_CFLAGS): Likewise.
4397 (videotest_mod_LDFLAGS): Likewise.
4398 (bitmap_mod_SOURCES): Likewise.
4399 (bitmap_mod_CFLAGS): Likewise.
4400 (bitmap_mod_LDFLAGS): Likewise.
4401 (tga_mod_SOURCES): Likewise.
4402 (tga_mod_CFLAGS): Likewise.
4403 (tga_mod_LDFLAGS): Likewise.
4404 (jpeg_mod_SOURCES): Likewise.
4405 (jpeg_mod_CFLAGS): Likewise.
4406 (jpeg_mod_LDFLAGS): Likewise.
4407 (png_mod_SOURCES): Likewise.
4408 (png_mod_CFLAGS): Likewise.
4409 (png_mod_LDFLAGS): Likewise.
4411 * conf/common.rmk (pkglib_MODULES): Added video.mod, videotest.mod,
4412 bitmap.mod, tga.mod, jpeg.mod, png.mod, font.mod, gfxterm.mod
4413 (video_mod_SOURCES): Added.
4414 (video_mod_CFLAGS): Likewise.
4415 (video_mod_LDFLAGS): Likewise.
4416 (videotest_mod_SOURCES): Likewise.
4417 (videotest_mod_CFLAGS): Likewise.
4418 (videotest_mod_LDFLAGS): Likewise.
4419 (bitmap_mod_SOURCES): Likewise.
4420 (bitmap_mod_CFLAGS): Likewise.
4421 (bitmap_mod_LDFLAGS): Likewise.
4422 (tga_mod_SOURCES): Likewise.
4423 (tga_mod_CFLAGS): Likewise.
4424 (tga_mod_LDFLAGS): Likewise.
4425 (jpeg_mod_SOURCES): Likewise.
4426 (jpeg_mod_CFLAGS): Likewise.
4427 (jpeg_mod_LDFLAGS): Likewise.
4428 (png_mod_SOURCES): Likewise.
4429 (png_mod_CFLAGS): Likewise.
4430 (png_mod_LDFLAGS): Likewise.
4431 (gfxterm_mod_SOURCES): Likewise.
4432 (gfxterm_mod_CFLAGS): Likewise.
4433 (gfxterm_mod_LDFLAGS): Likewise.
4435 * term/gfxterm.c: Removed include to grub/machine/memory.h,
4436 grub/machine/console.h.
4438 2009-01-04 Jerone Young <jerone@gmail.com>
4440 Make on screen instructions clearer
4442 Based on patch created by Jidanni <jidanni@jidanni.org>
4444 * normal/menu.c: print clearer instructions on the screen
4446 2009-01-02 Colin D Bennett <colin@gibibit.com>
4450 Additional changes by Vesa Jääskeläinen <chaac@nic.fi> to adapt to
4451 build system and fixed gfxterm.c to work with different sized fonts.
4453 * configure.ac: Changed UNIFONT_HEX to UNIFONT_BDF.
4455 * configure: Re-generated.
4457 * DISTLIST: Removed font/manager.c.
4459 Added font/font_cmd.c.
4461 * Makefile.in: Changed UNIFONT_HEX to UNIFONT_BDF. Added Font tool
4464 * include/grub/misc.h (grub_utf8_to_ucs4): Changed prototype. Changed users.
4466 * kern/misc.c (grub_utf8_to_ucs4): Changed prototype.
4468 * kern/term.c: Changed users of grub_utf8_to_ucs4.
4470 * normal/menu.c: Likewise.
4472 * conf/common.rmk (font_mod_SOURCES): Removed font/manager.c.
4473 (font_mod_SOURCES): Added font/font_cmd.c, font/font.c.
4475 * include/grub/font.h: Replaced with new file.
4477 * include/grub/video.h (GRUB_VIDEO_MODE_TYPE_ALPHA): Changed value.
4478 (GRUB_VIDEO_MODE_TYPE_DOUBLE_BUFFERED): Likewise.
4479 (GRUB_VIDEO_MODE_TYPE_COLOR_MASK): Likewise.
4480 (GRUB_VIDEO_MODE_TYPE_1BIT_BITMAP): Added.
4481 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_1BIT_PACKED.
4482 (grub_video_mode_info): Added bg_red, bg_green, bg_blue, bg_alpha,
4483 fg_red, fg_green, fg_blue, fg_alpha.
4484 (grub_video_adapter): Removed blit_glyph.
4485 (grub_video_blit_glyph): Removed.
4487 * font/manager.c: Removed file.
4489 * font/font.c: New file.
4491 * font/font_cmd.c: Likewise.
4493 * video/video.c (grub_video_blit_glyph): Removed.
4495 * video/i386/pc/vbe.c (grub_video_vbe_map_rgb): Added 1-bit support.
4496 (grub_video_vbe_map_rgba): Likewise.
4497 (grub_video_vbe_unmap_color_int): Likewise.
4498 (grub_video_vbe_blit_glyph): Removed.
4499 (grub_video_vbe_adapter): Removed blit_glyph.
4501 * video/i386/pc/vbeutil.c (get_data_ptr): Added 1-bit support.
4502 (get_pixel): Likewise.
4503 (set_pixel): Likewise.
4505 * commands/videotest.c (grub_cmd_videotest): Added more tests for fonts.
4507 * term/gfxterm.c: Adapted to new font engine.
4509 * term/i386/pc/vesafb.c: Marked as deprecated. Made it compile.
4511 * term/i386/pc/vga.c: Likewise.
4513 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: New file.
4515 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
4517 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
4519 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
4521 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
4523 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
4525 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
4527 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
4529 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
4531 * util/grub.d/00_header.in: Changed to use new loadfont command.
4533 * util/grub-mkconfig_lib.in: Changed font extension.
4535 2008-12-28 Felix Zielcke <fzielcke@z-51.de>
4537 * util/getroot.c (grub_util_get_grub_dev): Add support for
4538 /dev/md/dNNpNN style partitionable mdraid devices.
4540 2008-12-12 Alex Smith <alex@alex-smith.me.uk>
4542 * fs/i386/pc/pxe.c (grub_pxefs_open): Handle the one open connection
4543 at a time limit of the PXE TFTP API correctly.
4544 (grub_pxefs_close): Likewise.
4546 2008-11-29 Robert Millan <rmh@aybabtu.com>
4548 * disk/ata.c (grub_ata_pciinit): Handle errors raised by
4549 grub_ata_device_initialize() calls.
4551 2008-11-28 Krzysztof Smiechowicz <deadwood@wp.pl>
4553 * fs/affs.c (grub_affs_iterate_dir): Return failure when directory
4555 * fs/sfs.c (grub_sfs_iterate_dir): Likewise.
4557 2008-11-28 Robert Millan <rmh@aybabtu.com>
4559 Fix build on powerpc-ieee1275. Based on patch created by
4560 Manoel Abranches <mrabran@linux.vnet.ibm.com>.
4561 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
4562 `kern/ieee1275/mmap.c'.
4563 * include/grub/powerpc/ieee1275/memory.h: New file.
4565 Provide grub-install on coreboot.
4566 * conf/i386-coreboot.rmk (sbin_SCRIPTS): Add `grub-install'.
4567 (grub_install_SOURCES): New variable.
4568 * util/i386/pc/grub-install.in: Add a few condition checks to make it
4571 2008-11-25 Felix Zielcke <fzielcke@z-51.de>
4573 * util/grub-fstest.c (grub_term_get_current_input): Change return type
4574 to `grub_term_input_t'.
4575 (grub_term_get_current_output): Change return type to
4576 `grub_term_output_t'.
4578 2008-11-22 Robert Millan <rmh@aybabtu.com>
4580 Fix breakage on coreboot due to declaration mismatch.
4581 * term/i386/pc/vga_text.c (grub_vga_text_init_fini): New function.
4582 (grub_vga_text_term): Use grub_vga_text_init_fini() instead of
4583 grub_vga_text_cls().
4585 * kern/i386/loader.S (grub_multiboot_backward_relocator): Improve
4586 comments. Avoid copying one more byte than necessary (just in case).
4588 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Change link address
4589 to 0x200000 (avoids trouble with some OFW implementations, and matches
4590 with the one in Yaboot).
4591 Reported by Manoel Abranches
4593 2008-11-20 Robert Millan <rmh@aybabtu.com>
4595 * kern/i386/coreboot/init.c (grub_time_tics): Remove variable.
4596 (grub_get_rtc, grub_exit): Abort with grub_fatal() if called.
4598 * util/grub-mkconfig_lib.in (grub_warn): New function.
4599 (convert_system_path_to_grub_path): Use grub_warn() when issuing
4600 warnings, to obtain consistent formatting.
4601 * util/grub.d/00_header.in: Likewise.
4602 * util/update-grub_lib.in: Likewise.
4604 * loader/i386/linux.c (allocate_pages): Fix a warning.
4605 Move comment text to `#error' stanza.
4607 Harmonize ieee1275's grub_available_iterate() with the generic
4608 grub_machine_mmap_iterate() interface (fixes a recently-introduced
4609 build problem on i386-ieee1275):
4610 * kern/ieee1275/openfw.c (grub_available_iterate): Moved from here ...
4611 * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): ... here. Add third
4612 parameter `type'. Update all users of this function.
4613 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
4614 `kern/ieee1275/mmap.c'.
4615 * kern/ieee1275/init.c
4616 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): Replace
4618 (grub_machine_mmap_iterate): ... this.
4619 * include/grub/i386/pc/memory.h (grub_machine_mmap_iterate): Change
4620 return type to `grub_err_t'. Update all implementations of this
4622 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_iterate):
4625 Add `lsmmap' command (lists firmware-provided memory map):
4626 * commands/lsmmap.c: New file.
4627 * conf/i386-pc.rmk (pkglib_MODULES): Add `lsmmap.mod'.
4628 (lsmmap_mod_SOURCES, lsmmap_mod_CFLAGS, lsmmap_mod_LDFLAGS): New
4630 * conf/powerpc-ieee1275.rmk: Likewise.
4631 * conf/i386-coreboot.rmk: Likewise.
4632 * conf/i386-ieee1275.rmk: Likewise.
4634 2008-11-19 Robert Millan <rmh@aybabtu.com>
4636 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Fix a typo.
4637 * loader/i386/linux.c (grub_rescue_cmd_initrd): Implement a few needed
4638 constraints to initrd allocation (based on code from
4639 loader/i386/pc/linux.c). Without them, initrd was allocated too high
4640 for Linux to find it.
4642 2008-11-14 Robert Millan <rmh@aybabtu.com>
4644 * fs/cpio.c (grub_cpio_open): Compare `name' and `fn' by hand in
4645 order to cope with duplicate slashes.
4647 2008-11-14 Robert Millan <rmh@aybabtu.com>
4649 * include/grub/i386/coreboot/memory.h (GRUB_MEMORY_MACHINE_LOWER_SIZE):
4650 Redefine to match with GRUB_MEMORY_MACHINE_UPPER_START (0x100000). We
4651 don't want to mess with lower memory, because it is used in the Linux
4654 * loader/i386/linux.c (allocate_pages): Allocate `real_mode_mem' in
4655 an appropriate place in lower memory, between 0x10000 and 0x90000,
4656 like loader/i386/efi/linux.c does. Linux often panics if real_mode_mem
4657 is in our heap (probably as a result of it being corrupted during
4658 decompression). Add #error instance with comment to explain why this
4659 loader isn't currently usable on PC/BIOS.
4661 2008-11-14 Robert Millan <rmh@aybabtu.com>
4663 * term/i386/pc/serial.c [! GRUB_MACHINE_PCBIOS]
4664 (GRUB_SERIAL_PORT_NUM): Fix miscalculation.
4666 2008-11-12 Robert Millan <rmh@aybabtu.com>
4668 Make loader/i386/linux.c buildable on i386-pc (although disabled).
4670 * include/grub/i386/pc/init.h: Include `<grub/machine/memory.h>'.
4671 (struct grub_machine_mmap_entry, grub_machine_mmap_iterate): Move
4673 * include/grub/i386/pc/memory.h: ... to here.
4675 2008-11-12 Robert Millan <rmh@aybabtu.com>
4677 Fix build problems on i386-ieee1275 and *-efi (introduced by vga_text
4680 * include/grub/i386/pc/console.h: Include `<grub/i386/vga_common.h>'.
4681 (grub_console_cur_color, grub_console_real_putchar)
4682 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
4683 (grub_console_setcolorstate, grub_console_setcolor)
4684 (grub_console_getcolor): Move from here ...
4685 * include/grub/i386/vga_common.h: ... to here (new file).
4687 * term/i386/pc/vga_text.c: Replace `<grub/machine/console.h>' with
4688 `<grub/i386/vga_common.h>' and `<grub/cpu/io.h>' with
4690 * term/i386/vga_common.c: Replace `<grub/machine/console.h>' with
4691 `<grub/i386/vga_common.h>'.
4693 2008-11-12 Robert Millan <rmh@aybabtu.com>
4695 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `term/i386/vga_common.c'.
4696 * conf/i386.rmk (pkglib_MODULES): Add `vga_text.mod'.
4697 (vga_text_mod_SOURCES, vga_text_mod_CFLAGS, vga_text_mod_LDFLAGS): New
4699 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
4700 `term/i386/pc/console.c' with `term/i386/vga_common.c'.
4702 * kern/i386/coreboot/init.c (grub_machine_init): Replace call to
4703 grub_console_init() with call to grub_vga_text_init().
4704 (grub_machine_fini): Replace call to
4705 grub_console_fini() with call to grub_vga_text_fini() and
4706 grub_at_keyboard_fini().
4708 * include/grub/i386/pc/console.h: Include `<grub/term.h>'.
4709 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
4710 (grub_console_setcolorstate, grub_console_setcolor)
4711 (grub_console_getcolor): New function prototypes.
4713 * term/i386/pc/vga_text.c: Include `<grub/dl.h>'.
4714 (grub_vga_text_getxy, grub_vga_text_gotoxy, grub_vga_text_cls)
4715 (grub_vga_text_setcursor): Static-ize.
4716 (grub_vga_text_term): New structure.
4717 (GRUB_MOD_INIT(vga_text), GRUB_MOD_FINI(vga_text)): New functions.
4719 * term/i386/pc/console.c: Remove `<grub/machine/machine.h>'.
4720 (grub_console_cur_color, grub_console_standard_color)
4721 (grub_console_normal_color, grub_console_highlight_color)
4722 (map_char, grub_console_putchar, grub_console_getcharwidth)
4723 (grub_console_getwh, grub_console_setcolorstate, grub_console_setcolor)
4724 (grub_console_getcolor): Move from here ...
4725 * term/i386/vga_common.c: ... to here (same function names).
4727 2008-11-12 Robert Millan <rmh@aybabtu.com>
4729 Use newly-added Multiboot support in coreboot.
4731 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
4732 `kern/i386/coreboot/mmap.c' with `kern/i386/multiboot_mmap.c'.
4734 * kern/i386/coreboot/startup.S: Enable Multiboot header, fix its
4735 alignment, set `MULTIBOOT_MEMORY_INFO' flag.
4736 (codestart): Store the MBI in `startup_multiboot_info' when we're
4737 being loaded using Multiboot.
4739 * kern/i386/coreboot/init.c (grub_machine_init): Move
4740 grub_at_keyboard_init() call to beginning of function (useful for
4741 debugging). Call grub_machine_mmap_init() before attempting to use
4742 grub_machine_mmap_iterate().
4743 (grub_lower_mem, grub_upper_mem): Move from here ...
4744 * kern/i386/multiboot_mmap.c (grub_lower_mem, grub_upper_mem): ... to
4747 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_init): New
4750 2008-11-12 Robert Millan <rmh@aybabtu.com>
4752 Fix a regression introduced by the at_keyboard.mod split. Because
4753 some terminals are default on some platforms and non-default on
4754 others, the first terminal being registered determines which is
4755 going to be default.
4757 * kern/term.c (grub_term_register_input): If this is the first
4758 terminal being registered, set it as the current one.
4759 (grub_term_register_output): Likewise.
4761 * term/efi/console.c (grub_console_init): Do not call
4762 grub_term_set_current_output() or grub_term_set_current_input().
4763 * term/ieee1275/ofconsole.c (grub_console_init): Likewise.
4764 * term/i386/pc/console.c (grub_console_init): Likewise.
4765 (grub_console_fini): Do not call grub_term_set_current_input()
4766 (but leave grub_term_set_current_output() to restore text mode).
4768 2008-11-10 Robert Millan <rmh@aybabtu.com>
4770 * util/grub.d/00_header.in: Add backward compatibility check for
4771 versions of terminal.mod that don't understand `terminal_input' or
4774 2008-11-09 Robert Millan <rmh@aybabtu.com>
4776 * commands/terminal.c (GRUB_MOD_FINI(terminal)): Unregister
4777 `terminal_input' / `terminal_output', not `terminal'.
4779 2008-11-08 Robert Millan <rmh@aybabtu.com>
4781 * Makefile.in (include_DATA): Fix srcdir=. assumption.
4782 (DISTCLEANFILES): Add `build_env.mk'.
4784 2008-11-08 Robert Millan <rmh@aybabtu.com>
4786 * term/i386/pc/vesafb.c (grub_vesafb_term): Change type to
4787 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
4788 members. Update all users.
4789 * util/console.c (grub_ncurses_term): Split in ...
4790 (grub_ncurses_term_input): ... this, and ...
4791 (grub_ncurses_term_output): ... this. Update all users.
4792 * term/ieee1275/ofconsole.c: Remove stale `#endif'.
4794 2008-11-08 Robert Millan <rmh@aybabtu.com>
4796 * Makefile.in (PKGLIB): Add $(pkglib_BUILDDIR).
4797 (PKGDATA): Add $(pkgdata_SRCDIR).
4798 (pkglib_BUILDDIR): New variable.
4799 (pkgdata_SRCDIR): New variable.
4800 (build_env.mk): New target.
4801 (include_DATA): New variable.
4802 (install-local): Install $(include_DATA) files in $(includedir).
4804 2008-11-07 Pavel Roskin <proski@gnu.org>
4806 * gendistlist.sh: Use C locale for sorting to ensure consistent
4807 output on all systems.
4809 * util/grub.d/00_header.in: Remove incorrect space before
4812 2008-11-07 Robert Millan <rmh@aybabtu.com>
4814 * include/multiboot2.h (struct multiboot_header): Add `flags' member as
4816 * loader/multiboot2.c (grub_multiboot2): Fix Multiboot2 header check.
4817 * loader/multiboot_loader.c (find_multi_boot2_header): New function
4818 (based on find_multi_boot1_header).
4819 (grub_rescue_cmd_multiboot_loader): Check for Multiboot2 header,
4820 using find_multi_boot2_header(), and abort if neither Multiboot or
4821 Multiboot headers were found.
4823 2008-11-07 Robert Millan <rmh@aybabtu.com>
4825 Modularize at_keyboard.mod:
4827 * conf/i386.rmk (pkglib_MODULES): Add `at_keyboard.mod'.
4828 (at_keyboard_mod_SOURCES, at_keyboard_mod_CFLAGS)
4829 (at_keyboard_mod_LDFLAGS): New variables.
4831 Actual terminal split:
4833 * include/grub/term.h (struct grub_term): Split in ...
4834 (struct grub_term_input): ... this, and ...
4835 (struct grub_term_output): ... this. Update all users.
4836 (grub_term_set_current): Split in ...
4837 (grub_term_set_current_input): ... this, and ...
4838 (grub_term_set_current_output): ... this.
4839 (grub_term_get_current): Split in ...
4840 (grub_term_get_current_input): ... this, and ...
4841 (grub_term_get_current_output): ... this.
4842 (grub_term_register): Split in ...
4843 (grub_term_register_input): ... this, and ...
4844 (grub_term_register_output): ... this.
4845 (grub_term_unregister): Split in ...
4846 (grub_term_unregister_input): ... this, and ...
4847 (grub_term_unregister_output): ... this.
4848 (grub_term_iterate): Split in ...
4849 (grub_term_iterate_input): ... this, and ...
4850 (grub_term_iterate_output): ... this.
4852 * kern/term.c (grub_term_list): Split in ...
4853 (grub_term_list_input): ... this, and ...
4854 (grub_term_list_output): ... this. Update all users.
4855 (grub_cur_term): Split in ...
4856 (grub_cur_term_input): ... this, and ...
4857 (grub_cur_term_output): ... this. Update all users.
4858 (grub_term_set_current): Split in ...
4859 (grub_term_set_current_input): ... this, and ...
4860 (grub_term_set_current_output): ... this.
4861 (grub_term_get_current): Split in ...
4862 (grub_term_get_current_input): ... this, and ...
4863 (grub_term_get_current_output): ... this.
4864 (grub_term_register): Split in ...
4865 (grub_term_register_input): ... this, and ...
4866 (grub_term_register_output): ... this.
4867 (grub_term_unregister): Split in ...
4868 (grub_term_unregister_input): ... this, and ...
4869 (grub_term_unregister_output): ... this.
4870 (grub_term_iterate): Split in ...
4871 (grub_term_iterate_input): ... this, and ...
4872 (grub_term_iterate_output): ... this.
4874 * kern/misc.c (grub_abort): Split use of grub_term_get_current() into
4875 a check for input and one for output (and only attempt to get keys
4876 from user when input works).
4878 * util/grub-probe.c (grub_term_get_current): Split in ...
4879 (grub_term_get_current_input): ... this, and ...
4880 (grub_term_get_current_output): ... this.
4881 * util/grub-fstest.c: Likewise.
4882 * util/i386/pc/grub-setup.c: Likewise.
4883 * util/grub-editenv.c: Likewise.
4885 Portability adjustments:
4887 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Remove
4888 `term/i386/pc/at_keyboard.c'.
4889 * kern/ieee1275/init.c [__i386__] (grub_machine_init): Remove call to
4890 grub_keyboard_controller_init() (now handled by terminal .init).
4891 * kern/i386/coreboot/init.c (grub_machine_init): Add call to
4892 grub_at_keyboard_init().
4893 * include/grub/i386/ieee1275/console.h (grub_keyboard_controller_init)
4894 (grub_console_checkkey, grub_console_getkey): Remove (now provided by
4895 at_keyboard.mod via input terminal interface).
4896 * include/grub/i386/coreboot/console.h: Convert into a stub for
4897 `<grub/i386/pc/console.h>'.
4899 Migrate full terminals to new API:
4901 * term/efi/console.c (grub_console_term): Split into ...
4902 (grub_console_term_input): ... this, and ...
4903 (grub_console_term_output): ... this. Update all users.
4904 * term/ieee1275/ofconsole.c: Remove __i386__ hack.
4905 (grub_ofconsole_init): Split into ...
4906 (grub_ofconsole_init_input): ... this, and ...
4907 (grub_ofconsole_init_output): ... this.
4908 (grub_ofconsole_term): Split into ...
4909 (grub_ofconsole_term_input): ... this, and ...
4910 (grub_ofconsole_term_output): ... this. Update all users.
4911 * term/i386/pc/serial.c (grub_serial_term): Split into ...
4912 (grub_serial_term_input): ... this, and ...
4913 (grub_serial_term_output): ... this. Update all users.
4914 * term/i386/pc/console.c (grub_console_term): Split into ...
4915 (grub_console_term_input): ... this, and ...
4916 (grub_console_term_output): ... this. Update all users.
4917 (grub_console_term_input): Only enable it on PC/BIOS platform.
4918 (grub_console_init): Remove grub_keyboard_controller_init() call.
4920 Migrate input terminals to new API:
4922 * term/i386/pc/at_keyboard.c: Replace `cpu' and `machine' with
4923 `i386' and `i386/pc' to enable build on x86_64 (this driver is
4924 i386-specific anyway).
4925 (grub_console_checkkey): Rename to ...
4926 (grub_at_keyboard_checkkey): ... this. Static-ize. Update all
4928 (grub_keyboard_controller_orig): New variable.
4929 (grub_console_getkey): Rename to ...
4930 (grub_at_keyboard_getkey): ... this. Static-ize. Update all
4932 (grub_keyboard_controller_init): Static-ize. Save original
4933 controller value so that it can be restored ...
4934 (grub_keyboard_controller_fini): ... here (new function).
4935 (grub_at_keyboard_term): New structure.
4936 (GRUB_MOD_INIT(at_keyboard), GRUB_MOD_FINI(at_keyboard)): New
4939 Migrate output terminals to new API:
4941 * term/i386/pc/vga.c (grub_vga_term): Change type to
4942 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
4943 members. Update all users.
4944 * term/gfxterm.c (grub_video_term): Change type to
4945 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
4946 members. Update all users.
4947 * include/grub/i386/pc/console.h (grub_console_checkkey)
4948 (grub_console_getkey): Do not export (no longer needed by gfxterm,
4951 Migrate `terminal' command and userland tools to new API:
4953 * commands/terminal.c (grub_cmd_terminal): Split into ...
4954 (grub_cmd_terminal_input): ... this, and ...
4955 (grub_cmd_terminal_output): ... this.
4956 (GRUB_MOD_INIT(terminal)): Split `terminal' command in two commands:
4957 `terminal_input' and `terminal_output'.
4958 * util/grub.d/00_header.in: Adjust `terminal' calls to new
4959 `terminal_input' / `terminal_output' API.
4960 * util/grub-mkconfig.in: Export ${GRUB_TERMINAL_INPUT} and
4961 ${GRUB_TERMINAL_OUTPUT} instead of ${GRUB_TERMINAL} (and if user
4962 provided ${GRUB_TERMINAL}, convert it).
4964 2008-11-04 Robert Millan <rmh@aybabtu.com>
4966 * util/grub.d/10_freebsd.in: New file. Generate grub configuration
4968 * conf/common.rmk (grub-mkconfig_SCRIPTS): Add 10_freebsd.
4970 2008-11-03 Bean <bean123ch@gmail.com>
4972 * kern/elf.c (grub_elf32_load): Revert to previous code.
4973 (grub_elf64_load): Likewise.
4975 * loader/i386/bsd.c (grub_bsd_elf32_hook): Change return address.
4977 2008-11-01 Robert Millan <rmh@aybabtu.com>
4979 * Makefile.in (CPPFLAGS): Fix builddir=. assumption.
4980 (TARGET_CPPFLAGS): Likewise.
4981 * genmk.rb (mod_src): Fix builddir=. and srcdir=. assumptions.
4983 2008-11-01 Carles Pina i Estany <carles@pina.cat>
4985 * normal/menu.c (run_menu): Add Previous and Next Page keys in menu.
4987 2008-10-29 Guillem Jover <guillem.jover@nokia.com>
4989 * disk/lvm.c (grub_lvm_scan_device): Fix error recovery by delaying the
4990 addition of objects until the code is not going to be able to fail.
4992 2008-10-29 Guillem Jover <guillem.jover@nokia.com>
4994 * disk/lvm.c (grub_lvm_scan_device): Fix possible NULL value handling
4995 (add a missing NULL check, and correct them by moving the pointer
4996 operations after the actual check).
4998 2008-10-29 Robert Millan <rmh@aybabtu.com>
5000 * util/i386/pc/grub-install.in: Handle empty string as output from
5001 make_system_path_relative_to_its_root().
5003 2008-10-05 Hans Lambermont <hans@lambermont.dyndns.org>
5005 * disk/lvm.c (grub_lvm_scan_device): Allocate buffer space for the
5006 circular metadata worst case scenario. If the metadata is circular
5007 then copy the wrap in place.
5008 * include/grub/lvm.h: Add GRUB_LVM_MDA_HEADER_SIZE, from the LVM2
5009 project lib/format_text/layout.h
5010 Circular metadata bug found and patch debugged by Jan Derk Gerlings.
5012 2008-10-03 Felix Zielcke <fzielcke@z-51.de>
5014 * util/i386/pc/grub-install.in: Source grub-mkconfig_lib instead of update-grub_lib.
5016 2008-10-03 Felix Zielcke <fzielcke@z-51.de>
5018 * util/update-grub_lib.in: Mention filename in warning message.
5020 2008-09-29 Felix Zielcke <fzielcke@z-51.de>
5022 * NEWS: Update for rename of update-grub to grub-mkconfig.
5024 2008-09-29 Felix Zielcke <fzielcke@z-51.de>
5026 * util/update-grub_lib.in: Copy to ...
5027 * util/grub-mkconfig_lib.in: ... this. Update all users.
5028 * util/update-grub_lib.in: Make it a stub to `grub-mkconfig_lib.in'.
5029 * util/update-grub.in: Rename to ...
5030 * util/grub-mkconfig.in: ... this. Update all users. Remove `-y'
5031 option. Add `--output' option to allow users to specify the generated
5032 configuration file. Default to stdout.
5033 (update_grub_dir): Rename to ...
5034 (grub_mkconfig_dir): ... this.
5035 (grub_cfg): Default to an empty string.
5036 * conf/common.rmk (update-grub): Rename to ...
5037 (grub-mkconfig): ... this.
5038 (update-grub_lib): Copy to ...
5039 (grub-mkconfig_lib): ... this.
5040 (update-grub_SCRIPTS): Copy to ...
5041 (grub-mkconfig_SCRIPTS): ... this. Update all users.
5042 (update-grub_DATA): Rename to ...
5043 (grub-mkconfig_DATA): ... this.
5045 2008-09-28 Robert Millan <rmh@aybabtu.com>
5047 * fs/iso9660.c (struct grub_iso9660_primary_voldesc): Rename `created'
5048 to `modified'. Add the real `created' field.
5049 (grub_iso9660_uuid): Use `modified' rather than `created' for
5050 constructing the UUID.
5052 2008-09-28 Felix Zielcke <fzielcke@z-51.de>
5054 fs/jfs.c (grub_jfs_find_file): Treat multiple slashes like one.
5055 Based on code from Tomas Ebenlendr <ebik@ucw.cz>.
5057 2008-09-28 Bean <bean123ch@gmail.com>
5059 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a bug in the previous patch.
5060 Thanks to Christian Franke for finding this bug.
5062 2008-09-25 Robert Millan <rmh@aybabtu.com>
5064 * util/grub-mkdevicemap.c (make_device_map): Actually replace all
5065 instances of grub_util_get_disk_name() (see previous commit).
5067 2008-09-25 Robert Millan <rmh@aybabtu.com>
5069 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Remove
5070 `util/i386/get_disk_name.c'.
5071 * conf/i386-efi.rmk: Likewise.
5072 * conf/x86_64-efi.rmk: Likewise.
5073 * conf/i386-coreboot.rmk: Likewise.
5074 * conf/i386-ieee1275.rmk: Likewise.
5075 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Remove
5076 `util/ieee1275/get_disk_name.c'.
5077 * include/grub/util/misc.h (grub_util_get_disk_name): Remove.
5078 * util/ieee1275/get_disk_name.c: Remove file.
5079 * util/i386/get_disk_name.c: Remove file.
5080 * util/grub-mkdevicemap.c (make_device_map): Back to hardcoding
5081 "hd%d" for device.map entries, rather than using
5082 grub_util_get_disk_name().
5084 2008-09-24 Carles Pina i Estany <carles@pina.cat>
5086 * disk/dmraid_nvidia.c (grub_dmraid_nv_detect): Fix `unused parameter'
5088 * commands/i386/pc/pxecmd.c (dmraid_nvidia): Likewise.
5090 2008-09-24 Carles Pina i Estany <carles@pina.cat>
5092 * include/grub/i386/pc/console.h (GRUB_TERM_NPAGE):
5094 (GRUB_TERM_PPAGE): Changed to 0x4900.
5096 2008-09-24 Robert Millan <rmh@aybabtu.com>
5098 * include/grub/powerpc/ieee1275/console.h (GRUB_CONSOLE_KEY_*): Remove
5099 macros (they were i386-pc specific).
5100 * include/grub/sparc64/ieee1275/console.h: Likewise.
5101 * include/grub/efi/console.h: Likewise.
5103 2008-09-22 Bean <bean123ch@gmail.com>
5105 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a rare case where $BITMAP is
5106 resident and in attribute list.
5108 * include/grub/ntfs.h (BMP_LEN): Removed.
5110 2008-09-22 Bean <bean123ch@gmail.com>
5112 * disk/ata.c (grub_atapi_open): Initialize devfnd, no need to set
5113 scsi->name and scsi->luns, as they will be set in grub_scsi_open.
5115 * disk/scsi.c (grub_scsi_open): Don't call p->close (scsi) here when
5116 error occurs, as grub_disk_open will call grub_disk_close, which will
5117 call p->close (scsi).
5119 2008-09-21 Felix Zielcke <fzielcke@z-51.de>
5121 * configure.ac (AC_INIT): Quote `GRUB' string and version number.
5122 (AC_PREREQ): Bumped to 2.59.
5123 (AC_TRY_COMPILE): Replace obsolete macro with ...
5124 (AC_COMPILE_IFELSE): ... this.
5125 * aclocal.m4 (AC_TRY_LINK): Replace obsolete macro with ...
5126 (AC_LINK_IFELSE): ... this.
5128 2008-09-21 Felix Zielcke <fzielcke@z-51.de>
5130 * autogen.sh: Add a call to `gendistlist.sh'.
5132 2008-09-19 Christian Franke <franke@computer.org>
5134 * aclocal.m4 (grub_CHECK_ENABLE_EXECUTE_STACK): New function.
5135 * configure.ac: Call grub_CHECK_ENABLE_EXECUTE_STACK.
5136 * include/grub/misc.h [NEED_ENABLE_EXECUTE_STACK]:
5137 Export __enable_execute_stack() to modules.
5138 * kern/misc.c [NEED_ENABLE_EXECUTE_STACK] (__enable_execute_stack):
5141 2008-09-09 Felix Zielcke <fzielcke@z-51.de>
5143 * Makefile.in (RMKFILES): Add `i386.rmk' and `x86_64-efi.rmk'.
5146 2008-09-09 Felix Zielcke <fzielcke@z-51.de>
5148 * util/hostdisk.c: Replace #include <grub/util/biosdisk.h> with
5149 #include <grub/util/hostdisk.h>.
5151 2008-09-08 Robert Millan <rmh@aybabtu.com>
5153 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Skip
5154 segments when their filesz is zero (grub_file_read() interprets
5155 zero-size as "read until EOF", which results in memory corruption).
5156 Use `lowest_segment' rather than 0 for calculating the current
5157 segment load address.
5159 2008-09-08 Robert Millan <rmh@aybabtu.com>
5161 * util/hostdisk.c (open_device): Replace a grub_util_info() call
5162 with grub_dprintf("hostdisk", ...), as it was so verbose that it
5163 clobbered useful information.
5165 2008-09-08 Robert Millan <rmh@aybabtu.com>
5167 * include/grub/util/biosdisk.h: Move to ...
5168 * include/grub/util/hostdisk.h: ... here. Update all users.
5169 * util/biosdisk.c: Move to ...
5170 * util/hostdisk.c: ... here. Update all users.
5172 2008-09-07 Robert Millan <rmh@aybabtu.com>
5174 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): Remove
5176 (grub_multiboot): Move `mbi' allocation upwards, so that mmap address
5177 and length can be stored directly in the `mbi->mmap_addr' and
5178 `mbi->mmap_length' struct fields.
5180 2008-09-07 Robert Millan <rmh@aybabtu.com>
5182 * conf/i386.rmk: New file. Provides declaration for building
5184 * conf/i386-pc.rmk (pkglib_MODULES): Remove `cpuid.mod'.
5185 (cpuid_mod_SOURCES, cpuid_mod_CFLAGS, cpuid_mod_LDFLAGS): Remove
5187 Include `conf/i386.mk'.
5188 * conf/i386-efi.rmk: Likewise.
5189 * conf/x86_64-efi.rmk: Likewise.
5190 * conf/i386-coreboot.rmk: Likewise.
5191 * conf/i386-ieee1275.rmk: Likewise.
5193 2008-09-07 Vesa Jääskeläinen <chaac@nic.fi>
5195 Based on patch created by Colin D Bennett <colin@gibibit.com>.
5196 Adds optimization support for BGR based modes.
5198 * include/grub/i386/pc/vbeblit.h (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8) Removed.
5199 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
5200 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
5201 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
5202 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
5203 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
5204 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
5205 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
5206 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
5207 (grub_video_i386_vbeblit_index_index): Likewise.
5208 (grub_video_i386_vbeblit_replace_directN): Added.
5209 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
5210 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
5211 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
5212 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
5213 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
5214 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
5215 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
5216 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
5217 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
5218 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
5219 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
5220 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
5221 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
5223 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8) Removed.
5224 (grub_video_i386_vbefill_R8G8B8): Likewise.
5225 (grub_video_i386_vbefill_index): Likewise.
5226 (grub_video_i386_vbefill_direct32): Added.
5227 (grub_video_i386_vbefill_direct24): Likewise.
5228 (grub_video_i386_vbefill_direct16): Likewise.
5229 (grub_video_i386_vbefill_direct8): Likewise.
5231 * include/grub/video.h (grub_video_blit_format): Removed
5232 GRUB_VIDEO_BLIT_FORMAT_R8G8B8A8, GRUB_VIDEO_BLIT_FORMAT_R8G8B8.
5233 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_RGBA_8888,
5234 GRUB_VIDEO_BLIT_FORMAT_BGRA_8888, GRUB_VIDEO_BLIT_FORMAT_RGB_888,
5235 GRUB_VIDEO_BLIT_FORMAT_BGR_888, GRUB_VIDEO_BLIT_FORMAT_RGB_565,
5236 GRUB_VIDEO_BLIT_FORMAT_BGR_565.
5238 * video/video.c (grub_video_get_blit_format): Updated to use new
5239 blit formats. Added handling for 16 bit color modes.
5241 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Updated to use new
5243 (common_blitter): Updated to use new blitters.
5245 * video/i386/pc/vbeblit.c (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8):
5247 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
5248 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
5249 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
5250 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
5251 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
5252 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
5253 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
5254 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
5255 (grub_video_i386_vbeblit_index_index): Likewise.
5256 (grub_video_i386_vbeblit_replace_directN): Added.
5257 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
5258 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
5259 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
5260 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
5261 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
5262 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
5263 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
5264 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
5265 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
5266 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
5267 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
5268 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
5269 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
5271 * video/i386/pc/vbefill.c (grub_video_i386_vbefill_R8G8B8A8): Removed.
5272 (grub_video_i386_vbefill_R8G8B8): Likewise.
5273 (grub_video_i386_vbefill_index): Likewise.
5274 (grub_video_i386_vbefill_direct32): Added.
5275 (grub_video_i386_vbefill_direct24): Likewise.
5276 (grub_video_i386_vbefill_direct16): Likewise.
5277 (grub_video_i386_vbefill_direct8): Likewise.
5279 * video/readers/jpeg.c (grub_jpeg_decode_sos): Adapt to new blitter
5282 * video/readers/tga.c (grub_video_reader_tga): Adapt to new blitter
5285 * video/readers/png.c (grub_png_decode_image_header): Adapt to new
5288 * video/bitmap.c (grub_video_bitmap_create): Adapt to new blitter
5291 2008-09-06 Felix Zielcke <fzielcke@z-51.de>
5293 * disk/raid.c (insert_array): Set `array->chunk_size' to 64 for
5296 2008-09-06 Felix Zielcke <fzielcke@z-51.de>
5298 * fs/iso9660.c (grub_iso9660_date): New structure.
5299 (grub_iso9660_primary_voldesc): Add `grub_iso9660_date' member.
5300 (grub_iso9660_uuid): New function.
5302 2008-09-05 Bean <bean123ch@gmail.com>
5304 * fs/fshelp.c (grub_fshelp_find_file): Handle case insensitive names.
5306 * fs/ntfs.c (list_file): Ignore names in DOS namespace, set the case
5307 insensitive bit for names in Win32 and Win32 & DOS namespace.
5309 * include/grub/fshelp.h (GRUB_FSHELP_CASE_INSENSITIVE): New macro.
5311 * include/grub/types.h (LONG_MAX): Likewise.
5313 2008-09-04 Felix Zielcke <fzielcke@z-51.de>
5315 * util/getroot.c: Include <config.h>.
5316 (grub_util_get_grub_dev): Rewrite to use asprintf for mdraid devices,
5317 add support for /dev/md/N devices and handle LVM double dash escaping.
5319 2008-09-04 Felix Zielcke <fzielcke@z-51.de>
5321 * config.guess: Update to latest version from config git.
5322 * config.sub: Likewise.
5324 2008-09-03 Robert Millan <rmh@aybabtu.com>
5326 * disk/scsi.c (grub_scsi_open): Remove size limit when printing
5327 `disk->total_sectors'.
5329 2008-09-01 Colin D Bennett <colin@gibibit.com>
5331 * include/grub/normal.h: Fixed incorrect comment for
5332 GRUB_COMMAND_FLAG_NO_ARG_PARSE.
5334 2008-09-01 Colin D Bennett <colin@gibibit.com>
5336 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Replaced constant
5337 values with defines.
5339 * include/grub/i386/pc/vbe.h (GRUB_VBE_MODEATTR_SUPPORTED): Added.
5340 (GRUB_VBE_MODEATTR_RESERVED_1): Likewise.
5341 (GRUB_VBE_MODEATTR_BIOS_TTY_OUTPUT_SUPPORT): Likewise.
5342 (GRUB_VBE_MODEATTR_COLOR): Likewise.
5343 (GRUB_VBE_MODEATTR_GRAPHICS): Likewise.
5344 (GRUB_VBE_MODEATTR_VGA_COMPATIBLE): Likewise.
5345 (GRUB_VBE_MODEATTR_VGA_WINDOWED_AVAIL): Likewise.
5346 (GRUB_VBE_MODEATTR_LFB_AVAIL): Likewise.
5347 (GRUB_VBE_MODEATTR_DOUBLE_SCAN_AVAIL): Likewise.
5348 (GRUB_VBE_MODEATTR_INTERLACED_AVAIL): Likewise.
5349 (GRUB_VBE_MODEATTR_TRIPLE_BUF_AVAIL): Likewise.
5350 (GRUB_VBE_MODEATTR_STEREO_AVAIL): Likewise.
5351 (GRUB_VBE_MODEATTR_DUAL_DISPLAY_START): Likewise.
5352 (GRUB_VBE_MEMORY_MODEL_TEXT): Likewise.
5353 (GRUB_VBE_MEMORY_MODEL_CGA): Likewise.
5354 (GRUB_VBE_MEMORY_MODEL_HERCULES): Likewise.
5355 (GRUB_VBE_MEMORY_MODEL_PLANAR): Likewise.
5356 (GRUB_VBE_MEMORY_MODEL_NONCHAIN4_256): Likewise.
5357 (GRUB_VBE_MEMORY_MODEL_YUV): Likewise.
5359 2008-08-31 Robert Millan <rmh@aybabtu.com>
5361 * loader/i386/pc/multiboot.c (grub_get_multiboot_mmap_len): Fix
5363 (grub_multiboot): Fix a few warnings.
5365 2008-08-31 Robert Millan <rmh@aybabtu.com>
5367 * loader/i386/pc/multiboot.c: Update comment not to say that
5368 boot_device support is unimplemented.
5370 2008-08-31 Robert Millan <rmh@aybabtu.com>
5372 * loader/i386/pc/multiboot.c: Update comment not to say that a.out
5373 or memory map support are unimplemented.
5375 2008-08-31 Colin D Bennett <colin@gibibit.com>
5377 * util/i386/pc/grub-mkrescue.in: Support multiple overlay directories.
5379 2008-08-31 Colin D Bennett <colin@gibibit.com>
5381 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Show VBE version and
5382 total video memory in 'vbeinfo' output; show color format details for
5385 2008-08-30 Pavel Roskin <proski@gnu.org>
5387 * util/genmoddep.c: Remove for real this time.
5388 * DISTLIST: Remove util/genmoddep.c.
5390 2008-08-30 Robert Millan <rmh@aybabtu.com>
5392 * kern/i386/pc/startup.S (multiboot_header): Force 4-byte alignment
5393 as required by Multiboot spec (it was already 4-byte aligned, but
5396 2008-08-29 Pavel Roskin <proski@gnu.org>
5398 * kern/powerpc/ieee1275/crt0.S: Rename to ...
5399 * kern/powerpc/ieee1275/startup.S: ... this.
5400 * conf/powerpc-ieee1275.rmk: Adjust for the above.
5401 * DISTLIST: Likewise.
5403 * kern/powerpc/ieee1275/crt0.S: Include grub/symbol.h and
5404 grub/cpu/kernel.h. Add start label for consistency with other
5405 platforms. Add grub_prefix immediately after start. Add jump
5406 to the code after grub_prefix.
5407 * include/grub/powerpc/kernel.h: Provide valid values for
5408 GRUB_KERNEL_CPU_PREFIX and GRUB_KERNEL_CPU_DATA_END.
5410 2008-08-29 Bean <bean123ch@gmail.com>
5412 * configure.ac: Change host_os to cygwin for mingw.
5413 (asprintf): New check for function.
5415 * include/grub/symbol.h: Replace #ifndef __CYGWIN__ with
5416 #if ! defined (__CYGWIN__) && ! defined (__MINGW32__).
5418 * include/grub/util/misc.h: #include <config.h> and <grub/types.h>,
5419 declare asprintf if HAVE_ASPRINTF is not set, declare fseeko, ftello,
5420 sync, sleep and grub_util_get_disk_size for mingw.
5422 * util/biosdisk.c (grub_util_biosdisk_open): Use grub_util_get_disk_size
5423 to get size in mingw.
5424 (open_device): Use flag O_BINARY if it's defined.
5425 (find_root_device): Add dummy code for mingw.
5427 * util/grub-mkdevicemap.c (get_floppy_disk_name): Return 0 for mingw.
5428 (get_ide_disk_name): Return //./PHYSICALDRIVE%d for mingw.
5429 (get_scsi_disk_name): Return 0 for mingw.
5431 * util/hostfs.c: #include <grub/util/misc.h>.
5432 (grub_hostfs_open): Use "rb" flag to open file, use
5433 grub_util_get_disk_size to get disk size for mingw.
5435 * util/misc.c: #include <windows.h> and <winioctl.h> in mingw.
5436 (asprintf): New function if HAVE_ASPRINTF is not set.
5437 (sync): New function for mingw.
5439 (grub_util_get_disk_size): Likewise.
5441 2008-08-28 Pavel Roskin <proski@gnu.org>
5443 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
5446 2008-08-28 Robert Millan <rmh@aybabtu.com>
5448 * util/biosdisk.c (find_grub_drive): Declare missing `i' variable.
5450 2008-08-28 Robert Millan <rmh@aybabtu.com>
5452 Change find_grub_drive() syntax so it doesn't prevent it from
5453 detecting NULL names as errors.
5455 * util/biosdisk.c (find_grub_drive): Move free slot search code
5457 (find_free_slot): ... to here.
5458 (read_device_map): Use find_free_slot() to search for free slots.
5460 2008-08-27 Marco Gerards <marco@gnu.org>
5462 * conf/common.rmk (pkglib_MODULES): Add scsi.mod.
5463 (scsi_mod_SOURCES): New variable.
5464 (scsi_mod_CFLAGS): Likewise
5465 (scsi_mod_LDFLAGS): Likewise.
5467 * disk/scsi.c: New file.
5469 * include/grub/scsi.h: Likewise.
5471 * include/grub/scsicmd.h: Likewise.
5473 * disk/ata.c: Include <grub/scsi.h>.
5474 (grub_atapi_packet): Do not use grub_ata_cmd, use registers
5476 (grub_ata_iterate): Skip ATAPI devices.
5477 (grub_ata_open): Only handle ATAPI devices.
5478 (struct grub_atapi_read): Removed.
5479 (grub_atapi_readsector): Likewise.
5480 (grub_ata_read): No longer handle ATAPI devices.
5481 (grub_ata_write): Likewise.
5482 (grub_atapi_iterate): New function.
5483 (grub_atapi_read): Likewise.
5484 (grub_atapi_write): Likewise.
5485 (grub_atapi_open): Likewise.
5486 (grub_atapi_close): Likewise.
5487 (grub_atapi_dev): New variable.
5488 (GRUB_MOD_INIT(ata)): Register ATAPI as SCSI device.
5489 (GRUB_MOD_FINI(ata)): Unregister ATAPI.
5491 * include/grub/disk.h (enum grub_disk_dev_id): Add
5492 `GRUB_DISK_DEVICE_SCSI_ID'.
5494 2008-08-26 Robert Millan <rmh@aybabtu.com>
5496 * util/biosdisk.c (grub_util_biosdisk_open, open_device)
5497 (grub_util_biosdisk_get_grub_dev): Make error messages a bit more
5500 2008-08-23 Bean <bean123ch@gmail.com>
5502 * conf/common.rmk (grub_probe_SOURCES): Add disk/mdraid_linux.c.
5503 (grub_fstest_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
5504 disk/mdraid_linux.c and disk/dmraid_nvidia.c and lib/crc.c.
5505 (pkglib_MODULES): Add raid5rec.mod, raid6rec.mod, mdraid.mod and
5507 (raid5rec_mod_SOURCES): New macro.
5508 (raid5rec_mod_CFLAGS): Likewise.
5509 (raid5rec_mod_LDFLAGS): Likewise.
5510 (raid6rec_mod_SOURCES): Likewise.
5511 (raid6rec_mod_CFLAGS): Likewise.
5512 (raid6rec_mod_LDFLAGS): Likewise.
5513 (mdraid_mod_SOURCES): Likewise.
5514 (mdraid_mod_CFLAGS): Likewise.
5515 (mdraid_mod_LDFLAGS): Likewise.
5516 (dm_nv_mod_SOURCES): Likewise.
5517 (dm_nv_mod_CFLAGS): Likewise.
5518 (dm_nv_mod_LDFLAGS): Likewise.
5520 * conf/i386-pc.rmk (grub_setup_SOURCES): Add disk/mdraid_linux.c.
5521 (grub_emu_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
5522 disk/mdraid_linux.c and disk/dmraid_nvidia.c.
5524 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add disk/raid5_recover.c,
5525 disk/raid6_recover.c, disk/mdraid_linux.c and disk/dmraid_nvidia.c.
5527 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
5529 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
5531 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5533 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5535 * disk/raid5_recover.c: New file.
5537 * disk/raid6_recover.c: Likewise.
5539 * disk/mdraid_linux.c: Likewise.
5541 * disk/dmraid_nvidia.c: Likewise.
5543 * disk/i386/pc/biosdisk.c: Set total_sectors of cdrom device to
5546 * disk/raid.c (grub_raid_open): Use the size of the smallest disk to
5547 calculate the size of raid device.
5548 (grub_raid_read): Simplify raid0 code. Support raid4, raid6 and four
5549 different layout of raid5.
5550 (grub_raid_scan_device): Remove code specific to mdraid.
5551 (grub_raid_list): New variable.
5552 (free_array): New function.
5553 (grub_raid_register): Likewise.
5554 (grub_raid_unregister): Likewise.
5555 (grub_raid_rescan): Likewise.
5556 (GRUB_MOD_INIT): Don't iterate device here.
5557 (GRUB_MOD_FINI): Use free_array to release resource.
5559 * include/grub/raid.h: Remove macro and structure specific to mdraid.
5560 (grub_raid5_recover_func_t): New function variable type.
5561 (grub_raid6_recover_func_t): Likewise.
5562 (grub_raid5_recover_func): New variable.
5563 (grub_raid6_recover_func): Likewise.
5564 (grub_raid_register): New function.
5565 (grub_raid_unregister): Likewise.
5566 (grub_raid_rescan): Likewise.
5567 (grub_raid_block_xor): Likewise.
5569 * util/grub-fstest.c: Add #include <grub/raid.h> and <grub/lib/crc.h>.
5570 (CMD_CRC): New macro.
5572 (read_file): Handle device as well as file.
5573 (cmd_crc): New function.
5574 (fstest): Handle multiple disks.
5575 (options): Remove part, raw and long, add root and diskcount.
5576 (usage): Add crc, remove -p, -r, -l, add -r and -c.
5577 (main): Find the first non option entry and ignore subsequent options,
5578 add handling for the new options, support multiple disks.
5580 * util/grub-probe.c (probe): Add mdraid to abstraction_name.
5582 2008-08-23 Bean <bean123ch@gmail.com>
5584 * normal/x86_64/setjmp.S (grub_longjmp): Return 1 when val = 0.
5586 * genfslist.sh: Ignore kernel.mod.
5588 * genpartmaplist.sh: Likewise.
5590 2008-08-23 Robert Millan <rmh@aybabtu.com>
5592 * util/getroot.c (find_root_device): Skip anything that starts with
5593 a dot, not just directories. This avoids things like /dev/.tmp.md0.
5595 2008-08-22 Felix Zielcke <fzielcke@z-51.de>
5597 * util/update-grub.in (GRUB_GFXMODE): Export variable.
5598 * util/grub.d/00_header.in: Allow the administrator to change default
5599 gfxmode via ${GRUB_GFXMODE}.
5601 2008-08-21 Felix Zielcke <fzielcke@z-51.de>
5603 * fs/ntfs.c (grub_ntfs_mount): Fix a memory leak.
5605 2008-08-21 Robert Millan <rmh@aybabtu.com>
5607 * loader/i386/linux.c: New file. Implements generic 32-bit Linux
5609 * conf/i386-coreboot.rmk (_linux_mod_SOURCES): Replace
5610 `loader/i386/pc/linux.c' with `loader/i386/linux.c'.
5612 2008-08-20 Carles Pina i Estany <carles@pina.cat>
5614 * menu/normal.c (run_menu): Replace hardcoded numbers with macros
5615 (16 for GRUB_TERM_UP and 14 for GRUB_TERM_DOWN)
5617 2008-08-19 Robert Millan <rmh@aybabtu.com>
5619 * term/gfxterm.c (DEFAULT_CURSOR_COLOR): Remove.
5620 (struct grub_virtual_screen): Remove `cursor_color'.
5621 (grub_virtual_screen_setup): Remove `virtual_screen.cursor_color'
5623 (write_cursor): Use `virtual_screen.fg_color' to draw cursor.
5625 2008-08-18 Robert Millan <rmh@aybabtu.com>
5627 Unify (identical) linux_normal.c files.
5628 * loader/i386/efi/linux_normal.c: Move from here ...
5629 * loader/linux_normal.c: ... to here. Update all users.
5630 * loader/i386/pc/linux_normal.c: Delete. Update all users.
5631 * loader/i386/ieee1275/linux_normal.c: Likewise.
5633 2008-08-18 Robert Millan <rmh@aybabtu.com>
5635 * include/grub/i386/linux.h (LINUX_LOADER_ID_LILO)
5636 (LINUX_LOADER_ID_LOADLIN, LINUX_LOADER_ID_BOOTSECT)
5637 (LINUX_LOADER_ID_SYSLINUX, LINUX_LOADER_ID_ETHERBOOT)
5638 (LINUX_LOADER_ID_ELILO, LINUX_LOADER_ID_GRUB, LINUX_LOADER_ID_UBOOT)
5639 (LINUX_LOADER_ID_XEN, LINUX_LOADER_ID_GUJIN, LINUX_LOADER_ID_QEMU):
5641 (GRUB_LINUX_CL_OFFSET, GRUB_LINUX_CL_END_OFFSET): Move from here ...
5642 * loader/i386/pc/linux.c (GRUB_LINUX_CL_OFFSET)
5643 (GRUB_LINUX_CL_END_OFFSET): ... to here.
5644 * loader/i386/efi/linux.c (GRUB_EFI_CL_OFFSET): Rename to ...
5645 (GRUB_LINUX_CL_OFFSET): ... this. Update all users.
5646 (GRUB_EFI_CL_END_OFFSET): Rename to ...
5647 (GRUB_LINUX_CL_END_OFFSET): ... this. Update all users.
5648 (grub_rescue_cmd_linux): Macroify `type_of_loader' initialization.
5649 Initialize `params->video_cursor_x' and `params->video_cursor_y'
5650 portably using grub_getxy().
5651 Replace `-EFI' with `-bzImage' in boot message.
5653 2008-08-17 Robert Millan <rmh@aybabtu.com>
5655 * include/grub/x86_64/kernel.h: New file (<grub/i386/kernel.h> stub).
5657 2008-08-17 Robert Millan <rmh@aybabtu.com>
5659 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pc/mmap.c'.
5661 * include/grub/i386/pc/init.h (GRUB_MACHINE_MEMORY_AVAILABLE)
5662 (GRUB_MACHINE_MEMORY_RESERVED): New macros.
5663 (grub_machine_mmap_iterate): New function declaration.
5664 * include/grub/multiboot.h (struct grub_multiboot_mmap_entry): New
5666 (GRUB_MMAP_MEMORY_AVAILABLE, GRUB_MMAP_MEMORY_RESERVED): New
5669 * kern/i386/pc/init.c (grub_machine_init): Replace hardcoded region
5670 type check value with `GRUB_MACHINE_MEMORY_AVAILABLE'.
5671 Move e820 parsing from here ...
5672 * kern/i386/pc/mmap.c: New file.
5673 (grub_machine_mmap_iterate): ... to here.
5675 * include/grub/i386/coreboot/memory.h: Remove `<grub/err.h>'.
5676 (GRUB_LINUXBIOS_MEMORY_AVAILABLE): Rename (for consistency) to ...
5677 (GRUB_MACHINE_MEMORY_AVAILABLE): ... this. Update all users.
5678 (grub_available_iterate): Redeclare to return `void', and redeclare
5679 its hook to use grub_uint64_t as addr and size parameters, and rename
5681 (grub_machine_mmap_iterate): ... this. Update all users.
5683 * kern/i386/coreboot/mmap.c (grub_mmap_iterate): Simplify parser loop
5684 to make it more readable. Rename to ...
5685 (grub_machine_mmap_iterate): ... this.
5687 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): New variables.
5688 (grub_get_multiboot_mmap_len, grub_fill_multiboot_mmap): New functions.
5689 (grub_multiboot): Allocate an extra region after the payload, and fill
5690 it with a Multiboot memory map. Adjust a.out loader to calculate size
5691 with the extra space.
5692 (grub_multiboot_load_elf32): Adjust elf32 loader to calculate size
5693 with the extra space.
5695 2008-08-17 Carles Pina i Estany <carles@pina.cat>
5697 * menu/normal.c (run_menu): Add Home and End keys in grub-menu.
5699 2008-08-17 Felix Zielcke <fzielcke@z-51.de>
5701 * gendistlist.sh: Add *.y, *.tex, *.texi, grub.cfg, README, *.sc,
5702 mdate-sh to the list `find' searches for.
5703 * DISTLIST: Regenerated.
5705 2008-08-16 Felix Zielcke <fzielcke@z-51.de>
5707 * gendistlist.sh (EXTRA_DISTFILES): Remove gensymlist.sh,
5708 genkernsyms.sh. Add geninit.sh, geninitheader.sh, genkernsyms.sh.in,
5709 genmoddep.awk, gensymlist.sh.in.
5710 (DISTDIRS): Add bus, docs, hook, lib.
5711 * DISTLIST: Regenerated.
5712 * NEWS: Add cygwin support and change the `os-prober' entry a bit.
5714 2008-08-16 Robert Millan <rmh@aybabtu.com>
5716 * disk/raid.c (grub_raid_init): Handle/report errors set by
5717 grub_device_iterate().
5718 * disk/lvm.c (grub_lvm_init): Likewise.
5720 2008-08-15 Bean <bean123ch@gmail.com>
5722 * conf/i386-pc.rmk (pkglib_MODULES): Add datetime.mod, date.mod
5724 (datetime_mod_SOURCES): New macro.
5725 (datetime_mod_CFLAGS): Likewise.
5726 (datetime_mod_LDFLAGS): Likewise.
5727 (date_mod_SOURCES): Likewise.
5728 (date_mod_CFLAGS): Likewise.
5729 (date_mod_LDFLAGS): Likewise.
5730 (datehook_mod_SOURCES): Likewise.
5731 (datehook_mod_CFLAGS): Likewise.
5732 (datehook_mod_LDFLAGS): Likewise.
5734 * conf/i386-coreboot.rmk (pkglib_MODULES): Add datetime.mod, date.mod
5736 (datetime_mod_SOURCES): New macro.
5737 (datetime_mod_CFLAGS): Likewise.
5738 (datetime_mod_LDFLAGS): Likewise.
5739 (date_mod_SOURCES): Likewise.
5740 (date_mod_CFLAGS): Likewise.
5741 (date_mod_LDFLAGS): Likewise.
5742 (datehook_mod_SOURCES): Likewise.
5743 (datehook_mod_CFLAGS): Likewise.
5744 (datehook_mod_LDFLAGS): Likewise.
5746 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add datetime.mod, date.mod
5748 (datetime_mod_SOURCES): New macro.
5749 (datetime_mod_CFLAGS): Likewise.
5750 (datetime_mod_LDFLAGS): Likewise.
5751 (date_mod_SOURCES): Likewise.
5752 (date_mod_CFLAGS): Likewise.
5753 (date_mod_LDFLAGS): Likewise.
5754 (datehook_mod_SOURCES): Likewise.
5755 (datehook_mod_CFLAGS): Likewise.
5756 (datehook_mod_LDFLAGS): Likewise.
5758 * conf/i386-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
5760 (datetime_mod_SOURCES): New macro.
5761 (datetime_mod_CFLAGS): Likewise.
5762 (datetime_mod_LDFLAGS): Likewise.
5763 (date_mod_SOURCES): Likewise.
5764 (date_mod_CFLAGS): Likewise.
5765 (date_mod_LDFLAGS): Likewise.
5766 (datehook_mod_SOURCES): Likewise.
5767 (datehook_mod_CFLAGS): Likewise.
5768 (datehook_mod_LDFLAGS): Likewise.
5770 * conf/x86_64-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
5772 (datetime_mod_SOURCES): New macro.
5773 (datetime_mod_CFLAGS): Likewise.
5774 (datetime_mod_LDFLAGS): Likewise.
5775 (date_mod_SOURCES): Likewise.
5776 (date_mod_CFLAGS): Likewise.
5777 (date_mod_LDFLAGS): Likewise.
5778 (datehook_mod_SOURCES): Likewise.
5779 (datehook_mod_CFLAGS): Likewise.
5780 (datehook_mod_LDFLAGS): Likewise.
5782 * kern/env.c (grub_env_insert): Fix a bug in prevp pointer.
5784 * commands/date.c: New file.
5786 * hook/datehook.c: Likewise.
5788 * include/grub/lib/datetime.h: Likewise.
5790 * include/grub/i386/cmos.h: Likewise.
5792 * lib/datetime.c: Likewise.
5794 * lib/i386/datetime.c: Likewise.
5796 * lib/efi/datetime.c: Likewise.
5798 2008-08-14 Robert Millan <rmh@aybabtu.com>
5800 * conf/common.rmk (bin_UTILITIES): Add `grub-mkelfimage'.
5801 (grub_mkelfimage_SOURCES): New variable.
5802 (util/elf/grub-mkimage.c_DEPENDENCIES): Likewise.
5804 * conf/i386-coreboot.rmk (bin_UTILITIES, grub_mkimage_SOURCES)
5805 (grub_mkimage_LDFLAGS, util/elf/grub-mkimage.c_DEPENDENCIES): Remove.
5806 * conf/powerpc-ieee1275.rmk: Likewise.
5807 * conf/i386-ieee1275.rmk: Likewise.
5809 * kern/ieee1275/init.c: Include `<grub/cpu/kernel.h>'.
5810 * kern/i386/coreboot/init.c: Likewise.
5812 * kern/i386/ieee1275/startup.S: Replace `<grub/machine/kernel.h>'
5813 with `<grub/cpu/kernel.h>'.
5814 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Renamed
5816 (GRUB_KERNEL_CPU_PREFIX, GRUB_KERNEL_CPU_DATA_END): ... this.
5817 * kern/i386/coreboot/startup.S: Likewise.
5819 * include/grub/powerpc/ieee1275/kernel.h (GRUB_MOD_ALIGN)
5820 (GRUB_MOD_GAP): Remove.
5821 * include/grub/powerpc/kernel.h: New file.
5822 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX)
5823 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
5824 * include/grub/i386/kernel.h: New file.
5825 * include/grub/i386/coreboot/kernel.h (GRUB_MOD_ALIGN)
5826 (GRUB_MOD_GAP, GRUB_KERNEL_MACHINE_PREFIX)
5827 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
5829 * util/ieee1275/grub-install.in (grub_mkimage): Initialize to use
5831 Use --directory when invoking grub_mkimage.
5833 * util/elf/grub-mkimage.c: Include `<grub/cpu/kernel.h>'.
5834 (add_segments): Replace GRUB_KERNEL_MACHINE_DATA_END and
5835 GRUB_KERNEL_MACHINE_PREFIX with GRUB_KERNEL_CPU_DATA_END
5836 and GRUB_KERNEL_CPU_PREFIX.
5838 2008-08-14 Felix Zielcke <fzielcke@z-51.de>
5840 * include/grub/err.h (grub_err_printf): New function prototype.
5841 * util/misc.c (grub_err_printf): New function.
5842 * kern/misc.c [! GRUB_UTIL] (grub_err_printf): New alias for
5844 * kern/err.c (grub_print_error): Use grub_err_printf.
5846 2008-08-13 Robert Millan <rmh@aybabtu.com>
5848 * docs/grub.cfg: Remove `/dev/' prefix in GNU/Hurd boot entry.
5850 2008-08-13 Robert Millan <rmh@aybabtu.com>
5852 * docs/grub.cfg: Use the native device name for the example GNU/Hurd
5855 2008-08-12 Robert Millan <rmh@aybabtu.com>
5857 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Move part
5858 of the relocation code from here ...
5859 (grub_multiboot): ... to here.
5860 (forward_relocator, backward_relocator): Move from here ...
5861 * kern/i386/loader.S (grub_multiboot_forward_relocator)
5862 (grub_multiboot_backward_relocator): ... to here.
5863 (grub_multiboot_real_boot): Use %edx for entry offset. Put Multiboot
5864 magic in %eax. Use %ebp for jumping (so %edx is not trashed).
5865 * include/grub/i386/loader.h (grub_multiboot_forward_relocator)
5866 (grub_multiboot_forward_relocator_end)
5867 (grub_multiboot_backward_relocator)
5868 (grub_multiboot_backward_relocator_end): New variables.
5870 2008-08-12 Bean <bean123ch@gmail.com>
5872 * disk/raid.c (grub_raid_read): Fix a bug in raid0 code.
5874 2008-08-11 Robert Millan <rmh@aybabtu.com>
5876 * kern/i386/linuxbios/startup.S: Move from here ...
5877 * kern/i386/coreboot/startup.S: ... to here.
5879 * kern/i386/linuxbios/init.c: Move from here ...
5880 * kern/i386/coreboot/init.c: ... to here.
5882 * kern/i386/linuxbios/table.c: Move from here ...
5883 * kern/i386/coreboot/mmap.c: ... to here.
5885 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Update moved files.
5887 2008-08-11 Robert Millan <rmh@aybabtu.com>
5889 * kern/device.c (grub_device_open): Do not handle grub_disk_open()
5890 errors. Leave it to the upper layer to handle them.
5892 2008-08-09 Christian Franke <franke@computer.org>
5894 * Makefile.in: Add `target_os' and `enable_grub_pe2elf'.
5895 * conf/common.rmk: Install `grub-pe2elf' only if requested.
5896 Install `grub.d/10_windows' only on Cygwin.
5897 * configure.ac: Add subst of `target_os'.
5898 Check `target_os' also before setting TARGET_OBJ2ELF.
5899 Add `--enable-grub-pe2elf'.
5901 2008-08-08 Robert Millan <rmh@aybabtu.com>
5903 * kern/disk.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
5904 (grub_last_time): Change type to grub_uint64_t.
5905 (grub_disk_open): Migrate code from to using grub_get_time_ms().
5906 (grub_disk_close): Likewise.
5908 * normal/menu.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
5909 (run_menu): Migrate code from to using grub_get_time_ms().
5911 * util/misc.c (grub_get_time_ms): New function.
5913 2008-08-08 Marco Gerards <marco@gnu.org>
5915 * disk/ata.c (grub_ata_regget): Change return type to
5917 (grub_ata_regget2): Likewise.
5918 (grub_ata_wait_status): New function.
5919 (grub_ata_wait_busy): Removed function, updated all users to use
5920 `grub_ata_wait_status'.
5921 (grub_ata_wait_drq): Likewise.
5922 (grub_ata_cmd): New function.
5923 (grub_ata_pio_read): Change return type to `grub_uint8_t'. Add
5925 (grub_ata_pio_write): Add error handling.
5926 (grub_atapi_identify): Likewise.
5927 (grub_atapi_packet): Use `grub_ata_cmd' and improve error
5929 (grub_ata_identify): Use `grub_ata_cmd' and improve error
5930 handling. Actually use the detected registers. Reorder the
5931 detection logic such that it is easier to read.
5932 (grub_ata_pciinit): Do not assign the same ID to each controller.
5933 (grub_ata_setaddress): Use `grub_ata_cmd' and improve error
5935 (grub_atapi_readsector): Check the result of `grub_ata_pio_read'.
5937 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TIMEOUT'.
5939 2008-08-08 Marco Gerards <marco@gnu.org>
5943 2008-08-07 Bean <bean123ch@gmail.com>
5945 * include/grub/x86_64/pci.h: New file.
5947 2008-08-07 Christian Franke <franke@computer.org>
5949 * kern/i386/pit.c (TIMER2_SPEAKER): New define.
5950 (TIMER2_GATE): Likewise.
5951 (grub_pit_wait): Add enable/disable of the timer2 gate
5952 bit of port 0x61. This fixes a possible infinite loop.
5954 2008-08-07 Bean <bean123ch@gmail.com>
5956 * conf/x86_64-efi.rmk (kernel_mod_SOURCES): Add kern/time.c,
5957 kern/i386/tsc.c and kern/i386/pit.c.
5959 * include/grub/i386/tsc.h (grub_cpu_is_cpuid_supported): Handle
5962 * kern/i386/efi/init.c: Replace <grub/cpu/tsc.h> with
5965 * kern/i386/pit.c: Replace <grub/cpu/io.h> with <grub/i386/io.h>.
5967 2008-08-07 Bean <bean123ch@gmail.com>
5969 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add kern/time.c.
5971 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add kern/time.c,
5973 * include/grub/i386/pit.h: Use macro KERNEL_CPU_PIT_HEADER to avoid
5974 multiple inclusion. Add #include <grub/types.h>.
5976 2008-08-06 Christian Franke <franke@computer.org>
5978 * conf/common.rmk: Build and install `10_windows'.
5979 * util/grub.d/10_windows.in: New script.
5981 2008-08-06 Pavel Roskin <proski@gnu.org>
5983 * kern/i386/pit.c: Include `<grub/i386/pit.h>'.
5985 2008-08-06 Robert Millan <rmh@aybabtu.com>
5987 * conf/i386-coreboot.rmk (kernel_elf_ASFLAGS): New variable.
5988 * kern/i386/tsc.c: Include `<grub/i386/pit.h>'.
5990 2008-08-06 Bean <bean123ch@gmail.com>
5992 * fs/i386/pc/pxe.c (grub_pxe_data): New member block_size.
5993 (grub_pxefs_fs_int): Remove dummy definition.
5994 (grub_pxefs_open): Use data->block_size to store the current block
5996 (grub_pxefs_read): Use block size stored in data->block_size. As the
5997 value of grub_pxe_blksize can be changed after the file is opened.
5999 2008-08-06 Bean <bean123ch@gmail.com>
6001 * fs/i386/pc/pxe.c (curr_file): new variable.
6002 (grub_pxefs_open): Simply the handling of pxe file system. Don't
6003 require the dummy internal file system anymore.
6004 (grub_pxefs_read): Removed.
6005 (grub_pxefs_close): Likewise.
6006 (grub_pxefs_fs_int): Likewise.
6007 (grub_pxefs_read_int): Renamed to grub_pxefs_read. Reinitialize tftp
6008 connection when we switch file.
6009 (grub_pxefs_close_int): Renamed to grub_pxefs_close.
6011 2008-08-06 Robert Millan <rmh@aybabtu.com>
6013 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `reboot.mod' and
6015 (reboot_mod_SOURCES, reboot_mod_CFLAGS, reboot_mod_LDFLAGS)
6016 (halt_mod_SOURCES, halt_mod_CFLAGS, halt_mod_LDFLAGS): New variables.
6018 * kern/i386/halt.c: New file.
6019 * kern/i386/reboot.c: Likewise.
6020 * include/grub/i386/reboot.h: Likewise.
6021 * include/grub/i386/halt.h: Likewise.
6023 * commands/halt.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]:
6024 Include `<grub/cpu/halt.h>'.
6025 * commands/reboot.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]
6026 [! GRUB_MACHINE_PCBIOS]: Include `<grub/cpu/reboot.h>'.
6028 * term/i386/pc/at_keyboard.c: Include `<grub/cpu/at_keyboard.h>'.
6029 (SHIFT_L, SHIFT_R, CTRL, ALT, CAPS_LOCK, KEYBOARD_REG_DATA)
6030 (KEYBOARD_REG_STATUS, KEYBOARD_COMMAND_ISREADY, KEYBOARD_COMMAND_READ)
6031 (KEYBOARD_COMMAND_WRITE, KEYBOARD_COMMAND_REBOOT)
6032 (KEYBOARD_SCANCODE_SET1, KEYBOARD_ISMAKE, KEYBOARD_ISREADY)
6033 (KEYBOARD_SCANCODE, OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): Move
6035 * include/grub/i386/at_keyboard.h: ... to here.
6037 2008-08-05 Robert Millan <rmh@aybabtu.com>
6039 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pit.c'.
6040 * conf/i386-efi.rmk (kernel_mod_SOURCES): Likewise.
6041 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Likewise. Also add
6042 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
6043 `kern/generic/millisleep.c'.
6045 * kern/i386/tsc.c (calibrate_tsc): Rewrite using grub_pit_wait()
6046 instead of grub_get_rtc().
6047 (grub_tsc_init): Initialize `tsc_boot_time'.
6049 * kern/i386/linuxbios/init.c (grub_millisleep): Remove stub.
6050 (grub_machine_init): Use grub_tsc_init() rather than
6051 installing an RTC-based handler via grub_install_get_time_ms().
6053 * kern/i386/pit.c: New file.
6054 * include/grub/i386/pit.h: Likewise.
6056 2008-08-05 Bean <bean123ch@gmail.com>
6058 * boot/i386/pc/pxeboot.S (_start): Use drive number 0x7F for pxe.
6060 * conf/i386-pc.rmk (kernel_img_HEADERS): Add machine/pxe.h.
6061 (pkglib_MODULES): Add pxe.mod and pxecmd.mod.
6062 (pxe_mod_SOURCES): New macro.
6063 (pxe_mod_CFLAGS): Likewise.
6064 (pxe_mod_LDFLAGS): Likewise.
6065 (pxecmd_mod_SOURCES): Likewise.
6066 (pxecmd_mod_CFLAGS): Likewise.
6067 (pxecmd_mod_LDFLAGS): Likewise.
6069 * kern/i386/pc/startup.S (grub_pxe_scan): New function.
6070 (grub_pxe_call): Likewise.
6072 * include/grub/disk.h (grub_disk_dev_id): Add GRUB_DISK_DEVICE_PXE_ID.
6074 * commands/i386/pc/pxecmd.c: New file.
6076 * fs/i386/pc/pxe.c: Likewise.
6078 * include/grub/i386/pc/pxe.h: Likewise.
6080 2008-08-05 Bean <bean123ch@gmail.com>
6082 * util/console.c (grub_console_cur_color): New variable.
6083 (grub_console_standard_color): Likewise.
6084 (grub_console_normal_color): Likewise.
6085 (grub_console_highlight_color): Likewise.
6086 (color_map): Likewise.
6087 (use_color): Likewise.
6088 (NUM_COLORS): New macro.
6089 (grub_ncurses_setcolorstate): Handle color properly.
6090 (grub_ncurses_setcolor): Don't change color here, just remember the
6091 settings, color will be set in grub_ncurses_setcolorstate.
6092 (grub_ncurses_getcolor): New function.
6093 (grub_ncurses_init): Initialize color pairs.
6094 (grub_ncurses_term): New member grub_ncurses_getcolor.
6096 2008-08-05 Colin D Bennett <colin@gibibit.com>
6098 High resolution timer support. Implemented for x86 CPUs using TSC.
6099 Extracted generic grub_millisleep() so it's linked in only as needed.
6100 This requires a Pentium compatible CPU; if the RDTSC instruction is
6101 not supported, then it falls back on the generic grub_get_time_ms()
6102 implementation that uses the machine's RTC.
6104 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/time.c',
6105 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
6106 `kern/generic/millisleep.c'.
6108 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add `kern/i386/tsc.c',
6109 `kern/generic/rtc_get_time_ms.c' and `kern/generic/millisleep.c'.
6111 * conf/x86_64-efi.rml (kernel_mod_SOURCES): Add
6112 `kern/generic/millisleep.c' and `kern/generic/rtc_get_time_ms.c'.
6114 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
6116 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
6117 `kern/generic/millisleep.c'.
6119 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
6121 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Add `kern/time.c'.
6123 * kern/generic/rtc_get_time_ms.c: New file.
6125 * kern/generic/millisleep.c: New file.
6127 * kern/misc.c: Don't include
6128 <kern/time.h> anymore.
6129 (grub_millisleep_generic): Removed.
6131 * commands/sleep.c (grub_interruptible_millisleep): Uses
6132 grub_get_time_ms() instead of grub_get_rtc().
6134 * include/grub/i386/tsc.h (grub_get_tsc): New file. New inline
6136 (grub_cpu_is_cpuid_supported): New inline function.
6137 (grub_cpu_is_tsc_supported): New inline function.
6138 (grub_tsc_init): New function prototype.
6139 (grub_tsc_get_time_ms): New function prototype.
6141 * kern/i386/tsc.c (grub_get_time_ms): New file.
6143 * include/grub/time.h: Include <grub/types.h.
6144 (grub_millisleep_generic): Removed.
6145 (grub_get_time_ms): New prototype.
6146 (grub_install_get_time_ms): New prototype.
6147 (grub_rtc_get_time_ms): New prototype.
6149 * kern/time.c (grub_get_time_ms): New function.
6150 (grub_install_get_time_ms): New function.
6152 * kern/i386/efi/init.c: Include <grub/cpu/tsc.h>. Don't include
6153 <grub/time.h> anymore.
6154 (grub_millisleep): Removed.
6155 (grub_machine_init): Call grub_tsc_init.
6157 * kern/i386/linuxbios/init.c (grub_machine_init): Install the RTC
6158 get_time_ms() implementation.
6160 * kern/sparc64/ieee1275/init.c (grub_millisleep): Removed.
6161 (ieee1275_get_time_ms): New function.
6162 (grub_machine_init): Install get_time_ms() implementation.
6164 * kern/i386/pc/init.c: Include <grub/cpu/tsc.h>.
6165 (grub_machine_init): Call grub_tsc_init().
6166 (grub_millisleep): Removed.
6168 * kern/ieee1275/init.c (grub_millisleep): Removed.
6169 (grub_machine_init): Install ieee1275_get_time_ms()
6171 (ieee1275_get_time_ms): New function.
6172 (grub_get_rtc): Now calls ieee1275_get_time_ms(), which does the
6175 2008-08-05 Marco Gerards <marco@gnu.org>
6177 * disk/ata.c: Include <grub/pci.h>.
6178 (enum grub_ata_commands): Add `GRUB_ATA_CMD_EXEC_DEV_DIAGNOSTICS'.
6179 (grub_ata_initialize): Rewritten.
6180 (grub_ata_device_initialize): New function.
6182 2008-08-04 Pavel Roskin <proski@gnu.org>
6184 * kern/main.c: Include grub/mm.h.
6186 2008-08-04 Robert Millan <rmh@aybabtu.com>
6188 * conf/i386-coreboot.rmk (COMMON_ASFLAGS, COMMON_CFLAGS)
6189 (COMMON_LDFLAGS): Harmonize with i386-pc version (fixes a code
6190 corruption problem).
6192 2008-08-04 Robert Millan <rmh@aybabtu.com>
6194 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Fix misc
6195 warnings introduced in my last commit.
6197 2008-08-03 Robert Millan <rmh@aybabtu.com>
6199 Make PCI available on all i386 architectures.
6201 * include/grub/i386/pc/pci.h: Move from here ...
6202 * include/grub/i386/pci.h: ... to here.
6204 * include/grub/i386/pc/pci.h: Remove.
6205 * include/grub/i386/efi/pci.h: Remove.
6206 * include/grub/x86_64/efi/pci.h: Remove.
6208 * include/grub/pci.h: Replace `<grub/machine/pci.h>' with
6211 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `pci' and `lspci'.
6212 (pci_mod_SOURCES, pci_mod_CFLAGS, pci_mod_LDFLAGS, lspci_mod_SOURCES)
6213 (lspci_mod_CFLAGS, lspci_mod_LDFLAGS): New variables.
6215 * conf/i386-ieee1275.rmk: Likewise.
6217 2008-08-03 Robert Millan <rmh@aybabtu.com>
6219 * term/i386/pc/vga_text.c (CRTC_CURSOR_DISABLE): New macro.
6220 (grub_console_setcursor): Make it possible to set cursor off.
6222 2008-08-03 Robert Millan <rmh@aybabtu.com>
6224 * util/grub.d/00_header.in: Be platform-agnostic. Probe for existence
6225 of modules instead of assuming which platform provides what.
6226 * util/update-grub.in: Likewise.
6228 2008-08-03 Robert Millan <rmh@aybabtu.com>
6230 * kern/i386/pc/init.c (make_install_device): Check for `grub_prefix'
6231 instead of `grub_install_dos_part' to determine whether a drive needs
6232 to be prepended to prefix (`grub_install_dos_part' is not reliable,
6233 because it can be overridden when loading GRUB via Multiboot).
6235 2008-08-02 Robert Millan <rmh@aybabtu.com>
6237 * util/i386/pc/grub-install.in: Remove trailing slash from prefix.
6239 2008-08-02 Robert Millan <rmh@aybabtu.com>
6241 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Add a pair
6242 of informational grub_dprintf() calls.
6244 2008-08-02 Robert Millan <rmh@aybabtu.com>
6246 * disk/memdisk.c (memdisk_size): Don't initialize.
6247 (GRUB_MOD_INIT(memdisk)): Find memdisk using grub_module_iterate().
6249 * include/grub/i386/pc/kernel.h
6250 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): Remove macro.
6251 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Shift.
6252 (grub_memdisk_image_size, grub_arch_memdisk_addr)
6253 (grub_arch_memdisk_size): Remove.
6255 * include/grub/kernel.h (struct grub_module_header): Remove `offset'
6256 field (was only used to transfer a constant). Add `type' field to
6257 support multiple module types.
6258 (grub_module_iterate): New function.
6260 * kern/device.c (grub_device_open): Do not hide error messages
6261 when grub_disk_open() fails. Use grub_print_error() instead.
6263 * kern/i386/pc/init.c (grub_arch_modules_addr)
6264 (grub_arch_memdisk_size): Remove functions.
6265 (grub_arch_modules_addr): Return the module address in high memory
6266 (now that it isn't copied anymore).
6268 * kern/i386/pc/startup.S (grub_memdisk_image_size): Remove variable.
6269 (codestart): Don't add grub_memdisk_image_size to %ecx in LZMA
6270 decompression routine (grub_total_module_size already includes that
6271 now). Don't copy modules back to low memory.
6273 * kern/main.c: Include `<grub/mm.h>'.
6274 (grub_load_modules): Split out (and use) ...
6275 (grub_module_iterate): ... this function, which iterates through
6276 module objects and runs a hook.
6277 Comment out grub_mm_init_region() call, as it would cause non-ELF
6278 modules to be overwritten.
6280 * util/i386/pc/grub-mkimage.c (generate_image): Instead of appending
6281 the memdisk image in its own region, make it part of the module list.
6282 * util/elf/grub-mkimage.c (options): Add "memdisk"|'m' option.
6283 (main): Parse --memdisk|-m option, and pass user-provided path as
6284 parameter to generate_image().
6285 (add_segments): Pass `memdisk_path' down to load_modules().
6286 (load_modules): Embed memdisk image in module section when requested.
6287 * util/i386/efi/grub-mkimage.c (make_mods_section): Initialize
6288 `header.type' instead of `header.offset'.
6290 * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add `memdisk.mod'.
6291 (memdisk_mod_SOURCES, memdisk_mod_CFLAGS)
6292 (memdisk_mod_LDFLAGS): New variables.
6293 * conf/i386-coreboot.rmk: Likewise.
6294 * conf/i386-ieee1275.rmk: Likewise.
6296 2008-08-02 Robert Millan <rmh@aybabtu.com>
6298 * loader/i386/pc/multiboot.c (playground, forward_relocator)
6299 (backward_relocator): New variables. Used to allocate and relocate
6300 the payload, respectively.
6301 (grub_multiboot_load_elf32): Load into heap instead of requested
6302 address, install the appropriate relocator code in each bound of
6303 the payload, and set the entry point such that
6304 grub_multiboot_real_boot() will jump to one of them.
6306 * kern/i386/loader.S (grub_multiboot_payload_size)
6307 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
6308 (grub_multiboot_payload_entry_offset): New variables.
6309 (grub_multiboot_real_boot): Set cpu context to what the relocator
6310 expects, and jump to the relocator instead of the payload.
6312 * include/grub/i386/loader.h (grub_multiboot_payload_size)
6313 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
6314 (grub_multiboot_payload_entry_offset): Export.
6316 2008-08-01 Bean <bean123ch@gmail.com>
6318 * normal/menu_entry.c (editor_getline): Don't return the original
6319 string as result, as it will be released by lexer once it has done
6322 2008-08-01 Robert Millan <rmh@aybabtu.com>
6324 * util/grub.d/10_linux.in: Use prepare_grub_to_access_device() from
6325 within menuentries, not before them.
6326 util/grub.d/10_hurd.in: Likewise.
6328 2008-08-01 Bean <bean123ch@gmail.com>
6330 * conf/common.rmk (pkglib_MODULES): Add bufio.mod.
6331 (bufio_mod_SOURCES): New macro.
6332 (bufio_mod_CFLAGS): Likewise.
6333 (bufio_mod_LDFLAGS): Likewise.
6335 * include/grub/bufio.h: New file.
6337 * io/bufio.c: Likewise.
6339 * video/png.c: Replace <grub/file.h> with <grub/bufio.h>.
6340 (grub_video_reader_png): Use grub_buffile_open to open file.
6342 * video/jpeg.c: Replace <grub/file.h> with <grub/bufio.h>.
6343 (grub_video_reader_jpeg): Use grub_buffile_open to open file.
6345 * video/tga.c: Replace <grub/file.h> with <grub/bufio.h>.
6346 (grub_video_reader_tga): Use grub_buffile_open to open file.
6348 * font/manager.c: Include <grub/bufio.h>.
6349 (add_font): Use grub_buffile_open to open file.
6351 2008-07-31 Robert Millan <rmh@aybabtu.com>
6353 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): When loading
6354 ELF segments, use a macro for arbitrarily accessing any of them instead
6355 of preparing a pointer that allows access to one at a time.
6356 (grub_multiboot_load_elf64): Likewise.
6358 2008-07-31 Bean <bean123ch@gmail.com>
6360 * boot/i386/pc/lnxboot.S (real_code_2): Replace 0x50 with
6361 GRUB_KERNEL_MACHINE_DATA_END.
6363 2008-07-30 Robert Millan <rmh@aybabtu.com>
6365 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_DATA_END):
6366 Increase from 0x50 to 0x60.
6367 * util/i386/pc/grub-install.in: Detect cross-disk installs, and
6368 use UUIDs to identify the root drive for them. If that's not
6370 * util/i386/pc/grub-setup.c (setup): Do not special-case, or even
6371 check, for cross-disk installs.
6373 2008-07-30 Robert Millan <rmh@aybabtu.com>
6375 * kern/ieee1275/init.c (grub_machine_set_prefix): If `grub_prefix'
6376 is non-empty, use it to set the `prefix' environment variable instead
6377 of the usual approach.
6378 * kern/i386/linuxbios/init.c (make_install_device): Remove function.
6379 (grub_machine_set_prefix): Use `grub_prefix' to set the `prefix'
6380 environment variable instead of dummy make_install_device().
6382 * kern/i386/ieee1275/startup.S: Include `<grub/machine/kernel.h>'.
6383 (start): Insert a data section, with `grub_prefix' variable.
6384 * kern/i386/linuxbios/startup.S: Likewise.
6386 * include/grub/powerpc/ieee1275/kernel.h [!ASM_FILE] (grub_prefix):
6387 New variable reference.
6388 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX):
6389 New macro. Defines offset of `grub_prefix' within startup.S (relative
6391 (GRUB_KERNEL_MACHINE_DATA_END): New macro. Defines the end of data
6392 section within startup.S (relative to `start').
6393 * include/grub/i386/coreboot/kernel.h: Likewise.
6395 * util/elf/grub-mkimage.c (add_segments): Receive `prefix' parameter.
6396 Overwrite grub_prefix with its contents, at the beginning of the
6398 (main): Understand -p|--prefix.
6400 2008-07-30 Robert Millan <rmh@aybabtu.com>
6402 * util/grub.d/10_hurd.in: Source ${libdir}/grub/update-grub_lib.
6404 2008-07-30 Robert Millan <rmh@aybabtu.com>
6406 * term/i386/pc/vga_text.c (grub_console_cls): Use
6407 grub_console_gotoxy() to go back to beginning of the screen.
6408 Found by Patrick Georgi <patrick.georgi@coresystems.de>
6410 2008-07-29 Christian Franke <franke@computer.org>
6412 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
6413 Add conversion of emulated mount points on Cygwin.
6415 2008-07-29 Christian Franke <franke@computer.org>
6417 * util/update-grub.in: Add a check for admin
6419 Remove old `grub.cfg.new' before creation.
6420 Add `-f' to `mv' to handle the different filesystem
6421 semantics of Windows.
6423 2008-07-29 Bean <bean123ch@gmail.com>
6425 * normal/main.c (get_line): Fix buffer overflow bug.
6427 2008-07-28 Robert Millan <rmh@aybabtu.com>
6429 * partmap/apple.c (GRUB_APPLE_HEADER_MAGIC): New macro.
6430 (struct grub_apple_header): New struct. Describes the layout of
6432 (apple_partition_map_iterate): Check the header magic as well as the
6433 partition magic (which was already being checked).
6435 2008-07-28 Pavel Roskin <proski@gnu.org>
6437 * genmk.rb: Add a warning to the beginning of the output that
6438 it's a generated file and should not be edited.
6440 2008-07-28 Robert Millan <rmh@aybabtu.com>
6442 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
6443 with the same number are found, just use issue a warning with
6444 grub_dprintf(), as this error has been reported to be non-fatal.
6446 2008-07-27 Robert Millan <rmh@aybabtu.com>
6448 * disk/ata.c (grub_ata_dumpinfo): Use grub_dprintf() for debugging
6451 2008-07-27 Bean <bean123ch@gmail.com>
6453 * fs/fat.c (GRUB_FAT_MAXFILE): New constant.
6454 (grub_fat_find_dir): Ignore case when comparing filename.
6456 2008-07-27 Bean <bean123ch@gmail.com>
6458 * fs/xfs.c (grub_xfs_dir_header): Change field i8count back to
6459 smallino, as it's more descriptive, and i8count can be confused with
6460 the other field count.
6461 (grub_xfs_iterate_dir): Adjust grub_xfs_dir_entry pointer for small
6464 2008-07-27 Bean <bean123ch@gmail.com>
6466 * commands/crc.c: New file.
6468 * lib/crc.c: Likewise.
6470 * include/grub/lib/crc.h: Likewise.
6472 * util/grub-fstest.c: grub/hexdump.h => grub/lib/hexdump.h.
6474 * commands/hexdump.c: grub/hexdump.h => grub/lib/hexdump.h.
6475 (hexdump): Move this function to ...
6477 * lib/hexdump.c: ... here.
6479 * include/grub/hexdump.h: Renamed to ...
6481 * include/grub/lib/hexdump.h: ... this.
6483 * commands/loadenv.c: grub/envblk.h => grub/lib/envblk.h
6485 * util/grub-editenv.c: Likewise.
6487 * include/envblk.h: Renamed to ...
6489 * include/lib/envblk.h: ... this.
6491 * util/envblk.c: Renamed to ...
6493 * lib/envblk.c: ... this.
6495 * conf/common.rmk (grub_fstest_SOURCES): commands/hexdump.c =>
6497 (grub_editenv_SOURCES): util/envblk.c => lib/envblk.c
6498 (pkglib_MODULES): Add crc.mod.
6499 (hexdump_mod_SOURCES): Add lib/hexdump.c.
6500 (loadenv_mod_SOURCES): util/envblk.c => lib/envblk.c.
6501 (crc_mod_SOURCES): New macro.
6502 (crc_mod_CFLAGS): Likewise.
6503 (crc_mod_LDFLAGS): Likewise.
6505 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add lib/hexdump.c.
6507 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
6509 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
6511 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6513 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
6515 2008-07-27 Felix Zielcke <fzielcke@z-51.de>
6517 * commands/help.c: Include <grub/term.h>.
6518 (TERM_WIDTH): Removed. Updated all users.
6520 2008-07-27 Pavel Roskin <proski@gnu.org>
6522 * util/getroot.c (find_root_device): Rephrase a comment to avoid
6523 spurious warnings about a comment within a comment.
6525 2008-07-25 Robert Millan <rmh@aybabtu.com>
6527 * util/getroot.c (find_root_device): Skip devices that match
6528 /dev/dm-[0-9]. This lets the real device be found for any type of
6529 abstraction (LVM, EVMS, RAID..).
6530 (grub_guess_root_device): Do not traverse /dev/mapper (for LVM)
6531 and /dev/evms (for EVMS) before traversing /dev. If a /dev/dm-[0-9]
6532 device is found first, find_root_device() will now skip it.
6534 2008-07-24 Pavel Roskin <proski@gnu.org>
6536 * include/grub/types.h: Use __builtin_bswap32() and
6537 __builtin_bswap64() with gcc 4.3 and newer.
6539 2008-07-24 Christian Franke <franke@computer.org>
6541 * util/i386/pc/grub-install.in: If `--debug' is specified,
6542 pass `--verbose' to grub-setup.
6543 Abort script if make_system_path_relative_to_its_root() fails.
6545 2008-07-24 Bean <bean123ch@gmail.com>
6547 * configure.ac: Fixed a bug caused by the previous cygwin patch,
6548 variable `target_platform' should be `platform'.
6550 2008-07-24 Bean <bean123ch@gmail.com>
6552 * video/reader/png.c (DEFLATE_HLIT_MAX): Change value.
6553 (grub_png_init_fixed_block): New function.
6554 (grub_png_decode_image_data): Handle fixed huffman code compression.
6556 2008-07-24 Bean <bean123ch@gmail.com>
6558 * common.rmk (bin_UTILITIES): Add grub-pe2elf.
6559 (grub_pe2elf_SOURCES): New macro.
6560 (CLEANFILES): Add grub-pe2elf.
6562 * include/grub/efi/pe32.h (GRUB_PE32_SCN_ALIGN_1BYTES): New constant.
6563 (GRUB_PE32_SCN_ALIGN_2BYTES): Likewise.
6564 (GRUB_PE32_SCN_ALIGN_4BYTES): Likewise.
6565 (GRUB_PE32_SCN_ALIGN_8BYTES): Likewise.
6566 (GRUB_PE32_SCN_ALIGN_16BYTES): Likewise.
6567 (GRUB_PE32_SCN_ALIGN_32BYTES): Likewise.
6568 (GRUB_PE32_SCN_ALIGN_64BYTES): Likewise.
6569 (GRUB_PE32_SCN_ALIGN_SHIFT): Likewise.
6570 (GRUB_PE32_SCN_ALIGN_MASK): Likewise.
6571 (GRUB_PE32_SYM_CLASS_EXTERNAL): Likewise.
6572 (GRUB_PE32_SYM_CLASS_STATIC): Likewise.
6573 (GRUB_PE32_SYM_CLASS_FILE): Likewise.
6574 (GRUB_PE32_DT_FUNCTION): Likewise.
6575 (GRUB_PE32_REL_I386_DIR32): Likewise.
6576 (GRUB_PE32_REL_I386_REL32): Likewise.
6577 (grub_pe32_symbol): New structure.
6578 (grub_pe32_reloc): Likewise.
6580 * util/grub-pe2elf.c: New file.
6582 * configure.ac: Set TARGET_OBJ2ELF if host os is cygwin. Don't test for
6583 start symbol in non pc platform.
6585 * genmk.rb: Use TARGET_OBJ2ELF to convert native object format to elf.
6587 The following patches are from Christian Franke.
6589 * include/grub/dl.h: Remove .previous, gas supports this only
6592 * include/grub/symbol.h [__CYGWIN__] (#define FUNCTION/VARIABLE):
6593 Remove .type, gas supports this only for ELF format.
6595 * kern/dl.c (grub_dl_resolve_dependencies): Add check for trailing
6596 nullbytes in symbol table. This fixes an infinite loop if table is
6599 * Makefile.in: Add autoconf replacements TARGET_IMG_LDSCRIPT,
6600 TARGET_IMG_LDFLAGS and EXEEXT.
6602 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Replace -Wl,-N by
6603 TARGET_IMG_LDFLAGS_AC.
6604 (grub_CHECK_STACK_ARG_PROBE): New function.
6606 * conf/i386-pc.rmk: Replace -Wl,-N by TARGET_IMG_LDFLAGS.
6608 * conf/i386-pc-cygwin-ld-img.sc: New linker script.
6610 * configure.ac: Add check for linker script "conf/${target}-img-ld.c"
6611 to set TARGET_IMG_LD* accordingly.
6612 Add check for Cygwin to set TARGET_MOD_OBJCOPY accordingly.
6613 Add call to grub_CHECK_STACK_ARG_PROBE.
6614 Use TARGET_IMG_LDFLAGS to check start, bss_start, end symbols.
6616 * genkernsyms.sh.in: Handle HAVE_ASM_USCORE case.
6618 * genmk.rb: Add EXEEXT to CLEANFILES.
6620 2008-07-23 Robert Millan <rmh@aybabtu.com>
6622 * Makefile.in (UNICODE_ARROWS, UNICODE_LINES): New variables (they
6623 define the codes for arrows and lines used for the menu).
6624 (ascii.pff): Generate fonts for $(UNICODE_ARROWS) and $(UNICODE_LINES)
6627 * util/update-grub_lib.in (font_path): Prefer ascii.pff over complete
6628 fonts, because the latter are too slow.
6630 2008-07-21 Bean <bean123ch@gmail.com>
6632 * kern/i386/pc/startup.S (gate_a20_try_bios): Change test order for
6633 a20. Run keyboard test last, as it will cause macbook to halt.
6635 2008-07-18 Pavel Roskin <proski@gnu.org>
6637 * kern/dl.c: Go back to using GRUB_CPU_SIZEOF_VOID_P. We cannot
6638 load foreign architecture modules correctly anyway. Keep
6639 support for loading host architecture modules, whether we
6640 compile them or not.
6642 2008-07-17 Pavel Roskin <proski@gnu.org>
6644 * configure.ac: Use -m32 or -m64 regardless of whether we had to
6645 change target_cpu. The compiler default can mismatch target_cpu
6648 * disk/efi/efidisk.c: Fix format warnings on x86_64.
6649 * kern/efi/efi.c: Likewise.
6651 * aclocal.m4 (grub_PROG_TARGET_CC): New macro. Check if the
6652 target compiler is functional.
6653 * configure.ac: Call grub_PROG_TARGET_CC once all target flags
6656 * configure.ac: Default to efi platform for x86_64-apple. Allow
6657 powerpc64 CPU, default to ieee1275 platform for it. Split CPU
6658 adjustments from the rest, only do them if target is not
6659 explicitly given. Merge other adjustments with the final sanity
6660 check. Remove an extraneous check for supported CPU. Be
6661 specific which CPU and which platform is not supported.
6663 * configure.ac: Default to pc platform for x86_64.
6665 2008-07-17 Robert Millan <rmh@aybabtu.com>
6667 Partial LinuxBIOS -> Coreboot rename.
6669 * conf/i386-linuxbios.rmk: Renamed to ...
6670 * conf/i386-coreboot.rmk: ... this.
6671 * Makefile.in (RMKFILES): s/i386-linuxbios.rmk/i386-coreboot.rmk/g.
6672 * configure.ac: Accept "coreboot" as input platform (but maintain
6673 compatibility with "linuxbios").
6674 * include/grub/i386/linuxbios: Renamed to ...
6675 * include/grub/i386/coreboot: ... this.
6677 2008-07-17 Bean <bean123ch@gmail.com>
6679 * conf/i386/efi.rmk (pkglib_MODULES): add pci.mod and lspci.mod.
6680 (appleldr_mod_SOURCE): New variable.
6681 (appleldr_mod_CFLAGS): Likewise.
6682 (appleldr_mod_LDFLAGS): Likewise.
6683 (pci_mod_SOURCES): Likewise.
6684 (pci_mod_CFLAGS): Likewise.
6685 (pci_mod_LDFLAGS): Likewise.
6686 (lspci_mod_SOURCES): Likewise.
6687 (lspci_mod_CFLAGS): Likewise.
6688 (lspci_mod_LDFLAGS): Likewise.
6690 * conf/x86_64-efi.rmk: New file.
6692 * disk/efi/efidisk.c (grub_efidisk_read): Wrap efi calls with efi_call_N
6694 (grub_efidisk_write): Likewise.
6696 * include/efi/api.h (efi_call_0): New macro.
6697 (efi_call_1): Likewise.
6698 (efi_call_2): Likewise.
6699 (efi_call_3): Likewise.
6700 (efi_call_4): Likewise.
6701 (efi_call_5): Likewise.
6702 (efi_call_6): Likewise.
6704 * include/grub/efi/chainloader.h (grub_chainloader_cmd): Rename to
6705 grub_rescue_cmd_chainloader.
6707 * include/grub/efi/pe32.h (GRUB_PE32_MACHINE_X86_64): New macro.
6708 (grub_pe32_optional_header): Change some fields based on i386 or
6710 (GRUB_PE32_PE32_MAGIC): Likewise.
6712 * include/grub/efi/uga_draw.h: New file.
6714 * include/grub/elf.h (STN_ABS): New constant.
6715 (R_X86_64_NONE): Relocation constant for x86_64.
6716 (R_X86_64_64): Likewise.
6717 (R_X86_64_PC32): Likewise.
6718 (R_X86_64_GOT32): Likewise.
6719 (R_X86_64_PLT32): Likewise.
6720 (R_X86_64_COPY): Likewise.
6721 (R_X86_64_GLOB_DAT): Likewise.
6722 (R_X86_64_JUMP_SLOT): Likewise.
6723 (R_X86_64_RELATIVE): Likewise.
6724 (R_X86_64_GOTPCREL): Likewise.
6725 (R_X86_64_32): Likewise.
6726 (R_X86_64_32S): Likewise.
6727 (R_X86_64_16): Likewise.
6728 (R_X86_64_PC16): Likewise.
6729 (R_X86_64_8): Likewise.
6730 (R_X86_64_PC8): Likewise.
6732 * include/grub/i386/efi/pci.h: New file.
6734 * include/grub/i386/linux.h (GRUB_LINUX_EFI_SIGNATURE):
6735 Change it value based on platform.
6736 (GRUB_LINUX_EFI_SIGNATURE_0204): New constant.
6737 (GRUB_E820_RAM): Likewise.
6738 (GRUB_E820_RESERVED): Likewise.
6739 (GRUB_E820_ACPI): Likewise.
6740 (GRUB_E820_NVS): Likewise.
6741 (GRUB_E820_EXEC_CODE): Likewise.
6742 (GRUB_E820_MAX_ENTRY): Likewise.
6743 (grub_e820_mmap): New structure.
6744 (linux_kernel_header): Change the efi field according to different
6745 kernel version, also field from linux_kernel_header.
6747 * include/grub/kernel.h (grub_module_info): Add padding for x86_64.
6749 * include/grub/pci.h (GRUB_PCI_ADDR_SPACE_MASK): New constant.
6750 (GRUB_PCI_ADDR_SPACE_MEMORY): Likewise.
6751 (GRUB_PCI_ADDR_SPACE_IO): Likewise.
6752 (GRUB_PCI_ADDR_MEM_TYPE_MASK): Likewise.
6753 (GRUB_PCI_ADDR_MEM_TYPE_32): Likewise.
6754 (GRUB_PCI_ADDR_MEM_TYPE_1M): Likewise.
6755 (GRUB_PCI_ADDR_MEM_TYPE_64): Likewise.
6756 (GRUB_PCI_ADDR_MEM_PREFETCH): Likewise.
6757 (GRUB_PCI_ADDR_MEM_MASK): Likewise.
6758 (GRUB_PCI_ADDR_IO_MASK): Likewise.
6760 * include/grub/x86_64/efi/kernel.h: New file.
6762 * include/grub/x86_64/efi/loader.h: Likewise.
6764 * include/grub/x86_64/efi/machine.h: Likewise.
6766 * include/grub/x86_64/efi/pci.h: Likewise.
6768 * include/grub/x86_64/efi/time.h: Likewise.
6770 * include/grub/x86_64/linux.h: Likewise.
6772 * include/grub/x86_64/setjmp.h: Likewise.
6774 * include/grub/x86_64/time.h: Likewise.
6776 * include/grub/x86_64/types.h: Likewise.
6778 * kern/dl.c (GRUB_CPU_SIZEOF_VOID_P): Changed to
6779 GRUB_TARGET_SIZEOF_VOID_P.
6781 * kern/efi/efi.c (grub_efi_locate_protocol): Wrap efi calls.
6782 (grub_efi_locate_handle): Likewise.
6783 (grub_efi_open_protocol): Likewise.
6784 (grub_efi_set_text_mode): Likewise.
6785 (grub_efi_stall): Likewise.
6786 (grub_exit): Likewise.
6787 (grub_reboot): Likewise.
6788 (grub_halt): Likewise.
6789 (grub_efi_exit_boot_services): Likewise.
6790 (grub_get_rtc): Likewise.
6792 * kern/efi/mm.c (MEMORY_MAP_SIZE): Change to 0x3000 for new models.
6793 (GRUB_CPU_SIZEOF_VOID_P): Changed to GRUB_TARGET_SIZEOF_VOID_P.
6794 (grub_efi_allocate_pages): Wrap efi calls.
6795 (grub_efi_free_pages): Wrap efi calls.
6796 (grub_efi_get_memory_map): Wrap efi calls.
6798 * kern/x86_64/dl.c: New file.
6800 * kern/x86_64/efi/callwrap.S: Likewise.
6802 * kern/x86_64/efi/startup.S: Likewise.
6804 * loader/efi/appleloader.c: Likewise.
6806 * loader/efi/chainloader.c (cmdline): New variable.
6807 (grub_chainloader_unload): Wrap efi calls.
6808 (grub_chainloader_boot): Likewise.
6809 (grub_rescue_cmd_chainloader): Wrap efi calls, handle
6812 * loader/efi/chainloader_normal.c (chainloader_command):
6813 Change grub_chainloader_cmd to grub_rescue_cmd_chainloader, pass
6816 * loader/i386/efi/linux.c (allocate_pages): Change allocation
6818 (grub_e820_add_region): New function.
6819 (grub_linux_boot): Construct e820 map from efi map, handle x86_64
6821 (grub_find_video_card): New function.
6822 (grub_linux_setup_video): New function.
6823 (grub_rescue_cmd_linux): Probe for video information.
6825 * normal/x86_64/setjmp.S: New file.
6827 * term/efi/console.c (map_char): New function.
6828 (grub_console_putchar): Map unicode char.
6829 (grub_console_checkkey): Wrap efi calls.
6830 (grub_console_getkey): Likewise.
6831 (grub_console_getwh): Likewise.
6832 (grub_console_gotoxy): Likewise.
6833 (grub_console_cls): Likewise.
6834 (grub_console_setcolorstate): Likewise.
6835 (grub_console_setcursor): Likewise.
6837 * util/i386/efi/grub-mkimage.c: Add support for x86_64.
6839 2008-07-16 Pavel Roskin <proski@gnu.org>
6841 * loader/i386/efi/linux.c (allocate_pages): Fix warnings in
6844 * util/i386/efi/grub-mkimage.c (get_target_address): Return a
6845 pointer, not an integer. This fixes a warning and prevents
6846 precision loss on 64-bit systems.
6847 (relocate_addresses): Remove unneeded cast.
6849 2008-07-15 Pavel Roskin <proski@gnu.org>
6851 * kern/i386/ieee1275/init.c: Include grub/cache.h.
6853 * term/ieee1275/ofconsole.c: Disable code unused on i386.
6855 * kern/ieee1275/ieee1275.c (grub_ieee1275_get_integer_property):
6856 Fix comparison between signed and unsigned.
6858 * include/grub/i386/ieee1275/console.h: Declare
6859 grub_console_init() and grub_console_fini().
6861 * loader/i386/ieee1275/linux.c (grub_set_bootpath): Remove.
6862 It's empty and unused.
6864 * fs/ext2.c (grub_ext2_read_block): Initialize blknr in the
6865 beginning to avoid warnings with some compilers.
6867 * loader/ieee1275/multiboot2.c: Include grub/machine/loader.h.
6868 [__i386__] (grub_mb2_arch_boot): Avoid unnecessary cast.
6870 2008-07-14 Pavel Roskin <proski@gnu.org>
6872 * kern/env.c (grub_register_variable_hook): Don't copy empty
6873 string, it leaks memory. Pass "" to grub_env_set(), it should
6874 handle constant strings.
6876 * commands/blocklist.c (grub_cmd_blocklist): Fix format warning.
6877 * commands/cmp.c (grub_cmd_cmp): Likewise.
6878 * kern/dl.c (grub_dl_flush_cache): Likewise.
6879 (grub_dl_load_core): Likewise.
6880 * kern/elf.c (grub_elf32_load_phdrs): Likewise.
6881 (grub_elf64_load_phdrs): Likewise.
6883 2008-07-13 Pavel Roskin <proski@gnu.org>
6885 * lib/LzmaEnc.c (LzmaEnc_SetProps): Fix warning about comparison
6886 between signed and unsigned.
6887 (LzmaEnc_Finish): Fix warning about an unused parameter.
6889 2008-07-13 Bean <bean123ch@gmail.com>
6891 * Makefile.in (enable_lzo): New rule.
6893 * conf/i386-pc.rmk (grub_mkimage_SOURCES): New test with enable_lzo.
6895 * configure.ac (ENABLE_LZO): New option --enable-lzo.
6897 * boot/i386/pc/lnxboot.S: #include <config.h>.
6899 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE): Change
6900 its value according to the compression algorithm used, lzo or lzma.
6902 * util/i386/pc/grub-mkimage.c (compress_kernel): Use different
6903 compression algorithm according to configure macro.
6905 * kern/i386/pc/startup.S (codestart): Likewise.
6907 * kern/i386/pc/lzma_decode.S: New file.
6909 * include/grub/lib/LzFind.h: Likewise.
6911 * include/grub/lib/LzHash.h: Likewise.
6913 * include/grub/lib/LzmaDec.h: Likewise.
6915 * include/grub/lib/LzmaEnc.h: Likewise.
6917 * include/grub/lib/LzmaTypes.h: Likewise.
6919 * lib/LzFind.c: Likewise.
6921 * lib/LzmaDec.c: Likewise.
6923 * lib/LzmaEnc.c: Likewise.
6925 2008-07-13 Bean <bean123ch@gmail.com>
6927 * fs/ext2.c (EXT4_EXTENTS_FLAG): New macro.
6928 (grub_ext4_extent_header): New structure.
6929 (grub_ext4_extent): Likewise.
6930 (grub_ext4_extent_idx): Likewise.
6931 (grub_ext4_find_leaf): New function.
6932 (grub_ext2_read_block): Handle extents.
6934 2008-07-12 Robert Millan <rmh@aybabtu.com>
6936 * util/i386/pc/grub-mkrescue.in: s/grub-install/grub-mkrescue/g.
6938 2008-07-11 Robert Millan <rmh@aybabtu.com>
6940 * util/grub.d/40_custom.in: New file. Example on how to add custom
6941 entries to /etc/grub.d.
6942 * conf/common.rmk (%, update-grub_SCRIPTS, CLEANFILES): Install
6943 40_custom (implicitly, by merging all the grub.d rules).
6945 2008-07-11 Pavel Roskin <proski@gnu.org>
6947 * commands/read.c (grub_getline): Fix invalid memory access.
6948 Don't add newline to the variable value.
6950 * term/i386/pc/serial.c (GRUB_SERIAL_PORT_NUM): New constant.
6951 [!GRUB_MACHINE_PCBIOS] (serial_hw_io_addr): Add COM2 and COM3.
6952 (serial_hw_get_port): Check validity of the port number.
6953 (grub_cmd_serial): Check return value of serial_hw_get_port().
6955 2008-07-07 Pavel Roskin <proski@gnu.org>
6957 * boot/i386/pc/diskboot.S (notification_string): Replace
6958 "Loading kernel" with just "loading". This is shorter, less
6959 confusing and saves a few bytes for possible future changes.
6961 2008-07-05 Pavel Roskin <proski@gnu.org>
6963 * disk/ata.c (grub_ata_dumpinfo): Don't output addressing and
6964 size for ATAPI devices, they are undefined. Output sector
6965 number in decimal form.
6967 * disk/ata.c: Use named constants for status bits.
6969 2008-07-04 Pavel Roskin <proski@gnu.org>
6971 * kern/i386/linuxbios/init.c (grub_machine_init): Cast addr to
6972 grub_addr_t before casting it to the void pointer to fix a
6973 warning. Non-addressable regions are discarded earlier.
6974 (grub_arch_modules_addr): Cast _end to grub_addr_t.
6975 * kern/i386/linuxbios/table.c: Include grub/misc.h.
6976 (check_signature): Don't shadow table_header.
6977 (grub_linuxbios_table_iterate): Cast numeric constants to
6978 grub_linuxbios_table_header_t.
6979 * include/grub/i386/linuxbios/init.h: Add noreturn attribute to
6982 * kern/ieee1275/init.c: Cast _start and _end to grub_addr_t to
6985 * include/grub/misc.h (ALIGN_UP): Avoid unnecessary cast to a
6986 pointer, which can cause warnings. Support 64-bit addresses.
6988 * util/elf/grub-mkimage.c: Use GRUB_TARGET_SIZEOF_LONG instead
6989 of sizeof(long). This fixes PowerPC image generation on x86_64.
6991 2008-07-04 Robert Millan <rmh@aybabtu.com>
6993 This fixes a performance issue when pc & gpt partmap iterators
6994 didn't abort iteration even after our hook found what it was
6995 looking for (often causing expensive probes of non-existent drives).
6997 Some callers relied on previous buggy behaviour, since they would
6998 raise an error when their own hooks caused early abortion of its
7001 * kern/device.c (grub_device_open): Improve error message.
7002 * disk/lvm.c (grub_lvm_open): Likewise.
7003 * disk/raid.c (grub_raid_open): Likewise.
7005 * partmap/pc.c (pc_partition_map_iterate): Abort parent iteration
7006 when hook requests it, independently of grub_errno.
7007 (pc_partition_map_probe): Do not fail when find_func() caused
7008 early abortion of pc_partition_map_iterate().
7010 * partmap/gpt.c (gpt_partition_map_iterate): Abort parent iteration
7011 when hook requests it, independently of grub_errno.
7012 (gpt_partition_map_probe): Do not fail when find_func() caused
7013 early abortion of gpt_partition_map_iterate().
7015 * kern/partition.c (grub_partition_iterate): Abort parent iteration
7016 when hook requests it, independently of grub_errno. Do not fail when
7017 part_map_iterate_hook() caused early abortion of p->iterate().
7019 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Do not fail
7020 when grub_partition_iterate() returned with non-zero.
7022 2008-07-03 Pavel Roskin <proski@gnu.org>
7024 * disk/ata.c (grub_ata_pio_write): Check status before writing,
7025 like we do in grub_ata_pio_read().
7026 (grub_ata_readwrite): Always write individual sectors. Fix the
7027 sector count for the remainder.
7028 (grub_ata_write): Enable writing to ATA devices. Correctly
7029 report error for ATAPI devices.
7031 2008-07-02 Pavel Roskin <proski@gnu.org>
7033 * boot/i386/pc/cdboot.S: Add _start entry to fix a linker
7036 * disk/ata.c (grub_ata_readwrite): Don't increment sector number
7037 for every read sector, we already increment it for the whole
7038 batch. This fixes reading more than 256 sectors at once.
7040 * util/grub-editenv.c (cmd_info): Cast argument to long
7041 explicitly. ptrdiff_t reduces to int on i386.
7043 * util/grub-editenv.c (main): Be specific which parameter is
7046 * disk/memdisk.c (memdisk_addr): Make a pointer to fix warnings.
7047 (memdisk): Make memdisk_orig_addr a pointer.
7049 * fs/reiserfs.c (grub_reiserfs_read): Fix misuse of grub_size_t
7050 for file offsets, use grub_off_t instead. Fix printf format
7053 * fs/reiserfs.c: Remove #warning, TODO list items don't belong
7054 there. Real unexpected warnings should not drown in the noise
7055 about known problems.
7057 * commands/hexdump.c (grub_cmd_hexdump): Fix misuse of
7058 grub_disk_addr_t for memory addresses.
7060 * loader/aout.c (grub_aout_load): Cast load_addr to pointer
7061 explicitly to fix a warning.
7063 * util/grub-editenv.c (cmd_info): Fix warning in printf format.
7065 * Makefile.in (MODULE_LDFLAGS): New variable.
7066 * aclocal.m4 (grub_PROG_LD_BUILD_ID_NONE): New macro. Check if
7067 the linker accepts --build-id=none.
7068 * configure.ac: Call grub_PROG_LD_BUILD_ID_NONE. Substitute
7070 * genmk.rb: Use MODULE_LDFLAGS when linking modules.
7072 * fs/xfs.c (struct grub_xfs_dir_header): Use names similar to
7073 those in Linux XFS code. Provide a way to access 64-bit parent
7075 (grub_xfs_iterate_dir): Use the new names. Avoid reading past
7076 the end of struct grub_xfs_dir_header.
7078 2008-07-02 Bean <bean123ch@gmail.com>
7080 * include/grub/ieee1275.h (grub_ieee1275_flag): New constant
7081 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
7082 and GRUB_IEEE1275_FLAG_NO_ANSI.
7084 * kern/ieee1275/cmain.c (grub_ieee1275_find_options): Set flag
7085 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
7086 and GRUB_IEEE1275_FLAG_NO_ANSI for Open Hackware.
7088 * kern/ieee1275/ieee1275.c (grub_ieee1275_interpret): Return
7089 immediately if GRUB_IEEE1275_FLAG_CANNOT_INTERPRET is set.
7091 * kern/ieee1275/init.c (grub_claim_heap): Claim memory directly if
7092 GRUB_IEEE1275_FLAG_FORCE_CLAIM is set.
7094 * term/ieee1275/ofconsole.c (grub_ofconsole_writeesc): Don't output
7095 esc sequence on non ANSI terminal.
7096 (grub_ofconsole_gotoxy): Emulate backspace key on non ANSI terminal.
7098 * util/elf/grub-mkimage.c (add_segments): Move ELF header to the
7101 2008-07-02 Bean <bean123ch@gmail.com>
7103 * conf/common.rmk (bin_UTILITIES): Add grub-editenv.
7104 (grub_editenv_SOURCES): New variable.
7105 (pkglib_MODULES): Add loadenv.mod.
7106 (loadenv_mod_SOURCES): New variable.
7107 (loadenv_mod_CFLAGS): Likewise.
7108 (loadenv_mod_LDFLAGS): Likewise.
7110 * include/grub/envblk.h: New file.
7112 * util/envblk.c: New file.
7114 * util/grub-editenv.c: New file.
7116 * commands/loadenv.c: New file.
7118 2008-07-01 Pavel Roskin <proski@gnu.org>
7120 * include/multiboot2.h (struct multiboot_tag_module): Use char,
7121 not unsigned char. This fixes warnings and is consistent with
7124 * disk/fs_uuid.c (search_fs_uuid): Correctly increment count.
7126 * normal/parser.y: Define YYENABLE_NLS as 0 to fix warnings.
7128 * term/tparm.c (analyze): Always set *popcount.
7130 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Remove useless
7131 cast to fix a warning.
7133 * loader/i386/pc/multiboot2.c (grub_mb2_arch_module_alloc): Use
7134 cast to suppress a warning.
7136 * fs/afs.c (grub_afs_read_block): Return grub_disk_addr_t, as
7137 grub_fshelp_read_file() expects.
7139 * fs/fat.c: Fix UUID calculation on big-endian systems. We
7140 write uuid as a 32-bit value in CPU byte order, so declare and
7143 * disk/raid.c: Cast grub_dprintf() arguments to unsigned long
7144 long if the format specifier expects it.
7145 * partmap/gpt.c (gpt_partition_map_iterate): Likewise.
7146 * partmap/pc.c (pc_partition_map_iterate): Likewise.
7147 * fs/ntfs.c (grub_ntfs_uuid): Cast data->uuid to unsigned long
7148 long to fix a warning.
7149 * fs/reiserfs.c (grub_reiserfs_read): Change casts in
7150 grub_dprintf() arguments to fix warnings.
7152 2008-06-30 Pavel Roskin <proski@gnu.org>
7154 * util/i386/pc/grub-setup.c (setup): Write install_dos_part and
7155 install_bsd_part immediately before core.img is embedded or
7156 modified on disk. This fixes core.img verification if core.img
7159 * util/i386/pc/grub-setup.c (setup): Use core_path_dev, not
7160 core_path to calculate the blocklist.
7161 Patch from Javier MartÃn <lordhabbit@gmail.com>
7163 2008-06-29 Robert Millan <rmh@aybabtu.com>
7165 * fs/xfs.c (GRUB_XFS_FSB_TO_BLOCK): New macro. Maps filesystem
7166 block to disk block.
7167 (grub_xfs_read_block): Use GRUB_XFS_FSB_TO_BLOCK() on result.
7168 Patch from Niels Böhm <bitbucket@arcor.de>
7170 2008-06-29 Robert Millan <rmh@aybabtu.com>
7172 * util/update-grub_lib.in (font_path): Search for fonts in
7173 /boot/grub first, which is more likely to be readable (we aren't
7174 deciding where fonts live, just looking for them).
7176 2008-06-26 Pavel Roskin <proski@gnu.org>
7178 * util/biosdisk.c (read_device_map): Don't leave dead map
7179 entries for devices failing stat() check.
7181 * util/i386/pc/grub-setup.c (setup): Don't reuse core_path, use
7182 core_path_dev for the core.img path on the target device.
7184 2008-06-26 Robert Millan <rmh@aybabtu.com>
7186 * disk/fs_uuid.c: New file.
7187 * conf/common.rmk (pkglib_MODULES): Add `fs_uuid.mod'.
7188 (fs_uuid_mod_SOURCES, fs_uuid_mod_CFLAGS)
7189 (fs_uuid_mod_LDFLAGS): New variables.
7190 * include/grub/disk.h (grub_disk_dev_id): Add
7191 `GRUB_DISK_DEVICE_UUID_ID'.
7192 * kern/disk.c (grub_disk_dev_iterate): Allow disk devices not to
7193 implement iterate().
7195 2008-06-26 Robert Millan <rmh@aybabtu.com>
7197 * util/grub.d/10_linux.in: Avoid passing UUIDs to Linux when either
7198 "/dev/disk/by-uuid/${GRUB_DEVICE_UUID}" does not exist, or when a
7199 Linux image includes no initrd.
7201 2008-06-21 Javier MartÃn <lordhabbit@gmail.com>
7203 * util/i386/pc/grub-setup.c (setup): Remove literal "core.img" in a
7204 call to resolve the core image location that effectively appended the
7207 2008-06-21 Robert Millan <rmh@aybabtu.com>
7209 * util/grub.d/00_header.in: Move last prepare_grub_to_access_device()
7212 * util/grub.d/10_hurd.in: ... to here ...
7213 * util/grub.d/10_linux.in: ... and here.
7215 2008-06-19 Robert Millan <rmh@aybabtu.com>
7217 * kern/main.c (grub_main): Export `prefix' variable immediately
7218 after it has been set by grub_machine_set_prefix().
7220 2008-06-19 Robert Millan <rmh@aybabtu.com>
7222 * commands/search.c (search_label, search_fs_uuid, search_file): Print
7223 search result when not saving to variable, not the other way around.
7224 When saving to variable, abort iteration as soon as a match is found.
7226 2008-06-19 Robert Millan <rmh@aybabtu.com>
7228 * util/update-grub_lib.in (prepare_grub_to_access_device): Remove
7229 check for partition that provides /boot/grub. Its logic is flawed,
7230 as it prevents prepare_grub_to_access_device() from being called
7233 2008-06-19 Robert Millan <rmh@aybabtu.com>
7235 * util/update-grub_lib.in (prepare_grub_to_access_device): Issue
7236 "insmod" command directly when abstraction modules are needed,
7237 instead of relying on GRUB_PRELOAD_MODULES (which had no effect
7238 since it had already been processed).
7240 2008-06-19 Pavel Roskin <proski@gnu.org>
7242 * conf/i386-efi.rmk: Recompile grub-mkimage.c if Makefile has
7243 changed. This is needed in case GRUB_LIBDIR changes.
7244 * conf/i386-ieee1275.rmk: Likewise.
7245 * conf/i386-linuxbios.rmk: Likewise.
7246 * conf/i386-pc.rmk: Likewise.
7247 * conf/powerpc-ieee1275.rmk: Likewise.
7249 2008-06-18 Pavel Roskin <proski@gnu.org>
7251 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Rename
7252 kernel_elf_symlist.c to symlist.c for consistency with other
7253 architectures. Update all users.
7254 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
7256 2008-06-18 Robert Millan <rmh@aybabtu.com>
7258 * util/i386/pc/grub-install.in: If the drive is LVM or RAID, prepend
7261 * util/i386/pc/grub-setup.c (main): Don't handle prefix at all. Set
7262 `must_embed' to 1 when root_dev is a RAID device. When dest_dev is
7263 a RAID device, run setup() for all members independently on whether
7264 LVM abstraction is being used.
7265 (setup): Don't handle prefix at all; let grub-mkimage take care of it.
7266 If grub-mkimage has set `*install_dos_part == -2', don't override this
7268 Perform *install_dos_part adjustments independently on whether
7269 we're embedding or not.
7270 Clarify error message when image is too big for embedding.
7271 Remove duplicate *install_dos_part stanza.
7273 2008-06-17 Robert Millan <rmh@aybabtu.com>
7275 * term/ieee1275/ofconsole.c (fgcolor, bgcolor): Remove variables.
7276 (grub_ofconsole_normal_color, grub_ofconsole_highlight_color): New
7278 (grub_ofconsole_setcolor, grub_ofconsole_getcolor): Load/store
7279 values in grub_ofconsole_normal_color and
7280 grub_ofconsole_highlight_color (they're not directly related to
7281 background and foreground).
7282 (grub_ofconsole_setcolorstate): Extract background and foreground
7283 from grub_ofconsole_normal_color and grub_ofconsole_highlight_color.
7285 2008-06-17 Robert Millan <rmh@aybabtu.com>
7287 * util/update-grub_lib.in (prepare_grub_to_access_device): Use
7288 /boot/grub for the check in last commit, not /boot (they could be
7289 different partitions).
7291 2008-06-16 Robert Millan <rmh@aybabtu.com>
7293 * util/update-grub_lib.in (prepare_grub_to_access_device): If we were
7294 asked to setup access for the same partition that provides /boot,
7295 don't bother using UUIDs since our root already has the value we
7298 2008-06-16 Robert Millan <rmh@aybabtu.com>
7300 * util/biosdisk.c (convert_system_partition_to_system_disk): Detect
7302 Patch from Sven Mueller <sven@debian.org>.
7304 2008-06-16 Robert Millan <rmh@aybabtu.com>
7306 * util/update-grub.in: Check for $EUID instead of $UID.
7307 Reported by Vincent Zweije.
7309 2008-06-16 Bean <bean123ch@gmail.com>
7311 * fs/ext2.c (grub_ext2_blockgroup): Revert to pre-journal state.
7312 (grub_ext2_read_block): Likewise.
7313 (grub_ext2_read_inode): Likewise.
7314 (grub_ext2_mount): Likewise.
7315 (grub_ext2_close): Likewise.
7316 (grub_ext3_get_journal): Removed.
7318 * fs/reiserfs.c (grub_reiserfs_get_item): Revert to pre-journal state.
7319 (grub_reiserfs_read_symlink): Likewise.
7320 (grub_reiserfs_mount): Likewise.
7321 (grub_reiserfs_open): Likewise.
7322 (grub_reiserfs_read): Likewise.
7323 (grub_reiserfs_close): Likewise.
7324 (grub_reiserfs_get_journal): Removed.
7326 * fs/fshelp.c (grub_fshelp_read): Removed.
7327 (grub_fshelp_map_block): Likewise.
7329 * include/grub/fshelp.h (grub_fshelp_journal_type): Removed.
7330 (grub_fshelp_journal): Likewise.
7331 (grub_fshelp_read): Likewise.
7332 (grub_fshelp_map_block): Likewise.
7334 2008-06-16 Pavel Roskin <proski@gnu.org>
7336 * conf/powerpc-ieee1275.rmk: Remove -msoft-float, we don't use
7337 floating point anymore.
7338 * include/grub/powerpc/libgcc.h: Leave only necessary exports.
7340 2008-06-15 Pavel Roskin <proski@gnu.org>
7342 * commands/ls.c (grub_ls_list_files): Use integer calculations
7343 for human readable format, avoid floating point use.
7344 * kern/misc.c (grub_ftoa): Remove.
7345 (grub_vsprintf): Remove floating point support.
7347 2008-06-15 Robert Millan <rmh@aybabtu.com>
7349 * util/grub.d/10_linux.in: Use the underlying device for loop-AES
7351 Reported by Max Vozeler.
7353 2008-06-15 Robert Millan <rmh@aybabtu.com>
7355 * util/i386/pc/grub-mkimage.c (generate_image): If we included a drive
7356 in our prefix, set install_{dos,bsd}_part = -2 to indicate this can be
7358 (main): If a memdisk was requested, add "(memdisk)" drive explicitly to
7359 the beginning of the prefix.
7361 * kern/i386/pc/init.c (make_install_device): Remove memdisk check.
7362 It is assumed that if we have a memdisk, grub-mkimage has set
7363 grub_prefix to include the "(memdisk)" drive in it.
7365 2008-06-15 Robert Millan <rmh@aybabtu.com>
7367 * term/i386/pc/console.c [GRUB_MACHINE_LINUXBIOS] (grub_console_init):
7368 Initialize keyboard controller after registering the terminal, so that
7369 grub_printf() can be called from grub_keyboard_controller_init().
7371 2008-06-15 Robert Millan <rmh@aybabtu.com>
7373 * fs/sfs.c (grub_sfs_read_extent): Fix the count of nodes in
7374 extent-btree which is written as big endian on disk.
7375 Reported by Alain Greppin <al@chilibi.org>.
7377 2008-06-14 Robert Millan <rmh@aybabtu.com>
7379 * util/i386/efi/grub-install.in (modules): Remove `_chain'.
7380 * util/i386/pc/grub-install.in (modules): Likewise.
7382 2008-06-13 Pavel Roskin <proski@gnu.org>
7384 * commands/ls.c (grub_ls_list_files): Fix format warnings.
7386 2008-06-13 Bean <bean123ch@gmail.com>
7388 * commands/hexdump.c (grub_cmd_hexdump): Adjust offset for partition.
7390 * fs/ext2.c (grub_ext3_get_journal): Fix revoke block handling.
7392 * fs/fshelp.c (grub_fshelp_map_block): Don't map block 0 as it's used
7393 to indicate sparse block.
7395 2008-06-12 Pavel Roskin <proski@gnu.org>
7397 * fs/ext2.c (grub_ext2_read_inode): Don't normalize block
7398 number, grub_fshelp_read() does it for us.
7400 * fs/fshelp.c (grub_fshelp_read): New function. Implement
7401 linear disk read with journal translation.
7402 * fs/ext2.c: Use grub_fshelp_read() instead of grub_disk_read().
7403 * include/grub/fshelp.h: Declare grub_fshelp_read().
7405 2008-06-09 Pavel Roskin <proski@gnu.org>
7407 * fs/minix.c (grub_minix_mount): Handle error reading
7410 2008-06-08 Robert Millan <rmh@aybabtu.com>
7412 * util/i386/pc/grub-setup.c (main): If install drive is an LVM,
7413 don't append the RAID prefix afterwards.
7414 Reported by Clint Adams.
7416 2008-06-08 Robert Millan <rmh@aybabtu.com>
7418 Based on description from Pavel:
7419 * kern/disk.c (grub_disk_check_range): Rename to ...
7420 (grub_disk_adjust_range): ... this. Add a comment explaining the
7421 tasks performed by this function.
7423 2008-06-08 Robert Millan <rmh@aybabtu.com>
7425 * include/grub/ntfs.h (struct grub_ntfs_bpb): Rename `serial_number' to
7426 `num_serial' (for consistency with other variables).
7427 (struct grub_ntfs_data): Add `uuid' member.
7428 * fs/ntfs.c (grub_ntfs_mount): Initialize `data->uuid'.
7429 (grub_ntfs_uuid): New function.
7430 (grub_ntfs_fs): Reference grub_ntfs_uuid() in `uuid' struct member.
7432 2008-06-07 Pavel Roskin <proski@gnu.org>
7434 * util/biosdisk.c (open_device): Revert last change to the
7435 function, it broke installation. The sector needs to be
7436 different dependent on which device is opened.
7438 2008-06-06 Robert Millan <rmh@aybabtu.com>
7440 Ensure GRUB_KERNEL_MACHINE_DATA_END is always consistent with the
7441 rest of GRUB, and breakage doesn't happen if its value were modified.
7443 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
7444 Redefine as an offset from `GRUB_KERNEL_MACHINE_DATA_END' instead of
7445 a constant (same value).
7446 * kern/i386/pc/startup.S: Replace hardcoded `0x50' with
7447 `GRUB_KERNEL_MACHINE_DATA_END' (same value).
7449 2008-06-06 Robert Millan <rmh@aybabtu.com>
7451 * util/biosdisk.c (open_device): Do not modify sector offset when
7452 accessing a partition. kern/disk.c already handles this for us.
7454 2008-06-06 Robert Millan <rmh@aybabtu.com>
7456 * util/grub-emu.c (grub_machine_init): Move code in this function from
7458 (main): ... to here (before grub_util_biosdisk_init() call, to prevent
7459 segfault in case grub_printf() is called).
7461 * util/i386/pc/grub-install.in: Append `--device-map=${device_map}' to
7462 grub_probe. Update all users not to explicitly add it again.
7463 (grub_device): New variable; contains corresponding device for grubdir.
7464 (fs_module, partmap_module, devabstraction_module): Pass
7465 `--device ${grub_device}' to grub_probe to avoid traversing /dev
7468 2008-06-05 Robert Millan <rmh@aybabtu.com>
7470 * normal/misc.c (grub_normal_print_device_info): When a filesystem UUID
7471 is found, print it (same layout as with labels).
7473 2008-06-04 Robert Millan <rmh@aybabtu.com>
7475 * util/biosdisk.c (get_drive): Rename to ...
7476 (find_grub_drive): ... this. Update all users.
7478 (get_os_disk): Rename to ...
7479 (convert_system_partition_to_system_disk): ... this. Update all users.
7481 (find_drive): Rename to ...
7482 (find_system_device): ... this. Update all users.
7484 2008-06-04 Robert Millan <rmh@aybabtu.com>
7486 * util/biosdisk.c (get_os_disk): Handle IDA devices.
7487 * util/grub-mkdevicemap.c (get_mmc_disk_name)
7488 (make_device_map): Likewise.
7490 2008-06-01 Robert Millan <rmh@aybabtu.com>
7492 * util/biosdisk.c (get_drive): Verify that `map[i].drive' is non-NULL
7493 before dereferencing it.
7495 * fs/fat.c (struct grub_fat_bpb): Move fat32-specific fields into a
7496 union with fat12/fat16-specific ones. Add some new fields, including
7497 `num_serial' for both versions.
7498 (struct grub_fat_data): Add `uuid' member.
7499 (grub_fat_mount): Refer to fat32-specific fields in `bpb' by their new
7500 names. Initialize `data->uuid' using `num_serial'.
7501 (grub_fat_uuid): New function.
7502 (grub_fat_fs): Reference grub_fat_uuid() in `uuid' struct member.
7504 * fs/reiserfs.c (grub_reiserfs_superblock): Add `uuid' field.
7505 (grub_reiserfs_uuid): New function.
7506 (grub_reiserfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct
7509 * fs/xfs.c (grub_xfs_sblock): Add `uuid' field.
7510 (grub_xfs_uuid): New function.
7511 (grub_xfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct member.
7513 2008-06-01 Robert Millan <rmh@aybabtu.com>
7515 * util/update-grub_lib.in (prepare_grub_to_access_device): Generate
7516 code that is backward compatible with pre-uuid search command.
7518 2008-05-31 Robert Millan <rmh@aybabtu.com>
7520 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Iterate through
7521 floppies after everything else, to ensure floppy drive isn't accessed
7522 unnecessarily (patch from Bean).
7524 2008-05-31 Robert Millan <rmh@aybabtu.com>
7526 * commands/search.c (search_label, search_fs_uuid, search_file): Do
7527 not print device names when we were asked to set a variable.
7529 2008-05-31 Robert Millan <rmh@aybabtu.com>
7531 * term/ieee1275/ofconsole.c (grub_ofconsole_setcursor): Implement
7532 using "cursor-on" and "cursor-off" commands (understood at least by
7533 the Open Firmware flavour on OLPC).
7535 2008-05-31 Michael Gorven <michael@gorven.za.net>
7537 * term/terminfo.c (grub_terminfo_set_current): Correct vt100 cursor
7538 on and off sequences.
7540 2008-05-31 Robert Millan <rmh@aybabtu.com>
7542 * util/update-grub_lib.in: Replace `grub-probe' with `${grub_probe}'.
7543 * util/update-grub.in: Likewise.
7545 2008-05-30 Pavel Roskin <proski@gnu.org>
7547 * util/biosdisk.c (linux_find_partition): Simplify logic and
7548 make the code more universal. Keep special processing for
7549 devfs, but use a simple rule for all other devices. If the
7550 device ends with a number, append 'p' and the partition number.
7551 Otherwise, append only the partition number.
7553 2008-05-30 Robert Millan <rmh@aybabtu.com>
7555 * util/update-grub.in (GRUB_DISABLE_LINUX_UUID): Export variable.
7556 * util/grub.d/10_linux.in: If GRUB_DEVICE_UUID is set, and
7557 GRUB_DISABLE_LINUX_UUID isn't true, use the filesystem UUIDs as
7558 the `root' parameter to Linux.
7560 2008-05-30 Robert Millan <rmh@aybabtu.com>
7562 * commands/search.c (options): Rename --fs_uuid to --fs-uuid.
7563 * util/update-grub_lib.in (prepare_grub_to_access_device): Replace
7564 --fs_uuid with --fs-uuid.
7565 * util/update-grub.in: Allow filesystem UUID probes to fail (since not
7566 all filesystems support them).
7568 2008-05-30 Robert Millan <rmh@aybabtu.com>
7570 * fs/ext2.c (grub_ext2_uuid): Use `04x' instead of '02x' as
7571 grub_printf() flags, since we're printing in units of 2 bytes.
7573 2008-05-30 Robert Millan <rmh@aybabtu.com>
7575 * util/grub.d/00_header.in: Remove obsolete comment referencing
7576 convert_system_path_to_grub_path().
7577 * util/update-grub.in: Likewise.
7578 * util/update-grub_lib.in (is_path_readable_by_grub): New function.
7579 (convert_system_path_to_grub_path): Add a warning message explaining
7580 that this function is deprecated. Rely on is_path_readable_by_grub()
7581 for the readability checks.
7582 (font_path): Use is_path_readable_by_grub() for the readability
7583 check rather than convert_system_path_to_grub_path().
7585 2008-05-30 Robert Millan <rmh@aybabtu.com>
7587 * util/update-grub_lib.in (prepare_grub_to_access_device): New function.
7588 * util/update-grub.in: Set `GRUB_FONT_PATH' to the system path, without
7589 converting it first.
7590 * util/grub.d/00_header.in: Use prepare_grub_to_access_device() to setup
7591 grub.cfg for access to font file, and afterwards call it again to set
7594 2008-05-30 Robert Millan <rmh@aybabtu.com>
7596 * commands/search.c (options): Add --fs_uuid option.
7597 (search_fs_uuid): New function.
7598 (grub_cmd_search): Fix --set argument passing.
7599 Use search_fs_uuid() when requested via --fs_uuid.
7600 (grub_search_init): Update help message.
7601 * fs/ext2.c (struct grub_ext2_sblock): Rename `unique_id' to `uuid'
7602 and redeclare it as an array of 16-bit words.
7603 (grub_ext2_uuid): New function.
7604 (grub_ext2_fs): Reference grub_ext2_uuid() in `uuid' struct member.
7605 * include/grub/fs.h (struct grub_fs): Add `uuid' struct member.
7606 * util/update-grub.in (GRUB_DEVICE_UUID, GRUB_DEVICE_BOOT)
7607 (GRUB_DEVICE_BOOT_UUID): New variables.
7608 (GRUB_DRIVE. GRUB_DRIVE_BOOT. GRUB_DRIVE_BOOT_GRUB): Remove.
7609 * util/grub.d/00_header.in: Set root using `search --fs_uuid' command
7611 * util/grub.d/10_hurd.in: Avoid explicit use of root drive. Instead,
7612 just assume `root' variable has the right value.
7613 * util/grub.d/10_linux.in: Likewise.
7614 * util/grub-probe.c (probe): Probe for filesystem UUID when requested
7616 (main): Recognise `-t fs_uuid' argument.
7618 2008-05-30 Robert Millan <rmh@aybabtu.com>
7620 * util/biosdisk.c (map): Redefine structure to hold information
7621 about GRUB drive name.
7622 (get_drive): Reimplement without assuming (and verifying) BIOS-like
7624 (call_hook): Remove.
7625 (grub_util_biosdisk_iterate): Access drive names via `.drive' struct
7626 member. Assume drive has partitions.
7627 (grub_util_biosdisk_open): Access device names via `.device' struct
7629 (open_device): Likewise.
7630 (find_drive): Likewise.
7631 (read_device_map): Adjust map[] usage to match the new struct
7632 definition. Don't check for duplicates (still possible, but not cheap
7634 (grub_util_biosdisk_fini): Free malloced buffers referenced by map[].
7635 (make_device_name): Remove assumption of BIOS-like drive names.
7637 2008-05-30 Pavel Roskin <proski@gnu.org>
7639 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Remove, as
7640 compiling execute.c doesn't need grub_script.tab.h anymore.
7641 (normal/command.c_DEPENDENCIES): Likewise.
7642 (normal/function.c_DEPENDENCIES): Likewise.
7643 * conf/i386-ieee1275.rmk: Likewise.
7644 * conf/i386-linuxbios.rmk: Likewise.
7645 * conf/i386-pc.rmk: Likewise.
7646 * conf/powerpc-ieee1275.rmk: Likewise.
7647 * conf/sparc64-ieee1275.rmk: Likewise.
7649 2008-05-29 Pavel Roskin <proski@gnu.org>
7651 * disk/lvm.c (grub_lvm_scan_device): Check for the buffer end
7652 when scanning metadata for volume group name.
7654 * include/grub/script.h: Don't include grub_script.tab.h. It's
7655 a generated file, which may only be included from the files with
7656 DEPENDENCIES rules in the makefile. Don't use typedef YYSTYPE,
7657 use union YYSTYPE, as the later allows forward declaration.
7658 * normal/lexer.c: Don't use typedef YYSTYPE, use union YYSTYPE.
7660 2008-05-29 Robert Millan <rmh@aybabtu.com>
7662 * term/i386/pc/at_keyboard.c: Include `grub/machine/machine.h'.
7663 (OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): New macros.
7664 [GRUB_MACHINE_IEEE1275] (keyboard_map): Add OLPC scan codes
7665 (grub_console_checkkey): Add grub_dprintf() call to report unknown
7668 2008-05-29 Robert Millan <rmh@aybabtu.com>
7670 * term/i386/pc/at_keyboard.c (grub_console_checkkey): Add support for
7671 control key combinations.
7673 2008-05-29 Robert Millan <rmh@aybabtu.com>
7675 * util/powerpc/ieee1275/grub-install.in: Move from here ...
7676 * util/ieee1275/grub-install.in: ... to here.
7677 * powerpc-ieee1275.rmk (grub_install_SOURCES): Update location.
7678 * i386-ieee1275.rmk (sbin_SCRIPTS): New variable.
7679 (grub_install_SOURCES): Likewise.
7681 2008-05-29 Robert Millan <rmh@aybabtu.com>
7683 * fs/affs.c: Update copyright year.
7684 * fs/ext2.c: Likewise.
7685 * fs/fshelp.c: Likewise.
7686 * fs/hfsplus.c: Likewise.
7687 * fs/ntfs.c: Likewise.
7688 * fs/xfs.c: Likewise.
7689 * include/grub/fshelp.h: Likewise.
7690 * util/grub-mkdevicemap.c: Likewise.
7692 2008-05-28 Robert Millan <rmh@aybabtu.com>
7694 * util/update-grub.in: Allow chmod call to fail, since /boot/grub/
7695 might need to be fatfs to support some firmware implementations
7698 2008-05-28 Robert Millan <rmh@aybabtu.com>
7700 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle MMC
7702 * util/grub-mkdevicemap.c (get_mmc_disk_name)
7703 (make_device_map): Likewise.
7705 2008-05-20 Bean <bean123ch@gmail.com>
7707 * fs/fshelp.c (grub_fshelp_map_block): New function.
7708 (grub_fshelp_find_file): Use 64-bit type for pos and block address.
7709 Use `>>' and `&' operator to avoid 64-bit divide and modulo.
7711 * include/grub/fshelp.h (grub_fshelp_journal_type): New enum.
7712 (GRUB_FSHELP_JOURNAL_UNUSED_MAPPING): New macro.
7713 (grub_fshelp_journal): New structure.
7714 (grub_fshelp_map_block): New function prototype.
7715 (grub_fshelp_read_file): Use grub_disk_addr_t as block type.
7716 (grub_fshelp_map_block): Likewise.
7718 * fs/ext2.c (EXT3_FEATURE_COMPAT_HAS_JOURNAL): New macro.
7719 (EXT3_JOURNAL_MAGIC_NUMBER): Likewise.
7720 (EXT3_JOURNAL_DESCRIPTOR_BLOCK): Likewise.
7721 (EXT3_JOURNAL_COMMIT_BLOCK): Likewise.
7722 (EXT3_JOURNAL_SUPERBLOCK_V1): Likewise.
7723 (EXT3_JOURNAL_SUPERBLOCK_V2): Likewise.
7724 (EXT3_JOURNAL_REVOKE_BLOCK): Likewise.
7725 (EXT3_JOURNAL_FLAG_ESCAPE): Likewise.
7726 (EXT3_JOURNAL_FLAG_SAME_UUID): Likewise.
7727 (EXT3_JOURNAL_FLAG_DELETED): Likewise.
7728 (EXT3_JOURNAL_FLAG_LAST_TAG): Likewise.
7729 (grub_ext2_sblock): New members for journal support.
7730 (grub_ext3_journal_header): New structure.
7731 (grub_ext3_journal_revoke_header): Likewise.
7732 (grub_ext3_journal_block_tag): Likewise.
7733 (grub_ext3_journal_sblock): Likewise.
7734 (grub_fshelp_node): New members logfile and journal.
7735 (grub_ext2_read_block): Change block type to grub_disk_addr_t. Use
7736 grub_fshelp_map_block to get real block number.
7737 (grub_ext2_blockgroup): Use grub_fshelp_map_block to get real block
7739 (grub_ext2_read_inode): Likewise.
7740 (grub_ext3_get_journal): New function.
7741 (grub_read_inode): Initialize journal using grub_ext3_get_journal.
7742 (grub_ext2_close): Release memory used by journal.
7744 * fs/reiserfs.c (REISERFS_MAGIC_STRING): Changed to "ReIsEr".
7745 (REISERFS_MAGIC_DESC_BLOCK): New macro.
7746 (grub_reiserfs_transaction_header): Renamed to
7747 grub_reiserfs_description_block, replace field data with real_blocks.
7748 (grub_reiserfs_commit_block): New structure.
7749 (grub_reiserfs_data): New member journal.
7750 (grub_reiserfs_get_item): Use grub_fshelp_map_block to get real block
7752 (grub_reiserfs_read_symlink): Likewise.
7753 (grub_reiserfs_iterate_dir): Likewise.
7754 (grub_reiserfs_open): Likewise.
7755 (grub_reiserfs_read): Likewise.
7756 (grub_reiserfs_get_journal): New function.
7757 (grub_reiserfs_mount): Use "ReIsEr" as super block magic, as there are
7758 three varieties ReIsErFs, ReIsEr2Fs and ReIsEr3Fs. Initialize journal
7759 using grub_reiserfs_get_journal.
7760 (grub_reiserfs_close): Release memory used by journal.
7762 * fs/affs.c (grub_affs_read_block): Change block type to
7763 grub_disk_addr_t. Use grub_divmod64 to do 64-bit division.
7765 * fs/afs.c (grub_afs_read_block): Change block type to grub_disk_addr_t.
7767 * fs/hfsplus.c (grub_hfsplus_read_block): Likewise.
7769 * fs/ntfs.c (grub_ntfs_read_block): Likewise.
7771 * fs/udf.c (grub_udf_read_block): Change block type to
7772 grub_disk_addr_t. Use type cast to avoid warning.
7774 * fs/xfs.c (grub_xfs_read_block): Likewise.
7776 2008-05-16 Christian Franke <franke@computer.org>
7778 * commands/cat.c (grub_cmd_cat): Remove non-ESC keys from keyboard queue
7779 to ensure that break with ESC will always work.
7780 * commands/sleep.c (grub_interruptible_millisleep): Likewise.
7781 Remove ESC from keyboard queue.
7783 2008-05-16 Christian Franke <franke@computer.org>
7785 * util/biosdisk.c: [__CYGWIN__] Add includes.
7786 (grub_util_biosdisk_open): Use Linux code also for Cygwin.
7787 (get_os_disk): Move variable declarations to OS specific
7788 parts to avoid warning.
7789 [__GNU__] (get_os_disk): Fix /dev/sdXsN case.
7790 [__CYGWIN__] (get_os_disk): Add Cygwin /dev/sdXN device names.
7791 (grub_util_biosdisk_get_grub_dev): Use Linux code also for
7793 * util/getroot.c: [__CYGWIN__] Add includes.
7794 (strip_extra_slashes): Fix "/" case.
7795 [__CYGWIN__] (get_win32_path): New function.
7796 [__CYGWIN__] (grub_get_prefix): Add conversion to win32 path.
7797 [__CYGWIN__] (find_root_device): Disable.
7798 [__CYGWIN__] (get_bootsec_serial): New function.
7799 [__CYGWIN__] (find_cygwin_root_device): Likewise.
7800 [__linux__] (grub_guess_root_device): Add early returns to simplify
7802 [__CYGWIN__] (grub_guess_root_device): Call find_cygwin_root_device.
7803 [__linux__] (grub_util_get_dev_abstraction): Enable LVM and RAID
7804 check for Linux only.
7806 2008-05-15 Bean <bean123ch@gmail.com>
7808 * kern/i386/pc/startup.S (grub_console_getkey): Workaround for the
7809 keyboard hang problem in apple's intel mac.
7811 2008-05-09 Robert Millan <rmh@aybabtu.com>
7813 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle Virtio
7815 * util/grub-mkdevicemap.c (get_virtio_disk_name)
7816 (make_device_map): Likewise.
7817 Reported by Aurelien Jarno <aurel32@debian.org>
7819 2008-05-07 Ian Campbell <ijc@hellion.org.uk>
7821 * util/biosdisk.c (get_os_disk): Recognise xvd type disks.
7822 * util/grub-mkdevicemap.c (get_xvd_disk_name): New function.
7823 (make_device_map): Output entries for xvd type disks.
7825 2008-05-07 Robert Millan <rmh@aybabtu.com>
7827 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle CCISS
7829 * util/grub-mkdevicemap.c (get_cciss_disk_name)
7830 (make_device_map): Likewise.
7831 Reported by Roland Dreier <rdreier@cisco.com>
7833 2008-05-07 Robert Millan <rmh@aybabtu.com>
7835 * disk/lvm.c (grub_lvm_scan_device): Detect errors in an additional
7836 grub_strstr() call. Correct a few mistakes in failure path handling.
7838 2008-05-06 Robert Millan <rmh@aybabtu.com>
7840 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
7841 Do not print a trailing slash (therefore, the root directory is an
7843 (convert_system_path_to_grub_path): Do not remove trailing slash
7844 from make_system_path_relative_to_its_root() output.
7846 * util/i386/pc/grub-install.in: Add trailing slash to output from
7847 make_system_path_relative_to_its_root().
7849 2008-05-06 Robert Millan <rmh@aybabtu.com>
7851 * util/grub-fstest.c (grub_refresh): Call `fflush (stdout)'. This
7852 ensures that output lines aren't intermangled with those sent to
7853 stderr (via grub_util_info()).
7854 * util/grub-probe.c (grub_refresh): Likewise.
7855 * util/i386/pc/grub-setup.c (grub_refresh): Likewise.
7857 2008-05-05 Christian Franke <franke@computer.org>
7859 * util/grub-mkdevicemap.c (get_floppy_disk_name) [__CYGWIN__]:
7860 Add Cygwin device names.
7861 (get_ide_disk_name) [__CYGWIN__]: Likewise.
7862 (get_scsi_disk_name) [__CYGWIN__]: Likewise.
7863 (check_device): Return error instead of success on empty name.
7864 (make_device_map): Move label inside linux specific code to
7865 prevent compiler warning.
7867 2008-04-30 Robert Millan <rmh@aybabtu.com>
7869 Based on patch from Fabian Greffrath <greffrath@leat.rub.de>
7870 * util/grub.d/10_linux.in: Add ${GRUB_CMDLINE_LINUX_DEFAULT} to the
7872 * util/update-grub.in: Export GRUB_CMDLINE_LINUX_DEFAULT.
7874 2008-04-29 Robert Millan <rmh@aybabtu.com>
7876 * docs/grub.cfg: New file (example GRUB configuration).
7878 2008-04-26 Robert Millan <rmh@aybabtu.com>
7880 * DISTLIST: Sort (sort -u < DISTLIST | sponge DISTLIST). Add
7881 `loader/i386/ieee1275/linux.c', `loader/i386/ieee1275/linux_normal.c'
7882 and `disk/ieee1275/nand.c'.
7884 2008-04-25 Bean <bean123ch@gmail.com>
7886 * Makefile.in (RMKFILES): Add missing arch i386-ieee1275 and
7889 * commands/hexdump.c (grub_cmd_hexdump): Support dumping of device,
7890 change the buffer size to 4096 for cdrom device.
7892 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add _linux.mod, linux.mod
7894 (_linux_mod_SOURCES): New variable.
7895 (_linux_mod_CFLAGS): Likewise.
7896 (_linux_mod_LDFLAGS): Likewise.
7897 (linux_mod_SOURCES): Likewise.
7898 (linux_mod_CFLAGS): Likewise.
7899 (linux_mod_LDFLAGS): Likewise.
7900 (nand_mod_SOURCES): Likewise.
7901 (nand_mod_CFLAGS): Likewise.
7902 (nand_mod_LDFLAGS): Likewise.
7904 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Return
7905 GRUB_ERR_UNKNOWN_DEVICE instead of GRUB_ERR_BAD_DEVICE if no device
7906 type property. (nand device in olpc don't have this property)
7908 * include/grub/disk.h (grub_disk_dev_id): New macro
7909 GRUB_DISK_DEVICE_NAND_ID.
7911 * include/grub/i386/ieee1275/loader.h (grub_rescue_cmd_linux): New
7913 (grub_rescue_cmd_initrd): Likewise.
7915 * include/grub/i386/linux.h (GRUB_LINUX_OFW_SIGNATURE): New macro.
7916 (linux_kernel_params): Add new member ofw_signature, ofw_num_items,
7917 ofw_cif_handler and ofw_idt, adjust padding number.
7919 * include/grub/i386/pc/memory.h (grub_upper_mem): Export it if
7920 GRUB_MACHINE_IEEE1275 is defined.
7922 * include/grub/ieee1275/ieee1275.h (grub_available_iterate):
7923 Use NESTED_FUNC_ATTR attribute on the hook parameter.
7925 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Use NESTED_FUNC_ATTR
7926 on nested function heap_init.
7927 (grub_upper_mem): New variable for i386-ieee1275.
7928 (grub_get_extended_memory): New function for i386-ieee1275.
7929 (grub_machine_init): Call grub_get_extended_memory for i386-ieee1275.
7931 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Use
7932 NESTED_FUNC_ATTR on the hook parameter. Don't quit if no device type
7935 * loader/i386/ieee1275/linux.c: New file.
7937 * loader/i386/ieee1275/linux_normal.c: New file.
7939 * disk/ieee1275/nand.c: New file.
7941 2008-04-18 Thomas Schwinge <tschwinge@gnu.org>
7943 * util/i386/pc/grub-mkrescue.in (grub_mkimage): Don't overwrite correct
7945 * util/powerpc/ieee1275/grub-mkrescue.in (grub_mkimage): Likewise.
7947 2008-04-18 Robert Millan <rmh@aybabtu.com>
7949 Restructures early code path on ieee1275 to unify grub_main() as
7950 the first C function that is executed in every platform.
7952 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_init): New prototype.
7953 * kern/i386/ieee1275/startup.S (_start): Jump to grub_main() instead of
7955 * kern/powerpc/ieee1275/crt0.S (_start): Likewise.
7956 * kern/ieee1275/cmain.c (cmain): Rename to ...
7957 * kern/ieee1275/cmain.c (grub_ieee1275_init): ... this.
7958 * kern/ieee1275/init.c (grub_machine_init): Call grub_ieee1275_init()
7961 2008-04-18 Robert Millan <rmh@aybabtu.com>
7963 * util/update-grub.in: Fix syntax error when setting
7964 `GRUB_PRELOAD_MODULES'.
7965 Reported by Stephane Chazelas <stephane@artesyncp.com>
7967 2008-04-17 Lubomir Kundrak <lkundrak@redhat.com>
7969 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): take only .text
7970 section into account, newer toolchains generate unique build ids
7971 * configure.ac: remove the test for --build-id=none acceptance,
7972 we want build ids to be preserved
7973 * genmk.rb: add -R .note.gnu.build-id to objcopy, so build id
7974 far from other sections don't cause the raw binary images grow
7977 2008-04-15 Robert Millan <rmh@aybabtu.com>
7979 * disk/lvm.c: Update copyright year.
7980 * kern/misc.c: Likewise.
7982 2008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
7984 * disk/lvm.c (grub_lvm_scan_device): Add forgotten failure path when
7985 there is no memory left for physical volume name.
7987 2008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
7989 * disk/lvm.c (grub_lvm_scan_device): Fix logical volume's physical
7990 volume name mapping to support bigger than 9 character names properly.
7992 2008-04-13 Robert Millan <rmh@aybabtu.com>
7994 * disk/i386/pc/biosdisk.c (grub_biosdisk_rw): Fix CHS limit check,
7995 as per http://www.allensmith.net/Storage/HDDlimit/Int13h.htm
7997 2008-04-13 Christian Franke <franke@computer.org>
7999 * util/i386/pc/grub-mkrescue.in: Add --emulation=floppy
8000 to create a floppy emulation boot CD when non emulation mode
8002 Enable Joliet CD filesystem extension.
8004 2008-04-13 Robert Millan <rmh@aybabtu.com>
8006 * kern/misc.c (grub_strncat): Fix off-by-one error.
8007 Reported by Zhang Huan <zhanghuan@nrchpc.ac.cn>
8009 * kern/env.c (grub_env_context_close): Clear current context, not
8011 Patch from Zhang Huan <zhanghuan@nrchpc.ac.cn>
8013 * kern/misc.c (grub_strcat): Minor speed optimization (same code size).
8015 2008-04-13 Robert Millan <rmh@aybabtu.com>
8017 Improve robustness when handling LVM.
8019 * disk/lvm.c (grub_lvm_getvalue): Return 0 when `*p' is NULL
8020 (and leave `*p' unmodified).
8021 (grub_lvm_iterate): Don't assume `vg->lvs != NULL' when iterating
8023 (grub_lvm_memberlist): Don't assume `lv->vg->pvs != NULL' when
8024 iterating through it.
8025 (grub_lvm_open): Don't assume `vg->lvs != NULL' when iterating
8027 (grub_lvm_scan_device): Check the return value (and fail gracefully
8028 when due) on each grub_lvm_getvalue() or grub_strstr() call.
8029 Don't assume `vg->pvs != NULL' when iterating through it.
8031 2008-04-13 Robert Millan <rmh@aybabtu.com>
8033 * gendistlist.sh (EXTRA_DISTFILES): Add `genpartmaplist.sh'.
8034 * genmk.rb (partmap): New variable.
8035 (CLEANFILES, PARTMAPFILES): Add #{partmap}.
8036 (#{partmap}): New target rule.
8037 * genpartmaplist.sh: New file.
8038 * Makefile.in (pkglib_DATA): Add partmap.lst.
8039 (partmap.lst): New target rule.
8040 * util/i386/pc/grub-mkrescue.in: Generate grub.cfg that loads needed
8041 modules (including all partition maps), instead of preloading them.
8043 2007-04-13 Fabian Greffrath <fabian.greffrath@web.de>
8045 * util/grub.d/30_os-prober.in: New script. Use `os-prober' and
8046 `linux-boot-prober' (if installed) to detect other operating
8047 systems which are installed on the computer and add them to
8049 * conf/common.rmk: Build and install 30_os-prober.
8051 2008-04-12 Robert Millan <rmh@aybabtu.com>
8053 * kern/powerpc/ieee1275/init.c: Move from here ...
8054 * kern/ieee1275/init.c: ... to here. Update all users.
8056 * kern/powerpc/ieee1275/cmain.c: Move from here ...
8057 * kern/ieee1275/cmain.c: ... to here. Update all users.
8059 * kern/powerpc/ieee1275/openfw.c: Move from here ...
8060 * kern/ieee1275/openfw.c: ... to here. Update all users.
8062 * loader/powerpc/ieee1275/multiboot2.c: Move from here ...
8063 * loader/ieee1275/multiboot2.c: ... to here. Update all users.
8065 2008-04-10 Pavel Roskin <proski@gnu.org>
8067 * configure.ac: Always use "_cv_" in cache variables for
8068 compatibility with Autoconf 2.62.
8070 2008-04-07 Robert Millan <rmh@aybabtu.com>
8072 Revert grub/machine/init.h addition by Pavel (since it breaks on
8073 i386-ieee1275 and others):
8074 * util/i386/pc/misc.c: Remove grub/machine/init.h.
8075 * util/powerpc/ieee1275/misc.c: Likewise.
8077 2008-04-07 Robert Millan <rmh@aybabtu.com>
8079 * util/grub-probe.c (probe): Improve error message.
8081 2008-04-07 Robert Millan <rmh@aybabtu.com>
8083 * util/biosdisk.c (read_device_map): Skip devices that don't exist
8084 (this prevents the presence of a bogus entry from ruining the whole
8087 2008-04-06 Pavel Roskin <proski@gnu.org>
8089 * util/biosdisk.c: Include grub/util/biosdisk.h.
8090 * util/grub-fstest.c (execute_command): Make static.
8091 * util/grub-mkdevicemap.c (check_device): Likewise.
8092 * util/i386/pc/misc.c: Include grub/machine/init.h.
8093 * util/powerpc/ieee1275/misc.c: Likewise.
8094 * util/lvm.c: Include grub/util/lvm.h.
8095 * util/misc.c: Include grub/kernel.h, grub/misc.h and
8097 * util/raid.c: Include grub/util/raid.h.
8098 (grub_util_getdiskname): Make static.
8100 * util/grub-emu.c (main): Remove calls to grub_hostfs_init() and
8101 grub_hostfs_fini(), as they are called from grub_init_all() and
8102 grub_fini_all() respectively. This fixes an infinite loop in
8103 grub-fstest due to double registration of hostfs.
8104 Reported by Christian Franke <Christian.Franke@t-online.de>
8106 2008-04-05 Pavel Roskin <proski@gnu.org>
8108 * bus/pci.c (grub_pci_iterate): For multifunction devices, probe
8109 all 8 functions. Otherwise, probe function 0 only.
8111 2008-04-04 Pavel Roskin <proski@gnu.org>
8113 * commands/lspci.c (grub_lspci_iter): Print the bus number
8116 * commands/lspci.c (grub_pci_classes): Fix typos.
8117 (grub_lspci_iter): Don't print func twice. Print vendor ID
8118 before device ID, as it's normally done.
8120 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
8121 Fix signedness warnings.
8122 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate):
8124 * util/ieee1275/get_disk_name.c: Include config.h so that
8125 _GNU_SOURCE is defined and getline() is declared. Mark an
8126 unused argument as such. Fix a signedness warning.
8128 2008-04-02 Pavel Roskin <proski@gnu.org>
8130 * genkernsyms.sh.in: Use more robust assignments for CC and
8131 srcdir. Quote srcdir.
8132 * gensymlist.sh.in: Likewise. Assert at the compile time that
8133 the symbol table is not empty.
8135 * disk/raid.c (grub_raid_memberlist): Fix a signedness warning.
8136 * fs/cpio.c (grub_cpio_read): Likewise.
8138 2008-04-01 Pavel Roskin <proski@gnu.org>
8140 * disk/ata.c (grub_ata_open): Don't lose precision in disk->id.
8141 * disk/host.c (grub_host_open): Likewise.
8142 * disk/loopback.c (grub_loopback_open): Likewise.
8143 * disk/memdisk.c (grub_memdisk_open): Use a string pointer for
8144 disk->id as in disk/host.c, not a multi-character constant.
8146 * util/grub-fstest.c (cmd_cmp): Use fseeko(), not fseek(). The
8147 later is obsolete, potentially dangerous and sets a bad example.
8148 * util/i386/efi/grub-mkimage.c (make_header): Likewise.
8149 * util/misc.c (grub_util_get_image_size): Likewise.
8151 * disk/loopback.c (options): Improve help for "--partitions".
8153 * normal/arg.c (grub_arg_show_help): Fix spacing of the long
8154 options to align them with the short options, e.g. "echo -e".
8156 2008-03-31 Bean <bean123ch@gmail.com>
8158 * video/reader/png.c (grub_png_data): New member is_16bit and
8160 (grub_png_decode_image_header): Detect 16 bit png image.
8161 (grub_png_convert_image): New function to convert 16 bit image to 8 bit.
8162 (grub_png_decode_png): Call grub_png_convert_image for 16 bit image.
8163 (grub_video_reader_png): Release memory occupied by image_data.
8165 * fs/ntfs.c (find_attr): Handle non-resident attribute list larger than
8167 (grub_nfs_mount): Skip the test for sector per cluster.
8169 * include/grub/ntfs.h (MAX_SPC): Removed.
8171 2008-03-31 Bean <bean123ch@gmail.com>
8173 * conf/common.rmk (pkgdata_MODULES): Add afs.mod.
8174 (grub_probe_SOURCES): Add fs/afs.c.
8175 (grub_fstest_SOURCES): Likewise.
8176 (afs_mod_SOURCES): New variable.
8177 (afs_mod_CFLAGS): Likewise.
8178 (afs_mod_LDFLAGS): Likewise.
8180 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/afs.c.
8181 (grub_emu_SOURCES): Likewise.
8183 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
8185 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8187 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
8189 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8191 * fs/afs.c: New file.
8193 2008-03-30 Pavel Roskin <proski@gnu.org>
8195 * disk/host.c: Include grub/misc.h to fix a warning.
8196 * util/hostfs.c: Use GRUB_MOD_INIT and GRUB_MOD_FINI to fix
8197 warnings about implicit declarations.
8199 * fs/udf.c (grub_udf_mount): Fix warning about a shadowing a
8201 * include/grub/i386/loader.h: Change declaration of
8202 grub_linux_boot() to match what grub_loader_set() expects.
8203 * util/getroot.c (grub_guess_root_device): Return const char* to
8205 * util/grub-probe.c (probe): Fix a warning about uninitialized
8206 abstraction_name variable.
8207 * util/i386/get_disk_name.c (grub_util_get_disk_name): Mark
8208 second argument as unused to fix a warning.
8210 * loader/i386/pc/multiboot2.c (grub_mb2_arch_elf64_hook): Add
8211 missing grub_error() call.
8213 * util/update-grub_lib.in: Define datarootdir, since Autoconf
8214 2.60 and newer uses it to define datadir.
8216 * commands/sleep.c: Fix warning about implicit declaration.
8217 * disk/memdisk.c: Likewise.
8218 * loader/aout.c: Likewise.
8219 * loader/i386/bsd_normal.c: Likewise.
8220 * util/grub-probe.c: Likewise.
8222 * commands/i386/cpuid.c (has_longmode): Make static.
8223 * disk/i386/pc/biosdisk.c (cd_drive): Likewise.
8224 * include/grub/i386/bsd.h (bios_memmap_t): Remove, it's unused.
8226 * kern/i386/pc/startup.S (real_to_prot): Use %cs prefix to load
8227 GDT. This is more robust, as %ds can change.
8228 (grub_biosdisk_rw_int13_extensions): Don't clear %ds before
8229 calling real_to_prot().
8230 (grub_biosdisk_get_diskinfo_int13_extensions): Likewise.
8232 2008-03-28 Pavel Roskin <proski@gnu.org>
8234 * kern/i386/pc/startup.S: Assert that uncompressed functions
8235 don't spill beyond GRUB_KERNEL_MACHINE_RAW_SIZE.
8236 * kern/i386/pc/lzo1x.S: Remove all .align directives in the
8237 code, as they push parts of the code (error handlers) beyond
8238 GRUB_KERNEL_MACHINE_RAW_SIZE. Speed is not as important in this
8239 code as correctness and size.
8241 2008-03-28 Pavel Roskin <proski@gnu.org>
8243 * kern/i386/pc/startup.S
8244 (grub_biosdisk_get_diskinfo_int13_extensions): When converting
8245 data block address to the real mode, keep offset minimal. This
8246 works around a bug in AWARD BIOS on old Athlon systems, which
8247 makes CD detection hang.
8249 2008-03-26 Pavel Roskin <proski@gnu.org>
8251 * normal/color.c (grub_parse_color_name_pair): Make `name' a
8253 * include/grub/normal.h: Add grub_parse_color_name_pair()
8256 2008-03-24 Bean <bean123ch@gmail.com>
8258 * disk/i386/pc/biosdisk.c (cd_start): Removed.
8259 (cd_count): Removed.
8260 (cd_drive): New variable.
8261 (grub_biosdisk_get_drive): Don't check for (cdN) device.
8262 (grub_biosdisk_call_hook): Likewise.
8263 (grub_biosdisk_iterate): Change cdrom detection method.
8264 (grub_biosdisk_open): Replace cd_start with cd_drive.
8265 (GRUB_MOD_INIT): Use grub_biosdisk_get_cdinfo_int13_extension to
8266 detect cdrom device.
8268 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_MACHINE_CDROM_START):
8270 (GRUB_BIOSDISK_MACHINE_CDROM_END): Removed.
8271 (GRUB_BIOSDISK_CDTYPE_NO_EMUL): New macro.
8272 (GRUB_BIOSDISK_CDTYPE_1_2_M): Likewise.
8273 (GRUB_BIOSDISK_CDTYPE_1_44_M): Likewise.
8274 (GRUB_BIOSDISK_CDTYPE_2_88_M): Likewise.
8275 (GRUB_BIOSDISK_CDTYPE_HARDDISK): Likewise.
8276 (GRUB_BIOSDISK_CDTYPE_MASK): Likewise.
8277 (grub_biosdisk_cdrp): New structure.
8278 (grub_biosdisk_get_cdinfo_int13_extensions): New function.
8280 * include/grub/i386/pc/kernel.h (grub_boot_drive): Export this variable.
8282 * kern/i386/pc/init.c (make_install_device): Don't use (cdN) as root
8285 * kern/i386/pc/startup.S (grub_biosdisk_get_cdinfo_int13_extensions):
8288 2008-03-20 Robert Millan <rmh@aybabtu.com>
8290 Remove 2 TiB limit in ata.mod.
8291 * disk/ata.c (grub_ata_device): Promote `size' to grub_uint64_t.
8292 (grub_ata_dumpinfo): Print sector count with 0x%llx.
8293 (grub_ata_identify): Interpret `&info16[100]' as a pointer to
8294 grub_uint64_t instead of grub_uint32_t.
8296 2008-03-05 Bean <bean123ch@gmail.com>
8298 * loader/i386/pc/multiboot.c (grub_multiboot_get_bootdev): New function.
8299 (grub_multiboot): Set boot device.
8301 * boot/i386/pc/lnxboot.S (real_code_2): Set %dh to 0xFF.
8303 2008-03-02 Bean <bean123ch@gmail.com>
8305 * fs/reiserfs.c (grub_reiserfs_read_symlink): Add 0 at the end of
8308 2008-03-01 Yoshinori K. Okuji <okuji@enbug.org>
8310 * DISTLIST: Added docs/fdl.texi, docs/grub.texi, docs/mdate-sh and
8313 * docs/grub.texi: New file. Copied from GRUB Legacy, and slightly
8316 * docs/fdl.texi: New file.
8318 * docs/mdate-sh: New file. Copied from gnulib.
8319 * docs/texinfo.tex: Likewise.
8321 * config.guess: Updated from gnulib.
8322 * install-sh: Likewise.
8324 2008-02-28 Robert Millan <rmh@aybabtu.com>
8326 * conf/i386-linuxbios.rmk (pkglib_MODULES): Add aout.mod.
8327 (aout_mod_SOURCES): New variable.
8328 (aout_mod_CFLAGS): Likewise.
8329 (aout_mod_LDFLAGS): Likewise.
8331 * conf/i386-ieee1275.rmk: Likewise.
8333 2008-02-28 Robert Millan <rmh@aybabtu.com>
8335 * util/update-grub.in: Reorganise terminal validity check. Accept
8336 `ieee1275:console' (OLPC) and `*:gfxterm' as valid too.
8337 Based on suggestion by Franklin PIAT.
8339 2008-02-28 Fabian Greffrath <greffrath@leat.rub.de>
8341 * include/grub/util/getroot.h (grub_util_check_block_device): Export new
8343 * util/getroot.c (grub_util_check_block_device): New function that
8344 returns the given argument if it is a block device and returns NULL else.
8345 * util/grub-probe.c (argument_is_device): New variable.
8346 (probe): Promote device_name from a variable to an argument. Receive
8347 device_name from grub_util_check_block_device() if path is NULL and from
8348 grub_guess_root_device() else. Do not free() device_name anymore.
8349 (options): Introduce new parameter '-d, --device'.
8350 (main): Add description of the new parameter to the help screen.
8351 Rename path variable to argument. Set argument_is_device if the '-d'
8352 option is given. Pass argument to probe() depending on
8355 2008-02-24 Bean <bean123ch@gmail.com>
8357 * fs/iso9660.c (GRUB_ISO9660_VOLDESC_BOOT): New macro.
8358 (GRUB_ISO9660_VOLDESC_PRIMARY): Likewise.
8359 (GRUB_ISO9660_VOLDESC_SUPP): Likewise.
8360 (GRUB_ISO9660_VOLDESC_PART): Likewise.
8361 (GRUB_ISO9660_VOLDESC_END): Likewise.
8362 (grub_iso9660_primary_voldesc): New member escape.
8363 (grub_iso9660_data): New member joliet.
8364 (grub_iso9660_convert_string): New function.
8365 (grub_iso9660_mount): Detect joliet extension.
8366 (grub_iso9660_iterate_dir): Convert filename when joliet is detected.
8367 (grub_iso9660_iso9660_label): Likewise.
8369 * conf/common.rmk (pkgdata_MODULES): Add udf.mod.
8370 (grub_setup_SOURCES): Add fs/udf.c.
8371 (grub_fstest_SOURCES): Likewise.
8372 (udf_mod_SOURCES): New variable.
8373 (udf_mod_CFLAGS): Likewise.
8374 (udf_mod_LDFLAGS): Likewise.
8376 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/udf.c.
8377 (grub_emu_SOURCES): Likewise.
8379 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
8381 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8383 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
8385 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8387 * fs/udf.c: New file.
8389 2008-02-24 Robert Millan <rmh@aybabtu.com>
8391 * conf/i386-efi.rmk (normal/function.c_DEPENDENCIES)
8392 (normal/lexer.c_DEPENDENCIES): New variables.
8393 * conf/i386-ieee1275.rmk (normal/function.c_DEPENDENCIES)
8394 (normal/lexer.c_DEPENDENCIES): Likewise.
8395 * conf/i386-linuxbios.rmk (normal/function.c_DEPENDENCIES)
8396 (normal/lexer.c_DEPENDENCIES): Likewise.
8397 * conf/i386-pc.rmk (normal/function.c_DEPENDENCIES)
8398 (normal/lexer.c_DEPENDENCIES): Likewise.
8399 * conf/powerpc-ieee1275.rmk (normal/function.c_DEPENDENCIES)
8400 (normal/lexer.c_DEPENDENCIES): Likewise.
8401 * conf/sparc64-ieee1275.rmk (normal/function.c_DEPENDENCIES)
8402 (normal/lexer.c_DEPENDENCIES): Likewise.
8404 2008-02-23 Robert Millan <rmh@aybabtu.com>
8406 * partmap/gpt.c (grub_gpt_magic): Add `0x' qualifier to each member,
8407 since they were intended to be in hex. This didn't break previously
8408 because of a bug in gpt_partition_map_iterate() (see below).
8410 (gpt_partition_map_iterate): Replace `grub_memcmp' with `! grub_memcmp'
8411 when checking the validity of GPT header.
8412 Remove `partno', since it always provides the same information as `i'.
8414 2008-02-21 Yoshinori K. Okuji <okuji@enbug.org>
8416 * include/grub/efi/time.h: Fix a wrong comment.
8418 2008-02-19 Pavel Roskin <proski@gnu.org>
8420 * kern/rescue.c (grub_enter_rescue_mode): Improve initial
8423 2008-02-19 Bean <bean123ch@gmail.com>
8425 * conf/i386-pc.rmk (pkglib_MODULES): Add aout.mod _bsd.mod and bsd.mod.
8426 (aout_mod_SOURCES): New variable.
8427 (aout_mod_CFLAGS): Likewise.
8428 (aout_mod_LDFLAGS): Likewise.
8429 (_bsd_mod_SOURCES): New variable.
8430 (_bsd_mod_CFLAGS): Likewise.
8431 (_bsd_mod_LDFLAGS): Likewise.
8432 (bsd_mod_SOURCES): New variable.
8433 (bsd_mod_CFLAGS): Likewise.
8434 (bsd_mod_LDFLAGS): Likewise.
8436 * include/grub/aout.h: New file.
8438 * include/grub/i386/loader.h (grub_unix_real_boot): New function.
8440 * include/grub/i386/bsd.h: New file.
8442 * include/grub/i386/pc/init.h (grub_get_mmap_entry): Use EXPORT_FUNC
8445 * kern/elf.c (grub_elf32_load): Get the physical address after the hook
8446 function is called, so that it's possible to change it inside the hook.
8447 (grub_elf64_load): Likewise.
8448 (grub_elf_file): Don't close the file if elf header is not found.
8449 (grub_elf_close): Close the file if grub_elf_file fails (The new
8450 grub_elf_file won't close it).
8451 (grub_elf32_size): Use NESTED_FUNC_ATTR for nested function calcsize.
8452 (grub_elf64_size): Likewise.
8454 * kern/i386/loader.S (grub_unix_real_boot): New function.
8456 * loader/aout.c: New file.
8458 * loader/i386/bsd.c: New file.
8460 * loader/i386/bsd_normal.c: New file.
8462 * loader/i386/pc/multiboot.c (grub_multiboot): Handle a.out format.
8464 * loader/multiboot2.c (grub_multiboot2): Reset grub_errno so that it
8465 can test other formats.
8467 2008-02-19 Robert Millan <rmh@aybabtu.com>
8469 * partmap/gpt.c: Include `<grub/gpt_partition.h>'.
8470 (grub_gpt_partition_type_empty): Redefine with macro from
8471 `<grub/gpt_partition.h>'.
8472 (gpt_partition_map_iterate): Adjust partition type comparison.
8474 Export `entry' as partmap-specific `part.data' struct.
8475 (grub_gpt_header, grub_gpt_partentry): Move from here ...
8477 * include/grub/gpt_partition.h (grub_gpt_header)
8478 (grub_gpt_partentry): ... to here (new file).
8480 * util/i386/pc/grub-setup.c: Include `<grub/gpt_partition.h>'.
8482 (grub_gpt_partition_type_bios_boot): New const variable, defined
8483 with macro from `<grub/gpt_partition.h>'.
8485 (setup): Replace `first_start' with `embed_region', which keeps
8486 track of the embed region (and is partmap-agnostic).
8488 Replace find_first_partition_start() with find_usable_region(),
8489 which finds a usable region for embedding using partmap-specific
8490 knowledge (supports PC/MSDOS and GPT).
8492 Fix all assumptions that the embed region start at sector 1, using
8493 `embed_region.start' from now on. Similarly, use `embed_region.end'
8494 rather than `first_start' to calculate available size.
8496 In grub_util_info() message, replace "into after the MBR" with an
8497 indication of the specific sector our embed region starts at.
8499 2008-02-19 Robert Millan <rmh@aybabtu.com>
8501 * DISTLIST: Replace `commands/ieee1275/halt.c' and
8502 `commands/ieee1275/reboot.c' with `commands/halt.c' and
8503 `commands/reboot.c'.
8504 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
8505 (halt_mod_SOURCES): Likewise.
8506 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
8507 (halt_mod_SOURCES): Likewise.
8509 2008-02-17 Christian Franke <franke@computer.org>
8511 * commands/cat.c (grub_cmd_cat): Add break on GRUB_TERM_ESC key.
8513 2008-02-17 Robert Millan <rmh@aybabtu.com>
8515 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
8516 set `first_start' to 0 for non-PC/MSDOS partition maps.
8518 2008-02-16 Robert Millan <rmh@aybabtu.com>
8520 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
8521 do not assume partition map is PC/MSDOS before performing checks that
8522 are specific to that layout.
8524 2008-02-13 Robert Millan <rmh@aybabtu.com>
8526 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Remove
8527 `commands/i386/pc/halt.c' and `commands/i386/pc/reboot.c'.
8528 * kern/i386/linuxbios/init.c (grub_halt, grub_reboot): Remove stubs.
8530 2008-02-13 Yoshinori K. Okuji <okuji@enbug.org>
8532 * configure.ac: Only a cosmetic change on the handling of
8533 -fno-stack-protector.
8535 2008-02-12 Alexandre Boeglin <alex@boeglin.org>
8537 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace
8538 commands/i386/pc/halt.c and reboot.c by commands/halt.c and
8540 (grub_install_SOURCES): Add halt.mod and reboot.mod.
8541 (halt_mod_SOURCES): New variable.
8542 (halt_mod_CFLAGS): Likewise.
8543 (halt_mod_LDFLAGS): Likewise.
8544 (reboot_mod_SOURCES): Likewise.
8545 (reboot_mod_CFLAGS): Likewise.
8546 (reboot_mod_LDFLAGS): Likewise.
8548 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace
8549 commands/ieee1275/halt.c and reboot.c by commands/halt.c and
8551 (halt_mod_SOURCES): Likewise.
8552 (reboot_mod_SOURCES): Likewise.
8554 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace
8555 commands/i386/pc/reboot.c by commands/reboot.c.
8556 (reboot_mod_SOURCES): Likewise.
8558 * commands/i386/pc/reboot.c: merge this file ...
8560 * commands/ieee1275/reboot.c: ... and this file ...
8562 * commands/reboot.c: ... to this file.
8563 Add some precompiler directive to include the correct header for
8566 * commands/ieee1275/halt.c: move this file ...
8568 * commands/halt.c: ... to here.
8569 Add some precompiler directive to include the correct header for
8572 * include/grub/efi/efi.h (grub_reboot): New function declaration.
8573 (grub_halt): Likewise.
8575 * kern/efi/efi.c (grub_reboot): New function.
8576 (grub_halt): Likewise.
8578 2008-02-12 Robert Millan <rmh@aybabtu.com>
8580 * util/getroot.c (grub_guess_root_device): Inspect /dev/evms before
8581 /dev (like it is done for /dev/mapper). This doesn't provide support
8582 for EVMS, but at least it is now easy to identify the problem when it
8585 2008-02-11 Robert Millan <rmh@aybabtu.com>
8587 * util/biosdisk.c (grub_util_biosdisk_open, linux_find_partition)
8588 (grub_util_biosdisk_get_grub_dev): Check open() exit status by
8589 comparing it with -1, not 0.
8591 2008-02-10 Robert Millan <rmh@aybabtu.com>
8593 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `disk/raid.c' and
8595 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8596 * conf/i386-pc.rmk (grub_setup_SOURCES): Likewise.
8598 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Move `disk/raid.c' and
8599 `disk/lvm.c' to the end of the list.
8600 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
8601 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
8603 2008-02-10 Robert Millan <rmh@aybabtu.com>
8605 * kern/main.c (grub_load_normal_mode): Do not reset `grub_errno'. Call
8606 grub_print_error() instead. This will let user know why we're entering
8608 Based on suggestions from Sam Morris.
8610 2008-02-10 Alexandre Boeglin <alex@boeglin.org>
8612 * normal/arg.c (grub_arg_parse): If one of the args is "--", call add_arg()
8613 on remaining N args, instead of "--" arg N times.
8615 2008-02-09 Vesa Jaaskelainen <chaac@nic.fi>
8617 * font/manager.c (unknown_glyph): Added variable for unknown glyph.
8618 (fill_with_default_glyph): Changed to use unknown_glyph for fill
8619 pattern for unknown glyphs.
8621 2008-02-09 Robert Millan <rmh@aybabtu.com>
8623 * configure.ac: Probe for `help2man'.
8624 * Makefile.in (builddir): New variable.
8625 (HELP2MAN): Likewise. Set to `true' when @HELP2MAN@ doesn't provide it,
8626 or otherwise add a few flags/options to it.
8627 (install-local): For every executable utility or script that is
8628 installed, invoke $(HELP2MAN) to install a manpage based on --help
8631 * util/i386/pc/grub-install.in: Move down `update-grub_lib' sourcing, so
8632 that it doesn't prevent --help from working in build tree.
8634 * util/i386/pc/grub-mkrescue.in (usage): Replace `grub-devel@gnu.org'
8635 with `bug-grub@gnu.org'.
8636 * util/powerpc/ieee1275/grub-mkrescue.in (usage): Likewise.
8637 * util/update-grub.in (usage): New function.
8638 Implement proper argument check, with support for --help and --version
8639 (as well as existing -y).
8641 2008-02-09 Christian Franke <franke@computer.org>
8643 * commands/cat.c (grub_cmd_cat): Print '\r' as hex to
8644 avoid overwriting previous output.
8645 * kern/rescue.c (grub_rescue_cmd_cat): Likewise.
8647 2008-02-09 Robert Millan <rmh@aybabtu.com>
8649 * normal/menu.c (run_menu): If timeout is set to zero, don't bother
8652 2008-02-09 Robert Millan <rmh@aybabtu.com>
8654 * commands/sleep.c: New file.
8655 * conf/common.rmk (pkglib_MODULES): Add `commands/sleep.c'.
8656 (sleep_mod_SOURCES): New variable.
8657 (sleep_mod_CFLAGS): Likewise.
8658 (sleep_mod_LDFLAGS): Likewise.
8660 2008-02-09 Robert Millan <rmh@aybabtu.com>
8662 * disk/raid.c (grub_raid_scan_device): Add a pair of sanity checks for
8663 situations in which we can deduce the RAID size and the superblock
8666 2008-02-09 Robert Millan <rmh@aybabtu.com>
8668 * disk/lvm.c [GRUB_UTIL] (grub_lvm_memberlist): New function. Construct
8669 and return a grub_diskmemberlist_t composed of LVM physical volumes.
8670 [GRUB_UTIL] (grub_lvm_dev): Add `memberlist' member.
8672 * disk/raid.c [GRUB_UTIL] (grub_raid_memberlist): New function. Construct
8673 and return a grub_diskmemberlist_t composed of physical array members.
8674 [GRUB_UTIL] (grub_raid_dev): Add `memberlist' member.
8676 * include/grub/disk.h [GRUB_UTIL] (grub_disk_memberlist): New struct
8678 [GRUB_UTIL] (struct grub_disk_dev): Add `memberlist' function pointer.
8679 [GRUB_UTIL] (struct grub_disk_memberlist): New struct declaration.
8680 [GRUB_UTIL] (grub_disk_memberlist_t): New typedef.
8682 * util/grub-probe.c (probe): Move partmap probing code from here ...
8683 (probe_partmap): ... to here.
8684 (probe): Use probe_partmap() once for the disk we're probing, and
8685 additionally, when such disk contains a memberlist() struct member,
8686 once for each disk that is contained in the structure returned by
8689 2008-02-09 Robert Millan <rmh@aybabtu.com>
8691 * util/grub-probe.c (main): When `verbosity > 1', set `debug'
8692 environment variable to 'all' in order to obtain debug output from
8694 * util/i386/pc/grub-setup.c (main): Likewise.
8696 2008-02-08 Robert Millan <rmh@aybabtu.com>
8698 * disk/raid.c (grub_raid_scan_device): Check for
8699 `array->device[sb.this_disk.number]' rather than for
8700 `array->device[sb.this_disk.number]->name', since the latter is not
8701 guaranteed to be accessible.
8703 2008-02-08 Robert Millan <rmh@aybabtu.com>
8705 * disk/raid.c: Update copyright.
8706 * fs/cpio.c: Likewise.
8707 * include/grub/raid.h: Likewise.
8708 * loader/i386/pc/multiboot.c: Likewise.
8709 * util/hostfs.c: Likewise.
8711 2008-02-08 Robert Millan <rmh@aybabtu.com>
8713 * include/grub/raid.h (struct grub_raid_array): Change type of `device'
8714 to a grub_disk_t array.
8715 * disk/raid.c (grub_raid_read): Replace `device[x].disk' accesses with
8717 (grub_raid_scan_device): Replace `device[x].name' accesses with
8718 `device[x]->name'. Simplify initialization of `array->device[x]'.
8720 2008-02-08 Robert Millan <rmh@aybabtu.com>
8722 * disk/raid.c (grub_raid_open, grub_raid_scan_device): Add a few
8723 grub_dprintf() calls.
8724 * kern/disk.c (grub_disk_read): Include grub_errmsg in out of range
8727 2008-02-07 Christian Franke <franke@computer.org>
8729 * util/hostfs.c (grub_hostfs_open): Use fseeko and ftello
8730 instead of fseek and ftell to support large files.
8731 (grub_hostfs_read): Likewise.
8733 2008-02-07 Robert Millan <rmh@aybabtu.com>
8735 Patch from Jeroen Dekkers.
8736 * disk/raid.c (grub_raid_scan_device): Reset `grub_errno' on disk
8737 failure, since successfully reading all array members might not be
8740 2008-02-06 Robert Millan <rmh@aybabtu.com>
8742 * util/grub-probe.c (probe): Simplify partmap probing (with the
8743 assumption that the first word up to the underscore equals to
8746 2008-02-06 Christian Franke <franke@computer.org>
8748 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_NONE
8749 (and set *ofs = 0) instead of GRUB_ERR_FILE_NOT_FOUND on
8750 last block of a cpio or tar stream.
8751 Check for "TRAILER!!!" instead of any empty data
8752 block to detect last block of a cpio stream.
8753 (grub_cpio_dir): Fix constness of variable np.
8754 (grub_cpio_open): Return GRUB_ERR_FILE_NOT_FOUND if
8755 cpio or tar trailer is detected. This fixes a crash
8756 on open of a non existing file.
8758 2008-02-05 Bean <bean123ch@gmail.com>
8760 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Get physical
8762 (grub_multiboot_load_elf64): Likewise.
8763 (grub_multiboot): Initialize mbi structure.
8765 * util/grub-fstest.c: Don't include unused header file script.h.
8767 * conf/common.rmk (grub-fstest.c_DEPENDENCIES): Move to the beginning
8769 (grub_fstest_SOURCES): Likewise.
8771 2008-02-05 Robert Millan <rmh@aybabtu.com>
8773 * include/grub/term.h (GRUB_TERM_LEFT, GRUB_TERM_RIGHT)
8774 (GRUB_TERM_UP, GRUB_TERM_DOWN, GRUB_TERM_HOME, GRUB_TERM_END)
8775 (GRUB_TERM_DC, GRUB_TERM_PPAGE, GRUB_TERM_NPAGE, GRUB_TERM_ESC)
8776 (GRUB_TERM_TAB, GRUB_TERM_BACKSPACE): New macros.
8778 * kern/i386/pc/startup.S: Include `<grub/term.h>'.
8779 (translation_table): Replace hardcoded values with macros
8780 provided by `<grub/term.h>'.
8782 * term/i386/pc/at_keyboard.c: Include `<grub/term.h>'.
8783 (keyboard_map): Correct/add a few values, with macros provided
8785 (keyboard_map_shift): Zero values that don't differ from their
8786 `keyboard_map' equivalents.
8787 (grub_console_checkkey): Optimize KEYBOARD_STATUS_CAPS_LOCK toggling.
8788 Discard the second scan code that is always sent by Caps lock.
8789 Only use `keyboard_map_shift' when it provides a non-zero value,
8790 otherwise fallback to `keyboard_map'.
8792 2008-02-04 Bean <bean123ch@gmail.com>
8794 * Makefile.in (enable_grub_fstest): New variable.
8796 * conf/common.rmk (grub_fstest_init.lst): New rule.
8797 (grub_fstest_init.h): Likewise.
8798 (grub_fstest_init.c): Likewise.
8799 (util/grub-fstest.c_DEPENDENCIES): New variable.
8800 (grub_fstest_SOURCES): Likewise.
8802 * configure.ac (enable_grub_fstest): Check for --enable-grub-fstest.
8804 * util/grub-fstest.c: New file.
8806 2008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
8808 Make grub-setup handle a separate root device.
8810 * util/i386/pc/grub-setup.c (setup): Always open the root device,
8811 so that the root device can be compared with the destination
8813 When embedding the core image, if the root and destination devices
8814 are different, set ROOT_DRIVE to ROOT_DEV->DISK->ID. Otherwise, to
8816 When not embedding, set ROOT_DRIVE to 0xFF.
8818 2008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
8820 Add support for having a grub directory in a different drive. This
8821 is still only the data handling part.
8823 * kern/i386/pc/startup.S (multiboot_trampoline): Set %dh to 0xFF.
8824 (codestart): Save %dh in GRUB_ROOT_DRIVE.
8825 (grub_root_drive): New variable.
8827 * kern/i386/pc/init.c (make_install_device): Use GRUB_ROOT_DRIVE
8828 instead of GRUB_BOOT_DRIVE to construct a device name. Set
8829 GRUB_ROOT_DRIVE to GRUB_BOOT_DRIVE if it is 0xFF, otherwise use it
8832 * include/grub/i386/pc/kernel.h (grub_root_drive): New prototype.
8834 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_ROOT_DRIVE): New
8836 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Set to 0x4f.
8838 * boot/i386/pc/pxeboot.S (_start): Set %dh to 0xFF. For now, this
8839 is bogus, because PXE booting does not specify any drive
8842 * boot/i386/pc/lnxboot.S (reg_edx): Set the second byte to 0xFF. I
8843 am not sure if this is really correct.
8845 * boot/i386/pc/cdboot.S: Set %dh to 0xFF, because the root drive
8846 is always identical to the boot drive when booting from a CD.
8848 * boot/i386/pc/boot.S (MOV_MEM_TO_AL): Removed. Not needed any
8850 (root_drive): New variable.
8851 (real_start): Unconditionally set %dh to ROOT_DRIVE.
8852 (setup_sectors): Push %dx right after popping it, because %dh will
8854 (copy_buffer): Restore %dx.
8856 2008-02-03 Robert Millan <rmh@aybabtu.com>
8858 * util/i386/pc/grub-mkrescue.in: Rewrite most of image generation to
8859 use `cdboot.img' for cdrom images.
8861 2008-02-03 Robert Millan <rmh@aybabtu.com>
8863 * util/grub.d/00_header.in: Issue scripting commands for GRUB to
8864 only setup gfxterm when `font' command has succeeded.
8866 2008-02-03 Robert Millan <rmh@aybabtu.com>
8868 * loader/multiboot_loader.c [GRUB_MACHINE_LINUXBIOS]
8869 (grub_rescue_cmd_multiboot_loader)
8870 (grub_rescue_cmd_module_loader): Enable multiboot1 calls.
8872 2008-02-03 Pavel Roskin <proski@gnu.org>
8874 * kern/i386/pc/startup.S (grub_chainloader_real_boot): Pop
8875 %edx and %esi from stack only after grub_gate_a20() is called.
8876 grub_gate_a20() clobbers %edx.
8878 2008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
8880 * configure.ac (AC_INIT): Bumped to 1.96.
8882 * DISTLIST: Added boot/i386/pc/cdboot.S, bus/pci.c,
8883 commands/lspci.c,disk/memdisk.c, include/grub/pci.h,
8884 include/grub/i386/pc/pci.h, video/readers/jpeg.c, and
8885 video/readers/png.c.
8887 2008-02-03 Bean <bean123ch@gmail.com>
8889 * conf/i386-pc.rmk (pkglib_IMAGES): Add cdboot.img.
8890 (cdboot_img_SOURCES): New variable.
8891 (cdboot_img_ASFLAGS): New variable.
8892 (cdboot_img_LDFLAGS): New variable.
8894 * boot/i386/pc/cdboot.S: New file.
8896 * disk/i386/pc/biosdisk.c (cd_start): New variable.
8897 (cd_count): Likewise.
8898 (grub_biosdisk_get_drive): Add support for cd device.
8899 (grub_biosdisk_call_hook): Likewise.
8900 (grub_biosdisk_iterate): Likewise.
8901 (grub_biosdisk_open): Likewise.
8902 (GRUB_BIOSDISK_CDROM_RETRY_COUNT): New macro.
8903 (grub_biosdisk_rw): Support reading from cd device.
8904 (GRUB_MOD_INIT): Iterate cd devices.
8906 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_FLAG_CDROM): New macro.
8907 (GRUB_BIOSDISK_MACHINE_CDROM_START): Likewise.
8908 (GRUB_BIOSDISK_MACHINE_CDROM_END): Likewise.
8910 * kern/i386/pc/init.c (make_install_device): Check for cd device.
8912 2008-02-02 Robert Millan <rmh@aybabtu.com>
8914 * commands/read.c: New file.
8915 * conf/common.rmk (pkglib_MODULES): Add `commands/read.c'.
8916 (read_mod_SOURCES): New variable.
8917 (read_mod_CFLAGS): Likewise.
8918 (read_mod_LDFLAGS): Likewise.
8920 2008-02-02 Robert Millan <rmh@aybabtu.com>
8922 * normal/main.c (grub_normal_execute): Check for `menu->size' when
8923 determining whether menu has to be displayed.
8925 2008-02-02 Marco Gerards <marco@gnu.org>
8927 * bus/pci.c: New file.
8929 * include/grub/pci.h: Likewise.
8931 * include/grub/i386/pc/pci.h: Likewise.
8933 * commands/lspci.c: Likewise.
8935 * conf/i386-pc.rmk (pkglib_MODULES): Add `pci.mod' and
8937 (pci_mod_SOURCES): New variable.
8938 (pci_mod_CFLAGS): Likewise.
8939 (pci_mod_LDFLAGS): Likewise.
8940 (lspci_mod_SOURCES): Likewise.
8941 (lspci_mod_CFLAGS): Likewise.
8942 (lspci_mod_LDFLAGS): Likewise.
8944 2008-02-02 Bean <bean123ch@gmail.com>
8946 * fs/ufs.c (INODE_BLKSZ): Fix incorrect value.
8947 (grub_ufs_get_file_block): Fix indirect block calculation problem.
8949 * fs/xfs.c (grub_xfs_sblock): New member log2_dirblk.
8950 (grub_xfs_btree_node): New structure.
8951 (grub_xfs_btree_root): New structure.
8952 (grub_xfs_inode): New members nblocks, extsize, nextents and btree.
8953 (GRUB_XFS_EXTENT_OFFSET): Use exts instead of inode->data.extents.
8954 (GRUB_XFS_EXTENT_BLOCK): Likewise.
8955 (GRUB_XFS_EXTENT_SIZE): Likewise.
8956 (grub_xfs_read_block): Support btree format type.
8957 (grub_xfs_iterate_dir): Use NESTED_FUNC_ATTR in call_hook.
8958 Use directory block as basic unit.
8960 * fs/fshelp.c (grub_fshelp_read_file): Bug fix for sparse block.
8962 * aclocal.m4 (grub_i386_CHECK_REGPARM_BUG): Define NESTED_FUNC_ATTR as
8963 __attribute__ ((__regparm__ (1))).
8965 2008-02-01 Robert Millan <rmh@aybabtu.com>
8967 Correct a mistake in previous commit.
8969 * conf/i386-pc.rmk (normal/execute.c_DEPENDENCIES): Move to the
8971 (normal/command.c_DEPENDENCIES): New variable.
8973 2008-02-01 Robert Millan <rmh@aybabtu.com>
8975 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Move to the
8977 (normal/command.c_DEPENDENCIES): New variable.
8978 (grub-emu_DEPENDENCIES, normal_mod_DEPENDENCIES): Remove variables.
8979 * conf/i386-ieee1275.rmk: Likewise.
8980 * conf/i386-linuxbios.rmk: Likewise.
8981 * conf/i386-pc.rmk: Likewise.
8982 * conf/sparc64-ieee1275.rmk: Likewise.
8983 * conf/powerpc-ieee1275.rmk: Likewise.
8984 (grub_emu_SOURCES): Add `fs/fshelp.c'.
8986 * genmk.rb: Add `$(#{src}_DEPENDENCIES)' in targets that require it.
8988 2008-02-01 Robert Millan <rmh@aybabtu.com>
8990 * kern/disk.c (grub_disk_read, grub_disk_write): Add grub_dprintf()
8991 call at beginning of function.
8993 2008-01-31 Pavel Roskin <proski@gnu.org>
8995 * util/powerpc/ieee1275/grub-mkrescue.in: New file.
8996 * conf/powerpc-ieee1275.rmk (bin_SCRIPTS): New variable.
8997 (grub_mkrescue_SOURCES): Likewise.
8998 * DISTLIST: Add util/powerpc/ieee1275/grub-mkrescue.in.
9000 2008-01-30 Robert Millan <rmh@aybabtu.com>
9002 * conf/i386-pc.rmk (sbin_UTILITIES): Remove `grub-probe'.
9003 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Moved from here ...
9004 * conf/common.rmk (util/grub-probe.c_DEPENDENCIES)
9005 (grub_probe_SOURCES): ... to here.
9007 * conf/i386-efi.rmk (sbin_UTILITIES): Remove `grub-probe'.
9008 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Remove.
9009 * conf/i386-ieee1275.rmk: Likewise.
9010 * conf/i386-linuxbios.rmk: Likewise.
9011 * conf/powerpc-ieee1275.rmk: Likewise.
9013 2008-01-30 Tristan Gingold <gingold@free.fr>
9015 * kern/rescue.c: Silently accept empty lines.
9017 2008-01-29 Bean <bean123ch@gmail.com>
9019 * boot/i386/pc/lnxboot.S (data_start): Code cleanup.
9020 (real_code_2): Code cleanup and change comment style.
9021 (move_memory): Avoid using 32-bit address mode.
9023 2008-01-29 Bean <bean123ch@gmail.com>
9025 * conf/i386-pc.rmk (pkglib_MODULES): Add `png.mod'.
9026 (png_mod_SOURCES): New variable.
9027 (png_mod_CFLAGS): Likewise.
9028 (png_mod_LDFLAGS): Likewise.
9030 * video/readers/png.c: New file.
9032 2008-01-28 Robert Millan <rmh@aybabtu.com>
9034 * include/grub/i386/linuxbios/kernel.h (GRUB_MOD_GAP): New macro.
9035 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Remove
9036 `ifndef GRUB_MOD_GAP' hack.
9037 * util/elf/grub-mkimage.c (add_segments): Likewise.
9039 2008-01-27 Robert Millan <rmh@aybabtu.com>
9041 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Skip
9042 `GRUB_MOD_GAP' for platforms in which it's not defined.
9043 * util/elf/grub-mkimage.c (add_segments): Likewise.
9045 2008-01-27 Robert Millan <rmh@aybabtu.com>
9047 Get grub-emu to build again (including parallel builds).
9049 * conf/i386-pc.rmk (util/grub-emu.c_DEPENDENCIES): Remove variable.
9051 (util/grub-emu.c_DEPENDENCIES): ... this, ...
9052 (normal/execute.c_DEPENDENCIES): ... this, ...
9053 (grub-emu_DEPENDENCIES): ... and this.
9055 * conf/i386-efi.rmk: Likewise.
9056 * conf/i386-linuxbios.rmk: Likewise.
9057 * conf/i386-ieee1275.rmk: Likewise.
9058 * conf/powerpc-ieee1275.rmk: Likewise.
9059 (grub_emu_SOURCES): Remove duplicated `kern/file.c'.
9061 2008-01-27 Robert Millan <rmh@aybabtu.com>
9063 * NEWS: Add a few items.
9065 2008-01-27 Robert Millan <rmh@aybabtu.com>
9067 Fix parallel builds with grub-emu. Based on earlier commit for
9068 grub-probe and grub-setup.
9070 * conf/i386-pc.rmk (grub-emu_DEPENDENCIES): Renamed to ...
9071 (util/grub-emu.c_DEPENDENCIES): ... this.
9072 * conf/i386-efi.rmk (grub-emu_DEPENDENCIES): Renamed to ...
9073 (util/grub-emu.c_DEPENDENCIES): ... this.
9074 * conf/i386-linuxbios.rmk (grub-emu_DEPENDENCIES): Renamed to ...
9075 (util/grub-emu.c_DEPENDENCIES): ... this.
9076 * conf/i386-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
9077 (util/grub-emu.c_DEPENDENCIES): ... this.
9078 * conf/powerpc-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
9079 (util/grub-emu.c_DEPENDENCIES): ... this.
9081 2008-01-27 Pavel Roskin <proski@gnu.org>
9083 * include/grub/powerpc/ieee1275/kernel.h: Introduce GRUB_MOD_GAP
9084 to create a gap between _end and the modules added to the image
9085 with grub-mkrescue. That fixes "CLAIM failed" on PowerMAC.
9086 * kern/powerpc/ieee1275/init.c: Use GRUB_MOD_GAP.
9087 * util/elf/grub-mkimage.c (add_segments): Likewise.
9089 2008-01-26 Pavel Roskin <proski@gnu.org>
9091 * kern/dl.c (grub_dl_load): Don't abort if prefix is not set,
9092 just return an error.
9094 2008-01-26 Bean <bean123ch@gmail.com>
9096 * fs/reiserfs.c (grub_fshelp_node): New member next_offset.
9097 (grub_reiserfs_get_item): Save offset of the next item.
9098 (grub_reiserfs_iterate_dir): Use next_offset to find next item.
9100 2008-01-25 Robert Millan <rmh@aybabtu.com>
9102 * conf/i386-pc.rmk (grub_setup_SOURCES, grub_emu_SOURCES): Regroup to
9103 make all filesystem sources appear together (possibly fixing omissions
9105 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
9106 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
9107 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
9108 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
9110 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise. Additionally,
9112 * conf/i386-efi.rmk (grub_probe_SOURCES): Likewise.
9113 * conf/i386-ieee1275.rmk (grub_probe_SOURCES): Likewise.
9114 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Likewise.
9115 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Likewise.
9117 * util/grub-probe.c: Include `<grub/file.h>' and `<sys/stat.h>'.
9118 (probe): Add a sanity check to make sure of our ability to read
9119 requested files when probing for filesystem type.
9121 * genmk.rb: Update copyright year (2007).
9123 * include/grub/fs.h (grub_fat_init, grub_fat_fini, grub_ext2_init)
9124 (grub_ext2_fini, grub_ufs_init, grub_ufs_fini, grub_minix_init)
9125 (grub_minix_fini, grub_hfs_init, grub_hfs_fini, grub_jfs_init)
9126 (grub_jfs_fini, grub_xfs_init, grub_xfs_fini, grub_affs_init)
9127 (grub_affs_fini, grub_sfs_init, grub_sfs_fini, grub_iso9660_init)
9128 : Remove function prototypes.
9130 2008-01-25 Robert Millan <rmh@aybabtu.com>
9132 Revert my previous commits (based on wrong assumption of how grub_errno
9135 * kern/disk.c (grub_disk_open): Stop resetting grub_errno.
9136 * kern/file.c (grub_file_open): Likewise.
9138 2008-01-24 Pavel Roskin <proski@gnu.org>
9140 * include/grub/ieee1275/ieee1275.h: Introduce flag for firmwares
9141 that hang if GRUB tries to setup colors.
9142 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Don't set
9143 colors for firmwares that don't support it.
9144 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag):
9145 Recognize Open Hack'Ware, set flags to work around its
9148 2008-01-24 Robert Millan <rmh@aybabtu.com>
9150 * kern/file.c (grub_file_open): Do not account previous failures of
9151 unrelated functions when grub_errno is checked for.
9152 Reported by Oleg Strikov.
9154 2008-01-24 Bean <bean123ch@gmail.com>
9156 * fs/ufs.c (GRUB_UFS_VOLNAME_LEN): New macro.
9157 (grub_ufs_sblock): New member volume name.
9158 (grub_ufs_find_file): Fix string copy bug.
9159 (grub_ufs_label): Implement this function properly.
9161 * fs/hfs.c (grub_hfs_cnid_type): New enum.
9162 (grub_hfs_iterate_records): Use the correct file number for extents
9163 and catalog file. Fix problem in next index calculation.
9164 (grub_hfs_find_node): Replace recursive function call with loop.
9165 (grub_hfs_iterate_dir): Replace recursive function call with loop.
9167 2008-01-23 Robert Millan <rmh@aybabtu.com>
9169 * include/grub/i386/ieee1275/loader.h: Include `<grub/types.h>',
9170 `<grub/symbol.h>' and `<grub/multiboot.h>'.
9171 (grub_multiboot2_real_boot): New function prototype.
9173 * include/grub/i386/pc/memory.h: Include `<grub/machine/machine.h>'.
9174 [!GRUB_MACHINE_IEEE1275] (grub_lower_mem, grub_upper_mem): Disable.
9176 * kern/i386/ieee1275/init.c (grub_os_area_addr)
9177 (grub_os_area_size, grub_lower_mem, grub_upper_mem): Remove variables.
9179 2008-01-23 Robert Millan <rmh@aybabtu.com>
9181 * kern/mm.c (grub_mm_init_region): Replace grub_dprintf() call with
9182 #ifdef'ed out grub_printf().
9184 2008-01-23 Robert Millan <rmh@aybabtu.com>
9186 * term/i386/pc/at_keyboard.c (grub_keyboard_isr): #ifdef out
9187 grub_dprintf calls, since they make "debug=all" mode unusable.
9188 (grub_console_checkkey): Likewise.
9190 2008-01-23 Robert Millan <rmh@aybabtu.com>
9192 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
9193 `term/i386/pc/at_keyboard.c'.
9194 (pkglib_MODULES): Add `serial.mod'.
9195 (serial_mod_SOURCES): New variable.
9196 (serial_mod_CFLAGS): Likewise.
9197 (serial_mod_LDFLAGS): Likewise.
9199 * include/grub/i386/ieee1275/console.h: Add `<grub/symbol.h>'. Remove
9200 `<grub/powerpc/ieee1275/console.h>'.
9201 (grub_keyboard_controller_init): New function prototype.
9202 (grub_console_checkkey): Likewise.
9203 (grub_console_getkey): Likewise.
9205 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize AT
9208 * term/ieee1275/ofconsole.c (grub_ofconsole_term): On i386, use
9209 grub_ofconsole_checkkey() and grub_ofconsole_getkey() for input.
9211 2008-01-23 Robert Millan <rmh@aybabtu.com>
9213 * kern/i386/pc/init.c (make_install_device): When memdisk image is
9214 present, "(memdisk)/boot/grub" becomes the default prefix.
9216 * util/i386/pc/grub-mkrescue.in: Switch to a minimal core.img plus
9217 a memdisk tarball with all the modules. Add --overlay=DIR option that
9218 allows users to overlay additional files into the image.
9220 2008-01-23 Robert Millan <rmh@aybabtu.com>
9222 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add `machine/loader.h'
9223 and `machine/memory.h'.
9224 (pkglib_MODULES): Add `multiboot.mod' and `_multiboot.mod'.
9225 (_multiboot_mod_SOURCES): New variable.
9226 (_multiboot_mod_CFLAGS): Likewise.
9227 (_multiboot_mod_LDFLAGS): Likewise.
9228 (multiboot_mod_SOURCES): Likewise.
9229 (multiboot_mod_CFLAGS): Likewise.
9230 (multiboot_mod_LDFLAGS): Likewise.
9232 * include/grub/i386/ieee1275/loader.h: New file.
9234 * include/grub/i386/ieee1275/machine.h: Likewise.
9236 * include/grub/i386/ieee1275/memory.h: Likewise.
9238 * include/grub/i386/pc/init.h (grub_os_area_addr): Remove (redundant)
9239 variable declaration.
9240 (grub_os_area_size): Likewise.
9242 * kern/i386/ieee1275/init.c (grub_os_area_addr, grub_os_area_size)
9243 (grub_lower_mem, grub_upper_mem): New variables.
9244 (grub_stop_floppy): New function (just to make
9245 grub_multiboot2_real_boot() happy).
9247 * kern/i386/ieee1275/startup.S: Include `<grub/machine/memory.h>',
9248 `<grub/cpu/linux.h>', `<multiboot.h>' and `<multiboot2.h>'.
9249 (grub_stop): New function.
9250 Include `"../realmode.S"' and `"../loader.S"'.
9252 * loader/multiboot_loader.c: Include `<grub/machine/machine.h>'.
9253 Replace `__i386__' #ifdefs with `GRUB_MACHINE_PCBIOS'.
9255 * loader/powerpc/ieee1275/multiboot2.c (grub_mb2_arch_boot): On i386,
9256 rely on grub_multiboot2_real_boot() for final boot.
9258 2008-01-22 Robert Millan <rmh@aybabtu.com>
9260 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): When
9261 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag is set, skip any
9262 device that doesn't look like an SD card.
9263 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
9264 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag.
9265 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag): Detect
9266 OLPC laptop, and set `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' when
9269 2008-01-22 Robert Millan <rmh@aybabtu.com>
9271 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Add sanity check to
9272 avoid claiming over our own code.
9274 2008-01-22 Bean <bean123ch@gmail.com>
9276 * conf/i386-pc.rmk (pkglib_MODULES): Add `jpeg.mod'.
9277 (jpeg_mod_SOURCES): New variable.
9278 (jpeg_mod_CFLAGS): Likewise.
9279 (jpeg_mod_LDFLAGS): Likewise.
9281 * video/readers/jpeg.c : New file.
9283 2008-01-22 Bean <bean123ch@gmail.com>
9285 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_FILE_NOT_FOUND when
9286 there are no more items.
9288 2008-01-21 Robert Millan <rmh@aybabtu.com>
9290 * kern/mm.c (grub_mm_init_region): Improve debug message.
9292 2008-01-21 Robert Millan <rmh@aybabtu.com>
9294 * conf/i386-pc.rmk (GRUB_MEMORY_MACHINE_LINK_ADDR): New variable.
9295 (kernel_img_LDFLAGS): Use `GRUB_MEMORY_MACHINE_LINK_ADDR' as link
9297 (grub_mkimage_CFLAGS): Propagate `GRUB_MEMORY_MACHINE_LINK_ADDR' as
9299 * include/grub/i386/pc/memory.h (GRUB_MEMORY_MACHINE_UPPER): New macro.
9300 Indicates start of upper memory.
9301 * util/i386/pc/grub-mkimage.c: Include `<grub/machine/memory.h>'.
9302 (generate_image): Abort when image size is big enough to corrupt
9305 * include/grub/i386/pc/vga.h: Include `<grub/machine/memory.h>'.
9306 (GRUB_MEMORY_MACHINE_VGA_ADDR): Alias for `GRUB_MEMORY_MACHINE_UPPER'.
9307 * term/i386/pc/vga.c (VGA_MEM): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
9308 instead of hardcoding 0xA0000.
9309 * video/i386/pc/vbe.c: Include `<grub/machine/vga.h>'.
9310 (grub_vbe_set_video_mode): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
9311 instead of hardcoding 0xA0000.
9313 2008-01-21 Robert Millan <rmh@aybabtu.com>
9315 * disk/memdisk.c (memdisk_size): New variable.
9316 (grub_memdisk_open): Replace grub_arch_memdisk_size() call with
9318 (grub_memdisk_init): Initialize `memdisk_size'. Reallocate memdisk
9319 image to dynamic memory.
9320 (grub_memdisk_fini): Replace grub_arch_memdisk_size() call with
9321 `memdisk_size'. Free memdisk block.
9323 2008-01-21 Robert Millan <rmh@aybabtu.com>
9325 Fix detection of very small filesystems (like tar).
9327 * fs/reiserfs.c (grub_reiserfs_mount): When disk is too small to
9328 contain a ReiserFS, abort with GRUB_ERR_BAD_FS rather than
9329 GRUB_ERR_OUT_OF_RANGE (which made the upper layer think there's
9330 a problem with this disk).
9332 2008-01-21 Robert Millan <rmh@aybabtu.com>
9334 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Add debug message
9335 on grub_biosdisk_rw_standard() error.
9337 2008-01-21 Robert Millan <rmh@aybabtu.com>
9339 * include/grub/ieee1275/ieee1275.h: Add 2008 to Copyright line for
9341 * kern/elf.c: Likewise.
9342 * kern/ieee1275/ieee1275.c: Likewise.
9343 * kern/powerpc/ieee1275/openfw.c: Likewise.
9344 * term/ieee1275/ofconsole.c: Likewise.
9346 2008-01-21 Robert Millan <rmh@aybabtu.com>
9348 * include/grub/i386/pc/kernel.h: Include `<grub/symbol.h>'.
9350 * include/grub/kernel.h (grub_arch_memdisk_addr)
9351 (grub_arch_memdisk_size): Moved from here ...
9353 * include/grub/i386/pc/kernel.h (grub_arch_memdisk_addr)
9354 (grub_arch_memdisk_size): ... to here.
9356 2008-01-21 Robert Millan <rmh@aybabtu.com>
9358 Mostly based on bugfix from Bean.
9360 * kern/elf.c (grub_elf32_phdr_iterate): Use `NESTED_FUNC_ATTR'
9361 attribute with hook() parameter.
9362 (grub_elf32_load): Use `NESTED_FUNC_ATTR' with grub_elf32_load_segment()
9364 (grub_elf64_phdr_iterate): Use `NESTED_FUNC_ATTR'
9365 attribute with hook() parameter.
9366 (grub_elf64_load): Use `NESTED_FUNC_ATTR' with grub_elf64_load_segment()
9369 2008-01-21 Robert Millan <rmh@aybabtu.com>
9371 * conf/i386-pc.rmk (kernel_img_HEADERS): Add `machine/kernel.h'.
9372 (pkglib_MODULES): Add `memdisk.mod'.
9373 (memdisk_mod_SOURCES): New variable.
9374 (memdisk_mod_CFLAGS): Likewise.
9375 (memdisk_mod_LDFLAGS): Likewise.
9377 * disk/memdisk.c: New file.
9379 * include/grub/disk.h (grub_disk_dev_id): Add
9380 `GRUB_DISK_DEVICE_MEMDISK_ID'.
9382 * include/grub/i386/pc/kernel.h
9383 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): New macro.
9384 (GRUB_KERNEL_MACHINE_PREFIX): Increment by 4.
9385 (grub_kernel_image_size): New variable declaration.
9386 (grub_total_module_size): Likewise.
9387 (grub_memdisk_image_size): Likewise.
9389 * include/grub/i386/pc/memory.h
9390 (GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR): New macro.
9392 * include/grub/kernel.h: Include `<grub/symbol.h>'.
9393 (grub_arch_memdisk_addr): New variable declaration.
9394 (grub_arch_memdisk_size): Likewise.
9396 * kern/i386/pc/init.c (grub_arch_memdisk_addr): New function.
9397 (grub_arch_memdisk_size): Likewise.
9399 * kern/i386/pc/startup.S (grub_memdisk_image_size): New variable.
9400 (codestart): Replace hardcoded `0x100000' with
9401 `GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR' macro.
9403 * util/i386/pc/grub-mkimage.c: Include `<grub/misc.h>'.
9404 (generate_image): Add `memdisk_path' parameter. When `memdisk_path' is
9405 not NULL, append the contents of the file it refers to, at the end of
9406 the compressed kernel image. Initialize `grub_memdisk_image_size'
9407 variable (at `GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE' offset).
9408 (options): Add "memdisk"|'m' option.
9409 (main): Parse --memdisk|-m option, and pass user-provided path as
9410 parameter to generate_image().
9412 2008-01-20 Robert Millan <rmh@aybabtu.com>
9414 * kern/sparc64/ieee1275/openfw.c (grub_devalias_iterate): Copy debug
9415 grub_dprintf() calls from here ...
9416 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): ... to here.
9418 2008-01-20 Robert Millan <rmh@aybabtu.com>
9420 Fix detection of "real mode" when /options/real-mode? doesn't exist.
9422 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_mmu): New variable
9424 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_mmu): New variable.
9425 (grub_ieee1275_find_options): If `grub_ieee1275_mmu' is 0, set
9426 `GRUB_IEEE1275_FLAG_REAL_MODE'.
9427 (cmain): Initialize `grub_ieee1275_mmu' (using /chosen/mmu integer
9429 * kern/powerpc/ieee1275/openfw.c (grub_map): Rely on pre-initialized
9430 `grub_ieee1275_mmu' rather than obtaining a handler on every call.
9432 2008-01-19 Robert Millan <rmh@aybabtu.com>
9434 Get rid of confusing function (superseded by
9435 `grub_ieee1275_get_integer_property')
9436 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_decode_int_4): Remove
9438 * kern/ieee1275/ieee1275.c (grub_ieee1275_decode_int_4): Remove
9440 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid use of
9441 grub_ieee1275_decode_int_4(), by obtaining integer properties directly
9442 in native endianness from grub_ieee1275_get_integer_property().
9444 2008-01-19 Robert Millan <rmh@aybabtu.com>
9446 * kern/powerpc/ieee1275/openfw.c (grub_halt): Issue "power-off"
9447 command after "shut-down", since implementations differ on which
9448 the command for halt is.
9450 2008-01-19 Robert Millan <rmh@aybabtu.com>
9452 * include/grub/i386/linuxbios/console.h: Add header protection.
9453 (grub_keyboard_controller_init): New function prototype.
9454 * term/i386/pc/at_keyboard.c (KEYBOARD_COMMAND_ISREADY): New macro.
9455 (KEYBOARD_COMMAND_READ): Likewise.
9456 (KEYBOARD_COMMAND_WRITE): Likewise.
9457 (KEYBOARD_SCANCODE_SET1): Likewise.
9458 (grub_keyboard_controller_write): New function.
9459 (grub_keyboard_controller_read): Likewise.
9460 (grub_keyboard_controller_init): Likewise.
9462 * term/i386/pc/console.c: Include `<grub/machine/machine.h>'.
9463 (grub_console_init): On coreboot/LinuxBIOS, call
9464 grub_keyboard_controller_init().
9466 2008-01-19 Robert Millan <rmh@aybabtu.com>
9468 PowerPC changes provided by Pavel Roskin.
9470 * kern/powerpc/ieee1275/cmain.c (cmain): Don't take any arguments.
9471 * kern/powerpc/ieee1275/crt0.S: Store r5 in grub_ieee1275_entry_fn,
9472 don't rely on cmain() doing it.
9473 * kern/i386/ieee1275/startup.S (_start): Store %eax in
9474 grub_ieee1275_entry_fn, don't rely on cmain() doing it.
9476 2008-01-16 Robert Millan <rmh@aybabtu.com>
9478 * include/grub/i386/linuxbios/memory.h
9479 (GRUB_MEMORY_MACHINE_LINUXBIOS_TABLE_ADDR): Remove macro.
9480 * kern/i386/linuxbios/table.c (grub_linuxbios_table_iterate): Do not
9481 receive `table_header' as argument. Instead, probe for it in the
9482 known memory ranges where it can be present.
9483 (grub_available_iterate): Do not pass a fixed `table_header' address
9484 to grub_linuxbios_table_iterate().
9486 2008-01-15 Robert Millan <rmh@aybabtu.com>
9488 * configure.ac: Add `i386-ieee1275' to the list of supported targets.
9489 * conf/i386-ieee1275.rmk: New file.
9490 * include/grub/i386/ieee1275/console.h: Likewise.
9491 * include/grub/i386/ieee1275/ieee1275.h: Likewise.
9492 * include/grub/i386/ieee1275/kernel.h: Likewise.
9493 * include/grub/i386/ieee1275/time.h: Likewise.
9494 * kern/i386/ieee1275/init.c: Likewise.
9495 * kern/i386/ieee1275/startup.S: Likewise.
9497 2008-01-15 Robert Millan <rmh@aybabtu.com>
9499 * kern/misc.c (grub_vsprintf): Do not reset `longlongfmt' to zero
9500 when pointers are 32-bit (but still do set it to one when they are
9503 2008-01-15 Robert Millan <rmh@aybabtu.com>
9505 * include/grub/ieee1275/ieee1275.h
9506 (grub_ieee1275_get_integer_property): New function prototype.
9508 * kern/ieee1275/ieee1275.c: Include `<grub/types.h>'.
9509 (grub_ieee1275_get_integer_property): New function. Wraps around
9510 grub_ieee1275_get_property() to handle endianness.
9512 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Replace
9513 grub_ieee1275_get_property() with grub_ieee1275_get_integer_property()
9515 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Likewise.
9516 (grub_map): Likewise.
9517 * kern/sparc64/ieee1275/openfw.c (grub_map): Likewise.
9519 2008-01-15 Bean <bean123ch@gmail.com>
9521 * normal/execute.c (grub_script_exec_argument_to_string): Check for undefined variable.
9522 (grub_script_execute_cmdline): Reset grub_errno.
9524 * normal/main.c (read_config_file): Reset grub_errno.
9526 * normal/parse.y (script_init): New.
9527 (script): Move function and menuentry here.
9529 (command): Add delimiter at the end of command.
9530 (commands): Adjust to match the new command.
9531 (commandblock): Remove grub_script_lexer_record_start.
9532 (menuentry): Add grub_script_lexer_record_start, use the new commands.
9533 (if): Use the new commands.
9535 * conf/common.rmk (pkgdata_MODULES): Add echo.mod.
9537 2008-01-15 Robert Millan <rmh@aybabtu.com>
9539 * normal/menu.c (run_menu): Move timeout message from here ...
9540 (print_timeout): ... to here.
9541 (run_menu): Use print_timeout() once during initial draw to print
9542 the whole message, and again in every clock tick to update only
9543 the number of seconds.
9545 2008-01-15 Robert Millan <rmh@aybabtu.com>
9547 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Obtain
9548 actual size of `available' from grub_ieee1275_get_property(), and
9549 restrict parsing to that bound.
9551 2008-01-15 Christian Franke <franke@computer.org>
9553 * util/grub-emu.c: Replace <argp.h> by <getopt.h>.
9554 (argp_program_version): Remove variable.
9555 (argp_program_bug_address): Likewise.
9556 (options): Convert from struct argp_option to struct option.
9557 (struct arguments): Remove.
9558 (parse_opt): Remove.
9559 (usage): New function.
9560 (main): Replace struct args members by simple variables.
9561 Replace argp_parse() by getopt_long().
9562 Add switch to evaluate options.
9563 Add missing "(...)" around root_dev in prefix string.
9565 2008-01-14 Robert Millan <rmh@aybabtu.com>
9567 * kern/powerpc/ieee1275/init.c (grub_exit): Reimplement as a wrapper
9568 for grub_ieee1275_exit(), in order to improve portability.
9570 2008-01-14 Robert Millan <rmh@aybabtu.com>
9572 * util/grub.d/10_linux.in (prefix): Define.
9573 (exec_prefix): Likewise. Both definitions are later used by `libdir'.
9575 2008-01-13 Pavel Roskin <proski@gnu.org>
9577 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Don't use
9578 grub_errno if no errors have been detected.
9580 2008-01-12 Robert Millan <rmh@aybabtu.com>
9582 * include/grub/util/getroot.h (grub_dev_abstraction_types): New enum.
9583 (grub_util_get_dev_abstraction): New function prototype.
9585 * util/getroot.c: Include `<grub/util/getroot.h>'
9586 (grub_util_get_grub_dev): Move detection of abstraction type to ...
9587 (grub_util_get_dev_abstraction): ... here (new function).
9589 * util/grub-probe.c: Convert PRINT_* to an enum. Add
9590 `PRINT_ABSTRACTION'.
9591 (probe): Probe for abstraction type when requested.
9592 (main): Understand `--target=abstraction'.
9594 * util/i386/efi/grub-install.in: Add abstraction module to core
9595 image when it is found to be necessary.
9596 * util/i386/pc/grub-install.in: Likewise.
9597 * util/powerpc/ieee1275/grub-install.in: Likewise.
9599 * util/update-grub_lib.in (font_path): Return system path without
9600 converting to GRUB path.
9601 * util/update-grub.in: Convert system path returned by font_path()
9602 to a GRUB path. Use `grub-probe -t abstraction' to determine what
9603 abstraction module is needed for loading fonts (if any). Export
9604 that as `GRUB_PRELOAD_MODULES'.
9605 * util/grub.d/00_header.in: Process `GRUB_PRELOAD_MODULES' (print
9608 2008-01-12 Yoshinori K. Okuji <okuji@enbug.org>
9610 Remove some unused code from reiserfs.
9612 * fs/reiserfs.c (struct grub_reiserfs_key)
9613 [GRUB_REISERFS_KEYV2_BITFIELD]: Removed offset and type.
9614 (struct grub_reiserfs_node_body): Removed.
9615 (grub_reiserfs_get_key_v2_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
9617 (grub_reiserfs_get_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
9619 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
9621 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
9623 (grub_reiserfs_set_key_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
9625 (grub_reiserfs_iterate_dir) [GRUB_REISERFS_KEYV2_BITFIELD]:
9627 (grub_reiserfs_open) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
9628 (grub_reiserfs_read) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
9629 (grub_reiserfs_dir) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
9631 2008-01-10 Robert Millan <rmh@aybabtu.com>
9633 * util/update-grub_lib.in (grub_file_is_not_garbage): New function.
9634 Determines if a file is garbage left by packaging systems, etc.
9635 * util/update-grub.in: Use grub_file_is_not_garbage() as a condition
9636 for processing /etc/grub.d scripts.
9637 * util/grub.d/10_hurd.in: Fix `GRUB_DISTRIBUTOR' comparison.
9638 * util/grub.d/10_linux.in: Likewise. Use grub_file_is_not_garbage()
9639 as a condition for processing Linux images.
9641 2008-01-10 Pavel Roskin <proski@gnu.org>
9643 * include/grub/powerpc/libgcc.h (__ucmpdi2): New export. Needed
9644 to compile reiserfs.c on PowerPC.
9646 2008-01-10 Robert Millan <rmh@aybabtu.com>
9648 * kern/device.c (grub_device_iterate): Do not abort device iteration
9649 when one of the devices cannot be opened.
9650 * kern/disk.c (grub_disk_open): Do not account previous failures of
9651 unrelated functions when grub_errno is checked for.
9653 2008-01-08 Robert Millan <rmh@aybabtu.com>
9655 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): For
9656 `! grub_linux_is_bzimage', change order of address comparison to make
9657 it more intuitive, and improve "too big zImage" error message.
9659 2008-01-08 Robert Millan <rmh@aybabtu.com>
9661 * Makefile.in (uninstall): Handle `$(update-grub_SCRIPTS)' and
9662 `$(update-grub_DATA)'.
9663 (distcheck): Fix race condition when invoking `$(MAKE)' on multiple
9666 2008-01-07 Robert Millan <rmh@aybabtu.com>
9668 * boot/i386/pc/boot.S (boot_drive_check): Add a comment indicating
9669 which instruction is modified by grub-setup during installation
9670 (since it wasn't obvious by only looking at this file).
9672 2008-01-07 Robert Millan <rmh@aybabtu.com>
9674 * TODO: Rewrite. Just refer to the wiki and the BTS instead of
9675 listing actual TODO items.
9677 2008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
9679 * fs/reiserfs.c (grub_reiserfs_get_key_v2_type): Handle endianness
9681 (grub_reiserfs_get_key_offset): Likewise.
9682 (grub_reiserfs_set_key_offset): Likewise.
9683 (grub_reiserfs_set_key_type): Likewise.
9684 (grub_reiserfs_iterate_dir): Return 1 if found, otherwise 0.
9686 (GRUB_REISERFS_KEYV2_BITFIELD): Undefined. Probably it would be
9687 better to remove the bitfield version completely.
9689 2008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
9691 * fs/reiserfs.c (grub_reiserfs_iterate_dir): ENTRY_ITEM must be
9692 allocated from the heap, due to the fshelp implementation.
9693 (grub_reiserfs_dir): Free NODE, due to the same reason.
9695 2008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
9697 Mostly from Vincent Pelletier:
9699 * fs/reiserfs.c: New file.
9701 * conf/common.rmk (pkglib_MODULES): Added reiserfs.mod.
9702 (reiserfs_mod_SOURCES): New variable.
9703 (reiserfs_mod_CFLAGS): Likewise.
9704 (reiserfs_mod_LDFLAGS): Likewise.
9706 * DISTLIST: Added boot/i386/pc/lnxboot.S, commands/hexdump.c,
9707 disk/ata.c, fs/cpio.c, fs/ntfscomp.c, fs/reiserfs.c,
9708 include/grub/ntfs.h, include/grub/i386/pc/machine.h, and
9711 2008-01-06 Robert Millan <rmh@aybabtu.com>
9713 * normal/color.c: Remove `<grub/env.h>'.
9715 2008-01-05 Jeroen Dekkers <jeroen@dekkers.cx>
9717 * include/grub/normal.h: Include <grub/env.h>.
9719 2008-01-05 Robert Millan <rmh@aybabtu.com>
9721 * util/i386/pc/grub-setup.c (usage): Replace obsolete `(hd0,0)' in
9722 usage example with `(hd0,1)'.
9723 Reported by Samuel Thibault.
9725 2008-01-05 Robert Millan <rmh@aybabtu.com>
9727 * kern/i386/loader.S (grub_linux_is_bzimage): New variable.
9728 (grub_linux_boot_zimage): Rename to ...
9729 (grub_linux_boot): ... this.
9730 (grub_linux_boot_bzimage): Merge with `grub_linux_boot_zimage'.
9731 (grub_linux_boot_zimage): Conditionalize zImage copy.
9733 * include/grub/i386/loader.h (grub_linux_is_bzimage): Add prototype.
9734 (grub_linux_boot_bzimage): Remove prototype.
9735 (grub_linux_boot_zimage): Rename to ...
9736 (grub_linux_boot): ... this.
9738 * loader/i386/pc/linux.c (big_linux): Replace with `grub_linux_is_bzimage'.
9739 (grub_linux_boot): Remove function.
9741 2008-01-05 Robert Millan <rmh@aybabtu.com>
9743 * include/grub/normal.h (grub_env_write_color_normal): New prototype.
9744 (grub_env_write_color_highlight): Likewise.
9745 (grub_wait_after_message): Likewise.
9747 * normal/color.c: New file.
9749 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/color.c'.
9750 (normal_mod_DEPENDENCIES): Likewise.
9752 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `normal/color.c'.
9753 (normal_mod_DEPENDENCIES): Likewise.
9755 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add `normal/color.c'.
9756 (normal_mod_DEPENDENCIES): Likewise.
9758 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `normal/color.c'.
9759 (normal_mod_DEPENDENCIES): Likewise.
9761 * normal/menu_entry.c (run): Rely on grub_wait_after_message()
9762 for waiting after a message is printed.
9763 * normal/main.c (read_config_file): Likewise.
9764 (grub_normal_init): Register grub_env_write_color_normal() and
9765 grub_env_write_color_highlight() hooks. Mark `color_normal' and
9766 `color_highlight' variables as global.
9768 * normal/menu.c (grub_wait_after_message): New function.
9769 (grub_color_menu_normal): New variable. Replaces ...
9770 (GRUB_COLOR_MENU_NORMAL): ... this macro.
9771 (grub_color_menu_highlight): New variable. Replaces ...
9772 (GRUB_COLOR_MENU_HIGHLIGHT): ... this macro.
9773 (draw_border): Set color state to `GRUB_TERM_COLOR_NORMAL' instead of
9774 `GRUB_TERM_COLOR_STANDARD'.
9775 (print_message): Use `grub_setcolorstate' to reload colors. Rename
9776 `normal_code' and `highlight_code' to `old_color_normal' and
9777 `old_color_highlight', respectively.
9778 (grub_menu_init_page): Update colors when drawing the menu, based on
9779 `menu_color_normal' and `menu_color_highlight' variables.
9780 (grub_menu_run): Rely on grub_wait_after_message() for waiting after
9781 a message is printed.
9783 2008-01-05 Robert Millan <rmh@aybabtu.com>
9785 * kern/env.c (grub_env_context_open): Propagate hooks for global
9786 variables to new context.
9788 * kern/main.c (grub_set_root_dev): Export `root' variable.
9790 2008-01-05 Robert Millan <rmh@aybabtu.com>
9792 * util/biosdisk.c (get_os_disk): Check for devfs-style IDE and SCSI
9793 discs unconditionally, since udev and others have options to provide
9796 2008-01-05 Robert Millan <rmh@aybabtu.com>
9798 * normal/completion.c (iterate_dir): Skip `.' and `..' directories.
9800 2008-01-04 Christian Franke <franke@computer.org>
9802 * kern/i386/pc/init.c (grub_machine_init): Fix evaluation
9805 2008-01-03 Pavel Roskin <proski@gnu.org>
9807 * kern/i386/linuxbios/init.c: Put "void" to all function
9808 declarations with no arguments.
9809 * kern/powerpc/ieee1275/init.c: Likewise.
9810 * term/i386/pc/at_keyboard.c: Likewise.
9811 * term/i386/pc/vga_text.c: Likewise.
9812 * util/grub-mkdevicemap.c: Likewise.
9814 2008-01-02 Robert Millan <rmh@aybabtu.com>
9816 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Improve error
9817 message when loaded image is out of bounds.
9818 (grub_multiboot_load_elf64): Likewise.
9820 2008-01-02 Pavel Roskin <proski@gnu.org>
9822 * util/grub.d/10_linux.in: Try version without ".old" when
9823 looking for initrd. It's better to use initrd from the newer
9824 kernel of the same version than no initrd at all.
9826 2008-01-01 Robert Millan <rmh@aybabtu.com>
9828 * util/biosdisk.c (get_os_disk): Fix check for IDE or SCSI discs.
9830 2008-01-01 Vesa Jaaskelainen <chaac@nic.fi>
9832 * include/grub/video.h: Added grub_video_unmap_color and
9833 grub_video_get_active_render_target.
9834 (grub_video_adapter): Added unmap_color and get_active_render_target.
9836 * video/video.c: Added grub_video_unmap_color and
9837 grub_video_get_active_render_target.
9838 (grub_video_get_info): Changed method to accept NULL pointer as an
9839 argument to allow detection of active video adapter.
9841 * video/i386/pc/vbe.c: Renamed grub_video_vbe_unmap_color as
9842 grub_video_vbe_unmap_color_int.
9843 Added grub_video_vbe_unmap_color and
9844 grub_video_vbe_get_active_render_target.
9845 (grub_video_vbe_adapter): Added unmap_color and
9846 get_active_render_target.
9848 * video/i386/pc/vbeblit.c: Replaced grub_video_vbe_unmap_color usage
9849 with grub_video_vbe_unmap_color_int.
9851 * term/gfxterm.c (DEFAULT_STANDARD_COLOR): Added.
9852 (DEFAULT_NORMAL_COLOR): Likewise.
9853 (DEFAULT_HIGHLIGHT_COLOR) Likewise.
9854 (DEFAULT_FG_COLOR): Removed.
9855 (DEFAULT_BG_COLOR): Likewise.
9856 (DEFAULT_CURSOR_COLOR): Changed value.
9857 (grub_virtual_screen): Added standard_color_setting,
9858 normal_color_setting, highlight_color_setting and term_color.
9859 (grub_virtual_screen): Removed fg_color_setting and bg_color_setting.
9860 (bitmap_width): Added.
9861 (bitmap_height): Likewise.
9863 (set_term_color): Likewise.
9864 (grub_virtual_screen_setup): Changed to use new terminal coloring
9866 (grub_gfxterm_init): Added init for bitmap.
9867 (grub_gfxterm_fini): Added destroy for bitmap.
9868 (redraw_screen_rect): Updated to use background bitmap and new
9870 (scroll_up): Added optimization for case when there is no bitmap.
9871 (grub_gfxterm_cls): Fixed to use correct background color.
9872 (grub_virtual_screen_setcolorstate): Changed to use new terminal
9874 (grub_virtual_screen_setcolor): Likewise.
9875 (grub_virtual_screen_getcolor): Added.
9876 (grub_gfxterm_background_image_cmd): Likewise.
9877 (grub_video_term): Added setcolor and getcolor.
9878 (MOD_INIT): Added registration of background_image command.
9879 (MOD_TERM): Added unregistration for background_image command.
9881 2007-12-30 Pavel Roskin <proski@gnu.org>
9883 * loader/multiboot_loader.c: Fix multiboot command
9884 unregistration. Fix all typos in the word "multiboot".
9886 2007-12-29 Pavel Roskin <proski@gnu.org>
9888 * util/grub.d/10_linux.in: Refactor search for initrd. Add
9889 support for initrd names used in Fedora.
9891 2007-12-26 Bean <bean123ch@gmail.com>
9893 * conf/common.rmk (pkgdata_MODULES): Add cpio.mod.
9894 (cpio_mod_SOURCES): New variable.
9895 (cpio_mod_CFLAGS): Likewise.
9896 (cpio_mod_LDFLAGS): Likewise.
9898 * fs/cpio.c: New file.
9900 * conf/i386-pc.rmk (grub_emu_SOURCES): Add cpio.c.
9902 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
9904 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
9906 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
9908 2007-12-25 Robert Millan <rmh@aybabtu.com>
9910 * include/grub/term.h (struct grub_term): Add `getcolor' function.
9911 (grub_getcolor): New function.
9913 * kern/term.c (grub_getcolor): New function.
9914 * normal/menu.c (GRUB_COLOR_MENU_NORMAL): New macro.
9915 (GRUB_COLOR_MENU_HIGHLIGHT): New macro.
9916 (print_entry): Set normal and highlight colors to
9917 `GRUB_COLOR_MENU_NORMAL' and `GRUB_COLOR_MENU_HIGHLIGHT',
9918 respectively, before printing and restore them to old
9920 (grub_menu_init_page): Likewise. Fill an additional colored space
9921 that would otherwise be left blank.
9923 * term/efi/console.c (grub_console_getcolor): New function.
9924 (struct grub_console_term.getcolor): New variable.
9925 * term/i386/pc/console.c (grub_console_getcolor): New function.
9926 (struct grub_console_term.getcolor): New variable.
9927 * term/ieee1275/ofconsole.c (grub_ofconsole_getcolor): New function.
9928 (struct grub_console_term.getcolor): New variable.
9930 * term/i386/pc/serial.c (grub_serial_setcolor): Remove function.
9931 (struct grub_console_term.setcolor): Remove variable.
9932 * term/i386/pc/vesafb.c (grub_virtual_screen_setcolor): Remove function.
9933 (struct grub_console_term.setcolor): Remove variable.
9934 * term/i386/pc/vga.c (grub_vga_setcolor): Remove function.
9935 (struct grub_console_term.setcolor): Remove variable.
9936 * term/gfxterm.c (grub_virtual_screen_setcolor): Remove function.
9937 (struct grub_console_term.setcolor): Remove variable.
9939 2007-12-25 Robert Millan <rmh@aybabtu.com>
9941 * configure.ac: Search for possible unifont.hex locations, and
9942 define UNIFONT_HEX if found.
9944 * Makefile.in (UNIFONT_HEX): Define variable.
9945 (DATA): Rename to ...
9946 (PKGLIB): ... this. Update all users.
9947 (PKGDATA): New variable.
9948 (pkgdata_IMAGES): Rename to ...
9949 (pkglib_IMAGES): ... this. Update all users.
9950 (pkgdata_MODULES): Rename to ...
9951 (pkglib_MODULES): ... this. Update all users.
9952 (pkgdata_PROGRAMS): Rename to ...
9953 (pkglib_PROGRAMS): ... this. Update all users.
9954 (pkgdata_DATA): Rename to ...
9955 (pkglib_DATA): ... this. Update all users.
9956 (CLEANFILES): Redefine to `$(pkglib_DATA) $(pkgdata_DATA)'.
9957 (unicode.pff, ascii.pff): New rules.
9958 (all-local): Add `$(PKGDATA)' dependency.
9959 (install-local): Process `$(PKGDATA)'.
9961 * util/update-grub_lib.in (font_path): Search for *.pff files in
9962 a few more locations, including `${pkgdata}'.
9964 2007-12-23 Robert Millan <rmh@aybabtu.com>
9966 Patch from Bean <bean123ch@gmail.com>:
9967 * disk/loopback.c (grub_loopback_read): Add missing bit shift to
9970 2007-12-21 Bean <bean123ch@gmail.com>
9972 * conf/common.rmk (pkgdata_MODULES): Add ntfscomp.mod.
9973 (ntfscomp_mod_SOURCES): New variable.
9974 (ntfscomp_mod_CFLAGS): Likewise.
9975 (ntfscomp_mod_LDFLAGS): Likewise.
9977 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfscomp.c.
9978 (grub_probe_SOURCES): Likewise.
9979 (grub_emu_SOURCES): Likewise.
9981 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
9982 (grub_emu_SOURCES): Likewise.
9984 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
9985 (grub_emu_SOURCES): Likewise.
9987 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
9988 (grub_emu_SOURCES): Likewise.
9990 * fs/ntfs.c (grub_ntfscomp_func): New variable.
9991 (read_run_list): Renamed to grub_ntfs_read_run_list.
9992 (decomp_nextvcn): Moved to ntfscomp.c.
9993 (decomp_getch): Likewise.
9994 (decomp_get16): Likewise.
9995 (decomp_block): Likewise.
9996 (read_block): Likewise.
9997 (read_data): Partially moved to ntfscomp.c.
9998 (fixup): Change unsigned to grub_uint16_t.
9999 (read_mft): Change unsigned long to grub_uint32_t.
10000 (read_attr): Likewise.
10001 (read_data): Likewise.
10002 (read_run_data): Likewise.
10003 (read_run_list): Likewise.
10004 (read_mft): Likewise.
10006 * fs/ntfscomp.c: New file.
10008 * include/grub/ntfs.h: New file.
10010 2007-12-16 Robert Millan <rmh@aybabtu.com>
10012 * util/grub-mkdevicemap.c (make_device_map): Iterate up to 20 for
10013 IDE disk check, since Linux is known to support 20 IDE disks.
10014 Reported by Colin Watson.
10016 2007-12-15 Bean <bean123ch@gmail.com>
10018 * conf/i386-pc.rmk (pkgdata_IMAGES): Add lnxboot.img.
10019 (lnxboot_img_SOURCES): New variable.
10020 (lnxboot_img_ASFLAGS): Likewise.
10021 (lnxboot_img_LDFLAGS): Likewise.
10023 * boot/i386/pc/lnxboot.S: New file.
10025 2007-11-24 Pavel Roskin <proski@gnu.org>
10027 * configure.ac: Test if '--build-id=none' is supported by the
10028 linker. If yes, add it to TARGET_LDFLAGS. Build ID causes
10029 objcopy to generate incorrect binary files (binutils
10030 2.17.50.0.18-1 as shipped by Fedora 8).
10031 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Use LDFLAGS when
10032 linking, so that build ID doesn't break the test.
10034 2007-11-24 Pavel Roskin <proski@gnu.org>
10036 * include/grub/i386/time.h: use "void" in the argument list
10037 of grub_cpu_idle().
10038 * include/grub/powerpc/time.h: Likewise.
10039 * include/grub/sparc64/time.h: Likewise.
10041 2007-11-18 Christian Franke <franke@computer.org>
10043 * util/console.c (grub_ncurses_getkey): Change curses KEY_* mapping,
10044 now return control chars instead of GRUB_CONSOLE_KEY_* constants.
10045 This fixes the problem that function keys did not work in grub-emu.
10047 2007-11-18 Christian Franke <franke@computer.org>
10049 * disk/host.c (grub_host_open): Remove attribute unused from
10050 name parameter. Add check for "host". This fixes the problem
10051 that grub-emu does not find partitions.
10053 2007-11-18 Christian Franke <franke@computer.org>
10055 * util/hostfs.c (is_dir): New function.
10056 (grub_hostfs_dir): Handle missing dirent.d_type case.
10057 (grub_hostfs_read): Add missing fseek().
10058 (grub_hostfs_label): Clear label pointer. This fixes a crash
10059 of grub-emu on "ls (host)".
10061 2007-11-18 Christian Franke <franke@computer.org>
10063 * include/grub/i386/pc/init.h (struct grub_machine_mmap_entry):
10064 Add attribute packed, gcc 3.4.4 on Cygwin aligns this
10065 to 64 bit boundary by default.
10067 2007-11-18 Bean <bean123ch@gmail.com>
10069 * conf/common.rmk (pkgdata_MODULES): Add hexdump.mod.
10070 (hexdump_mod_SOURCES): New variable.
10071 (hexdump_mod_CFLAGS): Likewise.
10072 (hexdump_mod_LDFLAGS): Likewise.
10074 * conf/i386-pc.rmk (grub_emu_SOURCES): Add command/hexdump.c.
10076 * conf/i386-efi.rmk (grub_emu_SOURCES): Add command/hexdump.c.
10078 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add command/hexdump.c.
10080 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add command/hexdump.c.
10082 * include/grub/hexdump.h: New file.
10084 * commands/hexdump.c: New file.
10086 2007-11-10 Robert Millan <rmh@aybabtu.com>
10088 * commands/i386/pc/play.c (beep_off): Switch order of arguments
10089 in grub_outb() calls.
10090 (beep_on): Likewise.
10092 2007-11-10 Christian Franke <franke@computer.org>
10094 * normal/menu.c (run_menu): Check for empty menu to avoid crash.
10095 (grub_menu_run): Likewise.
10097 2007-11-10 Robert Millan <rmh@aybabtu.com>
10099 * include/grub/i386/efi/machine.h: New file.
10100 * include/grub/i386/linuxbios/machine.h: Likewise.
10101 * include/grub/i386/pc/machine.h: Likewise.
10102 * include/grub/powerpc/ieee1275/machine.h: Likewise.
10103 * include/grub/sparc64/ieee1275/machine.h: Likewise.
10105 * term/i386/pc/serial.c: Include <grub/machine/machine.h>.
10106 (serial_hw_io_addr): New variable.
10107 (serial_hw_get_port): Obtain port address from `serial_hw_io_addr'
10108 instead of `(unsigned short *) 0x400'.
10110 2007-11-10 Bean <bean123ch@gmail.com>
10112 * fs/ntfs.c (read_block): Fix a bug caused by adjacent blocks.
10114 2007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
10116 * conf/i386-pc.rmk (pkgdata_MODULES): Added vga.mod.
10117 (vga_mod_SOURCES): Added.
10118 (vga_mod_CFLAGS): Likewise.
10119 (vga_mod_LDFLAGS): Likewise.
10121 * term/i386/pc/vga.c (get_map_mask): Switch order of arguments in
10123 (set_map_mask): Likewise.
10124 (set_read_map): Likewise.
10125 (set_read_address): Likewise.
10126 (vga_font): Removed variable.
10127 (get_vga_glyph): Removed function.
10128 (invalidate_char): Likewise.
10129 (write_char): Changed to use grub_font_get_glyph() for font
10131 (grub_vga_putchar): Likewise.
10132 (grub_vga_getcharwidth): Likewise.
10134 2007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
10136 * conf/i386-pc.rmk (boot_img_LDFLAGS): Use COMMON_LDFLAGS for target
10138 (pxeboot_img_LDFLAGS): Likewise.
10139 (diskboot_img_LDFLAGS): Likewise.
10140 (kernel_img_LDFLAGS): Likewise.
10142 2007-11-06 Robert Millan <rmh@aybabtu.com>
10144 * term/i386/pc/serial.c (serial_hw_put): Switch order of arguments
10145 in grub_outb() calls.
10146 (serial_hw_init): Likewise.
10148 2007-11-05 Robert Millan <rmh@aybabtu.com>
10150 * util/update-grub.in: Allow files in ${update_grub_dir} to contain
10151 spaces. Skip non-regular files.
10153 2007-11-05 Robert Millan <rmh@aybabtu.com>
10155 * kern/disk.c (grub_disk_firmware_fini)
10156 (grub_disk_firmware_is_tainted): New variables.
10158 * include/grub/disk.h (grub_disk_firmware_fini)
10159 (grub_disk_firmware_is_tainted): Likewise.
10161 * disk/i386/pc/biosdisk.c (GRUB_MOD_FINI(biosdisk)): Moved from here ...
10162 (grub_disk_biosdisk_fini): ... to here.
10163 (GRUB_MOD_FINI(biosdisk)): Implement using grub_disk_biosdisk_fini().
10164 (GRUB_MOD_INIT(biosdisk)): Abort when `grub_disk_firmware_is_tainted'
10165 is set. Register grub_disk_biosdisk_fini() in
10166 `grub_disk_firmware_fini'.
10168 * disk/ata.c: Remove `<grub/machine/biosdisk.h>'.
10169 (GRUB_MOD_INIT(ata)): Remove grub_biosdisk_fini() call.
10170 Use `grub_disk_firmware_is_tainted' and `grub_disk_firmware_fini'
10171 to finish existing firmware disk interface.
10173 * conf/i386-linuxbios.rmk (pkgdata_MODULES): Add `ata.mod'.
10174 (ata_mod_SOURCES): New variable.
10175 (ata_mod_CFLAGS): Likewise.
10176 (ata_mod_LDFLAGS): Likewise.
10178 2007-11-05 Robert Millan <rmh@aybabtu.com>
10180 * disk/ata.c: Remove `<grub/machine/time.h>'. Include `<grub/time.h>'.
10181 (grub_ata_wait): Reimplement using grub_millisleep().
10183 * include/grub/misc.h (grub_div_roundup): Fix parenthesization.
10184 * include/grub/i386/time.h (grub_cpu_idle): Disable `hlt' instruction.
10186 2007-11-03 Marco Gerards <marco@gnu.org>
10188 * term/i386/pc/vga_text.c: Include <grub/cpu/io.h>.
10189 (CRTC_ADDR_PORT): New macro.
10190 (CRTC_DATA_PORT): Likewise.
10191 (CRTC_CURSOR): Likewise.
10192 (CRTC_CURSOR_ADDR_HIGH): Likewise.
10193 (CRTC_CURSOR_ADDR_LOW): Likewise.
10194 (update_cursor): New function.
10195 (grub_console_real_putchar): Call `update_cursor'.
10196 (grub_console_gotoxy): Likewise.
10197 (grub_console_cls): Set the default color when clearing the
10199 (grub_console_setcursor): Implemented.
10201 2007-11-03 Marco Gerards <marco@gnu.org>
10203 * disk/ata.c (grub_ata_pio_read): Don't wait for the command to
10205 (grub_ata_pio_write): Likewise.
10207 (grub_atapi_identify): Wait after issuing an ATA command.
10208 (grub_atapi_packet): Likewise.
10209 (grub_ata_identify): Likewise.
10210 (grub_ata_readwrite): Likewise.
10212 2007-11-03 Marco Gerards <marco@gnu.org>
10214 * disk/ata.c (grub_ata_pio_read): Detect and return the error code.
10215 (grub_ata_pio_write): Likewise.
10216 (grub_ata_readwrite): Use `grub_error', instead of
10217 returning `grub_errno'.
10219 2007-11-03 Marco Gerards <marco@gnu.org>
10221 * disk/ata.c (grub_ata_readwrite): Call grub_ata_pio_read and
10222 grub_ata_pio_write once for every single sector, instead of for
10225 2007-10-31 Robert Millan <rmh@aybabtu.com>
10227 * configure.ac: Add `i386-linuxbios' to the list of supported targets.
10229 * conf/i386-linuxbios.rmk: New file.
10231 * kern/i386/pc/hardware.c: Likewise.
10232 * term/i386/pc/at_keyboard.c: Likewise.
10233 * term/i386/pc/vga_text.c: Likewise.
10235 * include/grub/i386/linuxbios/boot.h: Likewise.
10236 * include/grub/i386/linuxbios/console.h: Likewise.
10237 * include/grub/i386/linuxbios/init.h: Likewise.
10238 * include/grub/i386/linuxbios/kernel.h: Likewise.
10239 * include/grub/i386/linuxbios/loader.h: Likewise.
10240 * include/grub/i386/linuxbios/memory.h: Likewise.
10241 * include/grub/i386/linuxbios/serial.h: Likewise.
10242 * include/grub/i386/linuxbios/time.h: Likewise.
10244 * kern/i386/linuxbios/init.c: Likewise.
10245 * kern/i386/linuxbios/startup.S: Likewise.
10246 * kern/i386/linuxbios/table.c: Likewise.
10248 2007-10-31 Marco Gerards <marco@gnu.org>
10250 * conf/i386-pc.rmk (pkgdata_MODULES): Add `ata.mod'.
10251 (ata_mod_SOURCES): New variable.
10252 (ata_mod_CFLAGS): Likewise.
10253 (ata_mod_LDFLAGS): Likewise.
10255 * disk/ata.c: New file.
10257 * include/grub/disk.h (grub_disk_dev_id): Add
10258 `GRUB_DISK_DEV_ATA_ID'.
10260 2007-10-31 Robert Millan <rmh@aybabtu.com>
10262 * include/grub/i386/pc/init.h (grub_lower_mem): Moved from here ...
10263 * include/grub/i386/pc/memory.h (grub_lower_mem): ... to here.
10265 * include/grub/i386/pc/init.h (grub_upper_mem): Moved from here ...
10266 * include/grub/i386/pc/memory.h (grub_upper_mem): ... to here.
10268 * include/grub/i386/pc/memory.h: Include `<grub/symbol.h>' and
10271 * loader/i386/pc/multiboot.c: Include `<grub/machine/memory.h>'.
10273 2007-10-27 Robert Millan <rmh@aybabtu.com>
10275 * include/grub/types.h (ULONG_MAX): Define macro.
10277 2007-10-22 Robert Millan <rmh@aybabtu.com>
10279 * kern/i386/pc/startup.S: Remove `"kern/i386/realmode.S"'. Include
10281 Remove `"kern/i386/loader.S"'. Include `"../loader.S"'.
10283 2007-10-22 Robert Millan <rmh@aybabtu.com>
10285 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove `disk/i386/pc/biosdisk.c'.
10286 (pkgdata_MODULES): Add `biosdisk.mod'.
10287 (biosdisk_mod_SOURCES, biosdisk_mod_CFLAGS, biosdisk_mod_LDFLAGS): New
10290 * disk/i386/pc/biosdisk.c: Include `<grub/dl.h>'.
10291 (grub_biosdisk_init): Replace with ...
10292 (GRUB_MOD_INIT(biosdisk)): ... this.
10293 (grub_biosdisk_fini): Replace with ...
10294 (GRUB_MOD_FINI(biosdisk)): ... this.
10296 * kern/i386/pc/init.c: Remove `<grub/machine/biosdisk.h>'.
10297 (grub_machine_init): Remove call to grub_biosdisk_init().
10298 (grub_machine_fini): Remove call to grub_machine_fini().
10300 * util/i386/pc/grub-install.in (modules): Add `biosdisk'.
10302 2007-10-22 Robert Millan <rmh@aybabtu.com>
10304 * include/grub/time.h: New file.
10305 * include/grub/i386/time.h: Likewise.
10306 * include/grub/powerpc/time.h: Likewise.
10307 * include/grub/sparc64/time.h: Likewise.
10309 * include/grub/i386/pc/time.h (KERNEL_TIME_HEADER): Rename all
10311 (KERNEL_MACHINE_TIME_HEADER): ... this.
10312 * include/grub/powerpc/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
10314 (KERNEL_MACHINE_TIME_HEADER): ... this.
10315 * include/grub/sparc64/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
10317 (KERNEL_MACHINE_TIME_HEADER): ... this.
10319 * kern/i386/efi/init.c: Include `<grub/time.h>'.
10320 (grub_millisleep): New function.
10321 * kern/i386/pc/init.c: Include `<grub/time.h>'.
10322 (grub_millisleep): New function.
10323 * kern/powerpc/ieee1275/init.c: Include `<grub/time.h>'.
10324 Remove `grub/machine/time.h' include.
10325 (grub_millisleep): New function.
10326 * kern/sparc64/ieee1275/init.c: Include `<grub/time.h>'.
10327 Remove `grub/machine/time.h' include.
10328 (grub_millisleep): New function.
10330 * include/grub/misc.h (grub_div_roundup): New function.
10332 * kern/misc.c: Include `<grub/time.h>'.
10333 (grub_millisleep_generic): New function.
10335 * conf/i386-efi.rmk (kernel_mod_HEADERS): Remove `i386/efi/time.h'.
10337 * conf/i386-pc.rmk (kernel_img_HEADERS): Remove `machine/time.h'.
10339 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Remove
10340 `machine/time.h'. Add `time.h'.
10341 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
10343 2007-10-21 Robert Millan <rmh@aybabtu.com>
10345 * include/grub/misc.h (grub_max): New function.
10347 2007-10-21 Robert Millan <rmh@aybabtu.com>
10349 * util/misc.c (grub_util_info): Call fflush() before returning.
10351 2007-10-20 Robert Millan <rmh@aybabtu.com>
10353 * genmk.rb (Image): Copy `extra_flags' from here ...
10354 (PModule): ... to here. Use it in `#{obj}: #{src}' rule.
10356 * commands/i386/cpuid.c (grub_cmd_cpuid): Add __attribute__ ((unused))
10357 to `argc' and `args' arguments.
10359 2007-10-17 Robert Millan <rmh@aybabtu.com>
10361 * kern/i386/loader.S: New file.
10363 * kern/i386/pc/startup.S (grub_linux_prot_size): Moved from here ...
10364 * kern/i386/loader.S (grub_linux_prot_size)... to here.
10365 * kern/i386/pc/startup.S (grub_linux_tmp_addr): Moved from here ...
10366 * kern/i386/loader.S (grub_linux_tmp_addr)... to here.
10367 * kern/i386/pc/startup.S (grub_linux_real_addr): Moved from here ...
10368 * kern/i386/loader.S (grub_linux_real_addr)... to here.
10369 * kern/i386/pc/startup.S (grub_linux_boot_zimage): Moved from here ...
10370 * kern/i386/loader.S (grub_linux_boot_zimage)... to here.
10371 * kern/i386/pc/startup.S (grub_linux_boot_bzimage): Moved from here ...
10372 * kern/i386/loader.S (grub_linux_boot_bzimage)... to here.
10373 * kern/i386/pc/startup.S (grub_multiboot_real_boot): Moved from here ...
10374 * kern/i386/loader.S (grub_multiboot_real_boot)... to here.
10375 * kern/i386/pc/startup.S (grub_multiboot2_real_boot): Moved from here ...
10376 * kern/i386/loader.S (grub_multiboot2_real_boot)... to here.
10378 * kern/i386/realmode.S: New file.
10380 * kern/i386/pc/startup.S (protstack): Moved from here ...
10381 * kern/i386/realmode.S (protstack)... to here.
10382 * kern/i386/pc/startup.S (gdt): Moved from here ...
10383 * kern/i386/realmode.S (gdt)... to here.
10384 * kern/i386/pc/startup.S (prot_to_real): Moved from here ...
10385 * kern/i386/realmode.S (prot_to_real)... to here.
10387 * kern/i386/pc/startup.S: Include `kern/i386/loader.S' and
10388 `kern/i386/realmode.S'.
10390 2007-10-17 Robert Millan <rmh@aybabtu.com>
10392 * include/grub/i386/loader.h: New file.
10394 * include/grub/i386/pc/loader.h (grub_linux_prot_size)
10395 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
10396 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
10397 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
10398 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): Moved from here ...
10399 * include/grub/i386/loader.h (grub_linux_prot_size)
10400 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
10401 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
10402 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
10403 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): ... to here.
10405 * include/grub/i386/pc/loader.h: Include `grub/cpu/loader.h'.
10407 2007-10-15 Robert Millan <rmh@aybabtu.com>
10409 * normal/misc.c (grub_normal_print_device_info): Do not probe for
10410 filesystem when dev->disk is unset.
10411 Do probe for filesystem even when dev->disk->has_partitions is set.
10412 In case a filesystem is found, always report it.
10413 In case it isn't, if dev->disk->has_partitions is set, report that
10414 a partition table was found instead of reporting that no filesystem
10415 could be identified.
10417 2007-10-12 Robert Millan <rmh@aybabtu.com>
10419 * conf/powerpc-ieee1275.rmk (grub_mkimage_SOURCES): Replace reference
10420 to util/powerpc/ieee1275/grub-mkimage.c with util/elf/grub-mkimage.c.
10422 * include/grub/types.h (grub_host_to_target16): New macro.
10423 (grub_host_to_target32): Likewise.
10424 (grub_host_to_target64): Likewise.
10425 (grub_target_to_host16): Likewise.
10426 (grub_target_to_host32): Likewise.
10427 (grub_target_to_host64): Likewise.
10429 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
10430 Renamed from to ...
10431 (GRUB_MOD_ALIGN): ...this. Update all users.
10433 * util/elf/grub-mkimage.c (load_note): Replace grub_cpu_to_be32 with
10434 grub_host_to_target32.
10435 Replace grub_be_to_cpu32 with grub_target_to_host32.
10436 (load_modules): Likewise.
10437 (add_segments): Replace grub_be_to_cpu16 with grub_target_to_host16.
10438 Replace grub_be_to_cpu32 with grub_target_to_host32.
10439 Replace grub_cpu_to_be16 with grub_host_to_target16.
10440 Replace grub_cpu_to_be32 grub_host_to_target32.
10442 2007-10-12 Robert Millan <rmh@aybabtu.com>
10444 * util/powerpc/ieee1275/grub-mkimage.c: Moved to ...
10445 * util/elf/grub-mkimage.c: ... here.
10447 * DISTLIST: Add `util/elf/grub-mkimage.c'. Remove
10448 `util/powerpc/ieee1275/grub-mkimage.c'.
10450 2007-10-07 Robert Millan <rmh@aybabtu.com>
10452 * kern/powerpc/ieee1275/init.c: Rename HEAP_LIMIT to HEAP_MAX_ADDR,
10453 and make it easier to figure out.
10454 Add HEAP_MIN_SIZE and HEAP_MAX_ADDR definitions.
10455 (grub_claim_heap): Use HEAP_MAX_ADDR rather than taking a parameter.
10456 Do not avoid claiming a region above HEAP_MAX_ADDR if that would
10457 leave us with less than HEAP_MIN_SIZE total heap.
10458 Avoid our total amount of heap to surpass HEAP_MAX_SIZE.
10460 2007-10-03 Robert Millan <rmh@aybabtu.com>
10462 * include/grub/i386/io.h: New file.
10463 * commands/i386/pc/play.c (inb): Removed.
10465 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
10467 * term/i386/pc/serial.c (inb): Removed.
10469 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
10471 * term/i386/pc/vga.c (inb): Removed.
10473 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
10476 2007-10-02 Robert Millan <rmh@aybabtu.com>
10478 * conf/i386-efi.rmk (grub_emu_SOURCES): Add util/hostfs.c.
10479 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
10480 Reported by Marcin Kurek.
10482 2007-09-07 Robert Millan <rmh@aybabtu.com>
10484 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_test_flag): Detect
10485 SmartFirmware version updates (as released by Sven Luther), and avoid
10486 setting GRUB_IEEE1275_FLAG_NO_PARTITION_0 or
10487 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS unless the running version is
10490 2007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
10492 From Hitoshi Ozeki:
10493 * kern/i386/pc/init.c (compact_mem_regions): Decrease NUM_REGIONS
10494 when merging two regions.
10496 2007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
10498 * kern/rescue.c (grub_enter_rescue_mode): Free ARGS.
10499 * normal/completion.c (grub_normal_do_completion): Likewise.
10500 Reported by Hitoshi Ozeki.
10502 2007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
10504 Do not use devices at boot in chainloading.
10506 * loader/i386/pc/chainloader.c (boot_drive): New variable.
10507 (boot_part_addr): Likewise.
10508 (grub_chainloader_boot): Simply call grub_chainloader_real_boot
10509 with BOOT_DRIVE and BOOT_PART_ADDR.
10510 (grub_chainloader_cmd): Set BOOT_DRIVE and BOOT_PART_ADDR.
10511 Reported by Hitoshi Ozeki <h-ozeki@ck2.so-net.ne.jp>.
10513 2007-08-29 Robert Millan <rmh@aybabtu.com>
10515 Patch from Simon Peter <dn.tlp@gmx.net>:
10516 * genmk.rb (Utility): Append $(#{src}_DEPENDENCIES) to #{obj} targets.
10517 * conf/i386-pc.rmk: Replace grub-probe_DEPENDENCIES with
10518 util/grub-probe.c_DEPENDENCIES. Replace grub-setup_DEPENDENCIES with
10519 util/i386/pc/grub-setup.c_DEPENDENCIES.
10520 * conf/i386-efi.rmk: Replace grub-probe_DEPENDENCIES with
10521 util/grub-probe.c_DEPENDENCIES.
10522 * conf/powerpc-ieee1275.rmk: Likewise.
10524 2007-08-28 Robert Millan <rmh@aybabtu.com>
10526 * util/i386/get_disk_name.c: New. Implement grub_util_get_disk_name()
10527 to tell grub-mkdevicemap how to name devices.
10528 * util/ieee1275/get_disk_name.c: Likewise (using "ofpathname -a"
10531 * conf/i386-efi.rmk (grub_mkdevicemap_SOURCES): Add
10532 util/i386/get_disk_name.c.
10533 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Likewise.
10534 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Add
10535 util/ieee1275/get_disk_name.c.
10537 * include/grub/util/misc.h: grub_util_get_disk_name() declaration.
10539 * DISTLIST: Add util/i386/get_disk_name.c and
10540 util/ieee1275/get_disk_name.c.
10542 * util/grub-mkdevicemap.c: Replace device naming logic with
10543 grub_util_get_disk_name() calls.
10545 2007-08-20 Robert Millan <rmh@aybabtu.com>
10547 * normal/menu.c (run_menu): Refer to seconds as "s" not "seconds"
10548 (so that it works for both plural and singular quantities).
10550 2007-08-05 Robert Millan <rmh@aybabtu.com>
10552 * util/grub.d/10_linux.in (test_gt): Strip out vmlinu[xz]- prefix
10553 so that [xz] isn't taken into account when determining order.
10555 2007-08-02 Marco Gerards <marco@gnu.org>
10557 * DISTLIST: Add `disk/host.c', `fs/ntfs.c', `include/multiboot.h',
10558 `include/multiboot2.h', `include/grub/elfload.h',
10559 `include/multiboot.h', `include/grub/multiboot.h',
10560 `include/grub/multiboot_loader.h', `include/grub/multiboot2.h',
10561 `include/grub/i386/pc/biosdisk.h', `include/grub/util/biosdisk.h',
10562 `kern/elf.c', `loader/multiboot_loader.c',
10563 `loader/multiboot_loader_normal.c', `loader/multiboot2.c',
10564 `loader/i386/pc/multiboot2.c',
10565 `loader/powerpc/ieee1275/multiboot2.c', `util/hostfs.c' and
10566 `util/i386/pc/grub-mkrescue.in'. Remove
10567 `include/grub/biosdisk.h', `include/grub/i386/pc/multiboot.h',
10568 `include/grub/i386/pc/util/biosdisk.h' and
10569 `include/grub/powerpc/ieee1275/multiboot.h'.
10571 2007-08-02 Bean <bean123ch@gmail.com>
10573 * conf/common.rmk (pkgdata_MODULES): Add ntfs.mod.
10574 (ntfs_mod_SOURCES): New variable.
10575 (ntfs_mod_CFLAGS): Likewise.
10576 (ntfs_mod_LDFLAGS): Likewise.
10578 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfs.c.
10579 (grub_probe_SOURCES): Likewise.
10580 (grub_emu_SOURCES): Likewise.
10582 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
10583 (grub_emu_SOURCES): Likewise.
10585 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
10586 (grub_emu_SOURCES): Likewise.
10588 * conf/misc.c (grub_utf16_to_utf8): Fix unicode conversion bug.
10590 * fs/ntfs.c: New file.
10592 2007-08-02 Bean <bean123ch@gmail.com>
10594 * disk.h (grub_disk): Use NESTED_FUNC_ATTR.
10596 * file.h (grub_file): Likewise.
10598 * fshelp.h (grub_fshelp_read_file): Likewise.
10600 * util/i386/pc/grub-setup.c (setup): Likewise.
10601 (save_first_sector): Likewise.
10602 (save_blocklists): Likewise.
10604 * fs/affs.c (grub_affs_read_file): Likewise.
10606 * fs/ext2.c (grub_ext2_read_file): Likewise.
10608 * fs/fat.c (grub_fat_read_data): Likewise.
10610 * fs/fshelp.c (grub_fshelp_read_file): Likewise.
10612 * fs/hfs.c (grub_hfs_read_file): Likewise.
10614 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
10616 * fs/jfs.c (grub_jfs_read_file): Likewise.
10618 * fs/minix.c (grub_minix_read_file): Likewise.
10620 * fs/sfs.c (grub_sfs_read_file): Likewise.
10622 * fs/ufs.c (grub_ufs_read_file): Likewise.
10624 * fs/xfs.c (grub_xfs_read_file): Likewise.
10626 * command/blocklist.c (read_blocklist): Likewise.
10627 (print_blocklist): Likewise.
10629 2007-08-02 Marco Gerards <marco@gnu.org>
10631 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/host.c' and
10634 * disk/host.c: New file.
10636 * util/hostfs.c: Likewise.
10638 * fs/hfsplus.c (grub_hfsplus_mount): When reading out of disk,
10639 return `GRUB_ERR_BAD_FS'.
10640 * fs/sfs.c (grub_sfs_mount): Likewise.
10641 * fs/xfs.c (grub_xfs_mount): Likewise.
10643 * include/grub/disk.h (enum grub_disk_dev_id): Add
10644 `GRUB_DISK_DEVICE_HOST_ID'.
10646 * util/grub-emu.c (main): Initialize and de-initialize hostfs.
10648 2007-07-24 Jerone Young <jerone@gmail.com>
10650 * conf/i386-pc.rmk: Add Multiboot loader and multiboot 2 to multiboot
10651 modules for compilation.
10652 * conf/powerpc-ieee1275.rmk: Likewise.
10654 * include/multiboot.h: Move multiboot definitions to one file. Rename
10655 many definitions to not get grub specific.
10656 * include/multiboot2.h: Create header with multiboot 2 definitions.
10657 * include/grub/multiboot.h: Header for grub specific function
10658 prototypes and definitions.
10659 * include/grub/multiboot2.h: Likewise.
10660 * include/grub/multiboot_loader.h: Likewise.
10661 * include/grub/i386/pc/multiboot.h: Removed.
10662 * include/grub/powerpc/ieee1275/multiboot.h: Removed.
10664 * loader/multiboot_loader.c: Created to act as a proxy for multiboot 1
10665 and 2 to allow for one multiboot and module commands.
10666 * loader/multiboot2.c: Add multiboot2 functionality.
10667 * loader/i386/pc/multiboot.c: Modify for new multiboot header location
10668 and definition names.
10669 * loader/i386/pc/multiboot2.c: Created to add i386 specific multiboot
10671 * loader/powerpc/ieee1275/multiboot2.c: Created to add powerpc
10672 ieee1275 specific multiboot2 code.
10674 * kern/i386/pc/startup.S: Change headers and definition names for
10675 multiboot. Add function grub_multiboot2_real_boot for multiboot 2.
10677 2007-07-22 Robert Millan <rmh@aybabtu.com>
10679 * geninitheader.sh: Process file specified in first parameter rather
10680 than hardcoding grub_modules_init.lst.
10681 * geninit.sh: Likewise. Also, construct header name dynamically rather
10682 than hardcoding grub_modules_init.h.
10684 * conf/common.rmk: Rename grub_modules_init.[ch] files associated with
10685 grub-emu to grub_emu_init.[ch]. Add rules to build analogous
10686 grub_probe_init.[ch] and grub_setup_init.[ch].
10688 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Replace
10689 grub_modules_init.h with grub_emu_init.h.
10690 (grub_probe_DEPENDENCIES, grub_probe_SOURCES): Add new
10691 grub_probe_init.[ch] files.
10692 * conf/i386-efi.rmk: Likewise.
10693 * conf/i386-pc.rmk: Likewise.
10694 (grub_setup_DEPENDENCIES, grub_setup_SOURCES): Add new
10695 grub_setup_init.[ch] files.
10697 * util/grub-emu.c: Replace grub_modules_init.h with grub_emu_init.h.
10698 * util/grub-probe.c: Include grub_probe_init.h. Use grub_init_all()
10699 to initialize modules rather than a list of hardcoded functions.
10700 * util/i386/pc/grub-setup.c: Include grub_setup_init.h. Use
10701 grub_init_all() to initialize modules rather than a list of hardcoded
10704 2007-07-22 Robert Millan <rmh@aybabtu.com>
10706 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set
10707 GRUB_IEEE1275_FLAG_NO_PARTITION_0 flag when running on SmartFirmware.
10709 2007-07-22 Robert Millan <rmh@aybabtu.com>
10711 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
10712 GRUB_IEEE1275_FLAG_BROKEN_OUTPUT flag.
10713 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set this
10714 flag when running on SmartFirmware.
10715 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid running
10716 "output-device output" command when GRUB_IEEE1275_FLAG_BROKEN_OUTPUT
10719 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
10720 Increase partno when GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS flag is set,
10721 rather than decreasing it.
10723 * util/i386/pc/grub-setup.c (setup): When embedding is required, but
10724 there's not enough space to do it, fail in the same way as when it
10725 can't be done because there are no partitions.
10727 * util/powerpc/ieee1275/grub-install.in: Improve error message shown
10728 when nvsetenv failed.
10730 2007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
10732 * conf/i386-pc.rmk (CLEANFILES): Removed for grub-mkrescue,
10733 because this rule is automatically generated.
10734 (grub-mkrescue): Removed for the same reason as above.
10736 2007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
10738 Migrate to GNU General Public License Version 3.
10740 * COPYING: Replaced with the plain text version of GPLv3.
10742 * config.guess: Updated from gnulib.
10743 * config.sub: Likewise.
10745 * geninit.sh: Output a GPLv3 copyright notice.
10746 * geninitheader.sh: Likewise.
10747 * genmodsrc.sh: Likewise.
10748 * gensymlist.sh.in: Likewise.
10750 * boot/i386/pc/boot.S: Upgraded to GPLv3.
10751 * boot/i386/pc/diskboot.S: Likewise.
10752 * boot/i386/pc/pxeboot.S: Likewise.
10753 * commands/blocklist.c: Likewise.
10754 * commands/boot.c: Likewise.
10755 * commands/cat.c: Likewise.
10756 * commands/cmp.c: Likewise.
10757 * commands/configfile.c: Likewise.
10758 * commands/echo.c: Likewise.
10759 * commands/help.c: Likewise.
10760 * commands/ls.c: Likewise.
10761 * commands/search.c: Likewise.
10762 * commands/terminal.c: Likewise.
10763 * commands/test.c: Likewise.
10764 * commands/videotest.c: Likewise.
10765 * commands/i386/cpuid.c: Likewise.
10766 * commands/i386/pc/halt.c: Likewise.
10767 * commands/i386/pc/play.c: Likewise.
10768 * commands/i386/pc/reboot.c: Likewise.
10769 * commands/i386/pc/vbeinfo.c: Likewise.
10770 * commands/i386/pc/vbetest.c: Likewise.
10771 * commands/ieee1275/halt.c: Likewise.
10772 * commands/ieee1275/reboot.c: Likewise.
10773 * commands/ieee1275/suspend.c: Likewise.
10774 * disk/loopback.c: Likewise.
10775 * disk/lvm.c: Likewise.
10776 * disk/raid.c: Likewise.
10777 * disk/efi/efidisk.c: Likewise.
10778 * disk/i386/pc/biosdisk.c: Likewise.
10779 * disk/ieee1275/ofdisk.c: Likewise.
10780 * font/manager.c: Likewise.
10781 * fs/affs.c: Likewise.
10782 * fs/ext2.c: Likewise.
10783 * fs/fat.c: Likewise.
10784 * fs/fshelp.c: Likewise.
10785 * fs/hfs.c: Likewise.
10786 * fs/hfsplus.c: Likewise.
10787 * fs/iso9660.c: Likewise.
10788 * fs/jfs.c: Likewise.
10789 * fs/minix.c: Likewise.
10790 * fs/sfs.c: Likewise.
10791 * fs/ufs.c: Likewise.
10792 * fs/xfs.c: Likewise.
10793 * hello/hello.c: Likewise.
10794 * include/grub/acorn_filecore.h: Likewise.
10795 * include/grub/arg.h: Likewise.
10796 * include/grub/bitmap.h: Likewise.
10797 * include/grub/boot.h: Likewise.
10798 * include/grub/cache.h: Likewise.
10799 * include/grub/device.h: Likewise.
10800 * include/grub/disk.h: Likewise.
10801 * include/grub/dl.h: Likewise.
10802 * include/grub/elfload.h: Likewise.
10803 * include/grub/env.h: Likewise.
10804 * include/grub/err.h: Likewise.
10805 * include/grub/file.h: Likewise.
10806 * include/grub/font.h: Likewise.
10807 * include/grub/fs.h: Likewise.
10808 * include/grub/fshelp.h: Likewise.
10809 * include/grub/gzio.h: Likewise.
10810 * include/grub/hfs.h: Likewise.
10811 * include/grub/kernel.h: Likewise.
10812 * include/grub/loader.h: Likewise.
10813 * include/grub/lvm.h: Likewise.
10814 * include/grub/misc.h: Likewise.
10815 * include/grub/mm.h: Likewise.
10816 * include/grub/net.h: Likewise.
10817 * include/grub/normal.h: Likewise.
10818 * include/grub/parser.h: Likewise.
10819 * include/grub/partition.h: Likewise.
10820 * include/grub/pc_partition.h: Likewise.
10821 * include/grub/raid.h: Likewise.
10822 * include/grub/rescue.h: Likewise.
10823 * include/grub/script.h: Likewise.
10824 * include/grub/setjmp.h: Likewise.
10825 * include/grub/symbol.h: Likewise.
10826 * include/grub/term.h: Likewise.
10827 * include/grub/terminfo.h: Likewise.
10828 * include/grub/tparm.h: Likewise.
10829 * include/grub/types.h: Likewise.
10830 * include/grub/video.h: Likewise.
10831 * include/grub/efi/api.h: Likewise.
10832 * include/grub/efi/chainloader.h: Likewise.
10833 * include/grub/efi/console.h: Likewise.
10834 * include/grub/efi/console_control.h: Likewise.
10835 * include/grub/efi/disk.h: Likewise.
10836 * include/grub/efi/efi.h: Likewise.
10837 * include/grub/efi/pe32.h: Likewise.
10838 * include/grub/efi/time.h: Likewise.
10839 * include/grub/i386/linux.h: Likewise.
10840 * include/grub/i386/setjmp.h: Likewise.
10841 * include/grub/i386/types.h: Likewise.
10842 * include/grub/i386/efi/kernel.h: Likewise.
10843 * include/grub/i386/efi/loader.h: Likewise.
10844 * include/grub/i386/efi/time.h: Likewise.
10845 * include/grub/i386/pc/biosdisk.h: Likewise.
10846 * include/grub/i386/pc/boot.h: Likewise.
10847 * include/grub/i386/pc/chainloader.h: Likewise.
10848 * include/grub/i386/pc/console.h: Likewise.
10849 * include/grub/i386/pc/init.h: Likewise.
10850 * include/grub/i386/pc/kernel.h: Likewise.
10851 * include/grub/i386/pc/loader.h: Likewise.
10852 * include/grub/i386/pc/memory.h: Likewise.
10853 * include/grub/i386/pc/multiboot.h: Likewise.
10854 * include/grub/i386/pc/serial.h: Likewise.
10855 * include/grub/i386/pc/time.h: Likewise.
10856 * include/grub/i386/pc/vbe.h: Likewise.
10857 * include/grub/i386/pc/vbeblit.h: Likewise.
10858 * include/grub/i386/pc/vbefill.h: Likewise.
10859 * include/grub/i386/pc/vbeutil.h: Likewise.
10860 * include/grub/i386/pc/vga.h: Likewise.
10861 * include/grub/ieee1275/ieee1275.h: Likewise.
10862 * include/grub/ieee1275/ofdisk.h: Likewise.
10863 * include/grub/powerpc/libgcc.h: Likewise.
10864 * include/grub/powerpc/setjmp.h: Likewise.
10865 * include/grub/powerpc/types.h: Likewise.
10866 * include/grub/powerpc/ieee1275/biosdisk.h: Likewise.
10867 * include/grub/powerpc/ieee1275/console.h: Likewise.
10868 * include/grub/powerpc/ieee1275/ieee1275.h: Likewise.
10869 * include/grub/powerpc/ieee1275/kernel.h: Likewise.
10870 * include/grub/powerpc/ieee1275/loader.h: Likewise.
10871 * include/grub/powerpc/ieee1275/multiboot.h: Likewise.
10872 * include/grub/powerpc/ieee1275/time.h: Likewise.
10873 * include/grub/powerpc/ieee1275/util/biosdisk.h: Likewise.
10874 * include/grub/sparc64/libgcc.h: Likewise.
10875 * include/grub/sparc64/setjmp.h: Likewise.
10876 * include/grub/sparc64/types.h: Likewise.
10877 * include/grub/sparc64/ieee1275/console.h: Likewise.
10878 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
10879 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
10880 * include/grub/sparc64/ieee1275/time.h: Likewise.
10881 * include/grub/util/biosdisk.h: Likewise.
10882 * include/grub/util/getroot.h: Likewise.
10883 * include/grub/util/lvm.h: Likewise.
10884 * include/grub/util/misc.h: Likewise.
10885 * include/grub/util/raid.h: Likewise.
10886 * include/grub/util/resolve.h: Likewise.
10887 * io/gzio.c: Likewise.
10888 * kern/device.c: Likewise.
10889 * kern/disk.c: Likewise.
10890 * kern/dl.c: Likewise.
10891 * kern/elf.c: Likewise.
10892 * kern/env.c: Likewise.
10893 * kern/err.c: Likewise.
10894 * kern/file.c: Likewise.
10895 * kern/fs.c: Likewise.
10896 * kern/loader.c: Likewise.
10897 * kern/main.c: Likewise.
10898 * kern/misc.c: Likewise.
10899 * kern/mm.c: Likewise.
10900 * kern/parser.c: Likewise.
10901 * kern/partition.c: Likewise.
10902 * kern/rescue.c: Likewise.
10903 * kern/term.c: Likewise.
10904 * kern/efi/efi.c: Likewise.
10905 * kern/efi/init.c: Likewise.
10906 * kern/efi/mm.c: Likewise.
10907 * kern/i386/dl.c: Likewise.
10908 * kern/i386/efi/init.c: Likewise.
10909 * kern/i386/efi/startup.S: Likewise.
10910 * kern/i386/pc/init.c: Likewise.
10911 * kern/i386/pc/lzo1x.S: Likewise.
10912 * kern/i386/pc/startup.S: Likewise.
10913 * kern/ieee1275/ieee1275.c: Likewise.
10914 * kern/powerpc/cache.S: Likewise.
10915 * kern/powerpc/dl.c: Likewise.
10916 * kern/powerpc/ieee1275/cmain.c: Likewise.
10917 * kern/powerpc/ieee1275/crt0.S: Likewise.
10918 * kern/powerpc/ieee1275/init.c: Likewise.
10919 * kern/powerpc/ieee1275/openfw.c: Likewise.
10920 * kern/sparc64/cache.S: Likewise.
10921 * kern/sparc64/dl.c: Likewise.
10922 * kern/sparc64/ieee1275/init.c: Likewise.
10923 * kern/sparc64/ieee1275/openfw.c: Likewise.
10924 * loader/efi/chainloader.c: Likewise.
10925 * loader/efi/chainloader_normal.c: Likewise.
10926 * loader/i386/efi/linux.c: Likewise.
10927 * loader/i386/efi/linux_normal.c: Likewise.
10928 * loader/i386/pc/chainloader.c: Likewise.
10929 * loader/i386/pc/chainloader_normal.c: Likewise.
10930 * loader/i386/pc/linux.c: Likewise.
10931 * loader/i386/pc/linux_normal.c: Likewise.
10932 * loader/i386/pc/multiboot.c: Likewise.
10933 * loader/i386/pc/multiboot_normal.c: Likewise.
10934 * loader/powerpc/ieee1275/linux.c: Likewise.
10935 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
10936 * normal/arg.c: Likewise.
10937 * normal/cmdline.c: Likewise.
10938 * normal/command.c: Likewise.
10939 * normal/completion.c: Likewise.
10940 * normal/execute.c: Likewise.
10941 * normal/function.c: Likewise.
10942 * normal/lexer.c: Likewise.
10943 * normal/main.c: Likewise.
10944 * normal/menu.c: Likewise.
10945 * normal/menu_entry.c: Likewise.
10946 * normal/misc.c: Likewise.
10947 * normal/parser.y: Likewise.
10948 * normal/script.c: Likewise.
10949 * normal/i386/setjmp.S: Likewise.
10950 * normal/powerpc/setjmp.S: Likewise.
10951 * normal/sparc64/setjmp.S: Likewise.
10952 * partmap/acorn.c: Likewise.
10953 * partmap/amiga.c: Likewise.
10954 * partmap/apple.c: Likewise.
10955 * partmap/gpt.c: Likewise.
10956 * partmap/pc.c: Likewise.
10957 * partmap/sun.c: Likewise.
10958 * term/gfxterm.c: Likewise.
10959 * term/terminfo.c: Likewise.
10960 * term/efi/console.c: Likewise.
10961 * term/i386/pc/console.c: Likewise.
10962 * term/i386/pc/serial.c: Likewise.
10963 * term/i386/pc/vesafb.c: Likewise.
10964 * term/i386/pc/vga.c: Likewise.
10965 * term/ieee1275/ofconsole.c: Likewise.
10966 * util/biosdisk.c: Likewise.
10967 * util/console.c: Likewise.
10968 * util/genmoddep.c: Likewise.
10969 * util/getroot.c: Likewise.
10970 * util/grub-emu.c: Likewise.
10971 * util/grub-mkdevicemap.c: Likewise.
10972 * util/grub-probe.c: Likewise.
10973 * util/lvm.c: Likewise.
10974 * util/misc.c: Likewise.
10975 * util/raid.c: Likewise.
10976 * util/resolve.c: Likewise.
10977 * util/update-grub.in: Likewise.
10978 * util/update-grub_lib.in: Likewise.
10979 * util/grub.d/00_header.in: Likewise.
10980 * util/grub.d/10_hurd.in: Likewise.
10981 * util/grub.d/10_linux.in: Likewise.
10982 * util/i386/efi/grub-install.in: Likewise.
10983 * util/i386/efi/grub-mkimage.c: Likewise.
10984 * util/i386/pc/grub-install.in: Likewise.
10985 * util/i386/pc/grub-mkimage.c: Likewise.
10986 * util/i386/pc/grub-mkrescue.in: Likewise.
10987 * util/i386/pc/grub-setup.c: Likewise.
10988 * util/i386/pc/misc.c: Likewise.
10989 * util/powerpc/ieee1275/grub-install.in: Likewise.
10990 * util/powerpc/ieee1275/grub-mkimage.c: Likewise.
10991 * util/powerpc/ieee1275/misc.c: Likewise.
10992 * video/bitmap.c: Likewise.
10993 * video/video.c: Likewise.
10994 * video/i386/pc/vbe.c: Likewise.
10995 * video/i386/pc/vbeblit.c: Likewise.
10996 * video/i386/pc/vbefill.c: Likewise.
10997 * video/i386/pc/vbeutil.c: Likewise.
10998 * video/readers/tga.c: Likewise.
11000 2007-07-02 Robert Millan <rmh@aybabtu.com>
11002 * conf/i386-efi.rmk: Replace obsolete reference to
11003 util/i386/pc/biosdisk.c with util/biosdisk.c, and util/i386/pc/getroot.c
11004 with util/getroot.c.
11005 * conf/powerpc-ieee1275.rmk: Likewise.
11006 * conf/sparc64-ieee1275.rmk: Likewise.
11008 * util/grub-emu.c (main): Fix unchecked pointer handling.
11010 2007-07-02 Robert Millan <rmh@aybabtu.com>
11012 * util/i386/efi/grub-install.in: Allow `grub_probe --target=partmap'
11013 invocation to fail, in order to support partition-less media.
11015 * util/i386/pc/grub-install.in: Likewise.
11017 * util/powerpc/ieee1275/grub-install.in: Use grub-probe to determine
11018 which fs or partmap modules are needed (akin to its sister scripts).
11020 Also use grub-probe to get rid of unportable /proc/mounts check.
11022 Print the same informational message that the other scripts do, before
11025 2007-06-23 Robert Millan <rmh@aybabtu.com>
11027 * util/update-grub_lib.in (font_path): New function. Determine whether
11028 a font file can be found and, if so, echo the GRUB path to it.
11030 * util/update-grub.in: Handle multiple terminals depending on user
11031 input, platform availability and font file presence. Propagate
11032 variables of our findings to /etc/grub.d/ children.
11034 * util/grub.d/00_header.in: Handle multiple terminals, based on
11035 environment setup by update-grub.
11037 2007-06-23 Robert Millan <rmh@aybabtu.com>
11039 * conf/i386-pc.rmk (pkgdata_MODULES): Add serial.mod.
11041 2007-06-21 Robert Millan <rmh@aybabtu.com>
11043 * include/grub/i386/pc/kernel.h: Define GRUB_KERNEL_MACHINE_DATA_END to
11044 indicate end of data section in kernel image.
11045 * include/grub/i386/efi/kernel.h: Define GRUB_KERNEL_MACHINE_PREFIX and
11046 GRUB_KERNEL_MACHINE_DATA_END.
11048 * kern/i386/pc/startup.S: Do not initialize grub_prefix, only reserve
11050 * kern/i386/efi/startup.S: Likewise.
11052 * util/i386/pc/grub-mkimage.c: Initialize grub_prefix to /boot/grub
11053 during image generation. Implement --prefix option to override this
11055 * util/i386/efi/grub-mkimage.c: Likewise.
11057 * util/update-grub_lib.in (convert_system_path_to_grub_path): Split
11058 code to make path relative to its root into a separate function.
11060 * util/i386/pc/grub-install.in: Use newly provided
11061 make_system_path_relative_to_its_root() to convert ${grubdir}, then
11062 pass the result to grub-install --prefix.
11064 2007-06-13 Robert Millan <rmh@aybabtu.com>
11066 * include/grub/util/misc.h: Define DEFAULT_DIRECTORY and
11067 DEFAULT_DEVICE_MAP.
11068 * util/grub-emu.c: Use above definitions from misc.h instead of
11070 * util/grub-mkdevicemap.c: Likewise.
11071 * util/i386/pc/grub-setup.c: Likewise.
11072 * util/grub-probe.c: Likewise.
11073 (probe): Abort with grub_util_error() when either
11074 grub_guess_root_device or grub_util_get_grub_dev fails.
11076 2007-06-12 Robert Millan <rmh@aybabtu.com>
11078 * normal/command.c (grub_command_execute): Use NULL rather than 0 for
11079 "pager" assignment.
11080 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Likewise for
11082 * util/grub-probe.c (probe): Likewise for "drive_name".
11084 2007-06-11 Robert Millan <rmh@aybabtu.com>
11086 * util/i386/pc/grub-mkrescue.in: Pad both floppy images with zeroes,
11087 not just the cdrom one.
11089 2007-06-11 Robert Millan <rmh@aybabtu.com>
11091 * util/i386/pc/grub-mkrescue.in: Add "set -e".
11092 Add --pkglibdir=DIR option to override pkglibdir.
11093 Mention --image-type=TYPE in help output.
11094 Fix --grub-mkimage (it was a no-op).
11095 Abort gracefully when no parameter is given.
11097 2007-06-11 Robert Millan <rmh@aybabtu.com>
11099 * util/i386/pc/grub-mkrescue.in: New file.
11100 * conf/i386-pc.rmk: Add its build declarations. Put it in bin_SCRIPTS.
11101 * Makefile.in: Handle bin_SCRIPTS.
11103 2007-06-10 Vesa Jaaskelainen <chaac@nic.fi>
11105 * term/gfxterm.c (grub_gfxterm_init): Added support for specifying
11106 list of video modes.
11108 2007-06-06 Robert Millan <rmh@aybabtu.com>
11110 * util/update-grub_lib.in (convert_system_path_to_grub_path): Abort if
11111 file doesn't exist, or if it is in a filesystem grub can't read.
11113 * util/update-grub.in: Set fallback for GRUB_FS check to "unknown". Do
11114 not abort if GRUB_DRIVE could not be defined. Rearrange generated
11115 header comment to fit in 80 columns when the variables are resolved.
11117 * util/grub.d/00_header.in: Only set root variable when GRUB_DRIVE
11118 could be identified by update-grub. Remove redundant check for
11119 unifont.pff existence (since convert_system_path_to_grub_path now
11122 2007-06-04 Robert Millan <rmh@aybabtu.com>
11124 * conf/i386-efi.rmk (grub_probe_SOURCES): Add partmap/apple.c.
11126 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise.
11128 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add partmap/pc.c.
11130 2007-06-04 Robert Millan <rmh@aybabtu.com>
11132 * conf/powerpc-ieee1275.rmk: Enable grub-mkdevicemap and grub-probe.
11134 * include/grub/partition.h: Declare grub_apple_partition_map_init and
11135 grub_apple_partition_map_fini.
11138 (grub_util_biosdisk_open): Replace BLKGETSIZE with BLKGETSIZE64 (needed
11139 to access >2 TiB disks).
11141 Print disk->total_sectors with %llu instead of %lu, since this
11142 variable is always 64-bit (prevents wrong disk size from being displayed
11143 on either >2 TiB disk or big-endian CPU).
11145 (grub_util_biosdisk_get_grub_dev): Convert gpt_partition_map handling
11146 into a generic case that supports all (sane) partition maps.
11148 Stop using grub_cpu_to_le32() on dos_part / bsd_part since it actually
11151 * util/grub-probe.c: Call grub_apple_partition_map_init() before probe()
11152 and grub_apple_partition_map_fini() after that.
11154 2007-06-01 Robert Millan <rmh@aybabtu.com>
11156 * util/update-grub.in: Export GRUB_CMDLINE_LINUX.
11158 * util/grub.d/00_header.in: Only enable gfxterm when
11159 convert_system_path_to_grub_path() succeeds.
11161 2007-05-20 Robert Millan <rmh@aybabtu.com>
11163 * util/update-grub_lib.in: New file.
11164 * DISTLIST: Add update-grub_lib.in.
11165 * conf/common.rmk: Generate update-grub_lib and install it in
11167 * Makefile.in: Add install routine for $(lib_DATA).
11169 * util/grub.d/00_header.in: Use convert_system_path_to_grub_path()
11170 function provided by update-grub_lib to support arbitrary paths of
11172 * util/update-grub.in: Use convert_system_path_to_grub_path() to
11173 initialize GRUB_DRIVE_BOOT and GRUB_DRIVE_BOOT_GRUB variables.
11175 2007-05-19 Robert Millan <rmh@aybabtu.com>
11177 * commands/i386/cpuid.c: New module.
11178 * DISTLIST: Add it.
11179 * conf/i386-efi.rmk: Enable cpuid.mod.
11180 * conf/i386-pc.rmk: Likewise.
11182 2007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
11184 * kern/disk.c (grub_disk_read): Check return value of
11187 2007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
11189 * util/getroot.c (grub_util_get_grub_dev): Support partitionable
11191 * disk/raid.c (grub_raid_open): Likewise.
11193 2007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
11195 * util/biosdisk.c (linux_find_partition): Allocate real_dev on the
11196 stack instead of on the heap.
11198 * kern/disk.c (grub_disk_read): Make sure tmp_buf is big enough
11199 before doing a read on it.
11201 * configure.ac: Only use -fno-stack-protector for the target
11204 2007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
11206 * video/i386/pc/vbe.c (grub_video_vbe_create_render_target): Add
11207 __attribute_ ((unused)) to mode_type argument.
11209 * util/getroot.c (grub_guess_root_device): Fix #endif.
11211 * kern/misc.c (memcmp): Fix prototype.
11213 * include/grub/partition.h [GRUB_UTIL]
11214 (grub_gpt_partition_map_init): Add prototype.
11215 (grub_gpt_partition_map_fini): Likewise.
11217 * fs/jfs.c (struct grub_jfs_inode): Put __attribute__ ((packed)
11218 at the right place.
11220 * fs/fat.c (grub_fat_mount): Replace ~0UL with ~0U.
11221 (grub_fat_read_data): Likewise.
11222 (grub_fat_find_dir): Likewise.
11224 * font/manager.c (find_glyph): Make table a const.
11225 (grub_font_get_glyph): Remove bitmap from if statement.
11227 2007-05-16 Jeroen Dekkers <jeroen@dekkers.cx>
11229 * util/getroot.c (grub_guess_root_device): Remove RAID and LVM
11230 code, first search for device in /dev/mapper, then in /dev.
11231 (grub_util_get_grub_dev): New function.
11232 * include/grub/util/getroot.h (grub_util_get_grub_dev): Add
11234 * util/grub-probe.c (probe): Remove check for RAID, call
11235 grub_util_get_grub_dev() instead of
11236 grub_util_biosdisk_get_grub_dev().
11237 * util/grub-emu.c (main): Call grub_util_get_grub_dev() instead of
11238 grub_util_biosdisk_get_grub_dev().
11239 * util/i386/pc/grub-setup.c (main): Likewise.
11241 2007-05-16 Robert Millan <rmh@aybabtu.com>
11243 * DISTLIST: Update for the latest changes.
11244 * conf/i386-pc.rmk: Use the new paths for util/getroot.c,
11245 util/grub-mkdevicemap.c, util/grub-probe.c and util/biosdisk.c.
11246 * util/grub-emu.c: Replace grub/i386/pc/util/biosdisk.h with
11247 grub/util/biosdisk.h.
11248 * util/i386/pc/grub-setup.c: Replace grub/machine/util/biosdisk.h with
11249 grub/util/biosdisk.h.
11251 2007-05-16 Robert Millan <rmh@aybabtu.com>
11253 * util/grub.d/00_header.in: Set default gfxmode to `640x480'.
11255 2007-05-16 Robert Millan <rmh@aybabtu.com>
11257 * util/i386/efi/grub-install.in: New.
11258 * conf/i386-efi.rmk: Enable grub-mkdevicemap, grub-probe and the
11259 newly added grub-install.
11260 * util/biosdisk.c: Remove unnecessary grub/machine/biosdisk.h
11262 * util/getroot.c: Replace grub/i386/pc/util/biosdisk.h with
11263 grub/util/biosdisk.h.
11264 * util/grub-probe.c: Replace grub/machine/util/biosdisk.h with
11265 grub/util/biosdisk.h.
11267 2007-05-16 Robert Millan <rmh@aybabtu.com>
11269 * include/grub/i386/pc/util/biosdisk.h: Moved to ...
11270 * include/grub/util/biosdisk.h: ... here.
11271 * util/i386/pc/biosdisk.c: Moved to ...
11272 * util/biosdisk.c: ... here.
11273 * util/i386/pc/getroot.c: Moved to ...
11274 * util/getroot.c: ... here.
11275 * util/i386/pc/grub-mkdevicemap.c: Moved to ...
11276 * util/grub-mkdevicemap.c: ... here.
11277 * util/i386/pc/grub-probe.c: Moved to ...
11278 * util/grub-probe.c: ... here.
11280 2007-05-15 Robert Millan <rmh@aybabtu.com>
11282 * util/update-grub.in: Remove duplicated line in grub.cfg header
11285 2007-05-13 Robert Millan <rmh@aybabtu.com>
11287 * util/update-grub.in: Fix a few assumptions about the devices holding
11288 /, /boot and /boot/grub being the same.
11289 * util/grub.d/00_header.in: Likewise.
11290 * util/grub.d/10_hurd.in: Likewise.
11291 * util/grub.d/10_linux.in: Likewise.
11293 * util/grub.d/10_linux.in: Implement Linux image sorting with arbitrary
11294 patterns. Use that to define the `.old' suffix as older than `'.
11296 * util/grub.d/00_header.in: Set default gfxmode to `800x600x16'.
11298 * util/update-grub.in: Add a reference to ${sysconfdir}/default/grub in
11299 the grub.cfg header message.
11301 2007-05-11 Robert Millan <rmh@aybabtu.com>
11303 * util/update-grub.in: Create device.map if it doesn't already exist,
11304 before attempting to run grub-probe.
11305 Check for grub-probe and grub-mkdevicemap with the same code
11306 grub-install is using.
11309 2007-05-09 Jeroen Dekkers <jeroen@dekkers.cx>
11311 * Makefile.in: Add the datarootdir autoconf variable.
11313 2007-05-09 Robert Millan <rmh@aybabtu.com>
11315 * util/i386/pc/grub-probe.c (probe): When detecting partition map,
11316 fail gracefully if dev->disk->partition == NULL.
11318 2007-05-07 Robert Millan <rmh@aybabtu.com>
11320 * util/i386/pc/grub-probe.c: Add `grub-probe -t partmap' parameter to
11321 determine partition map module.
11322 * util/i386/pc/grub-install.in: Use this feature to decide which
11323 partition module to load, instead of hardcoding pc and gpt.
11325 2007-05-07 Robert Millan <rmh@aybabtu.com>
11327 * Makefile.in: Fix assumption that $(srcdir) has a trailing slash when
11328 source directory differs from build directory.
11330 2007-05-05 Robert Millan <rmh@aybabtu.com>
11332 * util/powerpc/ieee1275/grub-install.in: Fix syntax error in pkglibdir
11335 2007-05-05 Robert Millan <rmh@aybabtu.com>
11337 * util/update-grub.in: Create ${grub_prefix} if it doesn't exist.
11339 2007-05-05 Robert Millan <rmh@aybabtu.com>
11341 * util/grub.d/10_linux.in: Allow the administrator to insert Linux
11342 command-line arguments via ${GRUB_CMDLINE_LINUX}.
11344 2007-05-05 Robert Millan <rmh@aybabtu.com>
11346 * conf/i386-pc.rmk (grub_setup_SOURCES): Add partmap/gpt.c.
11347 (grub_probe_SOURCES): Likewise.
11348 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): Detect
11349 GPT and initialize dos_part and bsd_part accordingly.
11350 * util/i386/pc/grub-setup.c (setup): Ditto for install_dos_part and
11352 (main): Activate gpt module for use during partition identification,
11353 and deactivate it afterwards.
11354 * util/i386/pc/grub-install.in: Add gpt module to core.img.
11355 * util/i386/pc/grub-probe.c (main): Activate gpt module for use during
11356 partition identification, and deactivate it afterwards.
11358 2007-05-05 Robert Millan <rmh@aybabtu.com>
11360 * term/i386/pc/console.c (grub_console_fini): Call
11361 grub_term_set_current() before grub_term_unregister().
11363 2007-05-04 Robert Millan <rmh@aybabtu.com>
11365 * DISTLIST: Add util/update-grub.in, util/grub.d/00_header.in,
11366 util/grub.d/10_hurd.in, util/grub.d/10_linux.in and util/grub.d/README.
11367 * Makefile.in: Build update-grub_SCRIPTS. Install update-grub_SCRIPTS
11368 and update-grub_DATA.
11369 * conf/common.rmk: Build and install update-grub components.
11370 * conf/common.mk: Regenerate.
11371 * util/update-grub.in: New. Core of update-grub.
11372 * util/grub.d/00_header.in: New. Generates grub.cfg header.
11373 * util/grub.d/10_hurd.in: New. Generates boot entries for the Hurd.
11374 * util/grub.d/10_linux.in: New. Generates boot entries for Linux.
11375 * util/grub.d/README: New. Document grub.d directory layout.
11377 2007-05-01 Robert Millan <rmh@aybabtu.com>
11379 * util/grub-emu.c: Move initialization functions
11380 grub_util_biosdisk_init() and grub_init_all() before
11381 grub_util_biosdisk_get_grub_dev(), which relies on them.
11383 2007-04-19 Robert Millan <rmh@aybabtu.com>
11385 * util/powerpc/ieee1275/grub-install.in: Initialize ${bindir}, since
11388 2007-04-18 Jerone Young <jerone@gmail.com>
11390 * kernel/elf.c: Add missing parenthesis for conditional statement
11393 2007-04-10 Jerone Young <jerone@gmail.com>
11395 * util/i386/pc/getroot.c: Update so that if root device is /dev/root ,
11396 continue on and look for device node with real device name.
11398 2007-04-10 Jerone Young <jerone@gmail.com>
11400 * configure.ac: Add argument for autoconf to use transformation
11402 * Makefile.in: Add autoconf package transformation code.
11403 * util/i386/pc/grub-install.in: Likewise.
11404 * util/powerpc/ieee1275/grub-install.in: Likewise.
11406 2007-03-19 Yoshinori K. Okuji <okuji@enbug.org>
11408 * fs/ext2.c (EXT2_GOOD_OLD_REVISION): New macro.
11409 (EXT2_GOOD_OLD_INODE_SIZE): Likewise.
11410 (EXT2_REVISION): Likewise.
11411 (EXT2_INODE_SIZE): Likewise.
11412 (struct grub_ext2_block_group): Added a missing member
11414 (grub_ext2_read_inode): Divide by the inode size in a superblock
11415 instead of 128 to obtain INODES_PER_BLOCK.
11416 Use the macro EXT2_INODE_SIZE instead of directly using
11417 SBLOCK->INODE_SIZE.
11419 2007-03-18 Yoshinori K. Okuji <okuji@enbug.org>
11421 * fs/ext2.c (grub_ext2_read_inode): Use the inode size in a
11422 superblock instead of the structure size to compute an
11423 offset. This fixes the problem that GRUB could not read a
11424 filesystem when inode size is different from 128-byte.
11426 2007-03-05 Marco Gerards <marco@gnu.org>
11428 * normal/main.c (read_config_file): When "menu" is not set, create
11429 an initial context.
11431 2007-02-21 Hollis Blanchard <hollis@penguinppc.org>
11433 * kern/powerpc/ieee1275/init.c (HEAP_SIZE): Removed.
11434 (HEAP_LIMIT): New macro.
11435 (grub_claim_heap): Claim memory up to `heaplimit'.
11437 2007-02-21 Hollis Blanchard <hollis@penguinppc.org>
11439 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Link at 64KB.
11440 * kern/powerpc/ieee1275/init.c (_end): Add declaration.
11441 (_start): Likewise.
11442 (grub_arch_modules_addr): Return address after `_end'.
11443 * util/powerpc/ieee1275/grub-mkimage.c: Include grub/misc.h.
11444 (load_modules): Use new parameter as `p_paddr' and `p_vaddr'.
11445 (add_segments): Calculate `_end' from phdr size and location.
11446 (ALIGN_UP): Moved to ...
11447 * include/grub/misc.h: here.
11448 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
11450 (GRUB_IEEE1275_MODULE_BASE): Removed.
11452 2007-02-20 Hollis Blanchard <hollis@penguinppc.org>
11454 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Correct
11457 2007-02-20 Hollis Blanchard <hollis@penguinppc.org>
11459 * include/grub/elfload.h (grub_elf32_load_hook_t): Return grub_err_t.
11461 (grub_elf64_load_hook_t): Likewise.
11462 * kern/elf.c: Call `grub_error_push' before `grub_error'. Improve
11465 2007-02-20 Hollis Blanchard <hollis@penguinppc.org>
11467 * kern/mm.c: Update copyright.
11468 (grub_mm_debug): Correct syntax error.
11469 (grub_mm_dump_free): New function.
11470 (grub_debug_free): Call `grub_free'.
11471 * include/grub/mm.h: Update copyright.
11472 (grub_mm_dump_free): Add declaration.
11474 2007-02-12 Hollis Blanchard <hollis@penguinppc.org>
11476 * include/grub/ieee1275/ieee1275.h: Update copyright.
11477 * kern/powerpc/ieee1275/init.c: Likewise.
11478 * kern/powerpc/ieee1275/openfw.c: Likewise.
11480 * loader/powerpc/ieee1275/linux.c: Likewise.
11481 * include/grub/elfload.h: Likewise.
11482 * kern/elf.c: Likewise.
11483 (grub_elf32_load): Pass `base' and `size' parameters. Update all
11485 (grub_elf64_load): Likewise.
11486 (grub_elf32_load_segment): Move to a nested function.
11487 (grub_elf64_load_segment): Likewise.
11489 2007-02-12 Hollis Blanchard <hollis@penguinppc.org>
11491 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): New
11493 * kern/powerpc/ieee1275/init.c (grub_heap_start): Removed.
11494 (grub_heap_len): Likewise.
11495 (HEAP_SIZE): New macro.
11496 (grub_claim_heap): New function.
11497 (grub_machine_init): Don't claim heap directly. Call
11499 * kern/powerpc/ieee1275/openfw.c: Include alloca.h.
11500 (grub_available_iterate): New function.
11502 2007-02-03 Thomas Schwinge <tschwinge@gnu.org>
11504 * aclocal.m4 (grub_CHECK_STACK_PROTECTOR): New definition.
11505 * configure.ac: Use it for testing the HOST and TARGET compilers.
11507 2006-12-13 Thomas Schwinge <tschwinge@gnu.org>
11509 * Makefile.in (enable_grub_emu): New variable.
11510 * configure.ac (--enable-grub-emu): New option.
11511 Do the checks for (n)curses only if `--enable-grub-emu' is requested.
11512 * conf/i386-efi.rmk (sbin_UTILITIES): Add `grub-emu' only if requested.
11513 * conf/i386-pc.rmk: Likewise.
11514 * conf/powerpc-ieee1275.rmk: Likewise.
11515 * conf/sparc64-ieee1275.rmk (bin_UTILITIES): Likewise.
11517 2006-12-12 Marco Gerards <marco@gnu.org>
11519 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_MENU'.
11521 * kern/env.c (grub_env_unset): Don't free the member `value' when
11522 the type is GRUB_ENV_VAR_DATA, in this case it's a user defined
11525 * normal/main.c (current_menu): Removed.
11526 (free_menu): Unset the `menu' environment variable.
11527 (grub_normal_menu_addentry): Make use of the environment variable
11528 `menu', instead of using the global `current_menu'. Allocate
11529 memory for the sourcecode of this entry.
11530 (read_config_file): New argument `nested', changed all callers.
11531 Only in the case of a new context, initialize a new menu. Set the
11532 `menu' environment variable.
11533 (grub_normal_execute): Don't set and unset the environment
11534 variable `menu' here anymore. Only free the menu when leaving the
11537 * util/i386/pc/biosdisk.c (linux_find_partition): Fixed a memory
11540 2006-12-11 Marco Gerards <marco@gnu.org>
11542 * normal/menu_entry.c (run): Fix off by one bug so the last line
11543 is executed. Move the loader check to outside the loop.
11545 2006-12-08 Hollis Blanchard <hollis@penguinppc.org>
11547 * kern/powerpc/ieee1275/cmain.c (cmain): Mark r3 and r4 as `UNUSED'.
11549 2006-11-25 Yoshinori K. Okuji <okuji@enbug.org>
11551 * util/i386/pc/grub-mkimage.c (generate_image): Fix the offset of
11552 the number of sectors. Reported by Andrey Shuvikov
11553 <mr_hyro@yahoo.com>.
11555 2006-11-11 Jeroen Dekkers <jeroen@dekkers.cx>
11557 * kern/disk.c (grub_disk_read): When there is a read error, always
11558 try to read only the necessary data.
11560 * conf/i386-pc.rmk (grub_probe_SOURCES): Add disk/lvm.c and
11562 * include/grub/disk.h [GRUB_UTIL] (grub_raid_init): New
11564 [GRUB_UTIL] (grub_raid_fini): Likewise.
11565 [GRUB_UTIL] (grub_lvm_init): Likewise.
11566 [GRUB_UTIL] (grub_lvm_fini): Likewise.
11567 * util/i386/pc/grub-probe.c (probe): Check whether DEVICE_NAME is
11568 RAID device and copy DEVICE_NAME to DRIVE_NAME in that case.
11569 (main): Call grub_raid_init(), grub_lvm_init(), grub_lvm_fini()
11570 and grub_raid_fini().
11572 2006-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
11574 * include/grub/types.h (__unused): Rename to UNUSED.
11575 * kern/elf.c (grub_elf32_size): Use UNUSED instead of __unused.
11576 (grub_elf64_size): Likewise.
11578 2006-11-03 Hollis Blanchard <hollis@penguinppc.org>
11580 * kern/elf.c (grub_elf_file): Call grub_file_seek. Call
11581 grub_error_push and grub_error_pop in the error-handling path.
11582 (grub_elf32_load_segment): Only call grub_file_read with non-zero
11585 2006-11-03 Hollis Blanchard <hollis@penguinppc.org>
11587 * conf/i386-efi.rmk (grub_emu_SOURCES): Add kern/elf.c.
11588 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
11589 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11590 (kernel_elf_SOURCES): Likewise.
11591 * conf/i386-efi.rmk (kernel_mod_HEADERS): Add elfload.h and cache.h.
11592 * conf/i386-pc.rmk (kernel_mod_HEADERS): Likewise.
11593 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
11594 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
11595 * conf/common.rmk (pkgdata_MODULES): Add elf.mod.
11596 (elf_mod_SOURCES): New variable.
11597 (elf_mod_CFLAGS): Likewise.
11598 (elf_mod_LDFLAGS): Likewise.
11599 * include/grub/types.h (__unused): New macro.
11600 * include/grub/elfload.h: New file.
11601 * kern/elf.c: Likewise.
11602 * loader/powerpc/ieee1275/linux.c: Include elfload.h.
11603 (ELF32_LOADMASK): New macro.
11604 (ELF64_LOADMASK): Likewise.
11605 (vmlinux): Removed.
11606 (grub_linux_load32): New function.
11607 (grub_linux_load64): Likewise.
11608 (grub_rescue_cmd_linux): Call grub_linux_load32 or grub_linux_load64.
11609 Use grub_elf_t instead of grub_file_t.
11611 2006-11-02 Hollis Blanchard <hollis@penguinppc.org>
11613 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): Add
11614 `catch_result' to struct set_color_args.
11616 2006-10-28 Yoshinori K. Okuji <okuji@enbug.org>
11618 * normal/menu.c: Include grub/script.h.
11619 * normal/menu_entry.c: Likewise.
11620 * include/grub/normal.h: Do not include grub/script.h.
11622 2006-10-27 Hollis Blanchard <hollis@penguinppc.org>
11624 * kern/disk.c (grub_disk_read): Correct debug printf formatting.
11626 2006-10-27 Hollis Blanchard <hollis@penguinppc.org>
11628 * kern/disk.c (grub_disk_open): Print debug messages when opening a
11630 (grub_disk_close): Print debug messages when closing a disk.
11631 (grub_disk_read): Print debug messages when disk read fails.
11632 * kern/fs.c (grub_fs_probe): Print debug messages when detecting
11634 * kern/partition.c: Include misc.h.
11635 (grub_partition_iterate): Print debug messages when detecting
11638 2006-10-27 Hollis Blanchard <hollis@penguinppc.org>
11640 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Return error if `status'
11642 * kern/ieee1275/ieee1275.c (IEEE1275_IHANDLE_INVALID): Change to 0.
11644 2006-10-26 Hollis Blanchard <hollis@penguinppc.org>
11646 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
11647 Reverse GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS test.
11649 2006-10-25 Jeroen Dekkers <jeroen@dekkers.cx>
11651 * disk/lvm.c (grub_lvm_scan_device): Malloc sizeof(*lv) bytes
11652 instead of sizeof(lv). Patch by Michael Guntsche.
11654 2006-10-18 Jeroen Dekkers <jeroen@dekkers.cx>
11656 * disk/lvm.c: Rename VGS to VG_LIST.
11657 (grub_lvm_iterate): Change VGS->LV to VG-LV.
11658 (grub_lvm_open): Likewise.
11659 Thanks to Michael Guntsche for finding this bug.
11661 2006-10-15 Yoshinori K. Okuji <okuji@enbug.org>
11663 * configure.ac (AC_INIT): Bumped to 1.95.
11665 2006-10-14 Robert Millan <rmh@aybabtu.com>
11667 * util/i386/pc/getroot.c (grub_guess_root_device): Don't compare os_dev
11668 with "/dev/.static/dev/md".
11670 2006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
11672 * util/i386/pc/grub-probe.c (probe): Print DEVICE_NAME instead of
11673 DRIVE_NAME when grub_util_biosdisk_get_grub_dev fails. Open
11674 DRIVE_NAME instead of DEVICE_NAME. Make sure that DEVICE_NAME and
11675 DRIVE_NAME are always freed.
11677 * util/i386/pc/biosdisk.c (make_device_name): Add one into
11678 DOS_PART, as a DOS partition is counted from one instead of zero
11679 now. Reported by Robert Millan.
11681 2006-10-14 Robert Millan <rmh@aybabtu.com>
11683 * util/i386/pc/getroot.c (grub_guess_root_device): Stop using
11684 grub_util_biosdisk_get_grub_dev to convert system device to GRUB device.
11685 * util/grub-emu.c (main): Use grub_util_biosdisk_get_grub_dev with the
11686 string returned by grub_guess_root_device.
11687 * util/i386/pc/grub-setup.c: Likewise.
11688 * util/i386/pc/grub-probefs.c: Likewise.
11690 * util/i386/pc/grub-probefs.c: Rename to ...
11691 * util/i386/pc/grub-probe.c: ... this.
11692 * DISTLIST: Remove grub-probefs, add grub-probe.
11693 * conf/i386-efi.rmk: Likewise.
11694 * conf/i386-pc.rmk: Likewise.
11695 * util/i386/pc/grub-install.in: Likewise.
11697 * util/i386/pc/grub-probe.c: Add --target=(fs|device|drive) option to
11698 choose which information we want to print.
11700 2006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
11702 * DISTLIST: Added commands/echo.c, disk/lvm.c, disk/raid.c,
11703 include/grub/bitmap.h, include/grub/lvm.h, include/grub/raid.h,
11704 include/grub/i386/pc/vbeutil.h, include/grub/util/lvm.h,
11705 include/grub/util/raid.h, util/lvm.c, util/raid.c, video/bitmap.c,
11706 video/readers/tga.c and video/i386/pc/vbeutil.c.
11708 2006-10-14 Jeroen Dekkers <jeroen@dekkers.cx>
11710 Added support for RAID and LVM.
11712 * disk/lvm.c: New file.
11713 * disk/raid.c: Likewise.
11714 * include/grub/lvm.h: Likewise.
11715 * include/grub/raid.h: Likewise.
11716 * include/grub/util/lvm.h: Likewise.
11717 * include/grub/util/raid.h: Likewise.
11718 * util/lvm.c: Likewise.
11719 * util/raid.c: Likewise.
11721 * include/grub/disk.h (grub_disk_dev_id): Add
11722 GRUB_DISK_DEVICE_RAID_ID and GRUB_DISK_DEVICE_LVM_ID.
11723 (grub_disk_get_size): New prototype.
11724 * kern/disk.c (grub_disk_open): Check whether grub_partition_probe()
11725 returns a partition.
11726 (grub_disk_get_size): New function.
11728 * kern/i386/pc/init.c (make_install_device): Copy the prefix
11729 verbatim if grub_install_dos_part is -2.
11731 * util/i386/pc/getroot.c (grub_guess_root_device): Support RAID
11734 * util/i386/pc/grub-setup.c (setup): New argument
11735 MUST_EMBED. Force embedding of GRUB when the argument is
11736 true. Close FILE before returning.
11737 (main): Add support for RAID and LVM.
11739 * conf/common.rmk: Add RAID and LVM modules.
11740 * conf/i386-pc.rmk (grub_setup_SOURCES): Add util/raid.c and
11742 (grub_emu_SOURCES): Add disk/raid.c and disk/lvm.c.
11744 * kern/misc.c (grub_strstr): New function.
11745 * include/grub/misc.h (grub_strstr): New prototype.
11747 2006-10-10 Tristan Gingold <tristan.gingold@bull.net>
11749 * include/grub/efi/api.h (GRUB_EFI_ERROR_CODE): Long constant.
11751 2006-10-05 Tristan Gingold <tristan.gingold@bull.net>
11753 * kern/misc.c (grub_strtoull): Guess the base only if not
11756 2006-10-01 Hollis Blanchard <hollis@penguinppc.org>
11758 * kern/powerpc/ieee1275/cmain.c (cmain): Remove incomplete Old World
11761 2006-10-01 Hollis Blanchard <hollis@penguinppc.org>
11763 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Cast `size' to long.
11765 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_next_property):
11766 Remove `flags' argument. All callers changed.
11767 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_ROOT): Removed.
11768 (IEEE1275_IHANDLE_INVALID): New variable.
11769 (IEEE1275_CELL_INVALID): New variable.
11770 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
11771 grub_ieee1275_get_property_length, grub_ieee1275_instance_to_package,
11772 grub_ieee1275_package_to_path, grub_ieee1275_instance_to_path,
11773 grub_ieee1275_peer, grub_ieee1275_child, grub_ieee1275_open,
11774 grub_ieee1275_claim, grub_ieee1275_set_property): Error-check return
11775 codes from Open Firmware. All callers updated.
11776 (grub_ieee1275_next_property): Directly return Open Firmware return
11778 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
11779 Standardize error checking from `grub_ieee1275_get_property'.
11780 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Rename
11781 `devalias' to `aliases'. Correct comments. Consolidate error paths.
11783 2006-10-01 Hollis Blanchard <hollis@penguinppc.org>
11785 * kern/ieee1275/ieee1275.c (grub_ieee1275_instance_to_path): Rename
11786 `instance_to_package_args' to `instance_to_path_args'.
11788 * kern/powerpc/ieee1275/init.c (grub_machine_init): Use
11789 `grub_ieee1275_chosen'.
11791 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Call
11792 `grub_ieee1275_interpret'.
11794 2006-09-25 Hollis Blanchard <hollis@penguinppc.org>
11796 * util/powerpc/ieee1275/grub-mkimage.c: Include config.h.
11798 2006-09-25 Hollis Blanchard <hollis@penguinppc.org>
11800 * include/grub/powerpc/libgcc.h (__floatdisf): New prototype.
11801 (__cmpdi): Likewise.
11803 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Pass 0 as
11804 `flags' to `grub_ieee1275_next_property'. Change `pathlen' to type
11807 * kern/powerpc/ieee1275/cmain.c: Include grub/misc.h.
11809 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Change `actual'
11810 to type `grub_ssize_t'.
11811 (grub_rescue_cmd_linux): Cast -1 to `grub_off_t'.
11813 2006-09-22 Marco Gerards <marco@gnu.org>
11815 * normal/script.c (grub_script_create_cmdmenu): Skip leading
11818 2006-09-22 Marco Gerards <marco@gnu.org>
11820 * commands/echo.c: New file.
11822 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/echo.c'.
11824 * conf/common.rmk (echo_mod_SOURCES): New variable.
11825 (echo_mod_CFLAGS): Likewise.
11826 (echo_mod_LDFLAGS): Likewise.
11828 2006-09-22 Marco Gerards <marco@gnu.org>
11830 * normal/main.c (get_line): Malloc memory instead of using
11831 preallocated memory. Removed the arguments `cmdline' and
11832 `max_len'. Updated all callers.
11834 2006-09-22 Marco Gerards <marco@gnu.org>
11836 * conf/i386-efi.rmk (grub_emu_DEPENDENCIES): New variable.
11837 (normal_mod_DEPENDENCIES): Likewise.
11839 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Likewise.
11840 (normal_mod_DEPENDENCIES): Likewise.
11842 * conf/sparc64-ieee1275.rmk (normal_mod_DEPENDENCIES): Likewise.
11844 2006-09-22 Johan Rydberg <jrydberg@gnu.org>
11846 * genmk.rb: Add DEPENDENCIES variables to modules, utilities, and
11848 * conf/i386-pc.rmk (grub_emu_DEPENDENCIES): Declare.
11849 (normal_mod_DEPENDENCIES): Likewise.
11850 * conf/i386-pc.mk: Regenerate.
11851 * conf/i386-efi.mk: Likewise
11852 * conf/common.mk: Likewise.
11853 * conf/powerpc-ieee1275.mk: Likewise.
11854 * conf/sparc64-ieee1275.mk: Likewise.
11856 2006-09-22 Robert Millan <rmh@aybabtu.com>
11858 Sync with i386 version.
11859 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Remove grub-emu, add grub-mkimage.
11860 * conf/powerpc-ieee1275.rmk (sbin_UTILITIES): Remove grub-mkimage, add grub-emu.
11862 2006-09-21 Robert Millan <rmh@aybabtu.com>
11864 Import from GRUB Legacy (lib/device.c):
11865 * util/i386/pc/grub-mkdevicemap.c (get_i2o_disk_name): New function.
11866 (init_device_map) [__linux__]: Add support for I2O devices.
11868 2006-09-14 Marco Gerards <marco@gnu.org>
11870 * conf/i386-pc.rmk (COMMON_LDFLAGS): Use `-m32' instead of
11873 2006-09-14 Robert Millan <rmh@aybabtu.com>
11875 * util/i386/pc/grub-install.in: Skip menu.lst when removing
11878 * util/i386/pc/getroot.c: Don't recurse into dotdirs (e.g. ".static").
11880 * util/i386/pc/grub-mkdevicemap.c: Make sure the floppy device exists
11881 before adding it to device.map.
11883 2006-08-15 Johan Rydberg <jrydberg@gnu.org>
11885 * genmk.rb: Let GCC generate dependencies the first time it
11886 compiles a file; using the -MD option.
11887 * conf/common.mk: Regenerate.
11888 * conf/i386-pc.mk: Likewise.
11889 * conf/i386-efi.mk: Likewise.
11890 * conf/powerpc-ieee1275.mk: Likewise.
11891 * conf/sparc64-ieee1275.mk: Likewise.
11893 2006-08-04 Yoshinori K. Okuji <okuji@enbug.org>
11895 Move the prototypes of grub_setjmp and grub_longjmp to
11896 cpu/setjmp.h, so that each architecture may specify different
11899 * include/grub/i386/setjmp.h (grub_setjmp): New prototype.
11900 (grub_longjmp): Likewise.
11901 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise..
11902 (grub_longjmp): Likewise.
11903 * include/grub/sparc64/setjmp.h (grub_setjmp): Likewise..
11904 (grub_longjmp): Likewise.
11906 * include/grub/setjmp.h [!GRUB_UTIL] (grub_setjmp): Removed.
11907 [!GRUB_UTIL] (grub_longjmp): Removed.
11909 2006-08-01 Pelletier Vincent <subdino2004@yahoo.fr>
11911 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): IEEE1275
11912 "color!" method does not return any value.
11914 2006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
11916 * include/grub/bitmap.h: New file.
11918 * include/grub/i386/pc/vbeutil.h: Likewise.
11920 * video/bitmap.c: Likewise.
11922 * video/readers/tga.c: Likewise.
11924 * video/i386/pc/vbeutil.c: Likewise.
11926 * commands/videotest.c: Code cleanup and updated to reflect to new
11929 * term/gfxterm.c: Likewise.
11931 * video/video.c: Likewise.
11933 * conf/i386-pc.rmk (pkgdata_MODULES): Added tga.mod and bitmap.mod.
11934 (vbe_mod_SOURCES): Added video/i386/pc/vbeutil.c.
11935 (bitmap_mod_SOURCES): New entry.
11936 (bitmap_mod_CFLAGS): Likewise.
11937 (bitmap_mod_LDFLAGS): Likewise.
11938 (tga_mod_SOURCES): Likewise.
11939 (tga_mod_CFLAGS): Likewise.
11940 (tga_mod_LDFLAGS): Likewise.
11942 * include/grub/video.h (grub_video_blit_operators): New enum type.
11943 (grub_video_render_target): Changed as forward declaration and moved
11944 actual definition to be video driver specific.
11945 (grub_video_adapter.blit_bitmap): Added blitting operator.
11946 (grub_video_adapter.blit_render_target): Likewise.
11947 (grub_video_blit_bitmap): Likewise.
11948 (grub_video_blit_render_target): Likewise.
11950 * include/grub/i386/pc/vbe.h (grub_video_render_target): Added
11951 driver specific render target definition.
11952 (grub_video_vbe_map_rgba): Added driver internal helper.
11953 (grub_video_vbe_unmap_color): Updated to use
11954 grub_video_i386_vbeblit_info.
11955 (grub_video_vbe_get_video_ptr): Likewise.
11957 * include/grub/i386/pc/vbeblit.h
11958 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8): Updated to use
11959 grub_video_i386_vbeblit_info.
11960 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
11961 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
11962 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
11963 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
11964 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
11965 (grub_video_i386_vbeblit_index_index): Likewise.
11966 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): New blitter function.
11967 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
11968 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
11969 (grub_video_i386_vbeblit_blend): Added generic blitter for blend
11971 (grub_video_i386_vbeblit_replace): Added generic blitter for replace
11974 * video/i386/pc/vbeblit.c: Updated to reflect changes on
11975 include/grub/i386/pc/vbeblit.h.
11977 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8):
11978 Updated to use grub_video_i386_vbeblit_info.
11979 (grub_video_i386_vbefill_R8G8B8): Likewise.
11980 (grub_video_i386_vbefill_index): Likewise.
11981 (grub_video_i386_vbefill): Added generic filler.
11983 * video/i386/pc/vbefill.c: Updated to reflect changes on
11984 include/grub/i386/pc/vbefill.h.
11986 * video/i386/pc/vbe.c (grub_video_vbe_get_video_ptr): Updated to use
11987 grub_video_i386_vbeblit_info.
11988 (grub_video_vbe_unmap_color): Likewise.
11989 (grub_video_vbe_blit_glyph): Likewise.
11990 (grub_video_vbe_scroll): Likewise.
11991 (grub_video_vbe_draw_pixel): Removed function.
11992 (grub_video_vbe_get_pixel): Likewise.
11993 (grub_video_vbe_fill_rect): Moved all blitters to vbefill.c and
11994 updated code to use it.
11995 (common_blitter): Added common blitter for render target and bitmap.
11996 (grub_video_vbe_blit_bitmap): Updated to use common_blitter.
11997 (grub_video_vbe_blit_render_target): Likewise.
11999 2006-07-30 Johan Rydberg <jrydberg@gnu.org>
12001 * kern/efi/efi.c (grub_efi_set_text_mode): Assume console already
12002 is in text mode if there is no console control protocol instance
12005 2006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
12007 * include/grub/video.h: Code cleanup.
12009 * include/grub/i386/pc/vbe.h: Likewise.
12011 * video/i386/pc/vbe.c: Likewise.
12013 * video/i386/pc/vbeblit.c: Likewise.
12015 * video/i386/pc/vbefill.c: Likewise.
12017 * video/video.c: Likewise. Also added more comments.
12019 2006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
12021 * disk/i386/pc/biosdisk.c (struct grub_biosdisk_drp): Moved to ...
12022 (struct grub_biosdisk_dap): Likewise.
12024 * include/grub/i386/pc/biosdisk.h: ... to here. Also corrected
12025 linkage settings for all functions.
12027 2006-07-12 Marco Gerards <marco@gnu.org>
12029 * configure.ac (--enable-mm-debug): Fix typo.
12031 * genkernsyms.sh.in: Use proper quoting for `CC'.
12033 2006-07-02 Jeroen Dekkers <jeroen@dekkers.cx>
12035 * conf/i386-pc.rmk (COMMON_ASFLAGS): Add "-m32".
12036 (normal_mod_ASFLAGS): Remove "-m32".
12038 2006-06-14 Yoshinori K. Okuji <okuji@enbug.org>
12040 * util/misc.c: Include config.h.
12041 [!HAVE_MEMALIGN]: Do not include malloc.h.
12042 (grub_memalign): Use posix_memalign, if present. Then, use
12043 memalign, if present. Otherwise, emit an error.
12045 * util/grub-emu.c: Do not include malloc.h.
12047 * include/grub/util/misc.h: Include unistd.h. This is required for
12048 FreeBSD, because off_t is defined in unistd.h. Reported by Harley
12049 D. Eades III <hde@foobar-qux.org>.
12051 * configure.ac (AC_GNU_SOURCE): Added.
12052 (AC_CHECK_FUNCS): Check posix_memalign and memalign for the host
12055 2006-06-09 Yoshinori K. Okuji <okuji@enbug.org>
12057 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Make sure that
12058 ADDR_MAX does not exceed GRUB_LINUX_INITRD_MAX_ADDRESS.
12060 2006-06-07 Jeroen Dekkers <jeroen@dekkers.cx>
12062 * include/grub/types.h (grub_host_addr_t): Rename to
12063 grub_target_addr_t.
12064 (grub_host_off_t): Rename to grub_target_off_t.
12065 (grub_host_size_t): Rename to grub_target_size_t.
12066 (grub_host_ssize_t): Rename to grub_target_ssize_t.
12067 Refer to GRUB_TARGET_SIZEOF_VOID_P to define those variables.
12069 * include/grub/kernel.h (struct grub_module_header): Change type
12070 of OFFSET to grub_target_off_t and type of SIZE to grub_target_size_t.
12071 (grub_module_info): Likewise.
12073 2006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
12075 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): The conditional
12076 of checking LINUX_MEM_SIZE was reverse. Reported by Jesus
12077 Velazquez <jesus.velazquez@gmail.com>.
12079 2006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
12081 Count partitions from 1 instead of 0 in the string representation
12082 of partitions. Still use 0-based internally.
12084 * partmap/sun.c (grub_sun_is_valid): A cosmetic change.
12085 (sun_partition_map_iterate): Use grub_partition_t instead of
12086 struct grub_partition *. Cast DESC->START_CYLINDER to
12087 grub_uint64_t after converting the endian.
12088 (sun_partition_map_probe): Subtract 1 for PARTNUM.
12089 (sun_partition_map_get_name): Add 1 to P->INDEX.
12091 * partmap/pc.c (grub_partition_parse): Subtract 1 for
12093 (pc_partition_map_get_name): Add 1 into PCDATA->DOS_PART.
12095 * partmap/gpt.c (gpt_partition_map_iterate): Initialize PARTNO to
12096 zero instead of one.
12097 (gpt_partition_map_probe): Subtract 1 for PARTNUM.
12098 (gpt_partition_map_get_name): Add 1 into P->INDEX.
12100 * partmap/apple.c (apple_partition_map_iterate): Change the type
12101 of POS to unsigned.
12102 (apple_partition_map_probe): Subtract 1 for PARTNUM.
12103 (apple_partition_map_get_name): Add 1 into P->INDEX.
12105 * partmap/amiga.c (amiga_partition_map_iterate): Change the type
12106 of POS to unsigned.
12107 (amiga_partition_map_iterate): Cast NEXT to grub_off_t to
12108 calculate the offset of a partition.
12109 (amiga_partition_map_probe): Subtract 1 for PARTNUM.
12110 (amiga_partition_map_get_name): Add 1 into P->INDEX.
12112 * partmap/acorn.c (acorn_partition_map_find): Change the type of
12113 SECTOR to grub_disk_addr_t.
12114 (acorn_partition_map_iterate): Likewise.
12115 (acorn_partition_map_probe): Subtract 1 for PARTNUM.
12116 Change the type of SECTOR to grub_disk_addr_t. Declare P on the
12118 (acorn_partition_map_get_name): Add 1 into P->INDEX.
12120 * kern/i386/pc/init.c (make_install_device): Add 1 into
12121 GRUB_INSTALL_DOS_PART.
12123 * fs/iso9660.c (grub_iso9660_mount): Fixed a reversed
12126 2006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
12128 Clean up the code to support 64-bit addressing in disks and
12129 files. This change is not enough for filesystems yet.
12131 * util/i386/pc/grub-setup.c (struct boot_blocklist): Change the
12132 type of "start" to grub_uint64_t.
12133 (setup): Change the types of KERNEL_SECTOR and FIRST_SECTOR to
12134 grub_disk_addr_t * and grub_disk_addr_t. Fix the format string in
12135 save_first_sector and save_blocklists. Use grub_le_to_cpu64 to
12138 * util/i386/pc/biosdisk.c (open_device): Change the type of SECTOR
12139 to grub_disk_addr_t.
12141 * partmap/gpt.c (gpt_partition_map_iterate): Fix the format
12144 * partmap/pc.c (pc_partition_map_iterate): Likewise.
12146 * partmap/amiga.c (amiga_partition_map_iterate): Cast RDSK.MAGIC
12149 * normal/script.c (grub_script_parse): Remove unused MEMFREE.
12151 * normal/parser.y (YYLTYPE_IS_TRIVIAL): New macro.
12153 * normal/lexer.c (grub_script_yyerror): Specify unused to LEX.
12155 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf64): Cast -1
12156 to grub_off_t, to detect an error from grub_file_seek.
12157 (grub_multiboot_load_elf32): Likewise.
12159 * kern/misc.c (grub_strtoul): Use grub_strtoull. Return the
12160 maximum unsigned long value when an overflow is detected.
12161 (grub_strtoull): New function.
12162 (grub_divmod64): Likewise.
12163 (grub_lltoa): use grub_divmod64.
12165 * kern/fs.c (struct grub_fs_block): Change the type of "offset" to
12167 (grub_fs_blocklist_open): Increase P if P is not NULL to advance
12168 the pointer to next character. Use grub_strtoull instead of
12170 (grub_fs_blocklist_read): Change the types of SECTOR, OFFSET and
12171 SIZE to grub_disk_addr_t, grub_off_t and grub_size_t,
12174 * kern/file.c (grub_file_read): Prevent an overflow of LEN, as the
12175 return value is signed.
12176 (grub_file_seek): Change the type of OLD to grub_off_t. Do not
12177 test if OFFSET is less than zero, as OFFSET is unsigned now.
12179 * kern/disk.c (struct grub_disk_cache): Change the type of
12180 "sector" to grub_disk_addr_t.
12181 (grub_disk_cache_get_index): Change the type of SECTOR to
12182 grub_disk_addr_t. Calculate the hash with SECTOR casted to
12183 unsigned after shifting.
12184 (grub_disk_cache_invalidate): Change the type of SECTOR to
12186 (grub_disk_cache_unlock): Likewise.
12187 (grub_disk_cache_store): Likewise.
12188 (grub_disk_check_range): Change the types of SECTOR, OFFSET, SIZE,
12189 START and LEN to grub_disk_addr_t *, grub_off_t *, grub_size_t,
12190 grub_disk_addr_t and grub_uint64_t, respectively.
12191 (grub_disk_read): Use an unsigned variable REAL_OFFSET for the
12192 body, as the value of OFFSET is tweaked by
12193 grub_disk_check_range. Change the types of START_SECTOR, LEN and
12194 POS to grub_disk_addr_t, grub_size_t and grub_size_t,
12196 (grub_disk_write): Use an unsigned variable REAL_OFFSET for the
12197 body, as the value of OFFSET is tweaked by
12198 grub_disk_check_range. Change the types of LEN and N to
12201 * io/gzio.c (struct grub_gzio): Change the types of "data_offset"
12202 and "saved_offset" to grub_off_t.
12203 (test_header): Cast BUF to char *.
12204 (get_byte): Cast GZIO->DATA_OFFSET to grub_off_t. Cast GZIO->INBUF
12206 (grub_gzio_read): Change the types of OFFSET and SIZE to
12207 grub_off_t and grub_size_t, respectively.
12209 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_FORCE_LBA):
12211 (GRUB_BOOT_MACHINE_BOOT_DRIVE): Changed to 0x4c.
12212 (GRUB_BOOT_MACHINE_KERNEL_ADDRESS): Changed to 0x40.
12213 (GRUB_BOOT_MACHINE_KERNEL_SEGMENT): Changed to 0x42.
12214 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Changed to 0x4e.
12215 (GRUB_BOOT_MACHINE_LIST_SIZE): Increased to 12.
12217 * include/grub/types.h (grub_off_t): Unconditionally set to
12219 (grub_disk_addr_t): Changed to grub_uint64_t.
12221 * include/grub/partition.h (struct grub_partition): Change the
12222 types of "start", "len" and "offset" to grub_disk_addr_t,
12223 grub_uint64_t and grub_disk_addr_t, respectively.
12224 (grub_partition_get_start): Return grub_disk_addr_t.
12225 (grub_partition_get_len): Return grub_uint64_t.
12227 * include/grub/misc.h (grub_strtoull): New prototype.
12228 (grub_divmod64): Likewise.
12230 * include/grub/fshelp.h (grub_fshelp_read_file): Change the types
12231 of SECTOR, LEN and FILESIZE to grub_disk_addr_t, grub_size_t and
12232 grub_off_t, respectively.
12233 All callers and references changed.
12235 * include/grub/fs.h (struct grub_fs): Change the type of LEN to
12236 grub_size_t in "read".
12237 All callers and references changed.
12239 * include/grub/file.h (struct grub_file): Change the types of
12240 "offset" and "size" to grub_off_t and grub_off_t,
12241 respectively. Change the type of SECTOR to grub_disk_addr_t in
12243 (grub_file_read): Change the type of LEN to grub_size_t.
12244 (grub_file_seek): Return grub_off_t. Change the type of OFFSET to
12246 (grub_file_size): Return grub_off_t.
12247 (grub_file_tell): Likewise.
12248 All callers and references changed.
12250 * include/grub/disk.h (struct grub_disk_dev): Change the types of
12251 SECTOR and SIZE to grub_disk_addr_t and grub_size_t in "read" and
12253 (struct grub_disk): Change the type of "total_sectors" to
12254 grub_uint64_t. Change the type of SECTOR to grub_disk_addr_t in
12256 (grub_disk_read): Change the types of SECTOR, OFFSET and SIZE to
12257 grub_disk_addr_t, grub_off_t and grub_size_t, respectively.
12258 (grub_disk_write): Likewise.
12259 All callers and references changed.
12261 * fs/iso9660.c (grub_iso9660_susp_iterate): Cast parameters to
12262 char * for grub_strncmp to silence gcc.
12263 (grub_iso9660_mount): Likewise.
12264 (grub_iso9660_mount): Likewise.
12265 (grub_iso9660_read_symlink): Likewise. Also, remove the nonsense
12267 (grub_iso9660_iterate_dir): Likewise.
12268 (grub_iso9660_label): Cast DATA->VOLDESC.VOLNAME to char *.
12270 * fs/hfs.c (grub_hfs_read_file): Change the types of SECTOR and
12271 LEN to grub_disk_addr_t and grub_size_t, respectively.
12273 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
12275 * fs/jfs.c (grub_jfs_read_file): Likewise.
12277 * fs/minix.c (grub_jfs_read_file): Likewise.
12279 * fs/sfs.c (grub_jfs_read_file): Likewise.
12281 * fs/ufs.c (grub_jfs_read_file): Likewise.
12283 * fs/xfs.c (grub_jfs_read_file): Likewise.
12285 * fs/fat.c (grub_fat_read_data): Change the types of SECTOR, LEN
12286 and SIZE to grub_disk_addr_t, grub_size_t and grub_size_t,
12289 * fs/ext2.c (grub_ext2_read_block): When an error happens, set
12290 BLKNR to -1 instead of returning GRUB_ERRNO.
12291 (grub_ext2_read_file): Change the types of SECTOR and
12292 LEN to grub_disk_addr_t and grub_size_t, respectively.
12294 * fs/affs.c (grub_affs_read_file): Change the types of SECTOR and
12295 LEN to grub_disk_addr_t and grub_size_t, respectively.
12297 * font/manager.c (grub_font_get_glyph): Cast BITMAP to char * for
12300 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Fix the format
12301 string. Do not cast SECTOR explicitly.
12303 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): Change the type of
12304 TOTAL_SECTORS to grub_uint64_t. Do not mask DRP->TOTAL_SECTORS.
12305 (grub_biosdisk_rw): Change the types of SECTOR and SIZE to
12306 grub_disk_addr_t and grub_size_t, respectively. If the sector is
12307 over 2TB and LBA mode is not supported, raise an error.
12308 (get_safe_sectors): New function.
12309 (grub_biosdisk_read): Use get_safe_sectors.
12310 (grub_biosdisk_write): Likewise.
12312 * disk/efi/efidisk.c (grub_efidisk_read): Fix the format string.
12313 (grub_efidisk_write): Likewise.
12315 * disk/loopback.c (delete_loopback): Cosmetic changes.
12316 (grub_cmd_loopback): Likewise. Also, test NEWDEV->FILENAME
12318 (grub_loopback_open): Likewise.
12319 (grub_loopback_read): Likewise. Also, change the type of POS to
12320 grub_off_t, and fix the usage of grub_memset.
12322 * commands/i386/pc/play.c: Include grub/machine/time.h.
12324 * commands/ls.c (grub_ls_list_files): Use "llu" instead of "d" to
12327 * commands/configfile.c: Include grub/env.h.
12329 * commands/cmp.c (grub_cmd_cmp): Do not use ERR, but use
12330 GRUB_ERRNO directly instead. Change the type of POS to
12331 grub_off_t. Follow the coding standard.
12333 * commands/blocklist.c: Include grub/partition.h.
12334 (grub_cmd_blocklist): Return an error if the underlying device is
12335 not a disk. Take the starting sector of a partition into account,
12336 if a partition is used.
12338 * boot/i386/pc/diskboot.S (bootloop): Adapted to the new offset of
12340 (lba_mode): Support 64-bit addresses.
12341 (chs_mode): Likewise.
12342 (copy_buffer): Adapted to the new offsets of a length field and a
12344 (blocklist_default_start): Allocate 64-bit space.
12346 * boot/i386/pc/boot.S (force_lba): Removed.
12347 (boot_drive): Moved to under KERNEL_SECTOR.
12348 (kernel_sector): Moved to under KERNEL_SEGMENT. Allocate 64-bit
12350 (real_start): Set %si earlier. Remove code for FORCE_LBA, since it
12352 (lba_mode): Refactored to support a 64-bit address. More size
12354 (setup_sectors): Likewise.
12356 2006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
12358 * DISTLIST: Added include/grub/i386/linux.h. Removed
12359 include/grub/i386/pc/linux.h
12361 * configure.ac (AC_INIT): Bumped to 1.94.
12363 * config.guess: Updated from gnulib.
12364 * config.sub: Likewise.
12365 * install-sh: Likewise.
12366 * mkinstalldirs: Likewise.
12368 2006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
12370 * conf/common.rmk (grub_modules_init.lst): Depended on
12371 grub_emu_SOURCES, excluding grub_emu_init.c, instead of
12374 * genmk.rb (PModule::rule): Reverted the previous change.
12376 2006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
12378 * conf/common.rmk (grub_modules_init.lst): Depends on
12379 $(MODSRCFILES). Grep only the files in $(MODSRCFILES). Make sure
12380 that the target does not exist before producing.
12381 (grub_modules_init.h): Remove the target before generating.
12382 (grub_emu_init.c): Likewise.
12384 * genmk.rb (PModule::rule): Add source files into MODSRCFILES.
12386 2006-05-31 Jeroen Dekkers <jeroen@dekkers.cx>
12388 * configure.ac: Don't set host_m32 for x86_64. Also reset LIBS
12389 for the target-specific tests. Make sure that we also have the
12390 up-to-date target variables for those tests.
12392 2006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
12394 * genmk.rb (Image::rule): Prefix CFLAGS or ASFLAGS with TARGET_.
12395 (PModule::rule): Likewise.
12397 2006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
12399 * genmk.rb (Image::rule): Set FLAG to CFLAGS or ASFLAGS instead of
12400 TARGET_CFLAGS or TARGET_ASFLAGS. There is no reason why
12401 target-specific flags should be prefixed.
12402 (PModule::rule): Likewise.
12404 2006-05-30 Yoshinori K. Okuji <okuji@enbug.org>
12406 * configure.ac (CMP): Check if cmp is available explicitly.
12408 2006-05-29 Yoshinori K. Okuji <okuji@enbug.org>
12410 * util/powerpc/ieee1275/grub-install.in (host_cpu): Removed.
12411 (target_cpu): New variable.
12412 (pkglibdir): Use target_cpu instead of host_cpu.
12414 * util/i386/pc/grub-install.in (host_cpu): Removed.
12415 (target_cpu): New variable.
12416 (pkglibdir): Use target_cpu instead of host_cpu.
12418 * util/genmoddep.c: Removed.
12420 * kern/efi/mm.c (filter_memory_map): Use GRUB_CPU_SIZEOF_VOID_P
12421 instead of GRUB_HOST_SIZEOF_VOID_P.
12422 * kern/dl.c: Likewise.
12424 * include/grub/i386/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed to
12426 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
12427 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
12428 (GRUB_TARGET_SIZEOF_LONG): ... this.
12429 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
12430 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
12431 * include/grub/powerpc/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
12433 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
12434 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
12435 (GRUB_TARGET_SIZEOF_LONG): ... this.
12436 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
12437 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
12438 * include/grub/sparc64/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
12440 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
12441 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
12442 (GRUB_TARGET_SIZEOF_LONG): ... this.
12443 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
12444 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
12446 * include/grub/types.h [!GRUB_UTIL] (GRUB_CPU_SIZEOF_VOID_P): Use
12447 GRUB_TARGET_SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P.
12448 [!GRUB_UTIL] (GRUB_CPU_SIZEOF_LONG): Use GRUB_TARGET_SIZEOF_LONG
12449 instead of GRUB_HOST_SIZEOF_LONG.
12450 [!GRUB_UTIL]: Refer to GRUB_TARGET_WORDS_BIGENDIAN instead of
12451 GRUB_HOST_WORDS_BIGENDIAN to define or undefine
12452 GRUB_CPU_WORDS_BIGENDIAN.
12453 Refer to SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P to
12454 define grub_host_addr_t, grub_host_off_t, grub_host_size_t and
12457 * conf/i386-efi.rmk (noinst_UTILITIES): Removed.
12458 (genmoddep_SOURCES): Likewise.
12459 * conf/i386-pc.rmk (noinst_UTILITIES): Likewise.
12460 (genmoddep_SOURCES): Likewise.
12461 * conf/conf/powerpc-ieee1275.rmk (noinst_UTILITIES): Likewise.
12462 (genmoddep_SOURCES): Likewise.
12463 * conf/conf/conf/sparc64-ieee1275.rmk (noinst_UTILITIES):
12465 (genmoddep_SOURCES): Likewise.
12467 * genmoddep.awk: New file.
12469 * genmk.rb (Image::rule): Use TARGET_CC, TARGET_CPPFLAGS,
12470 TARGET_CFLAGS, TARGET_ASFLAGS and TARGET_LDFLAGS instead of CC,
12471 CPPFLAGS, CFLAGS, ASFLAGS and LDFLAGS, respectively.
12472 (PModule::rule): Likewise.
12473 (Program::rule): Likewise.
12474 (Utility::rule): Use CC, CPPFLAGS, CFLAGS and LDFLAGS instead of
12475 BUILD_CC, BUILD_CPPFLAGS, BUILD_CFLAGS and BUILD_LDFLAGS,
12478 * configure.ac: Rewritten intensively to use host and target
12479 instead of build and host, respectively.
12481 * Makefile.in (pkglibdir): Use target_cpu instead of host_cpu.
12482 (host_cpu): Removed.
12483 (target_cpu): New variable.
12484 (CPPFLAGS): Added @CPPFLAGS@ and -DGRUB_LIBDIR=\"$(pkglibdir)\".
12485 (BUILD_CC): Removed.
12486 (BUILD_CFLAGS): Likewise.
12487 (BUILD_CPPFLAGS): Likewise.
12488 (TARGET_CC): New variable.
12489 (TARGET_CFLAGS): Likewise.
12490 (TARGET_CPPFLAGS): Likewise.
12491 (TARGET_LDFLAGS): Likewise.
12493 (include): Use target_cpu instead of host_cpu.
12494 (moddep.lst:): Use genmoddep.awk instead of genmoddep.
12496 * DISTLIST: Added genmoddep.awk. Removed util/genmoddep.c.
12498 2006-05-29 Vesa Jaaskelainen <chaac@nic.fi>
12500 * include/grub/script.h (grub_script_cmdif): Renamed field 'bool' to
12501 'exec_to_evaluate'. Renamed field 'true' to 'exec_on_true'. Renamed
12502 field 'false' to 'exec_on_false'.
12503 (grub_script_create_cmdif): Renamed argument names to reflect above
12506 * normal/execute.c (grub_script_execute_cmdif): Likewise.
12508 * normal/script.c (grub_script_create_cmdif): Likewise.
12510 2006-05-28 Yoshinori K. Okuji <okuji@enbug.org>
12512 * fs/hfsplus.c (grub_hfsplus_btree_recoffset): Moved to near the
12514 (grub_hfsplus_btree_recptr): Likewise.
12515 (grub_hfsplus_find_block): Do not take RETRY any longer. Use
12516 FILEBLOCK both to pass a block number and store next block
12518 (grub_hfsplus_read_block): Rewritten heavily to support an extent
12519 overflow file correctly. Specify errors appropriately, because
12520 fshelp expects that GRUB_ERRNO is set when fails. Reuse
12521 grub_hfsplus_btree_recptr to get the pointer to a found key.
12522 (grub_hfsplus_btree_search): Return 1 instead of 0 when no match
12525 * conf/i386-efi.rmk (pkgdata_MODULES): Added _linux.mod and
12527 (_linux_mod_SOURCES): New variable.
12528 (_linux_mod_CFLAGS): Likewise.
12529 (_linux_mod_LDFLAGS): Likewise.
12530 (linux_mod_SOURCES): Likewise.
12531 (linux_mod_CFLAGS): Likewise.
12532 (linux_mod_LDFLAGS): Likewise.
12534 * DISTLIST: Added loader/i386/efi/linux.c,
12535 loader/i386/efi/linux_normal.c and
12536 include/grub/i386/efi/loader.h.
12538 * loader/i386/efi/linux.c: New file.
12539 * loader/i386/efi/linux_normal.c: Likewise.
12540 * include/grub/i386/efi/loader.h: Likewise.
12542 2006-05-27 Yoshinori K. Okuji <okuji@enbug.org>
12544 * commands/blocklist.c: New file.
12546 * DISTLIST: Added commands/blocklist.c.
12548 * term/efi/console.c (grub_console_highlight_color): Use a lighter
12549 color for the background, and a darker color for the foreground.
12550 (grub_console_checkkey): Return READ_KEY.
12551 (grub_console_cls): Set the background to
12552 GRUB_EFI_BACKGROUND_BLACK temporarily to clean out the screen.
12554 * kern/efi/efi.c (grub_efi_exit_boot_services): New function.
12556 * include/grub/i386/linux.h (struct linux_kernel_params): Fixed
12557 the size of "padding5", "hd0_drive_info" and "hd1_drive_info".
12559 * include/grub/efi/efi.h (grub_efi_exit_boot_services): New
12562 * include/grub/efi/api.h (GRUB_EFI_TEXT_ATTR): Do not shift
12563 BG. The spec is wrong again.
12565 * include/grub/normal.h [GRUB_UTIL] (grub_blocklist_init): New
12567 [GRUB_UTIL] (grub_blocklist_fini): Likewise.
12569 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
12570 commands/blocklist.c.
12571 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
12573 * conf/common.rmk (pkgdata_MODULES): Added blocklist.mod.
12574 (blocklist_mod_SOURCES): New variable.
12575 (blocklist_mod_CFLAGS): Likewise.
12576 (blocklist_mod_LDFLAGS): Likewise.
12578 2006-05-20 Yoshinori K. Okuji <okuji@enbug.org>
12580 * boot/i386/pc/boot.S (real_start): Set %si earlier to eliminate
12582 (lba_mode): Use %eax more intensively to reduce the code size.
12584 2006-05-20 Marco Gerards <marco@gnu.org>
12586 * normal/lexer.c (grub_script_yylex): Don't filter out newlines.
12588 * normal/parser.y (commandblock): Defined as <cmd>. A subroutine
12590 (script): Accept leading newlines.
12591 (newlines): New rule to describe 0 or more newlines.
12592 (commands): Accept `command' with trailing newline. Fixed the
12593 order in which arguments were passed to `grub_script_add_cmd'.
12594 Accept commands separated by newlines.
12595 (function): Changed to accept newlines.
12596 (menuentry) Rewritten.
12598 * normal/script.c (grub_script_create_cmdmenu): Add new entries in
12599 front of the list, instead of to the end.
12601 2006-05-19 Yoshinori K. Okuji <okuji@enbug.org>
12603 * util/i386/pc/grub-install.in (bindir): New variable.
12604 (grub_mkimage): Use BINDIR instead of SBINDIR. Reported by Lee
12605 Shaver <lbgwjl@gmail.com>.
12607 2006-05-14 Yoshinori K. Okuji <okuji@enbug.org>
12609 * kern/i386/pc/startup.S: Include grub/cpu/linux.h instead of
12610 grub/machine/linux.h
12611 * loader/i386/pc/linux.c: Likewise.
12613 * include/grub/i386/pc/linux.h: Moved to ...
12614 * include/grub/i386/linux.h: ... here.
12616 * include/grub/i386/linux.h (struct linux_kernel_params): New
12619 2006-05-09 Vesa Jaaskelainen <chaac@nic.fi>
12621 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Corrected bounds
12623 (grub_video_vbe_blit_glyph): Likewise.
12624 (grub_video_vbe_blit_bitmap): Likewise.
12625 (grub_video_vbe_blit_render_target): Likewise.
12627 2006-05-09 Yoshinori K. Okuji <okuji@enbug.org>
12629 * configure.ac (--with-platform): Properly quote the square
12632 2006-05-08 Marco Gerards <marco@gnu.org>
12634 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Renamed from
12636 (kernel_elf_HEADERS): ...to this. Updated all users.
12637 (grubof_symlist.c): Renamed from this...
12638 (kernel_elf_symlist.c): ...to this. Updated all users.
12639 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
12640 (grubof_SOURCES): Renamed from this...
12641 (kernel_elf_SOURCES): ...to this.
12642 (grubof_HEADERS): Renamed from this...
12643 (kernel_elf_HEADERS): ...to this.
12644 (grubof_CFLAGS): Renamed from this...
12645 (kernel_elf_CFLAGS): ...to this.
12646 (grubof_ASFLAGS): Renamed from this...
12647 (kernel_elf_ASFLAGS): ...to this.
12648 (grubof_LDFLAGS): Renamed from this...
12649 (kernel_elf_LDFLAGS): ...to this.
12651 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Renamed from
12653 (kernel_elf_HEADERS): ...to this. Updated all users.
12654 (grubof_symlist.c): Renamed from this...
12655 (kernel_elf_symlist.c): ...to this. Updated all users.
12656 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
12657 (grubof_SOURCES): Renamed from this...
12658 (kernel_elf_SOURCES): ...to this.
12659 (grubof_HEADERS): Renamed from this...
12660 (kernel_elf_HEADERS): ...to this.
12661 (grubof_CFLAGS): Renamed from this...
12662 (kernel_elf_CFLAGS): ...to this.
12663 (grubof_ASFLAGS): Renamed from this...
12664 (kernel_elf_ASFLAGS): ...to this.
12665 (grubof_LDFLAGS): Renamed from this...
12666 (kernel_elf_LDFLAGS): ...to this.
12668 * util/powerpc/ieee1275/grub-mkimage.c (add_segments): Use
12669 `kernel.elf' instead of `grubof'.
12671 2006-05-08 Yoshinori K. Okuji <okuji@enbug.org>
12673 Add --with-platform to configure. Use pkglibdir instead of
12674 pkgdatadir. This is reported by Roger Leigh.
12676 * util/powerpc/ieee1275/grub-install.in (datadir): Removed.
12677 (host_vendor): Likewise.
12678 (host_os): Likewise.
12679 (pkgdatadir): Likewise.
12680 (platform): New variable.
12681 (pkglibdir): Likewise.
12682 Use PKGLIBDIR instead of PKGDATADIR.
12684 * util/i386/pc/grub-install.in (datadir): Removed.
12685 (host_vendor): Likewise.
12686 (host_os): Likewise.
12687 (pkgdatadir): Likewise.
12688 (platform): New variable.
12689 (pkglibdir): Likewise.
12690 Use PKGLIBDIR instead of PKGDATADIR.
12692 * util/powerpc/ieee1275/grub-mkimage.c (usage): Use GRUB_LIBDIR
12693 instead of GRUB_DATADIR.
12695 * util/i386/pc/grub-mkimage.c (usage): Likewise.
12697 * util/i386/efi/grub-mkimage.c (usage): Likewise.
12700 * configure.ac (--with-platform): New option.
12701 Use PLATFORM instead of HOST_VENDOR to specify a platform.
12703 * Makefile.in: Include a makefile based on PLATFORM instead of
12705 (pkgdatadir): Not appended by the machine type.
12706 (pkglibdir): Appended by the machine type.
12707 (host_vendor): Removed.
12708 (platform): New variable.
12709 (BUILD_CPPFLAGS): Specify GRUB_LIBDIR instead of GRUB_DATADIR.
12710 (install-local): Use PKGLIBDIR instead of PKGDATADIR.
12711 (uninstall): Likewise.
12713 2006-05-07 Yoshinori K. Okuji <okuji@enbug.org>
12715 Use the environment context in the menu. Remove the commands
12716 "default" and "timeout", and use variables instead.
12718 * normal/menu.c: Include grub/env.h.
12719 (print_entry): Cast TITLE to silence gcc.
12720 (get_timeout): New function.
12721 (set_timeout): Likewise.
12722 (get_entry_number): Likewise.
12723 (run_menu): Use a default entry, a fallback entry and a timeout
12724 in the environment variables "default", "fallback" and
12725 "timeout". Also, tweak the default entry if it is not within the
12726 current menu entries.
12727 (grub_menu_run): Use a fallback entry in the environment variable
12730 * normal/main.c (read_config_file): Do not initialize
12731 NEWMENU->DEFAULT_ENTRY, NEWMENU->FALLBACK_ENTRY or
12733 (grub_normal_execute): Use a data slot to store the menu.
12735 * include/grub/normal.h (struct grub_menu): Removed default_entry,
12736 fallback_entry and timeout.
12737 (struct grub_menu_list): Removed.
12738 (grub_menu_list_t): Likewise.
12739 (struct grub_context): Likewise.
12740 (grub_context_t): Likewise.
12741 (grub_context_get): Likewise.
12742 (grub_context_get_current_menu): Likewise.
12743 (grub_context_push_menu): Likewise.
12744 (grub_context_pop_menu): Likewise.
12745 (grub_default_init): Likewise.
12746 (grub_default_fini): Likewise.
12747 (grub_timeout_init): Likewise.
12748 (grub_timeout_fini): Likewise.
12750 * conf/sparc64-ieee1275.rmk (pkgdata_MODULES): Removed default.mod
12752 (normal_mod_SOURCES): Removed normal/context.c.
12754 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Removed
12755 commands/default.c, commands/timeout.c and normal/context.c.
12756 (normal_mod_SOURCES): Removed normal/context.c.
12758 * conf/i386-pc.rmk (grub_emu_SOURCES): Removed commands/default.c,
12759 commands/timeout.c and normal/context.c.
12760 (normal_mod_SOURCES): Removed normal/context.c.
12762 * conf/i386-efi.rmk (grub_emu_SOURCES): Removed
12763 commands/default.c, commands/timeout.c and normal/context.c.
12764 (normal_mod_SOURCES): Removed normal/context.c.
12766 * conf/common.rmk (pkgdata_MODULES): Removed default.mod and
12768 (default_mod_SOURCES): Removed.
12769 (default_mod_CFLAGS): Likewise.
12770 (default_mod_LDFLAGS): Likewise.
12771 (timeout_mod_SOURCES): Removed.
12772 (timeout_mod_CFLAGS): Likewise.
12773 (timeout_mod_LDFLAGS): Likewise.
12775 * DISTLIST: Removed commands/default.c, commands/timeout.c and
12778 * commands/default.c: Removed.
12779 * commands/timeout.c: Likewise.
12780 * normal/context.c: Likewise.
12782 2006-05-07 Vesa Jaaskelainen <chaac@nic.fi>
12784 * kern/i386/pc/startup.S (grub_exit): Added missing .code32 tag.
12786 2006-05-02 Yoshinori K. Okuji <okuji@enbug.org>
12788 * kern/env.c (struct grub_env_context): Removed "sorted". Renamed
12789 "next" to "prev" for readability.
12790 (struct grub_env_sorted_var): New struct.
12791 (grub_env_context): Renamed to ...
12792 (initial_context): ... this.
12793 (grub_env_var_context): Renamed to ...
12794 (current_context): ... this.
12795 (grub_env_find): Look only at CURRENT_CONTEXT.
12796 (grub_env_context_open): Rewritten to copy exported variables from
12798 (grub_env_context_close): Rewritten according to the new
12799 scheme. Also, add an assertion to prevent the initial context from
12801 (grub_env_insert): Removed the code for the sorted list.
12802 (grub_env_remove): Likewise.
12803 (grub_env_export): Simply mark the variable with
12804 GRUB_ENV_VAR_GLOBAL.
12805 (grub_env_set): A cosmetic change for naming consistency.
12806 (grub_env_get): Likewise.
12807 (grub_env_unset): Likewise.
12808 (grub_env_iterate): Rewritten to sort variables within this
12810 (grub_register_variable_hook): Fixed for naming consistency. Call
12811 grub_env_find again, only if NAME is not found at the first time.
12812 (mangle_data_slot_name): New function.
12813 (grub_env_set_data_slot): Likewise.
12814 (grub_env_get_data_slot): Likewise.
12815 (grub_env_unset_data_slot): Likewise.
12817 * include/grub/env.h (grub_env_var_type): New enum.
12818 (GRUB_ENV_VAR_LOCAL): New constant.
12819 (GRUB_ENV_VAR_GLOBAL): Likewise.
12820 (GRUB_ENV_VAR_DATA): Likewise.
12821 (struct grub_env_var): Removed "sort_next" and "sort_prevp". Added
12823 (grub_env_set): Replace VAR with NAME for consistency.
12824 (grub_register_variable_hook): Likewise.
12825 (grub_env_export): Specify the name of the argument.
12826 (grub_env_set_data_slot): New prototype.
12827 (grub_env_get_data_slot): Likewise.
12828 (grub_env_unset_data_slot): Likewise.
12830 2006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
12832 Extend the loader so that GRUB can accept a loader which comes
12833 back to GRUB when a loaded image exits. Also, this change adds
12834 support for a chainloader on EFI.
12836 * term/efi/console.c: Include grub/misc.h.
12837 (grub_console_checkkey): Display a scan code on the top for
12838 debugging. This will be removed once the EFI port gets stable.
12839 Correct the scan code mapping.
12841 * kern/efi/mm.c (sort_memory_map): Sort in a descending order to
12842 allocate memory from larger regions, in order to reduce the number
12843 of allocated regions. Otherwise, the MacOSX loader panics.
12844 (filter_memory_map): Avoid less than 1MB for compatibility with
12846 (add_memory_regions): Allocate from the tail of a region, if
12847 possible, to avoid allocating a region near to 1MB, for the MacOSX
12850 * kern/efi/init.c (grub_efi_set_prefix): Specify
12851 GRUB_EFI_IMAGE_HANDLE to grub_efi_get_loaded_image.
12853 * kern/efi/efi.c (grub_efi_get_loaded_image): Accept a new
12854 argument IMAGE_HANDLE and specify it to get a loaded image.
12855 (grub_arch_modules_addr): Specify GRUB_EFI_IMAGE_HANDLE to
12856 grub_efi_get_loaded_image.
12857 (grub_efi_get_filename): Divide the length by the size of
12859 (grub_efi_get_device_path): New function.
12860 (grub_efi_print_device_path): Print End Device Path nodes. Divide
12861 the length by the size of grub_efi_char16_t for a file path device
12864 * kern/loader.c (grub_loader_noreturn): New variable.
12865 (grub_loader_set): Accept a new argument NORETURN. Set
12866 GRUB_LOADER_NORETURN to NORETURN.
12867 All callers changed.
12868 (grub_loader_boot): If GRUB_LOADER_NORETURN is false, do not call
12871 * include/grub/efi/efi.h (grub_efi_get_device_path): New
12873 (grub_efi_get_loaded_image): Take an argument to specify an image
12876 * include/grub/loader.h (grub_loader_set): Added one more argument
12879 * disk/efi/efidisk.c (make_devices): Use grub_efi_get_device_path
12880 instead of grub_efi_open_protocol.
12881 (grub_efidisk_get_device_name): Likewise.
12882 (grub_efidisk_close): Print a newline.
12883 (grub_efidisk_get_device_handle): Fixed to use
12884 GRUB_EFI_DEVICE_PATH_SUBTYPE instead of
12885 GRUB_EFI_DEVICE_PATH_TYPE.
12887 * disk/efi/efidisk.c (device_path_guid): Moved to ...
12888 * kern/efi/efi.c (device_path_guid): ... here.
12890 * conf/i386-efi.rmk (pkgdata_MODULES): Added _chain.mod and
12892 (kernel_mod_HEADERS): Added efi/disk.h.
12893 (_chain_mod_SOURCES): New variable.
12894 (_chain_mod_CFLAGS): Likewise.
12895 (_chain_mod_LDFLAGS): Likewise.
12896 (chain_mod_SOURCES): Likewise.
12897 (chain_mod_CFLAGS): Likewise.
12898 (chain_mod_LDFLAGS): Likewise.
12900 * DISTLIST: Added include/grub/efi/chainloader.h,
12901 loader/efi/chainloader.c and loader/efi/chainloader_normal.c.
12903 * include/grub/efi/chainloader.h: New file.
12904 * loader/efi/chainloader.c: Likewise.
12905 * loader/efi/chainloader_normal.c: Likewise.
12907 2006-04-30 Marco Gerards <marco@gnu.org>
12909 * commands/configfile.c (grub_cmd_source): New function.
12910 (GRUB_MOD_INIT): Register the commands `source' and `.'.
12911 (GRUB_MOD_FINI): De-register the commands `source' and `.'.
12913 2006-04-30 Marco Gerards <marco@gnu.org>
12915 * normal/execute.c (grub_script_execute_cmd): Change the return
12916 type to `grub_err_t'. Correctly return the error.
12917 (grub_script_execute_cmdline): In case a command line is not a
12918 command or a function, try to interpret it as an assignment.
12920 2006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
12922 * fs/hfsplus.c (grub_hfsplus_read_block): Fixed a memory leak.
12923 (grub_hfsplus_iterate_dir): Reordered to skip unknown nodes. Also,
12924 skip a node whose name is obviously invalid as UTF-16,
12925 i.e. contains a NUL character. Stop the iteration when the last
12926 directory entry is found. Instead of using the return value of
12927 grub_hfsplus_btree_iterate_node, store the value in RET and use
12928 it, because the iterator can be stopped by the last directory
12931 2006-04-30 Marco Gerards <marco@gnu.org>
12933 * include/grub/env.h (grub_env_export): New prototype. Reported
12934 by Jan C. Kleinsorge <jan.kleinsorge@udo.edu>.
12936 2006-04-30 Marco Gerards <marco@gnu.org>
12938 * fs/hfsplus.c (grub_hfsplus_iterate_dir): Correctly calculate the
12939 size of the extents in a catalog file record.
12941 2006-04-29 Marco Gerards <marco@gnu.org>
12943 * commands/configfile.c (grub_cmd_configfile): Execute the
12944 configfile within its own context.
12946 * include/grub/env.h (grub_env_context_open): New prototype.
12947 (grub_env_context_close): Likewise.
12949 * kern/env.c (grub_env): Removed.
12950 (grub_env_sorted): Likewise.
12951 (grub_env_context): New variable.
12952 (grub_env_var_context): Likewise.
12953 (grub_env_find): Search both the active context and the global
12955 (grub_env_context_open): New function.
12956 (grub_env_context_close): Likewise.
12957 (grub_env_insert): Likewise.
12958 (grub_env_remove): Likewise.
12959 (grub_env_export): Likewise.
12960 (grub_env_set): Changed to use helper functions to avoid code
12962 (grub_env_iterate): Rewritten so both the current context and the
12963 global context are being used.
12965 * normal/command.c (export_command): New function.
12966 (grub_command_init): Register the `export' function.
12968 2006-04-26 Yoshinori K. Okuji <okuji@enbug.org>
12970 * util/i386/pc/grub-mkimage.c (compress_kernel): Cast arguments
12971 explicitly to suppress gcc's warnings.
12972 * fs/fat.c (grub_fat_find_dir): Likewise.
12973 (grub_fat_label): Likewise.
12974 * fs/xfs.c (grub_xfs_read_inode): Likewise.
12975 (grub_xfs_mount): Likewise.
12976 (grub_xfs_label): Likewise.
12977 * fs/affs.c (grub_affs_mount): Likewise.
12978 (grub_affs_label): Likewise.
12979 (grub_affs_iterate_dir): Likewise.
12980 * fs/sfs.c (grub_sfs_mount): Likewise.
12981 (grub_sfs_iterate_dir): Likewise.
12982 * fs/ufs.c (grub_ufs_lookup_symlink): Likewise.
12983 * fs/hfs.c (grub_hfs_mount): Likewise.
12984 (grub_hfs_cmp_catkeys): Likewise.
12985 (grub_hfs_find_dir): Likewise.
12986 (grub_hfs_dir): Likewise.
12987 (grub_hfs_label): Likewise.
12988 * fs/jfs.c (grub_jfs_mount): Likewise.
12989 (grub_jfs_opendir): Likewise.
12990 (grub_jfs_getent): Likewise.
12991 (grub_jfs_lookup_symlink): Likewise.
12992 (grub_jfs_label): Likewise.
12993 * fs/hfsplus.c (grub_hfsplus_cmp_catkey): Likewise.
12994 (grub_hfsplus_iterate_dir): Likewise.
12995 (grub_hfsplus_btree_iterate_node): Made static.
12997 * util/grub-emu.c (prefix): New variable.
12998 (grub_machine_set_prefix): New function.
12999 (main): Do not set the environment variable "prefix" here. Only
13000 set PREFIX, which is used later by grub_machine_set_prefix.
13002 * include/grub/video.h: Do not include grub/symbol.h.
13003 (grub_video_register): Not exported. This symbol is not defined in
13005 (grub_video_unregister): Likewise.
13006 (grub_video_iterate): Likewise.
13007 (grub_video_setup): Likewise.
13008 (grub_video_restore): Likewise.
13009 (grub_video_get_info): Likewise.
13010 (grub_video_get_blit_format): Likewise.
13011 (grub_video_set_palette): Likewise.
13012 (grub_video_get_palette): Likewise.
13013 (grub_video_set_viewport): Likewise.
13014 (grub_video_get_viewport): Likewise.
13015 (grub_video_map_color): Likewise.
13016 (grub_video_map_rgb): Likewise.
13017 (grub_video_map_rgba): Likewise.
13018 (grub_video_fill_rect): Likewise.
13019 (grub_video_blit_glyph): Likewise.
13020 (grub_video_blit_bitmap): Likewise.
13021 (grub_video_blit_render_target): Likewise.
13022 (grub_video_scroll): Likewise.
13023 (grub_video_swap_buffers): Likewise.
13024 (grub_video_create_render_target): Likewise.
13025 (grub_video_delete_render_target): Likewise.
13026 (grub_video_set_active_render_target): Likewise.
13028 * include/grub/symbol.h [GRUB_SYMBOL_GENERATOR] (EXPORT_FUNC):
13030 [GRUB_SYMBOL_GENERATOR] (EXPORT_VAR): Likewise.
13032 * conf/sparc64-ieee1275.rmk (grubof_symlist.c): Depended on
13033 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
13034 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
13035 instead of $(srcdir)/genkernsyms.sh.
13037 * conf/powerpc-ieee1275.rmk (grubof_symlist.c): Depended on
13038 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
13039 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
13040 instead of $(srcdir)/genkernsyms.sh.
13042 * conf/i386-pc.rmk (symlist.c): Depended on config.h. Use
13043 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
13044 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
13045 instead of $(srcdir)/genkernsyms.sh.
13047 * conf/i386-efi.rmk (symlist.c): Depended on config.h. Use
13048 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
13049 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
13050 instead of $(srcdir)/genkernsyms.sh.
13052 * configure.ac (AC_CONFIG_FILES): Added gensymlist.sh and
13055 * Makefile.in (DISTCLEANFILES): Added gensymlist.sh and
13057 (gensymlist.sh): New target.
13058 (genkernsyms.sh): Likewise.
13060 * DISTLIST: Removed genkernsyms.sh and gensymlist.sh. Added
13061 genkernsyms.sh.in and gensymlist.sh.in.
13063 * genkernsyms.sh: Removed.
13064 * gensymlist.sh: Likewise.
13066 * genkernsyms.sh.in: New file.
13067 * gensymlist.sh.in: Likewise.
13069 2006-04-25 Hollis Blanchard <hollis@penguinppc.org>
13071 * kern/powerpc/ieee1275/init.c (grub_machine_set_prefix): Do not
13072 clobber "prefix", since we may have already set it manually.
13074 2006-04-25 Hollis Blanchard <hollis@penguinppc.org>
13076 * kern/misc.c (abort): New alias for grub_abort.
13078 2006-04-25 Yoshinori K. Okuji <okuji@enbug.org>
13080 A new machine-specific function "grub_machine_set_prefix" is
13081 defined. This is called after loading modules, so that a prefix
13082 initialization can use modules. Also, this change adds an
13083 intensive debugging feature for the memory manager via the
13084 configure option "--enable-mm-debug".
13086 * partmap/gpt.c (gpt_partition_map_iterate): Add one more into
13089 * kern/sparc64/ieee1275/init.c (abort): Removed.
13090 (grub_stop): Likewise.
13091 (grub_exit): New function.
13092 (grub_set_prefix): Renamed to ...
13093 (grub_machine_set_prefix): ... this.
13094 (grub_machine_init): Do not call grub_set_prefix.
13096 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Renamed to ...
13097 (grub_machine_set_prefix): ... this.
13098 (grub_machine_init): Do not call grub_set_prefix.
13100 * kern/i386/pc/init.c (grub_machine_set_prefix): New function.
13101 (grub_machine_init): Do not set the prefix here.
13103 * kern/i386/efi/init.c (grub_machine_set_prefix): New function.
13105 * kern/efi/init.c: Include grub/mm.h.
13106 (grub_efi_set_prefix): New function.
13108 * kern/efi/efi.c (grub_exit): Call grub_efi_fini.
13109 (grub_efi_get_filename): New function.
13110 (grub_print_device_path): Renamed to ...
13111 (grub_efi_print_device_path): ... this.
13113 * kern/mm.c [MM_DEBUG] (grub_malloc): Undefined.
13114 [MM_DEBUG] (grub_realloc): Likewise.
13115 [MM_DEBUG] (grub_free): Likewise.
13116 [MM_DEBUG] (grub_memalign): Likewise.
13117 [MM_DEBUG] (grub_mm_debug): New variable.
13118 [MM_DEBUG] (grub_debug_malloc): New function.
13119 [MM_DEBUG] (grub_debug_free): New function.
13120 [MM_DEBUG] (grub_debug_realloc): New function.
13121 [MM_DEBUG] (grub_debug_memalign): New function.
13123 * kern/misc.c (grub_abort): Print a newline to distinguish
13126 * kern/main.c (grub_main): Call grub_machine_set_prefix and
13127 grub_set_root_dev after loading modules. This is necessary when
13128 setting a prefix depends on modules.
13130 * include/grub/efi/efi.h (grub_print_device_path): Renamed to ...
13131 (grub_efi_print_device_path): ... this.
13132 (grub_efi_get_filename): New prototype.
13133 (grub_efi_set_prefix): Likewise.
13135 * include/grub/efi/disk.h: Include grub/efi/api.h, grub/symbol.h
13137 (grub_efidisk_get_device_handle): New prototype.
13138 (grub_efidisk_get_device_name): Likewise.
13140 * include/grub/mm.h: Include config.h.
13141 (MM_DEBUG): Removed.
13142 [MM_DEBUG && !GRUB_UTIL] (grub_mm_debug): New prototype.
13143 [MM_DEBUG && !GRUB_UTIL] (grub_malloc): New macro.
13144 [MM_DEBUG && !GRUB_UTIL] (grub_realloc): Likewise.
13145 [MM_DEBUG && !GRUB_UTIL] (grub_memalign): Likewise.
13146 [MM_DEBUG && !GRUB_UTIL] (grub_free): Likewise.
13147 [MM_DEBUG && !GRUB_UTIL] (grub_debug_malloc): New prototype.
13148 [MM_DEBUG && !GRUB_UTIL] (grub_debug_realloc): New prototype.
13149 [MM_DEBUG && !GRUB_UTIL] (grub_debug_memalign): New prototype.
13150 [MM_DEBUG && !GRUB_UTIL] (grub_debug_free): New prototype.
13152 * include/grub/kernel.h (grub_machine_set_prefix): New prototype.
13154 * disk/efi/efidisk.c: Include grub/partition.h.
13155 (iterate_child_devices): New function.
13156 (add_device): First, compare only last device path nodes, so that
13157 devices are sorted by the types.
13158 (grub_efidisk_get_device_handle): New function.
13159 (grub_efidisk_get_device_name): Likewise.
13161 * configure.ac (--enable-mm-debug): New option to enable the
13162 memory manager debugging feature. This makes the binary much
13163 bigger, so is disabled by default.
13165 2006-04-23 Yoshinori K. Okuji <okuji@enbug.org>
13167 Use grub_abort instead of grub_stop, and grub_exit must be
13168 define in each architecture now. Also, this change adds support
13171 * util/i386/pc/grub-probefs.c: Include grub/term.h.
13172 (grub_getkey): New function.
13173 (grub_term_get_current): Likewise.
13175 * util/i386/pc/grub-setup.c: Include grub/term.h.
13176 (grub_getkey): New function.
13177 (grub_term_get_current): Likewise.
13179 * util/misc.c (grub_stop): Renamed to ...
13180 (grub_exit): ... this.
13182 * kern/powerpc/ieee1275/init.c (abort): Renamed to ...
13183 (grub_exit): ... this.
13184 (grub_machine_init): Use grub_abort instead of abort.
13185 (grub_stop): Removed.
13187 * kern/powerpc/ieee1275/cmain.c (cmain): Use grub_abort instead of
13190 * kern/i386/pc/startup.S (grub_exit): New function.
13191 (cold_reboot): New label.
13193 * kern/efi/init.c: Include grub/efi/disk.h and grub/env.h.
13194 (grub_efi_init): Call grub_efidisk_init.
13195 (grub_efi_fini): Call grub_efidisk_fini.
13197 * kern/efi/efi.c: Include grub/mm.h.
13198 (grub_efi_console_control_guid): Renamed to ...
13199 (console_control_guid): ... this.
13200 (grub_efi_loaded_image_guid): Renamed to ...
13201 (loaded_image_guid): ... this.
13202 (grub_efi_locate_handle): New function.
13203 (grub_efi_open_protocol): Likewise.
13204 (grub_efi_set_text_mode): Use CONSOLE_CONTROL_GUID instead of
13205 GRUB_EFI_CONSOLE_CONTROL_GUID.
13206 (grub_efi_exit): Removed.
13207 (grub_stop): Likewise.
13208 (grub_efi_get_loaded_image): Use grub_efi_open_protocol.
13209 (grub_exit): New function.
13210 (grub_print_device_path): Likewise.
13212 * kern/rescue.c (grub_rescue_cmd_exit): New function.
13213 (grub_enter_rescue_mode): Register "exit".
13215 * kern/misc.c (grub_real_dprintf): A cosmetic change.
13216 (grub_abort): New function.
13218 * kern/err.c (grub_fatal): Use grub_abort instead of grub_stop.
13220 * include/grub/sparc64/ieee1275/kernel.h (abort): Removed.
13222 * include/grub/powerpc/ieee1275/kernel.h (abort): Removed.
13224 * include/grub/efi/efi.h (grub_efi_exit): Removed.
13225 (grub_print_device_path): New prototype.
13226 (grub_efi_locate_handle): Likewise.
13227 (grub_efi_open_protocol): Likewise.
13229 * include/grub/efi/disk.h (grub_efidisk_fini): New file.
13230 * disk/efi/efidisk.c: Likewise.
13232 * DISTLIST: Added disk/efi/efidisk.c and include/grub/efi/disk.h.
13234 * include/grub/efi/console_control.h
13235 (GRUB_EFI_CONSOLE_CONTROL_GUID): Use an array for the last 8 bytes.
13237 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): Specify the
13238 last 8 bytes as an array.
13239 (GRUB_EFI_DISK_IO_GUID): New macro.
13240 (GRUB_EFI_BLOCK_IO_GUID): Likewise.
13241 (GRUB_EFI_DEVICE_PATH_GUID): Likewise.
13242 (grub_efi_ipv6_address_t): Change the type to grub_uint16_t from
13244 (struct grub_efi_guid): Use an array to specify the last 8 bytes.
13245 (struct grub_efi_device_path): Rename the member "sub_type" to
13247 (GRUB_EFI_DEVICE_PATH_TYPE): New macro.
13248 (GRUB_EFI_DEVICE_PATH_SUBTYPE): Likewise.
13249 (GRUB_EFI_DEVICE_PATH_LENGTH): Likewise.
13250 (GRUB_EFI_END_DEVICE_PATH_TYPE): Likewise.
13251 (GRUB_EFI_END_ENTIRE_DEVICE_PATH_SUBTYPE): Likewise.
13252 (GRUB_EFI_END_THIS_DEVICE_PATH_SUBTYPE): Likewise.
13253 (GRUB_EFI_END_ENTIRE_DEVICE_PATH): Likewise.
13254 (GRUB_EFI_NEXT_DEVICE_PATH): Likewise.
13255 (GRUB_EFI_HARDWARE_DEVICE_PATH_TYPE): Likewise.
13256 (GRUB_EFI_PCI_DEVICE_PATH_SUBTYPE): Likewise.
13257 (struct grub_efi_pci_device_path): New structure.
13258 (grub_efi_pci_device_path_t): New type.
13259 (GRUB_EFI_PCCARD_DEVICE_PATH_SUBTYPE): New macro.
13260 (struct grub_efi_pccard_device_path): New structure.
13261 (grub_efi_pccard_device_path_t): New type.
13262 (GRUB_EFI_MEMORY_MAPPED_DEVICE_PATH_SUBTYPE): New macro.
13263 (struct grub_efi_memory_mapped_device_path): New structure.
13264 (grub_efi_memory_mapped_device_path_t): New type.
13265 (GRUB_EFI_VENDOR_DEVICE_PATH_SUBTYPE): New macro.
13266 (struct grub_efi_vendor_device_path): New structure.
13267 (grub_efi_vendor_device_path_t): New type.
13268 (GRUB_EFI_CONTROLLER_DEVICE_PATH_SUBTYPE): New macro.
13269 (struct grub_efi_controller_device_path): New structure.
13270 (grub_efi_controller_device_path_t): New type.
13271 (GRUB_EFI_ACPI_DEVICE_PATH_TYPE): New macro.
13272 (GRUB_EFI_ACPI_DEVICE_PATH_SUBTYPE): Likewise.
13273 (struct grub_efi_acpi_device_path): New structure.
13274 (grub_efi_acpi_device_path_t): New type.
13275 (GRUB_EFI_EXPANDED_ACPI_DEVICE_PATH_SUBTYPE): New macro.
13276 (struct grub_efi_expanded_acpi_device_path): New structure.
13277 (grub_efi_expanded_acpi_device_path_t): New type.
13278 (GRUB_EFI_EXPANDED_ACPI_HIDSTR): New macro.
13279 (GRUB_EFI_EXPANDED_ACPI_UIDSTR): Likewise.
13280 (GRUB_EFI_EXPANDED_ACPI_CIDSTR): Likewise.
13281 (GRUB_EFI_MESSAGING_DEVICE_PATH_TYPE): Likewise.
13282 (GRUB_EFI_ATAPI_DEVICE_PATH_SUBTYPE): Likewise.
13283 (struct grub_efi_atapi_device_path): New structure.
13284 (grub_efi_atapi_device_path_t): New type.
13285 (GRUB_EFI_FIBRE_CHANNEL_DEVICE_PATH_SUBTYPE): New macro.
13286 (struct grub_efi_fibre_channel_device_path): New structure.
13287 (grub_efi_fibre_channel_device_path_t): New type.
13288 (GRUB_EFI_1394_DEVICE_PATH_SUBTYPE): New macro.
13289 (struct grub_efi_1394_device_path): New structure.
13290 (grub_efi_1394_device_path_t): New type.
13291 (GRUB_EFI_USB_DEVICE_PATH_SUBTYPE): New macro.
13292 (struct grub_efi_usb_device_path): New structure.
13293 (grub_efi_usb_device_path_t): New type.
13294 (GRUB_EFI_USB_CLASS_DEVICE_PATH_SUBTYPE): New macro.
13295 (struct grub_efi_usb_class_device_path): New structure.
13296 (grub_efi_usb_class_device_path_t): New type.
13297 (GRUB_EFI_I2O_DEVICE_PATH_SUBTYPE): New macro.
13298 (struct grub_efi_i2o_device_path): New structure.
13299 (grub_efi_i2o_device_path_t): New type.
13300 (GRUB_EFI_MAC_ADDRESS_DEVICE_PATH_SUBTYPE): New macro.
13301 (struct grub_efi_mac_address_device_path): New structure.
13302 (grub_efi_mac_address_device_path_t): New type.
13303 (GRUB_EFI_IPV4_DEVICE_PATH_SUBTYPE): New macro.
13304 (struct grub_efi_ipv4_device_path): New structure.
13305 (grub_efi_ipv4_device_path_t): New type.
13306 (GRUB_EFI_IPV6_DEVICE_PATH_SUBTYPE): New macro.
13307 (struct grub_efi_ipv6_device_path): New structure.
13308 (grub_efi_ipv6_device_path_t): New type.
13309 (GRUB_EFI_INFINIBAND_DEVICE_PATH_SUBTYPE): New macro.
13310 (struct grub_efi_infiniband_device_path): New structure.
13311 (grub_efi_infiniband_device_path_t): New type.
13312 (GRUB_EFI_UART_DEVICE_PATH_SUBTYPE): New macro.
13313 (struct grub_efi_uart_device_path): New structure.
13314 (grub_efi_uart_device_path_t): New type.
13315 (GRUB_EFI_VENDOR_MESSAGING_DEVICE_PATH_SUBTYPE): New macro.
13316 (struct grub_efi_vendor_messaging_device_path): New structure.
13317 (grub_efi_vendor_messaging_device_path_t): New type.
13318 (GRUB_EFI_MEDIA_DEVICE_PATH_TYPE): New macro.
13319 (GRUB_EFI_HARD_DRIVE_DEVICE_PATH_SUBTYPE): Likewise.
13320 (struct grub_efi_hard_drive_device_path): New structure.
13321 (grub_efi_hard_drive_device_path_t): New type.
13322 (GRUB_EFI_CDROM_DEVICE_PATH_SUBTYPE): New macro.
13323 (struct grub_efi_cdrom_device_path): New structure.
13324 (grub_efi_cdrom_device_path_t): New type.
13325 (GRUB_EFI_VENDOR_MEDIA_DEVICE_PATH_SUBTYPE): New macro.
13326 (struct grub_efi_vendor_media_device_path): New structure.
13327 (grub_efi_vendor_media_device_path_t): New type.
13328 (GRUB_EFI_FILE_PATH_DEVICE_PATH_SUBTYPE): New macro.
13329 (struct grub_efi_file_path_device_path): New structure.
13330 (grub_efi_file_path_device_path_t): New type.
13331 (GRUB_EFI_PROTOCOL_DEVICE_PATH_SUBTYPE): New macro.
13332 (struct grub_efi_protocol_device_path): New structure.
13333 (grub_efi_protocol_device_path_t): New type.
13334 (GRUB_EFI_BIOS_DEVICE_PATH_TYPE): New macro.
13335 (GRUB_EFI_BIOS_DEVICE_PATH_SUBTYPE): Likewise.
13336 (struct grub_efi_bios_device_path): New structure.
13337 (grub_efi_bios_device_path_t): New type.
13338 (struct grub_efi_disk_io): New structure.
13339 (grub_efi_disk_io_t): New type.
13340 (struct grub_efi_block_io_media): New structure.
13341 (grub_efi_block_io_media_t): New type.
13342 (struct grub_efi_block_io): New structure.
13343 (grub_efi_block_io_t): New type.
13345 * include/grub/misc.h (grub_stop): Removed.
13346 (grub_exit): New prototype.
13347 (grub_abort): Likewise.
13349 * include/grub/disk.h (enum grub_disk_dev_id): Added
13350 GRUB_DISK_DEVICE_EFIDISK_ID.
13352 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added
13353 disk/efi/efidisk.c.
13354 (kernel_syms.lst): Remove the target if an error occurs.
13356 2006-04-22 Yoshinori K. Okuji <okuji@enbug.org>
13358 * kern/misc.c (grub_lltoa): Rewritten the decimal conversion part,
13359 as it was simply too buggy.
13361 2006-04-21 Yoshinori K. Okuji <okuji@enbug.org>
13363 * kern/misc.c (grub_lltoa): New function.
13364 (grub_vsprintf): Added support for the long long suffix,
13367 2006-04-20 Hollis Blanchard <hollis@penguinppc.org>
13369 * Makefile.in (LDFLAGS): Add variable.
13370 (LD): Remove variable.
13371 * configure.ac: Add -m32 to LDFLAGS.
13372 * genmk.rb (PModule#rule): Use $(CC) instead of $(LD).
13373 * conf/powerpc-ieee1275.rmk (COMMON_LDFLAGS): Add variable.
13374 (grubof_LDFLAGS): Use $(COMMON_LDFLAGS).
13375 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS, normal_mod_LDFLAGS,
13376 suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS): New
13378 * conf/sparc64-ieee1275.rmk (COMMON_LDFLAGS): Add -nostdlib.
13379 * conf/i386-pc.rmk (COMMON_LDFLAGS): Add -nostdlib.
13380 * conf/i386-efi.rmk (COMMON_LDFLAGS): Add -nostdlib.
13382 2006-04-20 Vesa Jaaskelainen <chaac@nic.fi>
13384 * term/gfxterm.c (grub_gfxterm_getcharwidth): Fixed character
13385 length for unknown glyph.
13387 2006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
13389 Add support for pre-loaded modules into the EFI port.
13391 * util/i386/efi/grub-mkimage.c (make_mods_section): Rewritten
13392 completely. Accept one more argument DIR. The caller has changed.
13394 * kern/i386/efi/init.c (grub_arch_modules_addr): Removed.
13396 * kern/efi/efi.c: Include grub/efi/pe32.h and grub/kernel.h.
13397 (grub_efi_loaded_image_guid): New variable.
13398 (grub_efi_get_loaded_image): New function.
13399 (grub_arch_modules_addr): Likewise.
13401 * include/grub/efi/efi.h (grub_efi_get_loaded_image): New
13404 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): New macro.
13405 (struct grub_efi_loaded_image): New structure.
13406 (grub_efi_loaded_image_t): New type.
13408 2006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
13410 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Compare the file
13411 size with GRUB_OS_AREA_SIZE as grub_size_t instead of
13412 grub_ssize_t. Reported by Jeff Chua <jeff84@silk.corp.fedex.com>.
13414 2006-04-19 Roger Leigh <rleigh@whinlatter.ukfsn.org>
13416 * DISTLIST: Added `util/powerpc/ieee1275/grub-install.in'.
13418 2006-04-19 Yoshinori K. Okuji <okuji@enbug.org>
13420 * DISTLIST: Added include/grub/efi/console.h,
13421 include/grub/efi/time.h, include/grub/i386/efi/kernel.h,
13422 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
13424 * include/grub/efi/console.h: New file.
13425 * include/grub/efi/time.h: Likewise.
13426 * include/grub/i386/efi/kernel.h: Likewise.
13427 * kern/efi/init.c: Likewise.
13428 * kern/efi/mm.c: Likewise.
13429 * term/efi/console.c: Likewise.
13431 * kern/i386/efi/init.c: Do not include grub/machine/time.h.
13432 (grub_stop): Removed.
13433 (grub_get_rtc): Likewise.
13434 (grub_machine_init): Simply call grub_efi_init.
13435 (grub_machine_fini): Call grub_efi_fini.
13437 * kern/efi/efi.c: Include grub/machine/time.h and grub/term.h.
13438 (grub_efi_output_string): Removed.
13439 (grub_efi_stall): New function.
13440 (grub_stop): Likewise.
13441 (grub_get_rtc): Likewise.
13443 * include/grub/efi/efi.h (grub_efi_output_string): Removed.
13444 (grub_efi_stall): New prototype.
13445 (grub_efi_allocate_pages): Likewise.
13446 (grub_efi_free_pages): Likewise.
13447 (grub_efi_get_memory_map): Likewise.
13448 (grub_efi_mm_init): Likewise.
13449 (grub_efi_mm_fini): Likewise.
13450 (grub_efi_init): Likewise.
13451 (grub_efi_fini): Likewise.
13453 * include/grub/i386/efi/time.h: Do not include
13454 grub/symbol.h. Include grub/efi/time.h.
13455 (GRUB_TICKS_PER_SECOND): Removed.
13456 (grub_get_rtc): Likewise.
13458 * include/grub/efi/api.h (struct grub_efi_memory_descriptor):
13459 Added padding. The EFI spec is buggy.
13460 (GRUB_EFI_BLACK): New macro.
13461 (GRUB_EFI_BLUE): Likewise.
13462 (GRUB_EFI_GREEN): Likewise.
13463 (GRUB_EFI_CYAN): Likewise.
13464 (GRUB_EFI_RED): Likewise.
13465 (GRUB_EFI_MAGENTA): Likewise.
13466 (GRUB_EFI_BROWN): Likewise.
13467 (GRUB_EFI_LIGHTGRAY): Likewise.
13468 (GRUB_EFI_BRIGHT): Likewise.
13469 (GRUB_EFI_DARKGRAY): Likewise.
13470 (GRUB_EFI_LIGHTBLUE): Likewise.
13471 (GRUB_EFI_LIGHTGREEN): Likewise.
13472 (GRUB_EFI_LIGHTCYAN): Likewise.
13473 (GRUB_EFI_LIGHTRED): Likewise.
13474 (GRUB_EFI_LIGHTMAGENTA): Likewise.
13475 (GRUB_EFI_YELLOW): Likewise.
13476 (GRUB_EFI_WHITE): Likewise.
13477 (GRUB_EFI_BACKGROUND_BLACK): Likewise.
13478 (GRUB_EFI_BACKGROUND_BLUE): Likewise.
13479 (GRUB_EFI_BACKGROUND_GREEN): Likewise.
13480 (GRUB_EFI_BACKGROUND_CYAN): Likewise.
13481 (GRUB_EFI_BACKGROUND_RED): Likewise.
13482 (GRUB_EFI_BACKGROUND_MAGENTA): Likewise.
13483 (GRUB_EFI_BACKGROUND_BROWN): Likewise.
13484 (GRUB_EFI_BACKGROUND_LIGHTGRAY): Likewise.
13485 (GRUB_EFI_TEXT_ATTR): Likewise.
13487 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added kern/efi/efi.c,
13488 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
13489 (kernel_mod_HEADERS): Added efi/time.h.
13491 2006-04-18 Yoshinori K. Okuji <okuji@enbug.org>
13493 * DISTLIST: Added conf/i386-efi.mk, conf/i386-efi.rmk,
13494 include/grub/efi/api.h, include/grub/efi/console_control.h,
13495 include/grub/efi/efi.h, include/grub/efi/pe32.h,
13496 include/grub/i386/efi/time.h, kern/efi/efi.c,
13497 kern/i386/efi/init.c, kern/i386/efi/startup.S,
13498 and util/i386/efi/grub-mkimage.c.
13500 * Makefile.in (RMKFILES): Added i386-efi.rmk.
13502 * genmk.rb (PModule#rule): Do not export symbols if
13503 #{prefix}_EXPORTS is set to "no".
13505 * conf/i386-efi.mk: New file.
13506 * conf/i386-efi.rmk: Likewise.
13507 * include/grub/efi/api.h: Likewise.
13508 * include/grub/efi/console_control.h: Likewise.
13509 * include/grub/efi/efi.h: Likewise.
13510 * include/grub/efi/pe32.h: Likewise.
13511 * include/grub/i386/efi/time.h: Likewise.
13512 * kern/efi/efi.c: Likewise.
13513 * kern/i386/efi/init.c: Likewise.
13514 * kern/i386/efi/startup.S: Likewise.
13515 * util/i386/efi/grub-mkimage.c: Likewise.
13517 2006-04-17 Marco Gerards <marco@gnu.org>
13519 * include/grub/script.h: Include <grub/parser.h> and
13520 "grub_script.tab.h".
13521 (struct grub_lexer_param): New struct.
13522 (struct grub_parser_param): Likewise.
13523 (grub_script_create_arglist): Pass the state in an argument.
13524 (grub_script_add_arglist): Likewise.
13525 (grub_script_create_cmdline): Likewise.
13526 (grub_script_create_cmdblock): Likewise.
13527 (grub_script_create_cmdif): Likewise.
13528 (grub_script_create_cmdmenu): Likewise.
13529 (grub_script_add_cmd): Likewise.
13530 (grub_script_arg_add): Likewise.
13531 (grub_script_lexer_ref): Likewise.
13532 (grub_script_lexer_deref): Likewise.
13533 (grub_script_lexer_record_start): Likewise.
13534 (grub_script_lexer_record_stop): Likewise.
13535 (grub_script_mem_record): Likewise.
13536 (grub_script_mem_record_stop): Likewise.
13537 (grub_script_malloc): Likewise.
13538 (grub_script_yylex): Likewise.
13539 (grub_script_yyparse): Likewise.
13540 (grub_script_yyerror): Likewise.
13541 (grub_script_yylex): Likewise.
13542 (grub_script_lexer_init): Return the state.
13544 * normal/lexer.c (grub_script_lexer_state): Removed variable.
13545 (grub_script_lexer_done): Likewise.
13546 (grub_script_lexer_getline): Likewise.
13547 (grub_script_lexer_refs): Likewise.
13548 (script): Likewise.
13549 (newscript): Likewise.
13550 (record): Likewise.
13551 (recording): Likewise.
13552 (recordpos): Likewise.
13553 (recordlen): Likewise.
13554 (grub_script_lexer_init): Return the state instead of setting
13556 (grub_script_lexer_ref): Use the newly added argument for state
13557 instead of globals.
13558 (grub_script_lexer_deref): Likewise.
13559 (grub_script_lexer_record_start): Likewise.
13560 (grub_script_lexer_record_stop): Likewise.
13561 (recordchar): Likewise.
13562 (nextchar): Likewise.
13563 (grub_script_yylex2): Likewise.
13564 (grub_script_yylex): Likewise.
13565 (grub_script_yyerror): Likewise.
13567 * normal/parser.y (func_mem): Removed variable.
13568 (menu_entry): Likewise.
13570 (%lex-param): New parser option.
13571 (%parse-param): Likewise.
13572 (script): Always return the AST.
13573 (argument): Pass the state around.
13574 (arguments): Likewise.
13575 (grubcmd): Likewise.
13576 (commands): Likewise.
13577 (function): Likewise.
13578 (menuentry): Likewise.
13579 (if_statement): Likewise.
13582 * normal/script.c (grub_script_memused): Removed variable.
13583 (grub_script_parsed): Likewise.
13584 (grub_script_malloc): Added a state argument. Use that instead of
13586 (grub_script_mem_record): Likewise.
13587 (grub_script_mem_record_stop): Likewise.
13588 (grub_script_arg_add): Likewise.
13589 (grub_script_add_arglist): Likewise.
13590 (grub_script_create_cmdline): Likewise.
13591 (grub_script_create_cmdif): Likewise.
13592 (grub_script_create_cmdmenu): Likewise.
13593 (grub_script_add_cmd): Likewise.
13594 (grub_script_parse): Setup the state before calling the parser.
13596 2006-04-16 Marco Gerards <marco@gnu.org>
13598 * normal/command.c (grub_command_init): Remove the title command.
13600 * normal/lexer.c (grub_script_yylex): Renamed from this...
13601 (grub_script_yylex2): ... to this.
13602 (grub_script_yylex): New function. Temporary
13603 introduced to filter some tokens.
13604 (grub_script_yyerror): Print a newline.
13606 * normal/main.c (read_config_file): Output information about the
13607 lines that contain errors. Wait for a key after all lines have
13608 been processed. Don't return an empty menu.
13610 * normal/parser.y (func_mem): Don't initialize.
13611 (menu_entry): Likewise.
13612 (err): New variable.
13613 (script): Don't return anything when an error was encountered.
13614 (ws, returns): Removed rules.
13615 (argument): Disabled concatenated variable support.
13616 (arguments): Remove explicit separators.
13617 (grubcmd): Likewise.
13618 (function): Likewise.
13619 (menuentry): Likewise.
13621 (commands): Likewise. Add error handling.
13623 * normal/script.c (grub_script_create_cmdline): If
13624 `grub_script_parsed' is 0, assume the parser encountered an error.
13626 2006-04-02 Yoshinori K. Okuji <okuji@enbug.org>
13628 * configure.ac: Add support for EFI. Fix the typo
13629 BUILD_LDDFLAGS. Restore the LDFLAGS after testing.
13631 2006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
13633 * util/unifont2pff.rb: Removed unnecessary byte ordering. Now
13634 foreign multibyte characters should be shown correctly.
13636 2006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
13638 * normal/main.c (grub_normal_menu_addentry): Fixed menu size
13640 (read_config_file): Made it to close file before returning.
13642 2006-03-31 Vesa Jaaskelainen <chaac@nic.fi>
13644 * DISTLIST: Added include/grub/i386/pc/vbeblit.h,
13645 include/grub/i386/pc/vbefill.h, video/i386/pc/vbeblit.c,
13646 video/i386/pc/vbefill.c.
13648 * conf/i386-pc.rmk (vbe_mod_SOURCES): Added video/i386/pc/vbeblit.c,
13649 video/i386/pc/vbefill.c.
13651 * include/grub/video.h (grub_video_blit_format): New enum.
13652 (grub_video_mode_info): Added new member blit_format.
13653 (grub_video_get_blit_format): New function prototype.
13655 * include/grub/i386/pc/vbe.h (grub_video_vbe_get_video_ptr): New
13656 function prototype.
13657 (grub_video_vbe_map_rgb): Likewise.
13658 (grub_video_vbe_unmap_color): Likewise.
13660 * include/grub/i386/pc/vbeblit.h: New file.
13662 * include/grub/i386/pc/vbefill.h: New file.
13664 * video/video.c (grub_video_get_blit_format): New function.
13665 (grub_video_vbe_get_video_ptr): Re-declared as non-static.
13666 (grub_video_vbe_map_rgb): Likewise.
13667 (grub_video_vbe_unmap_color): Likewise.
13669 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Changed to use more
13671 (grub_video_vbe_blit_render_target): Changed to use more optimized
13673 (grub_video_vbe_setup): Added detection for optimized settings.
13674 (grub_video_vbe_create_render_target): Likewise.
13676 * video/i386/pc/vbeblit.c: New file.
13678 * video/i386/pc/vbefill.c: New file.
13680 2006-03-30 Vesa Jaaskelainen <chaac@nic.fi>
13682 * font/manager.c (grub_font_get_glyph): Removed font fixup from
13685 * util/unifont2pff.rb: ... and moved it to here. Improved argument
13686 parsing to support both hex and dec ranges. If filename was missing
13687 show usage information.
13689 2006-03-14 Vesa Jaaskelainen <chaac@nic.fi>
13691 * DISTLIST: Added include/grub/video.h, term/gfxterm.c,
13692 video/video.c, commands/videotest.c. Removed term/i386/pc/vesafb.c.
13694 * conf/i386-pc.rmk (pkgdata_MODULES): Added video.mod,
13695 gfxterm.mod, videotest.mod. Removed vga.mod, vesafb.mod.
13696 (video_mod_SOURCES): Added.
13697 (video_mod_CFLAGS): Likewise.
13698 (video_mod_LDFLAGS): Likewise.
13699 (gfxterm_mod_SOURCES): Likewise.
13700 (gfxterm_mod_CFLAGS): Likewise.
13701 (gfxterm_mod_LDFLAGS): Likewise.
13702 (videotest_mod_SOURCES): Likewise.
13703 (videotest_mod_CFLAGS): Likewise.
13704 (videotest_mod_LDFLAGS): Likewise.
13705 (vesafb_mod_SOURCES): Removed.
13706 (vesafb_mod_CFLAGS): Likewise.
13707 (vesafb_mod_LDFLAGS): Likewise.
13708 (vga_mod_SOURCES): Likewise.
13709 (vga_mod_CFLAGS): Likewise.
13710 (vga_mod_LDFLAGS): Likewise.
13712 * commands/videotest.c: New file.
13714 * font/manager.c (fill_with_default_glyph): Modified to use
13716 (grub_font_get_glyph): Likewise.
13717 (fontmanager): Renamed from this...
13718 (font_manager): ... to this.
13720 * include/grub/font.h (grub_font_glyph): Added new structure.
13721 (grub_font_get_glyph): Modified to use grub_font_glyph.
13723 * include/grub/misc.h (grub_abs): Added as inline function.
13725 * include/grub/video.h: New file.
13727 * include/grub/i386/pc/vbe.h (GRUB_VBE_STATUS_OK): New macro.
13728 (GRUB_VBE_MEMORY_MODEL_PACKED_PIXEL): Likewise.
13729 (GRUB_VBE_MEMORY_MODEL_DIRECT_COLOR): Likewise.
13730 (grub_vbe_get_controller_info): Renamed from this...
13731 (grub_vbe_bios_get_controller_info): ... to this.
13732 (grub_vbe_get_mode_info): Renamed from this...
13733 (grub_vbe_bios_get_mode_info): ... to this.
13734 (grub_vbe_set_mode): Renamed from this...
13735 (grub_vbe_bios_set_mode): ... to this.
13736 (grub_vbe_get_mode): Renamed from this...
13737 (grub_vbe_bios_get_mode): ... to this.
13738 (grub_vbe_set_memory_window): Renamed from this...
13739 (grub_vbe_bios_set_memory_window): ... to this.
13740 (grub_vbe_get_memory_window): Renamed from this...
13741 (grub_vbe_bios_get_memory_window): ... to this.
13742 (grub_vbe_set_scanline_length): Renamed from this...
13743 (grub_vbe_set_scanline_length): ... to this.
13744 (grub_vbe_get_scanline_length): Renamed from this...
13745 (grub_vbe_bios_get_scanline_length): ... to this.
13746 (grub_vbe_set_display_start): Renamed from this...
13747 (grub_vbe_bios_set_display_start): ... to this.
13748 (grub_vbe_get_display_start): Renamed from this...
13749 (grub_vbe_bios_get_display_start): ... to this.
13750 (grub_vbe_set_palette_data): Renamed from this...
13751 (grub_vbe_bios_set_palette_data): ... to this.
13752 (grub_vbe_set_pixel_rgb): Removed.
13753 (grub_vbe_set_pixel_index): Likewise.
13755 * kern/i386/pc/startup.S (grub_vbe_get_controller_info): Renamed
13757 (grub_vbe_bios_get_controller_info): ... to this.
13758 (grub_vbe_get_mode_info): Renamed from this...
13759 (grub_vbe_bios_get_mode_info): ... to this.
13760 (grub_vbe_set_mode): Renamed from this...
13761 (grub_vbe_bios_set_mode): ... to this.
13762 (grub_vbe_get_mode): Renamed from this...
13763 (grub_vbe_bios_get_mode): ... to this.
13764 (grub_vbe_set_memory_window): Renamed from this...
13765 (grub_vbe_bios_set_memory_window): ... to this.
13766 (grub_vbe_get_memory_window): Renamed from this...
13767 (grub_vbe_bios_get_memory_window): ... to this.
13768 (grub_vbe_set_scanline_length): Renamed from this...
13769 (grub_vbe_set_scanline_length): ... to this.
13770 (grub_vbe_get_scanline_length): Renamed from this...
13771 (grub_vbe_bios_get_scanline_length): ... to this.
13772 (grub_vbe_set_display_start): Renamed from this...
13773 (grub_vbe_bios_set_display_start): ... to this.
13774 (grub_vbe_get_display_start): Renamed from this...
13775 (grub_vbe_bios_get_display_start): ... to this.
13776 (grub_vbe_set_palette_data): Renamed from this...
13777 (grub_vbe_bios_set_palette_data): ... to this.
13778 (grub_vbe_bios_get_controller_info): Fixed problem with registers
13779 getting corrupted after calling it. Added more pushes and pops.
13780 (grub_vbe_bios_set_mode): Likewise.
13781 (grub_vbe_bios_get_mode): Likewise.
13782 (grub_vbe_bios_get_memory_window): Likewise.
13783 (grub_vbe_bios_set_scanline_length): Likewise.
13784 (grub_vbe_bios_get_scanline_length): Likewise.
13785 (grub_vbe_bios_get_display_start): Likewise.
13786 (grub_vbe_bios_set_palette_data): Likewise.
13788 * normal/cmdline.c (cl_set_pos): Refresh the screen.
13789 (cl_insert): Likewise.
13790 (cl_delete): Likewise.
13792 * term/gfxterm.c: New file.
13794 * term/i386/pc/vesafb.c: Removed file.
13796 * video/video.c: New file.
13798 * video/i386/pc/vbe.c (real2pm): Added new function.
13799 (grub_video_vbe_draw_pixel): Likewise.
13800 (grub_video_vbe_get_video_ptr): Likewise.
13801 (grub_video_vbe_get_pixel): Likewise
13802 (grub_video_vbe_init): Likewise.
13803 (grub_video_vbe_fini): Likewise.
13804 (grub_video_vbe_setup): Likewise.
13805 (grub_video_vbe_get_info): Likewise.
13806 (grub_video_vbe_set_palette): Likewise.
13807 (grub_video_vbe_get_palette): Likewise.
13808 (grub_video_vbe_set_viewport): Likewise.
13809 (grub_video_vbe_get_viewport): Likewise.
13810 (grub_video_vbe_map_color): Likewise.
13811 (grub_video_vbe_map_rgb): Likewise.
13812 (grub_video_vbe_map_rgba): Likewise.
13813 (grub_video_vbe_unmap_color): Likewise.
13814 (grub_video_vbe_fill_rect): Likewise.
13815 (grub_video_vbe_blit_glyph): Likewise.
13816 (grub_video_vbe_blit_bitmap): Likewise.
13817 (grub_video_vbe_blit_render_target): Likewise.
13818 (grub_video_vbe_scroll): Likewise.
13819 (grub_video_vbe_swap_buffers): Likewise.
13820 (grub_video_vbe_create_render_target): Likewise.
13821 (grub_video_vbe_delete_render_target): Likewise.
13822 (grub_video_vbe_set_active_render_target): Likewise.
13823 (grub_vbe_set_pixel_rgb): Remove function.
13824 (grub_vbe_set_pixel_index): Likewise.
13825 (index_color_mode): Remove static variable.
13826 (active_mode): Likewise.
13827 (framebuffer): Likewise.
13828 (bytes_per_scan_line): Likewise.
13829 (grub_video_vbe_adapter): Added new static variable.
13830 (framebuffer): Likewise.
13831 (render_target): Likewise.
13832 (initial_mode): Likewise.
13833 (mode_in_use): Likewise.
13834 (mode_list): Likewise.
13836 2006-03-10 Marco Gerards <marco@gnu.org>
13838 * configure.ac (AC_INIT): Bumped to 1.93.
13840 * DISTLIST: Added `include/grub/hfs.h'.
13842 2006-02-01 Yoshinori K. Okuji <okuji@enbug.org>
13844 * boot/i386/pc/boot.S (general_error): Before looping, try INT
13845 18H, which might help the BIOS falling back to next boot media.
13847 2006-01-25 Yoshinori K. Okuji <okuji@enbug.org>
13849 * util/i386/pc/grub-install.in: Escape a backslash. Reported by
13850 Poe Chen <poe.poechen@gmail.com>.
13852 2006-01-17 Marco Gerards <marco@gnu.org>
13854 * include/grub/normal.h: Include <grub/script.h>.
13855 (grub_command_list): Removed struct.
13856 (grub_command_list_t): Removed type.
13857 (grub_menu_entry): Remove members `num' and `command_list'. Add
13858 members `commands' and `sourcecode'.
13859 * include/grub/script.h: Add inclusion guards.
13860 (grub_script_cmd_menuentry): New struct.
13861 (grub_script_execute_menuentry): New prototype.
13862 (grub_script_lexer_record_start): Likewise.
13863 (grub_script_lexer_record_stop): Likewise.
13864 * normal/execute.c (grub_script_execute_menuentry): New function.
13865 * normal/lexer.c (record, recording, recordpos, recordlen): New
13867 (grub_script_lexer_record_start): New function.
13868 (grub_script_lexer_record_stop): Likewise.
13869 (recordchar): Likewise.
13870 (nextchar): Likewise.
13871 (grub_script_yylex): Use `nextchar' to fetch new characters. Use
13872 2048 as the buffer size. Add the tokens `menuentry' and `@'.
13873 * normal/main.c: Include <grub/parser.h> and <grub/script.h>
13874 (current_menu): New variable.
13875 (free_menu): Mainly rewritten.
13876 (grub_normal_menu_addentry): New function.
13877 (read_config_file): Rewritten.
13878 * normal/menu.c (run_menu_entry): Mainly rewritten.
13879 * normal/menu_entry.c (make_screen): Rewritten the code to insert
13881 (run): Mainly rewritten.
13882 * normal/parser.y (menu_entry): New variable.
13883 (GRUB_PARSER_TOKEN_MENUENTRY): New token.
13884 (menuentry): New rule.
13885 (command): Add `menuentry'.
13886 (if_statement): Allow additional returns before `fi'.
13887 * normal/script.c (grub_script_create_cmdmenu): New function.
13889 2006-01-03 Marco Gerards <marco@gnu.org>
13891 * INSTALL: GNU Bison is required.
13892 * configure.ac: Rewritten the test to detect Bison.
13893 * Makefile.in (YACC): New variable. Reported by Xun Sun
13894 <xun.sun.cn@gmail.com>.
13896 2006-01-03 Marco Gerards <marco@gnu.org>
13898 * fs/hfsplus.c (grub_hfsplus_read_block): Convert the offset of
13899 the HFS+ filesystem to filesystem blocks.
13900 (grub_hfsplus_iterate_dir): Cast the `fileinfo' assignment so a
13901 GCC warning is silenced.
13903 2006-01-03 Marco Gerards <marco@gnu.org>
13905 * partmap/apple.c (apple_partition_map_iterate): Convert the data
13906 read from disk from big endian to host byte order.
13908 2006-01-03 Hollis Blanchard <hollis@penguinppc.org>
13910 * fs/hfs.c: Include <grub/hfs.h>. Added reference to the official
13912 (GRUB_HFS_EMBED_HFSPLUS_SIG): New macro.
13913 (grub_hfs_mount): Grammar fix in error. Make sure this is not an
13914 embedded HFS+ filesystem.
13915 (GRUB_HFS_MAGIC, grub_hfs_extent, grub_hfs_datarecord_t)
13916 (grub_hfs_sblock): Move from here...
13917 * include/grub/hfs.h: To here... New file.
13918 * fs/hfsplus.c: Include <grub/hfs.h>. Added reference to the official
13920 (GRUB_HFSPLUS_MAGIC, GRUB_HFSPLUSX_MAGIC, GRUB_HFSPLUS_SBLOCK):
13922 (grub_hfsplus_volheader): Change type of member `magic' to
13924 (grub_hfsplus_data): Add new member `embedded_offset'.
13925 (grub_hfsplus_read_block): Add the HFS+ wrapper offset to the
13927 (grub_hfsplus_mount): Read the HFS+ wrapper if it exists.
13928 Calculate the offset.
13930 2005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
13932 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRP_ADDR):
13934 (GRUB_BOOT_MACHINE_DRP_SIZE): Likewise.
13936 2005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
13938 * kern/env.c (grub_env_set): Check if ENV->VALUE instead of
13939 ENV->NAME is NULL after allocating ENV->VALUE.
13941 2005-12-25 Marco Gerards <marco@gnu.org>
13943 * kern/env.c (grub_env_set): Rewritten the error handling code.
13945 2005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
13947 * geninit.sh: Made more robust, and more portable.
13949 2005-12-25 Marco Gerards <marco@gnu.org>
13951 Add support for Apple HFS+ filesystems.
13953 * fs/hfsplus.c: New file.
13955 * DISTLIST: Added `fs/hfsplus.c'.
13957 * conf/common.rmk (pkgdata_MODULES): Add `hfsplus.mod'.
13958 (hfsplus_mod_SOURCES): New variable.
13959 (hfsplus_mod_CFLAGS): Likewise.
13960 (hfsplus_mod_LDFLAGS): Likewise.
13961 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/hfsplus.c'.
13962 (grub_setup_SOURCES): Likewise.
13963 (grub_mkdevicemap_SOURCES): Likewise.
13964 (grub_emu_SOURCES): Likewise.
13965 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
13967 * fs/fshelp.c (grub_fshelp_log2blksize): New function.
13969 * include/grub/fshelp.h (grub_fshelp_log2blksize): new prototype.
13971 2005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
13973 * DISTLIST: Added geninitheader.sh, geninit.sh, commands/test.c,
13974 commands/i386/pc/play.c, conf/common.mk, conf/common.rmk,
13975 include/grub/parser.h, include/grub/script.h, kern/parser.c,
13976 kern/sparc64/cache.S, normal/execute.c, normal/function.c,
13977 normal/lexer.c, normal/parser.y, normal/script.c, and
13979 Removed kern/sparc64/cache.c.
13981 * conf/common.rmk (DISTCLEANFILES): Added grub_script.tab.c,
13982 grub_script.tab.h, grub_modules_init.lst, grub_modules_init.h,
13985 * configure.ac (AC_INIT): Bumped to 1.92.
13987 2005-12-24 Vesa Jaaskelainen <chaac@nic.fi>
13989 * kern/err.c (grub_error_push): Added new function to support error
13991 (grub_error_pop): Likewise.
13992 (grub_error_stack_items): New local variable to support error stacks.
13993 (grub_error_stack_pos): Likewise.
13994 (grub_error_stack_assert): Likewise.
13995 (GRUB_ERROR_STACK_SIZE): Added new define to configure maximum error
13997 (grub_print_error): Added support to print errors from error stack.
13999 * include/grub/err.h (grub_error_push): Added function prototype.
14000 (grub_error_pop): Likewise.
14002 2005-12-09 Hollis Blanchard <hollis@penguinppc.org>
14004 * configure.ac: Accept `powerpc64' as host_cpu.
14005 (amd64): Rename to `biarch32'.
14007 * kern/powerpc/cache.S (grub_arch_sync_caches): Handle
14008 non-cacheline-aligned addresses.
14010 * kern/dl.c (grub_dl_load_core): Add grub_dprintf messages.
14011 (grub_dl_flush_cache): Likewise. Only call `grub_arch_sync_caches'
14012 if `size' is non-zero.
14014 2005-12-03 Marco Gerards <mgerards@xs4all.nl>
14016 * conf/common.rmk (grub_modules_init.lst): Use `-printf "%P\n"'
14017 and `cd' to make sure the filename is not prefixed with a
14019 (pkgdata_MODULES): Add `gpt.mod'.
14020 (gpt_mod_SOURCES): New variable.
14021 (gpt_mod_CFLAGS): Likewise.
14022 (gpt_mod_LDFLAGS): Likewise.
14024 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/gpt.c'.
14026 * include/grub/pc_partition.h (GRUB_PC_PARTITION_TYPE_GPT_DISK):
14029 * partmap/gpt.c: New file.
14031 * partmap/pc.c (pc_partition_map_iterate): Don't continue when a
14032 GPT partition map is detected.
14034 2005-12-03 Vincent Pelletier <subdino2004@yahoo.fr>
14036 * commands/i386/pc/play.c: New file.
14037 * conf/i386-pc.rmk (pkgdata_MODULES): Added play.mod.
14038 (play_mod_SOURCES, play_mod_CFLAGS, play_mod_LDFLAGS): New
14041 2005-11-27 Marco Gerards <mgerards@xs4all.nl>
14043 * include/grub/dl.h (GRUB_MOD_INIT): Use `__attribute__
14044 ((unused))' to silence gcc warning.
14046 2005-11-26 Hollis Blanchard <hollis@penguinppc.org>
14048 * configure.ac: Correct `AC_PROG_YACC' test.
14050 2005-11-22 Hollis Blanchard <hollis@penguinppc.org>
14052 * util/powerpc/ieee1275/grub-install.in: Run the mount point
14053 check before installing files.
14055 2005-11-22 Mike Small <smallm@panix.com>
14057 * util/powerpc/ieee1275/grub-install.in (grubdir): Fixed partition
14058 number regex so multidigit numbers are recognized correctly.
14060 2005-11-22 Mike Small <smallm@panix.com>
14062 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Add a
14063 debugging message before attempting to claim memory.
14064 (grub_rescue_cmd_initrd): Add a claim debugging message and try
14065 multiple addresses in case of failure.
14067 2005-11-22 Hollis Blanchard <hollis@penguinppc.org>
14069 * term/tparm.c (get_space): Remove empty `if' statement.
14071 * fs/ufs.c (grub_ufs_find_file): Remove `grub_le_to_cpu32'.
14073 * kern/parser.c (check_varstate): Rename `state' to 's'.
14075 2005-11-22 Hollis Blanchard <hollis@penguinppc.org>
14077 * partmap/acorn.c: Change `unsigned' to `unsigned int'. Move all
14078 variable definitions to the beginning of each function. Sort stack
14080 (find): Rename to `acorn_partition_map_find'. Cast `grub_disk_read'
14081 `buf' argument to `char *'.
14083 2005-11-22 Hollis Blanchard <hollis@penguinppc.org>
14085 * conf/powerpc-ieee1275.rmk: Include conf/common.mk.
14086 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
14087 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
14088 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
14089 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
14090 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
14091 configfile.mod, search.mod, gzio.mod and test.mod.
14092 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
14093 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
14094 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
14095 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
14096 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
14097 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
14098 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
14099 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
14100 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
14101 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
14102 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
14103 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
14104 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
14105 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
14106 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
14107 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
14108 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
14109 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
14110 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
14111 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
14112 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
14113 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
14114 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Removed.
14116 * conf/common.mk (grub_modules_init.lst): Use `find' instead of
14118 (pkgdata_MODULES): Add test.mod.
14120 2005-11-18 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
14122 * genmk.rb: Fixed list rules moved to Makefile.in. Recognise
14123 appending to variables with "+=".
14124 (PModule): Use full pathname to generate *.lst filenames.
14126 * Makefile.in: Fixed list rules moved from genmk.rb.
14127 (.DELETE_ON_ERROR): New special target.
14128 (RMKFILES): Add common.rmk and sparc64-ieee1275.rmk.
14130 * conf/i386-pc.rmk: Include conf/common.mk.
14131 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
14132 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
14133 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
14134 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
14135 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
14136 configfile.mod, search.mod, gzio.mod and test.mod.
14137 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
14138 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
14139 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
14140 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
14141 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
14142 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
14143 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
14144 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
14145 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
14146 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
14147 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
14148 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
14149 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
14150 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
14151 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
14152 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
14153 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
14154 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
14155 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
14156 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
14157 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
14158 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
14159 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Move from
14161 * conf/common.rmk: ... to here. New file.
14163 * conf/common.mk: New file.
14165 2005-11-18 Yoshinori K. Okuji <okuji@enbug.org>
14167 * conf/powerpc-ieee1275.rmk (grub_script.tab.h): Unified to ...
14168 (grub_script.tab.c): ... here.
14170 * conf/sparc64-ieee1275.rmk (grub_script.tab.h): Unified to ...
14171 (grub_script.tab.c): ... here.
14173 * conf/i386-pc.rmk (grub_script.tab.h): Unified to ...
14174 (grub_script.tab.c): ... here.
14176 * normal/command.c (grub_command_find): Fixed a memory leak of
14177 MODULE_NAME. Reported by Mike Small <smallm@panix.com>.
14179 2005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
14181 * include/grub/symbol.h: (FUNCTION): Use double quotes instead of
14182 "@" which marks the start of a comment on ARM.
14183 (VARIABLE): Likewise.
14185 2005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
14187 Add support for Linux/ADFS partition tables.
14189 * partmap/acorn.c: New file.
14191 * include/grub/acorn_filecore.h: Likewise.
14193 * DISTLIST: Added `partmap/acorn.c' and
14194 `include/grub/acorn_filecore.h'.
14196 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
14198 (pkgdata_MODULES): Add `acorn.mod'.
14199 (acorn_mod_SOURCES): New variable.
14200 (acorn_mod_CFLAGS): Likewise.
14202 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
14204 (pkgdata_MODULES): Add `acorn.mod'.
14205 (acorn_mod_SOURCES): New variable.
14206 (acorn_mod_CFLAGS): Likewise.
14208 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/acorn.c'.
14209 (pkgdata_MODULES): Add `acorn.mod'.
14210 (acorn_mod_SOURCES): New variable.
14211 (acorn_mod_CFLAGS): Likewise.
14212 (acorn_mod_LDFLAGS): Likewise.
14214 * include/types.h (grub_disk_addr_t): New typedef.
14216 2005-11-13 Marco Gerards <mgerards@xs4all.nl>
14218 * geninit.sh: New file.
14220 * geninitheader.sh: Likewise.
14222 * commands/boot.c (grub_boot_init, grub_boot_fini): Removed.
14223 * commands/cat.c (grub_cat_init, grub_cat_fini): Likewise.
14224 * commands/cmp.c (grub_cmp_init, grub_cmp_fini): Likewise.
14225 * commands/configfile.c (grub_configfile_init)
14226 (grub_configfile_fini): Likewise.
14227 * commands/default.c (grub_default_init, grub_default_fini):
14229 * commands/help.c (grub_help_init, grub_help_fini): Likewise.
14230 * commands/ls.c (grub_ls_init, grub_ls_fini): Likewise.
14231 * commands/search.c (grub_search_init, grub_search_fini): Likewise.
14232 * commands/terminal.c (grub_terminal_init, grub_terminal_fini):
14234 * commands/test.c (grub_test_init, grub_test_fini): Likewise.
14235 * commands/timeout.c (grub_timeout_init, grub_timeout_fini):
14237 * commands/i386/pc/halt.c (grub_halt_init, grub_halt_fini): Likewise.
14238 * commands/ieee1275/halt.c (grub_halt_init, grub_halt_fini):
14240 * commands/i386/pc/reboot.c (grub_reboot_init, grub_reboot_fini):
14242 * commands/ieee1275/reboot.c (grub_reboot_init, grub_reboot_fini):
14244 * disk/loopback.c (grub_loop_init, grub_loop_fini): Likewise.
14245 * fs/affs.c (grub_affs_init, grub_affs_fini): Likewise.
14246 * fs/ext2.c (grub_ext2_init, grub_ext2_fini): Likewise.
14247 * fs/fat.c (grub_fat_init, grub_fat_fini): Likewise.
14248 * fs/hfs.c (grub_hfs_init, grub_hfs_fini): Likewise.
14249 * fs/iso9660.c (grub_iso9660_init, grub_iso9660_fini): Likewise.
14250 * fs/jfs.c (grub_jfs_init, grub_jfs_fini): Likewise.
14251 * fs/minix.c (grub_minix_init, grub_minix_fini): Likewise.
14252 * fs/sfs.c (grub_sfs_init, grub_sfs_fini): Likewise.
14253 * fs/ufs.c (grub_ufs_init, grub_ufs_fini): Likewise.
14254 * fs/xfs.c (grub_xfs_init, grub_xfs_fini): Likewise.
14255 * normal/main.c (grub_normal_init, grub_normal_fini): Likewise.
14256 * partmap/amiga.c (grub_amiga_partition_map_init)
14257 (grub_amiga_partition_map_fini): Likewise.
14258 * partmap/apple.c (grub_apple_partition_map_init)
14259 (grub_apple_partition_map_fini): Likewise.
14260 * partmap/pc.c (grub_pc_partition_map_init)
14261 (grub_pc_partition_map_fini): Likewise.
14262 * partmap/sun.c (grub_sun_partition_map_init,
14263 grub_sun_partition_map_fini): Likewise.
14264 * term/terminfo.c (grub_terminal_init, grub_terminal_fini):
14267 * util/grub-emu.c: Include <grub_modules_init.h>.
14268 (main): Don't initialize and de-initialize any modules directly,
14269 use `grub_init_all' and `grub_fini_all' instead.
14271 * term/i386/pc/vesafb.c (grub_vesafb_init): Renamed to
14272 `grub_vesafb_mod_init'.
14273 (grub_vesafb_fini): Renamed to `grub_vesafb_mod_fini'. Updated
14275 * term/i386/pc/vga.c (grub_vga_init): Renamed to
14276 `grub_vga_mod_init'. Updated all users.
14277 (grub_vga_fini): Renamed to `grub_vga_mod_fini'.
14279 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `grub_emu_init.c'.
14280 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c): New
14283 * include/grub/dl.h (GRUB_MOD_INIT): Add argument `name'.
14284 Generate a function to initialize the module in utilities.
14285 Updated all callers.
14286 (GRUB_MOD_FINI): Add argument `name'. Generate a function to
14287 initialize the module in utilities. Updated all callers.
14289 2005-11-09 Hollis Blanchard <hollis@penguinppc.org>
14291 * term/ieee1275/ofconsole.c (grub_ofconsole_cls): Use both the ANSI
14292 escape sequence and a literal ^L to clear the screen.
14294 * commands/ieee1275/suspend.c (grub_cmd_suspend): Clear the screen
14295 when returning from Open Firmware.
14297 2005-11-09 Hollis Blanchard <hollis@penguinppc.org>
14299 * term/ieee1275/ofconsole.c (grub_ofconsole_width): New variable.
14300 (grub_ofconsole_height): Likewise.
14301 (grub_ofconsole_putchar): If `grub_curr_x' exceeds console width,
14302 manually insert a '\n'.
14303 (grub_ofconsole_getwh): Set and return `grub_ofconsole_width' and
14304 `grub_ofconsole_height'. Return early if these are already set.
14306 2005-11-07 Vincent Pelletier <subdino2004@yahoo.fr>
14308 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
14309 `commands/test.c', `fs/affs.c', `fs/sfs.c', `fs/xfs.c',
14310 `normal/execute.c', `normal/lexer.c', `io/gzio.c',
14311 `kern/parser.c', `grub_script.tab.c', `normal/function.c'
14312 and `normal/script.c'.
14313 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
14314 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
14315 (test_mod_SOURCES): New variable.
14316 (test_mod_CFLAGS): Likewise.
14317 (test_mod_LDFLAGS): Likewise.
14318 (pkgdata_MODULES): Add `test.mod'.
14319 (grub_script.tab.c): New rule.
14320 (grub_script.tab.h): Likewise.
14322 2005-11-07 Marco Gerards <mgerards@xs4all.nl>
14324 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
14325 `commands/test.c', `normal/execute.c', `normal/lexer.c',
14326 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
14327 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
14328 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
14329 (test_mod_SOURCES): New variable.
14330 (test_mod_CFLAGS): Likewise.
14331 (pkgdata_MODULES): Add `test.mod'.
14332 (grub_script.tab.c): New rule.
14333 (grub_script.tab.h): Likewise.
14335 2005-11-06 Marco Gerards <mgerards@xs4all.nl>
14337 Add initial scripting support.
14339 * commands/test.c: New file.
14340 * include/grub/script.h: Likewise.
14341 * normal/execute.c: Likewise.
14342 * normal/function.c: Likewise.
14343 * normal/lexer.c: Likewise.
14344 * normal/parser.y: Likewise.
14345 * normal/script.c: Likewise.
14347 * configure.ac: Add `AC_PROG_YACC' test.
14349 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/test.c',
14350 `normal/execute.c', `normal/lexer.c', `grub_script.tab.c',
14351 `normal/function.c' and `normal/script.c'.
14352 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
14353 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
14354 (test_mod_SOURCES, test_mod_CFLAGS, test_mod_LDFLAGS): New
14356 (pkgdata_MODULES): Add `test.mod'.
14357 (grub_script.tab.c): New rule.
14358 (grub_script.tab.h): Likewise.
14360 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TEST_FAILURE'.
14362 * include/grub/normal.h (grub_test_init): New prototype.
14363 (grub_test_fini): Likewise.
14365 * normal/command.c: Include <grub/script.h>.
14366 (grub_command_execute): Rewritten.
14368 * util/grub-emu.c (main): Call `grub_test_init' and
14371 2005-11-03 Hollis Blanchard <hollis@penguinppc.org>
14373 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Initialize `msecs'
14375 * term/ieee1275/ofconsole.c (grub_ofconsole_checkkey): Return -1 if
14376 there are no pending characters.
14378 2005-11-03 Hollis Blanchard <hollis@penguinppc.org>
14380 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_get_devname): Use
14381 `grub_strndup' to drop device arguments. Replace unnecessary
14382 `grub_strndup' with `grub_strdup'.
14384 2005-11-03 Hollis Blanchard <hollis@penguinppc.org>
14386 * kern/term.c (grub_cls): Do not call grub_cur_term->cls() if the
14387 `debug' environment variable has been set.
14389 2005-11-02 Hollis Blanchard <hollis@penguinppc.org>
14391 * Makefile.in (install-local): Use $(DATA).
14392 (uninstall): Likewise.
14393 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Move grub-mkimage...
14394 (sbin_UTILITIES): ... to here.
14395 (sbin_SCRIPTS): New variable.
14396 (grub_install_SOURCES): New variable.
14397 * util/powerpc/ieee1275/grub-install.in: New file.
14398 * util/powerpc/ieee1275/grub-mkimage.c (kernel_path): Remove
14400 (add_segments): Call `grub_util_get_path'.
14402 2005-10-28 Yoshinori K. Okuji <okuji@enbug.org>
14404 From Timothy Baldwin:
14405 * commands/ls.c (grub_ls_list_files): Close FILE with
14407 * kern/misc.c (grub_vsprintf): Terminate the string S with NUL.
14409 2005-10-24 Marco Gerards <mgerards@xs4all.nl>
14411 * include/grub/parser.h: New file.
14413 * kern/parser.c: Likewise.
14415 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/parser.c'.
14416 (grub_setup_SOURCES): Likewise.
14417 (grub_probefs_SOURCES): Likewise.
14418 (grub_emu_SOURCES): Likewise.
14419 (kernel_img_HEADERS): Add `parser.h'.
14421 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
14422 (grub_emu_SOURCES): Add `kern/parser.c'.
14423 (grubof_SOURCES): Likewise.
14425 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
14426 (grubof_SOURCES): Add `kern/parser.c'.
14428 * include/grub/misc.h (grub_split_cmdline): Removed prototype.
14430 * kern/misc.c (grub_split_cmdline): Removed function.
14432 * kern/rescue.c: Include <grub/parser.h>.
14433 (grub_enter_rescue_mode): Use `grub_parser_split_cmdline' instead
14434 of `grub_split_cmdline'.
14436 * normal/command.c: Include <grub/parser.h>.
14437 (grub_command_execute): Use `grub_parser_split_cmdline' instead
14438 of `grub_split_cmdline'.
14440 * normal/completion.c: Include <grub/parser.h>.
14441 (cmdline_state): New variable.
14442 (iterate_dir): End the filename with a quote depending on the
14443 command line state.
14444 (get_state): new function.
14445 (grub_normal_do_completion): Use `grub_parser_split_cmdline' to
14446 split the arguments and determine the current argument. When the
14447 argument string is not quoted, escape all spaces.
14449 2005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
14451 * normal/sparc64/setjmp.S: New file.
14453 2005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
14455 * include/grub/sparc64/libgcc.h: New file.
14456 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Remove -Av9.
14457 (normal_mod_SOURCES): Use normal/sparc64/setjmp.S instead of
14458 normal/sparc64/setjmp.c.
14460 2005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
14462 * kern/sparc64/dl.c: Rewritten for SPARCV9 ELF.
14463 * kern/sparc64/cache.S: New file.
14464 * kern/sparc64/cache.c: Removed.
14465 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Add -Av9.
14466 (COMMON_CFLAGS): Add -mno-app-regs. Remove -mcpu=v9 and
14468 (COMMON_LDFLAGS): Add -melf64_sparc.
14469 (grubof_HEADERS): Add sparc64/libgcc.h and machine/kernel.h.
14470 (grubof_SOURCES): Use cache.S instead of cache.c.
14471 (grubof_LDFLAGS): Add -mno-app-regs. Replace "-Xlinker
14472 --oformat -Xlinker elf64-sparc" by "-Bstatic,-melf64_sparc".
14473 (pkgdata_MODULES): Uncomment. Leave linux.mod and _linux.mod
14475 (normal_mod_SOURCES): Add normal/completion.c and normal/misc.c.
14476 (_linux_mod_SOURCES, _linux_mod_CFLAGS, linux_mod_SOURCES)
14477 (linux_mod_CFLAGS): Commented out.
14478 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS): New macro, commented
14479 out because module isn't built.
14480 (fshelp_mod_LDFLAGS, fat_mod_LDFLAGS, ext2_mod_LDFLAGS)
14481 (ufs_mod_LDFLAGS, minix_mod_LDFLAGS, hfs_mod_LDFLAGS)
14482 (jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS, normal_mod_LDFLAGS)
14483 (hello_mod_LDFLAGS, boot_mod_LDFLAGS, terminal_mod_LDFLAGS)
14484 (ls_mod_LDFLAGS, cmp_mod_LDFLAGS, cat_mod_LDFLAGS)
14485 (font_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
14486 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
14487 (suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS)
14488 (help_mod_LDFLAGS, default_mod_LDFLAGS, timeout_mod_LDFLAGS)
14489 (configfile_mod_LDFLAGS, search_mod_LDFLAGS, xfs_mod_SOURCES)
14490 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
14491 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
14492 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, gzio_mod_SOURCES)
14493 (gzio_mod_CFLAGS, gzio_mod_LDFLAGS): New macro.
14495 2005-10-20 Yoshinori K. Okuji <okuji@enbug.org>
14497 * util/i386/pc/grub-probefs.c (main): Call grub_xfs_init and
14498 grub_xfs_fini. Do not call grub_hfs_init or grub_hfs_fini any
14499 longer, because HFS should not be used on PC.
14501 2005-10-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
14503 * io/gzio.c (grub_gzio_read): Use OFFSET instead of FILE->OFFSET
14504 consistently within the loop.
14506 2005-10-15 Marco Gerards <mgerards@xs4all.nl>
14508 * fs/xfs.c (grub_xfs_iterate_dir): Detect an error if part of a
14509 directory can not be read.
14511 2005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
14513 * configure.ac (AC_INIT): Increase the version number to 1.91.
14515 * DISTLIST: Added include/grub/terminfo.h, include/grub/tparm.h,
14516 include/grub/i386/pc/serial.h, term/terminfo.c, term/tparm.c and
14517 term/i386/pc/serial.c.
14519 2005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
14521 * kern/file.c (grub_file_seek): Seeking to an offset equal to a
14522 file size must be permitted.
14524 * kern/i386/pc/startup.S (multiboot_trampoline): Fix a mistake
14525 between %ah and %al.
14527 2005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
14529 * fs/xfs.c (grub_xfs_iterate_dir): Change the type of BLK to
14531 Call the hook with a NUL-terminated filename.
14532 (grub_xfs_mount): Use grub_be_to_cpu32 instead of
14535 * kern/term.c (cursor_state): New variable.
14536 (grub_term_set_current): Reset the cursor state on a new
14538 (grub_setcursor): Rewritten to use CURSOR_STATE.
14539 (grub_getcursor): New function.
14541 * include/grub/term.h (grub_getcursor): New prototype.
14543 * io/gzio.c (test_header): Align BUF for accessing it as 32-bit
14544 integers on ARM. Reported by Timothy Baldwin
14545 <T.E.Baldwin99@members.leeds.ac.uk>.
14547 2005-10-11 Marco Gerards <mgerards@xs4all.nl>
14549 * fs/sfs.c (grub_sfs_open): Don't free `data->label' if it is not
14551 (grub_sfs_dir): Likewise.
14553 2005-10-09 Marco Gerards <mgerards@xs4all.nl>
14555 Add support for the SFS filesystem.
14557 * fs/sfs.c: New file.
14559 * DISTLIST: Added `fs/sfs.c'.
14561 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/sfs.c'.
14562 (grub_probefs_SOURCES): Likewise.
14563 (grub_emu_SOURCES): Likewise.
14564 (pkgdata_MODULES): Add `sfs.mod'.
14565 (sfs_mod_SOURCES): New variable.
14566 (sfs_mod_CFLAGS): Likewise.
14567 (sfs_mod_LDFLAGS): Likewise.
14569 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/sfs.c'.
14570 (pkgdata_MODULES): Add `sfs.mod'.
14571 (sfs_mod_SOURCES): New variable.
14572 (sfs_mod_CFLAGS): Likewise.
14574 * util/grub-emu.c (main): Call `grub_sfs_init' and
14577 * include/grub/fs.h (grub_sfs_init): New prototype.
14578 (grub_sfs_fini): Likewise.
14580 2005-10-07 Marco Gerards <mgerards@xs4all.nl>
14582 Add support for the AFFS filesystem.
14584 * fs/affs.c: New file.
14586 * DISTLIST: Added `fs/affs.c'.
14588 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/affs.c'.
14589 (grub_probefs_SOURCES): Likewise.
14590 (grub_emu_SOURCES): Likewise.
14591 (pkgdata_MODULES): Add `affs.mod'.
14592 (affs_mod_SOURCES): New variable.
14593 (affs_mod_CFLAGS): Likewise.
14594 (affs_mod_LDFLAGS): Likewise.
14596 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/affs.c'.
14597 (pkgdata_MODULES): Add `affs.mod'.
14598 (affs_mod_SOURCES): New variable.
14599 (affs_mod_CFLAGS): Likewise.
14601 * util/grub-emu.c (main): Call `grub_affs_init' and
14604 * include/grub/fs.h (grub_affs_init): New prototype.
14605 (grub_affs_fini): Likewise.
14607 2005-10-01 Marco Gerards <mgerards@xs4all.nl>
14609 * fs/xfs.c (grub_xfs_iterate_dir): Add parentheses.
14611 2005-10-01 Marco Gerards <mgerards@xs4all.nl>
14613 * configure.ac: Accept `x86_64' as host_cpu. In that case add
14616 * genmk.rb (class PModule): Always use `$(#{prefix}_LDFLAGS)' when
14619 * conf/i386-pc.rmk (COMMON_CFLAGS): Add `-m32'.
14620 (COMMON_LDFLAGS): New variable.
14621 (kernel_img_LDFLAGS): Include `COMMON_FLAGS'.
14622 (_chain_mod_LDFLAGS, fshelp_mod_LDFLAGS, fat_mod_LDFLAGS)
14623 (ext2_mod_LDFLAGS, ufs_mod_LDFLAGS, minix_mod_LDFLAGS)
14624 (hfs_mod_LDFLAGS, jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS)
14625 (xfs_mod_LDFLAGS, _linux_mod_LDFLAGS, linux_mod_LDFLAGS)
14626 (normal_mod_LDFLAGS, hello_mod_LDFLAGS, boot_mod_LDFLAGS)
14627 (terminal_mod_LDFLAGS, ls_mod_LDFLAGS, cmp_mod_LDFLAGS)
14628 (cat_mod_LDFLAGS, help_mod_LDFLAGS, reboot_mod_LDFLAGS)
14629 (halt_mod_LDFLAGS, vga_mod_LDFLAGS, font_mod_LDFLAGS)
14630 (terminfo_mod_LDFLAGS, serial_mod_LDFLAGS, _multiboot_mod_LDFLAGS)
14631 (multiboot_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
14632 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
14633 (default_mod_LDFLAGS, timeout_mod_LDFLAGS, configfile_mod_LDFLAGS)
14634 (vbe_mod_LDFLAGS, vesafb_mod_LDFLAGS, vbeinfo_mod_LDFLAGS)
14635 (vbetest_mod_LDFLAGS, search_mod_LDFLAGS, gzio_mod_LDFLAGS): New
14637 (normal_mod_ASFLAGS): Add `-m32'.
14639 * include/grub/types.h (grub_host_addr_t, grub_host_off_t)
14640 (grub_host_size_t, grub_host_ssize_t): New types.
14641 (grub_addr_t, grub_off_t, grub_size_t, grub_ssize_t): Make type
14642 dependent of `GRUB_CPU_SIZEOF_VOID_P' instead on
14643 `GRUB_HOST_SIZEOF_VOID_P'.
14645 * include/grub/kernel.h (struct grub_module_header): Type of
14646 member offset changed to `grub_host_off_t'. Type of member size
14647 changed to `grub_host_size_t'.
14648 (struct grub_module_info): Type of member offset changed to
14649 `grub_host_off_t'. Type of member size changed to
14650 `grub_host_size_t'.
14652 2005-09-29 Yoshinori K. Okuji <okuji@enbug.org>
14654 Make GRUB's kernel compliant to Multiboot Specification.
14656 * kern/i386/pc/startup.S (multiboot_header): New label.
14657 (multiboot_entry): Likewise.
14658 (multiboot_trampoline): Likewise.
14660 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
14661 Increased to 0x4A0.
14663 * fs/xfs.c (grub_xfs_iterate_dir): Fix a syntax error. You may not
14664 put parentheses after a question mark.
14665 [!GRUB_UTIL] (my_mod): New variable.
14667 * util/grub-emu.c (main): Call grub_xfs_init and grub_xfs_fini.
14669 2005-09-28 Marco Gerards <mgerards@xs4all.nl>
14671 Adds support for the XFS filesystem. Btrees are not supported
14674 * fs/xfs.c: New file.
14676 * DISTLIST: Added `fs/xfs.c'.
14678 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/xfs.c'.
14679 (grub_probefs_SOURCES): Likewise.
14680 (grub_emu_SOURCES): Likewise.
14681 (pkgdata_MODULES): Add `xfs.mod'.
14682 (xfs_mod_SOURCES): New variable.
14683 (xfs_mod_CFLAGS): Likewise.
14685 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/xfs.c'.
14686 (pkgdata_MODULES): Add `xfs.mod'.
14687 (xfs_mod_SOURCES): New variable.
14688 (xfs_mod_CFLAGS): Likewise.
14690 * util/grub-emu.c (main): Call `grub_xfs_init' and
14693 * include/grub/fs.h (grub_xfs_init): New prototype.
14694 (grub_xfs_fini): Likewise.
14697 2005-09-18 Vesa Jaaskelainen <chaac@nic.fi>
14699 * video/i386/pc/vbe.c (grub_vbe_set_video_mode): In indexed
14700 color modes, allow greater than 16 colors to be configured as
14703 2005-09-03 Yoshinori K. Okuji <okuji@enbug.org>
14705 * normal/completion.c (complete_arguments): Add the qualifier
14706 const into OPTIONS.
14708 From Omniflux <omniflux+lists@omniflux.com>:
14709 * include/grub/terminfo.h: New file.
14710 * include/grub/tparm.h: Likewise.
14711 * include/grub/i386/pc/serial.h: Likewise.
14712 * term/terminfo.c: Likewise.
14713 * term/tparm.c: Likewise.
14714 * term/i386/pc/serial.c: Likewise.
14715 * conf/i386-pc.rmk (pkgdata_MODULES): Added terminfo.mod and
14717 (terminfo_mod_SOURCES): New variable.
14718 (terminfo_mod_CFLAGS): Likewise.
14719 (serial_mod_SOURCES): Likewise.
14720 (serial_mod_CFLAGS): Likewise.
14722 2005-08-31 Yoshinori K. Okuji <okuji@enbug.org>
14724 * DISTLIST: Replaced boot/powerpc/ieee1275/crt0.S and
14725 boot/powerpc/ieee1275/cmain.c with kern/powerpc/ieee1275/crt0.S
14726 and kern/powerpc/ieee1275/cmain.c, respectively.
14728 * boot/powerpc/ieee1275/crt0.S: Moved to ...
14729 * kern/powerpc/ieee1275/crt0.S: ... here.
14731 * boot/powerpc/ieee1275/cmain.c: Moved to ...
14732 * kern/powerpc/ieee1275/cmain.c: ... here.
14734 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Use
14735 kern/powerpc/ieee1275/crt0.S and kern/powerpc/ieee1275/cmain.c
14736 instead of boot/powerpc/ieee1275/crt0.S and
14737 boot/powerpc/ieee1275/cmain.c, respectively.
14739 * boot/i386/pc/boot.S (lba_mode): Do not store the total number of
14740 sectors. It was not used anyway.
14742 2005-08-30 Hollis Blanchard <hollis@penguinppc.org>
14744 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): Fix
14745 `unused parameter' warning.
14747 2005-08-30 Hollis Blanchard <hollis@penguinppc.org>
14749 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): New
14751 (grub_ofconsole_term): Specify grub_ofconsole_getcharwidth as
14754 2005-08-28 Marco Gerards <metgerards@student.han.nl>
14756 * include/grub/normal.h (enum grub_completion_type): Added
14757 `GRUB_COMPLETION_TYPE_ARGUMENT'.
14759 * normal/cmdline.c (print_completion): Handle
14760 the `GRUB_COMPLETION_TYPE_ARGUMENT' type.
14761 * normal/menu_entry.c (store_completion): Likewise.
14763 * normal/completion.c (complete_arguments): New function.
14764 (grub_normal_do_completion): Call `complete_arguments' when the
14765 current words start with a dash.
14767 2005-08-27 Marco Gerards <metgerards@student.han.nl>
14769 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Fix typo (use
14770 `gzio.mod' instead of `io.mod').
14772 2005-08-22 Yoshinori K. Okuji <okuji@enbug.org>
14774 * gendistlist.sh (EXTRA_DISTFILES): Added genfslist.sh.
14775 (DISTDIRS): Added io and video.
14776 Rewrite the search routine to make an output consistently.
14778 * DISTLIST: Added conf/sparc64-ieee1275.mk,
14779 conf/sparc64-ieee1275.rmk, include/grub/gzio.h,
14780 include/grub/ieee1275/ieee1275.h, include/grub/ieee1275/ofdisk.h,
14781 io/gzio.c, kern/sparc64/cache.c, kern/sparc64/dl.c,
14782 kern/sparc64/ieee1275/init.c, kern/sparc64/ieee1275/openfw.c and
14783 util/powerpc/ieee1275/misc.c.
14785 * include/grub/gzio.h: New file.
14786 * io/gzio.c: Likewise.
14788 * kern/file.c (grub_file_close): Call grub_device_close only if
14789 FILE->DEVICE is not NULL.
14791 * include/grub/mm.h [!NULL] (NULL): New macro.
14793 * include/grub/err.h (GRUB_ERR_BAD_GZIP_DATA): New constant.
14795 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added io/gzip.c.
14796 (pkgdata_MODULES): Added gzio.mod.
14797 (gzio_mod_SOURCES): New variable.
14798 (gzio_mod_CFLAGS): Likewise.
14800 * conf/i386-pc.rmk (grub_emu_SOURCES): Added io/gzip.c.
14801 (pkgdata_MODULES): Added gzio.mod.
14802 (gzio_mod_SOURCES): New variable.
14803 (gzio_mod_CFLAGS): Likewise.
14805 * commands/cat.c: Include grub/gzio.h.
14806 (grub_cmd_cat): Use grub_gzfile_open instead of
14809 * commands/cmp.c: Include grub/gzio.h.
14810 (grub_cmd_cmp): Use grub_gzfile_open instead of
14813 * loader/i386/pc/multiboot.c: Include grub/gzio.h.
14814 (grub_rescue_cmd_multiboot): Use grub_gzfile_open instead of
14816 (grub_rescue_cmd_module): Likewise.
14818 2005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
14820 * conf/sparc64-ieee1275.rmk (grubof_SOURCES): The first file must be
14821 kern/sparc64/ieee1275/init.c because it contains _start.
14822 * conf/sparc64-ieee1275.mk: Generated from conf/sparc64-ieee1275.rmk.
14824 2005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
14826 * configure.ac: Add support for sparc64 host with ieee1275
14828 * configure: Generated from configure.ac.
14829 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Use grub_ssize_t
14831 (grub_ofdisk_read): Likewise.
14832 (grub_ofdisk_open): Use %p to print pointer values, and cast the
14833 pointers as (void *) to remove a warning.
14834 (grub_ofdisk_close): Likewise.
14835 (grub_ofdisk_read): Likewise.
14836 * kern/ieee1275/ieee1275.c (grub_ieee1275_exit): This never
14837 returns, so make it return void to remove a warning.
14838 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_exit):
14839 Corresponding prototype change.
14840 * kern/mm.c (grub_mm_init_region): Use %p to print pointer
14841 values, and cast the pointers as (void *) to remove a warning.
14842 (grub_mm_dump): Likewise.
14843 * conf/sparc64-ieee1275.mk: New file.
14844 * conf/sparc64-ieee1275.rmk: Likewise.
14845 * include/grub/sparc64/setjmp.h: Likewise.
14846 * include/grub/sparc64/types.h: Likewise.
14847 * include/grub/sparc64/ieee1275/console.h: Likewise.
14848 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
14849 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
14850 * include/grub/sparc64/ieee1275/time.h: Likewise.
14851 * kern/sparc64/cache.c: Likewise.
14852 * kern/sparc64/dl.c: Likewise.
14853 * kern/sparc64/ieee1275/init.c: Likewise.
14854 * kern/sparc64/ieee1275/openfw.c: Likewise.
14856 2005-08-21 Yoshinori K. Okuji <okuji@enbug.org>
14858 * util/console.c (grub_ncurses_putchar): If C is greater than
14859 0x7f, set C to a question mark.
14860 (grub_ncurses_getcharwidth): New function.
14861 (grub_ncurses_term): Specify grub_ncurses_getcharwidth as
14864 * normal/menu.c (print_entry): Made aware of Unicode. First,
14865 convert TITLE to UCS-4, and predict the cursor position by
14868 * include/grub/misc.h (grub_utf8_to_ucs4): Specify the qualifier
14870 * kern/misc.c (grub_utf16_to_utf8): Likewise.
14872 2005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
14874 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Specify
14875 the boot file by the option BOOT_IMAGE. Use grub_stpcpy instead of
14878 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Specify the boot
14879 file by the option BOOT_IMAGE. Use grub_stpcpy instead of
14880 grub_strcpy and grub_strlen. Take it into account that a space
14881 character is inserted as a delimiter.
14883 2005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
14885 * partmap/pc.c (pc_partition_map_iterate): Include the value of an
14886 invalid magic in the error.
14888 * commands/search.c: New file.
14890 * util/grub-emu.c (main): Call grub_search_init and
14893 * kern/rescue.c (grub_rescue_print_disks): Removed.
14894 (grub_rescue_print_devices): New function.
14895 (grub_rescue_cmd_ls): Use grub_device_iterate with
14896 grub_rescue_print_devices instead of grub_disk_dev_iterate with
14897 grub_rescue_print_disks.
14899 * kern/partition.c (grub_partition_iterate): Return the result of
14900 PARTMAP->ITERATE instead of GRUB_ERRNO.
14902 * kern/device.c: Include grub/partition.h.
14903 (grub_device_iterate): New function.
14905 * include/grub/partition.h (grub_partition_iterate): Return int
14906 instead of grub_err_t.
14908 * include/grub/normal.h [GRUB_UTIL] (grub_search_init): New
14910 [GRUB_UTIL] (grub_search_fini): Likewise.
14912 * include/grub/device.h (grub_device_iterate): New prototype.
14914 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
14916 (pkgdata_MODULES): Added search.mod.
14917 (search_mod_SOURCES): New variable.
14918 (search_mod_CFLAGS): Likewise.
14920 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/search.c.
14921 (pkgdata_MODULES): Added search.mod.
14922 (search_mod_SOURCES): New variable.
14923 (search_mod_CFLAGS): Likewise.
14925 * commands/ls.c (grub_ls_list_disks): Renamed to ...
14926 (grub_ls_list_devices): ... this, and use grub_device_iterate.
14927 All callers changed.
14929 * DISTLIST: Added commands/search.c.
14931 2005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
14933 * kern/term.c (grub_putchar): Use grub_utf8_to_ucs4 for the
14935 (grub_getcharwidth): New function.
14937 * kern/misc.c (grub_utf8_to_ucs4): New function.
14939 * include/grub/term.h (struct grub_term): Added a new member
14941 (grub_getcharwidth): New prototype.
14943 * include/grub/misc.h (grub_utf8_to_ucs4): New prototype.
14945 * term/i386/pc/console.c (map_char): New function. Segregated from
14946 grub_console_putchar.
14947 (grub_console_putchar): Use map_char.
14948 (grub_console_getcharwidth): New function.
14949 (grub_console_term): Specified grub_console_getcharwidth as
14952 * term/i386/pc/vga.c (grub_vga_getcharwidth): New function.
14953 (grub_vga_term): Specified grub_vga_getcharwidth as getcharwidth.
14955 * term/i386/pc/vesafb.c (grub_virtual_screen_setup): Return
14957 (grub_vesafb_init): Do not use RC. Instead, use GRUB_ERRNO. Rely
14958 on grub_strtoul completely.
14959 (write_char): Declare local variables in the beginning of the
14961 (grub_vesafb_getcharwidth): New function.
14962 (grub_vesafb_term): Specified grub_vesafb_getcharwidth as
14965 2005-08-19 Yoshinori K. Okuji <okuji@enbug.org>
14967 * DISTLIST: Replace commands/i386/pc/vbe_list_modes.c and
14968 commands/i386/pc/vbe_test.c with commands/i386/pc/vbeinfo.c and
14969 commands/i386/pc/vbetest.c.
14971 * video/i386/pc/vbe.c (grub_vbe_probe): If INFOBLOCK is not NULL,
14972 call grub_vbe_get_controller_info again, because the returned
14973 information is volatile.
14974 (grub_vbe_set_video_mode): Mostly rewritten.
14975 (grub_vbe_get_video_mode): Use grub_vbe_probe and use
14976 grub_vbe_status_t correctly.
14977 (grub_vbe_get_video_mode_info): Likewise.
14978 (grub_vbe_set_pixel_rgb): Use a switch statement rather than
14979 several if statements.
14981 * commands/i386/pc/vbe_list_modes.c: Renamed to ...
14982 * commands/i386/pc/vbeinfo.c: ... this.
14984 * commands/i386/pc/vbe_test.c: Renamed to ...
14985 * commands/i386/pc/vbetest.c: ... this.
14987 * commands/i386/pc/vbeinfo.c (grub_cmd_vbe_list_modes): Renamed to
14989 (grub_cmd_vbeinfo): ... this. Save video modes before
14990 iterating. Skip a video mode, if it is not available, not enough
14991 information is given or it is monochrome. Show the memory
14992 model. Leave the interpretation of MODEVAR to grub_strtoul
14994 (GRUB_MOD_INIT): Rename vbe_list_modes to vbeinfo.
14995 (GRUB_MOD_FINI): Likewise.
14997 * commands/i386/pc/vbetest.c (grub_cmd_vbe_test): Renamed to ...
14998 (grub_cmd_vbetest): ... this. Don't print unnecessarily. Use
14999 grub_err_t instead of grub_uint32_t. Don't use SPTR. Remove a
15000 duplicated grub_env_get. Leave the interpretation of MODEVAR to
15001 grub_strtoul completely.
15002 (real2pm): Removed.
15003 (GRUB_MOD_INIT): Rename vbe_test to vbetest.
15004 (GRUB_MOD_FINI): Likewise.
15006 * normal/misc.c: Include grub/mm.h.
15008 * conf/i386-pc.rmk (pkgdata_MODULES): Replaced vbe_test.mod and
15009 vbe_list_modes with vbetest.mod and vbeinfo.mod.
15010 (vbe_list_modes_mod_SOURCES): Removed.
15011 (vbe_list_modes_mod_CFLAGS): Likewise.
15012 (vbe_test_mod_SOURCES): Likewise.
15013 (vbe_test_mod_CFLAGS): Likewise.
15014 (vbeinfo_mod_SOURCES): New variable.
15015 (vbeinfo_mod_CFLAGS): Likewise.
15016 (vbetest_mod_SOURCES): Likewise.
15017 (vbetest_mod_CFLAGS): Likewise.
15019 2005-08-18 Yoshinori K. Okuji <okuji@enbug.org>
15021 * normal/misc.c: New file.
15023 * DISTLIST: Added normal/misc.c.
15025 * partmap/amiga.c (amiga_partition_map_iterate): Add an argument
15026 DISK to HOOK. Call HOOK with DISK.
15027 * partmap/apple.c (apple_partition_map_iterate): Likewise.
15028 * partmap/pc.c (pc_partition_map_iterate): Likewise.
15029 * partmap/sun.c (sun_partition_map_iterate): Likewise.
15031 * normal/menu_entry.c (struct screen): Added a new member
15032 "completion_shown".
15033 (completion_buffer): New global variable.
15034 (make_screen): Set SCREEN->COMPLETION_SHOWN to zero.
15035 (store_completion): New function.
15036 (complete): Likewise.
15037 (clear_completions): Likewise.
15038 (grub_menu_entry_run): If SCREEN->COMPLETION_SHOWN is non-zero,
15039 call clear_completions and reset SCREEN->COMPLETION_SHOWN. If C is
15040 a tab, call complete.
15042 * normal/completion.c (disk_dev): Removed.
15043 (print_simple_completion): Likewise.
15044 (print_partition_completion): Likewise.
15045 (print_func): New global variable.
15046 (add_completion): Do not take the arguments WHAT or PRINT any
15047 longer. Added a new argument TYPE. Instead of printing directly,
15048 call PRINT_FUNC if not NULL.
15049 All callers changed.
15050 (complete_device): Use a local variable DEV instead of
15051 DISK_DEV. Do not move CURRENT_WORD to the end of a device name.
15052 (grub_normal_do_completion): Take a new argument HOOK. Do not
15053 initialize DISK_DEV. Initialize PRINT_FUNC to HOOK. If RET is an
15054 empty string, return NULL instead.
15055 All callers changed.
15057 * normal/cmdline.c (print_completion): New function.
15059 * kern/partition.c (grub_partition_iterate): Add an argument DISK
15061 All callers changed.
15063 * kern/disk.c (grub_print_partinfo): Removed.
15065 * include/grub/partition.h (struct grub_partition_map): Add a new
15066 argument DISK into HOOK of ITERATE.
15067 (grub_partition_iterate): Add a new argument DISK to HOOK.
15069 * include/grub/normal.h (enum grub_completion_type): New enum.
15070 (grub_completion_type_t): New type.
15071 (GRUB_COMPLETION_TYPE_COMMAND): New constant.
15072 (GRUB_COMPLETION_TYPE_DEVICE): Likewise.
15073 (GRUB_COMPLETION_TYPE_PARTITION): Likewise.
15074 (GRUB_COMPLETION_TYPE_FILE): Likewise.
15075 (grub_normal_do_completion): Added a new argument HOOK.
15076 (grub_normal_print_device_info): New prototype.
15078 * include/grub/disk.h (grub_print_partinfo): Removed.
15080 * conf/i386-pc.rmk (grub_emu_SOURCES): Added normal/misc.c.
15081 (normal_mod_SOURCES): Likewise.
15082 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
15083 (normal_mod_SOURCES): Likewise.
15085 * commands/ls.c (grub_ls_list_disks): Use
15086 grub_normal_print_device_info instead of grub_print_partinfo. Free
15088 (grub_ls_list_files): Use grub_normal_print_device_info instead of
15089 duplicating the code.
15091 2005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
15093 * commands/i386/pc/vbe_list_modes.c: Update source formatting to
15094 follow GCS more precisely.
15095 * commands/i386/pc/vbe_test.c: Likewise.
15096 * include/grub/i386/pc/vbe.h: Likewise.
15097 * term/i386/pc/vesafb.c: Likewise.
15098 * video/i386/pc/vbe.c: Likewise.
15100 2005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
15102 * DISTLIST: Added term/i386/pc/vesafb.c
15103 DISTLIST: Added video/i386/pc/vbe.c
15104 DISTLIST: Added commands/i386/pc/vbe_list_modes.c.
15105 DISTLIST: Added commands/i386/pc/vbe_test.c.
15106 * commands/i386/pc/vbe_list_modes.c: New file.
15107 * commands/i386/pc/vbe_test.c: Likewise.
15108 * term/i386/pc/vesafb.c: Likewise.
15109 * video/i386/pc/vbe.c: Likewise.
15110 * include/grub/i386/pc/vbe.h (GRUB_VBE_DEFAULT_VIDEO_MODE): Added define.
15111 (grub_vbe_probe) Added prototype.
15112 (grub_vbe_set_video_mode) Likewise.
15113 (grub_vbe_get_video_mode) Likewise.
15114 (grub_vbe_get_video_mode_info) Likewise.
15115 (grub_vbe_set_pixel_rgb) Likewise.
15116 (grub_vbe_set_pixel_index) Likewise.
15117 * conf/i386-pc.rmk (pkgdata_MODULES): Added vbe.mod.
15118 (pkgdata_MODULES): Added vesafb.mod.
15119 (pkgdata_MODULES): Added vbe_list_modes.mod.
15120 (pkgdata_MODULES): Added vbe_test.mod.
15121 (vbe_mod_SOURCES): Added.
15122 (vbe_mod_CFLAGS): Likewise.
15123 (vesafb_mod_SOURCES): Likewise.
15124 (vesafb_mod_CFLAGS): Likewise.
15125 (vbe_list_modes_mod_SOURCES): Likewise.
15126 (vbe_list_modes_mod_CFLAGS): Likewise.
15127 (vbe_test_mod_SOURCES): Likewise.
15128 (vbe_test_mod_CFLAGS): Likewise.
15130 2005-08-14 Yoshinori K. Okuji <okuji@enbug.org>
15132 * normal/command.c (grub_command_execute): If INTERACTIVE is
15133 false and GRUB_COMMAND_FLAG_NO_ECHO is not specified, print
15134 CMDLINE. Disable the pager if INTERACTIVE is true.
15135 All callers are changed.
15137 * normal/main.c (grub_normal_execute): Read command.lst and fs.lst
15138 before reading a config file.
15139 * normal/main.c (read_config_file): Even if a command is not
15140 found, register it if it is within an entry.
15142 * util/grub-emu.c: Include sys/types.h and unistd.h.
15143 (options): Added --hold.
15144 (struct arguments): Added a new member "hold".
15145 (parse_opt): If KEY is 'H', set ARGS->HOLD to ARG or -1 if ARG is
15147 (main): Initialize ARGS.HOLD to zero. Wait until ARGS.HOLD is
15148 cleared by a debugger, if it is not zero.
15150 * include/grub/normal.h (grub_command_execute): Add an argument
15153 2005-08-14 Vesa Jaaskelainen <chaac@nic.fi>
15155 * DISTLIST: Added include/grub/i386/pc/vbe.h.
15157 2005-08-13 Yoshinori K. Okuji <okuji@enbug.org>
15159 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Replace the test
15160 program with another one, because the old one didn't detect a bug
15161 in gcc-3.4. Always use regparm 2, because the new test is still
15162 not enough for gcc-4.0. Someone must investigate a simple test
15163 case which detects a bug in gcc-4.0.
15165 2005-08-12 Yoshinori K. Okuji <okuji@enbug.org>
15167 * DISTLIST: Added normal/completion.c.
15169 * normal/completion.c: New file.
15171 * term/i386/pc/console.c (grub_console_getwh): New function.
15172 (grub_console_term): Assign grub_console_getwh to getwh.
15174 * normal/cmdline.c (grub_tab_complete): Removed. Now the same
15175 function is defined in normal/completion.c as
15176 grub_normal_do_completion.
15177 (grub_cmdline_get): Use grub_normal_do_completion instead of
15180 * kern/partition.c (grub_partition_map_iterate): Return 1 if HOOK
15181 returns non-zero, otherwise return 0.
15182 (grub_partition_iterate): First, probe the partition map. Then,
15183 call ITERATE only for this partition map.
15185 * kern/misc.c (grub_strncmp): Rewritten.
15187 * kern/disk.c (grub_disk_dev_iterate): Return 1 if P->ITERATE
15188 returns non-zero. Otherwise return 0.
15190 * include/grub/partition.h (grub_partition_map_iterate): Return
15191 int instead of void.
15193 * include/grub/normal.h (grub_normal_do_completion): New prototype.
15195 * include/grub/misc.h (grub_strncmp): Change the type of N to
15198 * include/grub/disk.h (grub_disk_dev_iterate): Return int instead
15201 * normal/menu.c (draw_border): Cast GRUB_TERM_BORDER_WIDTH to
15202 unsigned explicitly before comparing it with I.
15204 * kern/main.c (grub_env_write_root): Add the attribute unused into
15207 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
15208 normal/completion.c.
15209 (normal_mod_SOURCES): Likewise.
15210 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
15211 (normal_mod_SOURCES): Likewise.
15213 * normal/command.c (grub_iterate_commands): If ITERATE returns
15214 non-zero, return one immediately.
15216 2005-08-09 Vesa Jaaskelainen <chaac@nic.fi>
15218 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vbe.h.
15219 * kern/i386/pc/startup.S: Updated Global Descriptor table's
15221 (grub_vbe_get_controller_info): New function.
15222 (grub_vbe_get_mode_info): Likewise.
15223 (grub_vbe_set_mode): Likewise.
15224 (grub_vbe_get_mode): Likewise.
15225 (grub_vbe_set_memory_window): Likewise.
15226 (grub_vbe_get_memory_window): Likewise.
15227 (grub_vbe_set_scanline_length): Likewise.
15228 (grub_vbe_get_scanline_length): Likewise.
15229 (grub_vbe_set_display_start): Likewise.
15230 (grub_vbe_get_display_start): Likewise.
15231 (grub_vbe_set_palette_data): Likewise.
15232 * include/grub/i386/pc/vbe.h: New file.
15234 2005-08-08 Hollis Blanchard <hollis@penguinppc.org>
15236 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
15237 kern/ieee1275/of.c with kern/ieee1275/ieee1275.c.
15238 * DISTLIST: Likewise.
15239 * kern/ieee1275/of.c: Moved to ...
15240 * kern/ieee1275/ieee1275.c: ... here.
15242 2005-08-08 Hollis Blanchard <hollis@penguinppc.org>
15244 * term/ieee1275/ofconsole.c: Include <grub/mm.h>.
15245 (grub_ofconsole_getwh): Cast -1 to type grub_ieee1275_ihandle_t.
15246 Pass 0 as `end' parameter to grub_strtoul().
15248 2005-08-08 Hollis Blanchard <hollis@penguinppc.org>
15250 * include/grub/powerpc/ieee1275/console.h: Do not include
15251 <grub/types.h>. Do not include <grub/symbol.h>. Remove ASM_FILE
15253 (grub_console_cur_color): Remove i386-specific prototype.
15254 (grub_console_real_putchar): Likewise.
15255 (grub_console_checkkey): Likewise.
15256 (grub_console_getkey): Likewise.
15257 (grub_console_getxy): Likewise.
15258 (grub_console_gotoxy): Likewise.
15259 (grub_console_cls): Likewise.
15260 (grub_console_setcursor): Likewise.
15261 * kern/powerpc/ieee1275/init.c: Don't include <grub/console.h>.
15262 Include <grub/machine/console.h>.
15263 * term/ieee1275/ofconsole.c: Likewise.
15265 2005-08-08 Yoshinori K. Okuji <okuji@enbug.org>
15267 * Makefile.in (LIBLZO): New variable.
15269 * configure.ac: Check for LZO version 2.
15271 * util/i386/pc/grub-mkimage.c [HAVE_LZO_LZO1X_H]: Include
15272 lzo/lzo1x.h instead of lzo1x.h.
15274 * conf/i386-pc.rmk (grub_mkimage_LDFLAGS): Use $(LIBLZO) instead
15277 * util/i386/pc/grub-setup.c (main): Do not free PREFIX
15278 twice. Reported by Vladimir Serbinenko <phcoder@gmail.com>.
15280 * partmap/pc.c (pc_partition_map_probe): Restore P->DATA after
15281 copying the data from PARTITION to P.
15283 2005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
15285 * kern/rescue.c (grub_rescue_cmd_rmmod): If the reference count is
15286 negative, unload the module.
15288 * util/i386/pc/grub-setup.c (setup): The name of the PC partition
15289 map is "pc_partition_map" but not "pc".
15290 (usage): Fix the description. The options are --boot-image and
15291 --core-image but not --boot-file or --core-file.
15292 (main): If not specified explicitly, make BOOT_FILE and CORE_FILE
15293 based on DEFAULT_BOOT_FILE and DEFAULT_CORE_FILE with DIR or
15296 * util/i386/pc/grub-install.in: Do not specify --boot-file or
15297 --core-file. Specify INSTALL_DEVICE as an argument.
15299 * util/console.c: Include config.h.
15300 [HAVE_NCURSeS_CURSES_H]: Include ncurses/curses.h.
15301 [HAVE_NCURSES_H]: Include ncurses.h.
15302 [HAVE_CURSES_H]: Include curses.h.
15303 [!A_NORMAL] (A_NORMAL): Defined as zero.
15304 [!A_STANDOUT] (A_STANDOUT): Likewise.
15306 * conf/i386-pc.rmk (grub_emu_LDFLAGS): Use $(LIBCURSES) instead of
15308 * conf/powerpc-ieee1275.rmk (grub_emu_LDFLAGS): Likewise.
15310 * configure.ac: Check for curses libraries and headers.
15312 * Makefile.in (LIBCURSES): New variable.
15314 * genmk.rb (Script::rule): Set the executable bits.
15316 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): The
15317 name of the PC partition map is "pc_partition_map" but not "pc".
15319 2005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
15321 * util/i386/pc/grub-install.in (grub_probefs): New variable.
15322 (modules): Likewise.
15323 (usage): Added descriptions for --modules and --grub-probefs.
15324 Handle --modules and --grub-probefs. Save the arguments in MODULES
15325 and GRUB_PROBEFS, respectively.
15326 Auto-detect a filesystem module against GRUBDIR. If the result is
15327 empty and modules are not specified explicitly, abort the
15328 installation. Add the result to MODULES.
15330 * DISTLIST: Removed boot/powerpc/ieee1275/ieee1275.c,
15331 disk/powerpc/ieee1275/ofdisk.c,
15332 include/grub/powerpc/ieee1275/init.h and
15333 term/powerpc/ieee1275/ofconsole.c.
15334 Added disk/ieee1275/ofdisk.c, kern/ieee1275/of.c and
15335 term/ieee1275/ofconsole.c.
15337 * include/grub/powerpc/ieee1275/console.h: Resurrected.
15339 * COPYING: Upgraded to the latest version. Only the address of the
15340 FSF office has changed.
15342 2005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
15344 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
15345 kern/ieee1275.c with kern/ieee1275/of.c.
15347 * kern/ieee1275.c: Moved to ...
15348 * kern/ieee1275/of.c: ... here.
15350 2005-08-06 Yoshinori K. Okuji <okuji@enbug.org>
15352 * conf/i386-pc.rmk (kernel_img_HEADERS): Reordered for
15355 * config.guess: Updated to the latest version from gnulib.
15356 * config.sub: Likewise.
15357 * install.sh: Likewise.
15358 * mkinstalldirs: Likewise.
15360 * include/grub/console.h: Removed. This file is arch-specific. Do
15361 not put this in include/grub.
15363 * include/grub/i386/pc/console.h: Resurrected.
15365 * util/console.c: Include grub/machine/console.h instead of
15367 * util/grub-emu.c: Likewise.
15369 2005-08-04 Marco Gerards <metgerards@student.han.nl>
15371 * kern/term.c (grub_putcode): Use `grub_getwh' instead of
15374 From Vincent Pelletier <subdino2004@yahoo.fr>
15375 * include/grub/term.h (GRUB_TERM_WIDTH, GRUB_TERM_HEIGHT):
15376 Redefined to use grub_getwh.
15377 (grub_term): New member named getwh.
15378 (grub_getwh): New prototype.
15379 * kern/term.c (grub_getwh): New function.
15380 * term/i386/pc/console.c (grub_console_getwh): New function.
15381 (grub_console_term): New member `getwh'.
15382 * term/i386/pc/vga.c (grub_vga_getwh): New function.
15383 (grub_vga_term): New member `getwh'.
15384 * term/ieee1275/ofconsole.c (grub_ofconsole_readkey): Use
15386 (grub_ofconsole_getw): New function.
15387 (grub_ofconsole_init): Use grub_ssize_t and unsigned char.
15388 (grub_ofconsole_term): New field named getwh and new initial
15391 2005-08-03 Hollis Blanchard <hollis@penguinppc.org>
15393 * include/grub/powerpc/ieee1275/ieee1275.h: Move ...
15394 * include/grub/ieee1275/ieee1275.h: ... to here. All users updated.
15395 Move `abort', `grub_reboot', and `grub_halt' prototypes ...
15396 * include/grub/powerpc/ieee1275/kernel.h: ... to here.
15397 * commands/ieee1275/halt.c: Include <grub/machine/kernel.h> instead
15398 of <grub/machine/ieee1275.h>.
15399 * commands/ieee1275/reboot.c: Likewise.
15400 * boot/powerpc/ieee1275/ieee1275.c: Move ...
15401 * kern/ieee1275.c: ... to here. All users updated. Change all
15402 parameter structs to use new type `grub_ieee1275_cell_t'.
15403 * term/powerpc/ieee1275/ofconsole.c: Move ...
15404 * term/ieee1275/ofconsole.c: ... to here. All users updated.
15405 * disk/powerpc/ieee1275/ofdisk.c: Move ...
15406 * disk/ieee1275/ofdisk.c: ... to here. All users updated.
15407 * boot/powerpc/ieee1275/cmain.c: Change `grub_ieee1275_entry_fn' type
15409 * include/grub/i386/pc/console.h: Move to include/grub/console.h.
15410 Remove unused prototypes. All users updated.
15411 * include/grub/powerpc/ieee1275/console.h: Removed.
15412 * include/grub/powerpc/ieee1275/ieee1275.h: Define
15413 `grub_ieee1275_cell_t'.
15414 * kern/powerpc/ieee1275/openfw.c: Include <grub/machine/kernel.h>.
15415 Cast comparisons with -1 to the correct type.
15416 * loader/powerpc/ieee1275/linux.c (kernel_entry_t): Change parameter
15417 type to match `grub_ieee1275_entry_fn'.
15419 2005-08-01 Yoshinori K. Okuji <okuji@enbug.org>
15421 * DISTLIST: Added util/i386/pc/grub-probefs.c.
15423 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-probefs.
15424 (grub_setup_SOURCES): Removed partmap/amiga.c, partmap/apple.c and
15426 (grub_probefs_SOURCES): New variable.
15428 * util/i386/pc/grub-probefs.c: New file.
15430 * util/i386/pc/grub-setup.c (main): Call
15431 grub_pc_partition_map_init, grub_ufs_init, grub_minix_init,
15432 grub_hfs_init and grub_jfs_init to initialize the system. Call
15433 grub_ufs_fini, grub_minix_fini, grub_hfs_fini, grub_jfs_init and
15434 grub_pc_partition_map_fini to finish the system.
15436 2005-07-31 Yoshinori K. Okuji <okuji@enbug.org>
15438 * loader/i386/pc/multiboot.c (grub_multiboot_is_elf32): New
15440 (grub_multiboot_load_elf32): Likewise.
15441 (grub_multiboot_is_elf64): Likewise.
15442 (grub_multiboot_load_elf64): Likewise.
15443 (grub_multiboot_load_elf): Likewise.
15444 (grub_rescue_cmd_multiboot): Call grub_multiboot_load_elf to load
15445 an ELF32 or ELF64 file.
15446 This is based on a patch from Ruslan Nikolaev <nruslan@mail.com>.
15448 From Serbinenko Vladimir <serbinenko.vova@list.ru>:
15449 * kern/disk.c (grub_print_partinfo): Check if FS->LABEL is not
15450 NULL before calling FS->LABEL.
15451 * fs/fat.c (grub_fat_dir): Initialize DIRNAME to NULL.
15452 * commands/ls.c (grub_ls_list_files): Show labels, if possible.
15453 (grub_ls_list_disks): Check if FS and FS->LABEL are not NULL
15454 before calling FS->LABEL.
15456 2005-07-26 Yoshinori K. Okuji <okuji@enbug.org>
15458 * util/i386/pc/grub-install.in (datadir): New variable.
15460 (pkgdatadir): New variable.
15461 (pkglibdir): Removed.
15463 2005-07-24 Yoshinori K. Okuji <okuji@enbug.org>
15465 * DISTLIST: Added util/i386/pc/grub-install.in.
15467 * util/i386/pc/grub-install.in: New file.
15469 * conf/i386-pc.rmk (sbin_SCRIPTS): New variable.
15470 (grub_install_SOURCES): Likewise.
15472 * genmk.rb: Added support for scripts.
15473 (Script): New class.
15474 (scripts): New variable.
15476 * Makefile.in (install-local): Install sbin_SCRIPTS by
15478 (uninstall): Remove sbin_SCRIPTS.
15480 * util/i386/pc/grub-setup.c (main): If the argument is not a GRUB
15481 device, try to get a GRUB device by
15482 grub_util_biosdisk_get_grub_dev.
15485 * util/i386/pc/grub-mkdevicemap.c (usage): Remove a duplicated
15486 description for --device-map.
15488 2005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
15490 Change the semantics of variable hooks. They now return strings
15491 instead of error values.
15493 * util/i386/pc/grub-setup.c: Include grub/env.h.
15494 (setup): Use grub_device_set_root instead of grub_env_set.
15496 * kern/rescue.c (grub_rescue_cmd_root): Use grub_env_set and
15497 grub_env_get instead of grub_device_set_root and
15498 grub_device_get_root, respectively.
15500 * kern/main.c (grub_env_write_root): New function.
15501 (grub_set_root_dev): Register grub_env_write_hook for "root". Use
15502 grub_env_set instead of grub_device_set_root.
15504 * kern/env.c (HASHSZ): Reduced to 13, because GRUB does not need
15506 (grub_env_set): Set ENV->VALUE to the result of ENV->WRITE_HOOK
15507 rather than calling ENV->WRITE_HOOK afterwards.
15508 (grub_env_get): Return the result of ENV->READ_HOOK rather than
15509 passing a pointer of a pointer.
15510 (grub_register_variable_hook): Change the types of "read_hook" and
15511 "write_hook" to grub_env_read_hook_t and grub_env_write_hook_t,
15513 Allocate the default empty string on the heap, because this string
15514 may be freed later.
15516 * kern/device.c: Include grub/env.h.
15517 (grub_device_set_root): Removed.
15518 (grub_device_get_root): Likewise.
15519 (grub_device_open): Use grub_env_get instead of
15520 grub_device_get_root.
15522 * include/grub/env.h (grub_env_read_hook_t): New type.
15523 (grub_env_write_hook_t): Likewise.
15524 (grub_env_var): Change the types of "read_hook" and "write_hook"
15525 to grub_env_read_hook_t and grub_env_write_hook_t, respectively.
15526 (grub_register_variable_hook): Likewise.
15528 * include/grub/device.h (grub_device_set_root): Removed.
15529 (grub_device_set_root): Likewise.
15531 * fs/fat.c (grub_fat_dir): Make a copy of PATH in DIRNAME, and
15532 make sure that DIRNAME terminates with '/', so that
15533 grub_fat_find_dir will fail if PATH is not a directory.
15535 * commands/ls.c (grub_ls_list_files): Remove the qualifier const
15537 Use the qualifier auto for print_files and print_files_long.
15538 If FS->DIR sets GRUB_ERRNO to GRUB_ERR_BAD_FILE_TYPE, try DIRNAME
15540 Put a newline only if there is no error.
15541 (grub_cmd_ls): Remove grub_ls_print_files, because this is not
15544 2005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
15546 * kern/partition.c (grub_partition_probe): Initialize PART to
15547 NULL. Otherwise, when no partition map is registered, this returns
15550 2005-07-19 Yoshinori K. Okuji <okuji@enbug.org>
15552 * partmap/apple.c (apple_partition_map_iterate): Check if POS
15553 equals GRUB_DISK_SECTOR_SIZE to see if the partition table is
15556 2005-07-18 Yoshinori K. Okuji <okuji@enbug.org>
15558 * commands/ls.c (grub_ls_list_disks): Print the filesystem
15559 information on each device, if it does not have partitions. Print
15560 "Device" instead of "Disk", because this function is not specific
15563 * normal/main.c (grub_rescue_cmd_normal): Make the variable CONFIG
15564 static to ensure that it is put on the memory rather than a
15567 2005-07-17 Yoshinori Okuji <okuji@enbug.org>
15569 * commands/cat.c (GRUB_MOD_INIT): Use better documentation.
15570 (grub_cat_init): Likewise.
15571 * loader/i386/pc/chainloader_normal.c (GRUB_MOD_INIT): Likewise.
15572 (options): Likewise.
15573 * commands/configfile.c (GRUB_MOD_INIT): Likewise.
15574 (grub_configfile_init): Likewise.
15575 * font/manager.c (GRUB_MOD_INIT): Likewise.
15576 * commands/help.c (GRUB_MOD_INIT): Likewise.
15577 (grub_help_init): Likewise.
15578 * normal/command.c (grub_command_init): Likewise.
15579 * loader/i386/pc/linux_normal.c (GRUB_MOD_INIT): Likewise.
15580 * disk/loopback.c (grub_loop_init): Likewise.
15581 (GRUB_MOD_INIT): Likewise.
15582 * commands/ls.c (grub_ls_init): Likewise.
15583 (GRUB_MOD_INIT): Likewise.
15584 (options): Likewise.
15585 * commands/boot.c (grub_boot_init): Likewise.
15586 (GRUB_MOD_INIT): Likewise.
15587 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Likewise.
15588 * commands/i386/pc/reboot.c (grub_reboot_init): Likewise.
15589 (GRUB_MOD_INIT): Likewise.
15590 * commands/cmp.c (grub_cmp_init): Likewise.
15591 (GRUB_MOD_INIT): Likewise.
15593 * normal/arg.c: Use <> instead of "" to include header files.
15594 (SHORT_ARG_HELP): New macro.
15595 (SHORT_ARG_USAGE): Likewise.
15596 (help_options): Specify SHORT_ARG_HELP and SHORT_ARG_USAGE instead
15597 of 'h' and 'u' for help and usage, respectively. Use more GNU-like
15599 (find_short): Check if C is 'h' or 'u' explicitly.
15600 (grub_arg_show_help): Use space characters instead of tabs. Treat
15601 SHORT_ARG_HELP and SHORT_ARG_USAGE exceptionally so that -h and -u
15602 are shown with --help and --usage only if they are not used for
15603 the command itself.
15604 (parse_option): Use SHORT_ARG_HELP and SHORT_ARG_USAGE instead of
15607 * include/grub/arg.h (struct grub_arg_option): Add the qualifier
15608 const into "longarg". Change the type of "shortarg" to int.
15610 2005-07-17 Yoshinori Okuji <okuji@enbug.org>
15612 * boot/i386/pc/boot.S (boot_drive_check): New label.
15614 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRIVE_CHECK): New
15617 * util/i386/pc/grub-setup.c (setup): Added a workaround for BIOSes
15618 which do not pass a boot drive correctly. Copied from GRUB Legacy.
15620 2005-07-17 Yoshinori Okuji <okuji@enbug.org>
15622 * kern/i386/pc/startup.S (gate_a20_try_system_control_port_a):
15623 When turning off Gate A20, skip the check and return immediately,
15624 because this is not fatal usually.
15626 2005-07-17 Yoshinori Okuji <okuji@enbug.org>
15628 * conf/i386-pc.rmk (pxeboot_img_LDFLAGS): The text address should
15629 be 0x7C00 instead of 0x8000.
15631 * boot/i386/pc/pxeboot.S: Rewritten.
15633 * kern/i386/pc/startup.S (gate_a20_try_bios): No need to specify
15635 (gate_a20_check_state): Read a byte from 0x108000. Invert the
15638 2005-07-16 Yoshinori K. Okuji <okuji@enbug.org>
15640 * kern/i386/pc/startup.S (grub_gate_a20): Rewritten for
15641 robustness. This routine now supports a BIOS call and System
15642 Control Port A to modify the gate A20.
15644 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
15645 Increased to 0x440.
15647 2005-07-12 Hollis Blanchard <hollis@penguinppc.org>
15649 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): dprintf the
15650 device path and resulting ihandle.
15651 (grub_ofdisk_close): dprintf the ihandle being closed.
15652 (grub_ofdisk_read): dprintf function parameters.
15653 * kern/mm.c (grub_mm_init_region): Likewise.
15654 * loader/powerpc/ieee1275/linux.c: Remove extra whitespace.
15655 (grub_linux_boot): dprintf the Linux entry point, initrd address and
15656 size, and boot arguments.
15657 (grub_rescue_cmd_linux): dprintf each ELF segment's address and size
15658 before loading into memory.
15659 (grub_rescue_cmd_initrd): dprintf the initrd's address and size
15660 before loading into memory.
15662 2005-07-12 Yoshinori K. Okuji <okuji@enbug.org>
15664 * kern/mm.c: Added much documentation.
15665 (GRUB_MM_ALIGN_LOG2): When GRUB_CPU_SIZEOF_VOID_P is
15666 8, set to 5 instead of 8.
15668 2005-07-10 Yoshinori Okuji <okuji@enbug.org>
15670 * DISTLIST: Added util/i386/pc/grub-mkimage.c.
15672 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-mkdevicemap.
15673 (grub_mkdevicemap_SOURCES): New variable.
15675 * util/i386/pc/grub-mkdevicemap.c: New file. Mostly copied from
15676 lib/device.c of GRUB Legacy.
15678 2005-07-10 Yoshinori Okuji <okuji@enbug.org>
15680 * commands/ls.c (grub_ls_list_files): Check if *PATH is NUL
15681 instead of PATH is NULL.
15683 2005-07-09 Vincent Pelletier <subdino2004@yahoo.fr>
15685 * commands/cmp.c (BUFFER_SIZE): New macro.
15686 (grub_cmd_cmp): Close the right file at the right time. Compare
15687 only data just read. Don't report files of different size as
15688 identical. Dynamically allocate buffers. Move variable
15689 declarations at the beginning of function.
15691 2005-07-09 Yoshinori Okuji <okuji@enbug.org>
15693 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): The return value was
15696 2004-07-04 Vincent Pelletier <subdino2004@yahoo.fr>
15698 * normal/cmdline.c (grub_cmdline_get): Don't fallback on ctrl-d
15699 when backspace is pressed at beginning of line.
15701 2005-07-03 Yoshinori Okuji <okuji@enbug.org>
15703 * DISTLIST: Added genfslist.sh.
15705 * normal/main.c (fs_module_list): New variable.
15706 (autoload_fs_module): New function.
15707 (read_fs_list): Likewise.
15708 (grub_normal_execute): Call read_fs_list.
15710 * kern/fs.c (grub_fs_autoload_hook): New variable.
15711 (grub_fs_probe): Added support for auto-loading.
15713 * include/grub/normal.h (struct grub_fs_module_list): New struct.
15714 (grub_fs_module_list_t): New type.
15716 * include/grub/fs.h (grub_fs_autoload_hook_t): New type.
15717 (grub_fs_autoload_hook): New prototype.
15719 * genfslist.sh: New file.
15721 * genmk.rb: Added a rule to generate a filesystem list.
15723 2005-06-30 Marco Gerards <metgerards@student.han.nl>
15725 * configure.ac: Fix the test for cross-compiling.
15727 * genmk.rb (Program): Use `$(CC)' instead of `$(BUILD_CC)'. Don't
15728 define GRUB_UTIL anymore.
15730 * util/powerpc/ieee1275/grub-mkimage.c (load_note): Endian fixes
15731 so this function works on other systems than just big endian.
15732 (load_modules): Likewise.
15733 (add_segments): Likewise.
15735 2005-06-23 Hollis Blanchard <hollis@penguinppc.org>
15737 * kern/misc.c (grub_vsprintf): Add `longfmt'. If format string
15738 contains `l' modifier, get a long from va_arg().
15740 2005-06-23 Yoshinori K. Okuji <okuji@enbug.org>
15742 * kern/mm.c (grub_free): If the next free block which is being
15743 merged is the first free block, set the first block to the block
15745 Reported by Vincent Guffens <guffens@inma.ucl.ac.be>.
15747 2005-05-08 Hollis Blanchard <hollis@penguinppc.org>
15749 * boot/powerpc/ieee1275/cmain.c (cmain): Initialize
15750 `grub_ieee1275_chosen'.
15752 2005-05-08 Hollis Blanchard <hollis@penguinppc.org>
15754 * boot/powerpc/ieee1275/cmain.c (module_info): Remove definition.
15755 (grub_ieee1275_chosen): New variable.
15756 (cmain): Initialize and use `grub_ieee1275_chosen' instead of
15758 * boot/powerpc/ieee1275/crt0.S (init_stack): Remove stack space.
15759 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
15760 Rename first argument to `phandle' for consistency.
15761 (grub_ieee1275_get_property_length): Likewise.
15762 (grub_ieee1275_next_property): Likewise. Change type of first argument
15763 to grub_ieee1275_phandle_t.
15764 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_entry_fn):
15765 Move export next to declaration.
15766 (grub_ieee1275_chosen): New variable.
15767 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MODULE_BASE):
15768 Correct cosmetic typo.
15769 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Use
15770 `grub_ieee1275_chosen'.
15771 * kern/powerpc/ieee1275/openfw.c (grub_map): Likewise.
15772 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Likewise.
15773 (grub_rescue_cmd_linux): Set `initrd_addr' to 0.
15774 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_refresh): Use
15775 `grub_ieee1275_chosen'.
15777 2005-05-10 Hollis Blanchard <hollis@penguinppc.org>
15779 * boot/powerpc/ieee1275/cmain.c (cmain): Remove code to parse
15781 * kern/powerpc/ieee1275/init.c (grub_machine_init): Parse
15782 /chosen/bootargs as "variable=value" pairs.
15784 2005-05-08 Vincent Pelletier <subdino2004@yahoo.fr>
15786 * include/grub/misc.h (grub_dprintf): New macro.
15787 (grub_real_dprintf): New prototype.
15788 (grub_strword): Likewise.
15789 (grub_iswordseparator): Likewise.
15790 * kern/misc.c (grub_real_dprintf): New function.
15791 (grub_strword): Likewise.
15792 (grub_iswordseparator): Likewise.
15794 2005-04-30 Hollis Blanchard <hollis@penguinppc.org>
15796 * boot/powerpc/ieee1275/cmain.c: Don't include grub/machine/init.h.
15797 (roundup): Remove macro.
15798 (grub_ieee1275_flags): Make static.
15799 (grub_ieee1275_realmode): Remove.
15800 (grub_ieee1275_test_flag): New function.
15801 (grub_ieee1275_set_flag): Likewise.
15802 (find_options): Rename to `grub_ieee1275_find_options'; update
15803 callers. Set GRUB_IEEE1275_FLAG_REAL_MODE and
15804 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS.
15805 (cmain): New prototype.
15806 (cmain): Use `grub_ieee1275_set_flag' instead of accessing
15807 `grub_ieee1275_flags' directly.
15808 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Remove
15809 machine/biosdisk.h.
15810 * disk/powerpc/ieee1275/ofdisk.c: Include grub/machine/ofdisk.h.
15811 Don't include grub/machine/init.h.
15812 (grub_ofdisk_open): Call `grub_ieee1275_test_flag'.
15813 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
15815 (grub_ieee1275_realmode): Likewise.
15816 (grub_ieee1275_flag): New enum.
15817 (grub_ieee1275_test_flag): New prototype.
15818 (grub_ieee1275_set_flag): New prototype.
15819 * include/grub/powerpc/ieee1275/init.h: Remove file.
15820 * include/grub/powerpc/ieee1275/ofdisk.h: New file.
15821 * kern/powerpc/ieee1275/init.c: Don't include grub/machine/init.h.
15822 Include grub/machine/console.h. Include grub/machine/ofdisk.h.
15823 (grub_machine_fini): Don't call `grub_ieee1275_release'. Remove
15825 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Call
15826 `grub_ieee1275_test_flag'.
15827 (grub_ieee1275_encode_devname): Likewise.
15829 2005-04-21 Hollis Blanchard <hollis@penguinppc.org>
15831 * include/grub/powerpc/ieee1275/ieee1275.h
15832 (grub_ieee1275_encode_devname): New prototype.
15833 (grub_ieee1275_get_filename): Likewise.
15834 * kern/powerpc/ieee1275/init.c (grub_translate_ieee175_path): New
15836 (grub_set_prefix): Likewise.
15837 (grub_machine_init): Call grub_set_prefix.
15838 * kern/powerpc/ieee1275/openfw.c: Fix typos.
15839 (grub_parse_type): New enum.
15840 (grub_ieee1275_get_devargs): New function.
15841 (grub_ieee1275_get_devname): Likewise.
15842 (grub_ieee1275_parse_args): Likewise.
15843 (grub_ieee1275_get_filename): Likewise.
15844 (grub_ieee1275_encode_devname): Likewise.
15846 2005-03-30 Marco Gerards <metgerards@student.han.nl>
15848 * kern/powerpc/ieee1275/init.c (grub_machine_fini): Don't call
15849 `grub_loader_unset'.
15851 2005-03-26 Hollis Blanchard <hollis@penguinppc.org>
15853 * commands/ieee1275/halt.c (grub_cmd_halt): Call grub_halt
15854 instead of grub_ieee1275_interpret.
15855 (grub_halt_init): New function.
15856 (grub_halt_fini): Likewise.
15857 (GRUB_MOD_INIT): Correct message grammar.
15858 * commands/ieee1275/reboot.c (grub_cmd_reboot): Call grub_reboot
15859 instead of grub_ieee1275_interpret.
15860 (grub_reboot_init): New function.
15861 (grub_reboot_fini): Likewise.
15862 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace
15863 commands/i386/pc/halt.c, commands/i386/pc/reboot.c, and
15864 util/i386/pc/misc.c with commands/ieee1275/halt.c,
15865 commands/ieee1275/reboot.c, and util/powerpc/ieee1275/misc.c.
15866 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_fini): New
15868 * include/grub/powerpc/ieee1275/console.h (grub_console_fini):
15870 * include/grub/powerpc/ieee1275/ieee1275.h (grub_reboot): Add
15872 (grub_halt): Likewise.
15873 * include/grub/powerpc/ieee1275/init.h: Remove inaccurate comment.
15874 (cmain): Remove __attribute__((unused)).
15875 * kern/powerpc/ieee1275/init.c (grub_heap_start): New variable.
15876 (grub_heap_len): Likewise.
15877 (grub_machine_fini): New function.
15878 * kern/powerpc/ieee1275/openfw.c (grub_reboot): New function.
15879 (grub_halt): Likewise.
15880 * term/powerpc/ieee1275/ofconsole.c (grub_console_fini): New
15882 * util/powerpc/ieee1275/misc.c: New file.
15884 2005-03-19 Yoshinori K. Okuji <okuji@enbug.org>
15886 * DISTLIST: New file.
15887 * gendistlist.sh: Likewise.
15889 * Makefile.in (COMMON_DISTFILES): Removed.
15890 (BOOT_DISTFILES): Likewise.
15891 (CONF_DISTFILES): Likewise.
15892 (DISK_DISTFILES): Likewise.
15893 (FS_DISTFILES): Likewise.
15894 (INCLUDE_DISTFILES): Likewise.
15895 (KERN_DISTFILES): Likewise.
15896 (LOADER_DISTFILES): Likewise.
15897 (TERM_DISTFILES): Likewise.
15898 (UTIL_DISTFILES): Likewise.
15899 (DISTFILES): Likewise.
15900 (uninstall): Uninstall files in $(pkgdata_DATA).
15901 (DISTLIST): New target.
15902 (distdir): Use the contents of the file DISTLIST to get a list of
15905 2005-03-18 Yoshinori K. Okuji <okuji@enbug.org>
15907 * fs/fat.c (grub_fat_mount): Ignore the 3rd bit of a media
15908 descriptor. This is ported from GRUB Legacy.
15910 * gencmdlist.sh: Added an extra semicolon to make it work with
15911 old sed versions. Reported by Robert Bihlmeyer
15912 <robbe@orcus.priv.at>.
15914 2005-03-08 Yoshinori Okuji <okuji@enbug.org>
15916 Automatic loading of commands is supported.
15918 * normal/main.c (read_command_list): New function.
15919 (grub_normal_execute): Call read_command_list.
15921 * normal/command.c (grub_register_command): Return zero or CMD.
15922 Allocate CMD->NAME from the heap.
15923 Initialize CMD->MODULE_NAME to zero.
15924 Find the same name as well. If the same command is found and it is
15925 a dummy command, overwrite members. If it is not a dummy command,
15927 (grub_unregister_command): Free Q->NAME and Q->MODULE_NAME.
15928 (grub_command_find): If a dummy command is found, load a module
15929 and retry to find a command only once.
15931 * normal/cmdline.c (grub_tab_complete): Call grub_command_find to
15932 make sure that each command is loaded.
15934 * include/grub/normal.h (GRUB_COMMAND_FLAG_NOT_LOADED): New
15936 (struct grub_command): Remove const from the member `name'.
15937 Add a new member `module_name'.
15938 (grub_register_command): Return grub_command_t.
15940 * commands/help.c (grub_cmd_help): Call grub_command_find to make
15941 sure that each command is loaded.
15943 * genmk.rb (PModule::rule): Specify a module name without the
15944 suffix ".mod" to gencmdlist.sh.
15946 2005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
15948 * gencmdlist.sh: New file.
15950 * genmk.rb (PModule::rule): Generate a rule for a command list.
15952 Generate command.lst from $(COMMANDFILES).
15954 * Makefile.in (COMMON_DISTFILES): Added gencmdlist.sh.
15955 (DATA): Added $(pkgdata_DATA).
15956 (install-local): Install files in $(pkgdata_DATA).
15958 2005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
15960 * term/i386/pc/vga.c (debug_command): Removed.
15961 (GRUB_MOD_INIT): Do not register the command "debug".
15963 From Hollis Blanchard:
15964 * commands/configfile.c: New file.
15965 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
15966 commands/configfile.c.
15967 (pkgdata_MODULES): Added configfile.mod.
15968 (configfile_mod_SOURCES): New variable.
15969 (configfile_mod_CFLAGS): Likewise.
15970 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
15971 commands/configfile.c.
15972 (pkgdata_MODULES): Added configfile.mod.
15973 (configfile_mod_SOURCES): New variable.
15974 (configfile_mod_CFLAGS): Likewise.
15975 * util/grub-emu.c (main): Call grub_configfile_init and
15976 grub_configfile_fini.
15977 * include/grub/normal.h [GRUB_UTIL] (grub_configfile_init): New
15979 [GRUB_UTIL] (grub_configfile_fini): Likewise.
15981 2005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
15983 * normal/arg.c (grub_arg_show_help): Do not show the bug report
15986 * commands/help.c (grub_cmd_help): Do not print newlines after
15987 the last command in print_command_help.
15989 2005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
15991 * commands/default.h: New file.
15992 * commands/timeout.h: Likewise.
15993 * normal/context.c: Likewise.
15995 * util/misc.c: Do not include sys/times.h.
15996 Include sys/time.h and grub/machine/time.h.
15997 (grub_get_rtc): Rewritten with gettimeofday.
15999 * util/grub-emu.c (main): Call grub_default_init and
16000 grub_timeout_init before grub_normal_init, and call
16001 grub_timeout_fini and grub_default_fini after grub_main.
16003 * util/console.c (grub_ncurses_checkkey): Return the read
16006 * normal/menu.c (run_menu): Set MENU->TIMEOUT to -1 once it
16009 * normal/main.c (read_config_file): Push MENU. If this fails,
16010 print an error and wait for a user input.
16011 Print an error only if GRUB_ERRNO is not GRUB_ERR_NONE.
16012 If a menu is empty or an error occurs, pop MENU.
16013 (grub_normal_execute): Pop and free MENU after grub_menu_run
16016 * kern/loader.c (grub_loader_boot): Call grub_machine_fini.
16018 * include/grub/powerpc/ieee1275/time.h [GRUB_UTIL]: Do not
16020 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
16022 * include/grub/i386/pc/time.h [GRUB_UTIL]: Do not include
16024 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
16027 * include/grub/normal.h (struct grub_menu_list): New struct.
16028 (grub_menu_list_t): New type.
16029 (struct grub_context): New struct.
16030 (grub_context_t): New type.
16031 (grub_register_command): Got rid of EXPORT_FUNC.
16032 (grub_unregister_command): Likewise.
16033 (grub_context_get): New prototype.
16034 (grub_context_get_current_menu): Likewise.
16035 (grub_context_push_menu): Likewise.
16036 (grub_context_pop_menu): Likewise.
16037 [GRUB_UTIL] (grub_default_init): Likewise.
16038 [GRUB_UTIL] (grub_default_fini): Likewise.
16039 [GRUB_UTIL] (grub_timeout_init): Likewise.
16040 [GRUB_UTIL] (grub_timeout_fini): Likewise.
16042 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/default.c,
16043 commands/timeout.c and normal/context.c.
16044 (pkgdata_MODULES): Added default.mod and timeout.mod.
16045 (normal_mod_SOURCES): Added normal/context.c.
16046 (default_mod_SOURCES): New variable.
16047 (default_mod_CFLAGS): Likewise.
16048 (timeout_mod_SOURCES): Likewise.
16049 (timeout_mod_CFLAGS): Likewise.
16050 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Copied from
16052 (pkgdata_MODULES): Added default.mod and timeout.mod.
16053 (normal_mod_SOURCES): Added normal/context.c.
16054 (default_mod_SOURCES): New variable.
16055 (default_mod_CFLAGS): Likewise.
16056 (timeout_mod_SOURCES): Likewise.
16057 (timeout_mod_CFLAGS): Likewise.
16059 * Makefile.in (all-local): Added $(MKFILES).
16061 2005-02-21 Vincent Pelletier <subdino2004@yahoo.fr>
16063 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `partmap/sun.c'.
16064 (grub_emu_SOURCES): Likewise.
16065 (pkgdata_MODULES): Add `sun.mod'.
16066 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
16067 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
16069 (pkgdata_MODULES): Add `sun.mod'.
16070 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
16071 * include/grub/partition.h (grub_sun_partition_map_init): New
16073 (grub_sun_partition_map_fini): Likewise.
16074 * partmap/sun.c: New file.
16075 * util/grub-emu.c (main): Initialize and de-initialize the sun
16076 partitionmap support.
16078 2005-02-19 Yoshinori K. Okuji <okuji@enbug.org>
16080 This implements an Emacs-like menu entry editor.
16082 * normal/menu_entry.c: New file.
16084 * util/console.c (grub_ncurses_putchar): Translate some Unicode
16085 characters to ASCII.
16086 (saved_char): New variable.
16087 (grub_ncurses_checkkey): Rewritten completely.
16088 (grub_ncurses_getkey): Likewise.
16089 (grub_ncurses_init): Call raw instead of cbreak.
16091 * normal/menu.c (print_entry): Do not put a space.
16092 (init_page): Renamed to ...
16093 (grub_menu_init_page): ... this. All callers changed.
16094 (edit_menu_entry): Removed.
16095 (run_menu): Call grub_menu_entry_run instead of edit_menu_entry.
16097 * normal/cmdline.c (grub_cmdline_run): Call grub_setcursor.
16099 * kern/misc.c (grub_vprintf): Call grub_refresh.
16101 * normal/menu.c (DISP_LEFT): Renamed to ...
16102 * include/grub/term.h (GRUB_TERM_DISP_LEFT): ... this.
16103 * normal/menu.c (DISP_UP): Renamed to ...
16104 * include/grub/term.h (GRUB_TERM_DISP_UP): ... this.
16105 * normal/menu.c (DISP_RIGHT): Renamed to ...
16106 * include/grub/term.h (GRUB_TERM_DISP_RIGHT): ... this.
16107 * normal/menu.c (DISP_DOWN): Renamed to ...
16108 * include/grub/term.h (GRUB_TERM_DISP_DOWN): ... this.
16109 * normal/menu.c (DISP_HLINE): Renamed to ...
16110 * include/grub/term.h (GRUB_TERM_DISP_HLINE): ... this.
16111 * normal/menu.c (DISP_VLINE): Renamed to ...
16112 * include/grub/term.h (GRUB_TERM_DISP_VLINE): ... this.
16113 * normal/menu.c (DISP_UL): Renamed to ...
16114 * include/grub/term.h (GRUB_TERM_DISP_UL): ... this.
16115 * normal/menu.c (DISP_UR): Renamed to ...
16116 * include/grub/term.h (GRUB_TERM_DISP_UR): ... this.
16117 * normal/menu.c (DISP_LL): Renamed to ...
16118 * include/grub/term.h (GRUB_TERM_DISP_LL): ... this.
16119 * normal/menu.c (DISP_LR): Renamed to ...
16120 * include/grub/term.h (GRUB_TERM_DISP_LR): ... this.
16121 * normal/menu.c (TERM_WIDTH): Renamed to ...
16122 * include/grub/term.h (GRUB_TERM_WIDTH): ... this.
16123 * normal/menu.c (TERM_HEIGHT): Renamed to ...
16124 * include/grub/term.h (GRUB_TERM_HEIGHT): ... this.
16125 * normal/menu.c (TERM_INFO_HEIGHT): Renamed to ...
16126 * include/grub/term.h (GRUB_TERM_INFO_HEIGHT): ... this.
16127 * normal/menu.c (TERM_MARGIN): Renamed to ...
16128 * include/grub/term.h (GRUB_TERM_MARGIN): ... this.
16129 * normal/menu.c (TERM_SCROLL_WIDTH): Renamed to ...
16130 * include/grub/term.h (GRUB_TERM_SCROLL_WIDTH): ... this.
16131 * normal/menu.c (TERM_TOP_BORDER_Y): Renamed to ...
16132 * include/grub/term.h (GRUB_TERM_TOP_BORDER_Y): ... this.
16133 * normal/menu.c (TERM_LEFT_BORDER_X): Renamed to ...
16134 * include/grub/term.h (GRUB_TERM_LEFT_BORDER_X): ... this.
16135 * normal/menu.c (TERM_BORDER_WIDTH): Renamed to ...
16136 * include/grub/term.h (GRUB_TERM_BORDER_WIDTH): ... this.
16137 * normal/menu.c (TERM_MESSAGE_HEIGHT): Renamed to ...
16138 * include/grub/term.h (GRUB_TERM_MESSAGE_HEIGHT): ... this.
16139 * normal/menu.c (TERM_BORDER_HEIGHT): Renamed to ...
16140 * include/grub/term.h (GRUB_TERM_BORDER_HEIGHT): ... this.
16141 * normal/menu.c (TERM_NUM_ENTRIES): Renamed to ...
16142 * include/grub/term.h (GRUB_TERM_NUM_ENTRIES): ... this.
16143 * normal/menu.c (TERM_FIRST_ENTRY_Y): Renamed to ...
16144 * include/grub/term.h (GRUB_TERM_FIRST_ENTRY_Y): ... this.
16145 * normal/menu.c (TERM_ENTRY_WIDTH): Renamed to ...
16146 * include/grub/term.h (GRUB_TERM_ENTRY_WIDTH): ... this.
16147 * normal/menu.c (TERM_CURSOR_X): Renamed to ...
16148 * include/grub/term.h (GRUB_TERM_CURSOR_X): ... this.
16149 All callers changed.
16151 * include/grub/normal.h: New prototype.
16153 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
16154 normal/menu_entry.c.
16155 (normal_mod_SOURCES): Likewise.
16156 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
16157 (normal_mod_SOURCES): Likewise.
16159 2005-02-15 Yoshinori K. Okuji <okuji@enbug.org>
16161 * include/grub/normal.h (grub_halt_init): New prototype.
16162 (grub_halt_fini): Likewise.
16163 (grub_reboot_init): Likewise.
16164 (grub_reboot_fini): Likewise.
16166 * util/grub-emu.c: Include signal.h.
16167 (main_env): New global variable.
16168 (grub_machine_init): Ignore SIGINT. Otherwise grub-emu cannot
16170 (grub_machine_fini): New function.
16171 (main): Call grub_halt_init and grub_reboot_init before
16172 grub_main, and grub_reboot_fini and grub_halt_fini after it.
16173 Call setjmp with MAIN_ENV to go back afterwards.
16174 Call grub_machine_fini right before return.
16176 * include/grub/util/misc.h: Include setjmp.h.
16177 (main_env): New prototype.
16179 * include/grub/kernel.h (grub_machine_fini): New prototype.
16180 * include/grub/i386/pc/biosdisk.h (grub_biosdisk_fini): Likewise.
16181 * include/grub/i386/pc/console.h (grub_console_fini): Likewise.
16183 * disk/i386/pc/biosdisk.c (grub_biosdisk_fini): New function.
16184 * kern/i386/pc/init.c (grub_machine_fini): Likewise.
16185 * term/i386/pc/console.c (grub_console_fini): Likewise.
16187 * util/i386/pc/misc.c: New file.
16189 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
16190 util/i386/pc/misc.c, commands/i386/pc/halt.c and
16191 commands/i386/pc/reboot.c.
16193 2005-02-14 Guillem Jover <guillem@hadrons.org>
16195 * include/grub/dl.h (grub_dl_check_header): New prototype.
16196 (grub_arch_dl_check_header): Change return type to grub_err_t,
16197 remove size parameter and export function. Update all callers.
16198 * kern/dl.c (grub_dl_check_header): New function.
16199 (grub_dl_load_core): Use `grub_dl_check_header' instead of
16200 `grub_arch_dl_check_header'. Check ELF type. Check if sections
16201 are inside the core.
16202 * kern/i386/dl.c (grub_arch_dl_check_header): Remove arch
16203 independent ELF header checks.
16204 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
16205 * loader/i386/pc/multiboot.c (grub_rescue_cmd_multiboot): Use
16206 `grub_dl_check_header' instead of explicit checks. Check for the
16208 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Use
16209 `grub_dl_check_header' instead of explicit checks. Remove arch
16210 specific ELF header checks.
16212 * util/grub-emu.c (grub_arch_dl_check_header): Remove the
16215 2005-02-13 Hollis Blanchard <hollis@penguinppc.org>
16217 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add ls.mod.
16218 * include/grub/powerpc/libgcc.h (__mulsf3): New prototype.
16220 2005-02-12 Hollis Blanchard <hollis@penguinppc.org>
16222 * kern/partition.c (grub_partition_probe): Clear `grub_errno' and
16223 return 0 if `grub_errno' is GRUB_ERR_BAD_PART_TABLE.
16224 (part_map_iterate): Clear `grub_errno' and return 0 if
16225 `partmap->iterate' returns GRUB_ERR_BAD_PART_TABLE.
16226 * partmap/amiga.c (amiga_partition_map_iterate): Return
16227 GRUB_ERR_BAD_PART_TABLE if no partition map magic is found.
16228 * partmap/apple.c (apple_partition_map_iterate): Likewise.
16230 2005-02-01 Guillem Jover <guillem@hadrons.org>
16232 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Fix module
16235 2005-01-31 Marco Gerards <metgerards@student.han.nl>
16237 * include/grub/powerpc/ieee1275/loader.h (grub_load_linux):
16239 (grub_rescue_cmd_linux): New prototype.
16240 (grub_rescue_cmd_initrd): Likewise.
16241 * powerpc/ieee1275/linux.c (grub_linux_boot): Remove struct
16243 (grub_linux_release_mem): Release the memory for the initrd.
16244 (grub_load_linux): Renamed from this...
16245 (grub_rescue_cmd_linux): ...To this. Changed all callers.
16246 Changed `entry' not to be static. Loop over memory regions to
16247 find another one when the default fails.
16248 (grub_rescue_cmd_initrd): New function.
16249 (grub_linux_init): Remove function.
16250 (grub_linux_fini): Likewise.
16251 (GRUB_MOD_INIT): Register `initrd'.
16252 (GRUB_MOD_FINI): Unregister `initrd'.
16253 * powerpc/ieee1275/linux_normal.c (grub_linux_normal_init):
16255 (grub_linux_normal_fini): Likewise.
16256 (GRUB_MOD_INIT): Register `initrd'.
16257 (GRUB_MOD_FINI): Unregister `initrd'.
16259 2005-01-31 Marco Gerards <metgerards@student.han.nl>
16261 * commands/help.c: New file.
16262 * normal/arg.c (show_help): Renamed to...
16263 (grub_arg_show_help): ... this.
16264 * commands/i386/pc/halt.c: New file.
16265 * commands/i386/pc/reboot.c: Likewise.
16266 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/help.c'.
16267 (pkgdata_MODULES): Add `reboot.mod', `halt.mod' and `help.mod'.
16268 (help_mod_SOURCES, help_mod_CFLAGS, reboot_mod_SOURCES)
16269 (reboot_mod_CFLAGS, halt_mod_SOURCES, halt_mod_CFLAGS): New
16271 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
16273 (pkgdata_MODULES): Add `help.mod'.
16274 (help_mod_SOURCES, help_mod_CFLAGS): New variables.
16275 * grub/i386/pc/init.h (grub_reboot): New prototype.
16276 (grub_halt): Likewise.
16277 * include/grub/normal.h (grub_arg_show_help): New prototype.
16278 (grub_help_init): Likewise.
16279 (grub_help_fini): Likewise.
16280 * util/grub-emu.c (main): Initialize and deinitialize the help
16283 * normal/cmdline.c (grub_cmdline_get): Doc fix.
16285 * normal/command.c (grub_command_init): Fixed the description of
16286 the `set' and `unset' commands.
16288 2005-01-31 Marco Gerards <metgerards@student.han.nl>
16290 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_interpret): New
16292 * commands/ieee1275/halt.c: New file.
16293 * commands/ieee1275/reboot.c: Likewise.
16294 * commands/ieee1275/suspend.c (grub_cmd_suspend): Use
16295 `__attribute__ ((unused))'. Some GCS related fixed.
16296 (grub_suspend_init) [GRUB_UTIL]: Function removed.
16297 (grub_suspend_fini): Likewise.
16298 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add `reboot.mod'
16300 (reboot_mod_SOURCES, reboot_mod_CFLAGS, halt_mod_SOURCES)
16301 (halt_mod_CFLAGS): New variables.
16302 * include/grub/powerpc/ieee1275/ieee1275.h
16303 (grub_ieee1275_interpret): New prototype.
16305 2005-01-29 Yoshinori K. Okuji <okuji@enbug.org>
16307 * include/grub/misc.h (memmove): New prototype.
16308 (memcpy): Likewise.
16310 2005-01-22 Hollis Blanchard <hollis@penguinppc.org>
16312 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Don't initialize
16313 `devpath' to 0. Use `name' instead of `devpath' with `grub_strndup'.
16315 2005-01-22 Marco Gerards <metgerards@student.han.nl>
16317 * kern/misc.c (grub_strndup): Function rewritten.
16319 2005-01-22 Vincent Pelletier <subdino2004@yahoo.fr>
16321 * normal/menu.c (TERM_WIDTH): Macro redefined.
16322 (TERM_TOP_BORDER_Y): Likewise.
16323 (draw_border): Replaced while-loop by a for-loop. Make the number
16324 of lines consistent with the number of lines displayed in
16325 print_entries. Added a margin below the rectangle.
16326 (print_entry): Make the entry fit in the rectangle.
16327 (print_entries): Display the scroll arrows next to the right
16330 2005-01-21 Marco Gerards <metgerards@student.han.nl>
16332 * fs/minix.c (grub_minix_find_file): Reserve more space for
16333 `fpath' so the \0 can be stored. Use `grub_strcpy' instead of
16334 `grub_strncpy' to copy `path' into it.
16336 2005-01-21 Marco Gerards <metgerards@student.han.nl>
16338 Add the loopback device, a device via which files can be accessed
16341 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/loopback.c'.
16342 (pkgdata_MODULES): Add loopback.mod.
16343 (loopback_mod_SOURCES): New variable.
16344 (loopback_mod_CFLAGS): Likewise.
16345 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
16347 (pkgdata_MODULES): Add loopback.mod.
16348 (loopback_mod_SOURCES): New variable.
16349 (loopback_mod_CFLAGS): Likewise.
16350 * disk/loopback.c: new file.
16351 * include/grub/normal.h (grub_loop_init): New prototype.
16352 (grub_loop_fini): New prototype.
16353 * util/grub-emu.c (main): Initialize and de-initialize loopback
16355 * include/grub/disk.h (grub_disk_dev_id): Add
16356 `GRUB_DISK_DEVICE_LOOPBACK_ID'.
16358 2005-01-20 Hollis Blanchard <hollis@penguinppc.org>
16360 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_enter): New
16362 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add suspend.mod.
16363 (suspend_mod_SOURCES): New variable.
16364 (suspend_mod_CFLAGS): Likewise.
16365 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_enter):
16367 * commands/ieee1275/suspend.c: New file.
16369 2005-01-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
16371 * include/grub/dl.h (GRUB_MOD_INIT): Changed `__attribute__
16372 ((unused))' to `__attribute__ ((used))'.
16373 (GRUB_MOD_FINI): Likewise.
16374 * kern/dl.c (grub_dl_load_file): Fix null pointer dereference.
16375 * genmk.rb (PModule): Assign space to common symbols when linking
16378 2005-01-20 Marco Gerards <metgerards@student.han.nl>
16380 * include/grub/mm.h (grub_mm_init_region): Change the type of the
16381 `unsigned' arguments to `grub_size_t'.
16382 (grub_malloc): Likewise.
16383 (grub_realloc): Likewise.
16384 (grub_memalign): Likewise.
16385 * kern/i386/dl.c (grub_arch_dl_check_header): Likewise.
16386 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
16387 * util/misc.c (grub_malloc): Likewise.
16388 (grub_realloc): Likewise.
16389 * kern/mm.c (get_header_from_pointer): Change the casts to
16390 `unsigned' into a cast to `grub_size_t'.
16392 * fs/fshelp.c (grub_fshelp_find_file): The `oldnode' should always
16393 point to `currnode' when `currnode' is changed.
16395 * util/grub-emu.c (main): Initialize `progname'. Reported by Nico
16396 Schottelius <nico-linux@schottelius.org>.
16398 2005-01-09 Hollis Blanchard <hollis@penguinppc.org>
16400 * util/powerpc/ieee1275/grub-mkimage.c: Include <string.h>.
16401 (note_path): Remove variable.
16402 (GRUB_IEEE1275_NOTE_NAME): New macro.
16403 (GRUB_IEEE1275_NOTE_TYPE): Likewise.
16404 (grub_ieee1275_note_hdr): New structure.
16405 (grub_ieee1275_note_desc): Likewise.
16406 (grub_ieee1275_note): Likewise.
16407 (load_note): Remove `dir' argument. All callers updated. Remove
16408 `note_img' and `path'. Do not load a file from `note_path'.
16409 Initialize a struct grub_ieee1275_note and write that to `out'.
16410 Use GRUB_IEEE1275_MODULE_BASE instead of MODULE_BASE.
16412 2005-01-05 Marco Gerards <metgerards@student.han.nl>
16414 * util/misc.c (grub_util_read_image): Revert last change. It
16415 called `grub_util_read_at', which seeks from the beginning of the
16418 2005-01-04 Hollis Blanchard <hollis@penguinppc.org>
16420 * TODO: Add note about endianness in grub-mkimage.
16421 * boot/powerpc/ieee1275/crt0.S (note): Remove unused .note
16423 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Add grub-mkimage.
16424 (grub_mkimage_SOURCES): New target.
16425 * include/grub/kernel.h (grub_start_addr): Remove variable.
16426 (grub_end_addr): Likewise.
16427 (grub_total_module_size): Likewise.
16428 (grub_kernel_image_size): Likewise.
16429 (GRUB_MODULE_MAGIC): New constant.
16430 (grub_module_info): New structure.
16431 (grub_arch_modules_addr): New prototype.
16432 (grub_get_end_addr): Remove prototype.
16433 * include/grub/i386/pc/kernel.h (grub_end_addr): New prototype.
16434 * include/grub/powerpc/ieee1275/kernel.h: New file.
16435 * include/grub/util/misc.h (grub_util_get_fp_size): New
16437 (grub_util_read_at): Likewise.
16438 (grub_util_write_image_at): Likewise.
16439 * kern/main.c (grub_get_end_addr): Remove function.
16440 (grub_load_modules): Call grub_arch_modules_addr instead of using
16441 grub_end_addr. Look for a grub_module_info struct in memory. Use
16442 the grub_module_info fields instead of calling grub_get_end_addr
16443 as loop conditions. Move grub_add_unused_region code here.
16444 (grub_add_unused_region): Remove function.
16445 * kern/i386/pc/init.c: Include grub/cache.h.
16446 (grub_machine_init): Remove call to grub_get_end_addr. Remove
16447 one call to add_mem_region.
16448 (grub_arch_modules_addr): New function.
16449 * kern/powerpc/ieee1275/init.c (grub_end_addr): Remove variable.
16450 (grub_total_module_size): Likewise.
16451 Include grub/machine/kernel.h.
16452 (grub_arch_modules_addr): New function.
16453 * util/grub-emu.c (grub_end_addr): Remove variable.
16454 (grub_total_module_size): Likewise.
16455 (grub_arch_modules_addr): New function.
16456 * util/misc.c: Include unistd.h.
16457 (grub_util_get_fp_size): New function.
16458 (grub_util_read_at): Likewise.
16459 (grub_util_write_image_at): Likewise.
16460 (grub_util_read_image): Call grub_util_read_at.
16461 (grub_util_write_image): Call grub_util_write_image_at.
16462 * util/i386/pc/grub-mkimage.c (generate_image): Allocate
16463 additional memory in kernel_img for a struct grub_module_info.
16464 Fill in that grub_module_info.
16465 * util/powerpc/ieee1275/grub-mkimage.c: New file.
16467 2005-01-03 Hollis Blanchard <hollis@penguinppc.org>
16469 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_milliseconds):
16471 * include/grub/powerpc/ieee1275/ieee1275.h
16472 (grub_ieee1275_milliseconds): New prototype.
16473 * include/grub/powerpc/ieee1275/time.h (GRUB_TICKS_PER_SECOND):
16475 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Call
16476 grub_ieee1275_milliseconds.
16478 2005-01-03 Hollis Blanchard <hollis@penguinppc.org>
16480 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_realmode): New
16482 (find_options): New function.
16483 (cmain): Call find_options.
16484 * include/grub/powerpc/ieee1275/ieee1275.h
16485 (grub_ieee1275_realmode): New extern variable.
16486 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Only call
16487 grub_map if grub_ieee1275_realmode is false.
16489 2004-12-29 Marco Gerards <metgerards@student.han.nl>
16491 * normal/cmdline.c (grub_cmdline_get): Redone logic so no empty
16492 lines are inserted and make it work like readline. Reported by
16493 Vincent Pelletier <subdino2004@yahoo.fr>.
16495 2004-12-28 Marco Gerards <metgerards@student.han.nl>
16497 * boot/powerpc/ieee1275/crt0.S (_start): Don't set up the stack.
16499 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCE): Remove
16500 `kern/powerpc/cache.S'.
16502 2004-12-27 Marco Gerards <metgerards@student.han.nl>
16504 * genmk.rb: Handle the `Program' class in the main loop. Written
16505 by Johan Rydberg <jrydberg@gnu.org>.
16506 (Program): New class.
16507 (programs): New variable.
16508 * boot/powerpc/ieee1275/cmain.c: Include <grub/machine/ieee1275.h>
16509 instead of "grub/machine/ieee1275.h". Include <grub/kernel.h>
16510 instead of "grub/kernel.h". Include <grub/machine/init.h>.
16511 (help_arch): Function removed.
16512 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add
16513 `powerpc/libgcc.h' and `loader.h'.
16514 (pkgdata_PROGRAMS): New variable.
16515 (sbin_UTILITIES): Variable removed.
16516 (grub_emu_SOURCES): Added kern/powerpc/cache.S.
16517 (grubof_SOURCES): Variable re-defined so it only includes the
16518 core functionality.
16519 (grubof_CFLAGS): Remove `-DGRUBOF'.
16520 (pkgdata_MODULES, fshelp_mod_SOURCES, fshelp_mod_CFLAGS,
16521 (fat_mod_SOURCES, fat_mod_CFLAGS, ext2_mod_SOURCES)
16522 (ext2_mod_CFLAGS, ufs_mod_SOURCES, ufs_mod_CFLAGS)
16523 (minix_mod_SOURCES, minix_mod_CFLAGS, hfs_mod_SOURCES)
16524 (hfs_mod_CFLAGS, jfs_mod_SOURCES, jfs_mod_CFLAGS)
16525 (iso9660_mod_SOURCES, iso9660_mod_CFLAGS, _linux_mod_SOURCES)
16526 (_linux_mod_CFLAGS, linux_mod_SOURCES, linux_mod_CFLAGS)
16527 (normal_mod_SOURCES, normal_mod_CFLAGS, normal_mod_ASFLAGS)
16528 (hello_mod_SOURCES, hello_mod_CFLAGS, boot_mod_SOURCES)
16529 (boot_mod_CFLAGS, terminal_mod_SOURCES, terminal_mod_CFLAGS)
16530 (ls_mod_SOURCES, ls_mod_CFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
16531 (cat_mod_SOURCES, cat_mod_CFLAGS, font_mod_SOURCES)
16532 (font_mod_CFLAGS, amiga_mod_SOURCES, amiga_mod_CFLAGS)
16533 (apple_mod_SOURCES, apple_mod_CFLAGS, pc_mod_SOURCES)
16534 (pc_mod_CFLAGS): New variables.
16535 * disk/powerpc/ieee1275/ofdisk.c: Include <grub/machine/init.h>.
16536 (grub_ofdisk_iterate): Add a prototype for `dev_iterate'.
16537 * include/grub/dl.h (grub_arch_dl_sync_caches): New prototype.
16538 * include/grub/loader.h (grub_os_area_addr, grub_os_area_size):
16540 * include/grub/i386/pc/init.h (grub_os_area_addr)
16541 (rub_os_area_size): ... to here.
16542 * include/grub/powerpc/ieee1275/ieee1275.h
16543 (grub_ieee1275_entry_fn): Export symbol.
16544 * include/grub/powerpc/ieee1275/init.h: New file.
16545 * include/grub/powerpc/libgcc.h: Likewise.
16546 * include/grub/cache.h: Likewise.
16547 * kern/powerpc/cache.S: Likewise. Written by Hollis Blanchard
16548 <hollis@penguinppc.org>.
16549 * kern/dl.c: Include <grub/cache.h>.
16550 (grub_dl_flush_cache): New function.
16551 (grub_dl_load_core): Call `grub_dl_flush_cache' to flush the cache
16553 * kern/powerpc/ieee1275/init.c (grub_ofdisk_init)
16554 (grub_console_init): Removed prototypes.
16555 (grub_machine_init): Don't initialize the modules anymore.
16556 * kern/powerpc/ieee1275/openfw.c (grub_map): Make the function
16558 * include/grub/powerpc/types.h (GRUB_HOST_WORDS_LITTLEENDIAN):
16559 Macro undef removed.
16560 (GRUB_HOST_WORDS_BIGENDIAN): New macro.
16561 * kern/powerpc/dl.c (grub_arch_dl_relocate_symbols): Add
16562 relocation `R_PPC_REL32'. Return an error when the relocation is
16564 * Makefile.in (DATA): Add `$(pkgdata_PROGRAMS)'.
16565 * kern/i386/pc/init.c (grub_arch_sync_caches): New function.
16566 * util/misc.c (grub_arch_sync_caches): Likewise.
16568 2004-12-19 Marco Gerards <metgerards@student.han.nl>
16570 * conf/powerpc-ieee1275.rmk (MOSTLYCLEANFILES): Remove
16571 `symlist.c', add `grubof_symlist.c'.
16572 (symlist.c): Variable removed.
16573 (grubof_HEADERS): Variable added.
16574 (grubof_symlist.c): New target.
16575 (kernel_syms.lst): Use `grubof_HEADERS' instead of
16576 `kernel_img_HEADERS'.
16577 (grubof_SOURCES): Add `kern/powerpc/dl.c' and `grubof_symlist.c'.
16578 * kern/powerpc/dl.c: New file.
16579 * kern/powerpc/ieee1275/init.c (grub_arch_dl_check_header):
16581 (grub_arch_dl_relocate_symbols): Likewise.
16582 (grub_register_exported_symbols): Likewise.
16584 2004-12-13 Marco Gerards <metgerards@student.han.nl>
16586 * fs/ext2.c (grub_ext2_open): Don't use data after freeing it.
16587 (grub_ext2_dir): Likewise. Don't return in case of an error, jump
16588 to fail instead. Reported by Vincent Pelletier
16589 <subdino2004@yahoo.fr>.
16591 * fs/fshelp.c (grub_fshelp_find_file): Don't free `oldnode' when
16592 it is not allocated. Reported by Vincent Pelletier
16593 <subdino2004@yahoo.fr>.
16595 * normal/cmdline.c (grub_tab_complete): Add a blank line to the
16596 output so the output looks better.
16598 2004-12-04 Marco Gerards <metgerards@student.han.nl>
16600 Modulize the partition map support and add support for the amiga
16603 * commands/ls.c: Include <grub/partition.h> instead of
16604 <grub/machine/partition.h>.
16605 * kern/disk.c: Likewise.
16606 * kern/rescue.c: Likewise.
16607 * loader/i386/pc/chainloader.c: Likewise.
16608 * normal/cmdline.c: Likewise.
16609 * kern/powerpc/ieee1275/init.c: Likewise.
16610 (grub_machine_init): Call `grub_pc_partition_map_init',
16611 `grub_amiga_partition_map_init' and
16612 `grub_apple_partition_map_init'.
16613 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove
16614 `disk/i386/pc/partition.c'. Add `kern/partition.c'.
16615 (kernel_img_HEADERS): Remove `machine/partition.h'. Add
16616 `partition.h' and `pc_partition.h'.
16617 (grub_setup_SOURCES): Remove
16618 `disk/i386/pc/partition.c'. Add `kern/partition.c',
16619 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
16620 (grub_emu_SOURCES): Likewise.
16621 (pkgdata_MODULES): Add `amiga.mod', `apple.mod' and `pc.mod'.
16622 (amiga_mod_SOURCES, amiga_mod_CFLAGS, apple_mod_SOURCES)
16623 (apple_mod_CFLAGS, pc_mod_SOURCES, pc_mod_CFLAGS): New variables.
16624 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
16625 `disk/powerpc/ieee1275/partition.c'. Add `kern/partition.c',
16626 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
16627 (grubof_SOURCES): Likewise.
16628 * disk/i386/pc/partition.c: File removed.
16629 * disk/powerpc/ieee1275/partition.c: Likewise.
16630 * include/grub/powerpc/ieee1275/partition.h: Likewise.
16631 * include/grub/i386/pc/partition.h: Likewise.
16632 * kern/partition.c: New file.
16633 * partmap/amiga.c: Likewise.
16634 * partmap/apple.c: Likewise.
16635 * partmap/pc.c: Likewise.
16636 * include/grub/partition.h: Likewise..
16637 * include/grub/pc_partition.h: Likewise.
16638 * util/grub-emu.c: Include <grub/partition.h> instead of
16639 <grub/machine/partition.h>.
16640 (main): Call `grub_pc_partition_map_init',
16641 `grub_amiga_partition_map_init' and
16642 `grub_apple_partition_map_init' and deinitialize afterwards.
16643 * util/i386/pc/biosdisk.c: Include `#include
16644 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
16645 `<grub/machine/partition.h>'.
16646 * util/i386/pc/grub-setup.c: Likewise.
16647 * util/i386/pc/biosdisk.c: Likewise.
16648 (grub_util_biosdisk_get_grub_dev): Only access the PC specific
16649 partition information in case of a PC partition.
16650 * util/i386/pc/grub-setup.c: Include `#include
16651 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
16652 `<grub/machine/partition.h>'.
16653 (setup): Only access the PC specific partition information in case
16656 2004-11-17 Hollis Blanchard <hollis@penguinppc.org>
16658 * kern/powerpc/ieee1275/init.c (grub_setjmp): Remove function.
16659 (grub_longjmp): Likewise.
16660 * include/grub/powerpc/setjmp.h (grub_jmp_buf): Set array size to
16662 * normal/powerpc/setjmp.S: New file.
16663 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
16664 `normal/powerpc/setjmp.S'.
16665 (grubof_CFLAGS): Add `-DGRUBOF'.
16666 * include/grub/setjmp.h [GRUB_UTIL]: Changed condition to
16667 [GRUB_UTIL && !GRUBOF].
16669 2004-11-16 Marco Gerards <metgerards@student.han.nl>
16671 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Skip any
16672 property named `name'. Correctly handle the error returned by
16673 `grub_ieee1275_finddevice' if a device can not be opened.
16675 2004-11-02 Hollis Blanchard <hollis@penguinppc.org>
16677 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_readkey): Test
16678 `actual' for negativity.
16679 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
16682 2004-11-01 Marco Gerards <metgerards@student.han.nl>
16684 * term/i386/pc/vga.c (VGA_HEIGHT): Changed to 350.
16685 (PAGE_OFFSET): New macro.
16686 (CRTC_ADDR_PORT): Likewise.
16687 (CRTC_DATA_PORT): Likewise.
16688 (START_ADDR_HIGH_REGISTER): Likewise.
16689 (START_ADDR_LOW_REGISTER): Likewise.
16690 (GRAPHICS_ADDR_PORT): Likewise.
16691 (GRAPHICS_DATA_PORT): Likewise.
16692 (READ_MAP_REGISTER): Likewise.
16693 (INPUT_STATUS1_REGISTER): Likewise.
16694 (INPUT_STATUS1_VERTR_BIT): Likewise.
16695 (page): New variable.
16696 (wait_vretrace): New function.
16697 (set_read_map): Likewise.
16698 (set_start_address): Likewise.
16699 (grub_vga_init): Use mode 0x10 instead of mode 0x12. Switch to
16701 (check_vga_mem): Take the page into account.
16702 (write_char): Likewise.
16703 (write_cursor): Likewise.
16704 (scroll_up): Likewise. Copy the page to the page that is not
16705 shown and switch between both pages.
16706 (grub_vga_putchar): Fix off by one error.
16707 (grub_vga_cls): Wait for the vertical retrace. Take the page into
16710 2004-11-01 Marco Gerards <metgerards@student.han.nl>
16712 Add support for iso9660 (including rockridge).
16714 * conf/i386-pc.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
16715 (iso9660_mod_SOURCES): New variable.
16716 (iso9660_mod_CFLAGS): Likewise.
16717 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
16718 * include/grub/fs.h (grub_iso9660_init): New prototype.
16719 * util/grub-emu.c (main): Call `grub_iso9660_init'.
16720 * fs/iso9660.c: New file.
16722 * include/grub/misc.h (grub_strncat): New prototype.
16723 * kern/misc.c (grub_strncat): New function.
16725 * fs/hfs.c (grub_hfs_mount): Translate the error
16726 `GRUB_ERR_OUT_OF_RANGE' to `GRUB_ERR_BAD_FS'.
16727 * fs/jfs.c (grub_jfs_mount): Likewise.
16728 * fs/ufs.c (grub_ufs_mount): Likewise.
16730 2004-10-28 Hollis Blanchard <hollis@penguinppc.org>
16732 * boot/powerpc/ieee1275/cmain.c (cmain): Remove asm statements
16733 which initialized BAT registers.
16734 * boot/powerpc/ieee1275/ieee1275.c (IEEE1275_CALL_ENTRY_FN,
16735 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
16737 * include/grub/powerpc/ieee1275/ieee1275.h (IEEE1275_CALL_ENTRY_FN,
16738 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
16740 * kern/powerpc/ieee1275/openfw.c (grub_map): New function.
16741 (grub_mapclaim): Likewise.
16742 * loader/powerpc/ieee1275/linux.c (grub_load_linux): Use
16743 grub_mapclaim instead of grub_ieee1275_claim. Assign linux_addr by
16746 2004-10-19 Hollis Blanchard <hollis@penguinppc.org>
16748 * conf/powerpc-ieee1275.rmk (COMMON_ASFLAGS): Remove -fno-builtin.
16749 (COMMON_CFLAGS): Remove -fno-builtin and -D__ASSEMBLY__. Add
16750 -ffreestanding and -msoft-float.
16752 2004-10-15 Hollis Blanchard <hollis@penguinppc.org>
16754 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Do not
16755 append ":0" to devpath if the GRUB_IEEE1275_NO_PARTITION_0 flag is
16756 set in grub_ieee1275_flags.
16758 2004-10-14 Hollis Blanchard <hollis@penguinppc.org>
16760 * include/grub/powerpc/ieee1275/ieee1275.h (abort): Add function
16762 * kern/powerpc/ieee1275/init.c (grub_machine_init): Call
16763 grub_console_init first.
16764 Change the memory range used for grub_ieee1275_claim and
16765 grub_mm_init_region.
16766 Print an error message if the claim fails.
16767 Include <grub/misc.h>.
16769 2004-10-13 Hollis Blanchard <hollis@penguinppc.org>
16771 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_iterate):
16772 Call grub_children_iterate for device nodes of type `scsi',
16774 (grub_ofdisk_open): Remove manual device alias resolution.
16775 Fix memory leak when device cannot be opened.
16776 * include/grub/powerpc/ieee1275/ieee1275.h
16777 (grub_children_iterate): New prototype.
16778 * kern/powerpc/ieee1275/openfw.c (grub_children_iterate):
16780 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
16781 Return -1 if args.size was -1.
16783 2004-10-11 Hollis Blanchard <hollis@penguinppc.org>
16785 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_flags): New global.
16786 (cmain): Accept 3 parameters. Test for 0xdeadbeef, indicating Old
16787 World Macintosh. If Old Wold, set flag in grub_ieee1275_flags; claim
16788 Open Firmware's memory for it; claim memory from _start to _end.
16789 * boot/powerpc/ieee1275/crt0.S (__bss_start): New extern.
16790 (_end): New extern.
16791 (_start): Zero BSS from __bss_start to _end.
16792 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
16794 (GRUB_IEEE1275_NO_PARTITION_0): New #define.
16796 2004-10-11 Hollis Blanchard <hollis@penguinppc.org>
16798 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): Return
16799 -1 if args.base was -1.
16801 2004-10-08 Hollis Blanchard <hollis@penguinppc.org>
16803 * term/powerpc/ieee1275/ieee1275.c (grub_ofconsole_cls): Use an ANSI
16804 escape sequence instead of a literal ^L. Also call
16805 grub_ofconsole_gotoxy.
16807 2004-10-03 Hollis Blanchard <hollis@penguinppc.org>
16809 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): change
16810 void * arguments to grub_addr_t. All callers updated. Also make
16811 the `result' argument optional.
16812 (grub_ieee1275_release): change void * arguments to grub_addr_t.
16813 All callers updated.
16815 2004-09-22 Hollis Blanchard <hollis@penguinppc.org>
16817 * commands/ls.c (grub_ls_list_files): Use the string following the
16818 initial ')', if present, as the filesystem path.
16819 * kern/rescue.c (grub_rescue_cmd_ls): Likewise.
16821 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): List crt0.S first.
16823 2004-09-18 Yoshinori K. Okuji <okuji@enbug.org>
16825 Make the source code of the menu interface more readable.
16827 * normal/menu.c: Include grub/mm.h.
16828 (TERM_WIDTH): New macro.
16829 (TERM_HEIGHT): Likewise.
16830 (TERM_INFO_HEIGHT): Likewise.
16831 (TERM_MARGIN): Likewise.
16832 (TERM_SCROLL_WIDTH): Likewise.
16833 (TERM_TOP_BORDER_Y): Likewise.
16834 (TERM_LEFT_BORDER_X): Likewise.
16835 (TERM_BORDER_WIDTH): Likewise.
16836 (TERM_MESSAGE_HEIGHT): Likewise.
16837 (TERM_BORDER_HEIGHT): Likewise.
16838 (TERM_NUM_ENTRIES): Likewise.
16839 (TERM_FIRST_ENTRY_Y): Likewise.
16840 (TERM_ENTRY_WIDTH): Likewise.
16841 (TERM_CURSOR_X): Likewise.
16842 (draw_border): Use macros instead of magic numbers.
16843 (print_entry): Likewise.
16844 (print_entries): Likewise.
16845 (run_menu): Likewise. Also, handle the key 'e'.
16846 (run_menu_entry): Ignore empty command lines.
16847 (print_message): Added a new argument EDIT. If EDIT is true,
16848 print a different message.
16849 (init_page): Likewise.
16850 (edit_menu_entry): New function. Not implemented yet.
16852 2004-09-17 Marco Gerards <metgerards@student.han.nl>
16854 Add `linux.mod' and `multiboot.mod' so linux and multiboot kernels
16855 can be loaded from normal mode.
16857 * conf/i386-pc.rmk (pkgdata_MODULES): Add `linux.mod' and
16859 (linux_mod_SOURCES, linux_mod_CFLAGS, multiboot_mod_SOURCES)
16860 (multiboot_mod_CFLAGS): New variables.
16861 * loader/i386/pc/linux_normal.c: New file.
16862 * loader/i386/pc/multiboot_normal.c: Likewise.
16864 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Don't use the
16865 attribute `unused'.
16867 * fs/ext2.c (grub_ext2_iterate_dir): Fix typos in inode type. Use
16868 `fdiro' to read the mode information from instead of `diro'.
16870 * fs/fshelp.c (grub_fshelp_find_file): Set type to foundtype after
16871 looking up a symlink.
16873 * include/grub/normal.h (GRUB_COMMAND_FLAG_NO_ARG_PARSE): New
16875 * normal/command.c (grub_command_execute): Don't parse the
16876 arguments when `GRUB_COMMAND_FLAG_NO_ARG_PARSE' is set in the
16877 flags of the command.
16879 * normal/menu.c (grub_menu_run): Fix typo.
16881 2004-09-14 Hollis Blanchard <hollis@penguinppc.org>
16883 * kern/powerpc/ieee1275/init.c (abort): Trap into Open Firmware.
16885 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_gotoxy): Use
16886 `y + 1' instead of `y - 1'.
16888 * conf/powerpc-ieee1275.rmk (grubof_LDFLAGS): Add `-N' and `-S'.
16890 2004-09-14 Yoshinori K. Okuji <okuji@enbug.org>
16892 From Hollis Blanchard <hollis@penguinppc.org>:
16893 * kern/misc.c (memmove): New alias for grub_memmove.
16894 (memcmp): New alias for grub_memcmp.
16895 (memset): New alias for grub_memset.
16896 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
16897 Change "int handle" to "grub_ieee1275_phandle_t handle".
16898 * include/grub/powerpc/ieee1275/ieee1275.h
16899 (grub_ieee1275_get_property): Likewise.
16901 2004-09-12 Tomas Ebenlendr <ebik@ucw.cz>
16903 Added normal mode command `chainloader' as module chain.mod, which
16904 depends on normal.mod and _chain.mod.
16906 * conf/i386-pc.rmk (pkgdata_MODULES): Add `chain.mod'.
16907 (chain_mod_SOURCES, chain_mod_CFLAGS): Variables added.
16908 * include/grub/i386/pc/loader.h (grub_rescue_cmd_chainloader):
16910 * loader/i386/pc/chainloader.c (grub_rescue_cmd_chainloader): All
16911 but arguments parsing moved to ...
16912 (grub_chainloader_cmd): ... here. New function.
16913 * include/grub/i386/pc/chainloader.h: New file.
16914 * loader/i386/pc/chainloader_normal.c: Likewise.
16916 2004-09-11 Marco Gerards <metgerards@student.han.nl>
16918 * conf/i386-pc.rmk (kernel_img_SOURCES): Added kern/fshelp.c.
16919 (grub_mkimage_LDFLAGS): Likewise.
16920 (grub_emu_SOURCES): Likewise.
16921 (kernel_img_HEADERS): Added fshelp.h.
16922 * fs/ext2.c: Include <grub/fshelp.h>.
16923 (FILETYPE_REG): New macro.
16924 (FILETYPE_INO_REG): Likewise.
16925 (grub_ext_sblock): Renamed to `grub_ext2_sblock'.
16927 (ext2_block_group): Renamed to `grub_ext2_block_group'. Changed
16929 (grub_fshelp_node): New struct.
16930 (grub_ext2_data): Added member `diropen'. Changed member `inode'
16932 (grub_ext2_get_file_block): Removed function.
16933 (grub_ext2_read_block): New function.
16934 (grub_ext2_read_file): Replaced parameter `data' by `node'.
16935 This function was written.
16936 (grub_ext2_mount): Read the root inode. Create a diropen struct.
16937 (grub_ext2_find_file): Removed function.
16938 (grub_ext2_read_symlink): New function.
16939 (grub_ext2_iterate_dir): Likewise.
16940 (grub_ext2_open): Rewritten.
16941 (grub_ext2_dir): Rewritten.
16942 * include/grub/fshelp.h: New file.
16943 * fs/fshelp.c: Likewise.
16945 2004-09-10 Yoshinori K. Okuji <okuji@enbug.org>
16947 * normal/menu.c: Include grub/loader.h and grub/machine/time.h.
16948 (print_message): Add a missing newline.
16949 (run_menu): Added timeout support.
16950 (run_menu_entry): New local function.
16951 (grub_menu_run): Added support for booting.
16953 * kern/loader.c (grub_loader_is_loaded): New function.
16955 * include/grub/powerpc/ieee1275/time.h: Include grub/symbol.h.
16956 (grub_get_rtc): Exported.
16958 * include/grub/i386/pc/time.h: Include grub/symbol.h.
16959 (grub_get_rtc): Exported.
16961 * include/grub/normal.h (struct grub_command_list): Remove
16962 constant from the member `command'.
16964 * include/grub/loader.h (grub_loader_is_loaded): Declared.
16966 * include/grub/err.h (GRUB_ERR_INVALID_COMMAND): New constant.
16968 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/time.h.
16970 2004-08-28 Marco Gerards <metgerards@student.han.nl>
16972 Add support for the JFS filesystem.
16974 * fs/jfs.c: New file.
16975 * include/grub/fs.h (grub_jfs_init): New prototype.
16976 (grub_jfs_fini): New prototype.
16977 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/jfs.c.
16978 (grub_emu_SOURCES): Likewise.
16979 (pkgdata_MODULES): Add jfs.mod.
16980 (jfs_mod_SOURCES): New variable.
16981 (jfs_mod_CFLAGS): Likewise.
16982 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs.jfs.c.
16983 (grubof_SOURCES): Likewise.
16984 * util/grub-emu.c (main): Initialize and deinitialize JFS support.
16986 * fs/fat.c (grub_fat_find_dir): Convert the filename little
16987 endian to the host endian.
16988 (grub_fat_utf16_to_utf8): Move function from there...
16989 * kern/misc.c (grub_utf16_to_utf8): ...to here. Do not convert
16990 the endianness of the source string anymore.
16991 * include/grub/misc.h (grub_utf16_to_utf8): New prototype.
16993 2004-08-24 Marco Gerards <metgerards@student.han.nl>
16995 * commands/boot.c (grub_boot_init) [GRUB_UTIL]: Make conditional.
16996 (grub_boot_fini) [GRUB_UTIL]: Likewise.
16997 (GRUB_MOD_INIT) [!GRUB_UTIL]: Likewise.
16998 (GRUB_MOD_FINI) [!GRUB_UTIL]: Likewise.
17000 * fs/hfs.c (grub_hfs_find_node): Add a prototype for `node_found'.
17001 (grub_hfs_iterate_dir): Make the function static. Add prototypes
17002 for `node_found' and `it_dir'.
17003 (grub_hfs_dir): Add prototype for `dir_hook'.
17005 * fs/minix.c (grub_minix_get_file_block): Add prototype for
17006 `grub_get_indir'. Rename `indir' in two blocks to `indir16'
17007 and `indir32' to silence a gcc warning.
17009 * include/grub/fs.h (grub_hfs_init): New prototype.
17010 (grub_hfs_fini): Likewise.
17013 2004-08-21 Yoshinori K. Okuji <okuji@enbug.org>
17015 Each disk device has its own id now. This is useful to make use
17016 of multiple disk devices.
17018 * include/grub/disk.h (grub_disk_dev_id): New enum.
17019 (GRUB_DISK_DEVICE_BIOSDISK_ID): New constant.
17020 (GRUB_DISK_DEVICE_OFDISK_ID): Likewise.
17022 * disk/i386/pc/biosdisk.c (grub_biosdisk_dev): Specify
17023 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
17025 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_dev): Specify
17026 GRUB_DISK_DEVICE_OFDISK_ID as an id.
17028 * util/i386/pc/biosdisk.c (grub_util_biosdisk_dev): Specify
17029 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
17031 * include/grub/disk.h (struct grub_disk_dev): Added a new member
17032 "id" which is used by the cache manager.
17034 * normal/main.c (grub_normal_init_page): Use "GNU GRUB" instead
17037 2004-08-18 Marco Gerards <metgerards@student.han.nl>
17039 * fs/hfs.c: New file.
17040 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/hfs.c.
17041 (grub_emu_SOURCES): Likewise.
17042 (pkgdata_MODULES): Add hfs.mod.
17043 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/hfs.c.
17044 (grubof_SOURCES): Likewise.
17045 * util/grub-emu.c (main): Initialize and deinitialize HFS support.
17047 * include/grub/misc.h (grub_strncasecmp): Add prototype.
17048 * kern/misc.c (grub_strncasecmp): Add function.
17050 2004-08-14 Marco Gerards <metgerards@student.han.nl>
17052 * include/grub/arg.h (GRUB_ARG_OPTION_OPTIONAL): Surround macro
17055 * fs/ext2.c (FILETYPE_UNKNOWN): New macro.
17056 (grub_ext2_dir): In case the directory entry type is unknown, read
17059 2004-08-02 Peter Bruin <pjbruin@dds.nl>
17061 * loader/powerpc/ieee1275/linux.c (grub_linux_init): Pass
17062 grub_load_linux instead of grub_rescue_cmd_linux as second
17063 argument of grub_rescue_register_command.
17065 * Makefile.in (RMKFILES): Add conf/powerpc-ieee1275.rmk.
17067 2004-07-27 Marco Gerards <metgerards@student.han.nl>
17069 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_release): New
17071 * commands/boot.c: Remove the check for `GRUB_UTIL'.
17072 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
17073 `loader/powerpc/ieee1275/linux.c',
17074 `loader/powerpc/ieee1275/linux_normal.c' and `commands/boot.c'.
17075 * include/grub/powerpc/ieee1275/ieee1275.h
17076 (grub_ieee1275_release): New prototype.
17077 * include/grub/powerpc/ieee1275/loader.h: Rewritten.
17078 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize
17079 normal, boot, linux and linux_normal.
17080 * loader/powerpc/ieee1275/linux.c: New file.
17081 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
17083 2004-07-12 Marco Gerards <metgerards@student.han.nl>
17085 * normal/arg.c (grub_arg_parse): Correct error handling after
17086 reallocating the argumentlist (check if `argl' is not null instead
17087 of checking if `args' is not null).
17088 * kern/mm.c (grub_realloc): Return the same pointer when using the
17089 same region, instead of returning the header address.
17091 2004-07-11 Marco Gerards <metgerards@student.han.nl>
17093 * disk/powerpc/ieee1275/partition.c (grub_partition_iterate): Skip
17094 one block instead of two when looking for the initial partition.
17095 (grub_partition_probe): Initialize the local variable `p' with 0.
17096 Use base 10 for the grub_strtoul call.
17097 * kern/misc.c (grub_strncpy): Fix off by one bug. Eliminated the
17098 need for one local variable.
17099 (grub_strtoul): Don't add the new value to `num', instead of that
17102 2004-07-11 Marco Gerards <metgerards@student.han.nl>
17104 * conf/i386-pc.rmk (pkgdata_IMAGE): Add pxeboot.img.
17105 (pxeboot_img_SOURCES): New variable.
17106 (pxeboot_img_ASFLAGS): Likewise.
17107 (pxeboot_img_LDFLAGS): Likewise.
17108 * boot/i386/pc/pxeboot.S: New file. Based on pxeloader.S from
17109 GRUB Legacy and boot.S. Adopted for GRUB 2 by lode leroy
17110 <lode_leroy@hotmail.com>.
17112 2004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
17114 * kern/rescue.c (grub_enter_rescue_mode): Don't continue when
17115 there was no input.
17117 2004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
17119 * normal/cmdline.c (grub_set_history): Fix off by one bug. Fixed
17120 the history buffer logic.
17122 2004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
17124 * fs/ext2.c (FILETYPE_INO_MASK, FILETYPE_INO_DIRECTORY)
17125 (FILETYPE_INO_SYMLINK): New macros.
17126 (grub_ext2_find_file): Check if the node is a directory using the
17127 inode stat information instead of using the filetype in the
17128 dirent. Exclude the first character of an absolute symlink.
17129 (grub_ext2_dir): Mask out the filetype part of the mode member of
17132 2004-05-24 Marco Gerards <metgerards@student.han.nl>
17134 Add support for UFS version 1 and 2. Add support for the minix
17135 filesystem version 1 and 2, both the variants with 14 and 30 long
17138 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ufs.c and
17140 (grub_emu_SOURCES): Likewise.
17141 (pkgdata_MODULES): Add ufs.mod and minix.mod.
17142 (ufs_mod_SOURCES): New variable.
17143 (ufs_mod_CFLAGS): Likewise.
17144 (minix_mod_SOURCES): Likewise.
17145 (minix_mod_CFLAGS): Likewise.
17146 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/ufs.c and
17148 (grubof_SOURCES): Likewise.
17149 * fs/ufs.c: New file.
17150 * fs/minix.c: New file.
17151 * include/grub/fs.h (grub_ufs_init): New prototype.
17152 (grub_ufs_fini): Likewise.
17153 (grub_minix_init): Likewise.
17154 (grub_minix_fini): Likewise.
17155 * util/grub-emu.c (main): Initialize and deinitialize UFS and
17158 2004-04-30 Jeroen Dekkers <jeroen@dekkers.cx>
17160 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add normal/arg.c,
17161 commands/ls.c, commands/terminal.c, commands/boot.c,
17162 commands/cmp.c and commands/cat.c.
17163 (grubof_LDFLAGS): Add -nostdlib -static-libgcc -lgcc.
17165 * kern/powerpc/ieee1275/init.c: Include "grub/env.h" instead of
17168 2004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
17170 All symbols prefixed with PUPA_ and pupa_ are renamed to GRUB_
17171 and grub_, respectively. Because the conversion is trivial and
17172 mechanical, I omit the details here. Please refer to the CVS
17173 if you need more information.
17175 2004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
17177 * include/pupa: Renamed to ...
17178 * include/grub: ... this.
17179 * util/i386/pc/pupa-mkimage.c: Renamed to ...
17180 * util/i386/pc/grub-mkimage.c: ... this.
17181 * util/i386/pc/pupa-setup.c: Renamed to ...
17182 * util/i386/pc/grub-setup.c: ... this.
17183 * util/pupa-emu.c: Renamed to ...
17184 * util/grub-emu.c: ... this.
17186 2004-03-29 Marco Gerards <metgerards@student.han.nl>
17188 Add support for the newworld apple macintosh (PPC). This has been
17189 tested on the powerbook 2000 only. It only adds support for
17190 generic ieee1275 functions, console and disk support. This should
17191 be easy to port to other architectures with support for Open
17194 * configure.ac: Accept the powerpc as host_cpu. In the case of
17195 the powerpc cpu set the host_vendor to ieee1275. Make sure the i386
17196 specific tests are only executed while building for the i386.
17197 Inverse test for crosscompile.
17198 * genmk.rb (Utility): Allow assembler files.
17199 * normal/cmdline.c (pupa_tab_complete): Reset pupa_errno.
17200 * conf/powerpc-ieee1275.rmk: New file.
17201 * disk/powerpc/ieee1275/ofdisk.c: Likewise.
17202 * disk/powerpc/ieee1275/partition.c: Likewise.
17203 * include/pupa/powerpc/ieee1275/biosdisk.h: Likewise.
17204 * include/pupa/powerpc/ieee1275/console.h: Likewise.
17205 * include/pupa/powerpc/ieee1275/partition.h: Likewise.
17206 * include/pupa/powerpc/ieee1275/time.h: Likewise.
17207 * include/pupa/powerpc/ieee1275/util/biosdisk.h: Likewise.
17208 * include/pupa/powerpc/ieee1275/multiboot.h: Likewise.
17209 * include/pupa/powerpc/ieee1275/loader.h
17210 * include/pupa/powerpc/setjmp.h: Likewise.
17211 * include/pupa/powerpc/types.h: Likewise.
17212 * kern/powerpc/ieee1275/init.c: Likewise.
17213 * kern/powerpc/ieee1275/openfw.c: Likewise.
17214 * term/powerpc/ieee1275/ofconsole.c: Likewise.
17216 These files were written by Johan Rydberg
17217 (jrydberg@night.trouble.net) and I only modified them slightly.
17219 * boot/powerpc/ieee1275/cmain.c: New file.
17220 * boot/powerpc/ieee1275/crt0.S: Likewise.
17221 * boot/powerpc/ieee1275/ieee1275.c: Likewise.
17222 * include/pupa/powerpc/ieee1275/ieee1275.h: Likewise.
17224 2004-03-14 Jeroen Dekkers <jeroen@dekkers.cx>
17226 * Makefile.in: Update copyright.
17227 * genmodsrc.sh: Likewise.
17228 * gensymlist.sh: Likewise.
17229 * term/i386/pc/vga.c: Indent correctly.
17231 * util/i386/pc/pupa-mkimage.c (usage): Use PACKAGE_BUGREPORT as
17232 bugreporting address.
17233 * util/i386/pc/pupa-setup.c (usage): Likewise,
17234 (main): Call pupa_ext2_init and pupa_ext2_fini.
17236 * fs/fat.c (log2): Renamed to ...
17237 (fat_log2): ... this.
17238 All callers changed.
17239 * kern/misc.c (memcpy): Alias to pupa_memmove.
17240 * loader/i386/pc/multiboot.c (pupa_rescue_cmd_multiboot): Fix
17242 * util/console.c (pupa_ncurses_fini): Return 0.
17244 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open)[__linux__]:
17245 Move fail label here.
17246 [__GNU__]: Don't warn when using stat.
17247 (open_device)[!__linux__]: Check if FD < 0 instead of !FD.
17248 (pupa_util_biosdisk_get_pupa_dev)[__GNU__]: Change type of N to
17249 long int. Use strtol instead of strtoul.
17251 2004-03-14 Marco Gerards <metgerards@student.han.nl>
17253 * commands/boot.c: New file.
17254 * commands/cat.c: Likewise.
17255 * commands/cmp.c: Likewise.
17256 * commands/ls.c: Likewise.
17257 * commands/terminal.c: Likewise.
17258 * normal/command.c: Include <pupa/env.h> and <pupa/dl.h>.
17259 (pupa_register_command): Changed interface to match the new
17261 (pupa_command_execute): Changed (almost rewritten) so it uses
17262 pupa_split_command. Added support for setting variables using the
17264 (rescue_command): Changed to work with the new argument parser.
17265 (terminal_command): Moved from here to commands/terminal.c.
17266 (set_command): New function.
17267 (unset_command): New function.
17268 (insmod_command): New function.
17269 (rmmod_command): New function.
17270 (lsmod_command): New function.
17271 (pupa_command_init): Don't initialize the command terminal
17272 anymore. Initialize the commands set, unset, insmod, rmmod and
17274 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/env.c.
17275 (kernel_img_HEADERS): Add arg.h and env.h.
17276 (pupa_mkimage_LDFLAGS): Add kern/env.c.
17277 (pupa_emu_SOURCES): Add kern/env.c, commands/ls.c,
17278 commands/terminal.c commands/boot.c commands/cmp.c commands/cat.c,
17280 (pkgdata_MODULES): Add ls.mod, boot.mod, cmp.mod, cat.mod and
17282 (normal_mod_SOURCES): Add normal/arg.c and normal/arg.c.
17283 (boot_mod_SOURCES): New variable.
17284 (terminal_mod_SOURCES): Likewise.
17285 (ls_mod_SOURCES): Likewise.
17286 (cmp_mod_SOURCES): Likewise.
17287 (cat_mod_SOURCES): Likewise.
17289 * normal/arg.c: New file.
17290 * kern/env.c: Likewise.
17291 * include/pupa/arg.h: Likewise.
17292 * include/pupa/env.h: Likewise.
17293 * font/manager.c (font_command): Changed to match argument parsing
17295 (PUPA_MOD_INIT): Likewise.
17296 * hello/hello.c (pupa_cmd_hello): Likewise.
17297 (PUPA_MOD_INIT): Likewise.
17298 * include/pupa/disk.h: Include <pupa/device.h>.
17299 (pupa_print_partinfo): New prototype.
17300 * include/pupa/dl.h (pupa_dl_set_prefix): Prototype removed.
17301 (pupa_dl_get_prefix): Likewise.
17302 * include/pupa/misc.h: Include <pupa/err.h>.
17303 (pupa_isgraph): New prototype.
17304 (pupa_isdigit): Likewise.
17305 (pupa_split_cmdline): Likewise.
17306 * include/pupa/normal.h: Include <pupa/arg.h>.
17307 (pupa_command): Changed the prototype of the member `func' to
17308 match the argument parsing interface. Added member `options'.
17309 (pupa_register_command): Updated to match function.
17310 (pupa_arg_parse): New prototype.
17311 (pupa_hello_init) [PUPA_UTIL]: New prototype.
17312 (pupa_hello_fini) [PUPA_UTIL]: Likewise.
17313 (pupa_ls_init) [PUPA_UTIL]: Likewise.
17314 (pupa_ls_fini) [PUPA_UTIL]: Likewise.
17315 (pupa_cat_init) [PUPA_UTIL]: Likewise.
17316 (pupa_cat_fini) [PUPA_UTIL]: Likewise.
17317 (pupa_boot_init) [PUPA_UTIL]: Likewise.
17318 (pupa_boot_fini) [PUPA_UTIL]: Likewise.
17319 (pupa_cmp_init) [PUPA_UTIL]: Likewise.
17320 (pupa_cmp_fini) [PUPA_UTIL]: Likewise.
17321 (pupa_terminal_init) [PUPA_UTIL]: Likewise.
17322 (pupa_terminal_fini) [PUPA_UTIL]: Likewise.
17323 * kern/disk.c: Include <pupa/file.h>.
17324 (pupa_print_partinfo): New function.
17325 * kern/dl.c: Include <pupa/env.h>.
17326 (pupa_dl_dir): Variable removed.
17327 (pupa_dl_load): Use the environment variable `prefix' instead of
17328 the variable pupa_dl_dir.
17329 (pupa_dl_set_prefix): Function removed.
17330 (pupa_dl_get_prefix): Likewise.
17331 * kern/i386/pc/init.c: Include <pupa/env.h>.
17332 (pupa_machine_init): Use the environment variable `prefix' instead of
17333 using pupa_dl_set_prefix to set the prefix.
17334 * kern/main.c: Include <pupa/env.h>.
17335 (pupa_set_root_dev): Use the environment variable `prefix' instead of
17336 using pupa_dl_get_prefix to get the prefix.
17337 * kern/misc.c: Include <pupa/env.h>.
17338 (pupa_isdigit): New function.
17339 (pupa_isgraph): Likewise.
17340 (pupa_ftoa): Likewise.
17341 (pupa_vsprintf): Added support for printing values of the type
17342 `double'. Make it possible to format variable output when using
17343 formatting like `%1.2%f'.
17344 (pupa_split_cmdline): New function.
17345 * kern/rescue.c: Include <pupa/env.h>.
17346 (next_word): Removed function.
17347 (pupa_rescue_cmd_prefix): Likewise.
17348 (pupa_rescue_cmd_set): New function.
17349 (pupa_rescue_cmd_unset): New function.
17350 (pupa_enter_rescue_mode): Use the `pupa_split_cmdline' function to
17351 split the command line instead of splitting it here. Added
17352 support for setting variables using the syntax `foo=bar'. Don't
17353 initialize the prefix command anymore. Initialized the set and
17355 * normal/cmdline.c: Include <pupa/env.h>.
17356 (pupa_tab_complete): Added prototypes for print_simple_completion,
17357 print_partition_completion, add_completion, iterate_commands,
17358 iterate_dev, iterate_part and iterate_dir. Moved code to print
17359 partition information from here to kern/disk.c.
17360 (pupa_cmdline_run): Don't check if the function exists anymore.
17361 * normal/main.c: Include <pupa/env.h>.
17362 (pupa_rescue_cmd_normal): Use the environment variable `prefix'
17363 instead of using pupa_dl_get_prefix to get the prefix.
17364 * term/i386/pc/vga.c: Include <pupa/arg.h>.
17365 (check_vga_mem): Cast pointers to `void *' to silence a gcc
17367 (pupa_vga_putchar) [! DEBUG_VGA]: Removed for this case.
17368 (pupa_vga_setcolor): Declare unused variables with `__attribute__
17369 ((unused))' to silence a gcc warning.
17370 (pupa_vga_setcolor): Likewise.
17371 (debug_command): Changed to match argument parsing
17373 * util/pupa-emu.c: Include <pupa/env.h>.
17374 (options): Added 0's for unused fields to silence a gcc warning.
17376 (main): Use the environment variable `prefix' instead of using
17377 pupa_dl_set_prefix to set the prefix. Initialize the commands ls,
17378 boot, cmp, cat and terminal. Finish the commands boot, cmp, cat
17381 * util/i386/pc/getroot.c: Include <pupa/i386/pc/util/biosdisk.h>.
17382 * util/misc.c: Include <malloc.h>.
17383 (pupa_malloc): Rewritten so errors are correctly reported.
17384 (pupa_realloc): Likewise.
17385 (pupa_memalign): Likewise.
17386 (pupa_mm_init_region): Declare unused variables with
17387 `__attribute__ ((unused))' to silence a gcc warning.
17388 * normal/i386/setjmp.S: Remove tab at the end of the file to
17389 silence a gcc warning.
17390 * loader/i386/pc/linux.c (pupa_rescue_cmd_initrd): Declare unused
17391 variables with `__attribute__ ((unused))' to silence a gcc
17393 * loader/i386/pc/multiboot.c (pupa_multiboot_unload): Make the
17394 local variable i unsigned to silence a gcc warning.
17396 * kern/term.c: Include <pupa/misc.h>.
17397 (pupa_more_lines): New variable.
17398 (pupa_more): Likewise.
17399 (pupa_putcode): When the pager is active pause at the end of every
17401 (pupa_set_more): New function.
17402 * include/pupa/term.h (pupa_set_more): New prototype.
17405 2004-03-07 Yoshinori K. Okuji <okuji@enbug.org>
17407 Now this project is GRUB 2 rather than PUPA. The location of
17408 the CVS repository was moved to GRUB's.
17410 * configure.ac: Use bug-grub as the reporting address.
17411 Use GRUB instead of PUPA.
17412 Change the version number to 1.90.
17414 2004-02-24 Yoshinori K. Okuji <okuji@enbug.org>
17416 * genkernsyms.sh: Updated copyright information.
17417 * genmk.rb: Likewise.
17418 * genmodsrc.sh: Likewise.
17419 * gensymlist.sh: Likewise.
17420 * boot/i386/pc/boot.S: Likewise.
17421 * boot/i386/pc/diskboot.S: Likewise.
17422 * disk/i386/pc/biosdisk.c: Likewise.
17423 * disk/i386/pc/partition.c: Likewise.
17424 * font/manager.c: Likewise.
17425 * fs/ext2.c: Likewise.
17426 * fs/fat.c: Likewise.
17427 * include/pupa/boot.h: Likewise.
17428 * include/pupa/device.h: Likewise.
17429 * include/pupa/disk.h: Likewise.
17430 * include/pupa/dl.h: Likewise.
17431 * include/pupa/elf.h: Likewise.
17432 * include/pupa/err.h: Likewise.
17433 * include/pupa/file.h: Likewise.
17434 * include/pupa/font.h: Likewise.
17435 * include/pupa/fs.h: Likewise.
17436 * include/pupa/kernel.h: Likewise.
17437 * include/pupa/loader.h: Likewise.
17438 * include/pupa/misc.h: Likewise.
17439 * include/pupa/mm.h: Likewise.
17440 * include/pupa/net.h: Likewise.
17441 * include/pupa/normal.h: Likewise.
17442 * include/pupa/rescue.h: Likewise.
17443 * include/pupa/setjmp.h: Likewise.
17444 * include/pupa/symbol.h: Likewise.
17445 * include/pupa/term.h: Likewise.
17446 * include/pupa/types.h: Likewise.
17447 * include/pupa/i386/setjmp.h: Likewise.
17448 * include/pupa/i386/types.h: Likewise.
17449 * include/pupa/i386/pc/biosdisk.h: Likewise.
17450 * include/pupa/i386/pc/boot.h: Likewise.
17451 * include/pupa/i386/pc/console.h: Likewise.
17452 * include/pupa/i386/pc/init.h: Likewise.
17453 * include/pupa/i386/pc/kernel.h: Likewise.
17454 * include/pupa/i386/pc/linux.h: Likewise.
17455 * include/pupa/i386/pc/loader.h: Likewise.
17456 * include/pupa/i386/pc/memory.h: Likewise.
17457 * include/pupa/i386/pc/multiboot.h: Likewise.
17458 * include/pupa/i386/pc/partition.h: Likewise.
17459 * include/pupa/i386/pc/time.h: Likewise.
17460 * include/pupa/i386/pc/vga.h: Likewise.
17461 * include/pupa/i386/pc/util/biosdisk.h: Likewise.
17462 * include/pupa/util/getroot.h: Likewise.
17463 * include/pupa/util/misc.h: Likewise.
17464 * include/pupa/util/resolve.h: Likewise.
17465 * kern/device.c: Likewise.
17466 * kern/disk.c: Likewise.
17467 * kern/dl.c: Likewise.
17468 * kern/err.c: Likewise.
17469 * kern/file.c: Likewise.
17470 * kern/fs.c: Likewise.
17471 * kern/loader.c: Likewise.
17472 * kern/main.c: Likewise.
17473 * kern/misc.c: Likewise.
17474 * kern/mm.c: Likewise.
17475 * kern/rescue.c: Likewise.
17476 * kern/term.c: Likewise.
17477 * kern/i386/dl.c: Likewise.
17478 * kern/i386/pc/init.c: Likewise.
17479 * kern/i386/pc/lzo1x.S: Likewise.
17480 * kern/i386/pc/startup.S: Likewise.
17481 * loader/i386/pc/chainloader.c: Likewise.
17482 * loader/i386/pc/linux.c: Likewise.
17483 * loader/i386/pc/multiboot.c: Likewise.
17484 * normal/cmdline.c: Likewise.
17485 * normal/command.c: Likewise.
17486 * normal/main.c: Likewise.
17487 * normal/menu.c: Likewise.
17488 * normal/i386/setjmp.S: Likewise.
17489 * term/i386/pc/console.c: Likewise.
17490 * term/i386/pc/vga.c: Likewise.
17491 * util/console.c: Likewise.
17492 * util/genmoddep.c: Likewise.
17493 * util/misc.c: Likewise.
17494 * util/pupa-emu.c: Likewise.
17495 * util/resolve.c: Likewise.
17496 * util/unifont2pff.rb: Likewise.
17497 * util/i386/pc/biosdisk.c: Likewise.
17498 * util/i386/pc/getroot.c: Likewise.
17499 * util/i386/pc/pupa-mkimage.c: Likewise.
17500 * util/i386/pc/pupa-setup.c: Likewise.
17502 2004-02-15 Jeroen Dekkers <jeroen@dekkers.cx>
17504 * fs/ext2.c (pupa_ext2_read_file): Correct the value of BLOCKEND
17505 when it is EXT2_BLOCK_SIZE (data). New argument READ_HOOK, all
17506 callers changed. Set DATA->DISK->READ_HOOK to READ_HOOK before
17507 reading and reset it after reading.
17508 (pupa_ext2_close): Return PUPA_ERR_NONE.
17510 * include/pupa/i386/pc/linux.h (PUPA_LINUX_INITRD_MAX_ADDRESS):
17512 (struct linux_kernel_header): Add kernel_version and
17514 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Check whether
17515 pupa_file_read succeeds.
17516 (pupa_rescue_cmd_initrd): Implement.
17518 2003-12-03 Marco Gerards <metgerards@student.han.nl>
17520 * fs/ext2.c (pupa_ext2_label): New function.
17521 (pupa_ext2_fs): Added label.
17522 * fs/fat.c (pupa_fat_label): New function.
17523 (pupa_fat_fs): Added label.
17524 * include/pupa/fs.h (struct pupa_fs): Added prototype label.
17526 * kern/misc.c (pupa_strndup): New function.
17527 * include/pupa/misc.h (pupa_strndup): New prototype.
17529 * include/pupa/normal.h: Include <pupa/err.h>.
17530 (pupa_set_history): New prototype.
17531 (pupa_iterate_commands): New prototype.
17532 * normal/cmdline.c: Include <pupa/machine/partition.h>,
17533 <pupa/disk.h>, <pupa/file.h>.
17534 (hist_size): New variable.
17535 (hist_lines): Likewise.
17536 (hist_end): Likewise.
17537 (hist_used): Likewise.
17538 (pupa_set_history): New function.
17539 (pupa_history_get): Likewise.
17540 (pupa_history_add): Likewise.
17541 (pupa_history_replace): Likewise.
17542 (pupa_tab_complete): Likewise.
17543 (pupa_cmdline_run): Added tab completion and history buffer. Tab
17544 completion shows partitionnames while completing partitions, this
17545 feature was suggested by Jeff Bailey.
17546 * normal/command.c (pupa_iterate_commands): New function.
17547 * normal/main.c (PUPA_DEFAULT_HISTORY_SIZE): New macro.
17548 (pupa_normal_init): Initialize history buffer.
17549 (PUPA_MOD_INIT): Likewise.
17550 (pupa_normal_fini): Free the history buffer.
17551 (PUPA_MOD_FINI): Likewise.
17553 * util/console.c (pupa_ncurses_getkey): Accept 127 as backspace
17556 * aclocal.m4 (pupa_I386_CHECK_REGPARM_BUG): New DEFUN.
17557 * configure.ac [i386]: Check for regparam bug.
17558 (NESTED_FUNC_ATTR) [! i386]: Defined.
17560 2003-11-17 Marco Gerards <metgerards@student.han.nl>
17562 * conf/i386-pc.rmk (sbin_UTILITIES): Added pupa-emu.
17563 (pupa_setup_SOURCES): Added util/i386/pc/getroot.c.
17564 (pupa_emu_SOURCES): New variable.
17565 (pupa_emu_LDFLAGS): Likewise.
17566 * include/pupa/fs.h (pupa_ext2_init) [PUPA_UTIL]: New prototype.
17567 (pupa_ext2_fini) [PUPA_UTIL]: Likewise.
17568 * include/pupa/normal.h (pupa_normal_init) [PUPA_UTIL]: Likewise.
17569 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
17570 * include/pupa/setjmp.h [PUPA_UTIL]: Include <setjmp.h>.
17571 (pupa_jmp_buf): New typedef.
17572 (pupa_setjmp) [PUPA_UTIL]: New macro.
17573 (pupa_longjmp) [PUPA_UTIL]: Likewise.
17574 * include/pupa/term.h (struct pupa_term): New member `refresh'.
17575 (pupa_refresh): New prototype.
17576 * include/pupa/util/getroot.h: New file.
17577 * kern/misc.c (pupa_vsprintf): Refresh the screen after updating
17579 * kern/rescue.c (pupa_rescue_get_command_line): Likewise.
17580 (pupa_rescue_cmd_cat): Likewise.
17581 (pupa_rescue_cmd_ls): Likewise.
17582 (pupa_rescue_cmd_testload): Likewise.
17583 (pupa_rescue_cmd_lsmod): Likewise.
17584 * normal/cmdline.c (pupa_cmdline_get): Likewise.
17585 * normal/menu.c (run_menu): Likewise.
17586 * kern/term.c (pupa_cls): Likewise.
17587 (pupa_refresh): New function.
17588 * normal/normal.c (pupa_normal_init) [PUPA_UTIL]: New function.
17589 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
17590 * util/console.c: New file.
17592 * util/i386/pc/getroot.c: New file.
17593 * util/i386/pc/pupa-setup.c: Include <pupa/util/getroot.h>.
17594 (pupa_putchar): New function.
17595 (pupa_refresh): Likewise.
17596 (xgetcwd): Function moved to ...
17597 (strip_extra_slashes): Likewise.
17598 (get_prefix): Likewise.
17599 * util/i386/pc/getroot.c: ... here.
17600 (find_root_device): Function moved and renamed to...
17601 * util/i386/pc/getroot.c (pupa_find_root_device): ... here.
17602 Changed all callers.
17603 * util/i386/pc/pupa-setup.c (guess_root_device): Function moved
17605 * util/i386/pc/getroot.c (pupa_guess_root_device): ... here.
17606 Changed all callers.
17607 * util/misc.c (pupa_memalign): New function.
17608 (pupa_mm_init_region): Likewise.
17609 (pupa_register_exported_symbols): Likewise.
17610 (pupa_putchar): Function removed.
17611 * util/pupa-emu.c: New file.
17613 2003-11-16 Jeroen Dekkers <jeroen@dekkers.cx>
17615 * conf/i386-pc.rmk (pkgdata_MODULES): Add _multiboot.mod.
17616 (_multiboot_mod_SOURCES): New variable.
17617 (_multiboot_mod_CFLAGS): Likewise.
17618 * loader/i386/pc/multiboot.c: New file.
17619 * include/pupa/i386/pc/multiboot.h: Likewise.
17620 * kern/i386/pc/startup.S: Include pupa/machine/multiboot.h.
17621 (pupa_multiboot_real_boot): New function.
17622 * include/pupa/i386/pc/loader.h: Include pupa/machine/multiboot.h.
17623 (pupa_multiboot_real_boot): New prototype.
17624 (pupa_rescue_cmd_multiboot): Likewise
17625 (pupa_rescue_cmd_module): Likewise.
17627 * kern/loader.c (pupa_loader_set): Continue when
17628 pupa_loader_unload_func() fails.
17629 (pupa_loader_unset): New function.
17630 * include/pupa/loader.h (pupa_loader_unset): New prototype.
17632 * kern/misc.c (pupa_stpcpy): New function.
17633 * include/pupa/misc.h (pupa_stpcpy): New prototype.
17635 2003-11-12 Marco Gerards <metgerards@student.han.nl>
17637 * disk/i386/pc/biosdisk.c (pupa_biosdisk_open): Correctly check
17638 for available extensions.
17640 * include/pupa/i386/pc/time.h: New file.
17641 * kern/disk.c: Include <pupa/machine/time.h>.
17642 (PUPA_CACHE_TIMEOUT): New macro.
17643 (pupa_last_time): New variable.
17644 (pupa_disk_open): Flush the cache when there was a timeout.
17645 (pupa_disk_close): Reset the timer.
17646 * kern/i386/pc/startup.S (pupa_get_rtc): Renamed from
17648 * util/misc.c: Include <sys/times.h>
17649 (pupa_get_rtc): New function.
17651 2003-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
17653 * fs/ext2.c (struct pupa_ext2_inode): Declare struct datablocks
17655 (pupa_ext2_get_file_block): Use blocks member.
17657 * fs/ext2.c (pupa_ext2_read_file): Only set skipfirst for the
17658 first block. Return -1 instead of pupa_errno on error.
17660 2003-10-27 Marco Gerards <metgerards@student.han.nl>
17662 * README: In the pupa-mkimage example use _chain instead of chain
17663 and ext2 instead of fat.
17664 * TODO: Replace ext2fs with jfs as an example. Add an item for
17665 adding journal playback for ext2fs.
17666 * conf/i386-pc.rmk (pupa_setup_SOURCES): Added fs/ext2.c.
17667 (pkgdata_MODULES): Added ext2.mod.
17668 (ext2_mod_SOURCES): New variable.
17669 (ext2_mod_CFLAGS): Likewise.
17670 * include/pupa/err.h (pupa_err_t): Added PUPA_ERR_SYMLINK_LOOP.
17671 * include/pupa/misc.h (pupa_strncpy): New prototype.
17672 (pupa_strcat): Likewise.
17673 (pupa_strncmp): Likewise.
17674 * kern/misc.c (pupa_strcat): Enable function.
17675 (pupa_strncpy): New function.
17676 (pupa_strncmp): Likewise.
17677 * fs/ext2.c: New file.
17679 * kern/disk.c (pupa_disk_read): Set pupa_errno to PUPA_ERR_NONE
17680 when the read failed before retrying.
17681 * util/i386/pc/biosdisk.c (_LARGEFILE_SOURCE): Removed.
17682 (_FILE_OFFSET_BITS): Likewise.
17683 * configure.ac: Added AC_SYS_LARGEFILE.
17685 2003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
17687 * genmk.rb (PModule#rule): Make sure to get only symbol names
17688 from the output of nm.
17689 Reported by Robert Millan <zeratul2@wanadoo.es>.
17691 2003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
17693 I forgot to check in these changes for a long time. This adds
17694 incomplete support for VGA console, and this is still very
17695 buggy. Also, a lot of consideration is required for I18N,
17696 UNICODE, and VGA font issues. Therefore, assume that this is
17697 such that "better than nothing".
17699 * font/manager.c: New file.
17700 * include/pupa/font.h: Likewise.
17701 * include/pupa/i386/pc/vga.h: Likewise.
17702 * term/i386/pc/vga.c: Likewise.
17703 * util/unifont2pff.rb: Likewise.
17705 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vga.h.
17706 (pkgdata_MODULES): Added vga.mod and font.mod.
17707 (vga_mod_SOURCES): New variables.
17708 (vga_mod_CFLAGS): Likewise.
17709 (font_mod_SOURCES): Likewise.
17710 (font_mod_CFLAGS): Likewise.
17712 * include/pupa/err.h (PUPA_ERR_BAD_FONT): New constant.
17714 * include/pupa/term.h: Include pupa/err.h.
17715 (struct pupa_term): Added init and fini.
17716 Changed the argument of putchar to pupa_uint32_t.
17718 * include/pupa/i386/pc/console.h: Include pupa/symbol.h.
17719 (pupa_console_real_putchar): New prototype.
17720 (pupa_console_putchar): Removed.
17721 (pupa_console_checkkey): Exported.
17722 (pupa_console_getkey): Likewise.
17724 * kern/misc.c (pupa_vsprintf): Add support for UNICODE
17727 * kern/term.c (pupa_term_set_current): Rewritten.
17728 (pupa_putchar): Likewise.
17729 (pupa_putcode): New function.
17731 * kern/i386/pc/startup.S (pupa_console_putchar): Renamed to ...
17732 (pupa_console_real_putchar): ... this.
17733 (pupa_vga_set_mode): New function.
17734 (pupa_vga_get_font): Likewise.
17736 * normal/command.c: Include pupa/term.h.
17737 (terminal_command): New function.
17738 (pupa_command_init): Register the command "terminal".
17740 * normal/menu.c (DISP_LEFT): Changed to a UNICODE value.
17741 (DISP_UP): Likewise.
17742 (DISP_RIGHT): Likewise.
17743 (DISP_DOWN): Likewise.
17744 (DISP_HLINE): Likewise.
17745 (DISP_VLINE): Likewise.
17746 (DISP_UL): Likewise.
17747 (DISP_UR): Likewise.
17748 (DISP_LL): Likewise.
17749 (DISP_LR): Likewise.
17751 * term/i386/pc/console.c (pupa_console_putchar): New function.
17753 2003-02-08 NIIBE Yutaka <gniibe@m17n.org>
17755 * util/resolve.c (pupa_util_resolve_dependencies): BUG
17756 FIX. Reverse the path_list.
17758 * include/pupa/normal.h: Export pupa_register_command and
17759 pupa_unregister_command.
17761 * hello/hello.c (pupa_cmd_hello): New module.
17762 * conf/i386-pc.rmk: Added hello.mod.
17764 2003-01-31 Yoshinori K. Okuji <okuji@enbug.org>
17766 * kern/i386/pc/lzo1x.S: New file.
17768 * util/i386/pc/pupa-mkimage.c: Include lzo1x.h.
17769 (compress_kernel): New variable.
17770 (generate_image): Heavily modified to support compressing a
17771 large part of the core image.
17773 * util/misc.c (pupa_util_read_image): Fix a file descriptor
17775 (pupa_util_load_image): New function.
17777 * kern/i386/pc/startup.S: Include pupa/machine/kernel.h.
17778 (pupa_compressed_size): New variable.
17779 (codestart): Enable Gate A20 here.
17780 Decompress the compressed part of the core image.
17781 Rearrange the code to put functions and variables which are
17782 required for initialization in the non-compressed part.
17785 * kern/i386/pc/init.c (pupa_machine_init): Don't enable Gate A20
17788 * include/pupa/util/misc.h (pupa_util_write_image): Declared.
17790 * include/pupa/i386/pc/kernel.h
17791 (PUPA_KERNEL_MACHINE_COMPRESSED_SIZE): New macro.
17792 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): Increased by 4.
17793 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
17794 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
17795 (PUPA_KERNEL_MACHINE_RAW_SIZE): New macro.
17797 * conf/i386-pc.rmk (pupa_mkimage_LDFLAGS): New variable.
17799 * genmk.rb (Image#rule): Put LDFLAGS at the end of a line.
17800 (Utility#rule): Likewise.
17802 * configure.ac: Check if LZO is available.
17804 2003-01-20 Yoshinori K. Okuji <okuji@enbug.org>
17806 * include/pupa/normal.h: New file.
17807 * include/pupa/setjmp.h: Likewise.
17808 * include/pupa/i386/setjmp.h: Likewise.
17809 * normal/cmdline.c: Likewise.
17810 * normal/command.c: Likewise.
17811 * normal/main.c: Likewise.
17812 * normal/menu.c: Likewise.
17813 * normal/i386/setjmp.S: Likewise.
17815 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Made global.
17816 (pupa_rescue_cmd_initrd): Likewise.
17818 * loader/i386/pc/chainloader.c (pupa_rescue_cmd_chainloader):
17821 * kern/i386/pc/startup.S (translation_table): New variable.
17822 (translate_keycode): New function.
17823 (pupa_console_getkey): Call translate_keycode.
17825 * kern/rescue.c (attempt_normal_mode): New function.
17826 (pupa_enter_rescue_mode): Attempt to execute the normal mode. If
17827 it failed, print a message.
17829 * kern/mm.c (pupa_real_malloc): Print more information when a
17830 free magic is broken.
17831 (pupa_free): If the first free header is not free actually, set
17834 * kern/main.c (pupa_load_normal_mode): Just load the module
17836 (pupa_main): Don't print the message
17837 "Entering into rescue mode..." here.
17839 * include/pupa/i386/pc/loader.h (pupa_rescue_cmd_initrd):
17841 (pupa_rescue_cmd_initrd): Likewise.
17842 (pupa_rescue_cmd_initrd): Likewise.
17844 * include/pupa/symbol.h (FUNCTION): Specify the type.
17845 (VARIABLE): Likewise.
17847 * include/pupa/err.h (pupa_err_t): Added
17848 PUPA_ERR_UNKNOWN_COMMAND.
17850 * include/pupa/dl.h (pupa_dl_set_prefix): Exported.
17851 (pupa_dl_get_prefix): Likewise.
17853 * conf/i386-pc.rmk (pkgdata_MODULES): Added normal.mod.
17854 Added _chain.mod and _linux.mod instead of chain.mod and
17856 (chain_mod_SOURCES): Renamed to ...
17857 (_chain_mod_SOURCES): ... this.
17858 (chain_mod_CFLAGS): Renamed to ...
17859 (_chain_mod_CFLAGS): ... this.
17860 (linux_mod_SOURCES): Renamed to ...
17861 (_linux_mod_SOURCES): ... this.
17862 (linux_mod_CFLAGS): Renamed to ...
17863 (_linux_mod_CFLAGS): ... this.
17864 (normal_mod_SOURCES): New variable.
17865 (normal_mod_CFLAGS): Likewise.
17866 (normal_mod_ASFLAGS): Likewise.
17868 2003-01-18 Yoshinori K. Okuji <okuji@enbug.org>
17870 * kern/rescue.c (pupa_rescue_cmd_rmmod): Call pupa_dl_unload, if
17873 * kern/dl.c (pupa_dl_ref): Refer depending modules
17875 (pupa_dl_unref): Unrefer depending modules recursively.
17876 Don't call pupa_dl_unload implicitly, because PUPA can crash if
17877 a module is unloaded before one depending on that module is
17879 (pupa_dl_unload): Unload depending modules explicitly,
17882 2003-01-17 Yoshinori K. Okuji <okuji@enbug.org>
17884 * include/pupa/i386/pc/linux.h: New file.
17885 * loader/i386/pc/linux.c: Likewise.
17887 * loader/i386/pc/chainloader.c (pupa_chainloader_boot_sector):
17889 (pupa_chainloader_unload): Return PUPA_ERR_NONE.
17890 (pupa_rescue_cmd_chainloader): Read the image to 0x7C00 instead
17891 of PUPA_CHAINLOADER_BOOT_SECTOR.
17893 * kern/i386/pc/startup.S: Include pupa/machine/linux.h.
17894 (pupa_linux_prot_size): New variable.
17895 (pupa_linux_tmp_addr): Likewise.
17896 (pupa_linux_real_addr): Likewise.
17897 (pupa_linux_boot_zimage): New function.
17898 (pupa_linux_boot_bzimage): Likewise.
17900 * kern/i386/pc/init.c (struct mem_region): New structure.
17901 (MAX_REGIONS): New macro.
17902 (mem_regions): New variable.
17903 (num_regions): Likewise.
17904 (pupa_os_area_addr): Likewise.
17905 (pupa_os_area_size): Likewise.
17906 (pupa_lower_mem): Likewise.
17907 (pupa_upper_mem): Likewise.
17908 (add_mem_region): New function.
17909 (compact_mem_regions): Likewise.
17910 (pupa_machine_init): Set PUPA_LOWER_MEM and PUPA_UPPER_MEM to
17911 the size of the conventional memory and that of so-called upper
17912 memory (before the first memory hole).
17913 Instead of adding each found region to free memory, use
17914 add_mem_region and add them after removing overlaps.
17915 Also, add only 1/4 of the upper memory to free memory. The rest
17916 is used for loading OS images. Maybe this is ad hoc, but this
17917 makes it much easier to relocate OS images when booting.
17919 * kern/rescue.c (pupa_rescue_cmd_module): Removed.
17920 (pupa_enter_rescue_mode): Don't register initrd and module.
17922 * kern/mm.c: Include pupa/dl.h.
17924 * kern/main.c: Include pupa/file.h and pupa/device.h.
17926 * kern/loader.c (pupa_loader_load_module_func): Removed.
17927 (pupa_loader_load_module): Likewise.
17929 * kern/dl.c (pupa_dl_load): Use the suffix ``.mod'' instead of
17932 * include/pupa/i386/pc/loader.h (pupa_linux_prot_size): Declared.
17933 (pupa_linux_tmp_addr): Likewise.
17934 (pupa_linux_real_addr): Likewise.
17935 (pupa_linux_boot_zimage): Likewise.
17936 (pupa_linux_boot_bzimage): Likewise.
17938 * include/pupa/i386/pc/init.h (pupa_lower_mem): Declared.
17939 (pupa_upper_mem): Likewise.
17940 (pupa_gate_a20): Don't export, because turning off Gate A20 in a
17941 module is too dangerous.
17943 * include/pupa/loader.h (pupa_os_area_addr): Declared.
17944 (pupa_os_area_size): Likewise.
17945 (pupa_loader_set): Remove the first argument. Loader doesn't
17946 manage modules or initrd any longer.
17947 (pupa_loader_load_module): Removed.
17949 * conf/i386-pc.rmk (pkgdata_MODULES): Added linux.mod.
17950 (linux_mod_SOURCES): New variable.
17951 (linux_mod_CFLAGS): Likewise.
17953 2003-01-07 Yoshinori K. Okuji <okuji@enbug.org>
17955 * util/i386/pc/pupa-setup.c (setup): Convert the endianness of
17956 the length of a blocklist correctly.
17958 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open) [__linux__]:
17959 Use ioctl only if the OS file is a block device.
17960 (pupa_util_biosdisk_open): Don't use ST.ST_BLOCKS, because it is
17961 not very useful for normal files.
17963 * kern/main.c (pupa_set_root_dev): New function.
17964 (pupa_load_normal_mode): Likewise.
17965 (pupa_main): Call those above.
17967 * include/pupa/types.h (pupa_swap_bytes16): Cast the result to
17970 * include/pupa/kernel.h (pupa_enter_normal_mode): Removed.
17972 2003-01-06 Yoshinori K. Okuji <okuji@enbug.org>
17974 * util/i386/pc/pupa-setup.c: Include pupa/machine/kernel.h.
17975 (setup): Configure the installed partition information and the
17978 * loader/i386/pc/chainloader.c (my_mod): New variable.
17979 (pupa_chainloader_unload): New function.
17980 (pupa_rescue_cmd_chainloader): Refer itself.
17981 (PUPA_MOD_INIT): Save its own module in MY_MOD.
17983 * kern/i386/pc/startup.S (install_partition): Removed.
17984 (version_string): Likewise.
17985 (config_file): Likewise.
17986 (pupa_install_dos_part): New variable.
17987 (pupa_install_bsd_part): Likewise.
17988 (pupa_prefix): Likewise.
17989 (pupa_chainloader_real_boot): Call pupa_dl_unload_all.
17991 * kern/i386/pc/init.c: Include pupa/machine/kernel.h, pupa/dl.h
17993 (make_install_device): New function.
17994 (pupa_machine_init): Set the dl prefix.
17996 * kern/rescue.c: Include pupa/rescue.h and pupa/dl.h.
17997 (buf): Renamed to ...
17998 (linebuf): ... this.
17999 (pupa_rescue_cmd_prefix): New function.
18000 (pupa_rescue_cmd_insmod): Likewise.
18001 (pupa_rescue_cmd_rmmod): Likewise.
18002 (pupa_rescue_cmd_lsmod): Likewise.
18003 (pupa_enter_rescue_mode): Register new commands: prefix, insmod,
18006 * kern/mm.c (pupa_memalign): If failed even after invalidating
18007 disk caches, unload unneeded modules and retry.
18009 * kern/misc.c (pupa_memmove): New function.
18010 (pupa_memcpy): Removed.
18011 (pupa_strcpy): New function.
18012 (pupa_itoa): Made static.
18014 * kern/dl.c (pupa_dl_iterate): New function.
18015 (pupa_dl_ref): Likewise.
18016 (pupa_dl_unref): Likewise.
18017 (pupa_dl_unload): Return if succeeded or not.
18018 (pupa_dl_unload_unneeded): New function.
18019 (pupa_dl_unload_all): Likewise.
18020 (pupa_dl_init): Renamed to ...
18021 (pupa_dl_set_prefix): ... this.
18022 (pupa_dl_get_prefix): New function.
18024 * include/pupa/i386/pc/kernel.h: Include pupa/types.h.
18025 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): New macro.
18026 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
18027 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
18028 (pupa_install_dos_part): Declared.
18029 (pupa_install_bsd_part): Likewise.
18030 (pupa_prefix): Likewise.
18031 (pupa_boot_drive): Likewise.
18033 * include/pupa/types.h: Fix a typo.
18035 * include/pupa/misc.h (pupa_memcpy): New macro. Just an alias to
18037 (pupa_memmove): Declared.
18038 (pupa_strcpy): Likewise.
18040 * include/pupa/dl.h (PUPA_MOD_INIT): Change the prototype. Now
18041 pupa_mod_init takes one argument, its own module.
18042 (pupa_dl_unload_unneeded): Declared.
18043 (pupa_dl_unload_all): Likewise.
18044 (pupa_dl_ref): Likewise.
18045 (pupa_dl_unref): Likewise.
18046 (pupa_dl_iterate): Likewise.
18047 (pupa_dl_init): Renamed to ...
18048 (pupa_dl_set_prefix): ... this.
18049 (pupa_dl_get_prefix): Declared.
18051 * fs/fat.c [!PUPA_UTIL] (my_mod): New variable.
18052 (pupa_fat_dir) [!PUPA_UTIL]: Prevent the fat module from being
18054 (pupa_fat_open) [!PUPA_UTIL]: Refer itself if succeeded.
18055 (pupa_fat_close) [!PUPA_UTIL]: Unrefer itself.
18057 * configure.ac (tmp_CFLAGS): Added -Wshadow, -Wpointer-arith,
18058 -Wmissing-prototypes, -Wundef and -Wstrict-prototypes.
18060 2003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
18062 * util/i386/pc/pupa-setup.c (setup): Define the internal
18063 function find_first_partition_start at the top level, because GCC
18064 3.0.x cannot compile internal functions in deeper scopes
18066 (find_root_device): Use lstat instead of stat.
18067 Don't follow symbolic links.
18068 Fix the path-constructing code.
18070 * util/i386/pc/biosdisk.c [__linux__] (BLKFLSBUF): New macro.
18071 (pupa_util_biosdisk_open) [__linux__]: Get the size of a device
18072 by a BLKGETSIZE ioctl first, because block devices don't fill
18073 the member st_mode of the structure stat on Linux.
18074 [__linux__] (linux_find_partition): Use a temporary buffer
18075 REAL_DEV for the working space. Copy it to DEV before returning.
18076 (open_device) [__linux__]: Call ioctl with BLKFLSBUF to make the
18077 buffer cache consistent.
18078 (get_os_disk) [__linux__]: Use the length 5 instead of 4 for
18079 strncmp. The previous value was merely wrong.
18080 (pupa_util_biosdisk_get_pupa_dev): Use stat instead of lstat.
18082 * fs/fat.c (pupa_fat_read_data): Shift 4 instead of 12 when the
18083 FAT size is 12. The previous value was merely wrong.
18085 * kern/main.c (pupa_main): Don't split the starting message from
18088 * kern/term.c (pupa_putchar): Put CR after LF instead of before
18089 LF, because BIOS goes crazy about character attributes in this
18092 2003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
18094 * include/i386/pc/util/biosdisk.h: New file.
18095 * util/i386/pc/biosdisk.c: Likewise.
18096 * util/i386/pc/pupa-setup.c: Likewise.
18098 * Makefile.in (INCLUDE_DISTFILES): Added
18099 include/pupa/i386/pc/util/biosdisk.h.
18100 (UTIL_DISTFILES): Added biosdisk.c and pupa-setup.c under the
18101 directory util/i386/pc.
18102 (install-local): Added a rule for sbin_UTILITIES.
18103 (uninstall): Likewise.
18105 * util/i386/pc/pupa-mkimage.c (usage): Fix a typo in the doc.
18107 * util/misc.c (xrealloc): New function.
18108 (pupa_malloc): Likewise.
18109 (pupa_free): Likewise.
18110 (pupa_realloc): Likewise.
18111 (pupa_stop): Likewise.
18112 (pupa_putchar): Likewise.
18114 * kern/disk.c (pupa_disk_read): Prevent L from underflowing.
18116 * include/pupa/util/misc.h (xrealloc): Declared.
18118 * include/pupa/i386/pc/boot.h (PUPA_BOOT_MACHINE_BPB_START): New
18120 (PUPA_BOOT_MACHINE_BPBEND): Renamed to ...
18121 (PUPA_BOOT_MACHINE_BPB_END): ... this.
18123 * include/pupa/fs.h [PUPA_UTIL] (pupa_fat_init): Declared.
18124 [PUPA_UTIL] (pupa_fat_fini): Likewise.
18126 * fs/fat.c [PUPA_UTIL] (pupa_fat_init): Defined. Maybe a better
18127 way should be implemented.
18128 [PUPA_UTIL] (pupa_fat_fini): Likewise.
18130 * disk/i386/pc/biosdisk.c (pupa_biosdisk_call_hook): Increase
18131 the size of NAME for safety.
18132 (pupa_biosdisk_iterate): Search hard disks to 0x90 instead of
18135 * conf/i386-pc.rmk (sbin_UTILITIES): New variable.
18136 (pupa_setup_SOURCES): Likewise.
18138 * genmk.rb (Utility#rule): Add $(BUILD_CFLAGS) into the rules.
18140 2002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
18142 * kern/i386/pc/startup.S (push_get_mmap_entry): Revert to a
18143 bunch of pushl's from pusha, because this destroys the return
18146 2002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
18148 Use -mrtd and -mregparm=3 to reduce the generated code sizes.
18149 This means that any missing prototypes could be fatal. Also, you
18150 must take care when writing assembly code. See the comments at
18151 the beginning of startup.S, for more details.
18153 * kern/i386/pc/startup.S (pupa_halt): Modified for the new
18154 compilation mechanism.
18155 (pupa_chainloader_real_boot): Likewise.
18156 (pupa_biosdisk_rw_int13_extensions): Likewise.
18157 (pupa_biosdisk_rw_standard): Likewise.
18158 (pupa_biosdisk_check_int13_extensions): Likewise.
18159 (pupa_biosdisk_get_diskinfo_int13_extensions): Likewise.
18160 (pupa_biosdisk_get_diskinfo_standard): Likewise.
18161 (pupa_get_memsize): Likewise.
18162 (pupa_get_mmap_entry): Likewise.
18163 (pupa_console_putchar): Likewise.
18164 (pupa_console_setcursor): Likewise.
18165 (pupa_getrtsecs): Use pushl instead of push.
18167 * kern/i386/pc/init.c (pupa_machine_init): Use the scratch
18168 memory instead of the stack for a mmap entry, because some
18169 BIOSes may ignore the maximum size and overflow.
18171 * conf/i386-pc.rmk (COMMON_CFLAGS): Added -mrtd and -mregparm=3.
18173 * genmk.rb (PModule#rule): Compile automatically generated
18174 sources with module-specific CFLAGS as well as other sources.
18176 2002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
18178 * configure.ac: Check ld.
18179 Replace CFLAGS and CPPFLAGS with BUILD_CFLAGS and BUILD_CPPFLAGS
18180 respectively, before checking endianness and sizes.
18182 * Makefile.in (LD): New variable.
18184 2002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
18186 * Makefile.in (BUILD_CC): CC -> BUILD_CC.
18188 2002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
18190 * Changelog: New file.