1 2009-09-08 Felix Zielcke <fzielcke@z-51.de>
3 * kern/rescue_parser.c (grub_rescue_parse_line): Only suggest to try
4 `help' if the command exists.
6 2009-09-06 Robert Millan <rmh.grub@aybabtu.com>
8 * INSTALL: Require GCC 4.1.3 or later.
10 2009-09-06 Yves Blusseau <blusseau@zetam.org>
12 * Makefile.in (RMKFILES): add i386-qemu.rmk
13 (MAINTAINER_CLEANFILES): add $(srcdir)/DISTLIST $(srcdir)/config.h.in
16 2009-09-05 Robert Millan <rmh.grub@aybabtu.com>
18 * util/grub-probe.c (probe): Comment out buggy codepath, which
19 was unexpectedly enabled by Colin Watson's 2009-09-02 fix. This
20 should be re-enabled after 1.97.
22 2009-09-05 Felix Zielcke <fzielcke@z-51.de>
24 * gendistlist.sh: Add `grub-dumpdevtree' and `*.lua' to the list
27 2009-09-04 Vladimir Serbinenko <phcoder@gmail.com>
29 * loader/i386/xnu.c (grub_cpu_xnu_fill_devicetree): Remove
30 unnecessary calls to grub_error.
32 2009-09-04 Colin Watson <cjwatson@ubuntu.com>
34 * NEWS: Mention `keystatus' and Unicode fonts.
36 2009-09-04 Robert Millan <rmh.grub@aybabtu.com>
38 * configure.ac: Bump version to 1.97~beta2.
39 * docs/version.texi: Likewise.
41 2009-09-03 Colin Watson <cjwatson@ubuntu.com>
43 * configure.ac: By default, GCC 4.4 generates .eh_frame sections
44 containing unwind information in some cases where it previously did
45 not. Use -fno-dwarf2-cfi-asm if available to restore the old
46 behaviour. See http://patchwork.kernel.org/patch/8555/ for related
49 2009-09-02 Yves BLUSSEAU <blusseau@zetam.org>
51 Embedding loadenv module into grub-emu
53 * conf/i386-pc.rmk (grub_emu_SOURCES): add lib/envblk.c and
55 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise
56 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise
57 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise
58 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise
59 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise
60 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise
62 2009-09-03 Magnus Granberg <zorry@ume.nu>
64 * aclocal.m4: Add grub_CHECK_PIE. It check if the compiler
65 include -fPIE in the default specs.
66 * configure.ac: Check if pie_possible is yes and add -fno-PIE
69 2009-09-03 Felix Zielcke <fzielcke@z-51.de>
71 * INSTALL: Note that GNU Bison 2.3 or later is required.
73 2009-09-03 Colin Watson <cjwatson@ubuntu.com>
75 * kern/i386/pc/startup.S: Fix typo.
77 2009-09-02 Vladimir Serbinenko <phcoder@gmail.com>
79 * efiemu/loadcore.c (SUFFIX (grub_efiemu_loadcore_load)): Fix style
82 2009-09-02 Colin Watson <cjwatson@ubuntu.com>
84 * docs/grub.texi (Naming convention): Describe one-based partition
86 (Device syntax): Likewise.
87 (File name syntax): Likewise.
88 (Block list syntax): Likewise.
89 (Making a GRUB bootable CD-ROM): Talk about grub.cfg rather than
91 (File name syntax): Likewise.
92 (Command-line and menu entry commands): Document acpi, blocklist,
93 crc, export, insmod, keystatus, ls, set, and unset commands.
95 2009-09-02 Colin Watson <cjwatson@ubuntu.com>
97 * commands/keystatus.c (GRUB_MOD_INIT (keystatus)): Adjust summary
98 to avoid implying that only one of --shift, --ctrl, or --alt may be
101 2009-09-02 Colin Watson <cjwatson@ubuntu.com>
103 * util/grub-probe.c (probe): Test st.st_mode using S_ISREG macro
104 rather than comparing against S_IFREG, which will almost never work.
106 2009-09-01 Vladimir Serbinenko <phcoder@gmail.com>
108 * commands/loadenv.c (check_blocklists): Fix off-by-one error.
109 (write_blocklists): Likewise.
111 2009-09-01 Colin Watson <cjwatson@ubuntu.com>
113 * script/lua/grub_lua.h (fputs): Supply a format string as the first
114 argument to grub_printf.
116 2009-09-01 Felix Zielcke <fzielcke@z-51.de>
118 * genmk.rb: Add quotes around $(TARGET_OBJ2ELF) to cope with
121 2009-08-30 Vladimir Serbinenko <phcoder@gmail.com>
123 * kern/file.c (grub_file_read): Spelling fix
125 2009-08-30 Vladimir Serbinenko <phcoder@gmail.com>
127 * loader/i386/bsdXX.c (SUFFIX (grub_freebsd_load_elfmodule)): Fix
128 loading of headers in some cases.
130 2009-08-30 Robert Millan <rmh.grub@aybabtu.com>
132 * configure.ac: Bump version to 1.97~beta1.
133 * docs/version.texi: Likewise.
135 2009-08-29 Vladimir Serbinenko <phcoder@gmail.com>
137 * include/grub/i386/xnu.h: Add license header.
138 include grub/err.h explicitly.
140 2009-08-29 Robert Millan <rmh.grub@aybabtu.com>
142 * util/grub.d/10_freebsd.in: Detect `ufs1' and `ufs2' and map them
143 to `ufs' in the vfs.root.mountfrom kernel parameter.
145 2009-08-29 Robert Millan <rmh.grub@aybabtu.com>
147 * term/i386/pc/serial.c: Include `<grub/machine/memory.h>'.
149 [GRUB_MACHINE_PCBIOS] (serial_hw_io_addr): Macroify initialization
150 value (0x0400 -> GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR).
152 [! GRUB_MACHINE_PCBIOS] (GRUB_SERIAL_PORT_NUM): Calculate using
155 2009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
157 * kern/file.c (grub_file_read): Check offset.
158 * fs/hfs.c (grub_hfs_read_file): Remove unnecessary offset check.
159 * fs/jfs.c (grub_jfs_read_file): Likewise.
160 * fs/ntfs.c (grub_ntfs_read): Likewise.
161 * fs/reiserfs.c (grub_reiserfs_read): Likewise.
162 * fs/minix.c (grub_minix_read_file): Correct offset check.
163 * fs/ufs.c (grub_ufs_read_file): Likewise.
165 2009-08-28 Colin Watson <cjwatson@ubuntu.com>
167 * term/i386/pc/console.c (bios_data_area): Cast
168 GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR explicitly.
170 2009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
172 1-bit optimised blitters.
174 * include/grub/fbblit.h (grub_video_fbblit_replace_32bit_1bit): New
176 (grub_video_fbblit_replace_24bit_1bit): Likewise.
177 (grub_video_fbblit_replace_16bit_1bit): Likewise.
178 (grub_video_fbblit_replace_8bit_1bit): Likewise.
179 (grub_video_fbblit_blend_XXXA8888_1bit): Likewise.
180 (grub_video_fbblit_blend_XXX888_1bit): Likewise.
181 (grub_video_fbblit_blend_XXX565_1bit): Likewise.
182 * video/fb/fbblit.c (grub_video_fbblit_replace_32bit_1bit): New
184 (grub_video_fbblit_replace_24bit_1bit): Likewise.
185 (grub_video_fbblit_replace_16bit_1bit): Likewise.
186 (grub_video_fbblit_replace_8bit_1bit): Likewise.
187 (grub_video_fbblit_blend_XXXA8888_1bit): Likewise.
188 (grub_video_fbblit_blend_XXX888_1bit): Likewise.
189 (grub_video_fbblit_blend_XXX565_1bit): Likewise.
190 * video/fb/video_fb.c (common_blitter): Use 1-bit optimised blitters
192 * video/video.c (grub_video_get_blit_format): Return
193 GRUB_VIDEO_BLIT_FORMAT_1BIT_PACKED if bpp = 1.
195 2009-08-28 Colin Watson <cjwatson@ubuntu.com>
197 * normal/cmdline.c (grub_cmdline_get): Supply a format string as
198 the first argument to grub_printf.
200 2009-08-28 Colin Watson <cjwatson@ubuntu.com>
201 2009-08-28 Robert Millan <rmh.grub@aybabtu.com>
203 Add `getkeystatus' terminal method. Add a new `keystatus' command
206 * include/grub/term.h (GRUB_TERM_STATUS_SHIFT,
207 GRUB_TERM_STATUS_CTRL, GRUB_TERM_STATUS_ALT): Definitions for
208 modifier key bitmasks.
209 (struct grub_term_input): Add `getkeystatus' member.
210 (grub_getkeystatus): Add prototype.
211 * kern/term.c (grub_getkeystatus): New function.
213 * include/grub/i386/pc/memory.h
214 (GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR): New macro.
215 (struct grub_machine_bios_data_area): Define necessary parts of BIOS
217 * term/i386/pc/console.c (grub_console_getkeystatus): New function.
218 (grub_console_term_input): Set `getkeystatus' member.
219 * term/usb_keyboard.c (grub_usb_hid): Macroify HID protocol
221 (grub_usb_keyboard_getreport): Likewise.
222 (grub_usb_keyboard_checkkey): Likewise.
223 (grub_usb_keyboard_getkeystatus): New function.
224 (grub_usb_keyboard_term): Set `getkeystatus' member.
226 * commands/keystatus.c: New file.
227 * conf/common.rmk (pkglib_MODULES): Add keystatus.mod.
228 (keystatus_mod_SOURCES): New variable.
229 (keystatus_mod_CFLAGS): Likewise.
230 (keystatus_mod_LDFLAGS): Likewise.
231 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add
232 commands/keystatus.c.
233 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
234 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
235 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
236 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
237 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
238 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
240 2009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
242 Split befs.mod and afs.mod into *_be.mod and *.mod
244 * conf/common.rmk (grub_probe_SOURCES): Add afs_be.c and befs_be.c.
245 (grub_fstest_SOURCES): Likewise.
246 (pkglib_MODULES): Add afs_be.mod and befs_be.mod.
247 (afs_be_mod_SOURCES): New variable.
248 (afs_be_mod_CFLAGS): Likewise.
249 (afs_be_mod_LDFLAGS): Likewise.
250 (befs_be_mod_SOURCES): Likewise.
251 (befs_be_mod_CFLAGS): Likewise.
252 (befs_be_mod_LDFLAGS): Likewise.
253 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add afs_be.c and befs_be.c.
254 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
255 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
256 * conf/i386-pc.rmk (grub_setup_SOURCES): Likewise.
257 (grub_emu_SOURCES): Likewise.
258 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
259 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
260 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
261 * fs/afs_be.c: New file.
262 * fs/befs_be.c: New file.
263 * fs/afs.c (GRUB_AFS_FSNAME_SUFFIX): New definition.
264 (GRUB_AFS_FSNAME): Use GRUB_AFS_FSNAME_SUFFIX.
265 (U16): Replaced with ...
266 (grub_afs_to_cpu16): ...this. All users updated.
267 (U32): Replaced with ...
268 (grub_afs_to_cpu32): ...this. All users updated.
269 (U64): Replaced with ...
270 (grub_afs_to_cpu64): ...this. All users updated.
271 (GRUB_AFS_BO_LITTLE_ENDIAN): Remove.
272 (GRUB_AFS_BO_BIG_ENDIAN): Likewise.
273 (grub_afs_validate_sblock): Check only one endiannness.
274 (GRUB_MOD_INIT (befs)) [MODE_BIGENDIAN && MODE_BFS]: Rename to ..
275 (GRUB_MOD_INIT (befs_be)) [MODE_BIGENDIAN && MODE_BFS]: ... this.
276 (GRUB_MOD_INIT (afs)) [MODE_BIGENDIAN && !MODE_BFS]: Rename to ..
277 (GRUB_MOD_INIT (afs_be)) [MODE_BIGENDIAN && !MODE_BFS]: ... this.
278 (GRUB_MOD_FINI (befs)) [MODE_BIGENDIAN && MODE_BFS]: Rename to ..
279 (GRUB_MOD_FINI (befs_be)) [MODE_BIGENDIAN && MODE_BFS]: ... this.
280 (GRUB_MOD_FINI (afs)) [MODE_BIGENDIAN && !MODE_BFS]: Rename to ..
281 (GRUB_MOD_FINI (afs_be)) [MODE_BIGENDIAN && !MODE_BFS]: ... this.
283 2009-08-26 Bean <bean123ch@gmail.com>
285 * fs/xfs.c (GRUB_XFS_INO_INOINAG): Replace 1L with 1LL to support
287 (GRUB_XFS_FSB_TO_BLOCK): Likewise.
288 (grub_xfs_inode_block): Change return type to grub_uint64_t.
289 (grub_xfs_read_inode): Change type of block to grub_uint64_t.
291 2009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
293 NetBSD memory map support.
295 * include/grub/i386/bsd.h (NETBSD_BTINFO_MEMMAP): New definition.
296 (grub_netbsd_btinfo_mmap_header): New structure.
297 (grub_netbsd_btinfo_mmap_entry): Likewise.
298 * loader/i386/bsd.c (grub_netbsd_boot): Pass memory map.
300 2009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
302 Enable bsd.mod on coreboot.
304 * conf/i386-coreboot.rmk (pkglib_MODULES): Add bsd.mod.
305 (bsd_mod_SOURCES): New variable.
306 (bsd_mod_CFLAGS): Likewise.
307 (bsd_mod_LDFLAGS): Likewise.
308 (bsd_mod_ASFLAGS): Likewise.
309 * loader/i386/bsd.c [!GRUB_MACHINE_PCBIOS]: Fix includes.
310 (grub_bsd_get_device) [!GRUB_MACHINE_PCBIOS]: Set *biosdev to 0xff.
312 2009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
314 Cleanup NetBSD root support.
316 * loader/i386/bsd.c (grub_netbsd_boot): Remove call to
320 2009-08-25 Felix Zielcke <fzielcke@z-51.de>
322 * util/grub.d/00_header.in: Move check for the video backend of
323 gfxterm from here ...
324 * util/grub-mkconfig.in: ... to here. Enable gfxterm if there's
325 a suitable video backend.
327 2009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
329 Fix breakage in grub-setup.
331 * util/i386/pc/grub-setup.c (setup): Use "part_msdos" instead of
332 "msdos_partition_map".
334 2009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
336 Fix breakage in normal/auth.c.
338 * normal/auth.c (grub_iswordseparator): New function.
340 2009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
342 Authentication support.
344 * commands/password.c: New file.
345 * conf/common.rmk (pkglib_MODULES): Add password.mod.
346 (password_mod_SOURCES): New variable.
347 (password_mod_CFLAGS): Likewise.
348 (password_mod_LDFLAGS): Likewise.
349 (normal_mod_SOURCES): Add normal/auth.c.
350 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add commands/password.c and
352 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
353 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
354 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
355 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
356 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
357 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
358 * include/grub/auth.h: New file.
359 * include/grub/err.h (grub_err_t): New enum value
360 GRUB_ERR_ACCESS_DENIED.
361 * include/grub/menu.h (grub_menu_entry): New fields 'restricted' and
363 * include/grub/normal.h (grub_cmdline_get): New argument 'history'.
364 * normal/cmdline.c (grub_cmdline_get): New argument 'history'. All
366 * normal/auth.c: New file.
367 * normal/main.c (grub_normal_add_menu_entry): Handle --users option.
368 (grub_cmdline_run): Don't allow to go to command line without
370 * normal/menu.c (grub_menu_execute_entry): Handle restricted entries.
371 * normal/menu_entry.c (grub_menu_entry_run): Don't allow editing
372 menuentry without superuser rights.
373 * normal/menu_viewer.c (grub_menu_viewer_show_menu): Don't exit if
374 user isn't a superuser.
376 2009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
378 Save space by inlining misc.c functions.
380 * kern/misc.c (grub_iswordseparator): Made static.
381 * kern/misc.c (grub_strcat): Moved from here ...
382 * include/grub/misc.h (grub_strcat): ... here. Inlined.
383 * kern/misc.c (grub_strncat): Moved from here ...
384 * include/grub/misc.h (grub_strncat): ... here. Inlined.
385 * kern/misc.c (grub_strcasecmp): Moved from here ...
386 * include/grub/misc.h (grub_strcasecmp): ... here. Inlined.
387 * kern/misc.c (grub_strncasecmp): Moved from here ...
388 * include/grub/misc.h (grub_strncasecmp): ... here. Inlined.
389 * kern/misc.c (grub_isalpha): Moved from here ...
390 * include/grub/misc.h (grub_isalpha): ... here. Inlined.
391 * kern/misc.c (grub_isdigit): Moved from here ...
392 * include/grub/misc.h (grub_isdigit): ... here. Inlined.
393 * kern/misc.c (grub_isgraph): Moved from here ...
394 * include/grub/misc.h (grub_isgraph): ... here. Inlined.
395 * kern/misc.c (grub_tolower): Moved from here ...
396 * include/grub/misc.h (grub_tolower): ... here. Inlined.
398 2009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
400 * script/sh/function.c (grub_script_function_find): Cut error message
401 not to flood terminal.
402 * script/sh/lexer.c (grub_script_yylex): Remove command line length
404 * script/sh/script.c (grub_script_arg_add): Duplicate string.
406 2009-08-24 Colin Watson <cjwatson@ubuntu.com>
408 * term/usb_keyboard.c (grub_usb_keyboard_getreport): Make
409 `report' grub_uint8_t *.
410 (grub_usb_keyboard_checkkey): Make `data' elements grub_uint8_t.
411 Use a 50-millisecond timeout rather than just repeating
412 grub_usb_keyboard_getreport 50 times.
413 (grub_usb_keyboard_getkey): Make `data' elements grub_uint8_t.
415 2009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
417 Rename *_partition_map to part_*
419 * partmap/acorn.c (grub_acorn_partition_map): Set name to 'part_acorn'.
420 * partmap/amiga.c (grub_amiga_partition_map): Set name to 'part_amiga'.
421 * partmap/apple.c (grub_apple_partition_map): Set name to 'part_apple'.
422 * partmap/gpt.c (grub_gpt_partition_map): Set name to 'part_gpt'.
424 * partmap/msdos.c (grub_msdos_partition_map): Set name to 'part_msdos'.
426 * partmap/sun.c (grub_sun_partition_map): Set name to 'part_sun'.
427 * util/grub-probe.c (probe_partmap): Don't transform partition name
430 2009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
432 Fix OpenBSD and NetBSD support.
434 * include/grub/i386/bsd.h (GRUB_BSD_TEMP_BUFFER): Change to resolve
435 memory address conflict.
436 (OPENBSD_MMAP_ACPI): New definition.
437 (OPENBSD_MMAP_NVS): Likewise.
438 * loader/i386/bsd.c (grub_openbsd_boot): Support OPENBSD_MMAP_ACPI
439 and OPENBSD_MMAP_NVS.
440 Add memory map terminator
441 Explicit cast when calling grub_unix_real_boot.
442 (grub_nebsd_boot): Explicit cast when calling grub_unix_real_boot.
444 2009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
446 Let user specify NetBSD root device.
448 * loader/i386/bsd.c (netbsd_root): New variable.
449 (netbsd_opts): New option 'root'.
450 (NETBSD_ROOT_ARG): New macro.
451 (grub_netbsd_boot): Use 'netbsd_root'.
452 (grub_bsd_unload): Free 'netbsd_root'.
453 (grub_cmd_netbsd): Fill 'netbsd_root'.
455 2009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
457 Support for 64-bit NetBSD.
459 * loader/i386/bsd.c (grub_bsd_load_elf): Apply correct mask to entry
460 point when booting non-FreeBSD.
462 2009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
464 Support --no-smp and --no-acpi for NetBSD.
466 * include/grub/i386/bsd.h (NETBSD_AB_NOSMP): New definition.
467 (NETBSD_AB_NOACPI): Likewise.
468 * loader/i386/bsd.c (netbsd_opts): New entries no-smp and no-acpi.
469 (netbsd_flags): Add NETBSD_AB_NOSMP, NETBSD_AB_NOACPI.
471 2009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
473 * fs/hfsplus.c (grub_hfsplus_mount): Don't ignore grub_hfsplus_read_file
475 (grub_hfsplus_btree_iterate_node): Don't ignore grub_hfsplus_read_file
476 errors. Call grub_error when needed.
478 2009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
480 * commands/search.c (search_fs): Try searching without autoload first.
481 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Load
482 filesystem module explicitly for faster booting.
484 2009-08-23 Colin Watson <cjwatson@ubuntu.com>
486 * util/grub-mkconfig.in: Export GRUB_DISABLE_OS_PROBER.
488 2009-08-23 Colin Watson <cjwatson@ubuntu.com>
490 * util/grub.d/30_os-prober.in: Disable os-prober if
491 `GRUB_DISABLE_OS_PROBER' was set to true.
493 2009-08-23 Robert Millan <rmh.grub@aybabtu.com>
495 * partmap/pc.c: Rename to ...
496 * partmap/msdos.c: ... this. Update all users.
497 (grub_pc_partition_map): Rename to ...
498 (grub_msdos_partition_map): ... this. Update all users.
500 * parttool/pcpart.c: Rename to ...
501 * parttool/msdospart.c: ... this. Update all users.
503 * include/grub/pc_partition.h: Rename to ...
504 * include/grub/msdos_partition.h: ... this. Update all users.
505 (grub_pc_partition_bsd_entry): Rename to ...
506 (grub_msdos_partition_bsd_entry): ... this. Update all users.
507 (grub_pc_partition_disk_label): Rename to ...
508 (grub_msdos_partition_disk_label): ... this. Update all users.
509 (grub_pc_partition_entry): Rename to ...
510 (grub_msdos_partition_entry): ... this. Update all users.
511 (grub_pc_partition_mbr): Rename to ...
512 (grub_msdos_partition_mbr): ... this. Update all users.
513 (grub_pc_partition): Rename to ...
514 (grub_msdos_partition): ... this. Update all users.
515 (grub_pc_partition_is_empty): Rename to ...
516 (grub_msdos_partition_is_empty): ... this. Update all users.
517 (grub_pc_partition_is_extended): Rename to ...
518 (grub_msdos_partition_is_extended): ... this. Update all users.
519 (grub_pc_partition_is_bsd): Rename to ...
520 (grub_msdos_partition_is_bsd): ... this. Update all users.
522 * conf/common.rmk (amiga_mod_SOURCES, amiga_mod_CFLAGS)
523 (amiga_mod_LDFLAGS, apple_mod_SOURCES, apple_mod_CFLAGS)
524 (apple_mod_LDFLAGS, msdos_mod_SOURCES, msdos_mod_CFLAGS)
525 (msdos_mod_LDFLAGS, sun_mod_SOURCES, sun_mod_CFLAGS)
526 (sun_mod_LDFLAGS, acorn_mod_SOURCES, acorn_mod_CFLAGS)
527 (acorn_mod_LDFLAGS, gpt_mod_SOURCES, gpt_mod_CFLAGS)
528 (gpt_mod_LDFLAGS): Rename to ...
529 (part_amiga_mod_SOURCES, part_amiga_mod_CFLAGS, part_amiga_mod_LDFLAGS)
530 (part_apple_mod_SOURCES, part_apple_mod_CFLAGS, part_apple_mod_LDFLAGS)
531 (part_msdos_mod_SOURCES, part_msdos_mod_CFLAGS, part_msdos_mod_LDFLAGS)
532 (part_sun_mod_SOURCES, part_sun_mod_CFLAGS, part_sun_mod_LDFLAGS)
533 (part_acorn_mod_SOURCES, part_acorn_mod_CFLAGS, part_acorn_mod_LDFLAGS)
534 (part_gpt_mod_SOURCES, part_gpt_mod_CFLAGS)
535 (part_gpt_mod_LDFLAGS): ... this.
536 (pkglib_MODULES): Prefix partition modules with `part_'. Rename
537 `pcpart.mod' to `msdospart.mod'.
538 (pcpart_mod_SOURCES, pcpart_mod_CFLAGS, pcpart_mod_LDFLAGS): Rename
540 (msdospart_mod_SOURCES, msdospart_mod_CFLAGS)
541 (msdospart_mod_LDFLAGS): ... this.
543 2009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
545 * loader/i386/bsd.c (freebsd_opts): Rewritten to use extcmd.
546 (openbsd_opts): Likewise.
547 (netbsd_opts): Likewise.
548 (freebsd_flags): Added 0 terminator.
549 (openbsd_flags): Likewise.
550 (netbsd_flags): Likewise.
551 (grub_bsd_parse_flags): Rewritten to use extcmd. All users updated.
552 (grub_cmd_freebsd): Transformed into extended command.
553 (grub_cmd_openbsd): Likewise.
554 (grub_cmd_netbsd): Likewise.
555 (cmd_freebsd): Changed type to grub_extcmd_t.
556 (cmd_openbsd): Likewise.
557 (cmd_netbsd): Likewise.
558 (GRUB_MOD_INIT (bsd)): Register grub_cmd_freebsd, grub_cmd_netbsd and
559 grub_cmd_openbsd as extended commands.
560 (GRUB_MOD_FINI (bsd)): Use grub_unregister_extcmd for cmd_freebsd,
561 cmd_netbsd and cmd_openbsd
563 2009-08-22 Vladimir Serbinenko <phcoder@gmail.com>
565 * commands/xnu_uuid.c (transform): Use grub_memcpy instead of memcpy.
567 2009-08-21 Pavel Roskin <proski@gnu.org>
569 * Makefile.in (install-local): When checking if a file is in the
570 build directory, use "test -e" to detect symlinks.
572 * Makefile.in (install-local): Remove all files in
573 $(DESTDIR)$(pkglibdir) before installing new files there.
575 2009-08-18 Felix Zielcke <fzielcke@z-51.de>
577 * util/powerpc/ieee1275/grub-mkrescue.in (grub_mkimage): Use
580 2009-08-18 Felix Zielcke <fzielcke@z-51.de>
582 * util/grub-mkconfig.in: Don't use gfxterm by default if not
583 explicitly specified by the user.
585 2009-08-18 Pavel Roskin <proski@gnu.org>
587 * include/grub/fbfill.h (struct grub_video_fbrender_target): Use
588 grub_uint8_t pointer for data.
589 * include/grub/fbutil.h (struct grub_video_fbblit_info):
591 * video/fb/fbutil.c: Remove unnecessary casts.
593 2009-08-17 Michal Suchanek <hramrach@centrum.cz>
597 * video/i386/pc/vbe.c (vbe_mode_in_use): Removed (duplicate).
598 (grub_vbe_set_video_mode): Save active mode info
599 only after setting the mode.
600 (grub_video_vbe_setup): Call 'grub_vbe_set_video_mode' with NULL as
603 2009-08-17 Michal Suchanek <hramrach@centrum.cz>
605 Rename variables for clarity.
607 * video/i386/pc/vbe.c (active_mode_info): Renamed to ...
608 (active_vbe_mode_info): ... this. All users updated.
609 (framebuffer): Rename 'active_mode' to 'active_vbe_mode'.
611 (initial_mode): Rename to ...
612 (initial_vbe_mode): ... this. All users updated.
613 (mode_in_use): Rename to ..
614 (vbe_mode_in_use): ... this. All users updated.
615 (mode_list): Rename to ..
616 (vbe_mode_list): ... this. All users updated.
617 (grub_vbe_set_video_mode): Rename 'mode' to 'vbe_mode', 'mode_info' to
618 'vbe_mode_info' and 'old_mode' to 'old_vbe_mode'.
619 (grub_video_vbe_init): Rename 'rm_mode_list' to 'rm_vbe_mode_list' and
620 'mode_list_size' to 'vbe_mode_list_size'.
621 (grub_video_vbe_setup): Rename 'mode_info' to 'vbe_mode_info',
622 'best_mode_info' to 'best_vbe_mode_info' and
623 'best_mode' to 'best_vbe_mode'
625 2009-08-17 Michal Suchanek <hramrach@centrum.cz>
627 Remove duplicate grub_video_fb_get_video_ptr.
629 * include/grub/fbutil.h (get_data_ptr): Rename to ...
630 (grub_video_fb_get_video_ptr): ... this.
631 * include/grub/video_fb.h (grub_video_fb_get_video_ptr): Removed.
632 * video/fb/fbutil.c: Add comment about addressing.
633 (get_data_ptr): Rename to ...
634 (grub_video_fb_get_video_ptr): ... this. All users updated.
635 * video/fb/video_fb.c (grub_video_fb_get_video_ptr): Remove.
637 2009-08-17 Robert Millan <rmh.grub@aybabtu.com>
639 * fs/fat.c (grub_fat_read_data): Remove `#if 0' braces around the
640 grub_dprintf() that was just added.
642 2009-08-17 Robert Millan <rmh.grub@aybabtu.com>
644 * loader/i386/linux.c (GRUB_ASSUME_LINUX_HAS_FB_SUPPORT)
645 (DEFAULT_VIDEO_MODE): Remove macros.
646 (grub_linux_boot): Remove assumption that Linux has FB support,
647 and use "text" as default video mode.
649 2009-08-15 Vladimir Serbinenko <phcoder@gmail.com>
651 * fs/affs.c (grub_affs_read_symlink): Change leftover grub_printf into
653 * fs/fat.c (grub_fat_read_data): Likewise.
655 2009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
657 * loader/i386/multiboot.c (grub_multiboot): Don't pass filename to
659 (grub_module): Likewise.
661 2009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
663 * loader/i386/multiboot.c (grub_multiboot_unload): Don't free mbi and
664 mbi->cmdline but free playground.
666 2009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
668 Handle group offset on UFS1.
670 * fs/ufs.c (grub_ufs_sblock): New field 'cylg_mask'.
671 (grub_ufs_read_inode) [!MODE_UFS2]: handle cylg_offset and cylg_mask.
673 2009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
675 Split ufs.mod into ufs1.mod and ufs2.mod.
677 * conf/common.rmk (grub_probe_SOURCES): Add fs/ufs2.c.
678 (grub_fstest_SOURCES): Likewise.
679 (pkglib_MODULES): Remove ufs.mod. Add ufs1.mod and ufs2.mod.
680 (ufs_mod_SOURCES): Remove.
681 (ufs_mod_CFLAGS): Likewise.
682 (ufs_mod_LDFLAGS): Likewise.
683 (ufs1_mod_SOURCES): New variable.
684 (ufs1_mod_CFLAGS): Likewise.
685 (ufs1_mod_LDFLAGS): Likewise.
686 (ufs2_mod_SOURCES): New variable.
687 (ufs2_mod_CFLAGS): Likewise.
688 (ufs2_mod_LDFLAGS): Likewise.
689 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add fs/ufs2.c.
690 * conf/i386-efi.rmk (util/i386/efi/grub-mkimage.c_DEPENDENCIES):
692 (grub_emu_SOURCES): Likewise.
693 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
694 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
695 (grub_setup_SOURCES): Likewise.
696 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
697 * conf/sparc64.rmk (grub_emu_SOURCES): Likewise.
698 (grub_setup_SOURCES): Likewise.
699 * conf/x86_64-efi.rmk (util/i386/efi/grub-mkimage.c_DEPENDENCIES):
701 * fs/ufs2.c: New file.
702 * fs/ufs.c: Separate UFS1 from UFS2 by using preprocessor.
704 2009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
708 * commands/i386/pc/vbetest.c (grub_cmd_vbetest): Restore video
709 subsystem at the end.
710 * conf/common.rmk (pkglib_MODULES): Add video_fb.mod.
711 (video_fb_mod_SOURCES): New variable.
712 (video_fb_mod_CFLAGS): Likewise.
713 (video_fb_mod_LDFLAGS): Likewise.
714 * conf/i386-pc.rmk (vbe_mod_SOURCES): Remove video/i386/pc/vbeblit.c,
715 video/i386/pc/vbefill.c and video/i386/pc/vbeutil.c.
716 * video/i386/pc/vbeblit.c: Moved from here ...
717 * video/fb/fbblit.c: ..here. Replaced 'vbe' with 'fb'.
718 * video/i386/pc/vbefill.c: Moved from here ...
719 * video/fb/fbfill.c: ..here. Replaced 'vbe' with 'fb'.
720 * video/i386/pc/vbeutil.c: Moved from here ...
721 * video/fb/fbutil.c: ..here. Replaced 'vbe' with 'fb'.
722 * include/grub/i386/pc/vbeblit.h: Moved from here ...
723 * include/grub/fbblit.h: ... here. Replaced 'vbe' with 'fb'.
724 * include/grub/i386/pc/vbefill.h: Moved from here ...
725 * include/grub/fbfill.h: ... here. Replaced 'vbe' with 'fb'.
726 * include/grub/i386/pc/vbeutil.h: Moved from here ...
727 * include/grub/fbutil.h: ... here. Replaced 'vbe' with 'fb'.
728 * include/grub/i386/pc/vbe.h: Moved framebuffer part ...
729 * include/grub/video_fb.h: ... here. Replaced 'vbe' with 'fb'.
730 * include/grub/video.h (GRUB_VIDEO_RENDER_TARGET_FRONT_BUFFER): Removed.
731 (GRUB_VIDEO_RENDER_TARGET_BACK_BUFFER): Likewise.
732 (grub_video_adapter): Added 'get_info_and_fini'.
733 (grub_video_get_info_and_fini): New prototype.
734 (grub_video_set_mode): make modestring const char *.
735 * loader/i386/linux.c (grub_linux_setup_video): Use
736 grub_video_get_info_and_fini.
737 (grub_linux_boot): Move modesetting just before booting.
738 * loader/i386/pc/xnu.c (grub_xnu_set_video): Use
739 grub_video_get_info_and_fini.
740 * video/i386/pc/vbe.c: Moved framebuffer part ...
741 * video/fb/video_fb.c: ... here. Replaced 'vbe' with 'fb'.
742 * video/i386/pc/vbe.c (grub_vbe_set_video_mode): Use
743 grub_video_fbstd_colors and grub_video_fb_set_palette.
744 (grub_video_vbe_init): Clear 'framebuffer' variable and use
746 (grub_video_vbe_fini): Use grub_video_fb_fini.
747 (grub_video_vbe_setup): Use framebuffer.render_target instead of
748 render_target and use grub_video_fb_set_active_render_target and
749 grub_video_fb_set_palette.
750 (grub_video_vbe_set_palette): Use grub_video_fb_set_palette.
751 (grub_video_vbe_set_viewport): Use grub_video_fb_set_viewport.
752 (grub_video_vbe_adapter): Use framebuffer.
753 * video/video.c (grub_video_get_info_and_fini): New function.
754 (grub_video_set_mode): Make modestring const char *.
755 (GRUB_MOD_INIT(video_video)): Don't set variables to 0 since these
756 values are already initialised.
758 2009-08-14 Pavel Roskin <proski@gnu.org>
760 * boot/i386/pc/cdboot.S: Use LOCAL for local labels. Eliminate
762 * boot/i386/pc/diskboot.S: Likewise.
763 * boot/i386/pc/lnxboot.S: Likewise. Hardcode the number of code
764 sectors allow compilation on MacOSX.
765 * conf/i386-pc.rmk: Enable unconditional compilation of
768 2009-08-13 Colin Watson <cjwatson@ubuntu.com>
770 * util/grub-mkconfig.in: Export GRUB_HIDDEN_TIMEOUT.
771 * util/grub.d/00_header.in: Enter interruptible sleep if
772 GRUB_HIDDEN_TIMEOUT is set.
774 2009-08-13 Yves Blusseau <blusseau@zetam.org>
776 * include/grub/symbol.h: Add the LOCAL macro.
777 * boot/i386/pc/boot.S: Use the LOCAL macro for all labels
780 2009-08-13 Pavel Roskin <proski@gnu.org>
782 * boot/i386/pc/boot.S: Remove ABS macro, it's not required by
783 any modern compilers we support.
785 * boot/i386/pc/boot.S: Remove all code dependent on APPLE_CC.
786 Use local labels starting with "L_" so that Apple assembler
787 knows they are local.
789 2009-08-10 Robert Millan <rmh.grub@aybabtu.com>
791 * include/grub/i386/bsd.h (KERNEL_TYPE_NONE, KERNEL_TYPE_FREEBSD)
792 (KERNEL_TYPE_OPENBSD, KERNEL_TYPE_NETBSD): Convert to ...
793 (bsd_kernel_types): ... this enum.
795 * loader/i386/bsd.c (grub_cmd_freebsd_loadenv, grub_cmd_freebsd_module)
796 (grub_cmd_freebsd_module_elf): Abort with "You need to load the
797 kernel first." when `kernel_type' is set to KERNEL_TYPE_NONE.
799 (grub_bsd_load_aout, grub_bsd_load, grub_cmd_freebsd_loadenv)
800 (grub_cmd_freebsd_module, grub_cmd_freebsd_module_elf)
801 (GRUB_MOD_INIT (bsd)): Fix capitalization in a few error
804 2009-08-08 Robert Millan <rmh.grub@aybabtu.com>
806 * util/grub-dumpdevtree: Moved from here ...
807 * util/i386/efi/grub-dumpdevtree: ... to here.
808 (hexify): New function. Converts a string to its hex version.
809 Generate hex versions of "efi" and "device-properties" by calling
810 hexify() on the ASCII strings rather than by hardcoding numbers.
812 2009-08-08 Robert Millan <rmh.grub@aybabtu.com>
814 * fs/jfs.c: Update copyright year.
816 2009-08-08 Felix Zielcke <fzielcke@z-51.de>
818 * util/grub.d/00_header.in: Fix a comment.
819 * util/grub.d/10_linux.in: Likewise.
820 * util/grub.d/10_windows.in: Likewise.
821 * util/grub.d/10_hurd.in: Likewise.
823 2009-08-08 Felix Zielcke <fzielcke@z-51.de>
825 * util/grub-mkconfig.in: Allow the user to specify the used font
828 2009-08-08 Pavel Roskin <proski@gnu.org>
830 * include/grub/powerpc/libgcc.h: Export __ashrdi3() if
831 available, xfs.mod needs it now.
833 * util/grub-mkconfig_lib.in (version_test_numeric): Don't use
834 the "g" modifier in sed when the intention is to strip something
835 once. This fixes comparison of kernels with multiple dashes.
837 * util/grub-mkconfig.in: Define datarootdir, datadir may depend
838 on it. Add missing space before closing bracket. Fix
839 misleading formatting.
841 2009-08-07 Robert Millan <rmh.grub@aybabtu.com>
843 * docs/grub.texi: Major overhaul. Remove all sections that are
844 specific to GRUB Legacy, or mostly composed of Legacy-specific
847 2009-08-07 Robert Millan <rmh.grub@aybabtu.com>
849 * docs/version.texi: New file. Provides version information for
852 2009-08-07 Robert Millan <rmh.grub@aybabtu.com>
854 * docs/grub.texi: Update CVS information to SVN.
855 Replace outdated "GRUB 2 will include" phrase with "GRUB 2 includes".
857 2009-08-07 Felix Zielcke <fzielcke@z-51.de>
859 * util/grub-mkconfig.in: Remove a wrong `fi'.
861 2009-08-07 Felix Zielcke <fzielcke@z-51.de>
863 * fs/uuid.c (grub_jfs_superblock): New fields unused2 and uuid.
864 (grub_jfs_uuid): New function.
865 (grub_jfs_fs): Set uuid field to grub_jfs_uuid.
867 2009-08-07 Felix Zielcke <fzielcke@z-51.de>
869 * util/grub-mkconfig_lib.in (font_path): Move the functionality
871 * util/grub-mkconfig.in: ... here. Prefer unicode.pf2 and
872 unifont.pf2 over ascii.pf2. Export LANG=C in case ascii.pf2 gets used.
874 2009-08-07 Robert Millan <rmh.grub@aybabtu.com>
876 * util/grub.d/10_linux.in (test_numeric): Moved from here ...
877 * util/grub-mkconfig_lib.in (version_test_numeric): ... to here.
880 * util/grub.d/10_linux.in (test_gt): Strip any basename prefix,
881 not just "vmlinu[zx]".
883 * util/grub-mkconfig_lib.in (version_test_gt): ... to here. Update
886 * util/grub.d/10_linux.in (find_latest): Moved from here ...
887 * util/grub-mkconfig_lib.in (version_find_latest): ... to here. Update
890 2009-08-07 Robert Millan <rmh.grub@aybabtu.com>
892 * util/grub.d/10_freebsd.in: Use an absolute device path for
893 `vfs.root.mountfrom'. Set `vfs.root.mountfrom.options=rw'.
895 2009-08-06 Felix Zielcke <fzielcke@z-51.de>
897 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Fix
898 handling of multiple abstraction modules.
900 2009-08-04 Robert Millan <rmh.grub@aybabtu.com>
902 Fix a bug resulting in black screen when loading Linux using a
905 * kern/i386/pc/startup.S (grub_vbe_bios_getset_dac_palette_width): New
908 * include/grub/i386/pc/vbe.h (GRUB_VBE_CAPABILITY_DACWIDTH): New macro.
909 (grub_vbe_bios_getset_dac_palette_width): New function.
910 (grub_vbe_bios_get_dac_palette_width)
911 (grub_vbe_bios_set_dac_palette_width): New macros (act as wrappers for
912 grub_vbe_bios_getset_dac_palette_width()).
914 * video/i386/pc/vbe.c (grub_vbe_probe): Use `GRUB_VBE_STATUS_OK' to
915 check for return status.
916 (grub_vbe_get_video_mode_info): When getting information for a packed
917 mode (<= 8 bpp), obtain DAC palette width using
918 grub_vbe_bios_getset_dac_palette_width(), and use that for initializing
919 {red,green,blue}_mark_size.
921 2009-08-04 Felix Zielcke <fzielcke@z-51.de>
923 * commands/search.c (options): Fix help output to match actual code.
925 2009-08-02 Vladimir Serbinenko <phcoder@gmail.com>
927 * commands/hexdump.c (grub_cmd_hexdump): Use grub_disk_read instead
930 2009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
932 * util/hostfs.c (grub_hostfs_dir): Don't use DT_DIR: It doesn't work
935 2009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
937 Support Apple partition map with sector size different from 512 bytes.
939 * partmap/apple.c (grub_apple_header): New field 'blocksize'.
940 (apple_partition_map_iterate): Respect 'aheader.blocksize'
941 and 'apart.partmap_size'.
943 2009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
944 2009-08-01 Robert Millan <rmh.grub@aybabtu.com>
948 * commands/i386/cpuid.c (options): New variable.
949 (grub_cmd_cpuid): Return real error.
950 (GRUB_MOD_INIT(cpuid)): Declare options.
952 2009-07-31 Vladimir Serbinenko <phcoder@gmail.com>
954 * partmap/pc.c (pc_partition_map_iterate): Check that boot flags are
957 2009-07-31 Bean <bean123ch@gmail.com>
959 * fs/xfs.c (grub_xfs_sblock): Change unused5 field to log2_sect and
961 (grub_fshelp_node): Move inode field to the end.
962 (grub_xfs_data): Remove inode field.
963 (grub_xfs_inode_block): Calculate inode size using sblock.
964 (grub_xfs_inode_offset): Likewise.
965 (grub_xfs_read_inode): Calculate inode size using sblock.
966 (grub_xfs_read_block): Replace XFS_INODE_EXTENTS with nrec.
967 (grub_xfs_iterate_dir): Calculate inode size using sblock.
968 (grub_xfs_mount): Use grub_zalloc instead of grub_malloc. Realloc data
970 (grub_xfs_dir): goto mount_fail when mount fails, as data->diropen is
971 not accessible when data is null.
972 (grub_xfs_open): Likewise.
974 2009-07-31 Bean <bean123ch@gmail.com>
976 * disk/lvm.c (grub_lvm_scan_device): Ignore extra copy of metadata.
977 Don't change pv->disk if it's already set.
979 * disk/raid.c (grub_raid_scan_device): Merge this function into ...
980 (grub_raid_register): ... here.
981 (grub_raid_rescan): Removed.
983 * include/grub/raid.h (grub_raid_rescan): Removed.
985 * util/grub-fstest.c: Remove include file <grub/raid.h>.
986 (fstest): Replace grub_raid_rescan with module fini function followed
989 * util/grub-probe.c: Add include file <grub/raid.h>.
990 (probe_raid_level): New function.
991 (probe): Detect abstraction by walking the disk device, support two
992 level of abstraction (LVM on RAID) when detecting partition map.
994 2009-07-31 Pavel Roskin <proski@gnu.org>
996 * disk/raid5_recover.c (grub_raid5_recover): Revert conversion
997 to grub_zalloc(), it was erroneous.
998 Reported by Bean <bean123ch@gmail.com>
1000 2009-07-30 Vladimir Serbinenko <phcoder@gmail.com>
1002 * util/i386/pc/grub-setup.c (setup): Check that no partition is in
1003 embeding zone, not only the first one.
1005 2009-07-29 Joe Auricchio <jauricchio@gmail.com>
1007 * term/gfxterm.c (clear_char): New function.
1008 (grub_virtual_screen_setup): Use clear_char.
1009 (scroll_up): Likewise.
1010 (grub_virtual_screen_cls): Likewise.
1012 2009-07-29 Felix Zielcke <fzielcke@z-51.de>
1014 * util/deviceiter.c (get_acceleraid_disk_name): New static
1016 (grub_util_iterate_devices): Handle Accelraid devices.
1017 * util/hostdisk.c (convert_system_partition_to_system_disk): Likewise.
1019 2009-07-28 Robert Millan <rmh.grub@aybabtu.com>
1021 * loader/i386/linux.c (grub_cmd_linux): Use ',' rather than ';' as
1022 separator for the suggested gfxpayload string (';' collides with the
1023 parser and needs escaping).
1025 2009-07-28 Vladimir Serbinenko <phcoder@gmail.com>
1027 * loader/i386/multiboot_helper.S (grub_multiboot_backward_relocator):
1028 Clear direction flag before jumping to OS.
1029 (grub_multiboot2_real_boot): Likewise.
1031 2009-07-28 Felix Zielcke <fzielcke@z-51.de>
1033 * util/i386/pc/grub-install: Fix parsing of --disk-module
1036 2009-07-28 Felix Zielcke <fzielcke@z-51.de>
1038 * util/i386/pc/grub-setup.c (setup): Fix 2 incorrect checks
1041 2009-07-26 Felix Zielcke <fzielcke@z-51.de>
1043 * util/grub-mkconfig.in (package_version): New variable.
1044 Use it do display the version.
1046 2009-07-25 Felix Zielcke <fzielcke@z-51.de>
1048 * kern/file.c (grub_file_open): Revert to previous check with
1051 2009-07-25 Vladimir Serbinenko <phcoder@gmail.com>
1053 * commands/probe.c (GRUB_MOD_INIT (probe)): Remove "[--target=target]"
1054 from help line. It's out of sync with code.
1056 2009-07-25 Vladimir Serbinenko <phcoder@gmail.com>
1058 * kern/parser.c (grub_parser_execute): Fix a bug causing truncated
1059 entries on failed boot.
1061 2009-07-25 Felix Zielcke <fzielcke@z-51.de>
1063 * kern/file.c (grub_file_open): Fix an error check.
1065 2009-07-24 Vladimir Serbinenko <phcoder@gmail.com>
1067 * util/i386/pc/grub-setup.c (setup): Fix segmentation fault when
1068 partition map couldn't be identified.
1070 2009-07-23 Pavel Roskin <proski@gnu.org>
1072 * commands/xnu_uuid.c (transform): Use GRUB_CPU_WORDS_BIGENDIAN
1073 instead of WORDS_BIGENDIAN. Use grub_le_to_cpu32(), so that the
1074 case of little endian words becomes just an optimization.
1075 Respect const modifier.
1076 (md5_final): Use code that doesn't depend on endianess.
1078 * include/grub/misc.h (ALIGN_UP): Cast align to the type of addr
1079 to avoid loss of upper bits if align is unsigned and shorter
1082 2009-07-21 Vladimir Serbinenko <phcoder@gmail.com>
1084 UUID support for UFS
1086 * fs/ufs.c (grub_ufs_sblock): Add uuidhi and uuidlow.
1087 (grub_ufs_uuid): New function.
1088 (grub_ufs_fs): add .uuid
1090 2009-07-21 Pavel Roskin <proski@gnu.org>
1092 * kern/dl.c (grub_dl_check_header): Make static.
1094 2009-07-21 Felix Zielcke <fzielcke@z-51.de>
1096 * util/grub.d/30_os-prober.in: Remove unused CHAINROOT. Don't
1097 add drivemap for Vista. It breaks Windows 7.
1099 2009-07-21 Vladimir Serbinenko <phcoder@gmail.com>
1101 * fs/ufs.c (grub_ufs_sblock): Fix offset of mtime2 which was off by
1104 2009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
1108 * conf/common.rmk (grub_probe_SOURCES): Add fs/befs.c.
1109 (grub_fstest_SOURCES): Likewise.
1110 (pkglib_MODULES): Add befs.mod.
1111 (befs_mod_SOURCES): New variable.
1112 (befs_mod_CFLAGS): Likewise.
1113 (befs_mod_LDFLAGS): Likewise.
1114 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
1115 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
1116 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1117 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
1118 (grub_setup_SOURCES): Likewise.
1119 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1120 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1121 (grub_setup_SOURCES): Likewise.
1122 * fs/befs.c: New file.
1123 * fs/afs.c (GRUB_AFS_FSNAME): New declaration.
1124 (GRUB_AFS_SBLOCK_SECTOR): Likewise.
1125 (GRUB_AFS_SBLOCK_MAGIC1) [MODE_BFS]: New conditional declaration.
1126 (GRUB_AFS_BTREE_MAGIC) [MODE_BFS]: Likewise
1127 (B_KEY_INDEX_ALIGN): New declaration.
1128 (B_KEY_INDEX_OFFSET): Use B_KEY_INDEX_ALIGN.
1129 (grub_afs_bnode) [MODE_BFS]: Make key_count and key_size 16-bit
1130 (grub_afs_btree) [MODE_BFS]: New conditional declaration.
1131 (grub_afs_sblock) [MODE_BFS]: Remove link_count.
1132 (grub_afs_validate_sblock) [MODE_BFS]: Support BFS
1133 (grub_afs_mount) [MODE_BFS]: Likewise.
1134 (grub_afs_dir) [MODE_BFS]: Divide mtime by 65536 and not 1000000.
1135 (grub_afs_fs): Use GRUB_AFS_FSNAME
1136 (GRUB_MOD_INIT (afs)) [MODE_BFS]: Rename to ...
1137 (GRUB_MOD_INIT (befs)) [MODE_BFS]: ... this
1138 (GRUB_MOD_FINI (afs)) [MODE_BFS]: Rename to ...
1139 (GRUB_MOD_FINI (befs)) [MODE_BFS]: ... this
1141 2009-07-19 Yves BLUSSEAU <yves.grub-devel@zetam.org>
1143 * util/getroot.c (find_root_device): Add support for MacOSX.
1144 * util/hostdisk.c: Likewise.
1146 2009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
1148 * font/font.c (find_glyph): Check whether a font is present to avoid
1151 2009-07-20 Joe Auricchio <jauricchio@gmail.com>
1153 * term/gfxterm.c (grub_virtual_screen_setup): Clear virtual_screen.
1155 2009-07-20 Pavel Roskin <proski@gnu.org>
1157 * configure.ac: Trim excessively wordy excuses.
1159 2009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
1161 Add symlink, mtime and label support to AtheFS.
1163 * fs/afs.c (grub_afs_sblock): Declare `name' as char.
1164 (grub_afs_iterate_dir): Handle symlinks.
1165 (grub_afs_open): Use grub_afs_read_symlink.
1166 (grub_afs_dir): Likewise.
1168 (grub_afs_label): New function.
1169 (grub_afs_fs): Add grub_afs_label.
1170 (grub_afs_read_symlink): New function.
1172 2009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
1176 * fs/afs.c: Fix comments style.
1177 (grub_afs_blockrun): Declare as packed.
1178 (grub_afs_datastream): Likewise.
1179 (grub_afs_bnode): Likewise.
1180 (grub_afs_btree): Likewise.
1181 (grub_afs_sblock): Likewise.
1182 Declare `name' as char.
1183 (grub_afs_inode): Declare as packed.
1184 Change void *vnode to grub_uint32_t unused.
1185 (grub_afs_iterate_dir): Check that key_size is positive.
1186 (grub_afs_mount): Don't read superblock twice.
1187 (grub_afs_dir): Don't free node in case of error,
1188 grub_fshelp_find_file already handles this.
1189 (grub_afs_open): Likewise.
1191 2009-07-19 Pavel Roskin <proski@gnu.org>
1193 * Makefile.in: Remove LIBLZO and enable_lzo.
1194 * conf/i386-pc.rmk: Remove lzo support.
1195 * configure.ac: Remove checks for lzo, don't define ENABLE_LZMA.
1196 * include/grub/i386/pc/kernel.h: Define ENABLE_LZMA. Remove lzo
1198 * kern/i386/pc/lzo1x.S: Remove.
1199 * kern/i386/pc/startup.S: Remove lzo support.
1200 * util/i386/pc/grub-mkimage.c: Likewise.
1202 2009-07-19 Vladimir Serbinenko <phcoder@gmail.com>
1204 * disk/usbms.c (grub_usbms_transfer): Fix double semicolon.
1205 * fs/xfs.c (grub_xfs_dir): Likewise.
1206 * fs/afs.c (grub_afs_dir): Likewise.
1207 * fs/iso9660.c (grub_iso9660_iterate_dir): Likewise.
1208 (grub_iso9660_open): Likewise.
1209 * fs/jfs.c (grub_jfs_open): Likewise.
1210 * fs/ext2.c (grub_ext2_dir): Likewise.
1211 * include/grub/macho.h (grub_macho_fat_arch): Likewise.
1212 * script/sh/lexer.c (grub_script_yylex): Likewise.
1214 2009-07-16 Pavel Roskin <proski@gnu.org>
1216 * configure.ac: Never add "-c" to CFLAGS.
1218 * configure.ac: Fix incorrect comparison for grub_cv_cc_efiemu.
1220 * configure.ac: Fix wrong use of grub_cv_cc_no_red_zone where
1221 grub_cv_cc_efiemu should be used.
1223 * configure.ac: Typo fixes.
1225 * kern/mm.c (grub_zalloc): New function.
1226 (grub_debug_zalloc): Likewise.
1227 * include/grub/mm.h: Declare grub_zalloc() and
1228 grub_debug_zalloc().
1229 * util/misc.c (grub_zalloc): New function.
1230 * bus/usb/uhci.c (grub_uhci_pci_iter): Use grub_zalloc()
1231 instead of grub_malloc(), remove unneeded initializations.
1232 * bus/usb/usbhub.c (grub_usb_hub_add_dev): Likewise.
1233 * commands/extcmd.c (grub_extcmd_dispatcher): Likewise.
1234 * commands/parttool.c (grub_cmd_parttool): Likewise.
1235 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): Likewise.
1236 * disk/raid5_recover.c (grub_raid5_recover): Likewise.
1237 * disk/raid6_recover.c (grub_raid6_recover): Likewise.
1238 * disk/usbms.c (grub_usbms_finddevs): Likewise.
1239 * efiemu/mm.c (grub_efiemu_request_memalign): Likewise.
1240 * efiemu/pnvram.c (grub_efiemu_pnvram): Likewise.
1241 (grub_cmd_efiemu_pnvram): Likewise.
1242 * fs/i386/pc/pxe.c (grub_pxefs_open): Likewise.
1243 * fs/iso9660.c (grub_iso9660_mount): Likewise.
1244 (grub_iso9660_iterate_dir): Likewise.
1245 * fs/jfs.c (grub_jfs_opendir): Likewise.
1246 * fs/ntfs.c (list_file): Likewise.
1247 (grub_ntfs_mount): Likewise.
1248 * kern/disk.c (grub_disk_open): Likewise.
1249 * kern/dl.c (grub_dl_load_core): Likewise.
1250 * kern/elf.c (grub_elf_file): Likewise.
1251 * kern/env.c (grub_env_context_open): Likewise.
1252 (grub_env_set): Likewise.
1253 (grub_env_set_data_slot): Likewise.
1254 * kern/file.c (grub_file_open): Likewise.
1255 * kern/fs.c (grub_fs_blocklist_open): Likewise.
1256 * loader/i386/multiboot.c (grub_module): Likewise.
1257 * loader/xnu.c (grub_xnu_create_key): Likewise.
1258 (grub_xnu_create_value): Likewise.
1259 * normal/main.c (grub_normal_add_menu_entry): Likewise.
1260 (read_config_file): Likewise.
1261 * normal/menu_entry.c (make_screen): Likewise.
1262 * partmap/sun.c (sun_partition_map_iterate): Likewise.
1263 * script/sh/lexer.c (grub_script_lexer_init): Likewise.
1264 * script/sh/script.c (grub_script_parse): Likewise.
1265 * video/bitmap.c (grub_video_bitmap_create): Likewise.
1266 * video/readers/jpeg.c (grub_video_reader_jpeg): Likewise.
1267 * video/readers/png.c (grub_png_output_byte): Likewise.
1268 (grub_video_reader_png): Likewise.
1270 2009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
1272 Enable all targets that can be built by default
1274 * configure.ac: enable efiemu runtime, grub-emu, grub-emu-usb,
1275 grub-mkfont and grub-fstest if they can be built
1277 2009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
1279 Fix hang and segmentation fault in grub-emu-usb
1281 * disk/scsi.c (grub_scsi_open): return err and not grub_errno
1282 * util/usb.c (grub_libusb_devices): likewise
1283 (grub_libusb_init): rename to ...
1284 (GRUB_MOD_INIT (libusb)):...this
1285 (grub_libusb_fini): rename to ..
1286 (GRUB_MOD_FINI (libusb)):...this
1287 * disk/usbms.c (grub_usbms_transfer): fix retry logic
1288 * include/grub/disk.h (grub_raid_init): removed, it's useless
1289 (grub_raid_fini): likewise
1290 (grub_lvm_init): likewise
1291 (grub_lvm_fini): likewise
1292 * util/grub-emu.c (main): don't call grub_libusb_init, it's done
1295 2009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
1299 * Makefile.in (LIBUSB): new macro
1300 * genmk.rb (Utility/print_tail): new method
1301 (Utility/rule): use intermediary variable #{prefix}_OBJECTS
1302 (top level): call util.print_tail at the end.
1304 2009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
1306 Make FreeBSD accept zpool.cache
1308 * loader/i386/bsd.c (grub_freebsd_add_meta_module): spoof filename if
1309 type is /boot/zfs/zpool.cache
1311 2009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
1315 * include/grub/efiemu/efiemu.h (grub_efiemu_configuration_table64_t):
1316 correct wrong typedef
1317 * efiemu/prepare.c (SUFFIX (grub_efiemu_prepare)): minor style fixes
1319 2009-07-15 Pavel Roskin <proski@gnu.org>
1321 * include/grub/disk.h (struct grub_disk_dev): Use enum for id.
1322 * kern/disk.c (struct grub_disk_cache): Likewise.
1324 * commands/probe.c (options): Typo fix.
1326 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_BPB_END):
1327 Increase to 0x5a to accommodate FAT32. Adjust other offsets
1329 Original patch by Yves Blusseau <yves.grub-devel@zetam.org>
1331 * boot/i386/pc/boot.S (general_error_string): Add DOS newline at
1332 the end of "Error" to make the message more readable.
1334 * boot/i386/pc/boot.S (kernel_segment): Remove.
1335 (copy_buffer): Use GRUB_BOOT_MACHINE_KERNEL_ADDR in segment 0
1338 * boot/i386/pc/boot.S (boot_version): Remove.
1339 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_VER_MAJ):
1342 * include/grub/i386/pc/boot.h: Sort all offsets.
1343 (GRUB_BOOT_MACHINE_KERNEL_ADDRESS): Remove, it's unused.
1344 (GRUB_BOOT_MACHINE_KERNEL_SEGMENT): Likewise.
1345 * boot/i386/pc/boot.S: Assert location of every offset listed in
1346 include/grub/i386/pc/boot.h.
1348 2009-07-13 Pavel Roskin <proski@gnu.org>
1350 * include/grub/i386/coreboot/machine.h: Rename
1351 GRUB_MACHINE_LINUXBIOS to GRUB_MACHINE_COREBOOT.
1352 * loader/multiboot_loader.c (grub_cmd_multiboot_loader): Allow
1353 multiboot 1 for GRUB_MACHINE_COREBOOT and GRUB_MACHINE_QEMU.
1355 * kern/dl.c: Force native word size to suppress warnings when
1358 * kern/device.c (grub_device_iterate): Change struct part_ent to
1359 hold the name, not a pointer to it. Use one grub_malloc() per
1360 partition, not two. Free partition_name if grub_malloc() fails.
1361 Set ents to NULL only before grub_partition_iterate() is called.
1363 2009-07-11 Bean <bean123ch@gmail.com>
1365 * kern/ieee1275/openfw.c (grub_children_iterate): Fix size of
1368 2009-07-10 Bean <bean123ch@gmail.com>
1369 2009-07-10 Robert Millan <rmh.grub@aybabtu.com>
1371 * kern/ieee1275/openfw.c (grub_children_iterate)
1372 (grub_devalias_iterate): Fix size evaluation for property or path
1373 strings, which was broken since r2132.
1375 2009-07-07 Pavel Roskin <proski@gnu.org>
1377 * commands/search.c (search_file): Merge into ...
1378 (search_fs): ... this. Accept search type as argument.
1379 (grub_cmd_search): Pass search type to search_fs().
1381 * include/grub/util/console.h: New file.
1382 * util/console.c: Use it instead of grub/machine/console.h.
1383 * util/grub-emu.c: Likewise.
1385 * lib/arg.c (find_long_option): Remove.
1386 (find_long): Add `len' argument, make `s' const char *.
1387 (grub_arg_parse): Parse long options in place, not in a
1390 2009-07-06 Pavel Roskin <proski@gnu.org>
1392 * commands/search.c (search_fs): Fix potential NULL pointer
1395 * commands/search.c (search_fs): Replace QUID macro with quid_fn
1398 2009-07-06 Daniel Mierswa <impulze@impulze.org>
1400 * commands/search.c (search_fs): Use grub_strcasecmp() for UUID
1403 2009-07-05 Pavel Roskin <proski@gnu.org>
1405 * include/grub/i386/linux.h (struct linux_kernel_params):
1406 Restore padding3, it's still needed.
1408 * util/grub.d/10_freebsd.in: Fix spelling of `device.hints' on
1410 * util/osdetect.lua: Likewise.
1412 2009-07-05 Bean <bean123ch@gmail.com>
1414 * conf/common.rmk (lua_mode_SOURCES): Add script/lua/lstrlib.c.
1416 * script/lua/grub_lib.c (grub_lua_run): Check input parameter.
1417 (grub_lua_getenv): Likewise.
1418 (grub_lua_setenv): Likewise.
1419 (save_errno): New function.
1420 (push_result): Likewise.
1421 (grub_lua_enum_device): Likewise.
1422 (grub_lua_enum_file): Likewise.
1423 (grub_lua_file_open): Likewise.
1424 (grub_lua_file_close): Likewise.
1425 (grub_lua_file_seek): Likewise.
1426 (grub_lua_file_read): Likewise.
1427 (grub_lua_file_getline): Likewise.
1428 (grub_lua_file_getsize): Likewise.
1429 (grub_lua_file_getpos): Likewise.
1430 (grub_lua_file_eof): Likewise.
1431 (grub_lua_file_exist): Likewise.
1432 (grub_lua_add_menu): Likewise.
1434 * script/lua/grub_lua.h (isupper): New inline function.
1435 (islower): Likewise.
1436 (ispunct): Likewise.
1437 (isxdigit): Likewise.
1438 (strcspn): Change to normal function.
1439 (strpbkr): New function declaration.
1442 * script/lua/grub_main.c (scan_str): New function.
1443 (strcspn): Likewise.
1444 (strpbrk): Likewise.
1447 * script/lua/linit.c (lualibs): Enable the string library.
1449 * util/osdetect.lua: New file.
1451 2009-07-04 Robert Millan <rmh.grub@aybabtu.com>
1453 * include/grub/i386/linux.h (struct linux_kernel_params): Add
1454 `capabilities' member.
1456 2009-07-02 Pavel Roskin <proski@gnu.org>
1458 * genparttoollist.sh: Add missing newline at the end.
1460 2009-07-01 Pavel Roskin <proski@gnu.org>
1462 * kern/x86_64/efi/callwrap.S: Add missing newline at the end.
1464 * util/hostdisk.c (open_device): Remove `const' from
1465 `sysctl_size', as sysctlbyname() can change it (in this case it
1466 doesn't actually happen).
1468 * include/grub/types.h: Define GRUB_LONG_MAX and GRUB_LONG_MIN
1469 using signed long int constants.
1471 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): Make `p'
1472 constant to avoid a warning on FreeBSD.
1474 * util/hostdisk.c (device_is_wholedisk): Compile only on systems
1477 * Makefile.in: Install include/grub/machine symlink.
1479 * Makefile.in: When installing symlinks, use "cp -fR", which
1480 works on FreeBSD and MacOSX.
1481 From Yves Blusseau <cl7m42e02@sneakemail.com>
1483 * kern/dl.c (grub_dl_resolve_symbol): Make static.
1484 * include/grub/dl.h: Remove grub_dl_resolve_symbol().
1486 * util/misc.c: Move grub_reboot() and grub_halt() ...
1487 * util/grub-emu.c: ... here. Make main_env static.
1488 * include/grub/util/misc.h: Remove main_env.
1490 * kern/mm.c: Use correct format to print size_t.
1492 * include/grub/elf.h: Define Elf_Sword and Elf_Xword.
1493 * kern/i386/dl.c: Use ELF symbols without "32" or "64".
1494 * kern/powerpc/dl.c: Likewise.
1495 * kern/sparc64/dl.c: Likewise.
1496 * kern/x86_64/dl.c: Likewise.
1498 2009-07-01 Robert Millan <rmh.grub@aybabtu.com>
1500 Fix grub-emu build on sparc64-ieee1275.
1502 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Synchronize with ...
1503 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): ... this.
1505 2009-07-01 Robert Millan <rmh.grub@aybabtu.com>
1507 * util/misc.c: Include `<setjmp.h>' and `<grub/machine/machine.h>'.
1508 (grub_reboot, grub_halt): New functions.
1510 * util/i386/pc/misc.c: Delete. Update all users.
1511 * util/sparc64/ieee1275/misc.c: Likewise.
1512 * util/powerpc/ieee1275/misc.c: Likewise.
1514 2009-07-01 Robert Millan <rmh.grub@aybabtu.com>
1516 * conf/i386.rmk (setjmp_mod_SOURCES)
1517 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): Move to ...
1518 * conf/common.rmk (setjmp_mod_SOURCES)
1519 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): ... here, and modify
1520 to use $(target_cpu).
1521 * conf/x86_64-efi.rmk (setjmp_mod_SOURCES)
1522 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): Remove.
1523 * conf/powerpc-ieee1275.rmk: Likewise.
1524 * conf/sparc64-ieee1275.rmk: Likewise.
1526 * conf/i386-pc.rmk (kernel_img_SOURCES): Use
1527 $(target_cpu) for kern/$(target_cpu)/dl.c.
1528 * conf/i386-efi.rmk: Likewise.
1529 * conf/i386-ieee1275.rmk: Likewise.
1530 * conf/x86_64-efi.rmk: Likewise.
1531 * conf/i386-coreboot.rmk: Likewise.
1532 * conf/powerpc-ieee1275.rmk (kernel_img_SOURCES): Use
1533 $(target_cpu) for kern/$(target_cpu)/dl.c and for
1534 kern/$(target_cpu)/cache.S.
1535 * conf/sparc64-ieee1275.rmk: Likewise.
1537 2009-07-01 Robert Millan <rmh.grub@aybabtu.com>
1539 * include/grub/i386/linux.h (linux_kernel_params): Change `mmap_size'
1540 type to `grub_uint8_t', and adjust `padding9' accordingly.
1542 2009-06-29 Robert Millan <rmh.grub@aybabtu.com>
1544 * include/grub/i386/linux.h (GRUB_VIDEO_TYPE_TEXT): New macro.
1546 * loader/i386/linux.c [__i386__] (grub_linux_boot): Simplify inline
1547 assembly in final jump, using register constraints.
1549 (grub_linux_boot): For text mode, initialize `have_vga' using
1550 GRUB_VIDEO_TYPE_TEXT rather than 0 (this changes its value to 1).
1552 Initialize `video_cursor_x' and `video_cursor_y' as late as possible,
1553 right before the final jump.
1555 Set `video_mode' to 0x3.
1557 Document initialization of `video_page', `video_mode' and
1560 2009-06-29 Robert Millan <rmh.grub@aybabtu.com>
1562 * include/grub/i386/linux.h (GRUB_LINUX_FLAG_QUIET): New macro.
1563 * loader/i386/linux.c (grub_cmd_linux): Recognize "quiet" option,
1564 and set GRUB_LINUX_FLAG_QUIET appropriately.
1566 2009-06-29 Robert Millan <rmh.grub@aybabtu.com>
1568 Fix build on Debian / sparc.
1570 * configure.ac: Recognize `sparc' target_cpu (as sparc64).
1572 2009-06-28 Pavel Roskin <proski@gnu.org>
1574 * kern/i386/qemu/mmap.c (grub_machine_mmap_iterate): Use cast to
1577 * util/grub.d/10_linux.in: Match SUSE style initrd names.
1579 2009-06-27 Robert Millan <rmh.grub@aybabtu.com>
1581 * loader/i386/linux.c (grub_linux_boot): Fix uninitialized use of
1584 2009-06-27 Robert Millan <rmh.grub@aybabtu.com>
1588 * loader/i386/linux.c (grub_cmd_linux): Don't call grub_error when
1589 file can't be opened. grub_file_open() is already supposed to set
1590 grub_errno / grub_errmsg appropriately.
1591 * loader/i386/pc/linux.c (grub_cmd_linux): Likewise.
1593 2009-06-27 Pavel Roskin <proski@gnu.org>
1594 2009-06-27 Robert Millan <rmh.grub@aybabtu.com>
1596 * include/grub/dl.h: Include grub/elf.h.
1597 (struct grub_dl): Add symtab field.
1598 * kern/dl.c [GRUB_MACHINE_QEMU]: Define
1599 GRUB_MODULES_MACHINE_READONLY.
1600 (grub_dl_resolve_symbols): Populate mod->symtab, making a copy
1601 of the header for read-only modules.
1602 (grub_dl_unload): Free mod->symtab for read-only modules.
1603 * kern/i386/dl.c: Use mod->symtab.
1604 * kern/powerpc/dl.c: Likewise.
1605 * kern/sparc64/dl.c: Likewise.
1606 * kern/x86_64/dl.c: Likewise.
1608 * conf/i386-qemu.rmk: New file.
1609 * kern/i386/qemu/startup.S: Likewise.
1610 * kern/i386/qemu/mmap.c: Likewise.
1611 * boot/i386/qemu/boot.S: Likewise.
1612 * include/grub/i386/qemu/time.h: Likewise.
1613 * include/grub/i386/qemu/serial.h: Likewise.
1614 * include/grub/i386/qemu/kernel.h: Likewise.
1615 * include/grub/i386/qemu/console.h: Likewise.
1616 * include/grub/i386/qemu/boot.h: Likewise.
1617 * include/grub/i386/qemu/init.h: Likewise.
1618 * include/grub/i386/qemu/machine.h: Likewise.
1619 * include/grub/i386/qemu/loader.h: Likewise.
1620 * include/grub/i386/qemu/memory.h: Likewise.
1622 * conf/i386-coreboot.rmk (GRUB_BOOT_MACHINE_LINK_ADDR)
1623 (GRUB_KERNEL_MACHINE_LINK_ADDR): New variables.
1624 [qemu] (pkglib_IMAGES): Add `boot.img'.
1625 [qemu] (boot_img_SOURCES, boot_img_ASFLAGS, boot_img_LDFLAGS)
1626 [qemu] (boot_img_FORMAT): New variables.
1627 [qemu] (bin_UTILITIES): Add `grub-mkimage'.
1628 [qemu] (grub_mkimage_SOURCES, grub_mkimage_CFLAGS): New variables.
1629 [qemu] (kernel_img_SOURCES, kernel_img_HEADERS, kernel_img_CFLAGS)
1630 [qemu] (kernel_img_ASFLAGS, kernel_img_LDFLAGS)
1631 [qemu] (kernel_img_FORMAT): New variables.
1633 * configure.ac: Recognise `i386-qemu'.
1635 * util/i386/pc/grub-mkimage.c (compress_kernel): Add dummy variant
1636 (for no compression).
1637 [GRUB_MACHINE_QEMU] (generate_image): Misc adjustments to produce
1638 a valid i386 ROM image. Make `GRUB_KERNEL_MACHINE_COMPRESSED_SIZE',
1639 `GRUB_KERNEL_MACHINE_INSTALL_DOS_PART' and
1640 `GRUB_KERNEL_MACHINE_INSTALL_BSD_PART' optional features (with
1643 2009-06-27 Pavel Roskin <proski@gnu.org>
1645 * efiemu/prepare.c: Eliminate TYPE macro, it makes code hard to
1647 * efiemu/prepare32.c: Likewise.
1648 * efiemu/prepare64.c: Likewise.
1650 2009-06-26 Pavel Roskin <proski@gnu.org>
1652 * include/grub/types.h: Define GRUB_TARGET_WORDSIZE.
1653 * include/grub/elf.h: Define symbols without "32" or "64" based
1654 on GRUB_TARGET_WORDSIZE.
1655 * include/grub/multiboot2.h: Use GRUB_TARGET_WORDSIZE.
1656 * efiemu/loadcore32.c: Redefine GRUB_TARGET_WORDSIZE, remove own
1658 * efiemu/loadcore64.c: Likewise.
1659 * loader/i386/bsd32.c: Likewise.
1660 * loader/i386/bsd64.c: Likewise.
1661 * kern/dl.c: Remove own ELF definitions.
1662 * util/i386/efi/grub-mkimage.c: Likewise.
1664 2009-06-23 Robert Millan <rmh.grub@aybabtu.com>
1666 * kern/i386/pc/startup.S (real_to_prot): Access `gdtdesc' using
1667 segment 0x0 unconditionally, because the reference generated by
1668 GAS is an absolute address.
1670 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
1672 * include/grub/i386/kernel.h: Include `<grub/machine/machine.h>'.
1673 [! GRUB_MACHINE_IEEE1275]: Set `GRUB_MOD_ALIGN' to 0x1.
1675 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
1677 * commands/search.c (grub_cmd_search): Macroify hardcoded args[]
1678 indexes. Check for -f explicitly.
1679 (search_file): Improve error message.
1680 (GRUB_MOD_INIT(search)): Add missing `-n' to help output.
1682 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
1684 * conf/i386-pc.rmk (GRUB_MEMORY_MACHINE_LINK_ADDR): Rename to ...
1685 (GRUB_KERNEL_MACHINE_LINK_ADDR): ... this. Update all users.
1687 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
1689 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/misc.S'.
1690 * conf/i386-ieee1275.rmk: Likewise.
1691 * conf/i386-coreboot.rmk: Likewise.
1693 * kern/i386/pc/startup.S (grub_stop): Remove function.
1694 * kern/i386/ieee1275/startup.S: Likewise.
1695 * kern/i386/coreboot/startup.S: Likewise.
1696 * kern/i386/misc.S (grub_stop): New function.
1698 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
1700 * kern/i386/pc/startup.S (real_to_prot): Move from here ...
1701 * kern/i386/realmode.S (real_to_prot): ... to here.
1703 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
1705 * conf/i386-ieee1275.rmk (pkglib_PROGRAMS): Replace `kernel.elf'
1707 (kernel_elf_SOURCES): Rename to ...
1708 (kernel_img_SOURCES): ... this.
1709 (kernel_elf_HEADERS): Rename to ...
1710 (kernel_img_HEADERS): ... this. Update all users.
1711 (kernel_elf_ASFLAGS): Rename to ...
1712 (kernel_img_ASFLAGS): ... this.
1713 (kernel_elf_CFLAGS): Rename to ...
1714 (kernel_img_CFLAGS): ... this.
1715 (kernel_elf_LDFLAGS): Rename to ...
1716 (kernel_img_LDFLAGS): ... this.
1717 * conf/i386-coreboot.rmk: Likewise.
1718 * conf/powerpc-ieee1275.rmk: Likewise.
1720 * util/elf/grub-mkimage.c (add_segments): Replace "kernel.elf"
1723 2009-06-21 Pavel Roskin <proski@gnu.org>
1725 * loader/powerpc/ieee1275/linux.c (offset_phdr): Fix prototypes
1726 to match nested functions.
1727 * loader/sparc64/ieee1275/linux.c: Likewise.
1729 * conf/i386-ieee1275.rmk: Define kernel_elf_ASFLAGS.
1731 2009-06-21 Robert Millan <rmh.grub@aybabtu.com>
1733 * configure.ac: Enable `END_SYMBOL' / `BSS_START_SYMBOL' test on
1736 2009-06-21 Robert Millan <rmh.grub@aybabtu.com>
1738 Fix asm file handling on ELF, and remove workarounds.
1740 * genmk.rb (class Programs): Detect assembly files, and set ASFLAGS
1741 and -DASM_FILE=1 appropriately (copied from `class Images' stanza).
1742 * kern/i386/ieee1275/startup.S (ASM_FILE): Remove macro.
1743 * kern/i386/coreboot/startup.S (ASM_FILE): Likewise.
1745 2009-06-21 Vladimir Serbinenko <phcoder@gmail.com>
1747 Load BSD ELF modules
1749 * conf/i386-pc.rmk (bsd_mod_SOURCES): Add loader/i386/bsd32.c
1750 and loader/i386/bsd64.c
1751 * include/grub/i386/bsd.h (FREEBSD_MODTYPE_MODULE): Remove
1752 (FREEBSD_MODTYPE_ELF_MODULE): New definition
1753 (FREEBSD_MODTYPE_ELF_MODULE_OBJ): Likewise
1754 (grub_freebsd_load_elfmodule32): New declaration
1755 (grub_freebsd_load_elfmoduleobj64): Likewise
1756 (grub_freebsd_load_elf_meta32): Likewise
1757 (grub_freebsd_load_elf_meta64): Likewise
1758 (grub_freebsd_add_meta): Likewise
1759 (grub_freebsd_add_meta_module): Likewise
1760 * loader/i386/bsd.c (grub_freebsd_add_meta): Make global
1761 (grub_freebsd_add_meta_module): Likewise and move module-specific
1762 parts to grub_cmd_freebsd and grub_cmd_freebsd_module
1763 (grub_cmd_freebsd): Add elf-kernel specific parts
1764 based on grub_freebsd_add_meta_module
1765 (grub_cmd_freebsd_module): Add type parsing moved from
1766 grub_freebsd_add_meta_module
1767 (grub_cmd_freebsd_module_elf): New function
1768 (cmd_freebsd_module_elf): New variable
1769 (GRUB_MOD_INIT): Register freebsd_module_elf
1770 * loader/i386/bsd32.c: New file
1771 * loader/i386/bsd64.c: Likewise
1772 * loader/i386/bsdXX.c: Likewise
1773 * kern/elf.c (grub_elf32_load): Let hook decide which pheaders to load
1774 (grub_elf64_load): Likewise
1775 * include/grub/elfload.h (grub_elf32_load_hook_t): New parameter do_load
1777 (grub_elf64_load_hook_t): Likewise
1779 2009-06-21 Colin Watson <cjwatson@ubuntu.com>
1781 * util/grub-mkconfig.in (GRUB_DISABLE_LINUX_RECOVERY): Export
1783 * util/grub.d/10_linux.in: If GRUB_DISABLE_LINUX_RECOVERY is true,
1784 don't write a menu entry for recovery mode.
1786 2009-06-20 Robert Millan <rmh.grub@aybabtu.com>
1788 * util/i386/pc/grub-mkimage.c (main): Oops, free `output' only
1789 after it's no longer needed.
1791 2009-06-20 Robert Millan <rmh.grub@aybabtu.com>
1793 * include/grub/i386/loader.h (grub_linux_prot_size)
1794 (grub_linux_tmp_addr, grub_linux_real_addr)
1795 (grub_linux_is_bzimage, grub_linux16_boot): Declare only on
1796 GRUB_MACHINE_PCBIOS.
1797 * util/i386/pc/grub-mkimage.c (compress_kernel): Move
1798 common grub_util_info() call to ...
1799 (generate_image): ... here.
1800 Fix use of uninitialized memory, comparison of signed with
1801 unsigned integers and memory leak.
1802 Remove bogus module address message.
1804 2009-06-20 Vladimir Serbinenko <phcoder@gmail.com>
1806 * disk/mdraid_linux.c (GRUB_MOD_FINI): use grub_raid_unregister and not
1808 * disk/dmraid_nvidia.c (GRUB_MOD_FINI): likewise
1810 2009-06-19 Pavel Roskin <proski@gnu.org>
1812 * configure.ac: Remove stray AC_MSG_CHECKING.
1814 2009-06-19 Vladimir Serbinenko <phcoder@gmail.com>
1816 * disk/scsi.c (grub_scsi_open): use continue instead of big if
1818 2009-06-18 Pavel Roskin <proski@gnu.org>
1820 * conf/common.rmk: Add fs_file.mod.
1821 * disk/fs_file.c: New file.
1822 * include/grub/disk.h (enum grub_disk_dev_id): Add
1823 GRUB_DISK_DEVICE_FILE_ID.
1825 2009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
1827 Fix build with Apple's toolchain. Part 2
1829 * aclocal.m4 (grub_PROG_TARGET_CC): add missing prototype for main and
1832 2009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
1834 Fix build with Apple's toolchain. Part 1
1836 * commands/i386/pc/drivemap_int13h.S: use assembly-time constants
1838 * configure.ac: remove a leftover AC_MSG_RESULT
1839 (CFLAGS): don't add -Wl,--defsym,___main=0x8100 when building with
1842 2009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
1846 * fs/ntfscomp.c (decomp_get16): initialize c1 and c2
1847 (decomp_block): initialize ch
1848 use grub_memcpy instead of memcpy
1850 2009-06-17 Pavel Roskin <proski@gnu.org>
1852 * include/grub/i386/coreboot/console.h: Don't use the i386-pc
1853 version, use declarations needed to use vga_text as the startup
1856 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Remove
1857 term/i386/pc/at_keyboard.c, it doesn't need to be compiled into
1859 * kern/i386/coreboot/init.c: Don't call grub_at_keyboard_init()
1860 and grub_at_keyboard_fini(), it's done on module load and
1863 2009-06-17 Felix Zielcke <fzielcke@z-51.de>
1865 * loader/i386/linux.c (grub_cmd_linux): Set grub_error if the
1866 file can't be found.
1867 * loader/i386/pc/linux.c (grub_cmd_linux): Likewise.
1869 2009-06-17 Vladimir Serbinenko <phcoder@gmail.com>
1871 Fix newline handling
1873 * include/grub/script_sh.h (grub_lexer_param): new field was_newline
1874 * script/sh/lexer.c (grub_script_lexer_init): initialize was_newline
1875 (grub_script_yylex): don't segfault on unterminated script
1876 newline terminates command and variable
1878 2009-06-17 Vladimir Serbinenko <phcoder@gmail.com>
1880 avoid double grub_adjust_range call. Bug reported by David Simner
1882 * kern/disk.c (grub_disk_write): change to raw disk access before
1885 2009-06-17 Colin Watson <cjwatson@ubuntu.com>
1887 * util/elf/grub-mkimage.c (usage): Prefix each option line with two
1888 spaces, for the benefit of help2man.
1889 * util/i386/efi/grub-mkimage.c (usage): Likewise.
1891 2009-06-16 Pavel Roskin <proski@gnu.org>
1893 * kern/i386/halt.c: Include grub/machine/init.h.
1894 * kern/i386/reboot.c: Include grub/cpu/reboot.h.
1896 2009-06-16 Felix Zielcke <fzielcke@z-51.de>
1898 * util/grub.d/30_os-prober.in: Use ${root} in the generated
1901 2009-06-16 James Jarvis <James.Jarvis@ed.ac.uk>
1903 * commands/help.c GRUB_MOD_INIT(echo): Fix the help output of
1906 2009-06-16 Pavel Roskin <proski@gnu.org>
1908 * boot/i386/pc/boot.S: Remove root_drive. Assert offset of
1909 boot_drive_check by using GRUB_BOOT_MACHINE_DRIVE_CHECK. Don't
1910 save %dx, we only need %dl and we never change it.
1911 * boot/i386/pc/cdboot.S: Don't set the root drive.
1912 * boot/i386/pc/pxeboot.S: Likewise.
1913 * include/grub/i386/pc/boot.h: Remove
1914 GRUB_BOOT_MACHINE_ROOT_DRIVE, adjust
1915 GRUB_BOOT_MACHINE_DRIVE_CHECK.
1916 * include/grub/i386/pc/kernel.h: Remove grub_root_drive.
1917 * kern/i386/pc/init.c (make_install_device): Remove references
1919 * kern/i386/pc/startup.S: Likewise.
1920 * util/i386/pc/grub-setup.c (setup): Don't set root_drive.
1922 2009-06-16 Vladimir Serbinenko <phcoder@gmail.com>
1926 * commands/xnu_uuid.c: new file
1927 * conf/common.rmk (pkglib_MODULES): add xnu_uuid.mod
1928 (xnu_uuid_mod_SOURCES): new variable
1929 (xnu_uuid_mod_CFLAGS): likewise
1930 (xnu_uuid_mod_LDFLAGS): likewise
1931 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/probe.c
1932 * conf/i386-ieee1275.rmk: likewise
1933 * conf/i386-pc.rmk: likewise
1934 * conf/powerpc-ieee1275.rmk: likewise
1935 * conf/sparc64-ieee1275.rmk: likewise
1936 * util/grub.d/30_os-prober.in: use UUID for Mac OS X/Darwin
1938 2009-06-16 Pavel Roskin <proski@gnu.org>
1940 * configure.ac: Avoid '==' in test command, it's not portable.
1942 2009-06-16 Vladimir Serbinenko <phcoder@gmail.com>
1946 * commands/probe.c: new file
1947 * conf/common.rmk (pkglib_MODULES): add probe.mod
1948 (probe_mod_SOURCES): new variable
1949 (probe_mod_CFLAGS): likewise
1950 (probe_mod_LDFLAGS): likewise
1951 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/probe.c
1952 * conf/i386-ieee1275.rmk: likewise
1953 * conf/i386-pc.rmk: likewise
1954 * conf/powerpc-ieee1275.rmk: likewise
1955 * conf/sparc64-ieee1275.rmk: likewise
1957 2009-06-15 Vladimir Serbinenko <phcoder@gmail.com>
1959 Fix handling of string like \"hello\" and "a
1962 * script/sh/lexer.c (check_textstate): accept GRUB_PARSER_STATE_ESC
1963 (grub_script_yylex): fix parsing of quoting, escaping and newline
1965 2009-06-13 Vladimir Serbinenko <phcoder@gmail.com>
1967 * loader/i386/multiboot.c (grub_multiboot_get_bootdev): fix partition
1970 2009-06-13 Jun Inoue <jun.lambda@gmail.com>
1972 * util/grub-mkconfig.in: Fix parsing of --output option.
1974 2009-06-12 Pavel Roskin <proski@gnu.org>
1976 * Makefile.in (pkgdata_SRCDIR): Remove. genmodsrc.sh and
1977 genmk.rb don't need to be generated or installed.
1979 2009-06-12 Vladimir Serbinenko <phcoder@gmail.com>
1981 * commands/i386/pc/drivemap_int13h.S: add more comments
1983 2009-06-11 Pavel Roskin <proski@gnu.org>
1985 * Makefile.in (uninstall): Uninstall manuals.
1987 * Makefile.in: Rename lib_DATA to lib_SCRIPTS, move it from
1988 PKGLIB to SCRIPTS. This fixes installation of grub-mkconfig_lib
1989 and update-grub_lib in two places.
1990 * conf/common.rmk: Rename lib_DATA to lib_SCRIPTS.
1992 * disk/usbms.c (grub_usbms_transfer): Initialize `err' to fix
1995 * loader/i386/bsd.c (grub_freebsd_boot): Rename `entry' to
1996 `entry_lo' to fix variable shadowing.
1998 2009-06-11 Christian Franke <franke@computer.org>
2000 * kern/misc.c (__enable_execute_stack): Add missing return type
2001 to prevent gcc warning.
2003 2009-06-11 Felix Zielcke <fzielcke@z-51.de>
2005 * conf/i386-ieee1275.rmk (COMMON_LDFLAGS): Remove `-static -lgcc'.
2007 2009-06-11 Pavel Roskin <proski@gnu.org>
2009 * Makefile.in: Don't rely on any scripts being executable.
2010 Always use $(SHELL) to run shell scripts.
2012 * configure.ac: Always define ___main if using -nostdlib. This
2013 fixes tests on Cygwin.
2015 2009-06-11 Giuseppe Caizzone <acaizzo@gmail.com>
2019 * fs/udf.c (grub_udf_read_block): handle the fact that ad->length
2020 is in bytes and not in blocks
2022 2009-06-11 Pavel Roskin <proski@gnu.org>
2024 * kern/i386/halt.c (grub_halt): Make `i' unsigned to fix a
2027 2009-06-11 Felix Zielcke <fzielcke@z-51.de>
2029 * util/grub.d/30_os-prober.in: Fix a comment. Source
2030 ${libdir}/grub/grub-mkconfig_lib. Use prepare_grub_to_access_device
2031 to set the root device. Place drivemap command in the generated
2034 2009-06-11 Pavel Roskin <proski@gnu.org>
2036 * configure.ac: Remove host_m32. Issues with 64-bit utilities
2037 have long been resolved.
2039 2009-06-11 Colin Watson <cjwatson@ubuntu.com>
2041 * util/grub.d/10_linux.in: Capitalise "Linux".
2043 * util/grub-pe2elf.c (usage): Fix references to grub-editenv.
2045 2009-06-11 Pavel Roskin <proski@gnu.org>
2047 * kern/efi/efi.c (grub_exit): Add infinite loop at the end to
2048 fix a gcc warning and ensure that the function won't ever exit.
2050 * kern/i386/ieee1275/init.c: Add missing prototype for
2053 * loader/ieee1275/multiboot2.c [__i386__]: Include
2054 grub/cpu/multiboot.h.
2056 * term/i386/pc/serial.c (serial_translate_key_sequence): Avoid
2057 casts to short - they are not portable and cause warnings. Fix
2058 use of uninitialized values in input_buf. Use ARRAY_SIZE.
2060 2009-06-11 Vladimir Serbinenko <phcoder@gmail.com>
2064 * commands/i386/pc/drivemap.c (grub_get_root_biosnumber_drivemap):
2066 (grub_get_root_biosnumber_saved): new variable
2067 (GRUB_MOD_INIT): register grub_get_root_biosnumber_drivemap
2068 (GRUB_MOD_FINI): unregister grub_get_root_biosnumber_drivemap
2069 * commands/i386/pc/drivemap_int13h.S (grub_drivemap_handler): restore
2070 %dx after the call if necessary
2071 * conf/common.rmk (pkglib_MODULES): remove boot.mod
2072 (boot_mod_SOURCES): remove
2073 (boot_mod_CFLAGS): remove
2074 (boot_mod_LDFLAGS): remove
2075 * conf/i386-coreboot.rmk (pkglib_MODULES): add boot.mod
2076 (boot_mod_SOURCES): new variable
2077 (boot_mod_CFLAGS): likewise
2078 (boot_mod_LDFLAGS): likewise
2079 * conf/i386-efi.rmk: likewise
2080 * conf/i386-ieee1275.rmk: likewise
2081 * conf/i386-pc.rmk: likewise
2082 * conf/powerpc-ieee1275.rmk: likewise
2083 * conf/sparc64-ieee1275.rmk: likewise
2084 * conf/x86_64-efi.rmk: likewise
2085 * include/grub/i386/pc/biosnum.h: new file
2086 * lib/i386/pc/biosnum.c: likewise
2087 * loader/i386/bsd.c (grub_bsd_get_device): use grub_get_root_biosnumber
2088 * loader/i386/multiboot.c (grub_multiboot_get_bootdev): likewise
2089 * loader/i386/pc/chainloader.c (grub_chainloader_cmd): likewise
2091 2009-06-10 Pavel Roskin <proski@gnu.org>
2093 * io/gzio.c (test_header): Don't reuse one buffer for all data.
2094 Use separate variables. Read only the file size at the end, but
2095 not the checksum that we don't use.
2097 * kern/file.c (grub_file_read): Use void pointer for the buffer.
2100 * kern/ieee1275/openfw.c: Remove libc includes.
2101 * kern/ieee1275/cmain.c: Likewise.
2102 * include/grub/ieee1275/ieee1275.h: Likewise.
2104 * kern/i386/coreboot/init.c: Include grub/cpu/tsc.h to fix
2107 2009-06-10 Felix Zielcke <fzielcke@z-51.de>
2109 * Makefile.in: Remove all trailing whitespace.
2110 * conf/i386-pc.rmk: Likewise.
2111 * conf/powerpc-ieee1275.rmk: Likewise.
2112 * conf/sparc64-ieee1275.rmk: Likewise.
2113 * docs/grub.texi: Likewise.
2114 * docs/texinfo.tex: Likewise.
2115 * disk/fs_uuid.c: Likewise.
2116 * disk/lvm.c: Likewise.
2117 * disk/scsi.c: Likewise.
2118 * disk/ata.c: Likewise.
2119 * disk/ieee1275/ofdisk.c: Likewise.
2120 * disk/i386/pc/biosdisk.c: Likewise.
2121 * disk/host.c: Likewise.
2122 * disk/raid.c: Likewise.
2123 * disk/efi/efidisk.c: Likewise.
2124 * disk/usbms.c: Likewise.
2125 * disk/memdisk.c: Likewise.
2126 * disk/loopback.c: Likewise.
2127 * kern/powerpc/dl.c: Likewise.
2128 * kern/device.c: Likewise.
2129 * kern/dl.c: Likewise.
2130 * kern/sparc64/dl.c: Likewise.
2131 * kern/ieee1275/ieee1275.c: Likewise.
2132 * kern/term.c: Likewise.
2133 * kern/fs.c: Likewise.
2134 * kern/i386/dl.c: Likewise.
2135 * kern/i386/pc/startup.S: Likewise.
2136 * kern/i386/pc/init.c: Likewise.
2137 * kern/i386/pc/mmap.c: Likewise.
2138 * kern/i386/pc/lzo1x.S: Likewise.
2139 * kern/i386/ieee1275/init.c: Likewise.
2140 * kern/i386/realmode.S: Likewise.
2141 * kern/i386/tsc.c: Likewise.
2142 * kern/partition.c: Likewise.
2143 * kern/corecmd.c: Likewise.
2144 * kern/file.c: Likewise.
2145 * kern/efi/efi.c: Likewise.
2146 * kern/efi/init.c: Likewise.
2147 * kern/efi/mm.c: Likewise.
2148 * kern/main.c: Likewise.
2149 * kern/err.c: Likewise.
2150 * kern/env.c: Likewise.
2151 * kern/disk.c: Likewise.
2152 * kern/generic/millisleep.c: Likewise.
2153 * kern/generic/rtc_get_time_ms.c: Likewise.
2154 * kern/misc.c: Likewise.
2155 * kern/parser.c: Likewise.
2156 * genmk.rb: Likewise.
2157 * configure.ac: Likewise.
2158 * boot/i386/pc/diskboot.S: Likewise.
2159 * boot/i386/pc/pxeboot.S: Likewise.
2160 * boot/i386/pc/boot.S: Likewise.
2161 * boot/i386/pc/lnxboot.S: Likewise.
2162 * boot/i386/pc/cdboot.S: Likewise.
2163 * parttool/pcpart.c: Likewise.
2164 * video/readers/tga.c: Likewise.
2165 * video/video.c: Likewise.
2166 * video/bitmap.c: Likewise.
2167 * lib/envblk.c: Likewise.
2168 * lib/i386/setjmp.S: Likewise.
2169 * fs/xfs.c: Likewise.
2170 * fs/afs.c: Likewise.
2171 * fs/fat.c: Likewise.
2172 * fs/ntfs.c: Likewise.
2173 * fs/udf.c: Likewise.
2174 * fs/affs.c: Likewise.
2175 * fs/iso9660.c: Likewise.
2176 * fs/hfs.c: Likewise.
2177 * fs/fshelp.c: Likewise.
2178 * fs/ext2.c: Likewise.
2179 * fs/jfs.c: Likewise.
2180 * fs/reiserfs.c: Likewise.
2181 * fs/hfsplus.c: Likewise.
2182 * fs/minix.c: Likewise.
2183 * fs/cpio.c: Likewise.
2184 * fs/sfs.c: Likewise.
2185 * fs/ufs.c: Likewise.
2186 * efiemu/prepare.c: Likewise.
2187 * efiemu/loadcore_common.c: Likewise.
2188 * efiemu/runtime/efiemu.sh: Likewise.
2189 * efiemu/runtime/efiemu.S: Likewise.
2190 * efiemu/runtime/efiemu.c: Likewise.
2191 * efiemu/pnvram.c: Likewise.
2192 * efiemu/main.c: Likewise.
2193 * efiemu/i386/pc/cfgtables.c: Likewise.
2194 * efiemu/i386/loadcore64.c: Likewise.
2195 * efiemu/i386/loadcore32.c: Likewise.
2196 * efiemu/loadcore.c: Likewise.
2197 * efiemu/symbols.c: Likewise.
2198 * efiemu/mm.c: Likewise.
2199 * include/grub/autoefi.h: Likewise.
2200 * include/grub/datetime.h: Likewise.
2201 * include/grub/term.h: Likewise.
2202 * include/grub/hfs.h: Likewise.
2203 * include/grub/lvm.h: Likewise.
2204 * include/grub/i386/tsc.h: Likewise.
2205 * include/grub/i386/linux.h: Likewise.
2206 * include/grub/i386/xnu.h: Likewise.
2207 * include/grub/i386/efiemu.h: Likewise.
2208 * include/grub/i386/pc/biosdisk.h: Likewise.
2209 * include/grub/i386/pc/memory.h: Likewise.
2210 * include/grub/i386/pc/vbe.h: Likewise.
2211 * include/grub/parttool.h: Likewise.
2212 * include/grub/video.h: Likewise.
2213 * include/grub/memory.h: Likewise.
2214 * include/grub/fs.h: Likewise.
2215 * include/grub/partition.h: Likewise.
2216 * include/grub/xnu.h: Likewise.
2217 * include/grub/efi/api.h: Likewise.
2218 * include/grub/efi/pe32.h: Likewise.
2219 * include/grub/efi/memory.h: Likewise.
2220 * include/grub/multiboot.h: Likewise.
2221 * include/grub/usbdesc.h: Likewise.
2222 * include/grub/multiboot2.h: Likewise.
2223 * include/grub/acpi.h: Likewise.
2224 * include/grub/efiemu/efiemu.h: Likewise.
2225 * include/grub/disk.h: Likewise.
2226 * include/grub/ieee1275/ieee1275.h: Likewise.
2227 * include/grub/net.h: Likewise.
2228 * include/grub/machoload.h: Likewise.
2229 * include/grub/macho.h: Likewise.
2230 * include/multiboot.h: Likewise.
2231 * genmoddep.awk: Likewise.
2232 * normal/main.c: Likewise.
2233 * normal/menu_entry.c: Likewise.
2234 * normal/menu_viewer.c: Likewise.
2235 * normal/completion.c: Likewise.
2236 * normal/cmdline.c: Likewise.
2237 * normal/misc.c: Likewise.
2238 * normal/datetime.c: Likewise.
2239 * bus/usb/usbtrans.c: Likewise.
2240 * bus/usb/ohci.c: Likewise.
2241 * bus/usb/uhci.c: Likewise.
2242 * bus/usb/usb.c: Likewise.
2243 * mmap/efi/mmap.c: Likewise.
2244 * mmap/i386/pc/mmap_helper.S: Likewise.
2245 * mmap/i386/pc/mmap.c: Likewise.
2246 * mmap/i386/mmap.c: Likewise.
2247 * mmap/i386/uppermem.c: Likewise.
2248 * mmap/mmap.c: Likewise.
2249 * commands/acpi.c: Likewise.
2250 * commands/echo.c: Likewise.
2251 * commands/blocklist.c: Likewise.
2252 * commands/loadenv.c: Likewise.
2253 * commands/usbtest.c: Likewise.
2254 * commands/boot.c: Likewise.
2255 * commands/parttool.c: Likewise.
2256 * commands/search.c: Likewise.
2257 * commands/cat.c: Likewise.
2258 * commands/i386/pc/play.c: Likewise.
2259 * commands/i386/pc/drivemap.c: Likewise.
2260 * commands/i386/pc/vbeinfo.c: Likewise.
2261 * commands/i386/pc/acpi.c: Likewise.
2262 * commands/i386/pc/vbetest.c: Likewise.
2263 * commands/ls.c: Likewise.
2264 * commands/cmp.c: Likewise.
2265 * commands/test.c: Likewise.
2266 * commands/efi/acpi.c: Likewise.
2267 * commands/gptsync.c: Likewise.
2268 * commands/help.c: Likewise.
2269 * partmap/amiga.c: Likewise.
2270 * partmap/apple.c: Likewise.
2271 * partmap/acorn.c: Likewise.
2272 * partmap/pc.c: Likewise.
2273 * partmap/sun.c: Likewise.
2274 * partmap/gpt.c: Likewise.
2275 * script/sh/lexer.c: Likewise.
2276 * script/sh/function.c: Likewise.
2277 * font/font.c: Likewise.
2278 * font/font_cmd.c: Likewise.
2279 * loader/powerpc/ieee1275/linux.c: Likewise.
2280 * loader/efi/chainloader.c: Likewise.
2281 * loader/multiboot_loader.c: Likewise.
2282 * loader/macho.c: Likewise.
2283 * loader/i386/multiboot.c: Likewise.
2284 * loader/i386/linux.c: Likewise.
2285 * loader/i386/pc/linux.c: Likewise.
2286 * loader/i386/pc/multiboot2.c: Likewise.
2287 * loader/i386/pc/chainloader.c: Likewise.
2288 * loader/i386/pc/xnu.c: Likewise.
2289 * loader/i386/bsd_trampoline.S: Likewise.
2290 * loader/i386/efi/linux.c: Likewise.
2291 * loader/i386/multiboot_elfxx.c: Likewise.
2292 * loader/i386/bsd_helper.S: Likewise.
2293 * loader/i386/bsd.c: Likewise.
2294 * loader/i386/linux_trampoline.S: Likewise.
2295 * loader/i386/xnu_helper.S: Likewise.
2296 * loader/i386/xnu.c: Likewise.
2297 * loader/i386/bsd_pagetable.c: Likewise.
2298 * loader/i386/multiboot_helper.S: Likewise.
2299 * loader/xnu.c: Likewise.
2300 * loader/xnu_resume.c: Likewise.
2301 * io/gzio.c: Likewise.
2302 * term/efi/console.c: Likewise.
2303 * term/terminfo.c: Likewise.
2304 * term/ieee1275/ofconsole.c: Likewise.
2305 * term/i386/pc/serial.c: Likewise.
2306 * term/i386/pc/vesafb.c: Likewise.
2307 * term/i386/pc/vga.c: Likewise.
2308 * term/usb_keyboard.c: Likewise.
2309 * term/gfxterm.c: Likewise.
2310 * aclocal.m4: Likewise.
2311 * util/lvm.c: Likewise.
2312 * util/grub.d/30_os-prober.in: Likewise.
2313 * util/grub.d/10_hurd.in: Likewise.
2314 * util/console.c: Likewise.
2315 * util/grub-macho2img.c: Likewise.
2316 * util/grub-probe.c: Likewise.
2317 * util/hostfs.c: Likewise.
2318 * util/i386/pc/grub-mkimage.c: Likewise.
2319 * util/i386/pc/grub-setup.c: Likewise.
2320 * util/i386/efi/grub-mkimage.c: Likewise.
2321 * util/grub-mkconfig.in: Likewise.
2322 * util/raid.c: Likewise.
2323 * util/resolve.c: Likewise.
2324 * util/grub-mkdevicemap.c: Likewise.
2325 * util/grub-emu.c: Likewise.
2326 * util/getroot.c: Likewise.
2327 * util/hostdisk.c: Likewise.
2328 * util/usb.c: Likewise.
2329 * util/grub-editenv.c: Likewise.
2330 * util/misc.c: Likewise.
2332 2009-06-10 Felix Zielcke <fzielcke@z-51.de>
2334 * gendistlist.sh (EXTRA_DISTFILES): Add `genhandlerlist.sh' and
2335 `genparttoollist.sh'.
2336 (DISTDIRS): Add `efiemu', `mmap', `parttool' and `script'.
2337 Add `*.sh' to the list find searches for and change `mdate.sh'
2340 2009-06-10 Pavel Roskin <proski@gnu.org>
2342 * include/grub/multiboot2.h: Provide compatibility defines for
2344 * include/multiboot2.h: Include stdint.h only if needed, using
2346 * loader/i386/pc/multiboot2.c: Include multiboot2.h after
2348 * loader/ieee1275/multiboot2.c: Likewise.
2349 * loader/multiboot2.c: Likewise.
2350 * loader/multiboot_loader.c: Likewise.
2352 * configure.ac: Use -nostdlib when probing for the target. It
2353 should not be required to have libc for the target.
2355 * configure.ac: Remove checks for __bswapsi2 and __bswapdi2,
2356 they fail without libc headers for the target.
2357 * include/grub/powerpc/libgcc.h: Use weak attribute for all
2359 * include/grub/sparc64/libgcc.h: Likewise. Don't use
2360 preprocessor conditionals.
2362 * conf/common.rmk: Compile tar.mod from tar.c, not cpio.c. The
2363 build system doesn't need to be aware of the tar.c internals.
2365 2009-06-09 Michel Hermier <michel.hermier@gmail.com>
2367 * fs/i386/pc/pxe.c (grub_pxefs_read): Fix returned values.
2369 2009-06-09 Robert Millan <rmh.grub@aybabtu.com>
2371 * util/deviceiter.c (grub_util_iterate_devices): Increase number of
2372 disk limit to 26 for IDE, Virtio, Xen and SCSI.
2374 2009-06-09 Felix Zielcke <fzielcke@z-51.de>
2376 * util/i386/pc/grub-install.in: Change the error message if UUIDs
2377 aren't available if ata.mod gets used.
2379 2009-06-09 Oliver Henshaw <oliver.henshaw@gmail.com>
2381 * bus/usb/ohci.c (grub_ohci_pci_iter): Link struct only after
2382 initialising controller.
2383 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
2385 2009-06-08 Felix Zielcke <fzielcke@z-51.de>
2387 * util/i386/pc/grub-install.in: Add a parameter --disk-module
2388 to choose between ata and biosdisk module on i386-pc.
2390 2009-06-08 Oliver Henshaw <oliver.henshaw@gmail.com>
2392 * bus/usb/ohci.c (grub_ohci_pci_iter): Define the Class,
2393 Subclass and Programming Interface fields in terms of the 3 byte
2394 Class Code register.
2395 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
2397 * bus/usb/ohci.c (grub_ohci_pci_iter): Check that programming
2398 interface is OHCI. Add grub_dprintf for symmetry with
2400 * bus/usb/uhci.c (grub_uhci_pci_iter): Check that programming
2401 interface is UHCI. Add interf variable for programming
2402 interface. Print interface with class/subclass.
2404 * bus/usb/ohci.c: Set interf with correct field.
2406 * bus/usb/uhci.c: Remove unneeded doubled lines.
2407 * bus/usb/ohci.c: Likewise. Change interf to grub_uint32_t.
2408 Remove whitespace inside comment.
2410 2009-06-08 Robert Millan <rmh.grub@aybabtu.com>
2412 * loader/i386/linux.c (grub_cmd_linux): When processing `vga=', use
2413 as fallback an equivalent option without depth.
2415 2009-06-08 Vladimir Serbinenko <phcoder@gmail.com>
2417 Not fail if unable to retrieve C/H/S on LBA disks
2419 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): behave gracefully
2420 if unable to retrieve C/H/S on LBA disks
2422 2009-06-08 Pavel Roskin <proski@gnu.org>
2424 * fs/hfs.c (grub_hfs_find_dir): Use union to avoid a warning
2427 2009-06-08 Felix Zielcke <fzielcke@z-51.de>
2429 * Makefile.in (uninstall): Remove all $lib_DATA files.
2431 2009-06-08 Vladimir Serbinenko <phcoder@gmail.com>
2433 Bugfix: install on partitionless device
2435 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): check if os_dev
2438 2009-06-08 Felix Zielcke <fzielcke@z-51.de>
2440 * Makefile.in (uninstall): Remove all $include_DATA files.
2442 2009-06-08 Felix Zielcke <fzielcke@z-51.de>
2444 * commands/true.c: New file. Implement the true and false commands.
2445 * conf/common.rmk.c (pkglib_MODULES): Add `true.mod'.
2446 (true_mod_SOURCES): New variable.
2447 (true_mod_CFLAGS): Likewise.
2448 (true_mod_LDFLAGS): Likewise.
2450 2009-06-05 Colin D Bennett <colin@gibibit.com>
2452 Optimized font character lookup using binary search instead of linear
2453 search. Fonts now are required to have the character index ordered by
2456 * font/font.c (load_font_index): Verify that fonts have ordered
2458 (find_glyph): Use binary search instead of linear search to find a
2459 character in a font.
2461 2009-06-05 Michael Scherer <misc@mandriva.org>
2463 * fs/hfsplus.c (grub_hfsplus_mount): Determine if the filesystem
2464 uses case sensitive btree.
2465 (grub_hfsplus_iterate_dir): Use GRUB_FSHELP_CASE_INSENSITIVE
2466 only for case insensitive filesystems.
2468 2009-06-05 Vladimir Serbinenko <phcoder@gmail.com>
2470 * conf/i386-pc.rmk (efiemu_mod_CFLAGS): remove -Werror -Wall
2471 * conf/common.rmk (search_mod_CFLAGS): likewise
2473 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2475 * kern/i386/pc/startup.S [APPLE_CC]: block of nops to
2476 compensate a compiler bug
2478 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2480 * include/grub/term.h (GRUB_TERM_BACKSPACE): explicitly define as 8
2483 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2485 Definitions for creating asm symbols with Apple's CC
2487 * include/grub/symbol.h [APPLE_CC] (FUNCTION): new macro
2488 [APPLE_CC] (VARIABLE): likewise
2490 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2492 Disable lnxboot.img when compiled
2495 * conf/i386-pc.rmk (pkglib_IMAGES): remove lnxboot.img
2496 pkglib_IMAGES [! TARGET_APPLE_CC] (pkglib_IMAGES): add lnxboot.img
2497 * boot/i386/pc/lnxboot.S [APPLE_CC]: define an #error
2498 [! APPLE_CC] (CODE_LENG): skip
2499 [! APPLE_CC] (setup_sects): likewise
2500 [! APPLE_CC]: skip filling
2502 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2504 Address in trampolines based on 32-bit registers when compiled
2507 * loader/i386/xnu_helper.S [APPLE_CC]: use 32-bit registers
2509 * loader/i386/linux_trampoline.S [APPLE_CC]: likewise
2511 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2513 Avoid aliases when compiling with Apple's CC for PCBIOS machine
2515 * kern/misc.c [APPLE_CC] (memcpy): new function
2516 [APPLE_CC] (memmove): likewise
2517 [APPLE_CC && !GRUB_UTIL] (grub_err_printf): likewise
2518 (memcpy): define alias conditionally on !APPLE_CC
2521 * include/grub/misc.h (memove): don't define when both GRUB_UTIL and
2522 APPLE_CC are defined
2523 * include/grub/list.h [APPLE_CC] (grub_assert_fail): new function
2524 (grub_assert_fail): make prototype conditional
2526 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2528 Use grub-macho2img when compiling with Apple's CC for PCBIOS machine
2530 * conf/common.rmk (bin_UTILITIES): add (on false on condition)
2532 (CLEANFILES): add grub-macho2img
2533 (grub_macho2img_SOURCES): new variable
2534 * kern/i386/pc/startup.S (bss_start): new variable
2536 * genmk.rb: use grub-macho2img for *.img when compiled with Apple's CC
2537 * util/grub-macho2img.c: new file
2539 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2541 Use objconv when compiling with Apple's CC
2543 * conf/i386-pc.rmk (efiemu32.o): use OBJCONV if defined
2544 (efiemu64.o): likewise
2545 (efiemu64_c.o): omit -mcmodel=large and add -DAPPLE_CC=1
2546 when compiling with Apple's CC
2547 (efiemu64_s.o): likewise
2548 * configure.ac: check for objconv when compiling with Apple's CC
2549 * genmk.rb: use objconv for modules when compiled with Apple's CC
2551 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2553 Define segment as well as section when compiling with
2556 * efiemu/runtime/efiemu.c (PHYSICAL_ATTRIBUTE): new definition
2557 (efiemu_set_virtual_address_map): declare with PHYSICAL_ATTRIBUTE
2558 (efiemu_convert_pointer): likewise
2559 (efiemu_set_virtual_address_map): likewise
2560 (efiemu_convert_pointer): likewise
2561 (efiemu_getcrc32): likewise
2562 (init_crc32_table): likewise
2564 * include/grub/dl.h (GRUB_MOD_NAME): define segment with Apple's CC
2565 (GRUB_MOD_DEP): likewise
2567 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2569 Allow a compilation without -mcmodel=large
2571 * kern/efi/mm.c (grub_efi_allocate_pages): don't allocate >4GiB
2572 when compiled without -mcmodel=large
2573 (filter_memory_map): remove memory post 4 GiB when compiled
2574 without -mcmodel=large
2575 * configure.ac: fail gracefully and add -DMCMODEL_SMALL=1 to
2576 TARGET_CFLAGS when -mcmodel=large isn't supported
2578 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2580 Remove nested functions in efiemu core
2582 * efiemu/runtime/efiemu.c (reflect): make static instead of nested
2584 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2586 Avoid clobbering %ebx/%rbx in inline assembly with Apple's CC
2588 * efiemu/runtime/efiemu.c (write_cmos): use %cl instead of %bl as
2590 * include/grub/i386/tsc.h (grub_get_tsc): restore %rbx/%ebx when
2592 (grub_cpu_is_tsc_supported): likewise
2593 * loader/i386/xnu.c (guessfsb): restore %rbx/%ebx in inline assembly
2595 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2597 Absolute addressing through constant with Apple's cc
2599 * kern/i386/pc/startup.S: Define necessary constants
2600 and address through it when using ABS with Apple's CC
2601 * boot/i386/pc/diskboot.S: likewise
2602 * boot/i386/pc/boot.S: likewise
2603 * boot/i386/pc/lnxboot.S: likewise
2604 * boot/i386/pc/cdboot.S: likewise
2605 * mmap/i386/pc/mmap_helper.S: likewise
2606 * commands/i386/pc/drivemap_int13h.S: likewise
2608 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2610 Check if compiler is apple cc
2612 * Makefile.in (ASFLAGS): new variable
2613 (TARGET_ASFLAGS): likewise
2614 (TARGET_MODULE_FORMAT): likewise
2615 (TARGET_APPLE_CC): likewise
2617 (TARGET_IMG_CFLAGS): likewise
2618 (TARGET_CPPFLAGS): add includedir
2619 * configure.ac: call grub_apple_cc and grub_apple_target_cc
2620 (TARGET_IMG_LDFLAGS): Add -Wl,-Ttext,. All users updated
2621 Check for linker script only if compiler isn't Apple's CC
2622 (TARGET_MODULE_FORMAT): set
2623 (TARGET_APPLE_CC): likewise
2624 (TARGET_ASFLAGS): likewise
2626 Check for objcopy only if compiler isn't Apple's CC
2627 Check for BSS symbol only if compiler isn't Apple's CC
2628 * genmk.rb: adapt nm options if we use Apple's utils
2629 * aclocal.m4 (grub_apple_cc): new test
2630 (grub_apple_target_cc): likewise
2632 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2634 Simplify sed expressions and improve awk
2636 * Makefile.in (install-local): simplify sed expression
2637 * gencmdlist.sh: likewise
2638 * genmoddep.awk: avoid adding module as a dependency of itself
2640 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2642 Add missing start symbols
2644 * boot/i386/pc/boot.S: add start
2645 * boot/i386/pc/pxeboot.S: likewise
2647 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2649 Fix wrong assumptions with grub-mkimage on EFI
2651 * i386/efi/grub-mkimage.c (read_kernel_module): don't write prefix here
2652 (relocate_addresses): consider both r_addend and value at offset
2653 (make_mods_section): zerofill modinfo and header
2654 (convert_elf): write prefix here
2656 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2658 Use .asciz instead of .string
2660 * i386/pc/diskboot.S: use .asciz instead of .string
2661 * i386/pc/boot.S: likewise
2662 * include/grub/dl.h (GRUB_MOD_DEP): likewise
2663 (GRUB_MOD_NAME): likewise
2665 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2669 * commands/videotest.c (grub_cmd_videotest): use grub_video_set_mode
2670 * include/grub/video.h (GRUB_VIDEO_MODE_TYPE_PURE_TEXT): new definition
2671 (grub_video_setup): remove
2672 (grub_video_set_mode): new prototype
2673 * loader/i386/linux.c (DEFAULT_VIDEO_MODE): new definition
2675 (linux_vesafb_res): compile only on PCBIOS
2676 (grub_linux_boot): support gfxpayload
2677 * loader/i386/pc/xnu.c (video_hook): new function
2678 (grub_xnu_set_video): support gfxpayload
2679 * term/gfxterm.c (DEFAULT_VIDEO_WIDTH): removed
2680 (DEFAULT_VIDEO_HEIGHT): likewise
2681 (DEFAULT_VIDEO_FLAGS): likewise
2682 (DEFAULT_VIDEO_MODE): new definition
2683 (video_hook): new function
2684 (grub_gfxterm_init): use grub_video_set_mode
2685 * util/grub.d/30_os-prober.in: remove explicit modesetting before
2687 * video/video.c (grub_video_setup): removed
2688 (grub_video_set_mode): new function based on grub_gfxterm_init and
2691 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2693 Avoid calling biosdisk in drivemap
2695 * commands/i386/pc/drivemap.c (parse_biosdisk): remove
2696 (revparse_biosdisk): likewise
2697 (list_mappings): derive name from id directly
2698 (grub_cmd_drivemap): use tryparse_diskstring
2700 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
2704 * include/grub/script_sh.h (grub_script_cmdline): remove cmdline
2705 (grub_lexer_param): add tokenonhold
2706 (grub_script_create_cmdline): remove cmdline. All callers updated
2707 (grub_script_function_create): make functionname
2708 grub_script_arg. All callers updated
2709 (grub_script_execute_argument_to_string): new prototype
2710 * kern/parser.c (state_transitions): reorder
2711 (grub_parser_cmdline_state): fix a bug and make more compact
2712 * script/sh/execute.c (grub_script_execute_argument_to_string):
2714 (grub_script_execute_cmdline): use new format
2715 * script/sh/function.c (grub_script_function_create): make functionname
2716 grub_script_arg. All callers updated
2717 * script/sh/lexer.c (grub_script_lexer_init): initialize tokenonhold
2718 (grub_script_yylex): remove
2719 (grub_script_yylex2): renamed to ...
2720 (grub_script_yylex): ...renamed
2721 parse the expressions like a${b}c
2722 * script/sh/parser.y (GRUB_PARSER_TOKEN_ARG): new typed terminal
2723 (GRUB_PARSER_TOKEN_VAR): remove
2724 (GRUB_PARSER_TOKEN_NAME): likewise
2725 ("if"): declare as typeless
2727 ("function"): likewise
2732 (argument): likewise
2733 (script): accept empty scripts and make exit on error
2734 (arguments): use GRUB_PARSER_TOKEN_ARG
2735 (function): likewise
2736 (command): move error handling to script
2737 (menuentry): move grub_script_lexer_ref before
2738 * script/sh/script.c (grub_script_create_cmdline): remove cmdline
2739 argument. All callers updated
2741 2009-06-04 Robert Millan <rmh.grub@aybabtu.com>
2743 Prevent GRUB from probing floppies during boot.
2745 * conf/common.rmk (search_mod_CFLAGS): Use `-Werror -Wall'.
2746 * commands/search.c (options): Add --no-floppy.
2747 (search_fs, search_file, grub_cmd_search): Support --no-floppy.
2748 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Use
2749 --no-floppy when searching for UUIDs.
2751 2009-06-04 Robert Millan <rmh.grub@aybabtu.com>
2753 Simplify the code duplication in commands/search.c.
2755 * commands/search.c (search_label, search_fs_uuid): Merge into ...
2756 (search_fs): ... this. Update all users.
2758 2009-06-03 Felix Zielcke <fzielcke@z-51.de>
2760 * util/grub-mkconfig.in (update_grub_dir): Rename to grub_mkconfig_dir.
2762 2009-05-28 Pavel Roskin <proski@gnu.org>
2764 * Makefile.in: Don't use "cp -d", it doesn't work on FreeBSD.
2765 Remove the original symlink explicitly.
2767 * fs/hfs.c (grub_hfs_find_dir): Skip sequences of slashes, not
2768 just one slash. That's how grub_fshelp_find_file() does it.
2770 2009-05-26 Pavel Roskin <proski@gnu.org>
2772 * genmk.rb: Avoid shadowing variable `s', rename the outer `s'
2775 * util/getroot.c (grub_util_get_dev_abstraction): Mark os_dev as
2778 2009-05-25 Christian Franke <franke@computer.org>
2780 * disk/ata.c (grub_ata_wait_not_busy): Add debug output of status
2782 (grub_atapi_identify): Add wait after drive select.
2783 (grub_ata_identify): Do more strict status register check before
2784 calling grub_atapi_identify (). Suppress error message if status
2785 register is 0x00 after command failure. Add status register
2786 check after PIO read to avoid bogus identify due to stuck DRQ.
2787 Thanks to Pavel Roskin for testing.
2788 (grub_device_initialize): Remove unsafe status register check.
2789 Thanks to 'phcoder' for problem report and patch.
2790 Prevent sign extension in debug message.
2792 2009-05-23 Colin D Bennett <colin@gibibit.com>
2794 Cleaned up `include/grub/normal.h'. Grouped prototypes by
2795 definition file, and functions defined in `normal/menu.c' have had
2796 their prototypes moved to `include/grub/menu.h' for consistency.
2798 * include/grub/menu.h (grub_menu_execute_callback): Added; moved
2800 (grub_menu_get_entry): Likewise.
2801 (grub_menu_get_timeout): Likewise.
2802 (grub_menu_set_timeout): Likewise.
2803 (grub_menu_execute_entry): Likewise.
2804 (grub_menu_execute_with_fallback): Likewise.
2805 (grub_menu_entry_run): Likewise.
2807 * include/grub/normal.h: Re-ordered and grouped function
2808 prototypes by file that the function is defined in.
2809 (grub_menu_execute_callback): Removed; moved to menu.h.
2810 (grub_menu_get_entry): Likewise.
2811 (grub_menu_get_timeout): Likewise.
2812 (grub_menu_set_timeout): Likewise.
2813 (grub_menu_execute_entry): Likewise.
2814 (grub_menu_execute_with_fallback): Likewise.
2815 (grub_menu_entry_run): Likewise.
2816 (grub_menu_addentry): Renamed from this ...
2817 (grub_normal_add_menu_entry): ... to this.
2819 * normal/main.c (grub_menu_addentry): Renamed from this ...
2820 (grub_normal_add_menu_entry): ... to this.
2822 * script/sh/execute.c (grub_script_execute_menuentry): Update
2823 reference to renamed grub_menu_addentry function.
2825 2009-05-23 Felix Zielcke <fzielcke@z-51.de>
2827 * commands/i386/pc/drivemap.c (MODNAME): Remove. Update all users.
2829 2009-05-22 Pavel Roskin <proski@gnu.org>
2831 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Remove.
2832 * configure.ac: Don't call grub_I386_CHECK_REGPARM_BUG. Define
2833 NESTED_FUNC_ATTR using AH_BOTTOM. Use regparm(1) only when
2834 compiling for the i386 targets, but not for the utilities.
2836 * include/grub/i386/pc/kernel.h (grub_boot_drive): Change type
2838 (grub_root_drive): Likewise.
2839 * kern/i386/pc/startup.S (grub_boot_drive): Change size to byte,
2841 (grub_root_drive): Change size to byte.
2842 (grub_start_addr): Remove.
2843 (grub_end_addr): Likewise.
2844 (grub_apm_bios_info): Likewise.
2846 2009-05-21 Felix Zielcke <fzielcke@z-51.de>
2848 * normal/i386: Remove.
2849 * normal/powerpc: Likewise.
2850 * normal/sparc64: Likewise.
2851 * normal/x86_64: Likewise.
2853 2009-05-19 Vladimir Serbinenko <phcoder@gmail.com>
2855 * conf/x86_64-efi.rmk (linux_mod_ASFLAGS): Add missing variable
2856 * loader/i386/linux_trampoline.S: Fix indentation
2857 * loader/i386/xnu_helper.S: Likewise
2859 2009-05-18 Colin D Bennett <colin@gibibit.com>
2861 Display error messages when parsing a Lua statement fails.
2862 Previously, executing a syntactically invalid statement like
2863 ")foo" or "bar;" would silently fail.
2865 * script/lua/grub_main.c (handle_lua_error): New function.
2866 (grub_lua_parse_line): Improved reporting of Lua parser and
2869 2009-05-17 Vladimir Serbinenko <phcoder@gmail.com>
2871 Remove -Werror which causes build to fail on some systems
2873 * conf/i386-pc.rmk (xnu_mod_CFLAGS): Remove -Werror -Wall
2874 * conf/i386-efi.rmk (xnu_mod_CFLAGS): Likewise
2875 * conf/x86_64-efi.rmk (xnu_mod_CFLAGS): Likewise
2877 2009-05-17 Vladimir Serbinenko <phcoder@gmail.com>
2879 trampoline for linux on 64-bit platform
2881 * conf/x86_64-efi.rmk (linux_mod_SOURCES): added
2882 loader/i386/efi/linux_trampoline.S
2883 * include/grub/x86_64/efi/loader.h (grub_linux_real_boot): removed
2885 * kern/x86_64/efi/startup.S (grub_linux_real_boot): moved from
2887 * loader/i386/linux_trampoline.S: moved here
2888 * loader/i386/efi/linux.c (allocate_pages): reserve space for
2890 (jumpvector): removed
2891 (grub_linux_trampoline_start): new declaration
2892 (grub_linux_trampoline_end): likewise
2893 (grub_linux_boot): use trampoline when on 64-bit platform
2894 * loader/i386/linux.c: likewise
2896 2009-05-16 Pavel Roskin <proski@gnu.org>
2898 * script/lua/grub_lib.c (grub_lua_getenv): Make name and value
2899 const to avoid a warning.
2900 (grub_lua_setenv): Likewise.
2901 * script/lua/grub_main.c (grub_lua_parse_line): Use size_t for
2902 lmsg to fix a warning.
2904 2009-05-16 Felix Zielcke <fzielcke@z-51.de>
2906 * conf/i386.rmk (setjmp_mod_CFLAGS): Rename to ...
2907 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
2908 * conf/x86_64-efi.rmk (setjmp_mod_CFLAGS): Rename to ...
2909 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
2910 * conf/powerpc-ieee1275.rmk (setjmp_mod_CFLAGS): Rename to ...
2911 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
2912 * conf/sparc64-ieee1275.rmk (setjmp_mod_CFLAGS): Rename to ...
2913 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
2915 2009-05-16 Felix Zielcke <fzielcke@z-51.de>
2917 * util/grub-mkconfig.in: Export GRUB_TERMINAL_INPUT.
2919 2009-05-16 Bean <bean123ch@gmail.com>
2921 * conf/common.rmk (pkglib_MODULES): Add lua.mod.
2922 (lua_mod_SOURCES): New variable.
2923 (lua_mod_CFLAGS): Likewise.
2924 (lua_mod_LDFLAGS): Likewise.
2926 * conf/i386.rmk (pkglib_MODULES): Add setjmp.mod.
2927 (setjmp_mod_SOURCES): New variable.
2928 (setjmp_mod_CFLAGS): Likewise.
2929 (setjmp_LDFLAGS): Likewise.
2931 * conf/x86_64-efi.rmk (pkglib_MODULES): Add setjmp.mod.
2932 (setjmp_mod_SOURCES): New variable.
2933 (setjmp_mod_CFLAGS): Likewise.
2934 (setjmp_LDFLAGS): Likewise.
2936 * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add setjmp.mod.
2937 (setjmp_mod_SOURCES): New variable.
2938 (setjmp_mod_CFLAGS): Likewise.
2939 (setjmp_LDFLAGS): Likewise.
2941 * conf/sparc64-ieee1275.rmk (pkglib_MODULES): Add setjmp.mod.
2942 (setjmp_mod_SOURCES): New variable.
2943 (setjmp_mod_CFLAGS): Likewise.
2944 (setjmp_LDFLAGS): Likewise.
2946 * normal/i386/setjmp.S: Moved from here ...
2947 * lib/i386/setjmp.S: ... Moved here
2948 * normal/x86_64/setjmp.S: Moved from here ...
2949 * lib/x86_64/setjmp.S: ... Moved here
2950 * normal/powerpc/setjmp.S: Moved from here ...
2951 * lib/powerpc/setjmp.S: ... Moved here
2952 * normal/sparc64/setjmp.S: Moved from here ...
2953 * lib/sparc64/setjmp.S: ... Moved here
2955 * include/grub/i386/setjmp.h (grub_setjmp): Don't use attribute
2956 returns_twice in mingw.
2958 * script/lua/grub_lib.c: New file.
2959 * script/lua/grub_lib.h: Likewise.
2960 * script/lua/grub_lua.h: Likewise.
2961 * script/lua/grub_main.c: Likewise.
2962 * script/lua/lapi.c: Likewise.
2963 * script/lua/lapi.h: Likewise.
2964 * script/lua/lauxlib.c: Likewise.
2965 * script/lua/lauxlib.h: Likewise.
2966 * script/lua/lbaselib.c: Likewise.
2967 * script/lua/lcode.c: Likewise.
2968 * script/lua/lcode.h: Likewise.
2969 * script/lua/ldblib.c: Likewise.
2970 * script/lua/ldebug.c: Likewise.
2971 * script/lua/ldebug.h: Likewise.
2972 * script/lua/ldo.c: Likewise.
2973 * script/lua/ldo.h: Likewise.
2974 * script/lua/ldump.c: Likewise.
2975 * script/lua/lfunc.c: Likewise.
2976 * script/lua/lfunc.h: Likewise.
2977 * script/lua/lgc.c: Likewise.
2978 * script/lua/lgc.h: Likewise.
2979 * script/lua/linit.c: Likewise.
2980 * script/lua/liolib.c: Likewise.
2981 * script/lua/llex.c: Likewise.
2982 * script/lua/llex.h: Likewise.
2983 * script/lua/llimits.h: Likewise.
2984 * script/lua/lmathlib.c: Likewise.
2985 * script/lua/lmem.c: Likewise.
2986 * script/lua/lmem.h: Likewise.
2987 * script/lua/loadlib.c: Likewise.
2988 * script/lua/lobject.c: Likewise.
2989 * script/lua/lobject.h: Likewise.
2990 * script/lua/lopcodes.c: Likewise.
2991 * script/lua/lopcodes.h: Likewise.
2992 * script/lua/loslib.c: Likewise.
2993 * script/lua/lparser.c: Likewise.
2994 * script/lua/lparser.h: Likewise.
2995 * script/lua/lstate.c: Likewise.
2996 * script/lua/lstate.h: Likewise.
2997 * script/lua/lstring.c: Likewise.
2998 * script/lua/lstring.h: Likewise.
2999 * script/lua/lstrlib.c: Likewise.
3000 * script/lua/ltable.c: Likewise.
3001 * script/lua/ltable.h: Likewise.
3002 * script/lua/ltablib.c: Likewise.
3003 * script/lua/ltm.c: Likewise.
3004 * script/lua/ltm.h: Likewise.
3005 * script/lua/lua.h: Likewise.
3006 * script/lua/luaconf.h: Likewise.
3007 * script/lua/lualib.h: Likewise.
3008 * script/lua/lundump.c: Likewise.
3009 * script/lua/lundump.h: Likewise.
3010 * script/lua/lvm.c: Likewise.
3011 * script/lua/lvm.h: Likewise.
3012 * script/lua/lzio.c: Likewise.
3013 * script/lua/lzio.h: Likewise.
3015 2009-05-16 Bean <bean123ch@gmail.com>
3017 * include/grub/kernel.h (grub_module_header_types): Add type
3020 * kern/main.c (grub_load_config): New function.
3021 (grub_main): Call grub_load_config to read boot config.
3023 * grub-mkimage (generate_image): New parameter config_path.
3024 (options): New option --config.
3025 (main): Parse --config option, and pass it to generate_image.
3027 2009-05-14 Christian Franke <franke@computer.org>
3029 * commands/i386/pc/drivemap_int13h.S: Add missing EXT_C for symbols.
3030 This fixes build on Cygwin.
3032 2009-05-14 Pavel Roskin <proski@gnu.org>
3034 * commands/i386/pc/drivemap_int13h.S: Eliminate unconditional
3035 jump. This saves two bytes, so the typical case of 2 swapped
3036 drives would fit 32 bytes.
3038 2009-05-13 Pavel Roskin <proski@gnu.org>
3040 * loader/i386/multiboot.c (grub_multiboot): Cast mmap_addr to
3041 grub_uint32_t to avoid a warning.
3043 * loader/i386/linux.c (allocate_pages): When assigning
3044 real_mode_mem, cast through grub_size_t to fix a warning. The
3045 code already makes sure that the value would fit a pointer.
3046 (grub_linux_setup_video): Cast render_target->data to
3047 grub_size_t to fix a warning.
3049 2009-05-13 Javier MartÃn <lordhabbit@gmail.com>
3051 * commands/i386/pc/drivemap.c: New file - implement drivemap
3053 * commands/i386/pc/drivemap_int13h.S: New file - int13 handler.
3054 * conf/i386-pc.rmk: Add drivemap.c and drivemap_int13h.S.
3056 2009-05-13 Pavel Roskin <proski@gnu.org>
3058 * util/i386/pc/grub-setup.c (setup): Remove unused variable
3059 embedding_area_exists.
3061 2009-05-13 Robert Millan <rmh.grub@aybabtu.com>
3063 * util/i386/pc/grub-setup.c (setup): Restructure code flow to make
3064 it easier to understand / work with.
3065 Improve warning messages for cases where there's no embedding area,
3066 or when it is too small (or core.img too large).
3068 2009-05-13 Pavel Roskin <proski@gnu.org>
3070 * loader/i386/pc/multiboot2.c: Add necessary includes for
3071 grub_multiboot2_real_boot().
3073 * fs/iso9660.c (grub_iso9660_iterate_dir): The file mode in the
3074 PX record is always little-endian. We only need the lower 2
3077 * fs/cpio.c: Use the same name "struct head" for tar and cpio to
3078 facilitate code reuse.
3079 (grub_cpio_mount): Use "struct head", not a char buffer. This
3080 fixes a warning reported by gcc 4.4.
3082 * kernel/disk.c (grub_disk_read): Use void pointer for the
3084 (grub_disk_write): Use const void pointer for the buffer.
3085 Adjust all callers. Remove unnecessary casts.
3087 2009-05-10 Robert Millan <rmh.grub@aybabtu.com>
3089 * util/i386/pc/grub-install.in: Update copyright year.
3091 2009-05-09 Vladimir Serbinenko <phcoder@gmail.com>
3095 * commands/gptsync.c: new file
3096 * conf/common.rmk (pkglib_MODULES): add gptsync.mod
3097 (gptsync_mod_SOURCES): new variable
3098 (gptsync_mod_CFLAGS): likewise
3099 (gptsync_mod_LDFLAGS): likewise
3100 * include/grub/pc_partition.h (GRUB_PC_PARTITION_TYPE_NTFS):
3102 (GRUB_PC_PARTITION_TYPE_HFS): likewise
3103 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/gptsync.c
3104 * conf/i386-ieee1275.rmk: likewise
3105 * conf/i386-pc.rmk: likewise
3106 * conf/powerpc-ieee1275.rmk: likewise
3108 2009-05-09 Vladimir Serbinenko <phcoder@gmail.com>
3112 * kern/dl.c (grub_dl_ref): omit when compiling grub-emu
3113 (grub_dl_ref): likewise
3115 2009-05-08 Robert Millan <rmh.grub@aybabtu.com>
3117 * util/i386/pc/grub-setup.c (setup): Factorize find_usable_region(),
3118 split in two functions (one for msdos and one for gpt).
3120 2009-05-08 Pavel Roskin <proski@gnu.org>
3122 * disk/raid.c (grub_raid_block_xor): Make buf2 constant, it's
3125 * disk/raid6_recover.c (grub_raid6_recover): Fix warnings about
3126 uninitialized err[0] and err[1]. Rename them to bad1 and bad2.
3127 Initialize them with -1. Add sanity check for bad1. Eliminate
3130 2009-05-08 David S. Miller <davem@davemloft.net>
3132 * util/sparc64/ieee1275/grub-ofpathname.c (main): Set progname.
3134 2009-05-06 Robert Millan <rmh.grub@aybabtu.com>
3136 * util/i386/pc/grub-setup.c (setup): Fix check for embed region
3139 2009-05-05 Felix Zielcke <fzielcke@z-51.de>
3141 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
3142 `kern/rescue_reader.c', `kern/rescue_parser.c' and `normal/autofs.c'.
3144 2009-05-05 David S. Miller <davem@davemloft.net>
3146 * util/sparc64/ieee1275/grub-install.in: Fix sed arg quoting.
3148 2009-05-05 Pavel Roskin <proski@gnu.org>
3150 * include/grub/dl.h [GRUB_UTIL]: Provide inline implementations
3151 of grub_dl_ref() and grub_dl_unref().
3152 * commands/parttool.c: Remove preprocessor conditionals around
3153 grub_dl_ref() and grub_dl_unref().
3154 * fs/affs.c: Likewise.
3155 * fs/afs.c: Likewise.
3156 * fs/cpio.c: Likewise.
3157 * fs/ext2.c: Likewise.
3158 * fs/fat.c: Likewise.
3159 * fs/hfs.c: Likewise.
3160 * fs/hfsplus.c: Likewise.
3161 * fs/iso9660.c: Likewise.
3162 * fs/jfs.c: Likewise.
3163 * fs/minix.c: Likewise.
3164 * fs/ntfs.c: Likewise.
3165 * fs/reiserfs.c: Likewise.
3166 * fs/sfs.c: Likewise.
3167 * fs/udf.c: Likewise.
3168 * fs/ufs.c: Likewise.
3169 * fs/xfs.c: Likewise.
3170 * include/grub/dl.h: Likewise.
3171 * loader/xnu.c: Likewise.
3173 2009-05-04 Pavel Roskin <proski@gnu.org>
3175 * commands/acpi.c: Remove unused variable my_mod.
3176 * partmap/amiga.c: Likewise.
3177 * partmap/apple.c: Likewise.
3178 * partmap/gpt.c: Likewise.
3179 * partmap/pc.c: Likewise.
3180 * partmap/sun.c: Likewise.
3181 * term/gfxterm.c: Likewise.
3182 * term/i386/pc/vesafb.c: Likewise.
3183 * term/i386/pc/vga.c: Likewise.
3185 2009-05-04 David S. Miller <davem@davemloft.net>
3187 * kern/ieee1275/openfw.c (grub_children_iterate): Fix string
3188 pointer args to grub_ieee1275_get_property().
3190 * conf/sparc64-ieee1275.rmk: Fix build due to missing '\'.
3192 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Bypass cdrom
3193 devices, and do not traverse down under controller nodes.
3195 * disk/ieee1275/ofdisk.c (compute_dev_path): New.
3196 (grub_ofdisk_open): Use it to un-escape "," characters.
3197 * kern/disk.c (find_part_sep): New.
3198 (grub_disk_open): Use it to find the first non-escaped ','
3199 character in the disk name.
3200 * util/ieee1275/devicemap.c (escape_of_path): New.
3201 (grub_util_emit_devicemap_entry): Use it.
3202 * util/sparc64/ieee1275/grub-install.in: Update script to
3203 strip partition specifiers properly by not triggering on
3204 '\' escaped ',' characters.
3206 2009-05-04 Robert Millan <rmh.grub@aybabtu.com>
3208 * include/grub/i386/linux.h (GRUB_LINUX_VID_MODE_VESA_START): Set
3210 * loader/i386/linux.c (vga_modes, linux_vesafb_res): Add a few
3212 (linux_vesafb_modes): Add a lot of additional modes to the list (based
3213 on documentation from Wikipedia).
3215 2009-05-04 Pavel Roskin <proski@gnu.org>
3217 * disk/ata.c: Spelling fixes.
3218 * disk/raid.c: Likewise.
3219 * disk/usbms.c: Likewise.
3220 * disk/dmraid_nvidia.c: Likewise.
3221 * kern/ieee1275/openfw.c: Likewise.
3222 * kern/ieee1275/init.c: Likewise.
3223 * kern/ieee1275/cmain.c: Likewise.
3224 * boot/i386/pc/cdboot.S: Likewise.
3225 * video/readers/png.c: Likewise.
3226 * video/i386/pc/vbe.c: Likewise.
3227 * fs/udf.c: Likewise.
3228 * fs/hfs.c: Likewise.
3229 * fs/reiserfs.c: Likewise.
3230 * efiemu/runtime/efiemu.c: Likewise.
3231 * efiemu/main.c: Likewise.
3232 * efiemu/mm.c: Likewise.
3233 * include/grub/elf.h: Likewise.
3234 * include/grub/xnu.h: Likewise.
3235 * include/grub/usbdesc.h: Likewise.
3236 * include/grub/usb.h: Likewise.
3237 * include/grub/script_sh.h: Likewise.
3238 * include/grub/lib/LzmaEnc.h: Likewise.
3239 * include/grub/efiemu/efiemu.h: Likewise.
3240 * include/grub/command.h: Likewise.
3241 * normal/menu.c: Likewise.
3242 * normal/main.c: Likewise.
3243 * normal/datetime.c: Likewise.
3244 * bus/usb/uhci.c: Likewise.
3245 * mmap/i386/uppermem.c: Likewise.
3246 * mmap/mmap.c: Likewise.
3247 * commands/acpi.c: Likewise.
3248 * commands/test.c: Likewise.
3249 * partmap/apple.c: Likewise.
3250 * font/font.c: Likewise.
3251 * loader/sparc64/ieee1275/linux.c: Likewise.
3252 * loader/macho.c: Likewise.
3253 * loader/i386/bsd_trampoline.S: Likewise.
3254 * loader/i386/bsd.c: Likewise.
3255 * loader/xnu.c: Likewise.
3256 * term/i386/pc/vesafb.c: Likewise.
3257 * term/usb_keyboard.c: Likewise.
3258 * util/resolve.c: Likewise.
3259 * util/getroot.c: Likewise.
3261 2009-05-04 Felix Zielcke <fzielcke@z-51.de>
3263 * conf/i386-pc.rmk (libpkg_DATA): Rename to pkglib_DATA.
3265 2009-05-04 Robert Millan <rmh.grub@aybabtu.com>
3267 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS] (grub_cmd_linux): Fix
3270 2009-05-04 Robert Millan <rmh.grub@aybabtu.com>
3272 * loader/i386/linux.c (grub_cmd_linux): Make "vga=" compatibility
3273 parameter only available on BIOS.
3275 2009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
3277 Removed wrong semicolon in declaration
3279 * grub/misc.h (grub_dprintf): remove semicolon
3281 2009-05-04 Robert Millan <rmh.grub@aybabtu.com>
3283 * loader/i386/linux.c (GRUB_ASSUME_LINUX_HAS_FB_SUPPORT): New macro.
3284 (grub_linux_boot): Don't check for `linux_vesafb_modes' bounds (this
3285 is done by grub_cmd_linux() now).
3286 [! GRUB_ASSUME_LINUX_HAS_FB_SUPPORT]: If "vga=" parameter wasn't set,
3287 restore video to text mode.
3288 (grub_cmd_linux): Default `vid_mode' initialization to 0, which
3289 indicates lack of "vga=" parameter. "vga=0" is mapped to
3290 `GRUB_LINUX_VID_MODE_NORMAL'.
3292 2009-05-04 Felix Zielcke <fzielcke@z-51.de>
3294 * conf/i386-efi.rmk (grub_emu_SOURCES): Remove `normal/execute.c',
3295 `normal/lexer.c', `kern/rescue.c', `normal/function.c', `normal/misc.c'
3296 and `normal/script.c'. Add `kern/rescue_reader.c',
3297 `kern/rescue_parser.c', `script/sh/main.c', `script/sh/execute.c',
3298 `script/sh/function.c', `script/sh/lexer.c', `script/sh/script.c' and
3299 `grub_script.tab.c'.
3301 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3302 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
3303 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3304 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
3305 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3307 * Makefile.in: Remove duplicated 2008 in Copyright line.
3309 2009-05-04 Robert Millan <rmh.grub@aybabtu.com>
3311 * util/misc.c (grub_util_warn): New function. Emits a warning
3313 * include/grub/util/misc.h (grub_util_warn): New declaration.
3315 * util/i386/pc/grub-install.in: Understand --force and pass it down
3318 * util/i386/pc/grub-setup.c (main): Understand --force and pass it
3320 (setup): Improve error messages and add warnings when requested to
3321 install in odd layouts. Refuse to install using blocklists unless
3324 2009-05-04 martin f. krafft <madduck@madduck.net>
3326 * disk/raid.c (grub_raid_scan_device): Improve debug message.
3328 2009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
3330 Updated copyright year
3332 * fs/hfsplus.c: updated copyright year
3334 2009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
3338 * fs/hfsplus.c (grub_hfsplus_volheader): added num_serial field
3339 in the space previously used by unused3
3340 (grub_hfsplus_uuid): new function
3341 (grub_hfsplus_fs): added uuid field
3343 2009-05-03 Pavel Roskin <proski@gnu.org>
3345 * disk/ata.c: Don't cast mod to void in GRUB_MOD_INIT to
3346 suppress warnings. It's no longer needed.
3347 * disk/host.c: Likewise.
3348 * disk/ata_pthru.c: Likewise.
3349 * disk/loopback.c: Likewise.
3350 * hook/datehook.c: Likewise.
3351 * parttool/pcpart.c: Likewise.
3352 * fs/i386/pc/pxe.c: Likewise.
3353 * fs/ntfscomp.c: Likewise.
3354 * efiemu/main.c: Likewise.
3355 * mmap/mmap.c: Likewise.
3356 * commands/crc.c: Likewise.
3357 * commands/hexdump.c: Likewise.
3358 * commands/hdparm.c: Likewise.
3359 * commands/acpi.c: Likewise.
3360 * commands/echo.c: Likewise.
3361 * commands/minicmd.c: Likewise.
3362 * commands/blocklist.c: Likewise.
3363 * commands/memrw.c: Likewise.
3364 * commands/loadenv.c: Likewise.
3365 * commands/usbtest.c: Likewise.
3366 * commands/lsmmap.c: Likewise.
3367 * commands/boot.c: Likewise.
3368 * commands/parttool.c: Likewise.
3369 * commands/configfile.c: Likewise.
3370 * commands/search.c: Likewise.
3371 * commands/ieee1275/suspend.c: Likewise.
3372 * commands/cat.c: Likewise.
3373 * commands/i386/pc/pxecmd.c: Likewise.
3374 * commands/i386/pc/play.c: Likewise.
3375 * commands/i386/pc/halt.c: Likewise.
3376 * commands/i386/pc/vbeinfo.c: Likewise.
3377 * commands/i386/pc/vbetest.c: Likewise.
3378 * commands/lspci.c: Likewise.
3379 * commands/date.c: Likewise.
3380 * commands/handler.c: Likewise.
3381 * commands/ls.c: Likewise.
3382 * commands/test.c: Likewise.
3383 * commands/cmp.c: Likewise.
3384 * commands/efi/loadbios.c: Likewise.
3385 * commands/efi/fixvideo.c: Likewise.
3386 * commands/halt.c: Likewise.
3387 * commands/help.c: Likewise.
3388 * commands/reboot.c: Likewise.
3389 * hello/hello.c: Likewise.
3390 * script/sh/main.c: Likewise.
3391 * loader/xnu.c: Likewise.
3392 * term/terminfo.c: Likewise.
3393 * term/i386/pc/serial.c: Likewise.
3394 * term/usb_keyboard.c: Likewise.
3396 2009-05-03 David S. Miller <davem@davemloft.net>
3398 * normal/menu.c: Include grub/parser.h
3400 2009-05-03 Pavel Roskin <proski@gnu.org>
3402 * mmap/efi/mmap.c (grub_mmap_malign_and_register): Return void*,
3404 * mmap/i386/mmap.c (grub_mmap_malign_and_register): Likewise.
3405 Suggested by Javier MartÃn <lordhabbit@gmail.com>
3407 * util/i386/pc/grub-mkrescue.in: Allow for the case when
3408 efiemu??.o doesn't exist.
3409 * util/i386/pc/grub-install.in: Likewise. Use "cp -f" for
3412 2009-05-03 Bean <bean123ch@gmail.com> Vladimir Serbinenko <phcoder@gmail.com>
3414 FreeBSD 64-bit support
3416 * conf/i386-pc.rmk (bsd_mod_SOURCES): add loader/i386/bsd_helper.S
3417 and loader/i386/bsd_trampoline.S
3418 (bsd_mod_ASFLAGS): new variable
3419 * include/grub/i386/bsd.h (FREEBSD_MODINFOMD_SMAP): new definition
3420 (FREEBSD_MODTYPE_KERNEL64): likewise
3421 (grub_bsd64_trampoline_start): likewise
3422 (grub_bsd64_trampoline_end): likewise
3423 (grub_bsd64_trampoline_selfjump): likewise
3424 (grub_bsd64_trampoline_gdt): likewise
3425 * include/grub/i386/loader.h (grub_unix_real_boot): moved from here ...
3426 * include/grub/i386/bsd.h (grub_unix_real_boot): ... moved here
3427 * kern/i386/loader.S (grub_unix_real_boot): moved from here ...
3428 * loader/i386/bsd_helper.S (grub_unix_real_boot): moved here
3429 * include/grub/gpt_partition.h (grub_gpt_partentry): Corrected the type
3431 * loader/i386/bsd_pagetable.c: new file
3432 * loader/i386/bsd_trampoline.S: likewise
3433 * loader/i386/bsd.c (ALIGN_QWORD): new macro
3434 (ALIGN_VAR): likewise
3435 (entry_hi): new variable
3436 (kern_end_mdofs): likewise
3437 (is_64bit): likewise
3438 (grub_freebsd_add_meta): use ALIGN_VAR
3439 (grub_e820_mmap): new declaration
3440 (grub_freebsd_add_mmap): new function
3441 (grub_freebsd_add_meta_module): support 64 bit kernels
3442 (grub_freebsd_list_modules): use ALIGN_VAR
3443 (gdt_descriptor): new declaration
3444 (grub_freebsd_boot): support 64 bit kernels
3445 (grub_bsd_elf64_hook): new function
3446 (grub_bsd_load_elf): support elf64
3448 2009-05-03 Bean <bean123ch@gmail.com>
3450 * script/sh/execute.c (grub_script_execute_cmdif): Reset grub_errno
3451 after we get the result of if statement.
3453 2009-05-03 Bean <bean123ch@gmail.com>
3455 * Makefile.in (enable_efiemu): New variable.
3457 * conf/i386-pc.rmk: Only compile efiemu runtimes when enable_efiemu is
3459 (efiemu32.o): Use macro $< for source file, add $(srcdir) to include
3461 (efi64_c.o): Use macro $< for source file, add $(srcdir) to include
3462 path, add -mno-red-zone option.
3463 (efiemu64_s.o): Likewise.
3464 (efiemu64.o): Use macro $^ for source file.
3466 * configure.ac (--enable-efiemu): New option.
3468 2009-05-03 Vladimir Serbinenko <phcoder@gmail.com>
3472 * conf/i386-efi.rmk (kernel_mod_HEADERS): added i386/pit.h
3473 (pkglib_MODULES): add xnu.mod
3474 (xnu_mod_SOURCES): new variable
3475 (xnu_mod_CFLAGS): likewise
3476 (xnu_mod_LDFLAGS): likewise
3477 (xnu_mod_ASFLAGS): likewise
3478 * conf/i386-pc.rmk: likewise
3479 * conf/x86_64-efi.rmk: likewise
3480 * include/grub/efi/efi.h (grub_efi_finish_boot_services):
3482 * include/grub/i386/macho.h: new file
3483 * include/grub/i386/xnu.h: likewise
3484 * include/grub/macho.h: likewise
3485 * include/grub/machoload.h: likewise
3486 * include/grub/x86_64/macho.h: likewise
3487 * include/grub/x86_64/xnu.h: likewise
3488 * include/grub/xnu.h: likewise
3489 * kern/efi/efi.c (grub_efi_finish_boot_services): new function
3490 * kern/efi/mm.c (MAX_HEAP_SIZE): increase
3491 * loader/i386/efi/xnu.c: new file
3492 * loader/i386/pc/xnu.c: likewise
3493 * loader/i386/xnu.c: likewise
3494 * loader/i386/xnu_helper.S: likewise
3495 * loader/macho.c: likewise
3496 * loader/xnu.c: likewise
3497 * loader/xnu_resume.c: likewise
3498 * util/grub-dumpdevtree: likewise
3499 * include/grub/i386/pit.h: include grub/err.h
3500 (grub_pit_wait): export
3501 * util/grub.d/30_os-prober.in: support Darwin/Mac OS X
3503 2009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
3507 * conf/i386-pc.rmk: new modules efiemu, efiemu_acpi, efiemu_pnvram,
3508 _linux_efi, linux_efi.
3509 new files in grub-emu
3510 new targets efiemu32.o and efiemu64.o
3511 * loader/linux_normal_efiemu.c: likewise
3512 * loader/i386/efi/linux.c: added preliminary efiemu support
3513 * util/i386/pc/grub-install.in: add efiemu??.o to the list of
3515 * include/grub/autoefi.h: new file
3516 * include/grub/i386/efiemu.h: likewise
3517 * include/grub/i386/pc/efiemu.h: likewise
3518 * include/grub/efi/api.h: add LL suffix when necessary
3519 new definitions relating to tables
3520 * include/grub/efiemu/efiemu.h: new file
3521 * include/grub/efiemu/runtime.h: likewise
3522 * efiemu/prepare.c: likewise
3523 * efiemu/loadcore_common.c: likewise
3524 * efiemu/loadcore64.c: likewise
3525 * efiemu/runtime/efiemu.sh: likewise
3526 * efiemu/runtime/efiemu.S: likewise
3527 * efiemu/runtime/efiemu.c: likewise
3528 * efiemu/runtime/config.h: likewise
3529 * efiemu/prepare32.c: likewise
3530 * efiemu/main.c: likewise
3531 * efiemu/modules/pnvram.c: likewise
3532 * efiemu/modules/i386: likewise
3533 * efiemu/modules/i386/pc: likewise
3534 * efiemu/modules/acpi.c: likewise
3535 * efiemu/i386/pc/cfgtables.c: likewise
3536 * efiemu/i386/loadcore64.c: likewise
3537 * efiemu/i386/loadcore32.c: likewise
3538 * efiemu/prepare64.c: likewise
3539 * efiemu/loadcore.c: likewise
3540 * efiemu/symbols.c: likewise
3541 * efiemu/mm.c: likewise
3542 * efiemu/loadcore32.c: likewise
3544 2009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
3548 * commands/acpi.c: new file
3549 * commands/i386/pc/acpi.c: likewise
3550 * commands/efi/acpi.c: likewise
3551 * include/grub/acpi.h: likewise
3552 * conf/i386-pc.rmk (pkglib_MODULES): added acpi.mod
3553 (acpi_mod_SOURCES): new variable
3554 (acpi_mod_CFLAGS): likewise
3555 (acpi_mod_LDFLAGS): likewise
3556 * conf/i386-efi.rmk: likewise
3557 * conf/x86_64-efi.rmk: likewise
3559 2009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
3561 Missing part from mmap patch
3563 * mmap/efi/mmap.c (grub_machine_mmap_unregister): renamed to
3564 (grub_mmap_unregister)
3565 (grub_mmap_free_and_unregister): use grub_mmap_register
3567 2009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
3571 * loader/i386/efi/linux.c (grub_linux_boot): use grub_mmap_iterate
3572 * loader/i386/linux.c (find_mmap_size): likewise
3573 (allocate_pages): likewise
3574 * loader/i386/multiboot.c (grub_get_multiboot_mmap_len): likewise
3575 (grub_fill_multiboot_mmap): likewise
3576 (grub_multiboot): use grub_mmap_get_lower and grub_mmap_get_upper
3577 * loader/i386/pc/linux.c (grub_cmd_linux): use grub_mmap_get_lower
3578 * include/grub/i386/bsd.h (OPENBSD_MMAP_AVAILABLE): new definition
3579 (OPENBSD_MMAP_RESERVED): likewise
3580 * include/grub/i386/pc/memory.h: include grub/memory.h
3581 (grub_lower_mem): removed
3582 (grub_upper_mem): likewise
3583 (GRUB_MACHINE_MEMORY_ACPI): new definition
3584 (GRUB_MACHINE_MEMORY_NVS): likewise
3585 (GRUB_MACHINE_MEMORY_MAX_TYPE): likewise
3586 (GRUB_MACHINE_MEMORY_HOLE): likewise
3587 (grub_machine_mmap_register): likewise
3588 (grub_machine_mmap_unregister): likewise
3589 (grub_machine_get_upper): likewise
3590 (grub_machine_get_lower): likewise
3591 (grub_machine_get_post64): likewise
3592 * include/grub/i386/efi/memory.h: new file
3593 * include/grub/x86_64/efi/memory.h: likewise
3594 * include/grub/efi/memory.h: likewise
3595 * conf/i386-pc.rmk (pkglib_MODULES): added mmap.mod
3596 (mmap_mod_SOURCES): new variable
3597 (mmap_mod_LDFLAGS): likewise
3598 (mmap_mod_ASFLAGS): likewise
3599 * conf/i386-coreboot.rmk: likewise
3600 * conf/i386-ieee1275.rmk: likewise
3601 * conf/i386-efi.rmk: likewise
3602 * conf/x86_64-efi.rmk: likewise
3603 * include/grub/types.h (UINT_TO_PTR): new macro
3604 (PTR_TO_UINT32): likewise
3605 (PTR_TO_UINT64): likewise
3606 * include/grub/memory.h: new file
3607 * mmap/i386/pc/mmap.c: likewise
3608 * mmap/i386/pc/mmap_helper.S: likewise
3609 * mmap/i386/uppermem.c: likewise
3610 * mmap/mmap.c: likewise
3611 * mmap/efi/mmap.c: likewise
3612 * kern/i386/coreboot/init.c (grub_machine_init): don't use
3614 * kern/i386/pc/init.c (grub_lower_mem): removed variable
3615 (grub_upper_mem): likewise
3616 (grub_machine_init): don't use grub_upper_mem,
3617 make grub_lower_mem local
3618 * loader/i386/bsd.c (grub_openbsd_boot): use grub_mmap_get_lower,
3619 grub_mmap_iterate and grub_mmap_get_upper
3620 (grub_netbsd_boot): use grub_mmap_get_lower and grub_mmap_get_upper
3622 2009-05-02 Bean <bean123ch@gmail.com>
3624 * conf/common.rmk (grub_script.tab.c): Change normal/parser.y to
3626 (pkglib_MODULES): Add normal.mod and sh.mod.
3627 (normal_SOURCES): New variable.
3628 (normal_mod_CFLAGS): Likewise.
3629 (normal_mod_LDFLAGS): Likewise.
3630 (sh_mod_SOURCES): Likewise.
3631 (sh_mod_CFLAGS): Likewise.
3632 (sh_mod_LDFLAGS): Likewise.
3634 * conf/i386-pc.rmk (normal/lexer.c_DEPENDENCIES): Changed to
3635 script/sh/lexer.c_DEPENDENCIES.
3636 (kernel_img_SOURCES): Remove kern/rescue.c, and kern/reader.c,
3637 kern/rescue_reader.c and kern/rescue_parser.c.
3638 (kernel_img_HEADERS): Remove rescue.h, add reader.h.
3639 (grub_emu_SOURCES): Change source files.
3640 (pkglib_MODULES): Remove normal.mod.
3641 (normal_SOURCES): Removed.
3642 (normal_mod_CFLAGS): Likewise.
3643 (normal_mod_LDFLAGS): Likewise.
3644 * conf/i386-coreboot.rmk: Likewise.
3645 * conf/i386-efi.rmk: Likewise.
3646 * conf/i386-ieee1276.rmk: Likewise.
3647 * conf/powerpc-ieee1275.rmk: Likewise.
3648 * conf/sparc64-ieee1275.rmk: Likewise.
3649 * conf/x86_64-efi.rmk: Likewise.
3651 * include/grub/command.h (grub_command_execute): New inline function.
3653 * include/grub/menu.h (grub_menu_entry): Removed commands field.
3655 * include/grub/normal.h: Remove <grub/setjmp.h>.
3656 (grub_fs_module_list): Moved to normal/autofs.c.
3657 (grub_exit_env): Removed.
3658 (grub_command_execute): Likewise.
3659 (grub_normal_menu_addentry): Renamed to grub_menu_addentry, removed
3661 (read_command_list): New function declaration.
3662 (read_fs_list): Likewise.
3664 * include/parser.h: Include <grub/reader.h>.
3665 (grub_parser_split_cmdline): Change type of getline parameter.
3666 (grub_parser): New structure.
3667 (grub_parser_class): New variable.
3668 (grub_parser_execute): New function declaration.
3669 (grub_register_rescue_parser): Likewise.
3670 (grub_parser_register): New inline function.
3671 (grub_parser_unregister): Likewise.
3672 (grub_parser_get_current): Likewise.
3673 (grub_parser_set_current): Likewise.
3675 * include/grub/reader.h: New file.
3676 * kern/reader.c: Likewise.
3677 * kern/rescue_parser.c: Likewise.
3678 * kern/rescue_reader.c: Likewise.
3679 * normal/autofs.c: Likewise.
3680 * normal/dyncmd.c: Likewise.
3682 * include/grub/rescue.h: Removed.
3683 * normal/command.h: Likewise.
3685 * include/grub/script.h: Moved to ...
3686 * include/grub/script_sh.h: ... Moved here.
3687 * normal/execute.c: Moved to ...
3688 * script/sh/execute.c: ... Moved here.
3689 * normal/function.c: Moved to ...
3690 * script/sh/function.c: ... Moved here.
3691 * normal/lexer.c: Moved to ...
3692 * script/sh/lexer.c: ... Moved here.
3693 * normal/parser.y: Moved to ...
3694 * script/sh/parser.y: ... Moved here.
3695 * normal/script.c: Moved to ...
3696 * script/sh/script.c: ... Moved here.
3698 * normal/main.c: Remove <grub/rescue.h> and <grub/script.h>, include
3700 (grub_exit_env): Removed.
3701 (fs_module_list): Moved to normal/autofs.c.
3702 (grub_file_getline): Don't handle comment here.
3703 (free_menu): Skip removed field entry->commands.
3704 (grub_normal_menu_addentry): Removed as grub_menu_entry, removed
3706 (read_config_file): Removed nested parameter, change getline function.
3707 (grub_enter_normal_mode): Removed.
3708 (grub_dyncmd_dispatcher): Moved to normal/dyncmd.c.
3709 (read_command_list): Likewise.
3710 (autoload_fs_module): Moved to normal/autofs.c.
3711 (read_fs_list): Likewise.
3712 (reader_nested): New variable.
3713 (grub_normal_execute): Run parser.sh to switch to sh parser.
3714 (grub_cmd_rescue): Removed.
3715 (cmd_normal): Removed.
3716 (grub_cmd_normal): Unregister itself at the beginning. Don't register
3718 (grub_cmdline_run): New function.
3719 (grub_normal_reader_init): Likewise.
3720 (grub_normal_read_line): Likewise.
3721 (grub_env_write_pager): Likewise.
3722 (cmdline): New variable.
3723 (grub_normal_reader): Likewise.
3724 (GRUB_MOD_INIT): Register normal reader and set as current, register
3725 pager hook, register normal command with grub_register_command_prio,
3726 so that it won't show up in command.lst.
3727 (GRUB_MOD_FINI): Unregister normal reader, unhook pager, clear
3728 grub_fs_autoload_hook.
3730 * normal/menu.c: Remove <grub/script.h>, add <grub/command.h>.
3731 (grub_menu_execute_entry): Replace grub_script_execute with
3732 grub_parser_execute, change parameter to grub_command_execute.
3734 * normal/menu_text.c: Remove <grub/script.h>.
3736 * normal/menu_entry.c: Remove <grub/script.h>, add <grub/command.h>
3737 and <grub/parser.h>.
3738 (run): Change editor_getline to use new parser interface. Change
3739 parameter to grub_command_execute.
3741 * kern/main.c: Remove <grub/rescue.h>, include <grub/command.h>,
3742 <grub/reader.h> and <grub/parser.h>.
3743 (grub_load_normal_mode): Execute normal command.
3744 (grub_main): Call grub_register_core_commands,
3745 grub_register_rescue_parser and grub_register_rescue_reader, use
3746 grub_reader_loop to enter input loop.
3748 * kern/parser.c (grub_parser_split_cmdline): Change type of
3750 (grub_parser_class): New variable.
3751 (grub_parser_execute): New function.
3753 * loader/i386/multiboot.c: Remove <grub/rescue.h>.
3754 * loader/multiboot2.c: Likewise.
3755 * loader/sparc64/ieee1275/linux.c: Likewise.
3757 * util/grub-emu.c (read_command_list): New dummy function.
3759 2009-05-02 Robert Millan <rmh.grub@aybabtu.com>
3761 * util/deviceiter.c (grub_util_iterate_devices): Increase max drive
3762 count to 16 for CCISS and IDA.
3764 2009-05-02 Robert Millan <rmh.grub@aybabtu.com>
3766 * normal/menu_text.c (grub_wait_after_message): Print a newline
3767 after waiting for user input.
3769 * loader/i386/linux.c: Include `<grub/normal.h>'.
3770 (grub_cmd_linux): Improve the error message about `ask' mode, by
3771 waiting for user input so it's not missed (we can do this, since
3772 user requested interaction).
3774 2009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
3776 Added missing lst to grub-mkrescue
3778 * util/i386/pc/grub-mkrescue.in: added ${input_dir}/handler.lst
3779 and ${input_dir}/parttool.lst
3781 2009-04-30 David S. Miller <davem@davemloft.net>
3783 * util/hostdisk.c (device_is_wholedisk): New function.
3784 (grub_util_biosdisk_get_grub_dev): Shortcut when hdg.start is
3785 zero only if device_is_wholedisk() returns true.
3787 * util/hostdisk.c (convert_system_partition_to_system_disk):
3788 Handle virtual disk devices named /dev/vdiskX as found on sparc
3791 * kern/sparc64/ieee1275/init.c (grub_machine_set_prefix): If
3792 lettered partition specifier is found, convert to numbered.
3794 2009-04-29 David S. Miller <davem@davemloft.net>
3796 * include/grub/powerpc/ieee1275/memory.h: Include ieee1275.h.
3797 * include/grub/sparc64/ieee1275/memory.h: Likewise.
3799 * normal/command.c: Add missing newline at end of file.
3801 * commands/lsmmap.c (grub_cmd_lsmmap): Add casts to avoid printf
3803 * kern/ieee1275/openfw.c (grub_claimmap): Likewise.
3804 * disk/ieee1275/ofdisk.c (grub_ofdisk_open, grub_ofdisk_close,
3805 grub_ofdisk_read): Likewise, and deal similarly with the fact that
3806 ihandles have a 32-bit type but need to be stored in a "void *".
3808 2009-04-28 Pavel Roskin <proski@gnu.org>
3810 * disk/fs_uuid.c (grub_fs_uuid_open): Use parent->data for dev,
3811 not disk. Adjust all dependencies.
3812 (grub_fs_uuid_close): Use grub_device_close(), not
3815 * disk/fs_uuid.c (grub_fs_uuid_open): Allocate memory to copy
3816 parent's partition, don't copy it by reference, as it gets freed
3819 2009-04-27 Vladimir Serbinenko <phcoder@gmail.com>
3821 Preboot hooks support
3823 * commands/boot.c (struct grub_preboot_t): new declaration
3824 (preboots_head): new variable
3825 (preboots_tail): likewise
3826 (grub_loader_register_preboot_hook): new function
3827 (grub_loader_unregister_preboot_hook): likewise
3828 (grub_loader_set): launch preboot hooks
3829 * include/grub/loader.h (grub_loader_preboot_hook_prio_t): new type
3830 (grub_loader_register_preboot_hook): new declaration
3831 (grub_loader_unregister_preboot_hook): likewise
3833 2009-04-27 Vladimir Serbinenko <phcoder@gmail.com>
3837 * disk/scsi.c (grub_scsi_open): added missing cast when
3838 calling grub_dprintf
3840 2009-04-26 Vladimir Serbinenko <phcoder@gmail.com>
3842 Bug and warning fixes
3844 * include/grub/i386/pc/init.h (grub_stop_floppy): added missing
3846 * commands/test.c (test_parse): fixed bug with file tests and corrected
3847 declaration of find_file
3849 2009-04-26 Pavel Roskin <proski@gnu.org>
3851 * Makefile.in: Don't install empty manual pages if help2man is
3852 missing. Use help2man option for output, not shell redirection.
3854 2009-04-26 David S. Miller <davem@davemloft.net>
3856 * util/grub-mkdevicemap.c (make_device_map): Add missing
3857 NESTED_FUNC_ATTR to process_device().
3859 2009-04-25 Vladimir Serbinenko <phcoder@gmail.com>
3863 * commands/test.c: rewritten to use bash-like test
3865 2009-04-25 Vladimir Serbinenko <phcoder@gmail.com>
3867 Parttool autoloading and improvements
3869 * Makefile.in (pkglib_DATA): add parttool.lst
3870 (parttool.lst): new target
3871 * genmk.rb: generate parttool-*
3872 (CLEANFILES): add #{parttool}
3873 (PARTTOOLFILES): new variable
3874 * genparttoollist.sh: new file
3875 * parttool/pcpart.c (grub_pcpart_boot): more feedback
3876 (grub_pcpart_type): likewise
3877 * commands/parttool.c (helpmsg): new variable
3878 (grub_cmd_parttool): output help if not enough arguments are supplied
3880 (GRUB_MOD_INIT(parttool)): use helpmsg
3882 2009-04-24 David S. Miller <davem@davemloft.net>
3884 Avoiding opening same device multiple times in device iterator.
3886 * kern/device.c: (grub_device_iterate): Define struct part_ent,
3887 and use it to build a list of partitions in iterate_disk() and
3888 iterate_partition().
3890 * disk/fs_uuid.c (grub_fs_uuid_close): Call grub_disk_close()
3893 * disk/ieee1275/nand.c (grub_nand_iterate): Return
3894 grub_devalias_iterate() result instead of unconditional 0.
3895 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Likewise.
3896 Also, capture hook return value, either directly or via
3897 grub_children_iterate(), and propagate to caller.
3898 * include/grub/ieee1275/ieee1275.h (grub_devalias_iterate,
3899 grub_children_iterate): Return value is now 'int' instead of
3901 * kern/ieee1275/openfw.c (grub_children_iterate): Fix to behave
3902 like a proper iterator, stopping when hooks return non-zero.
3903 (grub_devalias_iterate): Likewise.
3905 2009-04-23 David S. Miller <davem@davemloft.net>
3907 * kern/sparc64/ieee1275/openfw.c: Unused, delete.
3909 2009-04-22 David S. Miller <davem@davemloft.net>
3911 * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): If size_cells
3912 is larger than address_cells, use that value for address_cells too.
3914 * include/grub/ieee1275/ieee1275.h (IEEE1275_MAX_PROP_LEN,
3915 IEEE1275_MAX_PATH_LEN): Define.
3916 * kern/ieee1275/openfw.c (grub_children_iterate): Dynamically
3917 allocate 'childtype', 'childpath', 'childname', and 'fullname'.
3918 (grub_devalias_iterate): Dynamically allocate 'aliasname' and
3919 'devtype'. Explicitly NULL terminate devalias expansion.
3921 * util/sparc64/ieee1275/misc.c: New file.
3922 * util/sparc64/ieee1275/grub-setup.c: New file.
3923 * util/sparc64/ieee1275/grub-ofpathname.c: New file.
3924 * util/sparc64/ieee1275/grub-mkimage.c: New file.
3925 * util/sparc64/ieee1275/grub-install.in: New file.
3926 * util/ieee1275/ofpath.c: New file.
3927 * util/ieee1275/devicemap.c: New file.
3928 * util/devicemap.c: New file.
3929 * util/deviceiter.c: New file.
3930 * kern/sparc64/ieee1275/init.c: New file.
3931 * include/grub/util/ofpath.h: New file.
3932 * include/grub/util/deviceiter.h: New file.
3933 * util/grub-mkdevicemap.c: Include deviceiter.h.
3934 Implement using grub_util_emit_devicemap_entry and
3935 grub_util_iterate_devices.
3936 * conf/i386-corebook.rmk: Build util/deviceiter.c and
3937 util/devicemap.c into grub-mkdevicemap
3938 * conf/i386-efi.rmk: Likewise.
3939 * conf/i386-ieee1275.rmk: Likewise.
3940 * conf/i386-pc.rmk: Likewise.
3941 * conf/powerpc-ieee1275.rmk: Likewise.
3942 * conf/sparc64-ieee1275.rmk: Add rules to build boot block
3943 images and installation utilities. Build kernel as image
3944 instead of as elf binary. Use common rules as much as possible.
3946 2009-04-19 Vladimir Serbinenko <phcoder@gmail.com>
3948 Correct GPT definition
3950 * include/grub/gpt_partition.h (grub_gpt_partentry): Corrected the type
3953 2009-04-19 Felix Zielcke <fzielcke@z-51.de>
3955 * INSTALL: Replace `autogen.sh' with `./autogen.sh'.
3957 2009-04-19 David S. Miller <davem@davemloft.net>
3959 * loader/sparc64/ieee1275/linux.c: Include grub/command.h
3960 (grub_rescue_cmd_linux): Rename to...
3961 (grub_cmd_linux): and fix prototype.
3962 (grub_rescue_cmd_initrd): Rename to...
3963 (grub_cmd_initrd): and fix prototype.
3964 (cmd_linux, cmd_initrd): New.
3965 (GRUB_MOD_INIT(linux)): Use grub_register_command().
3966 (GRUB_MOD_FINI(linux): Use grub_unregister_command().
3968 2009-04-17 Pavel Roskin <proski@gnu.org>
3970 * bus/usb/ohci.c (grub_ohci_transaction): Fix incorrect printf
3972 (grub_ohci_transfer): Likewise.
3974 * bus/usb/usbtrans.c (grub_usb_control_msg): Warning fix.
3976 * loader/multiboot_loader.c (grub_cmd_multiboot_loader): Fix
3977 return without a value. Fix inconsistent indentation.
3979 * fs/i386/pc/pxe.c (grub_pxefs_dir): Fix function prototype to
3980 match struct grub_fs.
3982 * disk/ata.c (grub_ata_pciinit): Use NESTED_FUNC_ATTR.
3983 * bus/usb/ohci.c (grub_ohci_pci_iter): Likewise.
3984 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
3985 * commands/lspci.c (grub_lspci_iter): Likewise.
3987 2009-04-16 Bean <bean123ch@gmail.com>
3989 * commands/efi/loadbios.c (grub_cmd_fakebios): Add missing return
3992 2009-04-15 Pavel Roskin <proski@gnu.org>
3994 * include/grub/types.h: Rename ULONG_MAX to GRUB_ULONG_MAX and
3995 LONG_MAX to GRUB_LONG_MAX. Introduce GRUB_LONG_MIN. Update all
3996 users of ULONG_MAX, LONG_MAX and LONG_MIN to use the new
3999 2009-04-15 Felix Zielcke <fzielcke@z-51.de>
4001 * disk/lvm.c (grub_lvm_scan_device): Add `LVM' to the error messages,
4002 that no multiple data or metadata areas are supported and `Unknown
4005 2009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
4007 Move loader out of the kernel
4009 * kern/loader.c: moved to ...
4010 * commands/boot.c: ... moved here
4011 * commands/minicmd.c (grub_mini_cmd_boot): moved to ...
4012 * commands/boot.c (grub_cmd_boot): moved here. All users updated
4013 * include/grub/kernel.h (grub_machine_fini): export
4014 * include/grub/loader.h (grub_loader_is_loaded): update declaration
4015 (grub_loader_set): likewise
4016 (grub_loader_unset): likewise
4017 (grub_loader_boot): likewise
4018 * conf/common.rmk: new module boot.mod
4019 (pkglib_MODULES): add boot.mod
4020 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): remove kern/loader.c
4021 (grub_emu_SOURCES): likewise
4022 * conf/i386-efi.rmk (kernel_elf_SOURCES): likewise
4023 (grub_emu_SOURCES): likewise
4024 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): likewise
4025 (grub_emu_SOURCES): likewise
4026 * conf/i386-pc.rmk (kernel_elf_SOURCES): likewise
4027 (grub_emu_SOURCES): likewise
4028 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): likewise
4029 (grub_emu_SOURCES): likewise
4030 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): likewise
4031 (grub_emu_SOURCES): likewise
4032 * conf/x86_64-efi.rmk (kernel_elf_SOURCES): likewise
4033 (grub_emu_SOURCES): likewise
4035 2009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
4037 use grub_lltoa instead of grub_itoa and grub_ltoa for all purposes
4039 * kern/misc.c (grub_itoa): Removed function
4040 (grub_ltoa): likewise
4041 (grub_vsprintf): use grub_lltoa
4043 2009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
4047 * conf/i386-pc.rmk (grub_emu_SOURCES): add normal/handler.c
4048 * conf/i386-coreboot.rmk: likewise
4049 * conf/i386-ieee1275.rmk: likewise
4050 * conf/powerpc-ieee1275.rmk: likewise
4052 2009-04-15 Felix Zielcke <fzielcke@z-51.de>
4054 * INSTALL: Add that `./autogen.sh' needs to be run before
4057 2009-04-14 Bean <bean123ch@gmail.com>
4059 * Makefile.in (pkglib_DATA): Add handler.lst.
4060 (handler.lst): New rule.
4062 * conf/i386-pc.rmk (normal_mod_SOURCES): Add normal/handler.c.
4063 * conf/i386-coreboot.rmk: Likewise.
4064 * conf/i386-ieee1275.rmk: Likewise.
4065 * conf/i386-efi.rmk: Likewise.
4066 * conf/x86_64-efi.rmk: Likewise.
4067 * conf/powerpc-ieee1275.rmk: Likewise.
4068 * conf/sparc64-ieee1275.rmk: Likewise.
4070 * genhandlerlist.sh: New file.
4072 * genmk.rb: Add rules to generate handler.lst.
4074 * include/grub/normal.h (grub_file_getline): New function definition.
4075 (read_handler_list): Likewise.
4076 (free_handler_list): Likewise.
4078 * include/grub/term.h (grub_term_register_input): Add name parameter
4079 for auto generation of handler.lst.
4080 (grub_term_register_output): Likewise.
4082 * normal/handler.c: New file.
4084 * normal/main.c (get_line): Renamed to grub_file_getline.
4085 (read_config_file): Use the newly renamed grub_file_getline.
4086 (read_command_list): Likewise.
4087 (read_fs_list): Likewise.
4088 (grub_normal_execute): Call read_handler_list to parse handler.lst.
4089 (GRUB_MOD_FINI): Call free_handler_list to free handler list.
4091 * term/efi/console.c (grub_console_init): Add name parameter for auto
4092 generation of handler.lst.
4093 * term/gfxterm.c: Likewise.
4094 * term/i386/pc/at_keyboard.c: Likewise.
4095 * term/i386/pc/console.c: Likewise.
4096 * term/i386/pc/serial.c: Likewise.
4097 * term/i386/pc/vesafb.c: Likewise.
4098 * term/i386/pc/vga.c: Likewise.
4099 * term/i386/pc/vga_text.c: Likewise.
4100 * term/ieee1275/ofconsole.c: Likewise.
4101 * term/usb_keyboard.c: Likewise.
4103 2009-04-14 Bean <bean123ch@gmail.com>
4105 * util/grub-pe2elf.c (write_symbol_table): Terminate short name symbol
4106 properly with null character.
4108 2009-04-14 Felix Zielcke <fzielcke@z-51.de>
4110 * configure: Remove.
4111 * config.h.in: Likewise.
4112 * stamp-h.in: Likewise.
4113 * DISTLIST: Likewise.
4114 * conf/common.mk: Likewise.
4115 * conf/i386-coreboot.mk: Likewise.
4116 * conf/i386-efi.mk: Likewise.
4117 * conf/i386-ieee1275.mk: Likewise.
4118 * conf/i386.mk: Likewise.
4119 * conf/i386-pc.mk: Likewise.
4120 * conf/powerpc-ieee1275.mk: Likewise.
4121 * conf/sparc64-ieee1275.mk: Likewise.
4122 * conf/x86_64-efi.mk: Likewise.
4124 * INSTALL: Remove the sentence that Ruby and autoconf are only required if you
4127 2009-04-14 John Stanley <jpsinthemix@verizon.net>
4128 David S. Miller <davem@davemloft.net>
4130 * util/hostdisk.c (make_device_name): Fix buffer length
4133 2009-04-14 Felix Zielcke <fzielcke@z-51.de>
4135 * util/hostdisk.c [__FreeBSD__ || __FreeBSD_kernel__]: Include
4136 <sys/param.h> and <sys/sysctl.h>.
4137 (open_device) [__FreeBSD__ || __FreeBSD_kernel_]: Use sysctlgetbyname()
4138 to add 0x10 to `kern.geom.debugflags' if it's not already set, before
4139 opening the device and reset them afterwards.
4141 2009-04-13 Pavel Roskin <proski@gnu.org>
4143 * conf/common.rmk (grub_fstest_SOURCES): Add normal/datetime.c.
4144 Reported by John Stanley <jpsinthemix@verizon.net>
4146 2009-04-13 Robert Millan <rmh@aybabtu.com>
4148 * util/grub.d/10_freebsd.in: Detect Debian GNU/kFreeBSD and use
4149 that name for menuentries when appropriate.
4151 2009-04-13 Felix Zielcke <fzielcke@z-51.de>
4153 * util/grub.d/10_freebsd.in: Add a missing `fi'.
4155 2009-04-13 Robert Millan <rmh@aybabtu.com>
4157 * loader/i386/linux.c (grub_cmd_linux): Don't pass `vga=ask' parameter
4158 to Linux, simply abort telling the user it's no longer supported.
4160 2009-04-13 Felix Zielcke <fzielcke@z-51.de>
4162 * util/grub.d/10_freebsd.in: Don't exit if /boot/devices.hints
4163 doesn't exist. Check also for /boot/kernel/kernel.gz. Print
4164 `freebsd_loadenv' only when devices.hints exist.
4166 2009-04-13 Pavel Roskin <proski@gnu.org>
4168 * term/usb_keyboard.c (grub_usb_keyboard_getkey): Warning fixes.
4170 2009-04-13 Felix Zielcke <fzielcke@z-51.de>
4172 * util/i386/pc/grub-install.in (install_drive): Remove the BSD
4174 (grub_drive): Likewise.
4176 2009-04-13 David S. Miller <davem@davemloft.net>
4178 * kern/sparc64/ieee1275/ieee1275.c: New file.
4179 * include/grub/sparc64/ieee1275/ieee1275.h (IEEE1275_MAP_WRITE,
4180 IEEE1275_MAP_READ, IEEE1275_MAP_EXEC, IEEE1275_MAP_LOCKED,
4181 IEEE1275_MAP_CACHED, IEEE1275_MAP_SE, IEEE1275_MAP_GLOBAL,
4182 IEEE1275_MAP_IE, IEEE1275_MAP_DEFAULT): Define.
4183 (grub_ieee1275_map_physical, grub_ieee1275_claim_vaddr,
4184 grub_ieee1275_alloc_physmem): Declare new exported functions.
4186 * include/grub/sparc64/ieee1275/loader.h: New file.
4187 * include/grub/sparc64/ieee1275/memory.h: Likewise.
4188 * include/grub/sparc64/kernel.h: Likewise.
4189 * loader/sparc64/ieee1275/linux.c: Likewise.
4191 * conf/common.rmk (grub_probe_SOURCES): Add Sun partition module.
4192 (grub_fstest_SOURCES): Likewise.
4194 * util/hostdisk.c (make_device_name): Do not make any assumptions
4195 about the length of drive names.
4197 * kern/dl.c (grub_dl_load_file): Close file immediately when
4198 we are done using it.
4200 2009-04-12 David S. Miller <davem@davemloft.net>
4202 * kern/misc.c (grub_ltoa): Fix cast when handling negative
4203 values. Noticed by Pavel Roskin.
4205 * configure.ac: Check for __bswapsi2 and__bswapdi2 using
4208 * genmk.rb: Add more flexible image type specification, also
4209 pass --strip-unneeded to objcopy.
4210 * conf/i386-pc.rmk: Use *_FORMAT.
4211 * conf/i386-pc.mk: Rebuilt.
4213 * disk/ieee1275/ofdisk.c (struct ofdisk_hash_ent): New struct.
4214 (OFDISK_HASH_SZ): Define.
4215 (ofdisk_hash): New hash table.
4216 (ofdisk_hash_fn, ofdisk_hash_find, ofdisk_hash_add): New functions.
4217 (grub_ofdisk_open): Use ofdisk_hash_ent address as disk->id
4218 instead of device phandle which is not unique.
4220 * kern/sparc64/ieee1275/init.c: Delete, replace with...
4221 * kern/sparc64/ieee1275/crt0.S: assembler implementation.
4222 * include/grub/sparc64/ieee1275/kernel.h: Declare grub_prefix[].
4223 (GRUB_MOD_ALIGN, GRUB_MOD_GAP, GRUB_KERNEL_MACHINE_TOTAL_MODULE_SIZE,
4224 GRUB_KERNEL_MACHINE_KERNEL_IMAGE_SIZE,
4225 GRUB_KERNEL_MACHINE_COMPRESSED_SIZE, GRUB_KERNEL_MACHINE_PREFIX,
4226 GRUB_KERNEL_MACHINE_DATA_END): Define.
4227 (grub_kernel_image_size, grub_total_module_size): Declare.
4229 2009-04-12 Pavel Roskin <proski@gnu.org>
4231 * configure.ac: Change the logic when we check for target tools.
4232 Do it when the target is specified and it's different from the
4233 specified value of the host.
4235 2009-04-11 Felix Zielcke <fzielcke@z-51.de>
4237 * util/hostdisk.c [__FreeBSD_kernel__]: Include sys/disk.h.
4238 (grub_util_biosdisk_open) [__FreeBSD_kernel__]: Add support for
4239 GNU/kFreeBSD. Check if a device is a character device. Use
4240 DIOCGMEDIASIZE to get the size.
4241 (convert_system_partition_to_system_disk) [__FreeBSD_kernel__]: Add
4242 support for GNU/kFreeBSD.
4243 (grub_util_biosdisk_get_grub_dev) [__FreeBSD_kernel__]: Check if OS_DEV
4244 is a character device instead of a block device. Add support for
4245 FreeBSD device names.
4247 * util/getroot.c (find_root_device) [__FreeBSD_kernel__]: Check if ENT
4248 is a character device instead of a block device.
4250 * util/grub-probe.c (probe) [__FreeBSD_kernel__]: Check if DEVICE_NAME
4251 is a character device instead of a block device.
4253 2009-04-11 Andrey Shuvikov <mr_hyro@yahoo.com>
4255 * util/hostdisk.c [__FreeBSD__]: Include sys/disk.h.
4256 (grub_util_biosdisk_open) [__FreeBSD__]: Add support for
4257 FreeBSD. Check if a device is a character device. Use
4258 DIOCGMEDIASIZE to get the size.
4259 (convert_system_partition_to_system_disk) [__FreeBSD__]: Add
4260 support for FreeBSD.
4261 (grub_util_biosdisk_get_grub_dev) [__FreeBSD__]: Check if OS_DEV
4262 is a character device instead of a block device. Add support for
4263 FreeBSD device names.
4265 * util/getroot.c (find_root_device) [__FreeBSD__]: Check if ENT is
4266 a character device instead of a block device.
4267 (grub_util_check_char_device): New function.
4269 * util/grub-probe.c (probe) [__FreeBSD__]: Check if DEVICE_NAME is
4270 a character device instead of a block device.
4272 * include/grub/util/getroot.h (grub_util_check_char_device): New
4275 2009-04-11 David S. Miller <davem@davemloft.net>
4277 * conf/sparc64-ieee1275.rmk (kernel_img_LDFLAGS): Link with
4279 * configure.ac: Check for __bswapsi2 and __bswapdi2 presence.
4280 * include/grub/sparc64/libgcc.h (__bswapsi2): Export libgcc
4281 function, if present.
4282 (__bswapdi2): Likewise.
4284 * include/grub/sparc64/ieee1275/boot.h: New file.
4285 * boot/sparc64/ieee1275/boot.S: Likewise.
4286 * boot/sparc64/ieee1275/diskboot.S: Likewise.
4288 * kern/misc.c (grub_ltoa): New function.
4289 (grub_vsprintf): Use it to format 'long' integers.
4291 2009-04-10 David S. Miller <davem@davemloft.net>
4293 * disk/ieee1275/nand.c (grub_nand_open): All ieee1275 call arg
4294 slots are of type grub_ieee1275_cell_t.
4295 (grub_nand_read): Likewise.
4296 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_INVALID,
4297 IEEE1275_IHANDLE_INVALID): Use grub_ieee1275_cell_t since these
4298 macros are used to compare values in arg/ret block of the call.
4299 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
4300 grub_ieee1275_next_property, grub_ieee1275_get_property_length,
4301 grub_ieee1275_instance_to_package, grub_ieee1275_package_to_path,
4302 grub_ieee1275_instance_to_path, grub_ieee1275_write,
4303 grub_ieee1275_read, grub_ieee1275_seek, grub_ieee1275_peer,
4304 grub_ieee1275_child, grub_ieee1275_parent, grub_ieee1275_open,
4305 grub_ieee1275_close, grub_ieee1275_set_property,
4306 grub_ieee1275_set_color): All ieee1275 call arg slots are of type
4307 grub_ieee1275_cell_t.
4308 * kern/ieee1275/openfw.c (grub_map): Likewise.
4309 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_ihandle_t,
4310 grub_ieee1275_phandle_t): Define as grub_unit32_t type.
4312 * kern/ieee1275/init.c (grub_machine_init): Make 'actual' grub_ssize_t.
4313 * kern/ieee1275/openfw.c (grub_children_iterate): Likewise.
4314 (grub_devalias_iterate): Likewise.
4316 2009-04-10 Vladimir Serbinenko <phcoder@gmail.com>
4320 * fs/ufs.c (INODE_NBLOCKS): new definition
4321 (struct grub_ufs_dirent): added fields for non-BSD dirents
4322 (grub_ufs_get_file_block): fixed double indirect handling
4323 (grub_ufs_lookup_symlink): use more robust way to determine whether
4325 (grub_ufs_find_file): support for non-BSD dirents
4326 (grub_ufs_dir): support for non-BSD dirents
4328 2009-04-10 Bean <bean123ch@gnail.com>
4330 * include/grub/efi/api.h (grub_efi_configuration_table): Add packed
4331 attribute, otherwise the size would be wrong for i386 platform.
4333 * include/grub/pci.h (grub_pci_read_word): New inline function.
4334 (grub_pci_read_byte): Likewise.
4335 (grub_pci_write): Likewise.
4336 (grub_pci_write_word): Likewise.
4337 (grub_pci_write_byte): Likewise.
4339 * include/grub/pci.h (grub_pci_iteratefunc_t): Add NESTED_FUNC_ATTR.
4341 * loader/i386/efi/linux.c (fake_bios_data): Moved to loadbios module.
4342 (find_framebuf): Scan pci to locate the frame buffer address.
4344 * commands/efi/fixvideo.c: New file.
4346 * commands/efi/loadbios.c: Likewise.
4348 * commands/memrw.c: Likewise.
4350 * util/grub-dumpbios.in: Likewise.
4352 * conf/common.rmk (grub-dumpbios): New utility.
4353 (pkglib_MODULES): New module memrw.mod.
4354 (memrw_mod_SOURCE): New macro.
4355 (memrw_mod_CFLAGS): Likewise.
4356 (memrw_mod_LDFLAGS): Likewise.
4358 * conf/i386-efi.rmk (pkglib_MODULES): New module loadbios.mod and
4360 (loadbios_mod_SOURCE): New macro.
4361 (loadbios_mod_CFLAGS): Likewise.
4362 (loadbios_mod_LDFLAGS): Likewise.
4363 (fixvideo_mod_SOURCE): Likewise.
4364 (fixvideo_mod_CFLAGS): Likewise.
4365 (fixvideo_mod_LDFLAGS): Likewise.
4367 * conf/x86_64.rmk (pkglib_MODULES): New module loadbios.mod and
4369 (loadbios_mod_SOURCE): New macro.
4370 (loadbios_mod_CFLAGS): Likewise.
4371 (loadbios_mod_LDFLAGS): Likewise.
4372 (fixvideo_mod_SOURCE): Likewise.
4373 (fixvideo_mod_CFLAGS): Likewise.
4374 (fixvideo_mod_LDFLAGS): Likewise.
4376 2009-04-08 Felix Zielcke <fzielcke@z-51.de>
4378 * disk/lvm.c (grub_lvm_scan_device): Add a missing NULL check.
4380 2009-04-07 David S. Miller <davem@davemloft.net>
4382 * kern/sparc64/dl.c (grub_arch_dl_relocate_symbols): Add
4383 support for R_SPARC_OLO10 relocations. Fix compile warning for
4384 R_SPARC_WDISP30 case.
4385 * kern/sparc64/cache.S: Fix grub_arch_sync_caches implementation.
4387 2009-04-06 Pavel Roskin <proski@gnu.org>
4389 * include/grub/misc.h (ARRAY_SIZE): New macro.
4390 * include/grub/i386/linux.h (GRUB_LINUX_VID_MODE_VESA_START):
4392 * loader/i386/linux.c (allocate_pages): Use free_pages().
4393 (grub_linux_unload): Don't use free_pages().
4394 (grub_linux_boot): Prevent accessing linux_vesafb_modes with a
4395 wrong index. Treat all other modes as text modes.
4396 (grub_cmd_linux): Initialize vid_mode unconditionally to
4397 GRUB_LINUX_VID_MODE_NORMAL. Recognize and support "vga=ask".
4399 * commands/help.c (print_command_help): Use cmd->prio, not
4400 cmd->flags to check for GRUB_PRIO_LIST_FLAG_ACTIVE.
4402 2009-04-06 Vladimir Serbinenko <phcoder@gmail.com>
4406 * parttool/pcpart.c: new file
4407 * commands/parttool.c: likewise
4408 * conf/common.rmk (pkglib_MODULES): Added parttool.mod and pcpart.mod
4409 (parttool_mod_SOURCES): new variable
4410 (parttool_mod_CFLAGS): likewise
4411 (parttool_mod_LDFLAGS): likewise
4412 (pcpart_mod_SOURCES): likewise
4413 (pcpart_mod_CFLAGS): likewise
4414 (pcpart_mod_LDFLAGS): likewise
4415 * conf/i386-coreboot.rmk (grub_emu_SOURCES): added commands/parttool.c
4416 and parttool/pcpart.c
4417 * conf/i386-efi.rmk: likewise
4418 * conf/i386-ieee1275.rmk: likewise
4419 * conf/i386-pc.rmk: likewise
4420 * conf/powerpc-ieee1275.rmk: likewise
4421 * conf/sparc64-ieee1275.rmk: likewise
4422 * conf/x86_64-ieee1275.rmk: likewise
4424 2009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
4426 Support for mtime and further expandability of dir command
4428 * include/grub/lib/datetime.h: moved to ...
4429 * include/grub/datetime.h: ... moved here and added
4430 declaration of grub_unixtime2datetime. All users updated
4431 * include/grub/fs.h: new syntax for dir and mtime functions in
4433 * include/grub/fshelp.h: new declarations of GRUB_FSHELP_TYPE_MASK
4434 and GRUB_FSHELP_FLAGS_MASK
4435 * commands/ls.c (grub_ls_list_files): Write mtime in long format
4436 * fs/ext2.c (grub_ext2_dir): use new dir syntax and supply mtime
4437 (grub_ext2_mtime): new function
4438 * fs/hfsplus.c (grub_hfsplus_dir): use new dir syntax and supply mtime
4439 (grub_hfsplus_mtime): new function
4440 * fs/ufs.c (GRUB_UFS_ATTR_TYPE): new definition
4441 (GRUB_UFS_ATTR_FILE): likewise
4442 (GRUB_UFS_ATTR_LNK): likewise
4443 (struct grub_ufs_sblock): new fields mtime
4444 (grub_ufs_read_inode): new parameter to read inode to a separate buffer
4446 (grub_ufs_dir): mtime support
4447 (grub_ufs_mtime): new function
4448 * fs/affs.c (grub_affs_dir): use new dir syntax
4449 * fs/afs.c (grub_afs_dir): likewise
4450 * fs/cpio.c (grub_cpio_dir): likewise
4451 * fs/fat.c (grub_fat_find_dir): likewise
4452 * fs/hfs.c (grub_hfs_dir): likewise
4453 * fs/iso9660.c (grub_iso9660_dir): likewise
4454 * fs/jfs.c (grub_jfs_dir): likewise
4455 * fs/minix.c (grub_minix_dir): likewise
4456 * fs/ntfs.c (grub_ntfs_dir): likewise
4457 * fs/reiserfs.c (grub_reiserfs_dir): likewise
4458 * fs/sfs.c (grub_sfs_dir): likewise
4459 * fs/xfs.c (grub_xfs_dir): likewise
4460 * util/hostfs.c (grub_hostfs_dir): likewise
4461 * lib/datetime.c: moved to ...
4462 * normal/datetime.c: ... moved here
4463 (grub_unixtime2datetime): new function
4464 * kern/rescue.c (grub_rescue_print_files): use new dir syntax
4465 * normal/completion.c (iterate_dir): use new dir syntax
4466 * normal/misc.c (grub_normal_print_device_info): tell the
4467 last modification time of a volume
4468 * kern/fs.c (grub_fs_probe): updated dummy function to use new syntax
4469 * conf/common.rmk: added lib/datetime.c to ls.mod
4470 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add normal/datetime.c
4471 (normal_mod_SOURCES): likewise
4472 (datetime_mod_SOURCES): Removed lib/datetime.c
4473 * conf/i386-efi.rmk: likewise
4474 * conf/i386-ieee1275.rmk: likewise
4475 * conf/i386-pc.rmk: likewise
4476 * conf/powerpc-ieee1275.rmk: likewise
4477 * conf/sparc64-ieee1275.rmk: likewise
4478 * conf/x86_64-efi.rmk: likewise
4480 2009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
4482 Trim trailing spaces in FAT label and support mtools-like labels
4484 * fs/fat.c (grub_fat_iterate_dir): New function based
4485 on grub_fat_find_dir
4486 (grub_fat_find_dir): use grub_fat_iterate_dir
4487 (grub_fat_label): likewise
4489 2009-04-04 Vladimir Serbinenko <phcoder@gmail.com>
4491 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): add list.h
4493 remove extraneous kernel_elf_HEADERS
4495 2009-04-04 Bean <bean123ch@gnail.com>
4497 * include/grub/util/misc.h: Add dummy function fsync for mingw.
4499 * util/misc.c: Likewise.
4501 2009-04-04 Yoshinori K. Okuji <okuji@enbug.org>
4503 * loader/i386/efi/linux.c (fake_bios_data): Use grub_dprintf
4504 instead of grub_printf.
4506 2009-04-03 Robert Millan <rmh@aybabtu.com>
4508 * loader/i386/linux.c (grub_linux_setup_video): Fill
4509 `params->{red,green,blue,reserved}_{mask_size,field_pos}' with
4510 values from `mode info' structure instead of hardcoded
4513 2009-04-01 Pavel Roskin <proski@gnu.org>
4515 * Makefile.in: Remove all references to MODULE_LDFLAGS, it's
4517 * genmk.rb: Likewise.
4518 * configure.ac: Likewise.
4520 2009-04-01 Manoel Abranches <mrabran@linux.vnet.ibm.com>
4522 * aclocal.m4: Move --build-id=none from MODULE_LDFLAGS to
4523 TARGET_LDFLAGS. This corrects a problem with grub-mkelfimage.
4525 2009-04-01 David S. Miller <davem@davemloft.net>
4527 * normal/sparc64/setjmp.S: Fix setjmp implementation.
4528 * include/grub/sparc64/setjmp.h (grub_jmp_buf): Update.
4529 (grub_setjmp): Mark with 'returns_twice' attribute.
4530 * include/grub/i386/setjmp.h (grub_setjmp): Likewise
4531 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise.
4532 * include/grub/x86_64/setjmp.h (grub_setjmp): Likewise.
4534 2009-04-01 Robert Millan <rmh@aybabtu.com>
4536 Reapply fix from 2008-07-28 which was accidentally reverted; also
4537 perform the same fix to a similar check in same function.
4539 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
4540 with the same number are found, just use issue a warning with
4541 grub_dprintf(), as this error has been reported to be non-fatal.
4543 2009-03-31 Pavel Roskin <proski@gnu.org>
4545 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Provide safe default
4546 for cross-compilation.
4548 2009-03-30 Robert Millan <rmh@aybabtu.com>
4550 Fix i386-ieee1275 build.
4552 * include/grub/i386/ieee1275/loader.h (grub_multiboot2_real_boot):
4555 2009-03-30 Pavel Roskin <proski@gnu.org>
4557 * fs/hfs.c (grub_hfs_strncasecmp): Integrate into ...
4558 (grub_hfs_cmp_catkeys): ... this. Don't assume strings to be
4559 zero-terminated, rely only on the strlen value. Fix comparison
4560 of strings differing in length.
4562 2009-03-30 Robert Millan <rmh@aybabtu.com>
4564 * loader/i386/linux.c (grub_cmd_linux): Check for zImage before
4565 checking for abi version. Improve error messages on BIOS to notify
4566 user about `linux16' command.
4568 2009-03-29 Vladimir Serbinenko <phcoder@gmail.com>
4572 * kern/disk.c (grub_disk_cache_store): Invalidate previous cache
4573 in case of collision
4574 * disk/scsi.c (grub_scsi_open): free scsi in case of error
4576 2009-03-29 Robert Millan <rmh@aybabtu.com>
4578 * loader/i386/linux.c (grub_cmd_linux): Parse "vga=" parameter and
4579 set `vid_mode' accordingly.
4580 (grub_linux_boot): Process `vid_mode' and set video mode.
4582 2009-03-29 Robert Millan <rmh@aybabtu.com>
4584 * util/grub.d/10_linux.in (linux_entry): New function.
4585 Factorize generation of Linux boot entries.
4587 2009-03-29 Yoshinori K. Okuji <okuji@enbug.org>
4589 Make the format of Environment Block plain text. The boot loader
4590 part is not tested well yet.
4592 * util/grub-editenv.c (DEFAULT_ENVBLK_SIZE): New macro.
4595 (usage): Remove "info" and "clear". Add "unset". Update the
4596 description of "set", as this does not delete variables any
4598 (create_envblk_file): Complete rewrite.
4599 (open_envblk_file): Likewise.
4600 (cmd_info): Removed.
4601 (cmd_list): Likewise.
4602 (cmd_set): Likewise.
4603 (cmd_clear): Likewise.
4604 (list_variables): New function.
4605 (write_envblk): Likewise.
4606 (set_variables): Likewise.
4607 (unset_variables): Likewise.
4608 (main): Complete rewrite.
4610 * commands/loadenv.c (buffer): Removed.
4612 (open_envblk_file): New function.
4613 (read_envblk_file): Complete rewrite.
4614 (grub_cmd_load_env): Likewise.
4615 (grub_cmd_list_env): Likewise.
4616 (struct blocklist): New struct.
4617 (free_blocklists): New function.
4618 (check_blocklists): Likewise.
4619 (write_blocklists): Likewise.
4620 (grub_cmd_save_env): Complete rewrite.
4622 * include/grub/lib/envblk.h (GRUB_ENVBLK_SIGNATURE): Replaced with
4623 a plain text signature.
4624 (GRUB_ENVBLK_MAXLEN): Removed.
4625 (struct grub_envblk): Complete rewrite.
4626 (grub_envblk_find): Removed.
4627 (grub_envblk_insert): Likewise.
4628 (grub_envblk_open): New prototype.
4629 (grub_envblk_set): Likewise.
4630 (grub_envblk_delete): Put const to VALUE.
4631 (grub_envblk_iterate): Put const to NAME and VALUE.
4632 (grub_envblk_close): New prototype.
4633 (grub_envblk_buffer): New inline function.
4634 (grub_envblk_size): Likewise.
4636 * lib/envblk.c: Include grub/mm.h.
4637 (grub_env_find): Removed.
4638 (grub_envblk_open): New function.
4639 (grub_envblk_close): Likewise.
4640 (escaped_value_len): Likewise.
4641 (find_next_line): Likewise.
4642 (grub_envblk_insert): Removed.
4643 (grub_envblk_set): New function.
4644 (grub_envblk_delete): Complete rewrite.
4645 (grub_envblk_iterate): Likewise.
4647 2009-03-28 Robert Millan <rmh@aybabtu.com>
4649 * conf/i386-pc.rmk (pkglib_MODULES): Add `linux16.mod'.
4650 (linux16_mod_SOURCES, linux16_mod_CFLAGS, linux16_mod_LDFLAGS): New
4651 variables. Use 16-bit loader.
4652 (linux_mod_SOURCES, linux_mod_CFLAGS, linux_mod_LDFLAGS): Use 32-bit
4654 * kern/i386/loader.S (grub_linux_boot): Rename to ...
4655 (grub_linux16_boot): ... this. Update all users.
4656 * loader/i386/linux.c (grub_linux32_boot): Rename to ...
4657 (grub_linux_boot): ... this. Update all users.
4659 * loader/i386/pc/linux.c (GRUB_MOD_INIT(linux)): Rename to ...
4660 (GRUB_MOD_INIT(linux16)): ... this. Rename `linux' and `initrd'
4661 commands to `linux16' and `initrd16'.
4662 (GRUB_MOD_FINI(linux)): Rename to ...
4663 (GRUB_MOD_FINI(linux16)): ... this.
4665 2009-03-24 Pavel Roskin <proski@gnu.org>
4667 * genmk.rb: Define ASM_FILE for *.S files for *.lst generation,
4668 not just for compilation.
4670 2009-03-22 Vladimir Serbinenko <phcoder@gmail.com>
4672 Move multiboot helper out of kernel
4674 * conf/i386-pc.rmk (multiboot_mod_SOURCES): Add
4675 `loader/i386/multiboot_helper.S'.
4676 * conf/i386-coreboot.rmk: Likewise
4677 * conf/i386-ieee1275.rmk: Likewise
4679 * kern/i386/loader.S: Move multiboot helpers from here...
4680 * loader/i386/multiboot_helper.S: ...moved here
4681 * include/grub/i386/loader.h: Move declarations of multiboot
4682 helpers from here...
4683 * include/grub/i386/multiboot.h: ...moved here
4684 * loader/i386/multiboot.c: Added include of grub/cpu/multiboot.h
4686 2009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
4688 * kern/env.c (grub_env_context_open): Added an argument to specify
4689 whether a new context inherits exported variables from current
4690 one. This is useful when making a sandbox to interpret a config
4692 All callers updated.
4694 * include/grub/env.h (grub_env_context_open): Updated the prototype.
4696 2009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
4698 * kern/env.c (grub_env_context_close): Fix memory leaks.
4700 2009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
4702 * normal/main.c (grub_normal_execute): Added an argument
4703 BATCH to specify if an interactive interface should be provided
4704 after reading a config file.
4705 All callers updated.
4706 (read_command_list): Prevent being executed twice.
4707 (read_fs_list): Likewise.
4709 * include/grub/normal.h (grub_normal_execute): Updated the
4712 2009-03-22 Pavel Roskin <proski@gno.org>
4714 * kern/powerpc/ieee1275/startup.S: Replace EXT_C(start) with
4716 * kern/i386/pc/startup.S: Likewise.
4717 * kern/i386/efi/startup.S: Likewise.
4718 * kern/i386/ieee1275/startup.S: Likewise.
4719 * kern/i386/coreboot/startup.S: Likewise.
4720 * kern/x86_64/efi/startup.S: Likewise.
4722 * aclocal.m4 (grub_CHECK_START_SYMBOL): Remove.
4723 * configure.ac: Don't call grub_CHECK_START_SYMBOL.
4724 * kern/i386/pc/startup.S: Use _start instead of START_SYMBOL.
4726 2009-03-21 Vladimir Serbinenko <phcoder@gmail.com>
4728 Bugfixes in multiboot for bugs uncovered by solaris kernel.
4730 * loader/i386/multiboot_elfxx.c (grub_multiboot_load_elf): Corrected
4732 Use vaddr of correct segment for entry_point.
4734 2009-03-21 Bean <bean123ch@gmail.com>
4736 * commands/blocklist.c: Add include file <grub/command.h>, remove
4737 <grub/normal.h> and <grub/arg.h>.
4738 (grub_cmd_blocklist): Use the new command interface.
4739 (GRUB_MOD_INIT): Likewise.
4740 (GRUB_MOD_FINI): Likewise.
4741 * commands/boot.c: Likewise.
4742 * commands/cat.c: Likewise.
4743 * commands/cmp.c: Likewise.
4744 * commands/configfile.c: Likewise.
4745 * commands/crc.c: Likewise.
4746 * commands/echo.c: Likewise.
4747 * commands/halt.c: Likewise.
4748 * commands/handler.c: Likewise.
4749 * commands/hdparm.c: Likewise.
4750 * commands/help.c: Likewise.
4751 * commands/hexdump.c: Likewise.
4752 * commands/loadenv.c: Likewise.
4753 * commands/ls.c: Likewise.
4754 * commands/lsmmap.c: Likewise.
4755 * commands/lspci.c: Likewise.
4756 * commands/loadenv.c: Likewise.
4757 * commands/read.c: Likewise.
4758 * commands/reboot.c: Likewise.
4759 * commands/search.c: Likewise.
4760 * commands/sleep.c: Likewise.
4761 * commands/test.c: Likewise.
4762 * commands/usbtest.c: Likewise.
4763 * commands/videotest.c: Likewise.
4764 * commands/i386/cpuid.c: Likewise.
4765 * commands/i386/pc/halt.c: Likewise.
4766 * commands/i386/pc/play.c: Likewise.
4767 * commands/i386/pc/pxecmd.c: Likewise.
4768 * commands/i386/pc/vbeinfo.c: Likewise.
4769 * commands/i386/pc/vbetest.c: Likewise.
4770 * commands/ieee1275/suspend.c: Likewise.
4771 * disk/loopback.c: Likewise.
4772 * font/font_cmd.c: Likewise.
4773 * hello/hello.c: Likewise.
4774 * loader/efi/appleloader.c: Likewise.
4775 * loader/efi/chainloader.c: Likewise.
4776 * loader/i386/bsd.c: Likewise.
4777 * loader/i386/efi/linux.c: Likewise.
4778 * loader/i386/ieee1275/linux.c: Likewise.
4779 * loader/i386/linux.c: Likewise.
4780 * loader/i386/pc/chainloader.c: Likewise.
4781 * loader/i386/pc/linux.c: Likewise.
4782 * loader/powerpc/ieee1275/linux.c: Likewise.
4783 * loader/multiboot_loader.c: Likewise.
4784 * term/gfxterm.c: Likewise.
4785 * term/i386/pc/serial.c: Likewise.
4786 * term/terminfo.c: Likewise.
4788 * term/i386/pc/vesafb.c: Removed <grub/arg.h>.
4789 * term/i386/pc/vga.c: Likewise.
4790 * video/readers/jpeg.c: Likewise.
4791 * video/readers/png.c: Likewise.
4792 * video/readers/tga.c: Likewise.
4794 * util/grub-fstest (cmd_loopback): Removed.
4795 (cmd_blocklist): Likewise.
4797 (grub_register_command): Likewise.
4798 (grub_unregister_command): Likewise.
4799 (execute_command): Use grub_command_find to locate command and execute
4802 * include/grub/efi/chainloader.h: Removed.
4803 * loader/efi/chainloader_normal.c: Likewise.
4804 * loader/i386/bsd_normal.c: Likewise.
4805 * loader/i386/pc/chainloader_normal.c: Likewise.
4806 * loader/i386/pc/multiboot_normal.c: Likewise.
4807 * loader/linux_normal.c: Likewise.
4808 * loader/multiboot_loader_normal.c: Likewise.
4809 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
4811 * gencmdlist.sh: Scan new registration command grub_register_extcmd
4812 and grub_register_command_p1.
4814 * conf/common.rmk (grub_fstest_SOURCES): Add kern/list.c,
4815 kern/command.c, lib/arg.c and commands/extcmd.c.
4816 (pkglib_MODULES): Remove boot.mod, and minicmd.mod and extcmd.mod.
4817 (minicmd_mod_SOURCES): New variable.
4818 (minicmd_mod_CFLAGS): Likewise.
4819 (minicmd_mod_LDFLAGS): Likewise.
4820 (extcmd_mod_SOURCES): Likewise.
4821 (extcmd_mod_CFLAGS): Likewise.
4822 (extcmd_mod_LDFLAGS): Likewise.
4823 (boot_mod_SOURCES): Removed.
4824 (boot_mod_CFLAGS): Likewise.
4825 (boot_mod_LDFLAGS): Likewise.
4827 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/command.c and
4829 (kernel_img_HEADERS): Add command.h.
4830 (grub_emu_SOURCES): Remove commands/boot.c and normal/arg.c, add
4831 commands/minicmd.c, kern/command.c, kern/corecmd.c, commands/extcmd.c
4833 (pkglib_MODULES): Change _linux.mod, _chain.mod, _bsd.mod and
4834 _multiboot.mod as linux.mod, chain.mod, bsd.mod and multiboot.mod,
4835 remove the corresponding normal mode command.
4836 (normal_mod_SOURCES): Remove normal/arg.c.
4837 * conf/i386-coreboot.rmk: Likewise.
4838 * conf/i386-efi.rmk: Likewise.
4839 * conf/i386-ieee1275.rmk: Likewise.
4840 * conf/powerpc-ieee1275.rmk: Likewise.
4841 * conf/x86_64-efi.rmk: Likewise.
4843 * include/grub/arg.h: Move from here ...
4844 * include/grub/lib/arg.h: ... to here.
4846 * normal/arg.c: Move from here ...
4847 * lib/arg.c: ... to here.
4849 * commands/extcmd.c: New file.
4850 * commands/minicmd.c: Likewise.
4851 * include/grub/command.h: Likewise.
4852 * include/grub/extcmd.h: Likewise.
4853 * kern/command.c: Likewise.
4854 * kern/corecmd.c: Likewise.
4856 * kern/list.c (grub_list_iterate): Return int instead of void.
4857 (grub_list_insert): New function.
4858 (grub_prio_list_insert): Likewise.
4860 * kern/rescue.c (grub_rescue_command): Removed.
4861 (grub_rescue_command_list): Likewise.
4862 (grub_rescue_register_command): Likewise.
4863 (grub_rescue_unregister_command): Likewise.
4864 (grub_rescue_cmd_boot): Move to minicmd.c
4865 (grub_rescue_cmd_help): Likewise.
4866 (grub_rescue_cmd_info): Likewise.
4867 (grub_rescue_cmd_boot): Likewise.
4868 (grub_rescue_cmd_testload): Likewise.
4869 (grub_rescue_cmd_dump): Likewise.
4870 (grub_rescue_cmd_rmmod): Likewise.
4871 (grub_rescue_cmd_lsmod): Likewise.
4872 (grub_rescue_cmd_exit): Likewise.
4873 (grub_rescue_print_devices): Moved to corecmd.c.
4874 (grub_rescue_print_files): Likewise.
4875 (grub_rescue_cmd_ls): Likewise.
4876 (grub_rescue_cmd_insmod): Likewise.
4877 (grub_rescue_cmd_set): Likewise.
4878 (grub_rescue_cmd_unset): Likewise.
4879 (attempt_normal_mode): Use grub_command_find to get normal module.
4880 (grub_enter_rescue_mode): Use grub_register_core_commands to register
4881 commands, remove grub_rescue_register_command calls.
4883 * normal/command.c (grub_register_command): Removed.
4884 (grub_unregister_command): Likewise.
4885 (grub_command_find): Likewise.
4886 (grub_iterate_commands): Likewise.
4887 (rescue_command): Likewise.
4888 (export_command): Moved to corecmd.c.
4889 (set_command): Removed.
4890 (unset_command): Likewise.
4891 (insmod_command): Likewise.
4892 (rmmod_command): Likewise.
4893 (lsmod_command): Likewise.
4894 (grub_command_init): Likewise.
4896 * normal/completion.c (iterate_command): Use cmd->prio to check for
4898 (complete_arguments): Use grub_extcmd_t structure to find options.
4899 (grub_normal_do_completion): Change function grub_iterate_commands to
4900 grub_command_iterate.
4902 * normal/execute.c (grub_script_execute_cmd): No need to parse
4905 * normal/main.c (grub_dyncmd_dispatcher): New function.
4906 (read_command_list): Register unload commands as dyncmd.
4907 (grub_cmd_normal): Use new command interface, register rescue,
4908 unregister normal at entry, register normal, unregister rescue at exit.
4910 * include/grub/list.h (grub_list_test_t): New type.
4911 (grub_list_iterate): Return int instead of void.
4912 (grub_list_insert): New function.
4913 (GRUB_AS_NAMED_LIST_P): New macro.
4914 (GRUB_AS_PRIO_LIST): Likewise.
4915 (GRUB_AS_PRIO_LIST_P): Likewise.
4916 (GRUB_PRIO_LIST_PRIO_MASK): New constant.
4917 (GRUB_PRIO_LIST_FLAG_ACTIVE): Likewise.
4918 (grub_prio_list): New structure.
4919 (grub_prio_list_insert): New function.
4920 (grub_prio_list_remove): New inline function.
4922 * include/grub/normal.h: Remove <grub/arg.h>, add <grub/command.h>.
4923 (GRUB_COMMAND_FLAG_CMDLINE): Moved to command.h.
4924 (GRUB_COMMAND_FLAG_MENU): Likewise.
4925 (GRUB_COMMAND_FLAG_BOTH): Likewise.
4926 (GRUB_COMMAND_FLAG_TITLE): Likewise.
4927 (GRUB_COMMAND_FLAG_NO_ECHO): Likewise.
4928 (GRUB_COMMAND_FLAG_NO_ARG_PARSE): Removed.
4929 (GRUB_COMMAND_FLAG_NOT_LOADED): Likewise.
4930 (grub_command): Likewise.
4931 (grub_register_command): Likewise.
4932 (grub_command_find): Likewise.
4933 (grub_iterate_commands): Likewise.
4934 (grub_command_init): Likewise.
4935 (grub_arg_parse): Likewise.
4936 (grub_arg_show_help): Likewise.
4938 * include/grub/rescue.h (grub_rescue_register_command): Removed.
4939 (grub_rescue_unregister_command): Likewise.
4941 * include/grub/i386/bsd.h: Remove grub_rescue_cmd_freebsd,
4942 grub_rescue_cmd_openbsd, grub_rescue_cmd_netbsd,
4943 grub_rescue_cmd_freebsd_loadenv and grub_rescue_cmd_freebsd_module.
4945 * include/grub/i386/efi/loader.h: Remove grub_rescue_cmd_linux and
4946 grub_rescue_cmd_initrd.
4947 * include/grub/i386/loader.h: Likewise.
4948 * include/grub/x86_64/loader.h: Likewise.
4950 * include/grub/i386/pc/chainloader.h: Remove grub_chainloader_cmd.
4952 2009-03-21 Bean <bean123ch@gmail.com>
4954 * util/hostdisk.c (read_device_map): Use grub_util_get_disk_size
4955 instead of stat in mingw environment.
4957 * util/misc.c (grub_millisleep): Use Sleep in mingw environment.
4959 * aclocal.m4 (grub_CHECK_LINK_DIR): New function.
4961 * configure.ac: Use grub_CHECK_LINK_DIR to determine whether to use
4964 2009-03-21 Bean <bean123ch@gmail.com>
4966 * fs/ext2.c (grub_ext2_mount): Change errno to GRUB_ERR_BAD_FS for
4969 2009-03-18 Michel Dänzer <michel@daenzer.net>
4971 * fs/ext2.c (grub_ext2_read_block): Take endianness into account when
4972 checking inode flags for EXT4_EXTENTS_FLAG.
4974 2009-03-18 Robert Millan <rmh@aybabtu.com>
4976 * loader/i386/linux.c: Include `<grub/video.h>' and
4977 `<grub/i386/pc/vbe.h>'..
4978 (grub_linux_setup_video): New function. Loosely based on the EFI one.
4979 (grub_linux32_boot): Attempt to configure video settings with
4980 grub_linux_setup_video().
4981 (grub_rescue_cmd_linux): Set noreturn=0 in grub_loader_set, in order
4982 to avoid grub_console_fini() which would step out of graphical mode
4985 2009-03-14 Robert Millan <rmh@aybabtu.com>
4987 Fix build on powerpc.
4988 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Add `handler.h'.
4990 2009-03-12 Vladimir Serbinenko <phcoder@gmail.com>
4992 * term/gfxterm.c (GRUB_MOD_FINI(term_gfxterm)): Correct name of
4993 background image command.
4995 2009-03-12 Colin D Bennett <colin@gibibit.com>
4997 * term/gfxterm.c (draw_cursor): Ensure character is redrawn.
4998 (grub_gfxterm_putchar): Extract pairs of identical calls to
4999 draw_cursor out of conditional blocks.
5001 2009-03-11 Pavel Roskin <proski@gnu.org>
5003 * fs/hfs.c (grub_hfs_strncasecmp): New function.
5004 (grub_hfs_cmp_catkeys): Use HFS specific string comparison.
5006 2009-03-11 Robert Millan <rmh@aybabtu.com>
5008 * loader/i386/multiboot_elfxx.c
5009 (CONCAT(grub_multiboot_load_elf, XX)): Do not reject ET_DYN files.
5011 2009-03-11 Felix Zielcke <fzielcke@z-51.de>
5013 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add `kern/list.c' and
5016 2009-03-11 Robert Millan <rmh@aybabtu.com>
5018 * loader/i386/multiboot.c (code_size): New variable.
5019 (grub_multiboot): Define offsets by adding to `code_size' rather
5020 than subtracting from `grub_multiboot_payload_size'. Provide
5021 4-byte alignment to MBI and others by increasing
5022 `boot_loader_name_length' appropriately.
5024 * loader/i386/multiboot_elfxx.c
5025 (CONCAT(grub_multiboot_load_elf, XX)): Initialize `code_size'.
5027 2009-03-09 Felix Zielcke <fzielcke@z-51.de>
5029 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove duplicated
5032 2009-03-08 Robert Millan <rmh@aybabtu.com>
5034 Make loader/i386/linux.c usable on i386-pc again.
5036 * kern/i386/pc/init.c (grub_machine_init): Disable addition of low
5038 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS] (allocate_pages): Remove
5041 2009-03-07 Bean <bean123ch@gmail.com>
5043 * loader/i386/efi/linux.c (grub_rescue_cmd_initrd): Fix a bug in initrd
5046 2009-03-06 Robert Millan <rmh@aybabtu.com>
5048 Fix display issue on terminals with screen size other than 80x25
5049 (e.g. gfxterm with resolution higher than 640x480).
5051 * normal/main.c (grub_normal_init_page): Display title text in a
5052 position relative to the center of the terminal instead of relying
5053 on a hardcoded offset.
5055 2009-03-04 Robert Millan <rmh@aybabtu.com>
5057 Filter /etc/grub.d/10_* so that only add-ons for native kernels are
5060 * Makefile.in (host_kernel): New variable.
5061 * conf/common.rmk (grub-mkconfig_SCRIPTS): Conditionalize all 10_*.in
5062 scripts instead of just the windows one.
5063 * configure.ac: Initialize and AC_SUBST `host_kernel'.
5065 2009-03-04 Felix Zielcke <fzielcke@z-51.de>
5067 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `kern/list.c' and
5069 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
5070 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
5071 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
5072 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5073 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5074 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5076 2009-03-04 Felix Zielcke <fzielcke@z-51.de>
5078 * partmap/pc.c (pc_partition_map_iterate): Skip over invalid BSD partitions
5079 or if there's no space for the disk label and print the partition number on a
5082 2009-03-04 Felix Zielcke <fzielcke@z-51.de>
5084 * util/misc.c: Include <time.h>.
5085 (grub_millisleep): New function.
5087 2009-03-04 Bean <bean123ch@gmail.com>
5089 * configure.ac: Only test -mcmodel=large option in x86_64-efi, also add
5090 another option -mno-red-zone.
5092 * commands/handler.c: Change module description.
5094 * kern/handler.c: Add missing space at the end of description line.
5096 * kern/list.c: Likewise.
5098 2009-03-03 Robert Millan <rmh@aybabtu.com>
5100 Move more components to the relocation area, and fix mbi pointer
5101 handling to use the destination rather than the origin (thanks to
5102 Vladimir Serbinenko for spotting).
5104 * loader/i386/multiboot.c (mbi_dest): New variable.
5105 (grub_multiboot_boot): Use `mbi_dest' instead of `mbi'.
5106 (grub_multiboot): Put cmdline, boot_loader_name and mbi in the
5109 2009-03-01 Bean <bean123ch@gmail.com>
5111 * include/grub/efi/api.h (GRUB_EFI_MPS_TABLE_GUID): New constant.
5112 (GRUB_EFI_ACPI_TABLE_GUID): Likewise.
5113 (GRUB_EFI_ACPI_20_TABLE_GUID): Likewise.
5114 (GRUB_EFI_SMBIOS_TABLE_GUID): Likewise.
5116 * loader/i386/efi/linux.c (acpi_guid): New variable.
5117 (acpi_guid): Likewise.
5118 (EBDA_SEG_ADDR): New constant.
5119 (LOW_MEM_ADDR): Likewise.
5120 (FAKE_EBDA_SEG): Likewise.
5121 (fake_bios_data): New function.
5122 (grub_linux_boot): Call fake_bios_data.
5124 2009-03-01 Bean <bean123ch@gmail.com>
5126 * commands/terminal.c: Removed.
5128 * commands/handler.c: New file.
5130 * include/grub/list.h: Likewise.
5132 * include/grub/handler.h: Likewise.
5134 * kern/list.c: Likewise.
5136 * kern/handler.c: Likewise.
5138 * kern/term.h: Include header file <grub/handler.h>.
5139 (grub_term_input): Move next field to the beginning.
5140 (grub_term_output): Likewise.
5141 (grub_term_input_class): New variable.
5142 (grub_term_output_class): Likewise.
5143 (grub_term_register_input): Changed to inline function.
5144 (grub_term_register_output): Likewise.
5145 (grub_term_unregister_input): Likewise.
5146 (grub_term_unregister_output): Likewise.
5147 (grub_term_set_current_input): Likewise.
5148 (grub_term_set_current_output): Likewise.
5149 (grub_term_get_current_input): Likewise.
5150 (grub_term_get_current_output): Likewise.
5151 (grub_term_iterate_input): Removed.
5152 (grub_term_iterate_output): Likewise.
5154 * kern/term.c (grub_term_list_input): Removed.
5155 (grub_term_list_output): Likewise.
5156 (grub_term_input_class): New variable.
5157 (grub_term_output_class): Likewise.
5158 (grub_cur_term_input): Change variable as macro.
5159 (grub_cur_term_output): Likewise.
5160 (grub_term_register_input): Removed.
5161 (grub_term_register_output): Likewise.
5162 (grub_term_unregister_input): Likewise.
5163 (grub_term_unregister_output): Likewise.
5164 (grub_term_set_current_input): Likewise.
5165 (grub_term_set_current_output): Likewise.
5166 (grub_term_iterate_input): Likewise.
5167 (grub_term_iterate_output): Likewise.
5168 (grub_term_get_current_input): Likewise.
5169 (grub_term_get_current_output): Likewise.
5171 * util/grub-editenv.c: Include header file <grub/handler.h>.
5172 (grub_term_get_current_input): Removed.
5173 (grub_term_get_current_output): Likewise.
5174 (grub_term_input_class): New variable.
5175 (grub_term_output_class): Likewise.
5177 * util/grub-fstest.c (grub_term_get_current_input): Removed.
5178 (grub_term_get_current_output): Likewise.
5179 (grub_term_input_class): New variable.
5180 (grub_term_output_class): Likewise.
5182 * util/grub-probe.c (grub_term_get_current_input): Removed.
5183 (grub_term_get_current_output): Likewise.
5184 (grub_term_input_class): New variable.
5185 (grub_term_output_class): Likewise.
5187 * util/i386/pc/grub-setup.c (grub_term_get_current_input): Removed.
5188 (grub_term_get_current_output): Likewise.
5189 (grub_term_input_class): New variable.
5190 (grub_term_output_class): Likewise.
5192 * conf/common.rmk (pkglib_MODULES): Replace terminal with handler.
5193 (terminal_mod_SOURCES): Likewise.
5194 (terminal_mod_CFLAGS): Likewise.
5195 (terminal_mod_LDFLAGS): Likewise.
5197 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace terminal.c with
5199 (kernel_img_SOURCES): Add list.c and handler.c.
5200 (kernel_img_HEADERS): Add list.h and handler.h.
5202 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
5204 (kernel_mod_SOURCES): Add list.c and handler.c.
5205 (kernel_mod_HEADERS): Add list.h and handler.h.
5207 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Replace terminal.c with
5209 (kernel_elf_SOURCES): Add list.c and handler.c.
5210 (kernel_elf_HEADERS): Add list.h and handler.h.
5212 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
5214 (kernel_elf_SOURCES): Add list.c and handler.c.
5215 (kernel_elf_HEADERS): Add list.h and handler.h.
5217 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
5219 (kernel_mod_SOURCES): Add list.c and handler.c.
5220 (kernel_mod_HEADERS): Add list.h and handler.h.
5222 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
5224 (kernel_elf_SOURCES): Add list.c and handler.c.
5225 (kernel_elf_HEADERS): Add list.h and handler.h.
5227 2009-02-27 Robert Millan <rmh@aybabtu.com>
5229 Factorize elf32 / elf64 code in Multiboot loader. This will
5230 prevent it from getting out of sync again.
5232 * loader/i386/multiboot.c (grub_multiboot_is_elf32,
5233 grub_multiboot_load_elf32, grub_multiboot_is_elf64,
5234 grub_multiboot_load_elf64): Move from here ...
5235 * loader/i386/multiboot_elfxx.c (grub_multiboot_is_elf,
5236 grub_multiboot_load_elf): ... to here (new file).
5238 2009-02-27 Robert Millan <rmh@aybabtu.com>
5240 * util/grub.d/10_linux.in: Rename "single-user mode" to
5243 2009-02-27 Vladimir Serbinenko <phcoder@gmail.com>
5245 Don't leak in SCSI code.
5246 * disk/scsi.c (grub_scsi_close): free `scsi'.
5248 2009-02-27 Robert Millan <rmh@aybabtu.com>
5250 * loader/i386/pc/multiboot.c: Move from here ...
5251 * loader/i386/multiboot.c: ... to here. Update all users.
5253 2009-02-27 Robert Millan <rmh@aybabtu.com>
5255 Patch from Alexandre Bique <bique.alexandre@gmail.com>
5256 * util/i386/pc/grub-setup.c (setup): Fix directory path.
5258 2009-02-27 Krzysztof Smiechowicz <deadwood@wp.pl>
5260 * fs/sfs.c (grub_sfs_read_extent): Correction to traversing extent
5263 2009-02-27 Robert Millan <rmh@aybabtu.com>
5265 * kern/misc.c (grub_strtoull): Fix bug (it mistakenly parsed the
5266 `0x' qualifier as 0 when base is specified as parameter).
5268 2009-02-24 Bean <bean123ch@gmail.com>
5270 * configure.ac: Check for -mcmodel=large in x86_64 target.
5272 * include/grub/efi/api.h (efi_call_10): New macro.
5273 (efi_wrap_10): New function.
5275 * include/grub/efi/pe32.h (GRUB_PE32_REL_BASE_HIGH): New macro.
5276 (GRUB_PE32_REL_BASED_HIGH): Likewise.
5277 (GRUB_PE32_REL_BASED_LOW): Likewise.
5278 (GRUB_PE32_REL_BASED_HIGHLOW): Likewise.
5279 (GRUB_PE32_REL_BASED_HIGHADJ): Likewise.
5280 (GRUB_PE32_REL_BASED_MIPS_JMPADDR): Likewise.
5281 (GRUB_PE32_REL_BASED_SECTION): Likewise.
5282 (GRUB_PE32_REL_BASED_REL): Likewise.
5283 (GRUB_PE32_REL_BASED_IA64_IMM64): Likewise.
5284 (GRUB_PE32_REL_BASED_DIR64): Likewise.
5285 (GRUB_PE32_REL_BASED_HIGH3ADJ): Likewise.
5287 * kern/x86_64/dl.c (grub_arch_dl_relocate_symbols): Fixed relocation
5290 * kern/x86_64/efi/callwrap.S (efi_wrap_6): Bug fix.
5291 (efi_wrap_10): New function.
5293 * kern/x86_64/efi/startup.S (codestart): Use relative addressing.
5295 * loader/efi/appleloader.c (devpath_5): Add support for late 2008
5296 MB/MBP model (NV chipset).
5297 (devdata_devs): Add devpath_5 to the list.
5299 * load/i386/efi/linux.c (video_base): Remove variable.
5300 (RGB_MASK): New macro.
5301 (RGB_MAGIC): Likewise.
5302 (LINE_MIN): Likewise.
5303 (LINE_MAX): Likewise.
5304 (FBTEST_STEP): Likewise.
5305 (FBTEST_COUNT): Likewise.
5306 (fb_list): New variable.
5307 (grub_find_video_card): Remove function.
5308 (find_framebuf): New function.
5309 (grub_linux_setup_video): Use find_framebuf to get frame buffer and
5312 * util/i386/efi/grub-mkimage.c (grub_reloc_section): Fix relocation
5315 2009-02-22 Vesa Jääskeläinen <chaac@nic.fi>
5317 Patch #25624 by Kevin Lacquement <kevin@lacqui>.
5319 * util/grub-mkconfig.in: Use ${grub_mkdevicemap} instead of hard
5322 2009-02-22 Robert Millan <rmh@aybabtu.com>
5324 * include/multiboot.h (MULTIBOOT_INFO_ALIGN): New macro.
5325 * loader/i386/pc/multiboot.c (grub_multiboot): Include the MBI
5326 in our relocation, instead of using it directly from heap. Also
5327 use `MULTIBOOT_INFO_ALIGN' to ensure it is aligned.
5329 2009-02-21 Robert Millan <rmh@aybabtu.com>
5331 Implement USB keyboard support (based on patch by Marco Gerards)
5333 * conf/i386-pc.rmk (pkglib_MODULES): Add `usb_keyboard.mod'.
5334 (usb_keyboard_mod_SOURCES, usb_keyboard_mod_CFLAGS)
5335 (usb_keyboard_mod_LDFLAGS): New variables.
5337 * term/usb_keyboard.c: New file.
5339 2009-02-14 Vladimir Serbinenko <phcoder@gmail.com>
5341 Corrected wrong declaration
5343 * kern/disk.c: corrected declaration of grub_disk_ata_pass_through.
5345 2009-02-14 Christian Franke <franke@computer.org>
5347 * commands/lspci.c (grub_pci_classes): Add `SATA Controller'.
5348 (grub_lspci_iter): Print class code and programming interface byte.
5350 2009-02-14 Christian Franke <franke@computer.org>
5352 * gendistlist.sh: Ignore `.svn' directories.
5354 2009-02-14 Felix Zielcke <fzielcke@z-51.de>
5356 * fs/fat.c: Add 2009 to Copyright line.
5358 2009-02-14 Christian Franke <franke@computer.org>
5360 * commands/hdparm.c: New file. Provides `hdparm' command
5361 which sends ATA commands via grub_disk_ata_pass_through ().
5363 * conf/i386-pc.rmk: Add ata_pthru.mod and hdparm.mod.
5365 * disk/ata.c: Include <grub/ata.h>. Move <grub/misc.h>
5366 and <grub/cpu/io.h> to include/grub/ata.h.
5367 (enum grub_ata_addressing_t): Move to include/grub/ata.h.
5368 (GRUB_CDROM_SECTOR_SIZE): Remove.
5369 (GRUB_ATA_*): Move to include/grub/ata.h.
5370 (GRUB_ATAPI_*): Likewise.
5371 (enum grub_ata_commands): Likewise.
5372 (enum grub_ata_timeout_milliseconds): Likewise.
5373 (struct grub_ata_device): Likewise.
5374 (grub_ata_regset): Likewise.
5375 (grub_ata_regget): Likewise.
5376 (grub_ata_regset2): Likewise.
5377 (grub_ata_regget2): Likewise.
5378 (grub_ata_check_ready): Likewise.
5379 (grub_ata_wait_not_busy): Remove static, exported in
5381 (grub_ata_wait_drq): Likewise.
5382 (grub_ata_pio_read): Likewise.
5384 * disk/ata_pthru.c: New file. Provides grub_ata_pass_through ()
5385 function for hdparm.mod.
5387 * include/grub/ata.h: New file, contains declarations from
5389 (enum grub_ata_commands): Add new commands for commands/hdparm.c.
5391 * include/grub/disk.h (grub_disk_ata_pass_through_parms): New struct.
5392 (grub_disk_ata_pass_through): New exported variable.
5394 * kern/disk.c (grub_disk_ata_pass_through): New variable.
5396 2009-02-13 Colin D Bennett <colin@gibibit.com>
5398 Support multiple fallback entries, and provide an API to support
5399 executing default+fallback menu entries. Renamed the `terminal' menu
5402 * include/grub/normal.h (grub_normal_text_menu_viewer): New global
5403 variable declaration.
5404 (grub_menu_execute_callback): New structure declaration.
5405 (grub_menu_execute_callback_t): New typedef.
5406 (grub_menu_execute_with_fallback): New function declaration.
5407 (grub_menu_get_entry): Likewise.
5408 (grub_menu_get_timeout): Likewise.
5409 (grub_menu_set_timeout): Likewise.
5411 * normal/main.c (GRUB_MOD_INIT(normal)): Refer to new variable name.
5413 * normal/menu.c (grub_wait_after_message): Moved to
5414 `normal/menu_text.c'.
5415 (draw_border): Likewise.
5416 (print_message): Likewise.
5417 (print_entry): Likewise.
5418 (print_entries): Likewise.
5419 (grub_menu_init_page): Likewise.
5420 (get_entry_number): Likewise.
5421 (print_timeout): Likewise.
5422 (run_menu): Likewise.
5423 (grub_menu_execute_entry): Likewise.
5424 (show_text_menu): Likewise.
5425 (get_and_remove_first_entry_number): New function.
5426 (grub_menu_execute_with_fallback): Likewise.
5427 (get_entry): Renamed to ...
5428 (grub_menu_get_entry): .. this and made it global.
5429 (get_timeout): Renamed to ...
5430 (grub_menu_get_timeout): ... this and made it global.
5431 (set_timeout): Renamed to ...
5432 (grub_menu_set_timeout): ... this and made it global.
5433 (grub_normal_terminal_menu_viewer): Renamed to ...
5434 (grub_normal_text_menu_viewer): ... this.
5436 * normal/menu_text.c: New file. Extracted text-menu-specific code
5439 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add `normal/menu_text.c'.
5440 (normal_mod_SOURCES): Likewise.
5442 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
5443 (normal_mod_SOURCES): Likewise.
5445 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5446 (normal_mod_SOURCES): Likewise.
5448 * conf/i386-pc.rmk, (grub_emu_SOURCES): Likewise.
5449 (normal_mod_SOURCES): Likewise.
5451 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5452 (normal_mod_SOURCES): Likewise.
5454 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5455 (normal_mod_SOURCES): Likewise.
5457 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
5458 (normal_mod_SOURCES): Likewise.
5460 2009-02-11 Robert Millan <rmh@aybabtu.com>
5462 * util/grub.d/00_header.in: Update old reference to `font' command.
5464 2009-02-10 Felix Zielcke <fzielcke@z-51.de>
5466 * fs/fat.c (grub_fat_mount): Fix wrong comparison.
5468 Based on patch from Javier MartÃn.
5470 2009-02-09 Felix Zielcke <fzielcke@z-51.de>
5472 * conf/common.rmk (grub_probe_SOURCES): Move fs/ext2.c before fs/fat.c
5473 to avoid false positives with FAT.
5474 (grub_fstest_SOURCES): Likewise.
5475 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
5476 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
5477 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5478 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
5479 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5480 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5482 2009-02-09 Felix Zielcke <fzielcke@z-51.de>
5484 * fs/fat.c (grub_fat_mount): Try to avoid false positives by checking
5485 bpb.version_specific.fat12_or_fat16.fstype and
5486 bpb.version_specific.fat32.fstype.
5488 2009-02-08 Robert Millan <rmh@aybabtu.com>
5490 * fs/tar.c: Replace "fs/cpio.c" with "cpio.c".
5492 2009-02-08 Robert Millan <rmh@aybabtu.com>
5494 * Makefile.in (host_os, host_cpu): New variables.
5495 (target_os): Remove. Update all users.
5497 2009-02-08 Marco Gerards <marco@gnu.org>
5499 * Makefile.in (enable_grub_emu_usb): New variable.
5500 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/scsi.c'.
5501 (grub_emu_SOURCES) [grub_emu_SOURCES]: Add `disk/usbms.c',
5502 `util/usb.c', `bus/usb/usb.c' and `commands/usbtest.c'.
5503 (grub_emu_LDFLAGS): Add `$(LIBUSB)'.
5504 (pkglib_MODULES): Add `usb.mod', `uhci.mod', `ohci.mod',
5505 `usbtest.mod' and `usbms.mod'.
5506 (usb_mod_SOURCES, usb_mod_CFLAGS, usb_mod_LDFLAGS)
5507 (usbtest_mod_SOURCES, usbtest_mod_CFLAGS, usbtest_mod_LDFLAGS)
5508 (uhci_mod_SOURCES, uhci_mod_CFLAGS, uhci_mod_LDFLAGS,
5509 (ohci_mod_SOURCES, ohci_mod_CFLAGS, ohci_mod_LDFLAGS)
5510 (usbms_mod_SOURCES, usbms_mod_CFLAGS, usbms_mod_LDFLAGS): New
5513 * disk/usbms.c: New file.
5515 * include/grub/usb.h: Likewise.
5517 * include/grub/usbtrans.h: Likewise.
5519 * include/grub/usbdesc.h: Likewise.
5521 * bus/usb/usbtrans.c: Likewise.
5523 * bus/usb/ohci.c: Likewise.
5525 * bus/usb/uhci.c: Likewise.
5527 * bus/usb/usbhub.c: Likewise.
5529 * bus/usb/usb.c: Likewise.
5531 * commands/usbtest.c: Likewise.
5533 * util/usb.c: Likewise.
5535 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_IO'.
5537 * configure.ac: Test for libusb presence.
5539 * util/grub-emu.c (main) [HAVE_LIBUSB_H]: Call `grub_libusb_init'.
5541 2009-02-08 Vesa Jääskeläinen <chaac@nic.fi>
5543 * kern/mm.c: Add more comments.
5545 2009-02-08 Robert Millan <rmh@aybabtu.com>
5547 Patch from Javier MartÃn.
5548 * fs/ext2.c (EXT2_DRIVER_SUPPORTED_INCOMPAT): Add
5549 `EXT4_FEATURE_INCOMPAT_FLEX_BG'.
5551 2009-02-08 Robert Millan <rmh@aybabtu.com>
5553 * fs/cpio.c: Split tar functionality to ...
5554 * fs/tar.c: ... here (new file). Update all users.
5556 2009-02-07 Robert Millan <rmh@aybabtu.com>
5558 * fs/ext2.c (grub_ext2_mount): Avoid mounting filesystems with
5559 backward-incompatible features.
5561 Based on patch from Javier MartÃn, with some adjustments.
5563 2009-02-07 Michael Scherer <misc@mandriva.org>
5565 * fs/hfs.c (grub_hfsplus_iterate_dir): Treat hfs+ as case insensitive.
5567 2009-02-07 Robert Millan <rmh@aybabtu.com>
5569 * conf/common.rmk (grub_probe_SOURCES, grub_fstest_SOURCES): Move
5570 position of `disk/lvm.c' to ensure grub_init_all() always picks it
5571 after the RAID stuff.
5573 2009-02-05 Vesa Jääskeläinen <chaac@nic.fi>
5575 Fixes problem when running vbetest command as reported by
5576 Vladimir Serbinenko <phcoder@gmail.com>.
5578 * (grub_vbe_set_video_mode): Fixed problem with text modes.
5580 2009-02-04 Felix Zielcke <fzielcke@z-51.de>
5582 util/getroot.c (grub_util_get_grub_dev): Add support for /dev/mdNpN and
5583 /dev/md/NpN style mdraid devices.
5585 2009-02-03 Felix Zielcke <fzielcke@z-51.de>
5587 * util/unifont2pff.rb: Remove.
5589 2009-02-03 Felix Zielcke <fzielcke@z-51.de>
5591 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add a missing trailing
5594 2009-02-03 Felix Zielcke <fzielcke@z-51.de>
5596 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/menu_viewer.c'.
5597 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
5598 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
5599 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
5600 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5601 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5602 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5604 2009-02-02 Christian Franke <franke@computer.org>
5606 * lib/hexdump.c (hexdump): Print at most 3 lines if data is identical.
5608 2009-02-01 Felix Zielcke <fzielcke@z-51.de>
5610 * INSTALL: Note that we now require at least autoconf 2.59 and
5611 that LZO is optional.
5613 2009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
5615 Base on patch on bug #24154 created by Tomas Tintera
5618 * video/i386/pc/vbe.c (grub_video_vbe_scroll): Fix downward scrolling.
5620 2009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
5622 Based on patch on bug #25318 created by Bernhard Rosenkraenzer
5623 <bero@arklinux.org>.
5625 * normal/parser.y (script_init): Add missing semicolon.
5627 2009-01-31 Colin D Bennett <colin@gibibit.com>
5629 * normal/main.c: Add include to grub/menu_viewer.h.
5630 (free_menu_entry_classes): Added.
5631 (grub_normal_menu_addentry): Added class property handling.
5632 (grub_normal_execute): Changed to use new menu viewer for menu viewing.
5633 (GRUB_MOD_INIT(normal)): Added register for text based menu viewer.
5635 * normal/menu_viewer.c: New file.
5637 * normal/menu.c (run_menu_entry): Renamed to ...
5638 (grub_menu_execute_entry): ... this and made it as global.
5639 (grub_menu_run): Renamed to ...
5640 (show_text_menu): ... this and made it local.
5641 (show_text_menu): Adapt to new function names.
5642 (grub_normal_terminal_menu_viewer): New global variable.
5644 * include/grub/menu.h: New file.
5646 * include/grub/menu_viewer.h: New file.
5648 * include/grub/normal.h: Added include to grub/menu.h.
5649 (grub_menu_entry): Moved to include/grub/menu.h.
5650 (grub_menu_entry_t): Likewise.
5651 (grub_menu): Likewise.
5652 (grub_menu_t): Likewise.
5653 (grub_normal_terminal_menu_viewer): Added.
5654 (grub_menu_execute_entry): Likewise.
5655 (grub_menu_run): Removed.
5657 * DISTLIST: Added include/grub/menu.h.
5658 Added include/grub/menu_viewer.h.
5659 Added normal/menu_viewer.c.
5661 2009-01-31 Vesa Jääskeläinen <chaac@nic.fi>
5663 * normal/execute.c (grub_script_execute_menuentry): Changed to use
5664 arglist for menutitle arguments.
5666 * normal/main.c (grub_normal_menu_addentry): Likewise.
5668 * normal/parser.y (menuentry): Likewise.
5670 * normal/script.c (grub_script_create_cmdmenu): Likewise.
5672 * include/grub/script.h (grub_script_cmd_menuentry): Likewise.
5673 (grub_script_create_cmdmenu): Likewise.
5675 * include/grub/normal.h (grub_normal_menu_addentry): Likewise.
5677 * conf/i386-pc.rmk (normal_mod_SOURCES): Adapt Colin D Bennett's
5680 * conf/x86_64-efi.rmk (normal_mod_SOURCES): Likewise.
5682 * conf/i386-coreboot.rmk (normal_mod_SOURCES): Likewise.
5684 * conf/i386-efi.rmk (normal_mod_SOURCES): Likewise.
5686 * conf/i386-ieee1275.rmk (normal_mod_SOURCES): Likewise.
5688 * conf/powerpc-ieee1275.rmk (normal_mod_SOURCES): Likewise.
5690 * conf/sparc64-ieee1275.rmk (normal_mod_SOURCES): Likewise.
5692 2009-01-30 Christian Franke <franke@computer.org>
5694 * normal/arg.c (grub_arg_show_help): Add indentation if '\n' appears
5695 in option help text.
5697 2009-01-27 Pavel Roskin <proski@gnu.org>
5699 * disk/fs_uuid.c (search_fs_uuid): Ignore case of the UUID.
5701 2009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
5703 * commands/lsmmap.c: Add include to grub/machine/memory.h.
5705 * fs/i386/pc/pxe.c (grub_pxefs_open): Fix sign problem.
5707 * term/i386/pc/at_keyboard.c (GRUB_MOD_FINI(at_keyboard)): Use proper
5708 unregister function.
5710 2009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
5712 * disk/scsi.c (grub_scsi_read): Fix sign problem.
5714 * term/i386/pc/vga_text.c (grub_vga_text_init_fini). Fix declaration.
5716 * util/grub-mkfont.c (usage): Fix typo.
5718 * util/elf/grub-mkimage.c (load_modules): Fix warning.
5720 2009-01-26 Daniel Mierswa <impulze@impulze.org>
5722 * fs/fat.c (grub_fat_uuid): Fix shift of the first two bytes.
5724 * commands/search.c (search_fs_uuid): Ignore case of the UUID.
5726 * kern/misc.c (grub_strcasecmp): New function.
5727 (grub_strcasecmp): Use grub_size_t instead of int for length.
5729 * include/grub/misc.h: Update function prototypes.
5731 2009-01-26 Robert Millan <rmh@aybabtu.com>
5733 * configure.ac: Fix cross-compilation check.
5735 2009-01-22 Christian Franke <franke@computer.org>
5737 * kern/misc.c (grub_vsprintf): Fix size and termination of `format2'
5738 (precision) digit string. Allow `.format2' without `format1' (width).
5739 Limit input chars for `%s' output to `format2' if specified. This is
5740 compatible with standard printf ().
5742 2009-01-22 Christian Franke <franke@computer.org>
5744 * disk/ata.c (grub_ata_wait_status): Replace by ...
5745 (grub_ata_wait_not_busy): ... this function. Checks only BSY bit,
5746 other status bits may be invalid while BSY is asserted.
5747 (grub_ata_check_ready): New function.
5748 (grub_ata_cmd): Removed.
5749 (grub_ata_wait_drq): New function.
5750 (grub_ata_strncpy): Remove inline.
5751 (grub_ata_pio_read): Reduce to actual block transfer. BSY wait
5752 and error check now done by grub_ata_wait_drq ().
5753 (grub_ata_pio_write): Likewise.
5754 (grub_atapi_identify): Set DEV before check for !BSY. Use
5755 grub_ata_wait_drq () to wait for data.
5756 (grub_ata_device_initialize): Add status register check to
5757 detect missing SATA slave devices. Add debug messages.
5758 (grub_atapi_wait_drq): Use grub_ata_wait_not_busy ().
5759 (grub_atapi_packet): Set DEV before check for !BSY. Replace
5760 transfer loop by grub_ata_pio_write ().
5761 (grub_ata_identify): Set DEV before check for !BSY. Use
5762 grub_ata_wait_drq () to wait for data.
5763 (grub_ata_setaddress): Set DEV before check for !BSY.
5764 (grub_ata_readwrite): Remove duplicate code, handle batch/rest and
5765 read/write in one loop. Fix invalid command on write. Fix incomplete
5766 command on (size % batch) == 0. Add missing error check after write of
5767 last block. Add debug messages.
5768 (grub_atapi_read): Replace transfer loop by grub_ata_pio_read ().
5770 2009-01-19 Christian Franke <franke@computer.org>
5772 * disk/ata.c (GRUB_ATAPI_REG_*): New defines.
5773 (GRUB_ATAPI_IREASON_*): Likewise.
5774 (grub_ata_pio_write): Fix timeout error return.
5775 (grub_atapi_identify): Add grub_ata_wait () after cmd.
5776 (grub_atapi_wait_drq): New function.
5777 (grub_atapi_packet): New parameter `size'.
5778 Use grub_atapi_wait_drq () and direct write instead of
5779 grub_ata_pio_write ().
5780 (grub_atapi_read): Replace grub_ata_pio_read () by a loop which
5781 reads the number of bytes requested by the device for each DRQ
5783 (grub_atapi_write): Remove old implementation, return not
5784 implemented instead.
5786 2009-01-19 Christian Franke <franke@computer.org>
5788 * disk/scsi.c (grub_scsi_read10): Use scsi->blocksize instead
5789 of 512 to calculate data size.
5790 (grub_scsi_read12): Likewise.
5791 (grub_scsi_write10): Likewise.
5792 (grub_scsi_write12): Likewise.
5793 (grub_scsi_read): Adjust size according to blocksize.
5794 Add checks for invalid blocksize and unaligned transfer.
5796 2009-01-19 Vesa Jääskeläinen <chaac@nic.fi>
5798 * font/font.c (grub_font_loader_init): Re-position unknown glyph.
5800 * term/gfxterm.c (write_char): Fix background rendering for wide
5803 2009-01-19 Robert Millan <rmh@aybabtu.com>
5805 * config.guess: Update to latest version from config git.
5806 * config.sub: Likewise.
5808 2009-01-17 Felix Zielcke <fzielcke@z-51.de>
5810 * Makefile.in: Change font compilation to use new grub-mkfont instead
5813 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: Remove.
5814 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
5815 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
5816 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
5817 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
5818 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
5819 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
5820 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
5821 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
5823 2009-01-16 Christian Franke <franke@computer.org>
5825 * disk/ata.c (enum grub_ata_commands): Remove EXEC_DEV_DIAGNOSTICS.
5826 (enum grub_ata_timeout_milliseconds): New enum.
5827 (grub_ata_wait_status): Add parameter milliseconds.
5828 (grub_ata_cmd): Remove variable `err'. Remove wait for !DRQ to allow
5829 recovery from timed-out commands.
5830 (grub_ata_pio_read): Add parameter milliseconds. Fix error return,
5831 return grub_errno instead of REG_ERROR.
5832 (grub_ata_pio_write): Add parameter milliseconds.
5833 (grub_atapi_identify): Fix size of ATAPI IDENTIFY sector.
5834 Pass milliseconds to grub_ata_wait_status () and
5835 grub_ata_pio_read ().
5836 (grub_atapi_packet): Pass milliseconds to grub_ata_pio_write ().
5837 (grub_ata_identify): Remove variable `ataerr'. Pass milliseconds to
5838 grub_ata_wait_status (). Fix IDENTIFY timeout check.
5839 (grub_ata_device_initialize): Remove EXECUTE DEVICE DIAGNOSTICS.
5840 It is not suitable for device detection, because DEV bit is ignored,
5841 the command may run too long, and not all devices set the signature
5843 (grub_ata_pciinit): Clear grub_errno before grub_ata_device_initialize ().
5844 (grub_ata_setaddress): Pass milliseconds to grub_ata_wait_status ().
5845 Fix device selection, DEV bit must be set first to address the registers
5846 of the correct device.
5847 (grub_ata_readwrite): Pass milliseconds to grub_ata_wait_status () and
5848 grub_ata_pio_read/write ().
5849 (grub_atapi_read): Pass milliseconds to grub_ata_pio_read ().
5850 (grub_atapi_write): Pass milliseconds to grub_ata_pio_write ().
5852 2009-01-13 Carles Pina i Estany <carles@pina.cat>
5854 * util/grub-editenv.c (main): Use fseeko(), not fseek().
5856 2009-01-13 Bean <bean123ch@gmail.com>
5858 * util/grub-mkfont.c (write_font): forget to remove some debug code.
5860 2009-01-13 Bean <bean123ch@gmail.com>
5862 * Makefile.in: (enable_grub_mkfont): New variable.
5863 (freetype_cflags): Likewise.
5864 (freetype_libs): Likewise.
5866 * common.rmk (bin_UTILITIES): Add `grub-mkfont' if requested.
5867 (grub_mkfont_SOURCES): New variable.
5868 (grub_mkfont_CFLAGS): Likewise.
5869 (grub_mkfont_LDFLAGS): Likewise.
5871 * configure.ac (--enable-grub-mkfont): New option. Check for freetype2
5872 library if `--enable-grub-mkfont' is requested.
5873 (enable_grub_mkfont): New variable.
5874 (freetype_cflags): Likewise.
5875 (freetype_libs): Likewise.
5877 * util/grub-mkfont.c: New file.
5879 2009-01-12 Christian Franke <franke@computer.org>
5881 * disk/ata.c (grub_ata_pciinit): Fix bit numbers of compatibility
5882 mode check. Fix setting of compat_use[].
5884 2009-01-10 Robert Millan <rmh@aybabtu.com>
5886 Update a few copyright years which we forgot to do in 2008 (only for
5887 files whose changes made in 2008 were copyright-significant)
5889 * Makefile.in: Add 2008 to Copyright line.
5890 * disk/ieee1275/ofdisk.c: Likewise.
5891 * disk/efi/efidisk.c: Likewise.
5892 * kern/dl.c: Likewise.
5893 * kern/sparc64/ieee1275/init.c: Likewise.
5894 * kern/mm.c: Likewise.
5895 * kern/efi/mm.c: Likewise.
5896 * boot/i386/pc/boot.S: Likewise.
5897 * genfslist.sh: Likewise.
5898 * fs/iso9660.c: Likewise.
5899 * fs/hfs.c: Likewise.
5900 * fs/jfs.c: Likewise.
5901 * fs/minix.c: Likewise.
5902 * fs/ufs.c: Likewise.
5903 * gensymlist.sh.in: Likewise.
5904 * genkernsyms.sh.in: Likewise.
5905 * include/grub/misc.h: Likewise.
5906 * include/grub/types.h: Likewise.
5907 * include/grub/symbol.h: Likewise.
5908 * include/grub/elf.h: Likewise.
5909 * include/grub/kernel.h: Likewise.
5910 * include/grub/disk.h: Likewise.
5911 * include/grub/dl.h: Likewise.
5912 * include/grub/i386/linux.h: Likewise.
5913 * include/grub/i386/pc/biosdisk.h: Likewise.
5914 * include/grub/efi/api.h: Likewise.
5915 * include/grub/efi/pe32.h: Likewise.
5916 * include/grub/util/misc.h: Likewise.
5917 * normal/execute.c: Likewise.
5918 * normal/arg.c: Likewise.
5919 * normal/completion.c: Likewise.
5920 * normal/lexer.c: Likewise.
5921 * normal/parser.y: Likewise.
5922 * normal/misc.c: Likewise.
5923 * commands/i386/pc/vbeinfo.c: Likewise.
5924 * commands/hexdump.c: Likewise.
5925 * commands/terminal.c: Likewise.
5926 * commands/ls.c: Likewise.
5927 * commands/help.c: Likewise.
5928 * partmap/pc.c: Likewise.
5929 * loader/efi/chainloader.c: Likewise.
5930 * loader/multiboot_loader.c: Likewise.
5931 * loader/i386/pc/multiboot2.c: Likewise.
5932 * term/efi/console.c: Likewise.
5933 * term/i386/pc/serial.c: Likewise.
5934 * util/lvm.c: Likewise.
5935 * util/console.c: Likewise.
5936 * util/i386/efi/grub-mkimage.c: Likewise.
5937 * util/raid.c: Likewise.
5939 2009-01-06 Vesa Jääskeläinen <chaac@nic.fi>
5941 * commands/videotest.c: Removed include to grub/machine/memory.h.
5943 * conf/i386-pc.rmk (pkglib_MODULES): Removed video.mod, gfxterm.mod,
5944 videotest.mod, bitmap.mod, tga.mod, jpeg.mod, png.mod.
5945 (video_mod_SOURCES): Removed.
5946 (video_mod_CFLAGS): Likewise.
5947 (video_mod_LDFLAGS): Likewise.
5948 (gfxterm_mod_SOURCES): Likewise.
5949 (gfxterm_mod_CFLAGS): Likewise.
5950 (gfxterm_mod_LDFLAGS): Likewise.
5951 (videotest_mod_SOURCES): Likewise.
5952 (videotest_mod_CFLAGS): Likewise.
5953 (videotest_mod_LDFLAGS): Likewise.
5954 (bitmap_mod_SOURCES): Likewise.
5955 (bitmap_mod_CFLAGS): Likewise.
5956 (bitmap_mod_LDFLAGS): Likewise.
5957 (tga_mod_SOURCES): Likewise.
5958 (tga_mod_CFLAGS): Likewise.
5959 (tga_mod_LDFLAGS): Likewise.
5960 (jpeg_mod_SOURCES): Likewise.
5961 (jpeg_mod_CFLAGS): Likewise.
5962 (jpeg_mod_LDFLAGS): Likewise.
5963 (png_mod_SOURCES): Likewise.
5964 (png_mod_CFLAGS): Likewise.
5965 (png_mod_LDFLAGS): Likewise.
5967 * conf/common.rmk (pkglib_MODULES): Added video.mod, videotest.mod,
5968 bitmap.mod, tga.mod, jpeg.mod, png.mod, font.mod, gfxterm.mod
5969 (video_mod_SOURCES): Added.
5970 (video_mod_CFLAGS): Likewise.
5971 (video_mod_LDFLAGS): Likewise.
5972 (videotest_mod_SOURCES): Likewise.
5973 (videotest_mod_CFLAGS): Likewise.
5974 (videotest_mod_LDFLAGS): Likewise.
5975 (bitmap_mod_SOURCES): Likewise.
5976 (bitmap_mod_CFLAGS): Likewise.
5977 (bitmap_mod_LDFLAGS): Likewise.
5978 (tga_mod_SOURCES): Likewise.
5979 (tga_mod_CFLAGS): Likewise.
5980 (tga_mod_LDFLAGS): Likewise.
5981 (jpeg_mod_SOURCES): Likewise.
5982 (jpeg_mod_CFLAGS): Likewise.
5983 (jpeg_mod_LDFLAGS): Likewise.
5984 (png_mod_SOURCES): Likewise.
5985 (png_mod_CFLAGS): Likewise.
5986 (png_mod_LDFLAGS): Likewise.
5987 (gfxterm_mod_SOURCES): Likewise.
5988 (gfxterm_mod_CFLAGS): Likewise.
5989 (gfxterm_mod_LDFLAGS): Likewise.
5991 * term/gfxterm.c: Removed include to grub/machine/memory.h,
5992 grub/machine/console.h.
5994 2009-01-04 Jerone Young <jerone@gmail.com>
5996 Make on screen instructions clearer
5998 Based on patch created by Jidanni <jidanni@jidanni.org>
6000 * normal/menu.c: print clearer instructions on the screen
6002 2009-01-02 Colin D Bennett <colin@gibibit.com>
6006 Additional changes by Vesa Jääskeläinen <chaac@nic.fi> to adapt to
6007 build system and fixed gfxterm.c to work with different sized fonts.
6009 * configure.ac: Changed UNIFONT_HEX to UNIFONT_BDF.
6011 * configure: Re-generated.
6013 * DISTLIST: Removed font/manager.c.
6015 Added font/font_cmd.c.
6017 * Makefile.in: Changed UNIFONT_HEX to UNIFONT_BDF. Added Font tool
6020 * include/grub/misc.h (grub_utf8_to_ucs4): Changed prototype. Changed users.
6022 * kern/misc.c (grub_utf8_to_ucs4): Changed prototype.
6024 * kern/term.c: Changed users of grub_utf8_to_ucs4.
6026 * normal/menu.c: Likewise.
6028 * conf/common.rmk (font_mod_SOURCES): Removed font/manager.c.
6029 (font_mod_SOURCES): Added font/font_cmd.c, font/font.c.
6031 * include/grub/font.h: Replaced with new file.
6033 * include/grub/video.h (GRUB_VIDEO_MODE_TYPE_ALPHA): Changed value.
6034 (GRUB_VIDEO_MODE_TYPE_DOUBLE_BUFFERED): Likewise.
6035 (GRUB_VIDEO_MODE_TYPE_COLOR_MASK): Likewise.
6036 (GRUB_VIDEO_MODE_TYPE_1BIT_BITMAP): Added.
6037 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_1BIT_PACKED.
6038 (grub_video_mode_info): Added bg_red, bg_green, bg_blue, bg_alpha,
6039 fg_red, fg_green, fg_blue, fg_alpha.
6040 (grub_video_adapter): Removed blit_glyph.
6041 (grub_video_blit_glyph): Removed.
6043 * font/manager.c: Removed file.
6045 * font/font.c: New file.
6047 * font/font_cmd.c: Likewise.
6049 * video/video.c (grub_video_blit_glyph): Removed.
6051 * video/i386/pc/vbe.c (grub_video_vbe_map_rgb): Added 1-bit support.
6052 (grub_video_vbe_map_rgba): Likewise.
6053 (grub_video_vbe_unmap_color_int): Likewise.
6054 (grub_video_vbe_blit_glyph): Removed.
6055 (grub_video_vbe_adapter): Removed blit_glyph.
6057 * video/i386/pc/vbeutil.c (get_data_ptr): Added 1-bit support.
6058 (get_pixel): Likewise.
6059 (set_pixel): Likewise.
6061 * commands/videotest.c (grub_cmd_videotest): Added more tests for fonts.
6063 * term/gfxterm.c: Adapted to new font engine.
6065 * term/i386/pc/vesafb.c: Marked as deprecated. Made it compile.
6067 * term/i386/pc/vga.c: Likewise.
6069 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: New file.
6071 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
6073 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
6075 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
6077 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
6079 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
6081 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
6083 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
6085 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
6087 * util/grub.d/00_header.in: Changed to use new loadfont command.
6089 * util/grub-mkconfig_lib.in: Changed font extension.
6091 2008-12-28 Felix Zielcke <fzielcke@z-51.de>
6093 * util/getroot.c (grub_util_get_grub_dev): Add support for
6094 /dev/md/dNNpNN style partitionable mdraid devices.
6096 2008-12-12 Alex Smith <alex@alex-smith.me.uk>
6098 * fs/i386/pc/pxe.c (grub_pxefs_open): Handle the one open connection
6099 at a time limit of the PXE TFTP API correctly.
6100 (grub_pxefs_close): Likewise.
6102 2008-11-29 Robert Millan <rmh@aybabtu.com>
6104 * disk/ata.c (grub_ata_pciinit): Handle errors raised by
6105 grub_ata_device_initialize() calls.
6107 2008-11-28 Krzysztof Smiechowicz <deadwood@wp.pl>
6109 * fs/affs.c (grub_affs_iterate_dir): Return failure when directory
6111 * fs/sfs.c (grub_sfs_iterate_dir): Likewise.
6113 2008-11-28 Robert Millan <rmh@aybabtu.com>
6115 Fix build on powerpc-ieee1275. Based on patch created by
6116 Manoel Abranches <mrabran@linux.vnet.ibm.com>.
6117 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
6118 `kern/ieee1275/mmap.c'.
6119 * include/grub/powerpc/ieee1275/memory.h: New file.
6121 Provide grub-install on coreboot.
6122 * conf/i386-coreboot.rmk (sbin_SCRIPTS): Add `grub-install'.
6123 (grub_install_SOURCES): New variable.
6124 * util/i386/pc/grub-install.in: Add a few condition checks to make it
6127 2008-11-25 Felix Zielcke <fzielcke@z-51.de>
6129 * util/grub-fstest.c (grub_term_get_current_input): Change return type
6130 to `grub_term_input_t'.
6131 (grub_term_get_current_output): Change return type to
6132 `grub_term_output_t'.
6134 2008-11-22 Robert Millan <rmh@aybabtu.com>
6136 Fix breakage on coreboot due to declaration mismatch.
6137 * term/i386/pc/vga_text.c (grub_vga_text_init_fini): New function.
6138 (grub_vga_text_term): Use grub_vga_text_init_fini() instead of
6139 grub_vga_text_cls().
6141 * kern/i386/loader.S (grub_multiboot_backward_relocator): Improve
6142 comments. Avoid copying one more byte than necessary (just in case).
6144 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Change link address
6145 to 0x200000 (avoids trouble with some OFW implementations, and matches
6146 with the one in Yaboot).
6147 Reported by Manoel Abranches
6149 2008-11-20 Robert Millan <rmh@aybabtu.com>
6151 * kern/i386/coreboot/init.c (grub_time_tics): Remove variable.
6152 (grub_get_rtc, grub_exit): Abort with grub_fatal() if called.
6154 * util/grub-mkconfig_lib.in (grub_warn): New function.
6155 (convert_system_path_to_grub_path): Use grub_warn() when issuing
6156 warnings, to obtain consistent formatting.
6157 * util/grub.d/00_header.in: Likewise.
6158 * util/update-grub_lib.in: Likewise.
6160 * loader/i386/linux.c (allocate_pages): Fix a warning.
6161 Move comment text to `#error' stanza.
6163 Harmonize ieee1275's grub_available_iterate() with the generic
6164 grub_machine_mmap_iterate() interface (fixes a recently-introduced
6165 build problem on i386-ieee1275):
6166 * kern/ieee1275/openfw.c (grub_available_iterate): Moved from here ...
6167 * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): ... here. Add third
6168 parameter `type'. Update all users of this function.
6169 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
6170 `kern/ieee1275/mmap.c'.
6171 * kern/ieee1275/init.c
6172 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): Replace
6174 (grub_machine_mmap_iterate): ... this.
6175 * include/grub/i386/pc/memory.h (grub_machine_mmap_iterate): Change
6176 return type to `grub_err_t'. Update all implementations of this
6178 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_iterate):
6181 Add `lsmmap' command (lists firmware-provided memory map):
6182 * commands/lsmmap.c: New file.
6183 * conf/i386-pc.rmk (pkglib_MODULES): Add `lsmmap.mod'.
6184 (lsmmap_mod_SOURCES, lsmmap_mod_CFLAGS, lsmmap_mod_LDFLAGS): New
6186 * conf/powerpc-ieee1275.rmk: Likewise.
6187 * conf/i386-coreboot.rmk: Likewise.
6188 * conf/i386-ieee1275.rmk: Likewise.
6190 2008-11-19 Robert Millan <rmh@aybabtu.com>
6192 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Fix a typo.
6193 * loader/i386/linux.c (grub_rescue_cmd_initrd): Implement a few needed
6194 constraints to initrd allocation (based on code from
6195 loader/i386/pc/linux.c). Without them, initrd was allocated too high
6196 for Linux to find it.
6198 2008-11-14 Robert Millan <rmh@aybabtu.com>
6200 * fs/cpio.c (grub_cpio_open): Compare `name' and `fn' by hand in
6201 order to cope with duplicate slashes.
6203 2008-11-14 Robert Millan <rmh@aybabtu.com>
6205 * include/grub/i386/coreboot/memory.h (GRUB_MEMORY_MACHINE_LOWER_SIZE):
6206 Redefine to match with GRUB_MEMORY_MACHINE_UPPER_START (0x100000). We
6207 don't want to mess with lower memory, because it is used in the Linux
6210 * loader/i386/linux.c (allocate_pages): Allocate `real_mode_mem' in
6211 an appropriate place in lower memory, between 0x10000 and 0x90000,
6212 like loader/i386/efi/linux.c does. Linux often panics if real_mode_mem
6213 is in our heap (probably as a result of it being corrupted during
6214 decompression). Add #error instance with comment to explain why this
6215 loader isn't currently usable on PC/BIOS.
6217 2008-11-14 Robert Millan <rmh@aybabtu.com>
6219 * term/i386/pc/serial.c [! GRUB_MACHINE_PCBIOS]
6220 (GRUB_SERIAL_PORT_NUM): Fix miscalculation.
6222 2008-11-12 Robert Millan <rmh@aybabtu.com>
6224 Make loader/i386/linux.c buildable on i386-pc (although disabled).
6226 * include/grub/i386/pc/init.h: Include `<grub/machine/memory.h>'.
6227 (struct grub_machine_mmap_entry, grub_machine_mmap_iterate): Move
6229 * include/grub/i386/pc/memory.h: ... to here.
6231 2008-11-12 Robert Millan <rmh@aybabtu.com>
6233 Fix build problems on i386-ieee1275 and *-efi (introduced by vga_text
6236 * include/grub/i386/pc/console.h: Include `<grub/i386/vga_common.h>'.
6237 (grub_console_cur_color, grub_console_real_putchar)
6238 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
6239 (grub_console_setcolorstate, grub_console_setcolor)
6240 (grub_console_getcolor): Move from here ...
6241 * include/grub/i386/vga_common.h: ... to here (new file).
6243 * term/i386/pc/vga_text.c: Replace `<grub/machine/console.h>' with
6244 `<grub/i386/vga_common.h>' and `<grub/cpu/io.h>' with
6246 * term/i386/vga_common.c: Replace `<grub/machine/console.h>' with
6247 `<grub/i386/vga_common.h>'.
6249 2008-11-12 Robert Millan <rmh@aybabtu.com>
6251 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `term/i386/vga_common.c'.
6252 * conf/i386.rmk (pkglib_MODULES): Add `vga_text.mod'.
6253 (vga_text_mod_SOURCES, vga_text_mod_CFLAGS, vga_text_mod_LDFLAGS): New
6255 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
6256 `term/i386/pc/console.c' with `term/i386/vga_common.c'.
6258 * kern/i386/coreboot/init.c (grub_machine_init): Replace call to
6259 grub_console_init() with call to grub_vga_text_init().
6260 (grub_machine_fini): Replace call to
6261 grub_console_fini() with call to grub_vga_text_fini() and
6262 grub_at_keyboard_fini().
6264 * include/grub/i386/pc/console.h: Include `<grub/term.h>'.
6265 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
6266 (grub_console_setcolorstate, grub_console_setcolor)
6267 (grub_console_getcolor): New function prototypes.
6269 * term/i386/pc/vga_text.c: Include `<grub/dl.h>'.
6270 (grub_vga_text_getxy, grub_vga_text_gotoxy, grub_vga_text_cls)
6271 (grub_vga_text_setcursor): Static-ize.
6272 (grub_vga_text_term): New structure.
6273 (GRUB_MOD_INIT(vga_text), GRUB_MOD_FINI(vga_text)): New functions.
6275 * term/i386/pc/console.c: Remove `<grub/machine/machine.h>'.
6276 (grub_console_cur_color, grub_console_standard_color)
6277 (grub_console_normal_color, grub_console_highlight_color)
6278 (map_char, grub_console_putchar, grub_console_getcharwidth)
6279 (grub_console_getwh, grub_console_setcolorstate, grub_console_setcolor)
6280 (grub_console_getcolor): Move from here ...
6281 * term/i386/vga_common.c: ... to here (same function names).
6283 2008-11-12 Robert Millan <rmh@aybabtu.com>
6285 Use newly-added Multiboot support in coreboot.
6287 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
6288 `kern/i386/coreboot/mmap.c' with `kern/i386/multiboot_mmap.c'.
6290 * kern/i386/coreboot/startup.S: Enable Multiboot header, fix its
6291 alignment, set `MULTIBOOT_MEMORY_INFO' flag.
6292 (codestart): Store the MBI in `startup_multiboot_info' when we're
6293 being loaded using Multiboot.
6295 * kern/i386/coreboot/init.c (grub_machine_init): Move
6296 grub_at_keyboard_init() call to beginning of function (useful for
6297 debugging). Call grub_machine_mmap_init() before attempting to use
6298 grub_machine_mmap_iterate().
6299 (grub_lower_mem, grub_upper_mem): Move from here ...
6300 * kern/i386/multiboot_mmap.c (grub_lower_mem, grub_upper_mem): ... to
6303 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_init): New
6306 2008-11-12 Robert Millan <rmh@aybabtu.com>
6308 Fix a regression introduced by the at_keyboard.mod split. Because
6309 some terminals are default on some platforms and non-default on
6310 others, the first terminal being registered determines which is
6311 going to be default.
6313 * kern/term.c (grub_term_register_input): If this is the first
6314 terminal being registered, set it as the current one.
6315 (grub_term_register_output): Likewise.
6317 * term/efi/console.c (grub_console_init): Do not call
6318 grub_term_set_current_output() or grub_term_set_current_input().
6319 * term/ieee1275/ofconsole.c (grub_console_init): Likewise.
6320 * term/i386/pc/console.c (grub_console_init): Likewise.
6321 (grub_console_fini): Do not call grub_term_set_current_input()
6322 (but leave grub_term_set_current_output() to restore text mode).
6324 2008-11-10 Robert Millan <rmh@aybabtu.com>
6326 * util/grub.d/00_header.in: Add backward compatibility check for
6327 versions of terminal.mod that don't understand `terminal_input' or
6330 2008-11-09 Robert Millan <rmh@aybabtu.com>
6332 * commands/terminal.c (GRUB_MOD_FINI(terminal)): Unregister
6333 `terminal_input' / `terminal_output', not `terminal'.
6335 2008-11-08 Robert Millan <rmh@aybabtu.com>
6337 * Makefile.in (include_DATA): Fix srcdir=. assumption.
6338 (DISTCLEANFILES): Add `build_env.mk'.
6340 2008-11-08 Robert Millan <rmh@aybabtu.com>
6342 * term/i386/pc/vesafb.c (grub_vesafb_term): Change type to
6343 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
6344 members. Update all users.
6345 * util/console.c (grub_ncurses_term): Split in ...
6346 (grub_ncurses_term_input): ... this, and ...
6347 (grub_ncurses_term_output): ... this. Update all users.
6348 * term/ieee1275/ofconsole.c: Remove stale `#endif'.
6350 2008-11-08 Robert Millan <rmh@aybabtu.com>
6352 * Makefile.in (PKGLIB): Add $(pkglib_BUILDDIR).
6353 (PKGDATA): Add $(pkgdata_SRCDIR).
6354 (pkglib_BUILDDIR): New variable.
6355 (pkgdata_SRCDIR): New variable.
6356 (build_env.mk): New target.
6357 (include_DATA): New variable.
6358 (install-local): Install $(include_DATA) files in $(includedir).
6360 2008-11-07 Pavel Roskin <proski@gnu.org>
6362 * gendistlist.sh: Use C locale for sorting to ensure consistent
6363 output on all systems.
6365 * util/grub.d/00_header.in: Remove incorrect space before
6368 2008-11-07 Robert Millan <rmh@aybabtu.com>
6370 * include/multiboot2.h (struct multiboot_header): Add `flags' member as
6372 * loader/multiboot2.c (grub_multiboot2): Fix Multiboot2 header check.
6373 * loader/multiboot_loader.c (find_multi_boot2_header): New function
6374 (based on find_multi_boot1_header).
6375 (grub_rescue_cmd_multiboot_loader): Check for Multiboot2 header,
6376 using find_multi_boot2_header(), and abort if neither Multiboot or
6377 Multiboot headers were found.
6379 2008-11-07 Robert Millan <rmh@aybabtu.com>
6381 Modularize at_keyboard.mod:
6383 * conf/i386.rmk (pkglib_MODULES): Add `at_keyboard.mod'.
6384 (at_keyboard_mod_SOURCES, at_keyboard_mod_CFLAGS)
6385 (at_keyboard_mod_LDFLAGS): New variables.
6387 Actual terminal split:
6389 * include/grub/term.h (struct grub_term): Split in ...
6390 (struct grub_term_input): ... this, and ...
6391 (struct grub_term_output): ... this. Update all users.
6392 (grub_term_set_current): Split in ...
6393 (grub_term_set_current_input): ... this, and ...
6394 (grub_term_set_current_output): ... this.
6395 (grub_term_get_current): Split in ...
6396 (grub_term_get_current_input): ... this, and ...
6397 (grub_term_get_current_output): ... this.
6398 (grub_term_register): Split in ...
6399 (grub_term_register_input): ... this, and ...
6400 (grub_term_register_output): ... this.
6401 (grub_term_unregister): Split in ...
6402 (grub_term_unregister_input): ... this, and ...
6403 (grub_term_unregister_output): ... this.
6404 (grub_term_iterate): Split in ...
6405 (grub_term_iterate_input): ... this, and ...
6406 (grub_term_iterate_output): ... this.
6408 * kern/term.c (grub_term_list): Split in ...
6409 (grub_term_list_input): ... this, and ...
6410 (grub_term_list_output): ... this. Update all users.
6411 (grub_cur_term): Split in ...
6412 (grub_cur_term_input): ... this, and ...
6413 (grub_cur_term_output): ... this. Update all users.
6414 (grub_term_set_current): Split in ...
6415 (grub_term_set_current_input): ... this, and ...
6416 (grub_term_set_current_output): ... this.
6417 (grub_term_get_current): Split in ...
6418 (grub_term_get_current_input): ... this, and ...
6419 (grub_term_get_current_output): ... this.
6420 (grub_term_register): Split in ...
6421 (grub_term_register_input): ... this, and ...
6422 (grub_term_register_output): ... this.
6423 (grub_term_unregister): Split in ...
6424 (grub_term_unregister_input): ... this, and ...
6425 (grub_term_unregister_output): ... this.
6426 (grub_term_iterate): Split in ...
6427 (grub_term_iterate_input): ... this, and ...
6428 (grub_term_iterate_output): ... this.
6430 * kern/misc.c (grub_abort): Split use of grub_term_get_current() into
6431 a check for input and one for output (and only attempt to get keys
6432 from user when input works).
6434 * util/grub-probe.c (grub_term_get_current): Split in ...
6435 (grub_term_get_current_input): ... this, and ...
6436 (grub_term_get_current_output): ... this.
6437 * util/grub-fstest.c: Likewise.
6438 * util/i386/pc/grub-setup.c: Likewise.
6439 * util/grub-editenv.c: Likewise.
6441 Portability adjustments:
6443 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Remove
6444 `term/i386/pc/at_keyboard.c'.
6445 * kern/ieee1275/init.c [__i386__] (grub_machine_init): Remove call to
6446 grub_keyboard_controller_init() (now handled by terminal .init).
6447 * kern/i386/coreboot/init.c (grub_machine_init): Add call to
6448 grub_at_keyboard_init().
6449 * include/grub/i386/ieee1275/console.h (grub_keyboard_controller_init)
6450 (grub_console_checkkey, grub_console_getkey): Remove (now provided by
6451 at_keyboard.mod via input terminal interface).
6452 * include/grub/i386/coreboot/console.h: Convert into a stub for
6453 `<grub/i386/pc/console.h>'.
6455 Migrate full terminals to new API:
6457 * term/efi/console.c (grub_console_term): Split into ...
6458 (grub_console_term_input): ... this, and ...
6459 (grub_console_term_output): ... this. Update all users.
6460 * term/ieee1275/ofconsole.c: Remove __i386__ hack.
6461 (grub_ofconsole_init): Split into ...
6462 (grub_ofconsole_init_input): ... this, and ...
6463 (grub_ofconsole_init_output): ... this.
6464 (grub_ofconsole_term): Split into ...
6465 (grub_ofconsole_term_input): ... this, and ...
6466 (grub_ofconsole_term_output): ... this. Update all users.
6467 * term/i386/pc/serial.c (grub_serial_term): Split into ...
6468 (grub_serial_term_input): ... this, and ...
6469 (grub_serial_term_output): ... this. Update all users.
6470 * term/i386/pc/console.c (grub_console_term): Split into ...
6471 (grub_console_term_input): ... this, and ...
6472 (grub_console_term_output): ... this. Update all users.
6473 (grub_console_term_input): Only enable it on PC/BIOS platform.
6474 (grub_console_init): Remove grub_keyboard_controller_init() call.
6476 Migrate input terminals to new API:
6478 * term/i386/pc/at_keyboard.c: Replace `cpu' and `machine' with
6479 `i386' and `i386/pc' to enable build on x86_64 (this driver is
6480 i386-specific anyway).
6481 (grub_console_checkkey): Rename to ...
6482 (grub_at_keyboard_checkkey): ... this. Static-ize. Update all
6484 (grub_keyboard_controller_orig): New variable.
6485 (grub_console_getkey): Rename to ...
6486 (grub_at_keyboard_getkey): ... this. Static-ize. Update all
6488 (grub_keyboard_controller_init): Static-ize. Save original
6489 controller value so that it can be restored ...
6490 (grub_keyboard_controller_fini): ... here (new function).
6491 (grub_at_keyboard_term): New structure.
6492 (GRUB_MOD_INIT(at_keyboard), GRUB_MOD_FINI(at_keyboard)): New
6495 Migrate output terminals to new API:
6497 * term/i386/pc/vga.c (grub_vga_term): Change type to
6498 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
6499 members. Update all users.
6500 * term/gfxterm.c (grub_video_term): Change type to
6501 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
6502 members. Update all users.
6503 * include/grub/i386/pc/console.h (grub_console_checkkey)
6504 (grub_console_getkey): Do not export (no longer needed by gfxterm,
6507 Migrate `terminal' command and userland tools to new API:
6509 * commands/terminal.c (grub_cmd_terminal): Split into ...
6510 (grub_cmd_terminal_input): ... this, and ...
6511 (grub_cmd_terminal_output): ... this.
6512 (GRUB_MOD_INIT(terminal)): Split `terminal' command in two commands:
6513 `terminal_input' and `terminal_output'.
6514 * util/grub.d/00_header.in: Adjust `terminal' calls to new
6515 `terminal_input' / `terminal_output' API.
6516 * util/grub-mkconfig.in: Export ${GRUB_TERMINAL_INPUT} and
6517 ${GRUB_TERMINAL_OUTPUT} instead of ${GRUB_TERMINAL} (and if user
6518 provided ${GRUB_TERMINAL}, convert it).
6520 2008-11-04 Robert Millan <rmh@aybabtu.com>
6522 * util/grub.d/10_freebsd.in: New file. Generate grub configuration
6524 * conf/common.rmk (grub-mkconfig_SCRIPTS): Add 10_freebsd.
6526 2008-11-03 Bean <bean123ch@gmail.com>
6528 * kern/elf.c (grub_elf32_load): Revert to previous code.
6529 (grub_elf64_load): Likewise.
6531 * loader/i386/bsd.c (grub_bsd_elf32_hook): Change return address.
6533 2008-11-01 Robert Millan <rmh@aybabtu.com>
6535 * Makefile.in (CPPFLAGS): Fix builddir=. assumption.
6536 (TARGET_CPPFLAGS): Likewise.
6537 * genmk.rb (mod_src): Fix builddir=. and srcdir=. assumptions.
6539 2008-11-01 Carles Pina i Estany <carles@pina.cat>
6541 * normal/menu.c (run_menu): Add Previous and Next Page keys in menu.
6543 2008-10-29 Guillem Jover <guillem.jover@nokia.com>
6545 * disk/lvm.c (grub_lvm_scan_device): Fix error recovery by delaying the
6546 addition of objects until the code is not going to be able to fail.
6548 2008-10-29 Guillem Jover <guillem.jover@nokia.com>
6550 * disk/lvm.c (grub_lvm_scan_device): Fix possible NULL value handling
6551 (add a missing NULL check, and correct them by moving the pointer
6552 operations after the actual check).
6554 2008-10-29 Robert Millan <rmh@aybabtu.com>
6556 * util/i386/pc/grub-install.in: Handle empty string as output from
6557 make_system_path_relative_to_its_root().
6559 2008-10-05 Hans Lambermont <hans@lambermont.dyndns.org>
6561 * disk/lvm.c (grub_lvm_scan_device): Allocate buffer space for the
6562 circular metadata worst case scenario. If the metadata is circular
6563 then copy the wrap in place.
6564 * include/grub/lvm.h: Add GRUB_LVM_MDA_HEADER_SIZE, from the LVM2
6565 project lib/format_text/layout.h
6566 Circular metadata bug found and patch debugged by Jan Derk Gerlings.
6568 2008-10-03 Felix Zielcke <fzielcke@z-51.de>
6570 * util/i386/pc/grub-install.in: Source grub-mkconfig_lib instead of update-grub_lib.
6572 2008-10-03 Felix Zielcke <fzielcke@z-51.de>
6574 * util/update-grub_lib.in: Mention filename in warning message.
6576 2008-09-29 Felix Zielcke <fzielcke@z-51.de>
6578 * NEWS: Update for rename of update-grub to grub-mkconfig.
6580 2008-09-29 Felix Zielcke <fzielcke@z-51.de>
6582 * util/update-grub_lib.in: Copy to ...
6583 * util/grub-mkconfig_lib.in: ... this. Update all users.
6584 * util/update-grub_lib.in: Make it a stub to `grub-mkconfig_lib.in'.
6585 * util/update-grub.in: Rename to ...
6586 * util/grub-mkconfig.in: ... this. Update all users. Remove `-y'
6587 option. Add `--output' option to allow users to specify the generated
6588 configuration file. Default to stdout.
6589 (update_grub_dir): Rename to ...
6590 (grub_mkconfig_dir): ... this.
6591 (grub_cfg): Default to an empty string.
6592 * conf/common.rmk (update-grub): Rename to ...
6593 (grub-mkconfig): ... this.
6594 (update-grub_lib): Copy to ...
6595 (grub-mkconfig_lib): ... this.
6596 (update-grub_SCRIPTS): Copy to ...
6597 (grub-mkconfig_SCRIPTS): ... this. Update all users.
6598 (update-grub_DATA): Rename to ...
6599 (grub-mkconfig_DATA): ... this.
6601 2008-09-28 Robert Millan <rmh@aybabtu.com>
6603 * fs/iso9660.c (struct grub_iso9660_primary_voldesc): Rename `created'
6604 to `modified'. Add the real `created' field.
6605 (grub_iso9660_uuid): Use `modified' rather than `created' for
6606 constructing the UUID.
6608 2008-09-28 Felix Zielcke <fzielcke@z-51.de>
6610 fs/jfs.c (grub_jfs_find_file): Treat multiple slashes like one.
6611 Based on code from Tomas Ebenlendr <ebik@ucw.cz>.
6613 2008-09-28 Bean <bean123ch@gmail.com>
6615 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a bug in the previous patch.
6616 Thanks to Christian Franke for finding this bug.
6618 2008-09-25 Robert Millan <rmh@aybabtu.com>
6620 * util/grub-mkdevicemap.c (make_device_map): Actually replace all
6621 instances of grub_util_get_disk_name() (see previous commit).
6623 2008-09-25 Robert Millan <rmh@aybabtu.com>
6625 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Remove
6626 `util/i386/get_disk_name.c'.
6627 * conf/i386-efi.rmk: Likewise.
6628 * conf/x86_64-efi.rmk: Likewise.
6629 * conf/i386-coreboot.rmk: Likewise.
6630 * conf/i386-ieee1275.rmk: Likewise.
6631 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Remove
6632 `util/ieee1275/get_disk_name.c'.
6633 * include/grub/util/misc.h (grub_util_get_disk_name): Remove.
6634 * util/ieee1275/get_disk_name.c: Remove file.
6635 * util/i386/get_disk_name.c: Remove file.
6636 * util/grub-mkdevicemap.c (make_device_map): Back to hardcoding
6637 "hd%d" for device.map entries, rather than using
6638 grub_util_get_disk_name().
6640 2008-09-24 Carles Pina i Estany <carles@pina.cat>
6642 * disk/dmraid_nvidia.c (grub_dmraid_nv_detect): Fix `unused parameter'
6644 * commands/i386/pc/pxecmd.c (dmraid_nvidia): Likewise.
6646 2008-09-24 Carles Pina i Estany <carles@pina.cat>
6648 * include/grub/i386/pc/console.h (GRUB_TERM_NPAGE):
6650 (GRUB_TERM_PPAGE): Changed to 0x4900.
6652 2008-09-24 Robert Millan <rmh@aybabtu.com>
6654 * include/grub/powerpc/ieee1275/console.h (GRUB_CONSOLE_KEY_*): Remove
6655 macros (they were i386-pc specific).
6656 * include/grub/sparc64/ieee1275/console.h: Likewise.
6657 * include/grub/efi/console.h: Likewise.
6659 2008-09-22 Bean <bean123ch@gmail.com>
6661 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a rare case where $BITMAP is
6662 resident and in attribute list.
6664 * include/grub/ntfs.h (BMP_LEN): Removed.
6666 2008-09-22 Bean <bean123ch@gmail.com>
6668 * disk/ata.c (grub_atapi_open): Initialize devfnd, no need to set
6669 scsi->name and scsi->luns, as they will be set in grub_scsi_open.
6671 * disk/scsi.c (grub_scsi_open): Don't call p->close (scsi) here when
6672 error occurs, as grub_disk_open will call grub_disk_close, which will
6673 call p->close (scsi).
6675 2008-09-21 Felix Zielcke <fzielcke@z-51.de>
6677 * configure.ac (AC_INIT): Quote `GRUB' string and version number.
6678 (AC_PREREQ): Bumped to 2.59.
6679 (AC_TRY_COMPILE): Replace obsolete macro with ...
6680 (AC_COMPILE_IFELSE): ... this.
6681 * aclocal.m4 (AC_TRY_LINK): Replace obsolete macro with ...
6682 (AC_LINK_IFELSE): ... this.
6684 2008-09-21 Felix Zielcke <fzielcke@z-51.de>
6686 * autogen.sh: Add a call to `gendistlist.sh'.
6688 2008-09-19 Christian Franke <franke@computer.org>
6690 * aclocal.m4 (grub_CHECK_ENABLE_EXECUTE_STACK): New function.
6691 * configure.ac: Call grub_CHECK_ENABLE_EXECUTE_STACK.
6692 * include/grub/misc.h [NEED_ENABLE_EXECUTE_STACK]:
6693 Export __enable_execute_stack() to modules.
6694 * kern/misc.c [NEED_ENABLE_EXECUTE_STACK] (__enable_execute_stack):
6697 2008-09-09 Felix Zielcke <fzielcke@z-51.de>
6699 * Makefile.in (RMKFILES): Add `i386.rmk' and `x86_64-efi.rmk'.
6702 2008-09-09 Felix Zielcke <fzielcke@z-51.de>
6704 * util/hostdisk.c: Replace #include <grub/util/biosdisk.h> with
6705 #include <grub/util/hostdisk.h>.
6707 2008-09-08 Robert Millan <rmh@aybabtu.com>
6709 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Skip
6710 segments when their filesz is zero (grub_file_read() interprets
6711 zero-size as "read until EOF", which results in memory corruption).
6712 Use `lowest_segment' rather than 0 for calculating the current
6713 segment load address.
6715 2008-09-08 Robert Millan <rmh@aybabtu.com>
6717 * util/hostdisk.c (open_device): Replace a grub_util_info() call
6718 with grub_dprintf("hostdisk", ...), as it was so verbose that it
6719 clobbered useful information.
6721 2008-09-08 Robert Millan <rmh@aybabtu.com>
6723 * include/grub/util/biosdisk.h: Move to ...
6724 * include/grub/util/hostdisk.h: ... here. Update all users.
6725 * util/biosdisk.c: Move to ...
6726 * util/hostdisk.c: ... here. Update all users.
6728 2008-09-07 Robert Millan <rmh@aybabtu.com>
6730 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): Remove
6732 (grub_multiboot): Move `mbi' allocation upwards, so that mmap address
6733 and length can be stored directly in the `mbi->mmap_addr' and
6734 `mbi->mmap_length' struct fields.
6736 2008-09-07 Robert Millan <rmh@aybabtu.com>
6738 * conf/i386.rmk: New file. Provides declaration for building
6740 * conf/i386-pc.rmk (pkglib_MODULES): Remove `cpuid.mod'.
6741 (cpuid_mod_SOURCES, cpuid_mod_CFLAGS, cpuid_mod_LDFLAGS): Remove
6743 Include `conf/i386.mk'.
6744 * conf/i386-efi.rmk: Likewise.
6745 * conf/x86_64-efi.rmk: Likewise.
6746 * conf/i386-coreboot.rmk: Likewise.
6747 * conf/i386-ieee1275.rmk: Likewise.
6749 2008-09-07 Vesa Jääskeläinen <chaac@nic.fi>
6751 Based on patch created by Colin D Bennett <colin@gibibit.com>.
6752 Adds optimization support for BGR based modes.
6754 * include/grub/i386/pc/vbeblit.h (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8) Removed.
6755 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
6756 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
6757 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
6758 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
6759 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
6760 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
6761 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
6762 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
6763 (grub_video_i386_vbeblit_index_index): Likewise.
6764 (grub_video_i386_vbeblit_replace_directN): Added.
6765 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
6766 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
6767 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
6768 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
6769 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
6770 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
6771 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
6772 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
6773 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
6774 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
6775 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
6776 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
6777 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
6779 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8) Removed.
6780 (grub_video_i386_vbefill_R8G8B8): Likewise.
6781 (grub_video_i386_vbefill_index): Likewise.
6782 (grub_video_i386_vbefill_direct32): Added.
6783 (grub_video_i386_vbefill_direct24): Likewise.
6784 (grub_video_i386_vbefill_direct16): Likewise.
6785 (grub_video_i386_vbefill_direct8): Likewise.
6787 * include/grub/video.h (grub_video_blit_format): Removed
6788 GRUB_VIDEO_BLIT_FORMAT_R8G8B8A8, GRUB_VIDEO_BLIT_FORMAT_R8G8B8.
6789 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_RGBA_8888,
6790 GRUB_VIDEO_BLIT_FORMAT_BGRA_8888, GRUB_VIDEO_BLIT_FORMAT_RGB_888,
6791 GRUB_VIDEO_BLIT_FORMAT_BGR_888, GRUB_VIDEO_BLIT_FORMAT_RGB_565,
6792 GRUB_VIDEO_BLIT_FORMAT_BGR_565.
6794 * video/video.c (grub_video_get_blit_format): Updated to use new
6795 blit formats. Added handling for 16 bit color modes.
6797 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Updated to use new
6799 (common_blitter): Updated to use new blitters.
6801 * video/i386/pc/vbeblit.c (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8):
6803 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
6804 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
6805 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
6806 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
6807 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
6808 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
6809 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
6810 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
6811 (grub_video_i386_vbeblit_index_index): Likewise.
6812 (grub_video_i386_vbeblit_replace_directN): Added.
6813 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
6814 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
6815 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
6816 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
6817 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
6818 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
6819 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
6820 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
6821 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
6822 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
6823 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
6824 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
6825 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
6827 * video/i386/pc/vbefill.c (grub_video_i386_vbefill_R8G8B8A8): Removed.
6828 (grub_video_i386_vbefill_R8G8B8): Likewise.
6829 (grub_video_i386_vbefill_index): Likewise.
6830 (grub_video_i386_vbefill_direct32): Added.
6831 (grub_video_i386_vbefill_direct24): Likewise.
6832 (grub_video_i386_vbefill_direct16): Likewise.
6833 (grub_video_i386_vbefill_direct8): Likewise.
6835 * video/readers/jpeg.c (grub_jpeg_decode_sos): Adapt to new blitter
6838 * video/readers/tga.c (grub_video_reader_tga): Adapt to new blitter
6841 * video/readers/png.c (grub_png_decode_image_header): Adapt to new
6844 * video/bitmap.c (grub_video_bitmap_create): Adapt to new blitter
6847 2008-09-06 Felix Zielcke <fzielcke@z-51.de>
6849 * disk/raid.c (insert_array): Set `array->chunk_size' to 64 for
6852 2008-09-06 Felix Zielcke <fzielcke@z-51.de>
6854 * fs/iso9660.c (grub_iso9660_date): New structure.
6855 (grub_iso9660_primary_voldesc): Add `grub_iso9660_date' member.
6856 (grub_iso9660_uuid): New function.
6858 2008-09-05 Bean <bean123ch@gmail.com>
6860 * fs/fshelp.c (grub_fshelp_find_file): Handle case insensitive names.
6862 * fs/ntfs.c (list_file): Ignore names in DOS namespace, set the case
6863 insensitive bit for names in Win32 and Win32 & DOS namespace.
6865 * include/grub/fshelp.h (GRUB_FSHELP_CASE_INSENSITIVE): New macro.
6867 * include/grub/types.h (LONG_MAX): Likewise.
6869 2008-09-04 Felix Zielcke <fzielcke@z-51.de>
6871 * util/getroot.c: Include <config.h>.
6872 (grub_util_get_grub_dev): Rewrite to use asprintf for mdraid devices,
6873 add support for /dev/md/N devices and handle LVM double dash escaping.
6875 2008-09-04 Felix Zielcke <fzielcke@z-51.de>
6877 * config.guess: Update to latest version from config git.
6878 * config.sub: Likewise.
6880 2008-09-03 Robert Millan <rmh@aybabtu.com>
6882 * disk/scsi.c (grub_scsi_open): Remove size limit when printing
6883 `disk->total_sectors'.
6885 2008-09-01 Colin D Bennett <colin@gibibit.com>
6887 * include/grub/normal.h: Fixed incorrect comment for
6888 GRUB_COMMAND_FLAG_NO_ARG_PARSE.
6890 2008-09-01 Colin D Bennett <colin@gibibit.com>
6892 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Replaced constant
6893 values with defines.
6895 * include/grub/i386/pc/vbe.h (GRUB_VBE_MODEATTR_SUPPORTED): Added.
6896 (GRUB_VBE_MODEATTR_RESERVED_1): Likewise.
6897 (GRUB_VBE_MODEATTR_BIOS_TTY_OUTPUT_SUPPORT): Likewise.
6898 (GRUB_VBE_MODEATTR_COLOR): Likewise.
6899 (GRUB_VBE_MODEATTR_GRAPHICS): Likewise.
6900 (GRUB_VBE_MODEATTR_VGA_COMPATIBLE): Likewise.
6901 (GRUB_VBE_MODEATTR_VGA_WINDOWED_AVAIL): Likewise.
6902 (GRUB_VBE_MODEATTR_LFB_AVAIL): Likewise.
6903 (GRUB_VBE_MODEATTR_DOUBLE_SCAN_AVAIL): Likewise.
6904 (GRUB_VBE_MODEATTR_INTERLACED_AVAIL): Likewise.
6905 (GRUB_VBE_MODEATTR_TRIPLE_BUF_AVAIL): Likewise.
6906 (GRUB_VBE_MODEATTR_STEREO_AVAIL): Likewise.
6907 (GRUB_VBE_MODEATTR_DUAL_DISPLAY_START): Likewise.
6908 (GRUB_VBE_MEMORY_MODEL_TEXT): Likewise.
6909 (GRUB_VBE_MEMORY_MODEL_CGA): Likewise.
6910 (GRUB_VBE_MEMORY_MODEL_HERCULES): Likewise.
6911 (GRUB_VBE_MEMORY_MODEL_PLANAR): Likewise.
6912 (GRUB_VBE_MEMORY_MODEL_NONCHAIN4_256): Likewise.
6913 (GRUB_VBE_MEMORY_MODEL_YUV): Likewise.
6915 2008-08-31 Robert Millan <rmh@aybabtu.com>
6917 * loader/i386/pc/multiboot.c (grub_get_multiboot_mmap_len): Fix
6919 (grub_multiboot): Fix a few warnings.
6921 2008-08-31 Robert Millan <rmh@aybabtu.com>
6923 * loader/i386/pc/multiboot.c: Update comment not to say that
6924 boot_device support is unimplemented.
6926 2008-08-31 Robert Millan <rmh@aybabtu.com>
6928 * loader/i386/pc/multiboot.c: Update comment not to say that a.out
6929 or memory map support are unimplemented.
6931 2008-08-31 Colin D Bennett <colin@gibibit.com>
6933 * util/i386/pc/grub-mkrescue.in: Support multiple overlay directories.
6935 2008-08-31 Colin D Bennett <colin@gibibit.com>
6937 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Show VBE version and
6938 total video memory in 'vbeinfo' output; show color format details for
6941 2008-08-30 Pavel Roskin <proski@gnu.org>
6943 * util/genmoddep.c: Remove for real this time.
6944 * DISTLIST: Remove util/genmoddep.c.
6946 2008-08-30 Robert Millan <rmh@aybabtu.com>
6948 * kern/i386/pc/startup.S (multiboot_header): Force 4-byte alignment
6949 as required by Multiboot spec (it was already 4-byte aligned, but
6952 2008-08-29 Pavel Roskin <proski@gnu.org>
6954 * kern/powerpc/ieee1275/crt0.S: Rename to ...
6955 * kern/powerpc/ieee1275/startup.S: ... this.
6956 * conf/powerpc-ieee1275.rmk: Adjust for the above.
6957 * DISTLIST: Likewise.
6959 * kern/powerpc/ieee1275/crt0.S: Include grub/symbol.h and
6960 grub/cpu/kernel.h. Add start label for consistency with other
6961 platforms. Add grub_prefix immediately after start. Add jump
6962 to the code after grub_prefix.
6963 * include/grub/powerpc/kernel.h: Provide valid values for
6964 GRUB_KERNEL_CPU_PREFIX and GRUB_KERNEL_CPU_DATA_END.
6966 2008-08-29 Bean <bean123ch@gmail.com>
6968 * configure.ac: Change host_os to cygwin for mingw.
6969 (asprintf): New check for function.
6971 * include/grub/symbol.h: Replace #ifndef __CYGWIN__ with
6972 #if ! defined (__CYGWIN__) && ! defined (__MINGW32__).
6974 * include/grub/util/misc.h: #include <config.h> and <grub/types.h>,
6975 declare asprintf if HAVE_ASPRINTF is not set, declare fseeko, ftello,
6976 sync, sleep and grub_util_get_disk_size for mingw.
6978 * util/biosdisk.c (grub_util_biosdisk_open): Use grub_util_get_disk_size
6979 to get size in mingw.
6980 (open_device): Use flag O_BINARY if it's defined.
6981 (find_root_device): Add dummy code for mingw.
6983 * util/grub-mkdevicemap.c (get_floppy_disk_name): Return 0 for mingw.
6984 (get_ide_disk_name): Return //./PHYSICALDRIVE%d for mingw.
6985 (get_scsi_disk_name): Return 0 for mingw.
6987 * util/hostfs.c: #include <grub/util/misc.h>.
6988 (grub_hostfs_open): Use "rb" flag to open file, use
6989 grub_util_get_disk_size to get disk size for mingw.
6991 * util/misc.c: #include <windows.h> and <winioctl.h> in mingw.
6992 (asprintf): New function if HAVE_ASPRINTF is not set.
6993 (sync): New function for mingw.
6995 (grub_util_get_disk_size): Likewise.
6997 2008-08-28 Pavel Roskin <proski@gnu.org>
6999 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
7002 2008-08-28 Robert Millan <rmh@aybabtu.com>
7004 * util/biosdisk.c (find_grub_drive): Declare missing `i' variable.
7006 2008-08-28 Robert Millan <rmh@aybabtu.com>
7008 Change find_grub_drive() syntax so it doesn't prevent it from
7009 detecting NULL names as errors.
7011 * util/biosdisk.c (find_grub_drive): Move free slot search code
7013 (find_free_slot): ... to here.
7014 (read_device_map): Use find_free_slot() to search for free slots.
7016 2008-08-27 Marco Gerards <marco@gnu.org>
7018 * conf/common.rmk (pkglib_MODULES): Add scsi.mod.
7019 (scsi_mod_SOURCES): New variable.
7020 (scsi_mod_CFLAGS): Likewise
7021 (scsi_mod_LDFLAGS): Likewise.
7023 * disk/scsi.c: New file.
7025 * include/grub/scsi.h: Likewise.
7027 * include/grub/scsicmd.h: Likewise.
7029 * disk/ata.c: Include <grub/scsi.h>.
7030 (grub_atapi_packet): Do not use grub_ata_cmd, use registers
7032 (grub_ata_iterate): Skip ATAPI devices.
7033 (grub_ata_open): Only handle ATAPI devices.
7034 (struct grub_atapi_read): Removed.
7035 (grub_atapi_readsector): Likewise.
7036 (grub_ata_read): No longer handle ATAPI devices.
7037 (grub_ata_write): Likewise.
7038 (grub_atapi_iterate): New function.
7039 (grub_atapi_read): Likewise.
7040 (grub_atapi_write): Likewise.
7041 (grub_atapi_open): Likewise.
7042 (grub_atapi_close): Likewise.
7043 (grub_atapi_dev): New variable.
7044 (GRUB_MOD_INIT(ata)): Register ATAPI as SCSI device.
7045 (GRUB_MOD_FINI(ata)): Unregister ATAPI.
7047 * include/grub/disk.h (enum grub_disk_dev_id): Add
7048 `GRUB_DISK_DEVICE_SCSI_ID'.
7050 2008-08-26 Robert Millan <rmh@aybabtu.com>
7052 * util/biosdisk.c (grub_util_biosdisk_open, open_device)
7053 (grub_util_biosdisk_get_grub_dev): Make error messages a bit more
7056 2008-08-23 Bean <bean123ch@gmail.com>
7058 * conf/common.rmk (grub_probe_SOURCES): Add disk/mdraid_linux.c.
7059 (grub_fstest_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
7060 disk/mdraid_linux.c and disk/dmraid_nvidia.c and lib/crc.c.
7061 (pkglib_MODULES): Add raid5rec.mod, raid6rec.mod, mdraid.mod and
7063 (raid5rec_mod_SOURCES): New macro.
7064 (raid5rec_mod_CFLAGS): Likewise.
7065 (raid5rec_mod_LDFLAGS): Likewise.
7066 (raid6rec_mod_SOURCES): Likewise.
7067 (raid6rec_mod_CFLAGS): Likewise.
7068 (raid6rec_mod_LDFLAGS): Likewise.
7069 (mdraid_mod_SOURCES): Likewise.
7070 (mdraid_mod_CFLAGS): Likewise.
7071 (mdraid_mod_LDFLAGS): Likewise.
7072 (dm_nv_mod_SOURCES): Likewise.
7073 (dm_nv_mod_CFLAGS): Likewise.
7074 (dm_nv_mod_LDFLAGS): Likewise.
7076 * conf/i386-pc.rmk (grub_setup_SOURCES): Add disk/mdraid_linux.c.
7077 (grub_emu_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
7078 disk/mdraid_linux.c and disk/dmraid_nvidia.c.
7080 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add disk/raid5_recover.c,
7081 disk/raid6_recover.c, disk/mdraid_linux.c and disk/dmraid_nvidia.c.
7083 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
7085 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
7087 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7089 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7091 * disk/raid5_recover.c: New file.
7093 * disk/raid6_recover.c: Likewise.
7095 * disk/mdraid_linux.c: Likewise.
7097 * disk/dmraid_nvidia.c: Likewise.
7099 * disk/i386/pc/biosdisk.c: Set total_sectors of cdrom device to
7102 * disk/raid.c (grub_raid_open): Use the size of the smallest disk to
7103 calculate the size of raid device.
7104 (grub_raid_read): Simplify raid0 code. Support raid4, raid6 and four
7105 different layout of raid5.
7106 (grub_raid_scan_device): Remove code specific to mdraid.
7107 (grub_raid_list): New variable.
7108 (free_array): New function.
7109 (grub_raid_register): Likewise.
7110 (grub_raid_unregister): Likewise.
7111 (grub_raid_rescan): Likewise.
7112 (GRUB_MOD_INIT): Don't iterate device here.
7113 (GRUB_MOD_FINI): Use free_array to release resource.
7115 * include/grub/raid.h: Remove macro and structure specific to mdraid.
7116 (grub_raid5_recover_func_t): New function variable type.
7117 (grub_raid6_recover_func_t): Likewise.
7118 (grub_raid5_recover_func): New variable.
7119 (grub_raid6_recover_func): Likewise.
7120 (grub_raid_register): New function.
7121 (grub_raid_unregister): Likewise.
7122 (grub_raid_rescan): Likewise.
7123 (grub_raid_block_xor): Likewise.
7125 * util/grub-fstest.c: Add #include <grub/raid.h> and <grub/lib/crc.h>.
7126 (CMD_CRC): New macro.
7128 (read_file): Handle device as well as file.
7129 (cmd_crc): New function.
7130 (fstest): Handle multiple disks.
7131 (options): Remove part, raw and long, add root and diskcount.
7132 (usage): Add crc, remove -p, -r, -l, add -r and -c.
7133 (main): Find the first non option entry and ignore subsequent options,
7134 add handling for the new options, support multiple disks.
7136 * util/grub-probe.c (probe): Add mdraid to abstraction_name.
7138 2008-08-23 Bean <bean123ch@gmail.com>
7140 * normal/x86_64/setjmp.S (grub_longjmp): Return 1 when val = 0.
7142 * genfslist.sh: Ignore kernel.mod.
7144 * genpartmaplist.sh: Likewise.
7146 2008-08-23 Robert Millan <rmh@aybabtu.com>
7148 * util/getroot.c (find_root_device): Skip anything that starts with
7149 a dot, not just directories. This avoids things like /dev/.tmp.md0.
7151 2008-08-22 Felix Zielcke <fzielcke@z-51.de>
7153 * util/update-grub.in (GRUB_GFXMODE): Export variable.
7154 * util/grub.d/00_header.in: Allow the administrator to change default
7155 gfxmode via ${GRUB_GFXMODE}.
7157 2008-08-21 Felix Zielcke <fzielcke@z-51.de>
7159 * fs/ntfs.c (grub_ntfs_mount): Fix a memory leak.
7161 2008-08-21 Robert Millan <rmh@aybabtu.com>
7163 * loader/i386/linux.c: New file. Implements generic 32-bit Linux
7165 * conf/i386-coreboot.rmk (_linux_mod_SOURCES): Replace
7166 `loader/i386/pc/linux.c' with `loader/i386/linux.c'.
7168 2008-08-20 Carles Pina i Estany <carles@pina.cat>
7170 * menu/normal.c (run_menu): Replace hardcoded numbers with macros
7171 (16 for GRUB_TERM_UP and 14 for GRUB_TERM_DOWN)
7173 2008-08-19 Robert Millan <rmh@aybabtu.com>
7175 * term/gfxterm.c (DEFAULT_CURSOR_COLOR): Remove.
7176 (struct grub_virtual_screen): Remove `cursor_color'.
7177 (grub_virtual_screen_setup): Remove `virtual_screen.cursor_color'
7179 (write_cursor): Use `virtual_screen.fg_color' to draw cursor.
7181 2008-08-18 Robert Millan <rmh@aybabtu.com>
7183 Unify (identical) linux_normal.c files.
7184 * loader/i386/efi/linux_normal.c: Move from here ...
7185 * loader/linux_normal.c: ... to here. Update all users.
7186 * loader/i386/pc/linux_normal.c: Delete. Update all users.
7187 * loader/i386/ieee1275/linux_normal.c: Likewise.
7189 2008-08-18 Robert Millan <rmh@aybabtu.com>
7191 * include/grub/i386/linux.h (LINUX_LOADER_ID_LILO)
7192 (LINUX_LOADER_ID_LOADLIN, LINUX_LOADER_ID_BOOTSECT)
7193 (LINUX_LOADER_ID_SYSLINUX, LINUX_LOADER_ID_ETHERBOOT)
7194 (LINUX_LOADER_ID_ELILO, LINUX_LOADER_ID_GRUB, LINUX_LOADER_ID_UBOOT)
7195 (LINUX_LOADER_ID_XEN, LINUX_LOADER_ID_GUJIN, LINUX_LOADER_ID_QEMU):
7197 (GRUB_LINUX_CL_OFFSET, GRUB_LINUX_CL_END_OFFSET): Move from here ...
7198 * loader/i386/pc/linux.c (GRUB_LINUX_CL_OFFSET)
7199 (GRUB_LINUX_CL_END_OFFSET): ... to here.
7200 * loader/i386/efi/linux.c (GRUB_EFI_CL_OFFSET): Rename to ...
7201 (GRUB_LINUX_CL_OFFSET): ... this. Update all users.
7202 (GRUB_EFI_CL_END_OFFSET): Rename to ...
7203 (GRUB_LINUX_CL_END_OFFSET): ... this. Update all users.
7204 (grub_rescue_cmd_linux): Macroify `type_of_loader' initialization.
7205 Initialize `params->video_cursor_x' and `params->video_cursor_y'
7206 portably using grub_getxy().
7207 Replace `-EFI' with `-bzImage' in boot message.
7209 2008-08-17 Robert Millan <rmh@aybabtu.com>
7211 * include/grub/x86_64/kernel.h: New file (<grub/i386/kernel.h> stub).
7213 2008-08-17 Robert Millan <rmh@aybabtu.com>
7215 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pc/mmap.c'.
7217 * include/grub/i386/pc/init.h (GRUB_MACHINE_MEMORY_AVAILABLE)
7218 (GRUB_MACHINE_MEMORY_RESERVED): New macros.
7219 (grub_machine_mmap_iterate): New function declaration.
7220 * include/grub/multiboot.h (struct grub_multiboot_mmap_entry): New
7222 (GRUB_MMAP_MEMORY_AVAILABLE, GRUB_MMAP_MEMORY_RESERVED): New
7225 * kern/i386/pc/init.c (grub_machine_init): Replace hardcoded region
7226 type check value with `GRUB_MACHINE_MEMORY_AVAILABLE'.
7227 Move e820 parsing from here ...
7228 * kern/i386/pc/mmap.c: New file.
7229 (grub_machine_mmap_iterate): ... to here.
7231 * include/grub/i386/coreboot/memory.h: Remove `<grub/err.h>'.
7232 (GRUB_LINUXBIOS_MEMORY_AVAILABLE): Rename (for consistency) to ...
7233 (GRUB_MACHINE_MEMORY_AVAILABLE): ... this. Update all users.
7234 (grub_available_iterate): Redeclare to return `void', and redeclare
7235 its hook to use grub_uint64_t as addr and size parameters, and rename
7237 (grub_machine_mmap_iterate): ... this. Update all users.
7239 * kern/i386/coreboot/mmap.c (grub_mmap_iterate): Simplify parser loop
7240 to make it more readable. Rename to ...
7241 (grub_machine_mmap_iterate): ... this.
7243 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): New variables.
7244 (grub_get_multiboot_mmap_len, grub_fill_multiboot_mmap): New functions.
7245 (grub_multiboot): Allocate an extra region after the payload, and fill
7246 it with a Multiboot memory map. Adjust a.out loader to calculate size
7247 with the extra space.
7248 (grub_multiboot_load_elf32): Adjust elf32 loader to calculate size
7249 with the extra space.
7251 2008-08-17 Carles Pina i Estany <carles@pina.cat>
7253 * menu/normal.c (run_menu): Add Home and End keys in grub-menu.
7255 2008-08-17 Felix Zielcke <fzielcke@z-51.de>
7257 * gendistlist.sh: Add *.y, *.tex, *.texi, grub.cfg, README, *.sc,
7258 mdate-sh to the list `find' searches for.
7259 * DISTLIST: Regenerated.
7261 2008-08-16 Felix Zielcke <fzielcke@z-51.de>
7263 * gendistlist.sh (EXTRA_DISTFILES): Remove gensymlist.sh,
7264 genkernsyms.sh. Add geninit.sh, geninitheader.sh, genkernsyms.sh.in,
7265 genmoddep.awk, gensymlist.sh.in.
7266 (DISTDIRS): Add bus, docs, hook, lib.
7267 * DISTLIST: Regenerated.
7268 * NEWS: Add cygwin support and change the `os-prober' entry a bit.
7270 2008-08-16 Robert Millan <rmh@aybabtu.com>
7272 * disk/raid.c (grub_raid_init): Handle/report errors set by
7273 grub_device_iterate().
7274 * disk/lvm.c (grub_lvm_init): Likewise.
7276 2008-08-15 Bean <bean123ch@gmail.com>
7278 * conf/i386-pc.rmk (pkglib_MODULES): Add datetime.mod, date.mod
7280 (datetime_mod_SOURCES): New macro.
7281 (datetime_mod_CFLAGS): Likewise.
7282 (datetime_mod_LDFLAGS): Likewise.
7283 (date_mod_SOURCES): Likewise.
7284 (date_mod_CFLAGS): Likewise.
7285 (date_mod_LDFLAGS): Likewise.
7286 (datehook_mod_SOURCES): Likewise.
7287 (datehook_mod_CFLAGS): Likewise.
7288 (datehook_mod_LDFLAGS): Likewise.
7290 * conf/i386-coreboot.rmk (pkglib_MODULES): Add datetime.mod, date.mod
7292 (datetime_mod_SOURCES): New macro.
7293 (datetime_mod_CFLAGS): Likewise.
7294 (datetime_mod_LDFLAGS): Likewise.
7295 (date_mod_SOURCES): Likewise.
7296 (date_mod_CFLAGS): Likewise.
7297 (date_mod_LDFLAGS): Likewise.
7298 (datehook_mod_SOURCES): Likewise.
7299 (datehook_mod_CFLAGS): Likewise.
7300 (datehook_mod_LDFLAGS): Likewise.
7302 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add datetime.mod, date.mod
7304 (datetime_mod_SOURCES): New macro.
7305 (datetime_mod_CFLAGS): Likewise.
7306 (datetime_mod_LDFLAGS): Likewise.
7307 (date_mod_SOURCES): Likewise.
7308 (date_mod_CFLAGS): Likewise.
7309 (date_mod_LDFLAGS): Likewise.
7310 (datehook_mod_SOURCES): Likewise.
7311 (datehook_mod_CFLAGS): Likewise.
7312 (datehook_mod_LDFLAGS): Likewise.
7314 * conf/i386-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
7316 (datetime_mod_SOURCES): New macro.
7317 (datetime_mod_CFLAGS): Likewise.
7318 (datetime_mod_LDFLAGS): Likewise.
7319 (date_mod_SOURCES): Likewise.
7320 (date_mod_CFLAGS): Likewise.
7321 (date_mod_LDFLAGS): Likewise.
7322 (datehook_mod_SOURCES): Likewise.
7323 (datehook_mod_CFLAGS): Likewise.
7324 (datehook_mod_LDFLAGS): Likewise.
7326 * conf/x86_64-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
7328 (datetime_mod_SOURCES): New macro.
7329 (datetime_mod_CFLAGS): Likewise.
7330 (datetime_mod_LDFLAGS): Likewise.
7331 (date_mod_SOURCES): Likewise.
7332 (date_mod_CFLAGS): Likewise.
7333 (date_mod_LDFLAGS): Likewise.
7334 (datehook_mod_SOURCES): Likewise.
7335 (datehook_mod_CFLAGS): Likewise.
7336 (datehook_mod_LDFLAGS): Likewise.
7338 * kern/env.c (grub_env_insert): Fix a bug in prevp pointer.
7340 * commands/date.c: New file.
7342 * hook/datehook.c: Likewise.
7344 * include/grub/lib/datetime.h: Likewise.
7346 * include/grub/i386/cmos.h: Likewise.
7348 * lib/datetime.c: Likewise.
7350 * lib/i386/datetime.c: Likewise.
7352 * lib/efi/datetime.c: Likewise.
7354 2008-08-14 Robert Millan <rmh@aybabtu.com>
7356 * conf/common.rmk (bin_UTILITIES): Add `grub-mkelfimage'.
7357 (grub_mkelfimage_SOURCES): New variable.
7358 (util/elf/grub-mkimage.c_DEPENDENCIES): Likewise.
7360 * conf/i386-coreboot.rmk (bin_UTILITIES, grub_mkimage_SOURCES)
7361 (grub_mkimage_LDFLAGS, util/elf/grub-mkimage.c_DEPENDENCIES): Remove.
7362 * conf/powerpc-ieee1275.rmk: Likewise.
7363 * conf/i386-ieee1275.rmk: Likewise.
7365 * kern/ieee1275/init.c: Include `<grub/cpu/kernel.h>'.
7366 * kern/i386/coreboot/init.c: Likewise.
7368 * kern/i386/ieee1275/startup.S: Replace `<grub/machine/kernel.h>'
7369 with `<grub/cpu/kernel.h>'.
7370 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Renamed
7372 (GRUB_KERNEL_CPU_PREFIX, GRUB_KERNEL_CPU_DATA_END): ... this.
7373 * kern/i386/coreboot/startup.S: Likewise.
7375 * include/grub/powerpc/ieee1275/kernel.h (GRUB_MOD_ALIGN)
7376 (GRUB_MOD_GAP): Remove.
7377 * include/grub/powerpc/kernel.h: New file.
7378 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX)
7379 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
7380 * include/grub/i386/kernel.h: New file.
7381 * include/grub/i386/coreboot/kernel.h (GRUB_MOD_ALIGN)
7382 (GRUB_MOD_GAP, GRUB_KERNEL_MACHINE_PREFIX)
7383 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
7385 * util/ieee1275/grub-install.in (grub_mkimage): Initialize to use
7387 Use --directory when invoking grub_mkimage.
7389 * util/elf/grub-mkimage.c: Include `<grub/cpu/kernel.h>'.
7390 (add_segments): Replace GRUB_KERNEL_MACHINE_DATA_END and
7391 GRUB_KERNEL_MACHINE_PREFIX with GRUB_KERNEL_CPU_DATA_END
7392 and GRUB_KERNEL_CPU_PREFIX.
7394 2008-08-14 Felix Zielcke <fzielcke@z-51.de>
7396 * include/grub/err.h (grub_err_printf): New function prototype.
7397 * util/misc.c (grub_err_printf): New function.
7398 * kern/misc.c [! GRUB_UTIL] (grub_err_printf): New alias for
7400 * kern/err.c (grub_print_error): Use grub_err_printf.
7402 2008-08-13 Robert Millan <rmh@aybabtu.com>
7404 * docs/grub.cfg: Remove `/dev/' prefix in GNU/Hurd boot entry.
7406 2008-08-13 Robert Millan <rmh@aybabtu.com>
7408 * docs/grub.cfg: Use the native device name for the example GNU/Hurd
7411 2008-08-12 Robert Millan <rmh@aybabtu.com>
7413 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Move part
7414 of the relocation code from here ...
7415 (grub_multiboot): ... to here.
7416 (forward_relocator, backward_relocator): Move from here ...
7417 * kern/i386/loader.S (grub_multiboot_forward_relocator)
7418 (grub_multiboot_backward_relocator): ... to here.
7419 (grub_multiboot_real_boot): Use %edx for entry offset. Put Multiboot
7420 magic in %eax. Use %ebp for jumping (so %edx is not trashed).
7421 * include/grub/i386/loader.h (grub_multiboot_forward_relocator)
7422 (grub_multiboot_forward_relocator_end)
7423 (grub_multiboot_backward_relocator)
7424 (grub_multiboot_backward_relocator_end): New variables.
7426 2008-08-12 Bean <bean123ch@gmail.com>
7428 * disk/raid.c (grub_raid_read): Fix a bug in raid0 code.
7430 2008-08-11 Robert Millan <rmh@aybabtu.com>
7432 * kern/i386/linuxbios/startup.S: Move from here ...
7433 * kern/i386/coreboot/startup.S: ... to here.
7435 * kern/i386/linuxbios/init.c: Move from here ...
7436 * kern/i386/coreboot/init.c: ... to here.
7438 * kern/i386/linuxbios/table.c: Move from here ...
7439 * kern/i386/coreboot/mmap.c: ... to here.
7441 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Update moved files.
7443 2008-08-11 Robert Millan <rmh@aybabtu.com>
7445 * kern/device.c (grub_device_open): Do not handle grub_disk_open()
7446 errors. Leave it to the upper layer to handle them.
7448 2008-08-09 Christian Franke <franke@computer.org>
7450 * Makefile.in: Add `target_os' and `enable_grub_pe2elf'.
7451 * conf/common.rmk: Install `grub-pe2elf' only if requested.
7452 Install `grub.d/10_windows' only on Cygwin.
7453 * configure.ac: Add subst of `target_os'.
7454 Check `target_os' also before setting TARGET_OBJ2ELF.
7455 Add `--enable-grub-pe2elf'.
7457 2008-08-08 Robert Millan <rmh@aybabtu.com>
7459 * kern/disk.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
7460 (grub_last_time): Change type to grub_uint64_t.
7461 (grub_disk_open): Migrate code from to using grub_get_time_ms().
7462 (grub_disk_close): Likewise.
7464 * normal/menu.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
7465 (run_menu): Migrate code from to using grub_get_time_ms().
7467 * util/misc.c (grub_get_time_ms): New function.
7469 2008-08-08 Marco Gerards <marco@gnu.org>
7471 * disk/ata.c (grub_ata_regget): Change return type to
7473 (grub_ata_regget2): Likewise.
7474 (grub_ata_wait_status): New function.
7475 (grub_ata_wait_busy): Removed function, updated all users to use
7476 `grub_ata_wait_status'.
7477 (grub_ata_wait_drq): Likewise.
7478 (grub_ata_cmd): New function.
7479 (grub_ata_pio_read): Change return type to `grub_uint8_t'. Add
7481 (grub_ata_pio_write): Add error handling.
7482 (grub_atapi_identify): Likewise.
7483 (grub_atapi_packet): Use `grub_ata_cmd' and improve error
7485 (grub_ata_identify): Use `grub_ata_cmd' and improve error
7486 handling. Actually use the detected registers. Reorder the
7487 detection logic such that it is easier to read.
7488 (grub_ata_pciinit): Do not assign the same ID to each controller.
7489 (grub_ata_setaddress): Use `grub_ata_cmd' and improve error
7491 (grub_atapi_readsector): Check the result of `grub_ata_pio_read'.
7493 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TIMEOUT'.
7495 2008-08-08 Marco Gerards <marco@gnu.org>
7499 2008-08-07 Bean <bean123ch@gmail.com>
7501 * include/grub/x86_64/pci.h: New file.
7503 2008-08-07 Christian Franke <franke@computer.org>
7505 * kern/i386/pit.c (TIMER2_SPEAKER): New define.
7506 (TIMER2_GATE): Likewise.
7507 (grub_pit_wait): Add enable/disable of the timer2 gate
7508 bit of port 0x61. This fixes a possible infinite loop.
7510 2008-08-07 Bean <bean123ch@gmail.com>
7512 * conf/x86_64-efi.rmk (kernel_mod_SOURCES): Add kern/time.c,
7513 kern/i386/tsc.c and kern/i386/pit.c.
7515 * include/grub/i386/tsc.h (grub_cpu_is_cpuid_supported): Handle
7518 * kern/i386/efi/init.c: Replace <grub/cpu/tsc.h> with
7521 * kern/i386/pit.c: Replace <grub/cpu/io.h> with <grub/i386/io.h>.
7523 2008-08-07 Bean <bean123ch@gmail.com>
7525 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add kern/time.c.
7527 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add kern/time.c,
7529 * include/grub/i386/pit.h: Use macro KERNEL_CPU_PIT_HEADER to avoid
7530 multiple inclusion. Add #include <grub/types.h>.
7532 2008-08-06 Christian Franke <franke@computer.org>
7534 * conf/common.rmk: Build and install `10_windows'.
7535 * util/grub.d/10_windows.in: New script.
7537 2008-08-06 Pavel Roskin <proski@gnu.org>
7539 * kern/i386/pit.c: Include `<grub/i386/pit.h>'.
7541 2008-08-06 Robert Millan <rmh@aybabtu.com>
7543 * conf/i386-coreboot.rmk (kernel_elf_ASFLAGS): New variable.
7544 * kern/i386/tsc.c: Include `<grub/i386/pit.h>'.
7546 2008-08-06 Bean <bean123ch@gmail.com>
7548 * fs/i386/pc/pxe.c (grub_pxe_data): New member block_size.
7549 (grub_pxefs_fs_int): Remove dummy definition.
7550 (grub_pxefs_open): Use data->block_size to store the current block
7552 (grub_pxefs_read): Use block size stored in data->block_size. As the
7553 value of grub_pxe_blksize can be changed after the file is opened.
7555 2008-08-06 Bean <bean123ch@gmail.com>
7557 * fs/i386/pc/pxe.c (curr_file): new variable.
7558 (grub_pxefs_open): Simply the handling of pxe file system. Don't
7559 require the dummy internal file system anymore.
7560 (grub_pxefs_read): Removed.
7561 (grub_pxefs_close): Likewise.
7562 (grub_pxefs_fs_int): Likewise.
7563 (grub_pxefs_read_int): Renamed to grub_pxefs_read. Reinitialize tftp
7564 connection when we switch file.
7565 (grub_pxefs_close_int): Renamed to grub_pxefs_close.
7567 2008-08-06 Robert Millan <rmh@aybabtu.com>
7569 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `reboot.mod' and
7571 (reboot_mod_SOURCES, reboot_mod_CFLAGS, reboot_mod_LDFLAGS)
7572 (halt_mod_SOURCES, halt_mod_CFLAGS, halt_mod_LDFLAGS): New variables.
7574 * kern/i386/halt.c: New file.
7575 * kern/i386/reboot.c: Likewise.
7576 * include/grub/i386/reboot.h: Likewise.
7577 * include/grub/i386/halt.h: Likewise.
7579 * commands/halt.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]:
7580 Include `<grub/cpu/halt.h>'.
7581 * commands/reboot.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]
7582 [! GRUB_MACHINE_PCBIOS]: Include `<grub/cpu/reboot.h>'.
7584 * term/i386/pc/at_keyboard.c: Include `<grub/cpu/at_keyboard.h>'.
7585 (SHIFT_L, SHIFT_R, CTRL, ALT, CAPS_LOCK, KEYBOARD_REG_DATA)
7586 (KEYBOARD_REG_STATUS, KEYBOARD_COMMAND_ISREADY, KEYBOARD_COMMAND_READ)
7587 (KEYBOARD_COMMAND_WRITE, KEYBOARD_COMMAND_REBOOT)
7588 (KEYBOARD_SCANCODE_SET1, KEYBOARD_ISMAKE, KEYBOARD_ISREADY)
7589 (KEYBOARD_SCANCODE, OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): Move
7591 * include/grub/i386/at_keyboard.h: ... to here.
7593 2008-08-05 Robert Millan <rmh@aybabtu.com>
7595 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pit.c'.
7596 * conf/i386-efi.rmk (kernel_mod_SOURCES): Likewise.
7597 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Likewise. Also add
7598 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
7599 `kern/generic/millisleep.c'.
7601 * kern/i386/tsc.c (calibrate_tsc): Rewrite using grub_pit_wait()
7602 instead of grub_get_rtc().
7603 (grub_tsc_init): Initialize `tsc_boot_time'.
7605 * kern/i386/linuxbios/init.c (grub_millisleep): Remove stub.
7606 (grub_machine_init): Use grub_tsc_init() rather than
7607 installing an RTC-based handler via grub_install_get_time_ms().
7609 * kern/i386/pit.c: New file.
7610 * include/grub/i386/pit.h: Likewise.
7612 2008-08-05 Bean <bean123ch@gmail.com>
7614 * boot/i386/pc/pxeboot.S (_start): Use drive number 0x7F for pxe.
7616 * conf/i386-pc.rmk (kernel_img_HEADERS): Add machine/pxe.h.
7617 (pkglib_MODULES): Add pxe.mod and pxecmd.mod.
7618 (pxe_mod_SOURCES): New macro.
7619 (pxe_mod_CFLAGS): Likewise.
7620 (pxe_mod_LDFLAGS): Likewise.
7621 (pxecmd_mod_SOURCES): Likewise.
7622 (pxecmd_mod_CFLAGS): Likewise.
7623 (pxecmd_mod_LDFLAGS): Likewise.
7625 * kern/i386/pc/startup.S (grub_pxe_scan): New function.
7626 (grub_pxe_call): Likewise.
7628 * include/grub/disk.h (grub_disk_dev_id): Add GRUB_DISK_DEVICE_PXE_ID.
7630 * commands/i386/pc/pxecmd.c: New file.
7632 * fs/i386/pc/pxe.c: Likewise.
7634 * include/grub/i386/pc/pxe.h: Likewise.
7636 2008-08-05 Bean <bean123ch@gmail.com>
7638 * util/console.c (grub_console_cur_color): New variable.
7639 (grub_console_standard_color): Likewise.
7640 (grub_console_normal_color): Likewise.
7641 (grub_console_highlight_color): Likewise.
7642 (color_map): Likewise.
7643 (use_color): Likewise.
7644 (NUM_COLORS): New macro.
7645 (grub_ncurses_setcolorstate): Handle color properly.
7646 (grub_ncurses_setcolor): Don't change color here, just remember the
7647 settings, color will be set in grub_ncurses_setcolorstate.
7648 (grub_ncurses_getcolor): New function.
7649 (grub_ncurses_init): Initialize color pairs.
7650 (grub_ncurses_term): New member grub_ncurses_getcolor.
7652 2008-08-05 Colin D Bennett <colin@gibibit.com>
7654 High resolution timer support. Implemented for x86 CPUs using TSC.
7655 Extracted generic grub_millisleep() so it's linked in only as needed.
7656 This requires a Pentium compatible CPU; if the RDTSC instruction is
7657 not supported, then it falls back on the generic grub_get_time_ms()
7658 implementation that uses the machine's RTC.
7660 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/time.c',
7661 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
7662 `kern/generic/millisleep.c'.
7664 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add `kern/i386/tsc.c',
7665 `kern/generic/rtc_get_time_ms.c' and `kern/generic/millisleep.c'.
7667 * conf/x86_64-efi.rml (kernel_mod_SOURCES): Add
7668 `kern/generic/millisleep.c' and `kern/generic/rtc_get_time_ms.c'.
7670 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
7672 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
7673 `kern/generic/millisleep.c'.
7675 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
7677 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Add `kern/time.c'.
7679 * kern/generic/rtc_get_time_ms.c: New file.
7681 * kern/generic/millisleep.c: New file.
7683 * kern/misc.c: Don't include
7684 <kern/time.h> anymore.
7685 (grub_millisleep_generic): Removed.
7687 * commands/sleep.c (grub_interruptible_millisleep): Uses
7688 grub_get_time_ms() instead of grub_get_rtc().
7690 * include/grub/i386/tsc.h (grub_get_tsc): New file. New inline
7692 (grub_cpu_is_cpuid_supported): New inline function.
7693 (grub_cpu_is_tsc_supported): New inline function.
7694 (grub_tsc_init): New function prototype.
7695 (grub_tsc_get_time_ms): New function prototype.
7697 * kern/i386/tsc.c (grub_get_time_ms): New file.
7699 * include/grub/time.h: Include <grub/types.h.
7700 (grub_millisleep_generic): Removed.
7701 (grub_get_time_ms): New prototype.
7702 (grub_install_get_time_ms): New prototype.
7703 (grub_rtc_get_time_ms): New prototype.
7705 * kern/time.c (grub_get_time_ms): New function.
7706 (grub_install_get_time_ms): New function.
7708 * kern/i386/efi/init.c: Include <grub/cpu/tsc.h>. Don't include
7709 <grub/time.h> anymore.
7710 (grub_millisleep): Removed.
7711 (grub_machine_init): Call grub_tsc_init.
7713 * kern/i386/linuxbios/init.c (grub_machine_init): Install the RTC
7714 get_time_ms() implementation.
7716 * kern/sparc64/ieee1275/init.c (grub_millisleep): Removed.
7717 (ieee1275_get_time_ms): New function.
7718 (grub_machine_init): Install get_time_ms() implementation.
7720 * kern/i386/pc/init.c: Include <grub/cpu/tsc.h>.
7721 (grub_machine_init): Call grub_tsc_init().
7722 (grub_millisleep): Removed.
7724 * kern/ieee1275/init.c (grub_millisleep): Removed.
7725 (grub_machine_init): Install ieee1275_get_time_ms()
7727 (ieee1275_get_time_ms): New function.
7728 (grub_get_rtc): Now calls ieee1275_get_time_ms(), which does the
7731 2008-08-05 Marco Gerards <marco@gnu.org>
7733 * disk/ata.c: Include <grub/pci.h>.
7734 (enum grub_ata_commands): Add `GRUB_ATA_CMD_EXEC_DEV_DIAGNOSTICS'.
7735 (grub_ata_initialize): Rewritten.
7736 (grub_ata_device_initialize): New function.
7738 2008-08-04 Pavel Roskin <proski@gnu.org>
7740 * kern/main.c: Include grub/mm.h.
7742 2008-08-04 Robert Millan <rmh@aybabtu.com>
7744 * conf/i386-coreboot.rmk (COMMON_ASFLAGS, COMMON_CFLAGS)
7745 (COMMON_LDFLAGS): Harmonize with i386-pc version (fixes a code
7746 corruption problem).
7748 2008-08-04 Robert Millan <rmh@aybabtu.com>
7750 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Fix misc
7751 warnings introduced in my last commit.
7753 2008-08-03 Robert Millan <rmh@aybabtu.com>
7755 Make PCI available on all i386 architectures.
7757 * include/grub/i386/pc/pci.h: Move from here ...
7758 * include/grub/i386/pci.h: ... to here.
7760 * include/grub/i386/pc/pci.h: Remove.
7761 * include/grub/i386/efi/pci.h: Remove.
7762 * include/grub/x86_64/efi/pci.h: Remove.
7764 * include/grub/pci.h: Replace `<grub/machine/pci.h>' with
7767 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `pci' and `lspci'.
7768 (pci_mod_SOURCES, pci_mod_CFLAGS, pci_mod_LDFLAGS, lspci_mod_SOURCES)
7769 (lspci_mod_CFLAGS, lspci_mod_LDFLAGS): New variables.
7771 * conf/i386-ieee1275.rmk: Likewise.
7773 2008-08-03 Robert Millan <rmh@aybabtu.com>
7775 * term/i386/pc/vga_text.c (CRTC_CURSOR_DISABLE): New macro.
7776 (grub_console_setcursor): Make it possible to set cursor off.
7778 2008-08-03 Robert Millan <rmh@aybabtu.com>
7780 * util/grub.d/00_header.in: Be platform-agnostic. Probe for existence
7781 of modules instead of assuming which platform provides what.
7782 * util/update-grub.in: Likewise.
7784 2008-08-03 Robert Millan <rmh@aybabtu.com>
7786 * kern/i386/pc/init.c (make_install_device): Check for `grub_prefix'
7787 instead of `grub_install_dos_part' to determine whether a drive needs
7788 to be prepended to prefix (`grub_install_dos_part' is not reliable,
7789 because it can be overridden when loading GRUB via Multiboot).
7791 2008-08-02 Robert Millan <rmh@aybabtu.com>
7793 * util/i386/pc/grub-install.in: Remove trailing slash from prefix.
7795 2008-08-02 Robert Millan <rmh@aybabtu.com>
7797 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Add a pair
7798 of informational grub_dprintf() calls.
7800 2008-08-02 Robert Millan <rmh@aybabtu.com>
7802 * disk/memdisk.c (memdisk_size): Don't initialize.
7803 (GRUB_MOD_INIT(memdisk)): Find memdisk using grub_module_iterate().
7805 * include/grub/i386/pc/kernel.h
7806 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): Remove macro.
7807 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Shift.
7808 (grub_memdisk_image_size, grub_arch_memdisk_addr)
7809 (grub_arch_memdisk_size): Remove.
7811 * include/grub/kernel.h (struct grub_module_header): Remove `offset'
7812 field (was only used to transfer a constant). Add `type' field to
7813 support multiple module types.
7814 (grub_module_iterate): New function.
7816 * kern/device.c (grub_device_open): Do not hide error messages
7817 when grub_disk_open() fails. Use grub_print_error() instead.
7819 * kern/i386/pc/init.c (grub_arch_modules_addr)
7820 (grub_arch_memdisk_size): Remove functions.
7821 (grub_arch_modules_addr): Return the module address in high memory
7822 (now that it isn't copied anymore).
7824 * kern/i386/pc/startup.S (grub_memdisk_image_size): Remove variable.
7825 (codestart): Don't add grub_memdisk_image_size to %ecx in LZMA
7826 decompression routine (grub_total_module_size already includes that
7827 now). Don't copy modules back to low memory.
7829 * kern/main.c: Include `<grub/mm.h>'.
7830 (grub_load_modules): Split out (and use) ...
7831 (grub_module_iterate): ... this function, which iterates through
7832 module objects and runs a hook.
7833 Comment out grub_mm_init_region() call, as it would cause non-ELF
7834 modules to be overwritten.
7836 * util/i386/pc/grub-mkimage.c (generate_image): Instead of appending
7837 the memdisk image in its own region, make it part of the module list.
7838 * util/elf/grub-mkimage.c (options): Add "memdisk"|'m' option.
7839 (main): Parse --memdisk|-m option, and pass user-provided path as
7840 parameter to generate_image().
7841 (add_segments): Pass `memdisk_path' down to load_modules().
7842 (load_modules): Embed memdisk image in module section when requested.
7843 * util/i386/efi/grub-mkimage.c (make_mods_section): Initialize
7844 `header.type' instead of `header.offset'.
7846 * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add `memdisk.mod'.
7847 (memdisk_mod_SOURCES, memdisk_mod_CFLAGS)
7848 (memdisk_mod_LDFLAGS): New variables.
7849 * conf/i386-coreboot.rmk: Likewise.
7850 * conf/i386-ieee1275.rmk: Likewise.
7852 2008-08-02 Robert Millan <rmh@aybabtu.com>
7854 * loader/i386/pc/multiboot.c (playground, forward_relocator)
7855 (backward_relocator): New variables. Used to allocate and relocate
7856 the payload, respectively.
7857 (grub_multiboot_load_elf32): Load into heap instead of requested
7858 address, install the appropriate relocator code in each bound of
7859 the payload, and set the entry point such that
7860 grub_multiboot_real_boot() will jump to one of them.
7862 * kern/i386/loader.S (grub_multiboot_payload_size)
7863 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
7864 (grub_multiboot_payload_entry_offset): New variables.
7865 (grub_multiboot_real_boot): Set cpu context to what the relocator
7866 expects, and jump to the relocator instead of the payload.
7868 * include/grub/i386/loader.h (grub_multiboot_payload_size)
7869 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
7870 (grub_multiboot_payload_entry_offset): Export.
7872 2008-08-01 Bean <bean123ch@gmail.com>
7874 * normal/menu_entry.c (editor_getline): Don't return the original
7875 string as result, as it will be released by lexer once it has done
7878 2008-08-01 Robert Millan <rmh@aybabtu.com>
7880 * util/grub.d/10_linux.in: Use prepare_grub_to_access_device() from
7881 within menuentries, not before them.
7882 util/grub.d/10_hurd.in: Likewise.
7884 2008-08-01 Bean <bean123ch@gmail.com>
7886 * conf/common.rmk (pkglib_MODULES): Add bufio.mod.
7887 (bufio_mod_SOURCES): New macro.
7888 (bufio_mod_CFLAGS): Likewise.
7889 (bufio_mod_LDFLAGS): Likewise.
7891 * include/grub/bufio.h: New file.
7893 * io/bufio.c: Likewise.
7895 * video/png.c: Replace <grub/file.h> with <grub/bufio.h>.
7896 (grub_video_reader_png): Use grub_buffile_open to open file.
7898 * video/jpeg.c: Replace <grub/file.h> with <grub/bufio.h>.
7899 (grub_video_reader_jpeg): Use grub_buffile_open to open file.
7901 * video/tga.c: Replace <grub/file.h> with <grub/bufio.h>.
7902 (grub_video_reader_tga): Use grub_buffile_open to open file.
7904 * font/manager.c: Include <grub/bufio.h>.
7905 (add_font): Use grub_buffile_open to open file.
7907 2008-07-31 Robert Millan <rmh@aybabtu.com>
7909 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): When loading
7910 ELF segments, use a macro for arbitrarily accessing any of them instead
7911 of preparing a pointer that allows access to one at a time.
7912 (grub_multiboot_load_elf64): Likewise.
7914 2008-07-31 Bean <bean123ch@gmail.com>
7916 * boot/i386/pc/lnxboot.S (real_code_2): Replace 0x50 with
7917 GRUB_KERNEL_MACHINE_DATA_END.
7919 2008-07-30 Robert Millan <rmh@aybabtu.com>
7921 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_DATA_END):
7922 Increase from 0x50 to 0x60.
7923 * util/i386/pc/grub-install.in: Detect cross-disk installs, and
7924 use UUIDs to identify the root drive for them. If that's not
7926 * util/i386/pc/grub-setup.c (setup): Do not special-case, or even
7927 check, for cross-disk installs.
7929 2008-07-30 Robert Millan <rmh@aybabtu.com>
7931 * kern/ieee1275/init.c (grub_machine_set_prefix): If `grub_prefix'
7932 is non-empty, use it to set the `prefix' environment variable instead
7933 of the usual approach.
7934 * kern/i386/linuxbios/init.c (make_install_device): Remove function.
7935 (grub_machine_set_prefix): Use `grub_prefix' to set the `prefix'
7936 environment variable instead of dummy make_install_device().
7938 * kern/i386/ieee1275/startup.S: Include `<grub/machine/kernel.h>'.
7939 (start): Insert a data section, with `grub_prefix' variable.
7940 * kern/i386/linuxbios/startup.S: Likewise.
7942 * include/grub/powerpc/ieee1275/kernel.h [!ASM_FILE] (grub_prefix):
7943 New variable reference.
7944 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX):
7945 New macro. Defines offset of `grub_prefix' within startup.S (relative
7947 (GRUB_KERNEL_MACHINE_DATA_END): New macro. Defines the end of data
7948 section within startup.S (relative to `start').
7949 * include/grub/i386/coreboot/kernel.h: Likewise.
7951 * util/elf/grub-mkimage.c (add_segments): Receive `prefix' parameter.
7952 Overwrite grub_prefix with its contents, at the beginning of the
7954 (main): Understand -p|--prefix.
7956 2008-07-30 Robert Millan <rmh@aybabtu.com>
7958 * util/grub.d/10_hurd.in: Source ${libdir}/grub/update-grub_lib.
7960 2008-07-30 Robert Millan <rmh@aybabtu.com>
7962 * term/i386/pc/vga_text.c (grub_console_cls): Use
7963 grub_console_gotoxy() to go back to beginning of the screen.
7964 Found by Patrick Georgi <patrick.georgi@coresystems.de>
7966 2008-07-29 Christian Franke <franke@computer.org>
7968 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
7969 Add conversion of emulated mount points on Cygwin.
7971 2008-07-29 Christian Franke <franke@computer.org>
7973 * util/update-grub.in: Add a check for admin
7975 Remove old `grub.cfg.new' before creation.
7976 Add `-f' to `mv' to handle the different filesystem
7977 semantics of Windows.
7979 2008-07-29 Bean <bean123ch@gmail.com>
7981 * normal/main.c (get_line): Fix buffer overflow bug.
7983 2008-07-28 Robert Millan <rmh@aybabtu.com>
7985 * partmap/apple.c (GRUB_APPLE_HEADER_MAGIC): New macro.
7986 (struct grub_apple_header): New struct. Describes the layout of
7988 (apple_partition_map_iterate): Check the header magic as well as the
7989 partition magic (which was already being checked).
7991 2008-07-28 Pavel Roskin <proski@gnu.org>
7993 * genmk.rb: Add a warning to the beginning of the output that
7994 it's a generated file and should not be edited.
7996 2008-07-28 Robert Millan <rmh@aybabtu.com>
7998 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
7999 with the same number are found, just use issue a warning with
8000 grub_dprintf(), as this error has been reported to be non-fatal.
8002 2008-07-27 Robert Millan <rmh@aybabtu.com>
8004 * disk/ata.c (grub_ata_dumpinfo): Use grub_dprintf() for debugging
8007 2008-07-27 Bean <bean123ch@gmail.com>
8009 * fs/fat.c (GRUB_FAT_MAXFILE): New constant.
8010 (grub_fat_find_dir): Ignore case when comparing filename.
8012 2008-07-27 Bean <bean123ch@gmail.com>
8014 * fs/xfs.c (grub_xfs_dir_header): Change field i8count back to
8015 smallino, as it's more descriptive, and i8count can be confused with
8016 the other field count.
8017 (grub_xfs_iterate_dir): Adjust grub_xfs_dir_entry pointer for small
8020 2008-07-27 Bean <bean123ch@gmail.com>
8022 * commands/crc.c: New file.
8024 * lib/crc.c: Likewise.
8026 * include/grub/lib/crc.h: Likewise.
8028 * util/grub-fstest.c: grub/hexdump.h => grub/lib/hexdump.h.
8030 * commands/hexdump.c: grub/hexdump.h => grub/lib/hexdump.h.
8031 (hexdump): Move this function to ...
8033 * lib/hexdump.c: ... here.
8035 * include/grub/hexdump.h: Renamed to ...
8037 * include/grub/lib/hexdump.h: ... this.
8039 * commands/loadenv.c: grub/envblk.h => grub/lib/envblk.h
8041 * util/grub-editenv.c: Likewise.
8043 * include/envblk.h: Renamed to ...
8045 * include/lib/envblk.h: ... this.
8047 * util/envblk.c: Renamed to ...
8049 * lib/envblk.c: ... this.
8051 * conf/common.rmk (grub_fstest_SOURCES): commands/hexdump.c =>
8053 (grub_editenv_SOURCES): util/envblk.c => lib/envblk.c
8054 (pkglib_MODULES): Add crc.mod.
8055 (hexdump_mod_SOURCES): Add lib/hexdump.c.
8056 (loadenv_mod_SOURCES): util/envblk.c => lib/envblk.c.
8057 (crc_mod_SOURCES): New macro.
8058 (crc_mod_CFLAGS): Likewise.
8059 (crc_mod_LDFLAGS): Likewise.
8061 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add lib/hexdump.c.
8063 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
8065 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
8067 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8069 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
8071 2008-07-27 Felix Zielcke <fzielcke@z-51.de>
8073 * commands/help.c: Include <grub/term.h>.
8074 (TERM_WIDTH): Removed. Updated all users.
8076 2008-07-27 Pavel Roskin <proski@gnu.org>
8078 * util/getroot.c (find_root_device): Rephrase a comment to avoid
8079 spurious warnings about a comment within a comment.
8081 2008-07-25 Robert Millan <rmh@aybabtu.com>
8083 * util/getroot.c (find_root_device): Skip devices that match
8084 /dev/dm-[0-9]. This lets the real device be found for any type of
8085 abstraction (LVM, EVMS, RAID..).
8086 (grub_guess_root_device): Do not traverse /dev/mapper (for LVM)
8087 and /dev/evms (for EVMS) before traversing /dev. If a /dev/dm-[0-9]
8088 device is found first, find_root_device() will now skip it.
8090 2008-07-24 Pavel Roskin <proski@gnu.org>
8092 * include/grub/types.h: Use __builtin_bswap32() and
8093 __builtin_bswap64() with gcc 4.3 and newer.
8095 2008-07-24 Christian Franke <franke@computer.org>
8097 * util/i386/pc/grub-install.in: If `--debug' is specified,
8098 pass `--verbose' to grub-setup.
8099 Abort script if make_system_path_relative_to_its_root() fails.
8101 2008-07-24 Bean <bean123ch@gmail.com>
8103 * configure.ac: Fixed a bug caused by the previous cygwin patch,
8104 variable `target_platform' should be `platform'.
8106 2008-07-24 Bean <bean123ch@gmail.com>
8108 * video/reader/png.c (DEFLATE_HLIT_MAX): Change value.
8109 (grub_png_init_fixed_block): New function.
8110 (grub_png_decode_image_data): Handle fixed huffman code compression.
8112 2008-07-24 Bean <bean123ch@gmail.com>
8114 * common.rmk (bin_UTILITIES): Add grub-pe2elf.
8115 (grub_pe2elf_SOURCES): New macro.
8116 (CLEANFILES): Add grub-pe2elf.
8118 * include/grub/efi/pe32.h (GRUB_PE32_SCN_ALIGN_1BYTES): New constant.
8119 (GRUB_PE32_SCN_ALIGN_2BYTES): Likewise.
8120 (GRUB_PE32_SCN_ALIGN_4BYTES): Likewise.
8121 (GRUB_PE32_SCN_ALIGN_8BYTES): Likewise.
8122 (GRUB_PE32_SCN_ALIGN_16BYTES): Likewise.
8123 (GRUB_PE32_SCN_ALIGN_32BYTES): Likewise.
8124 (GRUB_PE32_SCN_ALIGN_64BYTES): Likewise.
8125 (GRUB_PE32_SCN_ALIGN_SHIFT): Likewise.
8126 (GRUB_PE32_SCN_ALIGN_MASK): Likewise.
8127 (GRUB_PE32_SYM_CLASS_EXTERNAL): Likewise.
8128 (GRUB_PE32_SYM_CLASS_STATIC): Likewise.
8129 (GRUB_PE32_SYM_CLASS_FILE): Likewise.
8130 (GRUB_PE32_DT_FUNCTION): Likewise.
8131 (GRUB_PE32_REL_I386_DIR32): Likewise.
8132 (GRUB_PE32_REL_I386_REL32): Likewise.
8133 (grub_pe32_symbol): New structure.
8134 (grub_pe32_reloc): Likewise.
8136 * util/grub-pe2elf.c: New file.
8138 * configure.ac: Set TARGET_OBJ2ELF if host os is cygwin. Don't test for
8139 start symbol in non pc platform.
8141 * genmk.rb: Use TARGET_OBJ2ELF to convert native object format to elf.
8143 The following patches are from Christian Franke.
8145 * include/grub/dl.h: Remove .previous, gas supports this only
8148 * include/grub/symbol.h [__CYGWIN__] (#define FUNCTION/VARIABLE):
8149 Remove .type, gas supports this only for ELF format.
8151 * kern/dl.c (grub_dl_resolve_dependencies): Add check for trailing
8152 nullbytes in symbol table. This fixes an infinite loop if table is
8155 * Makefile.in: Add autoconf replacements TARGET_IMG_LDSCRIPT,
8156 TARGET_IMG_LDFLAGS and EXEEXT.
8158 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Replace -Wl,-N by
8159 TARGET_IMG_LDFLAGS_AC.
8160 (grub_CHECK_STACK_ARG_PROBE): New function.
8162 * conf/i386-pc.rmk: Replace -Wl,-N by TARGET_IMG_LDFLAGS.
8164 * conf/i386-pc-cygwin-ld-img.sc: New linker script.
8166 * configure.ac: Add check for linker script "conf/${target}-img-ld.c"
8167 to set TARGET_IMG_LD* accordingly.
8168 Add check for Cygwin to set TARGET_MOD_OBJCOPY accordingly.
8169 Add call to grub_CHECK_STACK_ARG_PROBE.
8170 Use TARGET_IMG_LDFLAGS to check start, bss_start, end symbols.
8172 * genkernsyms.sh.in: Handle HAVE_ASM_USCORE case.
8174 * genmk.rb: Add EXEEXT to CLEANFILES.
8176 2008-07-23 Robert Millan <rmh@aybabtu.com>
8178 * Makefile.in (UNICODE_ARROWS, UNICODE_LINES): New variables (they
8179 define the codes for arrows and lines used for the menu).
8180 (ascii.pff): Generate fonts for $(UNICODE_ARROWS) and $(UNICODE_LINES)
8183 * util/update-grub_lib.in (font_path): Prefer ascii.pff over complete
8184 fonts, because the latter are too slow.
8186 2008-07-21 Bean <bean123ch@gmail.com>
8188 * kern/i386/pc/startup.S (gate_a20_try_bios): Change test order for
8189 a20. Run keyboard test last, as it will cause macbook to halt.
8191 2008-07-18 Pavel Roskin <proski@gnu.org>
8193 * kern/dl.c: Go back to using GRUB_CPU_SIZEOF_VOID_P. We cannot
8194 load foreign architecture modules correctly anyway. Keep
8195 support for loading host architecture modules, whether we
8196 compile them or not.
8198 2008-07-17 Pavel Roskin <proski@gnu.org>
8200 * configure.ac: Use -m32 or -m64 regardless of whether we had to
8201 change target_cpu. The compiler default can mismatch target_cpu
8204 * disk/efi/efidisk.c: Fix format warnings on x86_64.
8205 * kern/efi/efi.c: Likewise.
8207 * aclocal.m4 (grub_PROG_TARGET_CC): New macro. Check if the
8208 target compiler is functional.
8209 * configure.ac: Call grub_PROG_TARGET_CC once all target flags
8212 * configure.ac: Default to efi platform for x86_64-apple. Allow
8213 powerpc64 CPU, default to ieee1275 platform for it. Split CPU
8214 adjustments from the rest, only do them if target is not
8215 explicitly given. Merge other adjustments with the final sanity
8216 check. Remove an extraneous check for supported CPU. Be
8217 specific which CPU and which platform is not supported.
8219 * configure.ac: Default to pc platform for x86_64.
8221 2008-07-17 Robert Millan <rmh@aybabtu.com>
8223 Partial LinuxBIOS -> Coreboot rename.
8225 * conf/i386-linuxbios.rmk: Renamed to ...
8226 * conf/i386-coreboot.rmk: ... this.
8227 * Makefile.in (RMKFILES): s/i386-linuxbios.rmk/i386-coreboot.rmk/g.
8228 * configure.ac: Accept "coreboot" as input platform (but maintain
8229 compatibility with "linuxbios").
8230 * include/grub/i386/linuxbios: Renamed to ...
8231 * include/grub/i386/coreboot: ... this.
8233 2008-07-17 Bean <bean123ch@gmail.com>
8235 * conf/i386/efi.rmk (pkglib_MODULES): add pci.mod and lspci.mod.
8236 (appleldr_mod_SOURCE): New variable.
8237 (appleldr_mod_CFLAGS): Likewise.
8238 (appleldr_mod_LDFLAGS): Likewise.
8239 (pci_mod_SOURCES): Likewise.
8240 (pci_mod_CFLAGS): Likewise.
8241 (pci_mod_LDFLAGS): Likewise.
8242 (lspci_mod_SOURCES): Likewise.
8243 (lspci_mod_CFLAGS): Likewise.
8244 (lspci_mod_LDFLAGS): Likewise.
8246 * conf/x86_64-efi.rmk: New file.
8248 * disk/efi/efidisk.c (grub_efidisk_read): Wrap efi calls with efi_call_N
8250 (grub_efidisk_write): Likewise.
8252 * include/efi/api.h (efi_call_0): New macro.
8253 (efi_call_1): Likewise.
8254 (efi_call_2): Likewise.
8255 (efi_call_3): Likewise.
8256 (efi_call_4): Likewise.
8257 (efi_call_5): Likewise.
8258 (efi_call_6): Likewise.
8260 * include/grub/efi/chainloader.h (grub_chainloader_cmd): Rename to
8261 grub_rescue_cmd_chainloader.
8263 * include/grub/efi/pe32.h (GRUB_PE32_MACHINE_X86_64): New macro.
8264 (grub_pe32_optional_header): Change some fields based on i386 or
8266 (GRUB_PE32_PE32_MAGIC): Likewise.
8268 * include/grub/efi/uga_draw.h: New file.
8270 * include/grub/elf.h (STN_ABS): New constant.
8271 (R_X86_64_NONE): Relocation constant for x86_64.
8272 (R_X86_64_64): Likewise.
8273 (R_X86_64_PC32): Likewise.
8274 (R_X86_64_GOT32): Likewise.
8275 (R_X86_64_PLT32): Likewise.
8276 (R_X86_64_COPY): Likewise.
8277 (R_X86_64_GLOB_DAT): Likewise.
8278 (R_X86_64_JUMP_SLOT): Likewise.
8279 (R_X86_64_RELATIVE): Likewise.
8280 (R_X86_64_GOTPCREL): Likewise.
8281 (R_X86_64_32): Likewise.
8282 (R_X86_64_32S): Likewise.
8283 (R_X86_64_16): Likewise.
8284 (R_X86_64_PC16): Likewise.
8285 (R_X86_64_8): Likewise.
8286 (R_X86_64_PC8): Likewise.
8288 * include/grub/i386/efi/pci.h: New file.
8290 * include/grub/i386/linux.h (GRUB_LINUX_EFI_SIGNATURE):
8291 Change it value based on platform.
8292 (GRUB_LINUX_EFI_SIGNATURE_0204): New constant.
8293 (GRUB_E820_RAM): Likewise.
8294 (GRUB_E820_RESERVED): Likewise.
8295 (GRUB_E820_ACPI): Likewise.
8296 (GRUB_E820_NVS): Likewise.
8297 (GRUB_E820_EXEC_CODE): Likewise.
8298 (GRUB_E820_MAX_ENTRY): Likewise.
8299 (grub_e820_mmap): New structure.
8300 (linux_kernel_header): Change the efi field according to different
8301 kernel version, also field from linux_kernel_header.
8303 * include/grub/kernel.h (grub_module_info): Add padding for x86_64.
8305 * include/grub/pci.h (GRUB_PCI_ADDR_SPACE_MASK): New constant.
8306 (GRUB_PCI_ADDR_SPACE_MEMORY): Likewise.
8307 (GRUB_PCI_ADDR_SPACE_IO): Likewise.
8308 (GRUB_PCI_ADDR_MEM_TYPE_MASK): Likewise.
8309 (GRUB_PCI_ADDR_MEM_TYPE_32): Likewise.
8310 (GRUB_PCI_ADDR_MEM_TYPE_1M): Likewise.
8311 (GRUB_PCI_ADDR_MEM_TYPE_64): Likewise.
8312 (GRUB_PCI_ADDR_MEM_PREFETCH): Likewise.
8313 (GRUB_PCI_ADDR_MEM_MASK): Likewise.
8314 (GRUB_PCI_ADDR_IO_MASK): Likewise.
8316 * include/grub/x86_64/efi/kernel.h: New file.
8318 * include/grub/x86_64/efi/loader.h: Likewise.
8320 * include/grub/x86_64/efi/machine.h: Likewise.
8322 * include/grub/x86_64/efi/pci.h: Likewise.
8324 * include/grub/x86_64/efi/time.h: Likewise.
8326 * include/grub/x86_64/linux.h: Likewise.
8328 * include/grub/x86_64/setjmp.h: Likewise.
8330 * include/grub/x86_64/time.h: Likewise.
8332 * include/grub/x86_64/types.h: Likewise.
8334 * kern/dl.c (GRUB_CPU_SIZEOF_VOID_P): Changed to
8335 GRUB_TARGET_SIZEOF_VOID_P.
8337 * kern/efi/efi.c (grub_efi_locate_protocol): Wrap efi calls.
8338 (grub_efi_locate_handle): Likewise.
8339 (grub_efi_open_protocol): Likewise.
8340 (grub_efi_set_text_mode): Likewise.
8341 (grub_efi_stall): Likewise.
8342 (grub_exit): Likewise.
8343 (grub_reboot): Likewise.
8344 (grub_halt): Likewise.
8345 (grub_efi_exit_boot_services): Likewise.
8346 (grub_get_rtc): Likewise.
8348 * kern/efi/mm.c (MEMORY_MAP_SIZE): Change to 0x3000 for new models.
8349 (GRUB_CPU_SIZEOF_VOID_P): Changed to GRUB_TARGET_SIZEOF_VOID_P.
8350 (grub_efi_allocate_pages): Wrap efi calls.
8351 (grub_efi_free_pages): Wrap efi calls.
8352 (grub_efi_get_memory_map): Wrap efi calls.
8354 * kern/x86_64/dl.c: New file.
8356 * kern/x86_64/efi/callwrap.S: Likewise.
8358 * kern/x86_64/efi/startup.S: Likewise.
8360 * loader/efi/appleloader.c: Likewise.
8362 * loader/efi/chainloader.c (cmdline): New variable.
8363 (grub_chainloader_unload): Wrap efi calls.
8364 (grub_chainloader_boot): Likewise.
8365 (grub_rescue_cmd_chainloader): Wrap efi calls, handle
8368 * loader/efi/chainloader_normal.c (chainloader_command):
8369 Change grub_chainloader_cmd to grub_rescue_cmd_chainloader, pass
8372 * loader/i386/efi/linux.c (allocate_pages): Change allocation
8374 (grub_e820_add_region): New function.
8375 (grub_linux_boot): Construct e820 map from efi map, handle x86_64
8377 (grub_find_video_card): New function.
8378 (grub_linux_setup_video): New function.
8379 (grub_rescue_cmd_linux): Probe for video information.
8381 * normal/x86_64/setjmp.S: New file.
8383 * term/efi/console.c (map_char): New function.
8384 (grub_console_putchar): Map unicode char.
8385 (grub_console_checkkey): Wrap efi calls.
8386 (grub_console_getkey): Likewise.
8387 (grub_console_getwh): Likewise.
8388 (grub_console_gotoxy): Likewise.
8389 (grub_console_cls): Likewise.
8390 (grub_console_setcolorstate): Likewise.
8391 (grub_console_setcursor): Likewise.
8393 * util/i386/efi/grub-mkimage.c: Add support for x86_64.
8395 2008-07-16 Pavel Roskin <proski@gnu.org>
8397 * loader/i386/efi/linux.c (allocate_pages): Fix warnings in
8400 * util/i386/efi/grub-mkimage.c (get_target_address): Return a
8401 pointer, not an integer. This fixes a warning and prevents
8402 precision loss on 64-bit systems.
8403 (relocate_addresses): Remove unneeded cast.
8405 2008-07-15 Pavel Roskin <proski@gnu.org>
8407 * kern/i386/ieee1275/init.c: Include grub/cache.h.
8409 * term/ieee1275/ofconsole.c: Disable code unused on i386.
8411 * kern/ieee1275/ieee1275.c (grub_ieee1275_get_integer_property):
8412 Fix comparison between signed and unsigned.
8414 * include/grub/i386/ieee1275/console.h: Declare
8415 grub_console_init() and grub_console_fini().
8417 * loader/i386/ieee1275/linux.c (grub_set_bootpath): Remove.
8418 It's empty and unused.
8420 * fs/ext2.c (grub_ext2_read_block): Initialize blknr in the
8421 beginning to avoid warnings with some compilers.
8423 * loader/ieee1275/multiboot2.c: Include grub/machine/loader.h.
8424 [__i386__] (grub_mb2_arch_boot): Avoid unnecessary cast.
8426 2008-07-14 Pavel Roskin <proski@gnu.org>
8428 * kern/env.c (grub_register_variable_hook): Don't copy empty
8429 string, it leaks memory. Pass "" to grub_env_set(), it should
8430 handle constant strings.
8432 * commands/blocklist.c (grub_cmd_blocklist): Fix format warning.
8433 * commands/cmp.c (grub_cmd_cmp): Likewise.
8434 * kern/dl.c (grub_dl_flush_cache): Likewise.
8435 (grub_dl_load_core): Likewise.
8436 * kern/elf.c (grub_elf32_load_phdrs): Likewise.
8437 (grub_elf64_load_phdrs): Likewise.
8439 2008-07-13 Pavel Roskin <proski@gnu.org>
8441 * lib/LzmaEnc.c (LzmaEnc_SetProps): Fix warning about comparison
8442 between signed and unsigned.
8443 (LzmaEnc_Finish): Fix warning about an unused parameter.
8445 2008-07-13 Bean <bean123ch@gmail.com>
8447 * Makefile.in (enable_lzo): New rule.
8449 * conf/i386-pc.rmk (grub_mkimage_SOURCES): New test with enable_lzo.
8451 * configure.ac (ENABLE_LZO): New option --enable-lzo.
8453 * boot/i386/pc/lnxboot.S: #include <config.h>.
8455 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE): Change
8456 its value according to the compression algorithm used, lzo or lzma.
8458 * util/i386/pc/grub-mkimage.c (compress_kernel): Use different
8459 compression algorithm according to configure macro.
8461 * kern/i386/pc/startup.S (codestart): Likewise.
8463 * kern/i386/pc/lzma_decode.S: New file.
8465 * include/grub/lib/LzFind.h: Likewise.
8467 * include/grub/lib/LzHash.h: Likewise.
8469 * include/grub/lib/LzmaDec.h: Likewise.
8471 * include/grub/lib/LzmaEnc.h: Likewise.
8473 * include/grub/lib/LzmaTypes.h: Likewise.
8475 * lib/LzFind.c: Likewise.
8477 * lib/LzmaDec.c: Likewise.
8479 * lib/LzmaEnc.c: Likewise.
8481 2008-07-13 Bean <bean123ch@gmail.com>
8483 * fs/ext2.c (EXT4_EXTENTS_FLAG): New macro.
8484 (grub_ext4_extent_header): New structure.
8485 (grub_ext4_extent): Likewise.
8486 (grub_ext4_extent_idx): Likewise.
8487 (grub_ext4_find_leaf): New function.
8488 (grub_ext2_read_block): Handle extents.
8490 2008-07-12 Robert Millan <rmh@aybabtu.com>
8492 * util/i386/pc/grub-mkrescue.in: s/grub-install/grub-mkrescue/g.
8494 2008-07-11 Robert Millan <rmh@aybabtu.com>
8496 * util/grub.d/40_custom.in: New file. Example on how to add custom
8497 entries to /etc/grub.d.
8498 * conf/common.rmk (%, update-grub_SCRIPTS, CLEANFILES): Install
8499 40_custom (implicitly, by merging all the grub.d rules).
8501 2008-07-11 Pavel Roskin <proski@gnu.org>
8503 * commands/read.c (grub_getline): Fix invalid memory access.
8504 Don't add newline to the variable value.
8506 * term/i386/pc/serial.c (GRUB_SERIAL_PORT_NUM): New constant.
8507 [!GRUB_MACHINE_PCBIOS] (serial_hw_io_addr): Add COM2 and COM3.
8508 (serial_hw_get_port): Check validity of the port number.
8509 (grub_cmd_serial): Check return value of serial_hw_get_port().
8511 2008-07-07 Pavel Roskin <proski@gnu.org>
8513 * boot/i386/pc/diskboot.S (notification_string): Replace
8514 "Loading kernel" with just "loading". This is shorter, less
8515 confusing and saves a few bytes for possible future changes.
8517 2008-07-05 Pavel Roskin <proski@gnu.org>
8519 * disk/ata.c (grub_ata_dumpinfo): Don't output addressing and
8520 size for ATAPI devices, they are undefined. Output sector
8521 number in decimal form.
8523 * disk/ata.c: Use named constants for status bits.
8525 2008-07-04 Pavel Roskin <proski@gnu.org>
8527 * kern/i386/linuxbios/init.c (grub_machine_init): Cast addr to
8528 grub_addr_t before casting it to the void pointer to fix a
8529 warning. Non-addressable regions are discarded earlier.
8530 (grub_arch_modules_addr): Cast _end to grub_addr_t.
8531 * kern/i386/linuxbios/table.c: Include grub/misc.h.
8532 (check_signature): Don't shadow table_header.
8533 (grub_linuxbios_table_iterate): Cast numeric constants to
8534 grub_linuxbios_table_header_t.
8535 * include/grub/i386/linuxbios/init.h: Add noreturn attribute to
8538 * kern/ieee1275/init.c: Cast _start and _end to grub_addr_t to
8541 * include/grub/misc.h (ALIGN_UP): Avoid unnecessary cast to a
8542 pointer, which can cause warnings. Support 64-bit addresses.
8544 * util/elf/grub-mkimage.c: Use GRUB_TARGET_SIZEOF_LONG instead
8545 of sizeof(long). This fixes PowerPC image generation on x86_64.
8547 2008-07-04 Robert Millan <rmh@aybabtu.com>
8549 This fixes a performance issue when pc & gpt partmap iterators
8550 didn't abort iteration even after our hook found what it was
8551 looking for (often causing expensive probes of non-existent drives).
8553 Some callers relied on previous buggy behaviour, since they would
8554 raise an error when their own hooks caused early abortion of its
8557 * kern/device.c (grub_device_open): Improve error message.
8558 * disk/lvm.c (grub_lvm_open): Likewise.
8559 * disk/raid.c (grub_raid_open): Likewise.
8561 * partmap/pc.c (pc_partition_map_iterate): Abort parent iteration
8562 when hook requests it, independently of grub_errno.
8563 (pc_partition_map_probe): Do not fail when find_func() caused
8564 early abortion of pc_partition_map_iterate().
8566 * partmap/gpt.c (gpt_partition_map_iterate): Abort parent iteration
8567 when hook requests it, independently of grub_errno.
8568 (gpt_partition_map_probe): Do not fail when find_func() caused
8569 early abortion of gpt_partition_map_iterate().
8571 * kern/partition.c (grub_partition_iterate): Abort parent iteration
8572 when hook requests it, independently of grub_errno. Do not fail when
8573 part_map_iterate_hook() caused early abortion of p->iterate().
8575 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Do not fail
8576 when grub_partition_iterate() returned with non-zero.
8578 2008-07-03 Pavel Roskin <proski@gnu.org>
8580 * disk/ata.c (grub_ata_pio_write): Check status before writing,
8581 like we do in grub_ata_pio_read().
8582 (grub_ata_readwrite): Always write individual sectors. Fix the
8583 sector count for the remainder.
8584 (grub_ata_write): Enable writing to ATA devices. Correctly
8585 report error for ATAPI devices.
8587 2008-07-02 Pavel Roskin <proski@gnu.org>
8589 * boot/i386/pc/cdboot.S: Add _start entry to fix a linker
8592 * disk/ata.c (grub_ata_readwrite): Don't increment sector number
8593 for every read sector, we already increment it for the whole
8594 batch. This fixes reading more than 256 sectors at once.
8596 * util/grub-editenv.c (cmd_info): Cast argument to long
8597 explicitly. ptrdiff_t reduces to int on i386.
8599 * util/grub-editenv.c (main): Be specific which parameter is
8602 * disk/memdisk.c (memdisk_addr): Make a pointer to fix warnings.
8603 (memdisk): Make memdisk_orig_addr a pointer.
8605 * fs/reiserfs.c (grub_reiserfs_read): Fix misuse of grub_size_t
8606 for file offsets, use grub_off_t instead. Fix printf format
8609 * fs/reiserfs.c: Remove #warning, TODO list items don't belong
8610 there. Real unexpected warnings should not drown in the noise
8611 about known problems.
8613 * commands/hexdump.c (grub_cmd_hexdump): Fix misuse of
8614 grub_disk_addr_t for memory addresses.
8616 * loader/aout.c (grub_aout_load): Cast load_addr to pointer
8617 explicitly to fix a warning.
8619 * util/grub-editenv.c (cmd_info): Fix warning in printf format.
8621 * Makefile.in (MODULE_LDFLAGS): New variable.
8622 * aclocal.m4 (grub_PROG_LD_BUILD_ID_NONE): New macro. Check if
8623 the linker accepts --build-id=none.
8624 * configure.ac: Call grub_PROG_LD_BUILD_ID_NONE. Substitute
8626 * genmk.rb: Use MODULE_LDFLAGS when linking modules.
8628 * fs/xfs.c (struct grub_xfs_dir_header): Use names similar to
8629 those in Linux XFS code. Provide a way to access 64-bit parent
8631 (grub_xfs_iterate_dir): Use the new names. Avoid reading past
8632 the end of struct grub_xfs_dir_header.
8634 2008-07-02 Bean <bean123ch@gmail.com>
8636 * include/grub/ieee1275.h (grub_ieee1275_flag): New constant
8637 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
8638 and GRUB_IEEE1275_FLAG_NO_ANSI.
8640 * kern/ieee1275/cmain.c (grub_ieee1275_find_options): Set flag
8641 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
8642 and GRUB_IEEE1275_FLAG_NO_ANSI for Open Hackware.
8644 * kern/ieee1275/ieee1275.c (grub_ieee1275_interpret): Return
8645 immediately if GRUB_IEEE1275_FLAG_CANNOT_INTERPRET is set.
8647 * kern/ieee1275/init.c (grub_claim_heap): Claim memory directly if
8648 GRUB_IEEE1275_FLAG_FORCE_CLAIM is set.
8650 * term/ieee1275/ofconsole.c (grub_ofconsole_writeesc): Don't output
8651 esc sequence on non ANSI terminal.
8652 (grub_ofconsole_gotoxy): Emulate backspace key on non ANSI terminal.
8654 * util/elf/grub-mkimage.c (add_segments): Move ELF header to the
8657 2008-07-02 Bean <bean123ch@gmail.com>
8659 * conf/common.rmk (bin_UTILITIES): Add grub-editenv.
8660 (grub_editenv_SOURCES): New variable.
8661 (pkglib_MODULES): Add loadenv.mod.
8662 (loadenv_mod_SOURCES): New variable.
8663 (loadenv_mod_CFLAGS): Likewise.
8664 (loadenv_mod_LDFLAGS): Likewise.
8666 * include/grub/envblk.h: New file.
8668 * util/envblk.c: New file.
8670 * util/grub-editenv.c: New file.
8672 * commands/loadenv.c: New file.
8674 2008-07-01 Pavel Roskin <proski@gnu.org>
8676 * include/multiboot2.h (struct multiboot_tag_module): Use char,
8677 not unsigned char. This fixes warnings and is consistent with
8680 * disk/fs_uuid.c (search_fs_uuid): Correctly increment count.
8682 * normal/parser.y: Define YYENABLE_NLS as 0 to fix warnings.
8684 * term/tparm.c (analyze): Always set *popcount.
8686 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Remove useless
8687 cast to fix a warning.
8689 * loader/i386/pc/multiboot2.c (grub_mb2_arch_module_alloc): Use
8690 cast to suppress a warning.
8692 * fs/afs.c (grub_afs_read_block): Return grub_disk_addr_t, as
8693 grub_fshelp_read_file() expects.
8695 * fs/fat.c: Fix UUID calculation on big-endian systems. We
8696 write uuid as a 32-bit value in CPU byte order, so declare and
8699 * disk/raid.c: Cast grub_dprintf() arguments to unsigned long
8700 long if the format specifier expects it.
8701 * partmap/gpt.c (gpt_partition_map_iterate): Likewise.
8702 * partmap/pc.c (pc_partition_map_iterate): Likewise.
8703 * fs/ntfs.c (grub_ntfs_uuid): Cast data->uuid to unsigned long
8704 long to fix a warning.
8705 * fs/reiserfs.c (grub_reiserfs_read): Change casts in
8706 grub_dprintf() arguments to fix warnings.
8708 2008-06-30 Pavel Roskin <proski@gnu.org>
8710 * util/i386/pc/grub-setup.c (setup): Write install_dos_part and
8711 install_bsd_part immediately before core.img is embedded or
8712 modified on disk. This fixes core.img verification if core.img
8715 * util/i386/pc/grub-setup.c (setup): Use core_path_dev, not
8716 core_path to calculate the blocklist.
8717 Patch from Javier MartÃn <lordhabbit@gmail.com>
8719 2008-06-29 Robert Millan <rmh@aybabtu.com>
8721 * fs/xfs.c (GRUB_XFS_FSB_TO_BLOCK): New macro. Maps filesystem
8722 block to disk block.
8723 (grub_xfs_read_block): Use GRUB_XFS_FSB_TO_BLOCK() on result.
8724 Patch from Niels Böhm <bitbucket@arcor.de>
8726 2008-06-29 Robert Millan <rmh@aybabtu.com>
8728 * util/update-grub_lib.in (font_path): Search for fonts in
8729 /boot/grub first, which is more likely to be readable (we aren't
8730 deciding where fonts live, just looking for them).
8732 2008-06-26 Pavel Roskin <proski@gnu.org>
8734 * util/biosdisk.c (read_device_map): Don't leave dead map
8735 entries for devices failing stat() check.
8737 * util/i386/pc/grub-setup.c (setup): Don't reuse core_path, use
8738 core_path_dev for the core.img path on the target device.
8740 2008-06-26 Robert Millan <rmh@aybabtu.com>
8742 * disk/fs_uuid.c: New file.
8743 * conf/common.rmk (pkglib_MODULES): Add `fs_uuid.mod'.
8744 (fs_uuid_mod_SOURCES, fs_uuid_mod_CFLAGS)
8745 (fs_uuid_mod_LDFLAGS): New variables.
8746 * include/grub/disk.h (grub_disk_dev_id): Add
8747 `GRUB_DISK_DEVICE_UUID_ID'.
8748 * kern/disk.c (grub_disk_dev_iterate): Allow disk devices not to
8749 implement iterate().
8751 2008-06-26 Robert Millan <rmh@aybabtu.com>
8753 * util/grub.d/10_linux.in: Avoid passing UUIDs to Linux when either
8754 "/dev/disk/by-uuid/${GRUB_DEVICE_UUID}" does not exist, or when a
8755 Linux image includes no initrd.
8757 2008-06-21 Javier MartÃn <lordhabbit@gmail.com>
8759 * util/i386/pc/grub-setup.c (setup): Remove literal "core.img" in a
8760 call to resolve the core image location that effectively appended the
8763 2008-06-21 Robert Millan <rmh@aybabtu.com>
8765 * util/grub.d/00_header.in: Move last prepare_grub_to_access_device()
8768 * util/grub.d/10_hurd.in: ... to here ...
8769 * util/grub.d/10_linux.in: ... and here.
8771 2008-06-19 Robert Millan <rmh@aybabtu.com>
8773 * kern/main.c (grub_main): Export `prefix' variable immediately
8774 after it has been set by grub_machine_set_prefix().
8776 2008-06-19 Robert Millan <rmh@aybabtu.com>
8778 * commands/search.c (search_label, search_fs_uuid, search_file): Print
8779 search result when not saving to variable, not the other way around.
8780 When saving to variable, abort iteration as soon as a match is found.
8782 2008-06-19 Robert Millan <rmh@aybabtu.com>
8784 * util/update-grub_lib.in (prepare_grub_to_access_device): Remove
8785 check for partition that provides /boot/grub. Its logic is flawed,
8786 as it prevents prepare_grub_to_access_device() from being called
8789 2008-06-19 Robert Millan <rmh@aybabtu.com>
8791 * util/update-grub_lib.in (prepare_grub_to_access_device): Issue
8792 "insmod" command directly when abstraction modules are needed,
8793 instead of relying on GRUB_PRELOAD_MODULES (which had no effect
8794 since it had already been processed).
8796 2008-06-19 Pavel Roskin <proski@gnu.org>
8798 * conf/i386-efi.rmk: Recompile grub-mkimage.c if Makefile has
8799 changed. This is needed in case GRUB_LIBDIR changes.
8800 * conf/i386-ieee1275.rmk: Likewise.
8801 * conf/i386-linuxbios.rmk: Likewise.
8802 * conf/i386-pc.rmk: Likewise.
8803 * conf/powerpc-ieee1275.rmk: Likewise.
8805 2008-06-18 Pavel Roskin <proski@gnu.org>
8807 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Rename
8808 kernel_elf_symlist.c to symlist.c for consistency with other
8809 architectures. Update all users.
8810 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
8812 2008-06-18 Robert Millan <rmh@aybabtu.com>
8814 * util/i386/pc/grub-install.in: If the drive is LVM or RAID, prepend
8817 * util/i386/pc/grub-setup.c (main): Don't handle prefix at all. Set
8818 `must_embed' to 1 when root_dev is a RAID device. When dest_dev is
8819 a RAID device, run setup() for all members independently on whether
8820 LVM abstraction is being used.
8821 (setup): Don't handle prefix at all; let grub-mkimage take care of it.
8822 If grub-mkimage has set `*install_dos_part == -2', don't override this
8824 Perform *install_dos_part adjustments independently on whether
8825 we're embedding or not.
8826 Clarify error message when image is too big for embedding.
8827 Remove duplicate *install_dos_part stanza.
8829 2008-06-17 Robert Millan <rmh@aybabtu.com>
8831 * term/ieee1275/ofconsole.c (fgcolor, bgcolor): Remove variables.
8832 (grub_ofconsole_normal_color, grub_ofconsole_highlight_color): New
8834 (grub_ofconsole_setcolor, grub_ofconsole_getcolor): Load/store
8835 values in grub_ofconsole_normal_color and
8836 grub_ofconsole_highlight_color (they're not directly related to
8837 background and foreground).
8838 (grub_ofconsole_setcolorstate): Extract background and foreground
8839 from grub_ofconsole_normal_color and grub_ofconsole_highlight_color.
8841 2008-06-17 Robert Millan <rmh@aybabtu.com>
8843 * util/update-grub_lib.in (prepare_grub_to_access_device): Use
8844 /boot/grub for the check in last commit, not /boot (they could be
8845 different partitions).
8847 2008-06-16 Robert Millan <rmh@aybabtu.com>
8849 * util/update-grub_lib.in (prepare_grub_to_access_device): If we were
8850 asked to setup access for the same partition that provides /boot,
8851 don't bother using UUIDs since our root already has the value we
8854 2008-06-16 Robert Millan <rmh@aybabtu.com>
8856 * util/biosdisk.c (convert_system_partition_to_system_disk): Detect
8858 Patch from Sven Mueller <sven@debian.org>.
8860 2008-06-16 Robert Millan <rmh@aybabtu.com>
8862 * util/update-grub.in: Check for $EUID instead of $UID.
8863 Reported by Vincent Zweije.
8865 2008-06-16 Bean <bean123ch@gmail.com>
8867 * fs/ext2.c (grub_ext2_blockgroup): Revert to pre-journal state.
8868 (grub_ext2_read_block): Likewise.
8869 (grub_ext2_read_inode): Likewise.
8870 (grub_ext2_mount): Likewise.
8871 (grub_ext2_close): Likewise.
8872 (grub_ext3_get_journal): Removed.
8874 * fs/reiserfs.c (grub_reiserfs_get_item): Revert to pre-journal state.
8875 (grub_reiserfs_read_symlink): Likewise.
8876 (grub_reiserfs_mount): Likewise.
8877 (grub_reiserfs_open): Likewise.
8878 (grub_reiserfs_read): Likewise.
8879 (grub_reiserfs_close): Likewise.
8880 (grub_reiserfs_get_journal): Removed.
8882 * fs/fshelp.c (grub_fshelp_read): Removed.
8883 (grub_fshelp_map_block): Likewise.
8885 * include/grub/fshelp.h (grub_fshelp_journal_type): Removed.
8886 (grub_fshelp_journal): Likewise.
8887 (grub_fshelp_read): Likewise.
8888 (grub_fshelp_map_block): Likewise.
8890 2008-06-16 Pavel Roskin <proski@gnu.org>
8892 * conf/powerpc-ieee1275.rmk: Remove -msoft-float, we don't use
8893 floating point anymore.
8894 * include/grub/powerpc/libgcc.h: Leave only necessary exports.
8896 2008-06-15 Pavel Roskin <proski@gnu.org>
8898 * commands/ls.c (grub_ls_list_files): Use integer calculations
8899 for human readable format, avoid floating point use.
8900 * kern/misc.c (grub_ftoa): Remove.
8901 (grub_vsprintf): Remove floating point support.
8903 2008-06-15 Robert Millan <rmh@aybabtu.com>
8905 * util/grub.d/10_linux.in: Use the underlying device for loop-AES
8907 Reported by Max Vozeler.
8909 2008-06-15 Robert Millan <rmh@aybabtu.com>
8911 * util/i386/pc/grub-mkimage.c (generate_image): If we included a drive
8912 in our prefix, set install_{dos,bsd}_part = -2 to indicate this can be
8914 (main): If a memdisk was requested, add "(memdisk)" drive explicitly to
8915 the beginning of the prefix.
8917 * kern/i386/pc/init.c (make_install_device): Remove memdisk check.
8918 It is assumed that if we have a memdisk, grub-mkimage has set
8919 grub_prefix to include the "(memdisk)" drive in it.
8921 2008-06-15 Robert Millan <rmh@aybabtu.com>
8923 * term/i386/pc/console.c [GRUB_MACHINE_LINUXBIOS] (grub_console_init):
8924 Initialize keyboard controller after registering the terminal, so that
8925 grub_printf() can be called from grub_keyboard_controller_init().
8927 2008-06-15 Robert Millan <rmh@aybabtu.com>
8929 * fs/sfs.c (grub_sfs_read_extent): Fix the count of nodes in
8930 extent-btree which is written as big endian on disk.
8931 Reported by Alain Greppin <al@chilibi.org>.
8933 2008-06-14 Robert Millan <rmh@aybabtu.com>
8935 * util/i386/efi/grub-install.in (modules): Remove `_chain'.
8936 * util/i386/pc/grub-install.in (modules): Likewise.
8938 2008-06-13 Pavel Roskin <proski@gnu.org>
8940 * commands/ls.c (grub_ls_list_files): Fix format warnings.
8942 2008-06-13 Bean <bean123ch@gmail.com>
8944 * commands/hexdump.c (grub_cmd_hexdump): Adjust offset for partition.
8946 * fs/ext2.c (grub_ext3_get_journal): Fix revoke block handling.
8948 * fs/fshelp.c (grub_fshelp_map_block): Don't map block 0 as it's used
8949 to indicate sparse block.
8951 2008-06-12 Pavel Roskin <proski@gnu.org>
8953 * fs/ext2.c (grub_ext2_read_inode): Don't normalize block
8954 number, grub_fshelp_read() does it for us.
8956 * fs/fshelp.c (grub_fshelp_read): New function. Implement
8957 linear disk read with journal translation.
8958 * fs/ext2.c: Use grub_fshelp_read() instead of grub_disk_read().
8959 * include/grub/fshelp.h: Declare grub_fshelp_read().
8961 2008-06-09 Pavel Roskin <proski@gnu.org>
8963 * fs/minix.c (grub_minix_mount): Handle error reading
8966 2008-06-08 Robert Millan <rmh@aybabtu.com>
8968 * util/i386/pc/grub-setup.c (main): If install drive is an LVM,
8969 don't append the RAID prefix afterwards.
8970 Reported by Clint Adams.
8972 2008-06-08 Robert Millan <rmh@aybabtu.com>
8974 Based on description from Pavel:
8975 * kern/disk.c (grub_disk_check_range): Rename to ...
8976 (grub_disk_adjust_range): ... this. Add a comment explaining the
8977 tasks performed by this function.
8979 2008-06-08 Robert Millan <rmh@aybabtu.com>
8981 * include/grub/ntfs.h (struct grub_ntfs_bpb): Rename `serial_number' to
8982 `num_serial' (for consistency with other variables).
8983 (struct grub_ntfs_data): Add `uuid' member.
8984 * fs/ntfs.c (grub_ntfs_mount): Initialize `data->uuid'.
8985 (grub_ntfs_uuid): New function.
8986 (grub_ntfs_fs): Reference grub_ntfs_uuid() in `uuid' struct member.
8988 2008-06-07 Pavel Roskin <proski@gnu.org>
8990 * util/biosdisk.c (open_device): Revert last change to the
8991 function, it broke installation. The sector needs to be
8992 different dependent on which device is opened.
8994 2008-06-06 Robert Millan <rmh@aybabtu.com>
8996 Ensure GRUB_KERNEL_MACHINE_DATA_END is always consistent with the
8997 rest of GRUB, and breakage doesn't happen if its value were modified.
8999 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
9000 Redefine as an offset from `GRUB_KERNEL_MACHINE_DATA_END' instead of
9001 a constant (same value).
9002 * kern/i386/pc/startup.S: Replace hardcoded `0x50' with
9003 `GRUB_KERNEL_MACHINE_DATA_END' (same value).
9005 2008-06-06 Robert Millan <rmh@aybabtu.com>
9007 * util/biosdisk.c (open_device): Do not modify sector offset when
9008 accessing a partition. kern/disk.c already handles this for us.
9010 2008-06-06 Robert Millan <rmh@aybabtu.com>
9012 * util/grub-emu.c (grub_machine_init): Move code in this function from
9014 (main): ... to here (before grub_util_biosdisk_init() call, to prevent
9015 segfault in case grub_printf() is called).
9017 * util/i386/pc/grub-install.in: Append `--device-map=${device_map}' to
9018 grub_probe. Update all users not to explicitly add it again.
9019 (grub_device): New variable; contains corresponding device for grubdir.
9020 (fs_module, partmap_module, devabstraction_module): Pass
9021 `--device ${grub_device}' to grub_probe to avoid traversing /dev
9024 2008-06-05 Robert Millan <rmh@aybabtu.com>
9026 * normal/misc.c (grub_normal_print_device_info): When a filesystem UUID
9027 is found, print it (same layout as with labels).
9029 2008-06-04 Robert Millan <rmh@aybabtu.com>
9031 * util/biosdisk.c (get_drive): Rename to ...
9032 (find_grub_drive): ... this. Update all users.
9034 (get_os_disk): Rename to ...
9035 (convert_system_partition_to_system_disk): ... this. Update all users.
9037 (find_drive): Rename to ...
9038 (find_system_device): ... this. Update all users.
9040 2008-06-04 Robert Millan <rmh@aybabtu.com>
9042 * util/biosdisk.c (get_os_disk): Handle IDA devices.
9043 * util/grub-mkdevicemap.c (get_mmc_disk_name)
9044 (make_device_map): Likewise.
9046 2008-06-01 Robert Millan <rmh@aybabtu.com>
9048 * util/biosdisk.c (get_drive): Verify that `map[i].drive' is non-NULL
9049 before dereferencing it.
9051 * fs/fat.c (struct grub_fat_bpb): Move fat32-specific fields into a
9052 union with fat12/fat16-specific ones. Add some new fields, including
9053 `num_serial' for both versions.
9054 (struct grub_fat_data): Add `uuid' member.
9055 (grub_fat_mount): Refer to fat32-specific fields in `bpb' by their new
9056 names. Initialize `data->uuid' using `num_serial'.
9057 (grub_fat_uuid): New function.
9058 (grub_fat_fs): Reference grub_fat_uuid() in `uuid' struct member.
9060 * fs/reiserfs.c (grub_reiserfs_superblock): Add `uuid' field.
9061 (grub_reiserfs_uuid): New function.
9062 (grub_reiserfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct
9065 * fs/xfs.c (grub_xfs_sblock): Add `uuid' field.
9066 (grub_xfs_uuid): New function.
9067 (grub_xfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct member.
9069 2008-06-01 Robert Millan <rmh@aybabtu.com>
9071 * util/update-grub_lib.in (prepare_grub_to_access_device): Generate
9072 code that is backward compatible with pre-uuid search command.
9074 2008-05-31 Robert Millan <rmh@aybabtu.com>
9076 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Iterate through
9077 floppies after everything else, to ensure floppy drive isn't accessed
9078 unnecessarily (patch from Bean).
9080 2008-05-31 Robert Millan <rmh@aybabtu.com>
9082 * commands/search.c (search_label, search_fs_uuid, search_file): Do
9083 not print device names when we were asked to set a variable.
9085 2008-05-31 Robert Millan <rmh@aybabtu.com>
9087 * term/ieee1275/ofconsole.c (grub_ofconsole_setcursor): Implement
9088 using "cursor-on" and "cursor-off" commands (understood at least by
9089 the Open Firmware flavour on OLPC).
9091 2008-05-31 Michael Gorven <michael@gorven.za.net>
9093 * term/terminfo.c (grub_terminfo_set_current): Correct vt100 cursor
9094 on and off sequences.
9096 2008-05-31 Robert Millan <rmh@aybabtu.com>
9098 * util/update-grub_lib.in: Replace `grub-probe' with `${grub_probe}'.
9099 * util/update-grub.in: Likewise.
9101 2008-05-30 Pavel Roskin <proski@gnu.org>
9103 * util/biosdisk.c (linux_find_partition): Simplify logic and
9104 make the code more universal. Keep special processing for
9105 devfs, but use a simple rule for all other devices. If the
9106 device ends with a number, append 'p' and the partition number.
9107 Otherwise, append only the partition number.
9109 2008-05-30 Robert Millan <rmh@aybabtu.com>
9111 * util/update-grub.in (GRUB_DISABLE_LINUX_UUID): Export variable.
9112 * util/grub.d/10_linux.in: If GRUB_DEVICE_UUID is set, and
9113 GRUB_DISABLE_LINUX_UUID isn't true, use the filesystem UUIDs as
9114 the `root' parameter to Linux.
9116 2008-05-30 Robert Millan <rmh@aybabtu.com>
9118 * commands/search.c (options): Rename --fs_uuid to --fs-uuid.
9119 * util/update-grub_lib.in (prepare_grub_to_access_device): Replace
9120 --fs_uuid with --fs-uuid.
9121 * util/update-grub.in: Allow filesystem UUID probes to fail (since not
9122 all filesystems support them).
9124 2008-05-30 Robert Millan <rmh@aybabtu.com>
9126 * fs/ext2.c (grub_ext2_uuid): Use `04x' instead of '02x' as
9127 grub_printf() flags, since we're printing in units of 2 bytes.
9129 2008-05-30 Robert Millan <rmh@aybabtu.com>
9131 * util/grub.d/00_header.in: Remove obsolete comment referencing
9132 convert_system_path_to_grub_path().
9133 * util/update-grub.in: Likewise.
9134 * util/update-grub_lib.in (is_path_readable_by_grub): New function.
9135 (convert_system_path_to_grub_path): Add a warning message explaining
9136 that this function is deprecated. Rely on is_path_readable_by_grub()
9137 for the readability checks.
9138 (font_path): Use is_path_readable_by_grub() for the readability
9139 check rather than convert_system_path_to_grub_path().
9141 2008-05-30 Robert Millan <rmh@aybabtu.com>
9143 * util/update-grub_lib.in (prepare_grub_to_access_device): New function.
9144 * util/update-grub.in: Set `GRUB_FONT_PATH' to the system path, without
9145 converting it first.
9146 * util/grub.d/00_header.in: Use prepare_grub_to_access_device() to setup
9147 grub.cfg for access to font file, and afterwards call it again to set
9150 2008-05-30 Robert Millan <rmh@aybabtu.com>
9152 * commands/search.c (options): Add --fs_uuid option.
9153 (search_fs_uuid): New function.
9154 (grub_cmd_search): Fix --set argument passing.
9155 Use search_fs_uuid() when requested via --fs_uuid.
9156 (grub_search_init): Update help message.
9157 * fs/ext2.c (struct grub_ext2_sblock): Rename `unique_id' to `uuid'
9158 and redeclare it as an array of 16-bit words.
9159 (grub_ext2_uuid): New function.
9160 (grub_ext2_fs): Reference grub_ext2_uuid() in `uuid' struct member.
9161 * include/grub/fs.h (struct grub_fs): Add `uuid' struct member.
9162 * util/update-grub.in (GRUB_DEVICE_UUID, GRUB_DEVICE_BOOT)
9163 (GRUB_DEVICE_BOOT_UUID): New variables.
9164 (GRUB_DRIVE. GRUB_DRIVE_BOOT. GRUB_DRIVE_BOOT_GRUB): Remove.
9165 * util/grub.d/00_header.in: Set root using `search --fs_uuid' command
9167 * util/grub.d/10_hurd.in: Avoid explicit use of root drive. Instead,
9168 just assume `root' variable has the right value.
9169 * util/grub.d/10_linux.in: Likewise.
9170 * util/grub-probe.c (probe): Probe for filesystem UUID when requested
9172 (main): Recognise `-t fs_uuid' argument.
9174 2008-05-30 Robert Millan <rmh@aybabtu.com>
9176 * util/biosdisk.c (map): Redefine structure to hold information
9177 about GRUB drive name.
9178 (get_drive): Reimplement without assuming (and verifying) BIOS-like
9180 (call_hook): Remove.
9181 (grub_util_biosdisk_iterate): Access drive names via `.drive' struct
9182 member. Assume drive has partitions.
9183 (grub_util_biosdisk_open): Access device names via `.device' struct
9185 (open_device): Likewise.
9186 (find_drive): Likewise.
9187 (read_device_map): Adjust map[] usage to match the new struct
9188 definition. Don't check for duplicates (still possible, but not cheap
9190 (grub_util_biosdisk_fini): Free malloced buffers referenced by map[].
9191 (make_device_name): Remove assumption of BIOS-like drive names.
9193 2008-05-30 Pavel Roskin <proski@gnu.org>
9195 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Remove, as
9196 compiling execute.c doesn't need grub_script.tab.h anymore.
9197 (normal/command.c_DEPENDENCIES): Likewise.
9198 (normal/function.c_DEPENDENCIES): Likewise.
9199 * conf/i386-ieee1275.rmk: Likewise.
9200 * conf/i386-linuxbios.rmk: Likewise.
9201 * conf/i386-pc.rmk: Likewise.
9202 * conf/powerpc-ieee1275.rmk: Likewise.
9203 * conf/sparc64-ieee1275.rmk: Likewise.
9205 2008-05-29 Pavel Roskin <proski@gnu.org>
9207 * disk/lvm.c (grub_lvm_scan_device): Check for the buffer end
9208 when scanning metadata for volume group name.
9210 * include/grub/script.h: Don't include grub_script.tab.h. It's
9211 a generated file, which may only be included from the files with
9212 DEPENDENCIES rules in the makefile. Don't use typedef YYSTYPE,
9213 use union YYSTYPE, as the later allows forward declaration.
9214 * normal/lexer.c: Don't use typedef YYSTYPE, use union YYSTYPE.
9216 2008-05-29 Robert Millan <rmh@aybabtu.com>
9218 * term/i386/pc/at_keyboard.c: Include `grub/machine/machine.h'.
9219 (OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): New macros.
9220 [GRUB_MACHINE_IEEE1275] (keyboard_map): Add OLPC scan codes
9221 (grub_console_checkkey): Add grub_dprintf() call to report unknown
9224 2008-05-29 Robert Millan <rmh@aybabtu.com>
9226 * term/i386/pc/at_keyboard.c (grub_console_checkkey): Add support for
9227 control key combinations.
9229 2008-05-29 Robert Millan <rmh@aybabtu.com>
9231 * util/powerpc/ieee1275/grub-install.in: Move from here ...
9232 * util/ieee1275/grub-install.in: ... to here.
9233 * powerpc-ieee1275.rmk (grub_install_SOURCES): Update location.
9234 * i386-ieee1275.rmk (sbin_SCRIPTS): New variable.
9235 (grub_install_SOURCES): Likewise.
9237 2008-05-29 Robert Millan <rmh@aybabtu.com>
9239 * fs/affs.c: Update copyright year.
9240 * fs/ext2.c: Likewise.
9241 * fs/fshelp.c: Likewise.
9242 * fs/hfsplus.c: Likewise.
9243 * fs/ntfs.c: Likewise.
9244 * fs/xfs.c: Likewise.
9245 * include/grub/fshelp.h: Likewise.
9246 * util/grub-mkdevicemap.c: Likewise.
9248 2008-05-28 Robert Millan <rmh@aybabtu.com>
9250 * util/update-grub.in: Allow chmod call to fail, since /boot/grub/
9251 might need to be fatfs to support some firmware implementations
9254 2008-05-28 Robert Millan <rmh@aybabtu.com>
9256 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle MMC
9258 * util/grub-mkdevicemap.c (get_mmc_disk_name)
9259 (make_device_map): Likewise.
9261 2008-05-20 Bean <bean123ch@gmail.com>
9263 * fs/fshelp.c (grub_fshelp_map_block): New function.
9264 (grub_fshelp_find_file): Use 64-bit type for pos and block address.
9265 Use `>>' and `&' operator to avoid 64-bit divide and modulo.
9267 * include/grub/fshelp.h (grub_fshelp_journal_type): New enum.
9268 (GRUB_FSHELP_JOURNAL_UNUSED_MAPPING): New macro.
9269 (grub_fshelp_journal): New structure.
9270 (grub_fshelp_map_block): New function prototype.
9271 (grub_fshelp_read_file): Use grub_disk_addr_t as block type.
9272 (grub_fshelp_map_block): Likewise.
9274 * fs/ext2.c (EXT3_FEATURE_COMPAT_HAS_JOURNAL): New macro.
9275 (EXT3_JOURNAL_MAGIC_NUMBER): Likewise.
9276 (EXT3_JOURNAL_DESCRIPTOR_BLOCK): Likewise.
9277 (EXT3_JOURNAL_COMMIT_BLOCK): Likewise.
9278 (EXT3_JOURNAL_SUPERBLOCK_V1): Likewise.
9279 (EXT3_JOURNAL_SUPERBLOCK_V2): Likewise.
9280 (EXT3_JOURNAL_REVOKE_BLOCK): Likewise.
9281 (EXT3_JOURNAL_FLAG_ESCAPE): Likewise.
9282 (EXT3_JOURNAL_FLAG_SAME_UUID): Likewise.
9283 (EXT3_JOURNAL_FLAG_DELETED): Likewise.
9284 (EXT3_JOURNAL_FLAG_LAST_TAG): Likewise.
9285 (grub_ext2_sblock): New members for journal support.
9286 (grub_ext3_journal_header): New structure.
9287 (grub_ext3_journal_revoke_header): Likewise.
9288 (grub_ext3_journal_block_tag): Likewise.
9289 (grub_ext3_journal_sblock): Likewise.
9290 (grub_fshelp_node): New members logfile and journal.
9291 (grub_ext2_read_block): Change block type to grub_disk_addr_t. Use
9292 grub_fshelp_map_block to get real block number.
9293 (grub_ext2_blockgroup): Use grub_fshelp_map_block to get real block
9295 (grub_ext2_read_inode): Likewise.
9296 (grub_ext3_get_journal): New function.
9297 (grub_read_inode): Initialize journal using grub_ext3_get_journal.
9298 (grub_ext2_close): Release memory used by journal.
9300 * fs/reiserfs.c (REISERFS_MAGIC_STRING): Changed to "ReIsEr".
9301 (REISERFS_MAGIC_DESC_BLOCK): New macro.
9302 (grub_reiserfs_transaction_header): Renamed to
9303 grub_reiserfs_description_block, replace field data with real_blocks.
9304 (grub_reiserfs_commit_block): New structure.
9305 (grub_reiserfs_data): New member journal.
9306 (grub_reiserfs_get_item): Use grub_fshelp_map_block to get real block
9308 (grub_reiserfs_read_symlink): Likewise.
9309 (grub_reiserfs_iterate_dir): Likewise.
9310 (grub_reiserfs_open): Likewise.
9311 (grub_reiserfs_read): Likewise.
9312 (grub_reiserfs_get_journal): New function.
9313 (grub_reiserfs_mount): Use "ReIsEr" as super block magic, as there are
9314 three varieties ReIsErFs, ReIsEr2Fs and ReIsEr3Fs. Initialize journal
9315 using grub_reiserfs_get_journal.
9316 (grub_reiserfs_close): Release memory used by journal.
9318 * fs/affs.c (grub_affs_read_block): Change block type to
9319 grub_disk_addr_t. Use grub_divmod64 to do 64-bit division.
9321 * fs/afs.c (grub_afs_read_block): Change block type to grub_disk_addr_t.
9323 * fs/hfsplus.c (grub_hfsplus_read_block): Likewise.
9325 * fs/ntfs.c (grub_ntfs_read_block): Likewise.
9327 * fs/udf.c (grub_udf_read_block): Change block type to
9328 grub_disk_addr_t. Use type cast to avoid warning.
9330 * fs/xfs.c (grub_xfs_read_block): Likewise.
9332 2008-05-16 Christian Franke <franke@computer.org>
9334 * commands/cat.c (grub_cmd_cat): Remove non-ESC keys from keyboard queue
9335 to ensure that break with ESC will always work.
9336 * commands/sleep.c (grub_interruptible_millisleep): Likewise.
9337 Remove ESC from keyboard queue.
9339 2008-05-16 Christian Franke <franke@computer.org>
9341 * util/biosdisk.c: [__CYGWIN__] Add includes.
9342 (grub_util_biosdisk_open): Use Linux code also for Cygwin.
9343 (get_os_disk): Move variable declarations to OS specific
9344 parts to avoid warning.
9345 [__GNU__] (get_os_disk): Fix /dev/sdXsN case.
9346 [__CYGWIN__] (get_os_disk): Add Cygwin /dev/sdXN device names.
9347 (grub_util_biosdisk_get_grub_dev): Use Linux code also for
9349 * util/getroot.c: [__CYGWIN__] Add includes.
9350 (strip_extra_slashes): Fix "/" case.
9351 [__CYGWIN__] (get_win32_path): New function.
9352 [__CYGWIN__] (grub_get_prefix): Add conversion to win32 path.
9353 [__CYGWIN__] (find_root_device): Disable.
9354 [__CYGWIN__] (get_bootsec_serial): New function.
9355 [__CYGWIN__] (find_cygwin_root_device): Likewise.
9356 [__linux__] (grub_guess_root_device): Add early returns to simplify
9358 [__CYGWIN__] (grub_guess_root_device): Call find_cygwin_root_device.
9359 [__linux__] (grub_util_get_dev_abstraction): Enable LVM and RAID
9360 check for Linux only.
9362 2008-05-15 Bean <bean123ch@gmail.com>
9364 * kern/i386/pc/startup.S (grub_console_getkey): Workaround for the
9365 keyboard hang problem in apple's intel mac.
9367 2008-05-09 Robert Millan <rmh@aybabtu.com>
9369 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle Virtio
9371 * util/grub-mkdevicemap.c (get_virtio_disk_name)
9372 (make_device_map): Likewise.
9373 Reported by Aurelien Jarno <aurel32@debian.org>
9375 2008-05-07 Ian Campbell <ijc@hellion.org.uk>
9377 * util/biosdisk.c (get_os_disk): Recognise xvd type disks.
9378 * util/grub-mkdevicemap.c (get_xvd_disk_name): New function.
9379 (make_device_map): Output entries for xvd type disks.
9381 2008-05-07 Robert Millan <rmh@aybabtu.com>
9383 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle CCISS
9385 * util/grub-mkdevicemap.c (get_cciss_disk_name)
9386 (make_device_map): Likewise.
9387 Reported by Roland Dreier <rdreier@cisco.com>
9389 2008-05-07 Robert Millan <rmh@aybabtu.com>
9391 * disk/lvm.c (grub_lvm_scan_device): Detect errors in an additional
9392 grub_strstr() call. Correct a few mistakes in failure path handling.
9394 2008-05-06 Robert Millan <rmh@aybabtu.com>
9396 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
9397 Do not print a trailing slash (therefore, the root directory is an
9399 (convert_system_path_to_grub_path): Do not remove trailing slash
9400 from make_system_path_relative_to_its_root() output.
9402 * util/i386/pc/grub-install.in: Add trailing slash to output from
9403 make_system_path_relative_to_its_root().
9405 2008-05-06 Robert Millan <rmh@aybabtu.com>
9407 * util/grub-fstest.c (grub_refresh): Call `fflush (stdout)'. This
9408 ensures that output lines aren't intermangled with those sent to
9409 stderr (via grub_util_info()).
9410 * util/grub-probe.c (grub_refresh): Likewise.
9411 * util/i386/pc/grub-setup.c (grub_refresh): Likewise.
9413 2008-05-05 Christian Franke <franke@computer.org>
9415 * util/grub-mkdevicemap.c (get_floppy_disk_name) [__CYGWIN__]:
9416 Add Cygwin device names.
9417 (get_ide_disk_name) [__CYGWIN__]: Likewise.
9418 (get_scsi_disk_name) [__CYGWIN__]: Likewise.
9419 (check_device): Return error instead of success on empty name.
9420 (make_device_map): Move label inside linux specific code to
9421 prevent compiler warning.
9423 2008-04-30 Robert Millan <rmh@aybabtu.com>
9425 Based on patch from Fabian Greffrath <greffrath@leat.rub.de>
9426 * util/grub.d/10_linux.in: Add ${GRUB_CMDLINE_LINUX_DEFAULT} to the
9428 * util/update-grub.in: Export GRUB_CMDLINE_LINUX_DEFAULT.
9430 2008-04-29 Robert Millan <rmh@aybabtu.com>
9432 * docs/grub.cfg: New file (example GRUB configuration).
9434 2008-04-26 Robert Millan <rmh@aybabtu.com>
9436 * DISTLIST: Sort (sort -u < DISTLIST | sponge DISTLIST). Add
9437 `loader/i386/ieee1275/linux.c', `loader/i386/ieee1275/linux_normal.c'
9438 and `disk/ieee1275/nand.c'.
9440 2008-04-25 Bean <bean123ch@gmail.com>
9442 * Makefile.in (RMKFILES): Add missing arch i386-ieee1275 and
9445 * commands/hexdump.c (grub_cmd_hexdump): Support dumping of device,
9446 change the buffer size to 4096 for cdrom device.
9448 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add _linux.mod, linux.mod
9450 (_linux_mod_SOURCES): New variable.
9451 (_linux_mod_CFLAGS): Likewise.
9452 (_linux_mod_LDFLAGS): Likewise.
9453 (linux_mod_SOURCES): Likewise.
9454 (linux_mod_CFLAGS): Likewise.
9455 (linux_mod_LDFLAGS): Likewise.
9456 (nand_mod_SOURCES): Likewise.
9457 (nand_mod_CFLAGS): Likewise.
9458 (nand_mod_LDFLAGS): Likewise.
9460 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Return
9461 GRUB_ERR_UNKNOWN_DEVICE instead of GRUB_ERR_BAD_DEVICE if no device
9462 type property. (nand device in olpc don't have this property)
9464 * include/grub/disk.h (grub_disk_dev_id): New macro
9465 GRUB_DISK_DEVICE_NAND_ID.
9467 * include/grub/i386/ieee1275/loader.h (grub_rescue_cmd_linux): New
9469 (grub_rescue_cmd_initrd): Likewise.
9471 * include/grub/i386/linux.h (GRUB_LINUX_OFW_SIGNATURE): New macro.
9472 (linux_kernel_params): Add new member ofw_signature, ofw_num_items,
9473 ofw_cif_handler and ofw_idt, adjust padding number.
9475 * include/grub/i386/pc/memory.h (grub_upper_mem): Export it if
9476 GRUB_MACHINE_IEEE1275 is defined.
9478 * include/grub/ieee1275/ieee1275.h (grub_available_iterate):
9479 Use NESTED_FUNC_ATTR attribute on the hook parameter.
9481 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Use NESTED_FUNC_ATTR
9482 on nested function heap_init.
9483 (grub_upper_mem): New variable for i386-ieee1275.
9484 (grub_get_extended_memory): New function for i386-ieee1275.
9485 (grub_machine_init): Call grub_get_extended_memory for i386-ieee1275.
9487 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Use
9488 NESTED_FUNC_ATTR on the hook parameter. Don't quit if no device type
9491 * loader/i386/ieee1275/linux.c: New file.
9493 * loader/i386/ieee1275/linux_normal.c: New file.
9495 * disk/ieee1275/nand.c: New file.
9497 2008-04-18 Thomas Schwinge <tschwinge@gnu.org>
9499 * util/i386/pc/grub-mkrescue.in (grub_mkimage): Don't overwrite correct
9501 * util/powerpc/ieee1275/grub-mkrescue.in (grub_mkimage): Likewise.
9503 2008-04-18 Robert Millan <rmh@aybabtu.com>
9505 Restructures early code path on ieee1275 to unify grub_main() as
9506 the first C function that is executed in every platform.
9508 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_init): New prototype.
9509 * kern/i386/ieee1275/startup.S (_start): Jump to grub_main() instead of
9511 * kern/powerpc/ieee1275/crt0.S (_start): Likewise.
9512 * kern/ieee1275/cmain.c (cmain): Rename to ...
9513 * kern/ieee1275/cmain.c (grub_ieee1275_init): ... this.
9514 * kern/ieee1275/init.c (grub_machine_init): Call grub_ieee1275_init()
9517 2008-04-18 Robert Millan <rmh@aybabtu.com>
9519 * util/update-grub.in: Fix syntax error when setting
9520 `GRUB_PRELOAD_MODULES'.
9521 Reported by Stephane Chazelas <stephane@artesyncp.com>
9523 2008-04-17 Lubomir Kundrak <lkundrak@redhat.com>
9525 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): take only .text
9526 section into account, newer toolchains generate unique build ids
9527 * configure.ac: remove the test for --build-id=none acceptance,
9528 we want build ids to be preserved
9529 * genmk.rb: add -R .note.gnu.build-id to objcopy, so build id
9530 far from other sections don't cause the raw binary images grow
9533 2008-04-15 Robert Millan <rmh@aybabtu.com>
9535 * disk/lvm.c: Update copyright year.
9536 * kern/misc.c: Likewise.
9538 2008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
9540 * disk/lvm.c (grub_lvm_scan_device): Add forgotten failure path when
9541 there is no memory left for physical volume name.
9543 2008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
9545 * disk/lvm.c (grub_lvm_scan_device): Fix logical volume's physical
9546 volume name mapping to support bigger than 9 character names properly.
9548 2008-04-13 Robert Millan <rmh@aybabtu.com>
9550 * disk/i386/pc/biosdisk.c (grub_biosdisk_rw): Fix CHS limit check,
9551 as per http://www.allensmith.net/Storage/HDDlimit/Int13h.htm
9553 2008-04-13 Christian Franke <franke@computer.org>
9555 * util/i386/pc/grub-mkrescue.in: Add --emulation=floppy
9556 to create a floppy emulation boot CD when non emulation mode
9558 Enable Joliet CD filesystem extension.
9560 2008-04-13 Robert Millan <rmh@aybabtu.com>
9562 * kern/misc.c (grub_strncat): Fix off-by-one error.
9563 Reported by Zhang Huan <zhanghuan@nrchpc.ac.cn>
9565 * kern/env.c (grub_env_context_close): Clear current context, not
9567 Patch from Zhang Huan <zhanghuan@nrchpc.ac.cn>
9569 * kern/misc.c (grub_strcat): Minor speed optimization (same code size).
9571 2008-04-13 Robert Millan <rmh@aybabtu.com>
9573 Improve robustness when handling LVM.
9575 * disk/lvm.c (grub_lvm_getvalue): Return 0 when `*p' is NULL
9576 (and leave `*p' unmodified).
9577 (grub_lvm_iterate): Don't assume `vg->lvs != NULL' when iterating
9579 (grub_lvm_memberlist): Don't assume `lv->vg->pvs != NULL' when
9580 iterating through it.
9581 (grub_lvm_open): Don't assume `vg->lvs != NULL' when iterating
9583 (grub_lvm_scan_device): Check the return value (and fail gracefully
9584 when due) on each grub_lvm_getvalue() or grub_strstr() call.
9585 Don't assume `vg->pvs != NULL' when iterating through it.
9587 2008-04-13 Robert Millan <rmh@aybabtu.com>
9589 * gendistlist.sh (EXTRA_DISTFILES): Add `genpartmaplist.sh'.
9590 * genmk.rb (partmap): New variable.
9591 (CLEANFILES, PARTMAPFILES): Add #{partmap}.
9592 (#{partmap}): New target rule.
9593 * genpartmaplist.sh: New file.
9594 * Makefile.in (pkglib_DATA): Add partmap.lst.
9595 (partmap.lst): New target rule.
9596 * util/i386/pc/grub-mkrescue.in: Generate grub.cfg that loads needed
9597 modules (including all partition maps), instead of preloading them.
9599 2007-04-13 Fabian Greffrath <fabian.greffrath@web.de>
9601 * util/grub.d/30_os-prober.in: New script. Use `os-prober' and
9602 `linux-boot-prober' (if installed) to detect other operating
9603 systems which are installed on the computer and add them to
9605 * conf/common.rmk: Build and install 30_os-prober.
9607 2008-04-12 Robert Millan <rmh@aybabtu.com>
9609 * kern/powerpc/ieee1275/init.c: Move from here ...
9610 * kern/ieee1275/init.c: ... to here. Update all users.
9612 * kern/powerpc/ieee1275/cmain.c: Move from here ...
9613 * kern/ieee1275/cmain.c: ... to here. Update all users.
9615 * kern/powerpc/ieee1275/openfw.c: Move from here ...
9616 * kern/ieee1275/openfw.c: ... to here. Update all users.
9618 * loader/powerpc/ieee1275/multiboot2.c: Move from here ...
9619 * loader/ieee1275/multiboot2.c: ... to here. Update all users.
9621 2008-04-10 Pavel Roskin <proski@gnu.org>
9623 * configure.ac: Always use "_cv_" in cache variables for
9624 compatibility with Autoconf 2.62.
9626 2008-04-07 Robert Millan <rmh@aybabtu.com>
9628 Revert grub/machine/init.h addition by Pavel (since it breaks on
9629 i386-ieee1275 and others):
9630 * util/i386/pc/misc.c: Remove grub/machine/init.h.
9631 * util/powerpc/ieee1275/misc.c: Likewise.
9633 2008-04-07 Robert Millan <rmh@aybabtu.com>
9635 * util/grub-probe.c (probe): Improve error message.
9637 2008-04-07 Robert Millan <rmh@aybabtu.com>
9639 * util/biosdisk.c (read_device_map): Skip devices that don't exist
9640 (this prevents the presence of a bogus entry from ruining the whole
9643 2008-04-06 Pavel Roskin <proski@gnu.org>
9645 * util/biosdisk.c: Include grub/util/biosdisk.h.
9646 * util/grub-fstest.c (execute_command): Make static.
9647 * util/grub-mkdevicemap.c (check_device): Likewise.
9648 * util/i386/pc/misc.c: Include grub/machine/init.h.
9649 * util/powerpc/ieee1275/misc.c: Likewise.
9650 * util/lvm.c: Include grub/util/lvm.h.
9651 * util/misc.c: Include grub/kernel.h, grub/misc.h and
9653 * util/raid.c: Include grub/util/raid.h.
9654 (grub_util_getdiskname): Make static.
9656 * util/grub-emu.c (main): Remove calls to grub_hostfs_init() and
9657 grub_hostfs_fini(), as they are called from grub_init_all() and
9658 grub_fini_all() respectively. This fixes an infinite loop in
9659 grub-fstest due to double registration of hostfs.
9660 Reported by Christian Franke <Christian.Franke@t-online.de>
9662 2008-04-05 Pavel Roskin <proski@gnu.org>
9664 * bus/pci.c (grub_pci_iterate): For multifunction devices, probe
9665 all 8 functions. Otherwise, probe function 0 only.
9667 2008-04-04 Pavel Roskin <proski@gnu.org>
9669 * commands/lspci.c (grub_lspci_iter): Print the bus number
9672 * commands/lspci.c (grub_pci_classes): Fix typos.
9673 (grub_lspci_iter): Don't print func twice. Print vendor ID
9674 before device ID, as it's normally done.
9676 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
9677 Fix signedness warnings.
9678 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate):
9680 * util/ieee1275/get_disk_name.c: Include config.h so that
9681 _GNU_SOURCE is defined and getline() is declared. Mark an
9682 unused argument as such. Fix a signedness warning.
9684 2008-04-02 Pavel Roskin <proski@gnu.org>
9686 * genkernsyms.sh.in: Use more robust assignments for CC and
9687 srcdir. Quote srcdir.
9688 * gensymlist.sh.in: Likewise. Assert at the compile time that
9689 the symbol table is not empty.
9691 * disk/raid.c (grub_raid_memberlist): Fix a signedness warning.
9692 * fs/cpio.c (grub_cpio_read): Likewise.
9694 2008-04-01 Pavel Roskin <proski@gnu.org>
9696 * disk/ata.c (grub_ata_open): Don't lose precision in disk->id.
9697 * disk/host.c (grub_host_open): Likewise.
9698 * disk/loopback.c (grub_loopback_open): Likewise.
9699 * disk/memdisk.c (grub_memdisk_open): Use a string pointer for
9700 disk->id as in disk/host.c, not a multi-character constant.
9702 * util/grub-fstest.c (cmd_cmp): Use fseeko(), not fseek(). The
9703 later is obsolete, potentially dangerous and sets a bad example.
9704 * util/i386/efi/grub-mkimage.c (make_header): Likewise.
9705 * util/misc.c (grub_util_get_image_size): Likewise.
9707 * disk/loopback.c (options): Improve help for "--partitions".
9709 * normal/arg.c (grub_arg_show_help): Fix spacing of the long
9710 options to align them with the short options, e.g. "echo -e".
9712 2008-03-31 Bean <bean123ch@gmail.com>
9714 * video/reader/png.c (grub_png_data): New member is_16bit and
9716 (grub_png_decode_image_header): Detect 16 bit png image.
9717 (grub_png_convert_image): New function to convert 16 bit image to 8 bit.
9718 (grub_png_decode_png): Call grub_png_convert_image for 16 bit image.
9719 (grub_video_reader_png): Release memory occupied by image_data.
9721 * fs/ntfs.c (find_attr): Handle non-resident attribute list larger than
9723 (grub_nfs_mount): Skip the test for sector per cluster.
9725 * include/grub/ntfs.h (MAX_SPC): Removed.
9727 2008-03-31 Bean <bean123ch@gmail.com>
9729 * conf/common.rmk (pkgdata_MODULES): Add afs.mod.
9730 (grub_probe_SOURCES): Add fs/afs.c.
9731 (grub_fstest_SOURCES): Likewise.
9732 (afs_mod_SOURCES): New variable.
9733 (afs_mod_CFLAGS): Likewise.
9734 (afs_mod_LDFLAGS): Likewise.
9736 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/afs.c.
9737 (grub_emu_SOURCES): Likewise.
9739 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
9741 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
9743 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
9745 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
9747 * fs/afs.c: New file.
9749 2008-03-30 Pavel Roskin <proski@gnu.org>
9751 * disk/host.c: Include grub/misc.h to fix a warning.
9752 * util/hostfs.c: Use GRUB_MOD_INIT and GRUB_MOD_FINI to fix
9753 warnings about implicit declarations.
9755 * fs/udf.c (grub_udf_mount): Fix warning about a shadowing a
9757 * include/grub/i386/loader.h: Change declaration of
9758 grub_linux_boot() to match what grub_loader_set() expects.
9759 * util/getroot.c (grub_guess_root_device): Return const char* to
9761 * util/grub-probe.c (probe): Fix a warning about uninitialized
9762 abstraction_name variable.
9763 * util/i386/get_disk_name.c (grub_util_get_disk_name): Mark
9764 second argument as unused to fix a warning.
9766 * loader/i386/pc/multiboot2.c (grub_mb2_arch_elf64_hook): Add
9767 missing grub_error() call.
9769 * util/update-grub_lib.in: Define datarootdir, since Autoconf
9770 2.60 and newer uses it to define datadir.
9772 * commands/sleep.c: Fix warning about implicit declaration.
9773 * disk/memdisk.c: Likewise.
9774 * loader/aout.c: Likewise.
9775 * loader/i386/bsd_normal.c: Likewise.
9776 * util/grub-probe.c: Likewise.
9778 * commands/i386/cpuid.c (has_longmode): Make static.
9779 * disk/i386/pc/biosdisk.c (cd_drive): Likewise.
9780 * include/grub/i386/bsd.h (bios_memmap_t): Remove, it's unused.
9782 * kern/i386/pc/startup.S (real_to_prot): Use %cs prefix to load
9783 GDT. This is more robust, as %ds can change.
9784 (grub_biosdisk_rw_int13_extensions): Don't clear %ds before
9785 calling real_to_prot().
9786 (grub_biosdisk_get_diskinfo_int13_extensions): Likewise.
9788 2008-03-28 Pavel Roskin <proski@gnu.org>
9790 * kern/i386/pc/startup.S: Assert that uncompressed functions
9791 don't spill beyond GRUB_KERNEL_MACHINE_RAW_SIZE.
9792 * kern/i386/pc/lzo1x.S: Remove all .align directives in the
9793 code, as they push parts of the code (error handlers) beyond
9794 GRUB_KERNEL_MACHINE_RAW_SIZE. Speed is not as important in this
9795 code as correctness and size.
9797 2008-03-28 Pavel Roskin <proski@gnu.org>
9799 * kern/i386/pc/startup.S
9800 (grub_biosdisk_get_diskinfo_int13_extensions): When converting
9801 data block address to the real mode, keep offset minimal. This
9802 works around a bug in AWARD BIOS on old Athlon systems, which
9803 makes CD detection hang.
9805 2008-03-26 Pavel Roskin <proski@gnu.org>
9807 * normal/color.c (grub_parse_color_name_pair): Make `name' a
9809 * include/grub/normal.h: Add grub_parse_color_name_pair()
9812 2008-03-24 Bean <bean123ch@gmail.com>
9814 * disk/i386/pc/biosdisk.c (cd_start): Removed.
9815 (cd_count): Removed.
9816 (cd_drive): New variable.
9817 (grub_biosdisk_get_drive): Don't check for (cdN) device.
9818 (grub_biosdisk_call_hook): Likewise.
9819 (grub_biosdisk_iterate): Change cdrom detection method.
9820 (grub_biosdisk_open): Replace cd_start with cd_drive.
9821 (GRUB_MOD_INIT): Use grub_biosdisk_get_cdinfo_int13_extension to
9822 detect cdrom device.
9824 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_MACHINE_CDROM_START):
9826 (GRUB_BIOSDISK_MACHINE_CDROM_END): Removed.
9827 (GRUB_BIOSDISK_CDTYPE_NO_EMUL): New macro.
9828 (GRUB_BIOSDISK_CDTYPE_1_2_M): Likewise.
9829 (GRUB_BIOSDISK_CDTYPE_1_44_M): Likewise.
9830 (GRUB_BIOSDISK_CDTYPE_2_88_M): Likewise.
9831 (GRUB_BIOSDISK_CDTYPE_HARDDISK): Likewise.
9832 (GRUB_BIOSDISK_CDTYPE_MASK): Likewise.
9833 (grub_biosdisk_cdrp): New structure.
9834 (grub_biosdisk_get_cdinfo_int13_extensions): New function.
9836 * include/grub/i386/pc/kernel.h (grub_boot_drive): Export this variable.
9838 * kern/i386/pc/init.c (make_install_device): Don't use (cdN) as root
9841 * kern/i386/pc/startup.S (grub_biosdisk_get_cdinfo_int13_extensions):
9844 2008-03-20 Robert Millan <rmh@aybabtu.com>
9846 Remove 2 TiB limit in ata.mod.
9847 * disk/ata.c (grub_ata_device): Promote `size' to grub_uint64_t.
9848 (grub_ata_dumpinfo): Print sector count with 0x%llx.
9849 (grub_ata_identify): Interpret `&info16[100]' as a pointer to
9850 grub_uint64_t instead of grub_uint32_t.
9852 2008-03-05 Bean <bean123ch@gmail.com>
9854 * loader/i386/pc/multiboot.c (grub_multiboot_get_bootdev): New function.
9855 (grub_multiboot): Set boot device.
9857 * boot/i386/pc/lnxboot.S (real_code_2): Set %dh to 0xFF.
9859 2008-03-02 Bean <bean123ch@gmail.com>
9861 * fs/reiserfs.c (grub_reiserfs_read_symlink): Add 0 at the end of
9864 2008-03-01 Yoshinori K. Okuji <okuji@enbug.org>
9866 * DISTLIST: Added docs/fdl.texi, docs/grub.texi, docs/mdate-sh and
9869 * docs/grub.texi: New file. Copied from GRUB Legacy, and slightly
9872 * docs/fdl.texi: New file.
9874 * docs/mdate-sh: New file. Copied from gnulib.
9875 * docs/texinfo.tex: Likewise.
9877 * config.guess: Updated from gnulib.
9878 * install-sh: Likewise.
9880 2008-02-28 Robert Millan <rmh@aybabtu.com>
9882 * conf/i386-linuxbios.rmk (pkglib_MODULES): Add aout.mod.
9883 (aout_mod_SOURCES): New variable.
9884 (aout_mod_CFLAGS): Likewise.
9885 (aout_mod_LDFLAGS): Likewise.
9887 * conf/i386-ieee1275.rmk: Likewise.
9889 2008-02-28 Robert Millan <rmh@aybabtu.com>
9891 * util/update-grub.in: Reorganise terminal validity check. Accept
9892 `ieee1275:console' (OLPC) and `*:gfxterm' as valid too.
9893 Based on suggestion by Franklin PIAT.
9895 2008-02-28 Fabian Greffrath <greffrath@leat.rub.de>
9897 * include/grub/util/getroot.h (grub_util_check_block_device): Export new
9899 * util/getroot.c (grub_util_check_block_device): New function that
9900 returns the given argument if it is a block device and returns NULL else.
9901 * util/grub-probe.c (argument_is_device): New variable.
9902 (probe): Promote device_name from a variable to an argument. Receive
9903 device_name from grub_util_check_block_device() if path is NULL and from
9904 grub_guess_root_device() else. Do not free() device_name anymore.
9905 (options): Introduce new parameter '-d, --device'.
9906 (main): Add description of the new parameter to the help screen.
9907 Rename path variable to argument. Set argument_is_device if the '-d'
9908 option is given. Pass argument to probe() depending on
9911 2008-02-24 Bean <bean123ch@gmail.com>
9913 * fs/iso9660.c (GRUB_ISO9660_VOLDESC_BOOT): New macro.
9914 (GRUB_ISO9660_VOLDESC_PRIMARY): Likewise.
9915 (GRUB_ISO9660_VOLDESC_SUPP): Likewise.
9916 (GRUB_ISO9660_VOLDESC_PART): Likewise.
9917 (GRUB_ISO9660_VOLDESC_END): Likewise.
9918 (grub_iso9660_primary_voldesc): New member escape.
9919 (grub_iso9660_data): New member joliet.
9920 (grub_iso9660_convert_string): New function.
9921 (grub_iso9660_mount): Detect joliet extension.
9922 (grub_iso9660_iterate_dir): Convert filename when joliet is detected.
9923 (grub_iso9660_iso9660_label): Likewise.
9925 * conf/common.rmk (pkgdata_MODULES): Add udf.mod.
9926 (grub_setup_SOURCES): Add fs/udf.c.
9927 (grub_fstest_SOURCES): Likewise.
9928 (udf_mod_SOURCES): New variable.
9929 (udf_mod_CFLAGS): Likewise.
9930 (udf_mod_LDFLAGS): Likewise.
9932 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/udf.c.
9933 (grub_emu_SOURCES): Likewise.
9935 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
9937 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
9939 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
9941 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
9943 * fs/udf.c: New file.
9945 2008-02-24 Robert Millan <rmh@aybabtu.com>
9947 * conf/i386-efi.rmk (normal/function.c_DEPENDENCIES)
9948 (normal/lexer.c_DEPENDENCIES): New variables.
9949 * conf/i386-ieee1275.rmk (normal/function.c_DEPENDENCIES)
9950 (normal/lexer.c_DEPENDENCIES): Likewise.
9951 * conf/i386-linuxbios.rmk (normal/function.c_DEPENDENCIES)
9952 (normal/lexer.c_DEPENDENCIES): Likewise.
9953 * conf/i386-pc.rmk (normal/function.c_DEPENDENCIES)
9954 (normal/lexer.c_DEPENDENCIES): Likewise.
9955 * conf/powerpc-ieee1275.rmk (normal/function.c_DEPENDENCIES)
9956 (normal/lexer.c_DEPENDENCIES): Likewise.
9957 * conf/sparc64-ieee1275.rmk (normal/function.c_DEPENDENCIES)
9958 (normal/lexer.c_DEPENDENCIES): Likewise.
9960 2008-02-23 Robert Millan <rmh@aybabtu.com>
9962 * partmap/gpt.c (grub_gpt_magic): Add `0x' qualifier to each member,
9963 since they were intended to be in hex. This didn't break previously
9964 because of a bug in gpt_partition_map_iterate() (see below).
9966 (gpt_partition_map_iterate): Replace `grub_memcmp' with `! grub_memcmp'
9967 when checking the validity of GPT header.
9968 Remove `partno', since it always provides the same information as `i'.
9970 2008-02-21 Yoshinori K. Okuji <okuji@enbug.org>
9972 * include/grub/efi/time.h: Fix a wrong comment.
9974 2008-02-19 Pavel Roskin <proski@gnu.org>
9976 * kern/rescue.c (grub_enter_rescue_mode): Improve initial
9979 2008-02-19 Bean <bean123ch@gmail.com>
9981 * conf/i386-pc.rmk (pkglib_MODULES): Add aout.mod _bsd.mod and bsd.mod.
9982 (aout_mod_SOURCES): New variable.
9983 (aout_mod_CFLAGS): Likewise.
9984 (aout_mod_LDFLAGS): Likewise.
9985 (_bsd_mod_SOURCES): New variable.
9986 (_bsd_mod_CFLAGS): Likewise.
9987 (_bsd_mod_LDFLAGS): Likewise.
9988 (bsd_mod_SOURCES): New variable.
9989 (bsd_mod_CFLAGS): Likewise.
9990 (bsd_mod_LDFLAGS): Likewise.
9992 * include/grub/aout.h: New file.
9994 * include/grub/i386/loader.h (grub_unix_real_boot): New function.
9996 * include/grub/i386/bsd.h: New file.
9998 * include/grub/i386/pc/init.h (grub_get_mmap_entry): Use EXPORT_FUNC
10001 * kern/elf.c (grub_elf32_load): Get the physical address after the hook
10002 function is called, so that it's possible to change it inside the hook.
10003 (grub_elf64_load): Likewise.
10004 (grub_elf_file): Don't close the file if elf header is not found.
10005 (grub_elf_close): Close the file if grub_elf_file fails (The new
10006 grub_elf_file won't close it).
10007 (grub_elf32_size): Use NESTED_FUNC_ATTR for nested function calcsize.
10008 (grub_elf64_size): Likewise.
10010 * kern/i386/loader.S (grub_unix_real_boot): New function.
10012 * loader/aout.c: New file.
10014 * loader/i386/bsd.c: New file.
10016 * loader/i386/bsd_normal.c: New file.
10018 * loader/i386/pc/multiboot.c (grub_multiboot): Handle a.out format.
10020 * loader/multiboot2.c (grub_multiboot2): Reset grub_errno so that it
10021 can test other formats.
10023 2008-02-19 Robert Millan <rmh@aybabtu.com>
10025 * partmap/gpt.c: Include `<grub/gpt_partition.h>'.
10026 (grub_gpt_partition_type_empty): Redefine with macro from
10027 `<grub/gpt_partition.h>'.
10028 (gpt_partition_map_iterate): Adjust partition type comparison.
10030 Export `entry' as partmap-specific `part.data' struct.
10031 (grub_gpt_header, grub_gpt_partentry): Move from here ...
10033 * include/grub/gpt_partition.h (grub_gpt_header)
10034 (grub_gpt_partentry): ... to here (new file).
10036 * util/i386/pc/grub-setup.c: Include `<grub/gpt_partition.h>'.
10038 (grub_gpt_partition_type_bios_boot): New const variable, defined
10039 with macro from `<grub/gpt_partition.h>'.
10041 (setup): Replace `first_start' with `embed_region', which keeps
10042 track of the embed region (and is partmap-agnostic).
10044 Replace find_first_partition_start() with find_usable_region(),
10045 which finds a usable region for embedding using partmap-specific
10046 knowledge (supports PC/MSDOS and GPT).
10048 Fix all assumptions that the embed region start at sector 1, using
10049 `embed_region.start' from now on. Similarly, use `embed_region.end'
10050 rather than `first_start' to calculate available size.
10052 In grub_util_info() message, replace "into after the MBR" with an
10053 indication of the specific sector our embed region starts at.
10055 2008-02-19 Robert Millan <rmh@aybabtu.com>
10057 * DISTLIST: Replace `commands/ieee1275/halt.c' and
10058 `commands/ieee1275/reboot.c' with `commands/halt.c' and
10059 `commands/reboot.c'.
10060 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
10061 (halt_mod_SOURCES): Likewise.
10062 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
10063 (halt_mod_SOURCES): Likewise.
10065 2008-02-17 Christian Franke <franke@computer.org>
10067 * commands/cat.c (grub_cmd_cat): Add break on GRUB_TERM_ESC key.
10069 2008-02-17 Robert Millan <rmh@aybabtu.com>
10071 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
10072 set `first_start' to 0 for non-PC/MSDOS partition maps.
10074 2008-02-16 Robert Millan <rmh@aybabtu.com>
10076 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
10077 do not assume partition map is PC/MSDOS before performing checks that
10078 are specific to that layout.
10080 2008-02-13 Robert Millan <rmh@aybabtu.com>
10082 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Remove
10083 `commands/i386/pc/halt.c' and `commands/i386/pc/reboot.c'.
10084 * kern/i386/linuxbios/init.c (grub_halt, grub_reboot): Remove stubs.
10086 2008-02-13 Yoshinori K. Okuji <okuji@enbug.org>
10088 * configure.ac: Only a cosmetic change on the handling of
10089 -fno-stack-protector.
10091 2008-02-12 Alexandre Boeglin <alex@boeglin.org>
10093 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace
10094 commands/i386/pc/halt.c and reboot.c by commands/halt.c and
10096 (grub_install_SOURCES): Add halt.mod and reboot.mod.
10097 (halt_mod_SOURCES): New variable.
10098 (halt_mod_CFLAGS): Likewise.
10099 (halt_mod_LDFLAGS): Likewise.
10100 (reboot_mod_SOURCES): Likewise.
10101 (reboot_mod_CFLAGS): Likewise.
10102 (reboot_mod_LDFLAGS): Likewise.
10104 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace
10105 commands/ieee1275/halt.c and reboot.c by commands/halt.c and
10107 (halt_mod_SOURCES): Likewise.
10108 (reboot_mod_SOURCES): Likewise.
10110 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace
10111 commands/i386/pc/reboot.c by commands/reboot.c.
10112 (reboot_mod_SOURCES): Likewise.
10114 * commands/i386/pc/reboot.c: merge this file ...
10116 * commands/ieee1275/reboot.c: ... and this file ...
10118 * commands/reboot.c: ... to this file.
10119 Add some precompiler directive to include the correct header for
10122 * commands/ieee1275/halt.c: move this file ...
10124 * commands/halt.c: ... to here.
10125 Add some precompiler directive to include the correct header for
10128 * include/grub/efi/efi.h (grub_reboot): New function declaration.
10129 (grub_halt): Likewise.
10131 * kern/efi/efi.c (grub_reboot): New function.
10132 (grub_halt): Likewise.
10134 2008-02-12 Robert Millan <rmh@aybabtu.com>
10136 * util/getroot.c (grub_guess_root_device): Inspect /dev/evms before
10137 /dev (like it is done for /dev/mapper). This doesn't provide support
10138 for EVMS, but at least it is now easy to identify the problem when it
10141 2008-02-11 Robert Millan <rmh@aybabtu.com>
10143 * util/biosdisk.c (grub_util_biosdisk_open, linux_find_partition)
10144 (grub_util_biosdisk_get_grub_dev): Check open() exit status by
10145 comparing it with -1, not 0.
10147 2008-02-10 Robert Millan <rmh@aybabtu.com>
10149 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `disk/raid.c' and
10151 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
10152 * conf/i386-pc.rmk (grub_setup_SOURCES): Likewise.
10154 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Move `disk/raid.c' and
10155 `disk/lvm.c' to the end of the list.
10156 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
10157 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
10159 2008-02-10 Robert Millan <rmh@aybabtu.com>
10161 * kern/main.c (grub_load_normal_mode): Do not reset `grub_errno'. Call
10162 grub_print_error() instead. This will let user know why we're entering
10164 Based on suggestions from Sam Morris.
10166 2008-02-10 Alexandre Boeglin <alex@boeglin.org>
10168 * normal/arg.c (grub_arg_parse): If one of the args is "--", call add_arg()
10169 on remaining N args, instead of "--" arg N times.
10171 2008-02-09 Vesa Jaaskelainen <chaac@nic.fi>
10173 * font/manager.c (unknown_glyph): Added variable for unknown glyph.
10174 (fill_with_default_glyph): Changed to use unknown_glyph for fill
10175 pattern for unknown glyphs.
10177 2008-02-09 Robert Millan <rmh@aybabtu.com>
10179 * configure.ac: Probe for `help2man'.
10180 * Makefile.in (builddir): New variable.
10181 (HELP2MAN): Likewise. Set to `true' when @HELP2MAN@ doesn't provide it,
10182 or otherwise add a few flags/options to it.
10183 (install-local): For every executable utility or script that is
10184 installed, invoke $(HELP2MAN) to install a manpage based on --help
10187 * util/i386/pc/grub-install.in: Move down `update-grub_lib' sourcing, so
10188 that it doesn't prevent --help from working in build tree.
10190 * util/i386/pc/grub-mkrescue.in (usage): Replace `grub-devel@gnu.org'
10191 with `bug-grub@gnu.org'.
10192 * util/powerpc/ieee1275/grub-mkrescue.in (usage): Likewise.
10193 * util/update-grub.in (usage): New function.
10194 Implement proper argument check, with support for --help and --version
10195 (as well as existing -y).
10197 2008-02-09 Christian Franke <franke@computer.org>
10199 * commands/cat.c (grub_cmd_cat): Print '\r' as hex to
10200 avoid overwriting previous output.
10201 * kern/rescue.c (grub_rescue_cmd_cat): Likewise.
10203 2008-02-09 Robert Millan <rmh@aybabtu.com>
10205 * normal/menu.c (run_menu): If timeout is set to zero, don't bother
10208 2008-02-09 Robert Millan <rmh@aybabtu.com>
10210 * commands/sleep.c: New file.
10211 * conf/common.rmk (pkglib_MODULES): Add `commands/sleep.c'.
10212 (sleep_mod_SOURCES): New variable.
10213 (sleep_mod_CFLAGS): Likewise.
10214 (sleep_mod_LDFLAGS): Likewise.
10216 2008-02-09 Robert Millan <rmh@aybabtu.com>
10218 * disk/raid.c (grub_raid_scan_device): Add a pair of sanity checks for
10219 situations in which we can deduce the RAID size and the superblock
10222 2008-02-09 Robert Millan <rmh@aybabtu.com>
10224 * disk/lvm.c [GRUB_UTIL] (grub_lvm_memberlist): New function. Construct
10225 and return a grub_diskmemberlist_t composed of LVM physical volumes.
10226 [GRUB_UTIL] (grub_lvm_dev): Add `memberlist' member.
10228 * disk/raid.c [GRUB_UTIL] (grub_raid_memberlist): New function. Construct
10229 and return a grub_diskmemberlist_t composed of physical array members.
10230 [GRUB_UTIL] (grub_raid_dev): Add `memberlist' member.
10232 * include/grub/disk.h [GRUB_UTIL] (grub_disk_memberlist): New struct
10234 [GRUB_UTIL] (struct grub_disk_dev): Add `memberlist' function pointer.
10235 [GRUB_UTIL] (struct grub_disk_memberlist): New struct declaration.
10236 [GRUB_UTIL] (grub_disk_memberlist_t): New typedef.
10238 * util/grub-probe.c (probe): Move partmap probing code from here ...
10239 (probe_partmap): ... to here.
10240 (probe): Use probe_partmap() once for the disk we're probing, and
10241 additionally, when such disk contains a memberlist() struct member,
10242 once for each disk that is contained in the structure returned by
10245 2008-02-09 Robert Millan <rmh@aybabtu.com>
10247 * util/grub-probe.c (main): When `verbosity > 1', set `debug'
10248 environment variable to 'all' in order to obtain debug output from
10250 * util/i386/pc/grub-setup.c (main): Likewise.
10252 2008-02-08 Robert Millan <rmh@aybabtu.com>
10254 * disk/raid.c (grub_raid_scan_device): Check for
10255 `array->device[sb.this_disk.number]' rather than for
10256 `array->device[sb.this_disk.number]->name', since the latter is not
10257 guaranteed to be accessible.
10259 2008-02-08 Robert Millan <rmh@aybabtu.com>
10261 * disk/raid.c: Update copyright.
10262 * fs/cpio.c: Likewise.
10263 * include/grub/raid.h: Likewise.
10264 * loader/i386/pc/multiboot.c: Likewise.
10265 * util/hostfs.c: Likewise.
10267 2008-02-08 Robert Millan <rmh@aybabtu.com>
10269 * include/grub/raid.h (struct grub_raid_array): Change type of `device'
10270 to a grub_disk_t array.
10271 * disk/raid.c (grub_raid_read): Replace `device[x].disk' accesses with
10273 (grub_raid_scan_device): Replace `device[x].name' accesses with
10274 `device[x]->name'. Simplify initialization of `array->device[x]'.
10276 2008-02-08 Robert Millan <rmh@aybabtu.com>
10278 * disk/raid.c (grub_raid_open, grub_raid_scan_device): Add a few
10279 grub_dprintf() calls.
10280 * kern/disk.c (grub_disk_read): Include grub_errmsg in out of range
10283 2008-02-07 Christian Franke <franke@computer.org>
10285 * util/hostfs.c (grub_hostfs_open): Use fseeko and ftello
10286 instead of fseek and ftell to support large files.
10287 (grub_hostfs_read): Likewise.
10289 2008-02-07 Robert Millan <rmh@aybabtu.com>
10291 Patch from Jeroen Dekkers.
10292 * disk/raid.c (grub_raid_scan_device): Reset `grub_errno' on disk
10293 failure, since successfully reading all array members might not be
10296 2008-02-06 Robert Millan <rmh@aybabtu.com>
10298 * util/grub-probe.c (probe): Simplify partmap probing (with the
10299 assumption that the first word up to the underscore equals to
10302 2008-02-06 Christian Franke <franke@computer.org>
10304 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_NONE
10305 (and set *ofs = 0) instead of GRUB_ERR_FILE_NOT_FOUND on
10306 last block of a cpio or tar stream.
10307 Check for "TRAILER!!!" instead of any empty data
10308 block to detect last block of a cpio stream.
10309 (grub_cpio_dir): Fix constness of variable np.
10310 (grub_cpio_open): Return GRUB_ERR_FILE_NOT_FOUND if
10311 cpio or tar trailer is detected. This fixes a crash
10312 on open of a non existing file.
10314 2008-02-05 Bean <bean123ch@gmail.com>
10316 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Get physical
10318 (grub_multiboot_load_elf64): Likewise.
10319 (grub_multiboot): Initialize mbi structure.
10321 * util/grub-fstest.c: Don't include unused header file script.h.
10323 * conf/common.rmk (grub-fstest.c_DEPENDENCIES): Move to the beginning
10325 (grub_fstest_SOURCES): Likewise.
10327 2008-02-05 Robert Millan <rmh@aybabtu.com>
10329 * include/grub/term.h (GRUB_TERM_LEFT, GRUB_TERM_RIGHT)
10330 (GRUB_TERM_UP, GRUB_TERM_DOWN, GRUB_TERM_HOME, GRUB_TERM_END)
10331 (GRUB_TERM_DC, GRUB_TERM_PPAGE, GRUB_TERM_NPAGE, GRUB_TERM_ESC)
10332 (GRUB_TERM_TAB, GRUB_TERM_BACKSPACE): New macros.
10334 * kern/i386/pc/startup.S: Include `<grub/term.h>'.
10335 (translation_table): Replace hardcoded values with macros
10336 provided by `<grub/term.h>'.
10338 * term/i386/pc/at_keyboard.c: Include `<grub/term.h>'.
10339 (keyboard_map): Correct/add a few values, with macros provided
10340 by `<grub/term.h>'.
10341 (keyboard_map_shift): Zero values that don't differ from their
10342 `keyboard_map' equivalents.
10343 (grub_console_checkkey): Optimize KEYBOARD_STATUS_CAPS_LOCK toggling.
10344 Discard the second scan code that is always sent by Caps lock.
10345 Only use `keyboard_map_shift' when it provides a non-zero value,
10346 otherwise fallback to `keyboard_map'.
10348 2008-02-04 Bean <bean123ch@gmail.com>
10350 * Makefile.in (enable_grub_fstest): New variable.
10352 * conf/common.rmk (grub_fstest_init.lst): New rule.
10353 (grub_fstest_init.h): Likewise.
10354 (grub_fstest_init.c): Likewise.
10355 (util/grub-fstest.c_DEPENDENCIES): New variable.
10356 (grub_fstest_SOURCES): Likewise.
10358 * configure.ac (enable_grub_fstest): Check for --enable-grub-fstest.
10360 * util/grub-fstest.c: New file.
10362 2008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
10364 Make grub-setup handle a separate root device.
10366 * util/i386/pc/grub-setup.c (setup): Always open the root device,
10367 so that the root device can be compared with the destination
10369 When embedding the core image, if the root and destination devices
10370 are different, set ROOT_DRIVE to ROOT_DEV->DISK->ID. Otherwise, to
10372 When not embedding, set ROOT_DRIVE to 0xFF.
10374 2008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
10376 Add support for having a grub directory in a different drive. This
10377 is still only the data handling part.
10379 * kern/i386/pc/startup.S (multiboot_trampoline): Set %dh to 0xFF.
10380 (codestart): Save %dh in GRUB_ROOT_DRIVE.
10381 (grub_root_drive): New variable.
10383 * kern/i386/pc/init.c (make_install_device): Use GRUB_ROOT_DRIVE
10384 instead of GRUB_BOOT_DRIVE to construct a device name. Set
10385 GRUB_ROOT_DRIVE to GRUB_BOOT_DRIVE if it is 0xFF, otherwise use it
10388 * include/grub/i386/pc/kernel.h (grub_root_drive): New prototype.
10390 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_ROOT_DRIVE): New
10392 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Set to 0x4f.
10394 * boot/i386/pc/pxeboot.S (_start): Set %dh to 0xFF. For now, this
10395 is bogus, because PXE booting does not specify any drive
10398 * boot/i386/pc/lnxboot.S (reg_edx): Set the second byte to 0xFF. I
10399 am not sure if this is really correct.
10401 * boot/i386/pc/cdboot.S: Set %dh to 0xFF, because the root drive
10402 is always identical to the boot drive when booting from a CD.
10404 * boot/i386/pc/boot.S (MOV_MEM_TO_AL): Removed. Not needed any
10406 (root_drive): New variable.
10407 (real_start): Unconditionally set %dh to ROOT_DRIVE.
10408 (setup_sectors): Push %dx right after popping it, because %dh will
10410 (copy_buffer): Restore %dx.
10412 2008-02-03 Robert Millan <rmh@aybabtu.com>
10414 * util/i386/pc/grub-mkrescue.in: Rewrite most of image generation to
10415 use `cdboot.img' for cdrom images.
10417 2008-02-03 Robert Millan <rmh@aybabtu.com>
10419 * util/grub.d/00_header.in: Issue scripting commands for GRUB to
10420 only setup gfxterm when `font' command has succeeded.
10422 2008-02-03 Robert Millan <rmh@aybabtu.com>
10424 * loader/multiboot_loader.c [GRUB_MACHINE_LINUXBIOS]
10425 (grub_rescue_cmd_multiboot_loader)
10426 (grub_rescue_cmd_module_loader): Enable multiboot1 calls.
10428 2008-02-03 Pavel Roskin <proski@gnu.org>
10430 * kern/i386/pc/startup.S (grub_chainloader_real_boot): Pop
10431 %edx and %esi from stack only after grub_gate_a20() is called.
10432 grub_gate_a20() clobbers %edx.
10434 2008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
10436 * configure.ac (AC_INIT): Bumped to 1.96.
10438 * DISTLIST: Added boot/i386/pc/cdboot.S, bus/pci.c,
10439 commands/lspci.c,disk/memdisk.c, include/grub/pci.h,
10440 include/grub/i386/pc/pci.h, video/readers/jpeg.c, and
10441 video/readers/png.c.
10443 2008-02-03 Bean <bean123ch@gmail.com>
10445 * conf/i386-pc.rmk (pkglib_IMAGES): Add cdboot.img.
10446 (cdboot_img_SOURCES): New variable.
10447 (cdboot_img_ASFLAGS): New variable.
10448 (cdboot_img_LDFLAGS): New variable.
10450 * boot/i386/pc/cdboot.S: New file.
10452 * disk/i386/pc/biosdisk.c (cd_start): New variable.
10453 (cd_count): Likewise.
10454 (grub_biosdisk_get_drive): Add support for cd device.
10455 (grub_biosdisk_call_hook): Likewise.
10456 (grub_biosdisk_iterate): Likewise.
10457 (grub_biosdisk_open): Likewise.
10458 (GRUB_BIOSDISK_CDROM_RETRY_COUNT): New macro.
10459 (grub_biosdisk_rw): Support reading from cd device.
10460 (GRUB_MOD_INIT): Iterate cd devices.
10462 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_FLAG_CDROM): New macro.
10463 (GRUB_BIOSDISK_MACHINE_CDROM_START): Likewise.
10464 (GRUB_BIOSDISK_MACHINE_CDROM_END): Likewise.
10466 * kern/i386/pc/init.c (make_install_device): Check for cd device.
10468 2008-02-02 Robert Millan <rmh@aybabtu.com>
10470 * commands/read.c: New file.
10471 * conf/common.rmk (pkglib_MODULES): Add `commands/read.c'.
10472 (read_mod_SOURCES): New variable.
10473 (read_mod_CFLAGS): Likewise.
10474 (read_mod_LDFLAGS): Likewise.
10476 2008-02-02 Robert Millan <rmh@aybabtu.com>
10478 * normal/main.c (grub_normal_execute): Check for `menu->size' when
10479 determining whether menu has to be displayed.
10481 2008-02-02 Marco Gerards <marco@gnu.org>
10483 * bus/pci.c: New file.
10485 * include/grub/pci.h: Likewise.
10487 * include/grub/i386/pc/pci.h: Likewise.
10489 * commands/lspci.c: Likewise.
10491 * conf/i386-pc.rmk (pkglib_MODULES): Add `pci.mod' and
10493 (pci_mod_SOURCES): New variable.
10494 (pci_mod_CFLAGS): Likewise.
10495 (pci_mod_LDFLAGS): Likewise.
10496 (lspci_mod_SOURCES): Likewise.
10497 (lspci_mod_CFLAGS): Likewise.
10498 (lspci_mod_LDFLAGS): Likewise.
10500 2008-02-02 Bean <bean123ch@gmail.com>
10502 * fs/ufs.c (INODE_BLKSZ): Fix incorrect value.
10503 (grub_ufs_get_file_block): Fix indirect block calculation problem.
10505 * fs/xfs.c (grub_xfs_sblock): New member log2_dirblk.
10506 (grub_xfs_btree_node): New structure.
10507 (grub_xfs_btree_root): New structure.
10508 (grub_xfs_inode): New members nblocks, extsize, nextents and btree.
10509 (GRUB_XFS_EXTENT_OFFSET): Use exts instead of inode->data.extents.
10510 (GRUB_XFS_EXTENT_BLOCK): Likewise.
10511 (GRUB_XFS_EXTENT_SIZE): Likewise.
10512 (grub_xfs_read_block): Support btree format type.
10513 (grub_xfs_iterate_dir): Use NESTED_FUNC_ATTR in call_hook.
10514 Use directory block as basic unit.
10516 * fs/fshelp.c (grub_fshelp_read_file): Bug fix for sparse block.
10518 * aclocal.m4 (grub_i386_CHECK_REGPARM_BUG): Define NESTED_FUNC_ATTR as
10519 __attribute__ ((__regparm__ (1))).
10521 2008-02-01 Robert Millan <rmh@aybabtu.com>
10523 Correct a mistake in previous commit.
10525 * conf/i386-pc.rmk (normal/execute.c_DEPENDENCIES): Move to the
10527 (normal/command.c_DEPENDENCIES): New variable.
10529 2008-02-01 Robert Millan <rmh@aybabtu.com>
10531 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Move to the
10533 (normal/command.c_DEPENDENCIES): New variable.
10534 (grub-emu_DEPENDENCIES, normal_mod_DEPENDENCIES): Remove variables.
10535 * conf/i386-ieee1275.rmk: Likewise.
10536 * conf/i386-linuxbios.rmk: Likewise.
10537 * conf/i386-pc.rmk: Likewise.
10538 * conf/sparc64-ieee1275.rmk: Likewise.
10539 * conf/powerpc-ieee1275.rmk: Likewise.
10540 (grub_emu_SOURCES): Add `fs/fshelp.c'.
10542 * genmk.rb: Add `$(#{src}_DEPENDENCIES)' in targets that require it.
10544 2008-02-01 Robert Millan <rmh@aybabtu.com>
10546 * kern/disk.c (grub_disk_read, grub_disk_write): Add grub_dprintf()
10547 call at beginning of function.
10549 2008-01-31 Pavel Roskin <proski@gnu.org>
10551 * util/powerpc/ieee1275/grub-mkrescue.in: New file.
10552 * conf/powerpc-ieee1275.rmk (bin_SCRIPTS): New variable.
10553 (grub_mkrescue_SOURCES): Likewise.
10554 * DISTLIST: Add util/powerpc/ieee1275/grub-mkrescue.in.
10556 2008-01-30 Robert Millan <rmh@aybabtu.com>
10558 * conf/i386-pc.rmk (sbin_UTILITIES): Remove `grub-probe'.
10559 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Moved from here ...
10560 * conf/common.rmk (util/grub-probe.c_DEPENDENCIES)
10561 (grub_probe_SOURCES): ... to here.
10563 * conf/i386-efi.rmk (sbin_UTILITIES): Remove `grub-probe'.
10564 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Remove.
10565 * conf/i386-ieee1275.rmk: Likewise.
10566 * conf/i386-linuxbios.rmk: Likewise.
10567 * conf/powerpc-ieee1275.rmk: Likewise.
10569 2008-01-30 Tristan Gingold <gingold@free.fr>
10571 * kern/rescue.c: Silently accept empty lines.
10573 2008-01-29 Bean <bean123ch@gmail.com>
10575 * boot/i386/pc/lnxboot.S (data_start): Code cleanup.
10576 (real_code_2): Code cleanup and change comment style.
10577 (move_memory): Avoid using 32-bit address mode.
10579 2008-01-29 Bean <bean123ch@gmail.com>
10581 * conf/i386-pc.rmk (pkglib_MODULES): Add `png.mod'.
10582 (png_mod_SOURCES): New variable.
10583 (png_mod_CFLAGS): Likewise.
10584 (png_mod_LDFLAGS): Likewise.
10586 * video/readers/png.c: New file.
10588 2008-01-28 Robert Millan <rmh@aybabtu.com>
10590 * include/grub/i386/linuxbios/kernel.h (GRUB_MOD_GAP): New macro.
10591 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Remove
10592 `ifndef GRUB_MOD_GAP' hack.
10593 * util/elf/grub-mkimage.c (add_segments): Likewise.
10595 2008-01-27 Robert Millan <rmh@aybabtu.com>
10597 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Skip
10598 `GRUB_MOD_GAP' for platforms in which it's not defined.
10599 * util/elf/grub-mkimage.c (add_segments): Likewise.
10601 2008-01-27 Robert Millan <rmh@aybabtu.com>
10603 Get grub-emu to build again (including parallel builds).
10605 * conf/i386-pc.rmk (util/grub-emu.c_DEPENDENCIES): Remove variable.
10607 (util/grub-emu.c_DEPENDENCIES): ... this, ...
10608 (normal/execute.c_DEPENDENCIES): ... this, ...
10609 (grub-emu_DEPENDENCIES): ... and this.
10611 * conf/i386-efi.rmk: Likewise.
10612 * conf/i386-linuxbios.rmk: Likewise.
10613 * conf/i386-ieee1275.rmk: Likewise.
10614 * conf/powerpc-ieee1275.rmk: Likewise.
10615 (grub_emu_SOURCES): Remove duplicated `kern/file.c'.
10617 2008-01-27 Robert Millan <rmh@aybabtu.com>
10619 * NEWS: Add a few items.
10621 2008-01-27 Robert Millan <rmh@aybabtu.com>
10623 Fix parallel builds with grub-emu. Based on earlier commit for
10624 grub-probe and grub-setup.
10626 * conf/i386-pc.rmk (grub-emu_DEPENDENCIES): Renamed to ...
10627 (util/grub-emu.c_DEPENDENCIES): ... this.
10628 * conf/i386-efi.rmk (grub-emu_DEPENDENCIES): Renamed to ...
10629 (util/grub-emu.c_DEPENDENCIES): ... this.
10630 * conf/i386-linuxbios.rmk (grub-emu_DEPENDENCIES): Renamed to ...
10631 (util/grub-emu.c_DEPENDENCIES): ... this.
10632 * conf/i386-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
10633 (util/grub-emu.c_DEPENDENCIES): ... this.
10634 * conf/powerpc-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
10635 (util/grub-emu.c_DEPENDENCIES): ... this.
10637 2008-01-27 Pavel Roskin <proski@gnu.org>
10639 * include/grub/powerpc/ieee1275/kernel.h: Introduce GRUB_MOD_GAP
10640 to create a gap between _end and the modules added to the image
10641 with grub-mkrescue. That fixes "CLAIM failed" on PowerMAC.
10642 * kern/powerpc/ieee1275/init.c: Use GRUB_MOD_GAP.
10643 * util/elf/grub-mkimage.c (add_segments): Likewise.
10645 2008-01-26 Pavel Roskin <proski@gnu.org>
10647 * kern/dl.c (grub_dl_load): Don't abort if prefix is not set,
10648 just return an error.
10650 2008-01-26 Bean <bean123ch@gmail.com>
10652 * fs/reiserfs.c (grub_fshelp_node): New member next_offset.
10653 (grub_reiserfs_get_item): Save offset of the next item.
10654 (grub_reiserfs_iterate_dir): Use next_offset to find next item.
10656 2008-01-25 Robert Millan <rmh@aybabtu.com>
10658 * conf/i386-pc.rmk (grub_setup_SOURCES, grub_emu_SOURCES): Regroup to
10659 make all filesystem sources appear together (possibly fixing omissions
10661 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
10662 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
10663 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
10664 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
10666 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise. Additionally,
10668 * conf/i386-efi.rmk (grub_probe_SOURCES): Likewise.
10669 * conf/i386-ieee1275.rmk (grub_probe_SOURCES): Likewise.
10670 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Likewise.
10671 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Likewise.
10673 * util/grub-probe.c: Include `<grub/file.h>' and `<sys/stat.h>'.
10674 (probe): Add a sanity check to make sure of our ability to read
10675 requested files when probing for filesystem type.
10677 * genmk.rb: Update copyright year (2007).
10679 * include/grub/fs.h (grub_fat_init, grub_fat_fini, grub_ext2_init)
10680 (grub_ext2_fini, grub_ufs_init, grub_ufs_fini, grub_minix_init)
10681 (grub_minix_fini, grub_hfs_init, grub_hfs_fini, grub_jfs_init)
10682 (grub_jfs_fini, grub_xfs_init, grub_xfs_fini, grub_affs_init)
10683 (grub_affs_fini, grub_sfs_init, grub_sfs_fini, grub_iso9660_init)
10684 : Remove function prototypes.
10686 2008-01-25 Robert Millan <rmh@aybabtu.com>
10688 Revert my previous commits (based on wrong assumption of how grub_errno
10691 * kern/disk.c (grub_disk_open): Stop resetting grub_errno.
10692 * kern/file.c (grub_file_open): Likewise.
10694 2008-01-24 Pavel Roskin <proski@gnu.org>
10696 * include/grub/ieee1275/ieee1275.h: Introduce flag for firmwares
10697 that hang if GRUB tries to setup colors.
10698 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Don't set
10699 colors for firmwares that don't support it.
10700 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag):
10701 Recognize Open Hack'Ware, set flags to work around its
10704 2008-01-24 Robert Millan <rmh@aybabtu.com>
10706 * kern/file.c (grub_file_open): Do not account previous failures of
10707 unrelated functions when grub_errno is checked for.
10708 Reported by Oleg Strikov.
10710 2008-01-24 Bean <bean123ch@gmail.com>
10712 * fs/ufs.c (GRUB_UFS_VOLNAME_LEN): New macro.
10713 (grub_ufs_sblock): New member volume name.
10714 (grub_ufs_find_file): Fix string copy bug.
10715 (grub_ufs_label): Implement this function properly.
10717 * fs/hfs.c (grub_hfs_cnid_type): New enum.
10718 (grub_hfs_iterate_records): Use the correct file number for extents
10719 and catalog file. Fix problem in next index calculation.
10720 (grub_hfs_find_node): Replace recursive function call with loop.
10721 (grub_hfs_iterate_dir): Replace recursive function call with loop.
10723 2008-01-23 Robert Millan <rmh@aybabtu.com>
10725 * include/grub/i386/ieee1275/loader.h: Include `<grub/types.h>',
10726 `<grub/symbol.h>' and `<grub/multiboot.h>'.
10727 (grub_multiboot2_real_boot): New function prototype.
10729 * include/grub/i386/pc/memory.h: Include `<grub/machine/machine.h>'.
10730 [!GRUB_MACHINE_IEEE1275] (grub_lower_mem, grub_upper_mem): Disable.
10732 * kern/i386/ieee1275/init.c (grub_os_area_addr)
10733 (grub_os_area_size, grub_lower_mem, grub_upper_mem): Remove variables.
10735 2008-01-23 Robert Millan <rmh@aybabtu.com>
10737 * kern/mm.c (grub_mm_init_region): Replace grub_dprintf() call with
10738 #ifdef'ed out grub_printf().
10740 2008-01-23 Robert Millan <rmh@aybabtu.com>
10742 * term/i386/pc/at_keyboard.c (grub_keyboard_isr): #ifdef out
10743 grub_dprintf calls, since they make "debug=all" mode unusable.
10744 (grub_console_checkkey): Likewise.
10746 2008-01-23 Robert Millan <rmh@aybabtu.com>
10748 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
10749 `term/i386/pc/at_keyboard.c'.
10750 (pkglib_MODULES): Add `serial.mod'.
10751 (serial_mod_SOURCES): New variable.
10752 (serial_mod_CFLAGS): Likewise.
10753 (serial_mod_LDFLAGS): Likewise.
10755 * include/grub/i386/ieee1275/console.h: Add `<grub/symbol.h>'. Remove
10756 `<grub/powerpc/ieee1275/console.h>'.
10757 (grub_keyboard_controller_init): New function prototype.
10758 (grub_console_checkkey): Likewise.
10759 (grub_console_getkey): Likewise.
10761 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize AT
10764 * term/ieee1275/ofconsole.c (grub_ofconsole_term): On i386, use
10765 grub_ofconsole_checkkey() and grub_ofconsole_getkey() for input.
10767 2008-01-23 Robert Millan <rmh@aybabtu.com>
10769 * kern/i386/pc/init.c (make_install_device): When memdisk image is
10770 present, "(memdisk)/boot/grub" becomes the default prefix.
10772 * util/i386/pc/grub-mkrescue.in: Switch to a minimal core.img plus
10773 a memdisk tarball with all the modules. Add --overlay=DIR option that
10774 allows users to overlay additional files into the image.
10776 2008-01-23 Robert Millan <rmh@aybabtu.com>
10778 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add `machine/loader.h'
10779 and `machine/memory.h'.
10780 (pkglib_MODULES): Add `multiboot.mod' and `_multiboot.mod'.
10781 (_multiboot_mod_SOURCES): New variable.
10782 (_multiboot_mod_CFLAGS): Likewise.
10783 (_multiboot_mod_LDFLAGS): Likewise.
10784 (multiboot_mod_SOURCES): Likewise.
10785 (multiboot_mod_CFLAGS): Likewise.
10786 (multiboot_mod_LDFLAGS): Likewise.
10788 * include/grub/i386/ieee1275/loader.h: New file.
10790 * include/grub/i386/ieee1275/machine.h: Likewise.
10792 * include/grub/i386/ieee1275/memory.h: Likewise.
10794 * include/grub/i386/pc/init.h (grub_os_area_addr): Remove (redundant)
10795 variable declaration.
10796 (grub_os_area_size): Likewise.
10798 * kern/i386/ieee1275/init.c (grub_os_area_addr, grub_os_area_size)
10799 (grub_lower_mem, grub_upper_mem): New variables.
10800 (grub_stop_floppy): New function (just to make
10801 grub_multiboot2_real_boot() happy).
10803 * kern/i386/ieee1275/startup.S: Include `<grub/machine/memory.h>',
10804 `<grub/cpu/linux.h>', `<multiboot.h>' and `<multiboot2.h>'.
10805 (grub_stop): New function.
10806 Include `"../realmode.S"' and `"../loader.S"'.
10808 * loader/multiboot_loader.c: Include `<grub/machine/machine.h>'.
10809 Replace `__i386__' #ifdefs with `GRUB_MACHINE_PCBIOS'.
10811 * loader/powerpc/ieee1275/multiboot2.c (grub_mb2_arch_boot): On i386,
10812 rely on grub_multiboot2_real_boot() for final boot.
10814 2008-01-22 Robert Millan <rmh@aybabtu.com>
10816 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): When
10817 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag is set, skip any
10818 device that doesn't look like an SD card.
10819 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
10820 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag.
10821 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag): Detect
10822 OLPC laptop, and set `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' when
10825 2008-01-22 Robert Millan <rmh@aybabtu.com>
10827 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Add sanity check to
10828 avoid claiming over our own code.
10830 2008-01-22 Bean <bean123ch@gmail.com>
10832 * conf/i386-pc.rmk (pkglib_MODULES): Add `jpeg.mod'.
10833 (jpeg_mod_SOURCES): New variable.
10834 (jpeg_mod_CFLAGS): Likewise.
10835 (jpeg_mod_LDFLAGS): Likewise.
10837 * video/readers/jpeg.c : New file.
10839 2008-01-22 Bean <bean123ch@gmail.com>
10841 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_FILE_NOT_FOUND when
10842 there are no more items.
10844 2008-01-21 Robert Millan <rmh@aybabtu.com>
10846 * kern/mm.c (grub_mm_init_region): Improve debug message.
10848 2008-01-21 Robert Millan <rmh@aybabtu.com>
10850 * conf/i386-pc.rmk (GRUB_MEMORY_MACHINE_LINK_ADDR): New variable.
10851 (kernel_img_LDFLAGS): Use `GRUB_MEMORY_MACHINE_LINK_ADDR' as link
10853 (grub_mkimage_CFLAGS): Propagate `GRUB_MEMORY_MACHINE_LINK_ADDR' as
10855 * include/grub/i386/pc/memory.h (GRUB_MEMORY_MACHINE_UPPER): New macro.
10856 Indicates start of upper memory.
10857 * util/i386/pc/grub-mkimage.c: Include `<grub/machine/memory.h>'.
10858 (generate_image): Abort when image size is big enough to corrupt
10861 * include/grub/i386/pc/vga.h: Include `<grub/machine/memory.h>'.
10862 (GRUB_MEMORY_MACHINE_VGA_ADDR): Alias for `GRUB_MEMORY_MACHINE_UPPER'.
10863 * term/i386/pc/vga.c (VGA_MEM): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
10864 instead of hardcoding 0xA0000.
10865 * video/i386/pc/vbe.c: Include `<grub/machine/vga.h>'.
10866 (grub_vbe_set_video_mode): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
10867 instead of hardcoding 0xA0000.
10869 2008-01-21 Robert Millan <rmh@aybabtu.com>
10871 * disk/memdisk.c (memdisk_size): New variable.
10872 (grub_memdisk_open): Replace grub_arch_memdisk_size() call with
10874 (grub_memdisk_init): Initialize `memdisk_size'. Reallocate memdisk
10875 image to dynamic memory.
10876 (grub_memdisk_fini): Replace grub_arch_memdisk_size() call with
10877 `memdisk_size'. Free memdisk block.
10879 2008-01-21 Robert Millan <rmh@aybabtu.com>
10881 Fix detection of very small filesystems (like tar).
10883 * fs/reiserfs.c (grub_reiserfs_mount): When disk is too small to
10884 contain a ReiserFS, abort with GRUB_ERR_BAD_FS rather than
10885 GRUB_ERR_OUT_OF_RANGE (which made the upper layer think there's
10886 a problem with this disk).
10888 2008-01-21 Robert Millan <rmh@aybabtu.com>
10890 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Add debug message
10891 on grub_biosdisk_rw_standard() error.
10893 2008-01-21 Robert Millan <rmh@aybabtu.com>
10895 * include/grub/ieee1275/ieee1275.h: Add 2008 to Copyright line for
10897 * kern/elf.c: Likewise.
10898 * kern/ieee1275/ieee1275.c: Likewise.
10899 * kern/powerpc/ieee1275/openfw.c: Likewise.
10900 * term/ieee1275/ofconsole.c: Likewise.
10902 2008-01-21 Robert Millan <rmh@aybabtu.com>
10904 * include/grub/i386/pc/kernel.h: Include `<grub/symbol.h>'.
10906 * include/grub/kernel.h (grub_arch_memdisk_addr)
10907 (grub_arch_memdisk_size): Moved from here ...
10909 * include/grub/i386/pc/kernel.h (grub_arch_memdisk_addr)
10910 (grub_arch_memdisk_size): ... to here.
10912 2008-01-21 Robert Millan <rmh@aybabtu.com>
10914 Mostly based on bugfix from Bean.
10916 * kern/elf.c (grub_elf32_phdr_iterate): Use `NESTED_FUNC_ATTR'
10917 attribute with hook() parameter.
10918 (grub_elf32_load): Use `NESTED_FUNC_ATTR' with grub_elf32_load_segment()
10920 (grub_elf64_phdr_iterate): Use `NESTED_FUNC_ATTR'
10921 attribute with hook() parameter.
10922 (grub_elf64_load): Use `NESTED_FUNC_ATTR' with grub_elf64_load_segment()
10925 2008-01-21 Robert Millan <rmh@aybabtu.com>
10927 * conf/i386-pc.rmk (kernel_img_HEADERS): Add `machine/kernel.h'.
10928 (pkglib_MODULES): Add `memdisk.mod'.
10929 (memdisk_mod_SOURCES): New variable.
10930 (memdisk_mod_CFLAGS): Likewise.
10931 (memdisk_mod_LDFLAGS): Likewise.
10933 * disk/memdisk.c: New file.
10935 * include/grub/disk.h (grub_disk_dev_id): Add
10936 `GRUB_DISK_DEVICE_MEMDISK_ID'.
10938 * include/grub/i386/pc/kernel.h
10939 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): New macro.
10940 (GRUB_KERNEL_MACHINE_PREFIX): Increment by 4.
10941 (grub_kernel_image_size): New variable declaration.
10942 (grub_total_module_size): Likewise.
10943 (grub_memdisk_image_size): Likewise.
10945 * include/grub/i386/pc/memory.h
10946 (GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR): New macro.
10948 * include/grub/kernel.h: Include `<grub/symbol.h>'.
10949 (grub_arch_memdisk_addr): New variable declaration.
10950 (grub_arch_memdisk_size): Likewise.
10952 * kern/i386/pc/init.c (grub_arch_memdisk_addr): New function.
10953 (grub_arch_memdisk_size): Likewise.
10955 * kern/i386/pc/startup.S (grub_memdisk_image_size): New variable.
10956 (codestart): Replace hardcoded `0x100000' with
10957 `GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR' macro.
10959 * util/i386/pc/grub-mkimage.c: Include `<grub/misc.h>'.
10960 (generate_image): Add `memdisk_path' parameter. When `memdisk_path' is
10961 not NULL, append the contents of the file it refers to, at the end of
10962 the compressed kernel image. Initialize `grub_memdisk_image_size'
10963 variable (at `GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE' offset).
10964 (options): Add "memdisk"|'m' option.
10965 (main): Parse --memdisk|-m option, and pass user-provided path as
10966 parameter to generate_image().
10968 2008-01-20 Robert Millan <rmh@aybabtu.com>
10970 * kern/sparc64/ieee1275/openfw.c (grub_devalias_iterate): Copy debug
10971 grub_dprintf() calls from here ...
10972 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): ... to here.
10974 2008-01-20 Robert Millan <rmh@aybabtu.com>
10976 Fix detection of "real mode" when /options/real-mode? doesn't exist.
10978 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_mmu): New variable
10980 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_mmu): New variable.
10981 (grub_ieee1275_find_options): If `grub_ieee1275_mmu' is 0, set
10982 `GRUB_IEEE1275_FLAG_REAL_MODE'.
10983 (cmain): Initialize `grub_ieee1275_mmu' (using /chosen/mmu integer
10985 * kern/powerpc/ieee1275/openfw.c (grub_map): Rely on pre-initialized
10986 `grub_ieee1275_mmu' rather than obtaining a handler on every call.
10988 2008-01-19 Robert Millan <rmh@aybabtu.com>
10990 Get rid of confusing function (superseded by
10991 `grub_ieee1275_get_integer_property')
10992 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_decode_int_4): Remove
10994 * kern/ieee1275/ieee1275.c (grub_ieee1275_decode_int_4): Remove
10996 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid use of
10997 grub_ieee1275_decode_int_4(), by obtaining integer properties directly
10998 in native endianness from grub_ieee1275_get_integer_property().
11000 2008-01-19 Robert Millan <rmh@aybabtu.com>
11002 * kern/powerpc/ieee1275/openfw.c (grub_halt): Issue "power-off"
11003 command after "shut-down", since implementations differ on which
11004 the command for halt is.
11006 2008-01-19 Robert Millan <rmh@aybabtu.com>
11008 * include/grub/i386/linuxbios/console.h: Add header protection.
11009 (grub_keyboard_controller_init): New function prototype.
11010 * term/i386/pc/at_keyboard.c (KEYBOARD_COMMAND_ISREADY): New macro.
11011 (KEYBOARD_COMMAND_READ): Likewise.
11012 (KEYBOARD_COMMAND_WRITE): Likewise.
11013 (KEYBOARD_SCANCODE_SET1): Likewise.
11014 (grub_keyboard_controller_write): New function.
11015 (grub_keyboard_controller_read): Likewise.
11016 (grub_keyboard_controller_init): Likewise.
11018 * term/i386/pc/console.c: Include `<grub/machine/machine.h>'.
11019 (grub_console_init): On coreboot/LinuxBIOS, call
11020 grub_keyboard_controller_init().
11022 2008-01-19 Robert Millan <rmh@aybabtu.com>
11024 PowerPC changes provided by Pavel Roskin.
11026 * kern/powerpc/ieee1275/cmain.c (cmain): Don't take any arguments.
11027 * kern/powerpc/ieee1275/crt0.S: Store r5 in grub_ieee1275_entry_fn,
11028 don't rely on cmain() doing it.
11029 * kern/i386/ieee1275/startup.S (_start): Store %eax in
11030 grub_ieee1275_entry_fn, don't rely on cmain() doing it.
11032 2008-01-16 Robert Millan <rmh@aybabtu.com>
11034 * include/grub/i386/linuxbios/memory.h
11035 (GRUB_MEMORY_MACHINE_LINUXBIOS_TABLE_ADDR): Remove macro.
11036 * kern/i386/linuxbios/table.c (grub_linuxbios_table_iterate): Do not
11037 receive `table_header' as argument. Instead, probe for it in the
11038 known memory ranges where it can be present.
11039 (grub_available_iterate): Do not pass a fixed `table_header' address
11040 to grub_linuxbios_table_iterate().
11042 2008-01-15 Robert Millan <rmh@aybabtu.com>
11044 * configure.ac: Add `i386-ieee1275' to the list of supported targets.
11045 * conf/i386-ieee1275.rmk: New file.
11046 * include/grub/i386/ieee1275/console.h: Likewise.
11047 * include/grub/i386/ieee1275/ieee1275.h: Likewise.
11048 * include/grub/i386/ieee1275/kernel.h: Likewise.
11049 * include/grub/i386/ieee1275/time.h: Likewise.
11050 * kern/i386/ieee1275/init.c: Likewise.
11051 * kern/i386/ieee1275/startup.S: Likewise.
11053 2008-01-15 Robert Millan <rmh@aybabtu.com>
11055 * kern/misc.c (grub_vsprintf): Do not reset `longlongfmt' to zero
11056 when pointers are 32-bit (but still do set it to one when they are
11059 2008-01-15 Robert Millan <rmh@aybabtu.com>
11061 * include/grub/ieee1275/ieee1275.h
11062 (grub_ieee1275_get_integer_property): New function prototype.
11064 * kern/ieee1275/ieee1275.c: Include `<grub/types.h>'.
11065 (grub_ieee1275_get_integer_property): New function. Wraps around
11066 grub_ieee1275_get_property() to handle endianness.
11068 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Replace
11069 grub_ieee1275_get_property() with grub_ieee1275_get_integer_property()
11071 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Likewise.
11072 (grub_map): Likewise.
11073 * kern/sparc64/ieee1275/openfw.c (grub_map): Likewise.
11075 2008-01-15 Bean <bean123ch@gmail.com>
11077 * normal/execute.c (grub_script_exec_argument_to_string): Check for undefined variable.
11078 (grub_script_execute_cmdline): Reset grub_errno.
11080 * normal/main.c (read_config_file): Reset grub_errno.
11082 * normal/parse.y (script_init): New.
11083 (script): Move function and menuentry here.
11085 (command): Add delimiter at the end of command.
11086 (commands): Adjust to match the new command.
11087 (commandblock): Remove grub_script_lexer_record_start.
11088 (menuentry): Add grub_script_lexer_record_start, use the new commands.
11089 (if): Use the new commands.
11091 * conf/common.rmk (pkgdata_MODULES): Add echo.mod.
11093 2008-01-15 Robert Millan <rmh@aybabtu.com>
11095 * normal/menu.c (run_menu): Move timeout message from here ...
11096 (print_timeout): ... to here.
11097 (run_menu): Use print_timeout() once during initial draw to print
11098 the whole message, and again in every clock tick to update only
11099 the number of seconds.
11101 2008-01-15 Robert Millan <rmh@aybabtu.com>
11103 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Obtain
11104 actual size of `available' from grub_ieee1275_get_property(), and
11105 restrict parsing to that bound.
11107 2008-01-15 Christian Franke <franke@computer.org>
11109 * util/grub-emu.c: Replace <argp.h> by <getopt.h>.
11110 (argp_program_version): Remove variable.
11111 (argp_program_bug_address): Likewise.
11112 (options): Convert from struct argp_option to struct option.
11113 (struct arguments): Remove.
11114 (parse_opt): Remove.
11115 (usage): New function.
11116 (main): Replace struct args members by simple variables.
11117 Replace argp_parse() by getopt_long().
11118 Add switch to evaluate options.
11119 Add missing "(...)" around root_dev in prefix string.
11121 2008-01-14 Robert Millan <rmh@aybabtu.com>
11123 * kern/powerpc/ieee1275/init.c (grub_exit): Reimplement as a wrapper
11124 for grub_ieee1275_exit(), in order to improve portability.
11126 2008-01-14 Robert Millan <rmh@aybabtu.com>
11128 * util/grub.d/10_linux.in (prefix): Define.
11129 (exec_prefix): Likewise. Both definitions are later used by `libdir'.
11131 2008-01-13 Pavel Roskin <proski@gnu.org>
11133 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Don't use
11134 grub_errno if no errors have been detected.
11136 2008-01-12 Robert Millan <rmh@aybabtu.com>
11138 * include/grub/util/getroot.h (grub_dev_abstraction_types): New enum.
11139 (grub_util_get_dev_abstraction): New function prototype.
11141 * util/getroot.c: Include `<grub/util/getroot.h>'
11142 (grub_util_get_grub_dev): Move detection of abstraction type to ...
11143 (grub_util_get_dev_abstraction): ... here (new function).
11145 * util/grub-probe.c: Convert PRINT_* to an enum. Add
11146 `PRINT_ABSTRACTION'.
11147 (probe): Probe for abstraction type when requested.
11148 (main): Understand `--target=abstraction'.
11150 * util/i386/efi/grub-install.in: Add abstraction module to core
11151 image when it is found to be necessary.
11152 * util/i386/pc/grub-install.in: Likewise.
11153 * util/powerpc/ieee1275/grub-install.in: Likewise.
11155 * util/update-grub_lib.in (font_path): Return system path without
11156 converting to GRUB path.
11157 * util/update-grub.in: Convert system path returned by font_path()
11158 to a GRUB path. Use `grub-probe -t abstraction' to determine what
11159 abstraction module is needed for loading fonts (if any). Export
11160 that as `GRUB_PRELOAD_MODULES'.
11161 * util/grub.d/00_header.in: Process `GRUB_PRELOAD_MODULES' (print
11164 2008-01-12 Yoshinori K. Okuji <okuji@enbug.org>
11166 Remove some unused code from reiserfs.
11168 * fs/reiserfs.c (struct grub_reiserfs_key)
11169 [GRUB_REISERFS_KEYV2_BITFIELD]: Removed offset and type.
11170 (struct grub_reiserfs_node_body): Removed.
11171 (grub_reiserfs_get_key_v2_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
11173 (grub_reiserfs_get_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
11175 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
11177 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
11179 (grub_reiserfs_set_key_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
11181 (grub_reiserfs_iterate_dir) [GRUB_REISERFS_KEYV2_BITFIELD]:
11183 (grub_reiserfs_open) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
11184 (grub_reiserfs_read) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
11185 (grub_reiserfs_dir) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
11187 2008-01-10 Robert Millan <rmh@aybabtu.com>
11189 * util/update-grub_lib.in (grub_file_is_not_garbage): New function.
11190 Determines if a file is garbage left by packaging systems, etc.
11191 * util/update-grub.in: Use grub_file_is_not_garbage() as a condition
11192 for processing /etc/grub.d scripts.
11193 * util/grub.d/10_hurd.in: Fix `GRUB_DISTRIBUTOR' comparison.
11194 * util/grub.d/10_linux.in: Likewise. Use grub_file_is_not_garbage()
11195 as a condition for processing Linux images.
11197 2008-01-10 Pavel Roskin <proski@gnu.org>
11199 * include/grub/powerpc/libgcc.h (__ucmpdi2): New export. Needed
11200 to compile reiserfs.c on PowerPC.
11202 2008-01-10 Robert Millan <rmh@aybabtu.com>
11204 * kern/device.c (grub_device_iterate): Do not abort device iteration
11205 when one of the devices cannot be opened.
11206 * kern/disk.c (grub_disk_open): Do not account previous failures of
11207 unrelated functions when grub_errno is checked for.
11209 2008-01-08 Robert Millan <rmh@aybabtu.com>
11211 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): For
11212 `! grub_linux_is_bzimage', change order of address comparison to make
11213 it more intuitive, and improve "too big zImage" error message.
11215 2008-01-08 Robert Millan <rmh@aybabtu.com>
11217 * Makefile.in (uninstall): Handle `$(update-grub_SCRIPTS)' and
11218 `$(update-grub_DATA)'.
11219 (distcheck): Fix race condition when invoking `$(MAKE)' on multiple
11222 2008-01-07 Robert Millan <rmh@aybabtu.com>
11224 * boot/i386/pc/boot.S (boot_drive_check): Add a comment indicating
11225 which instruction is modified by grub-setup during installation
11226 (since it wasn't obvious by only looking at this file).
11228 2008-01-07 Robert Millan <rmh@aybabtu.com>
11230 * TODO: Rewrite. Just refer to the wiki and the BTS instead of
11231 listing actual TODO items.
11233 2008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
11235 * fs/reiserfs.c (grub_reiserfs_get_key_v2_type): Handle endianness
11237 (grub_reiserfs_get_key_offset): Likewise.
11238 (grub_reiserfs_set_key_offset): Likewise.
11239 (grub_reiserfs_set_key_type): Likewise.
11240 (grub_reiserfs_iterate_dir): Return 1 if found, otherwise 0.
11242 (GRUB_REISERFS_KEYV2_BITFIELD): Undefined. Probably it would be
11243 better to remove the bitfield version completely.
11245 2008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
11247 * fs/reiserfs.c (grub_reiserfs_iterate_dir): ENTRY_ITEM must be
11248 allocated from the heap, due to the fshelp implementation.
11249 (grub_reiserfs_dir): Free NODE, due to the same reason.
11251 2008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
11253 Mostly from Vincent Pelletier:
11255 * fs/reiserfs.c: New file.
11257 * conf/common.rmk (pkglib_MODULES): Added reiserfs.mod.
11258 (reiserfs_mod_SOURCES): New variable.
11259 (reiserfs_mod_CFLAGS): Likewise.
11260 (reiserfs_mod_LDFLAGS): Likewise.
11262 * DISTLIST: Added boot/i386/pc/lnxboot.S, commands/hexdump.c,
11263 disk/ata.c, fs/cpio.c, fs/ntfscomp.c, fs/reiserfs.c,
11264 include/grub/ntfs.h, include/grub/i386/pc/machine.h, and
11267 2008-01-06 Robert Millan <rmh@aybabtu.com>
11269 * normal/color.c: Remove `<grub/env.h>'.
11271 2008-01-05 Jeroen Dekkers <jeroen@dekkers.cx>
11273 * include/grub/normal.h: Include <grub/env.h>.
11275 2008-01-05 Robert Millan <rmh@aybabtu.com>
11277 * util/i386/pc/grub-setup.c (usage): Replace obsolete `(hd0,0)' in
11278 usage example with `(hd0,1)'.
11279 Reported by Samuel Thibault.
11281 2008-01-05 Robert Millan <rmh@aybabtu.com>
11283 * kern/i386/loader.S (grub_linux_is_bzimage): New variable.
11284 (grub_linux_boot_zimage): Rename to ...
11285 (grub_linux_boot): ... this.
11286 (grub_linux_boot_bzimage): Merge with `grub_linux_boot_zimage'.
11287 (grub_linux_boot_zimage): Conditionalize zImage copy.
11289 * include/grub/i386/loader.h (grub_linux_is_bzimage): Add prototype.
11290 (grub_linux_boot_bzimage): Remove prototype.
11291 (grub_linux_boot_zimage): Rename to ...
11292 (grub_linux_boot): ... this.
11294 * loader/i386/pc/linux.c (big_linux): Replace with `grub_linux_is_bzimage'.
11295 (grub_linux_boot): Remove function.
11297 2008-01-05 Robert Millan <rmh@aybabtu.com>
11299 * include/grub/normal.h (grub_env_write_color_normal): New prototype.
11300 (grub_env_write_color_highlight): Likewise.
11301 (grub_wait_after_message): Likewise.
11303 * normal/color.c: New file.
11305 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/color.c'.
11306 (normal_mod_DEPENDENCIES): Likewise.
11308 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `normal/color.c'.
11309 (normal_mod_DEPENDENCIES): Likewise.
11311 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add `normal/color.c'.
11312 (normal_mod_DEPENDENCIES): Likewise.
11314 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `normal/color.c'.
11315 (normal_mod_DEPENDENCIES): Likewise.
11317 * normal/menu_entry.c (run): Rely on grub_wait_after_message()
11318 for waiting after a message is printed.
11319 * normal/main.c (read_config_file): Likewise.
11320 (grub_normal_init): Register grub_env_write_color_normal() and
11321 grub_env_write_color_highlight() hooks. Mark `color_normal' and
11322 `color_highlight' variables as global.
11324 * normal/menu.c (grub_wait_after_message): New function.
11325 (grub_color_menu_normal): New variable. Replaces ...
11326 (GRUB_COLOR_MENU_NORMAL): ... this macro.
11327 (grub_color_menu_highlight): New variable. Replaces ...
11328 (GRUB_COLOR_MENU_HIGHLIGHT): ... this macro.
11329 (draw_border): Set color state to `GRUB_TERM_COLOR_NORMAL' instead of
11330 `GRUB_TERM_COLOR_STANDARD'.
11331 (print_message): Use `grub_setcolorstate' to reload colors. Rename
11332 `normal_code' and `highlight_code' to `old_color_normal' and
11333 `old_color_highlight', respectively.
11334 (grub_menu_init_page): Update colors when drawing the menu, based on
11335 `menu_color_normal' and `menu_color_highlight' variables.
11336 (grub_menu_run): Rely on grub_wait_after_message() for waiting after
11337 a message is printed.
11339 2008-01-05 Robert Millan <rmh@aybabtu.com>
11341 * kern/env.c (grub_env_context_open): Propagate hooks for global
11342 variables to new context.
11344 * kern/main.c (grub_set_root_dev): Export `root' variable.
11346 2008-01-05 Robert Millan <rmh@aybabtu.com>
11348 * util/biosdisk.c (get_os_disk): Check for devfs-style IDE and SCSI
11349 discs unconditionally, since udev and others have options to provide
11352 2008-01-05 Robert Millan <rmh@aybabtu.com>
11354 * normal/completion.c (iterate_dir): Skip `.' and `..' directories.
11356 2008-01-04 Christian Franke <franke@computer.org>
11358 * kern/i386/pc/init.c (grub_machine_init): Fix evaluation
11361 2008-01-03 Pavel Roskin <proski@gnu.org>
11363 * kern/i386/linuxbios/init.c: Put "void" to all function
11364 declarations with no arguments.
11365 * kern/powerpc/ieee1275/init.c: Likewise.
11366 * term/i386/pc/at_keyboard.c: Likewise.
11367 * term/i386/pc/vga_text.c: Likewise.
11368 * util/grub-mkdevicemap.c: Likewise.
11370 2008-01-02 Robert Millan <rmh@aybabtu.com>
11372 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Improve error
11373 message when loaded image is out of bounds.
11374 (grub_multiboot_load_elf64): Likewise.
11376 2008-01-02 Pavel Roskin <proski@gnu.org>
11378 * util/grub.d/10_linux.in: Try version without ".old" when
11379 looking for initrd. It's better to use initrd from the newer
11380 kernel of the same version than no initrd at all.
11382 2008-01-01 Robert Millan <rmh@aybabtu.com>
11384 * util/biosdisk.c (get_os_disk): Fix check for IDE or SCSI discs.
11386 2008-01-01 Vesa Jaaskelainen <chaac@nic.fi>
11388 * include/grub/video.h: Added grub_video_unmap_color and
11389 grub_video_get_active_render_target.
11390 (grub_video_adapter): Added unmap_color and get_active_render_target.
11392 * video/video.c: Added grub_video_unmap_color and
11393 grub_video_get_active_render_target.
11394 (grub_video_get_info): Changed method to accept NULL pointer as an
11395 argument to allow detection of active video adapter.
11397 * video/i386/pc/vbe.c: Renamed grub_video_vbe_unmap_color as
11398 grub_video_vbe_unmap_color_int.
11399 Added grub_video_vbe_unmap_color and
11400 grub_video_vbe_get_active_render_target.
11401 (grub_video_vbe_adapter): Added unmap_color and
11402 get_active_render_target.
11404 * video/i386/pc/vbeblit.c: Replaced grub_video_vbe_unmap_color usage
11405 with grub_video_vbe_unmap_color_int.
11407 * term/gfxterm.c (DEFAULT_STANDARD_COLOR): Added.
11408 (DEFAULT_NORMAL_COLOR): Likewise.
11409 (DEFAULT_HIGHLIGHT_COLOR) Likewise.
11410 (DEFAULT_FG_COLOR): Removed.
11411 (DEFAULT_BG_COLOR): Likewise.
11412 (DEFAULT_CURSOR_COLOR): Changed value.
11413 (grub_virtual_screen): Added standard_color_setting,
11414 normal_color_setting, highlight_color_setting and term_color.
11415 (grub_virtual_screen): Removed fg_color_setting and bg_color_setting.
11416 (bitmap_width): Added.
11417 (bitmap_height): Likewise.
11418 (bitmap): Likewise.
11419 (set_term_color): Likewise.
11420 (grub_virtual_screen_setup): Changed to use new terminal coloring
11422 (grub_gfxterm_init): Added init for bitmap.
11423 (grub_gfxterm_fini): Added destroy for bitmap.
11424 (redraw_screen_rect): Updated to use background bitmap and new
11426 (scroll_up): Added optimization for case when there is no bitmap.
11427 (grub_gfxterm_cls): Fixed to use correct background color.
11428 (grub_virtual_screen_setcolorstate): Changed to use new terminal
11430 (grub_virtual_screen_setcolor): Likewise.
11431 (grub_virtual_screen_getcolor): Added.
11432 (grub_gfxterm_background_image_cmd): Likewise.
11433 (grub_video_term): Added setcolor and getcolor.
11434 (MOD_INIT): Added registration of background_image command.
11435 (MOD_TERM): Added unregistration for background_image command.
11437 2007-12-30 Pavel Roskin <proski@gnu.org>
11439 * loader/multiboot_loader.c: Fix multiboot command
11440 unregistration. Fix all typos in the word "multiboot".
11442 2007-12-29 Pavel Roskin <proski@gnu.org>
11444 * util/grub.d/10_linux.in: Refactor search for initrd. Add
11445 support for initrd names used in Fedora.
11447 2007-12-26 Bean <bean123ch@gmail.com>
11449 * conf/common.rmk (pkgdata_MODULES): Add cpio.mod.
11450 (cpio_mod_SOURCES): New variable.
11451 (cpio_mod_CFLAGS): Likewise.
11452 (cpio_mod_LDFLAGS): Likewise.
11454 * fs/cpio.c: New file.
11456 * conf/i386-pc.rmk (grub_emu_SOURCES): Add cpio.c.
11458 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
11460 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
11462 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11464 2007-12-25 Robert Millan <rmh@aybabtu.com>
11466 * include/grub/term.h (struct grub_term): Add `getcolor' function.
11467 (grub_getcolor): New function.
11469 * kern/term.c (grub_getcolor): New function.
11470 * normal/menu.c (GRUB_COLOR_MENU_NORMAL): New macro.
11471 (GRUB_COLOR_MENU_HIGHLIGHT): New macro.
11472 (print_entry): Set normal and highlight colors to
11473 `GRUB_COLOR_MENU_NORMAL' and `GRUB_COLOR_MENU_HIGHLIGHT',
11474 respectively, before printing and restore them to old
11476 (grub_menu_init_page): Likewise. Fill an additional colored space
11477 that would otherwise be left blank.
11479 * term/efi/console.c (grub_console_getcolor): New function.
11480 (struct grub_console_term.getcolor): New variable.
11481 * term/i386/pc/console.c (grub_console_getcolor): New function.
11482 (struct grub_console_term.getcolor): New variable.
11483 * term/ieee1275/ofconsole.c (grub_ofconsole_getcolor): New function.
11484 (struct grub_console_term.getcolor): New variable.
11486 * term/i386/pc/serial.c (grub_serial_setcolor): Remove function.
11487 (struct grub_console_term.setcolor): Remove variable.
11488 * term/i386/pc/vesafb.c (grub_virtual_screen_setcolor): Remove function.
11489 (struct grub_console_term.setcolor): Remove variable.
11490 * term/i386/pc/vga.c (grub_vga_setcolor): Remove function.
11491 (struct grub_console_term.setcolor): Remove variable.
11492 * term/gfxterm.c (grub_virtual_screen_setcolor): Remove function.
11493 (struct grub_console_term.setcolor): Remove variable.
11495 2007-12-25 Robert Millan <rmh@aybabtu.com>
11497 * configure.ac: Search for possible unifont.hex locations, and
11498 define UNIFONT_HEX if found.
11500 * Makefile.in (UNIFONT_HEX): Define variable.
11501 (DATA): Rename to ...
11502 (PKGLIB): ... this. Update all users.
11503 (PKGDATA): New variable.
11504 (pkgdata_IMAGES): Rename to ...
11505 (pkglib_IMAGES): ... this. Update all users.
11506 (pkgdata_MODULES): Rename to ...
11507 (pkglib_MODULES): ... this. Update all users.
11508 (pkgdata_PROGRAMS): Rename to ...
11509 (pkglib_PROGRAMS): ... this. Update all users.
11510 (pkgdata_DATA): Rename to ...
11511 (pkglib_DATA): ... this. Update all users.
11512 (CLEANFILES): Redefine to `$(pkglib_DATA) $(pkgdata_DATA)'.
11513 (unicode.pff, ascii.pff): New rules.
11514 (all-local): Add `$(PKGDATA)' dependency.
11515 (install-local): Process `$(PKGDATA)'.
11517 * util/update-grub_lib.in (font_path): Search for *.pff files in
11518 a few more locations, including `${pkgdata}'.
11520 2007-12-23 Robert Millan <rmh@aybabtu.com>
11522 Patch from Bean <bean123ch@gmail.com>:
11523 * disk/loopback.c (grub_loopback_read): Add missing bit shift to
11526 2007-12-21 Bean <bean123ch@gmail.com>
11528 * conf/common.rmk (pkgdata_MODULES): Add ntfscomp.mod.
11529 (ntfscomp_mod_SOURCES): New variable.
11530 (ntfscomp_mod_CFLAGS): Likewise.
11531 (ntfscomp_mod_LDFLAGS): Likewise.
11533 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfscomp.c.
11534 (grub_probe_SOURCES): Likewise.
11535 (grub_emu_SOURCES): Likewise.
11537 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
11538 (grub_emu_SOURCES): Likewise.
11540 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
11541 (grub_emu_SOURCES): Likewise.
11543 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
11544 (grub_emu_SOURCES): Likewise.
11546 * fs/ntfs.c (grub_ntfscomp_func): New variable.
11547 (read_run_list): Renamed to grub_ntfs_read_run_list.
11548 (decomp_nextvcn): Moved to ntfscomp.c.
11549 (decomp_getch): Likewise.
11550 (decomp_get16): Likewise.
11551 (decomp_block): Likewise.
11552 (read_block): Likewise.
11553 (read_data): Partially moved to ntfscomp.c.
11554 (fixup): Change unsigned to grub_uint16_t.
11555 (read_mft): Change unsigned long to grub_uint32_t.
11556 (read_attr): Likewise.
11557 (read_data): Likewise.
11558 (read_run_data): Likewise.
11559 (read_run_list): Likewise.
11560 (read_mft): Likewise.
11562 * fs/ntfscomp.c: New file.
11564 * include/grub/ntfs.h: New file.
11566 2007-12-16 Robert Millan <rmh@aybabtu.com>
11568 * util/grub-mkdevicemap.c (make_device_map): Iterate up to 20 for
11569 IDE disk check, since Linux is known to support 20 IDE disks.
11570 Reported by Colin Watson.
11572 2007-12-15 Bean <bean123ch@gmail.com>
11574 * conf/i386-pc.rmk (pkgdata_IMAGES): Add lnxboot.img.
11575 (lnxboot_img_SOURCES): New variable.
11576 (lnxboot_img_ASFLAGS): Likewise.
11577 (lnxboot_img_LDFLAGS): Likewise.
11579 * boot/i386/pc/lnxboot.S: New file.
11581 2007-11-24 Pavel Roskin <proski@gnu.org>
11583 * configure.ac: Test if '--build-id=none' is supported by the
11584 linker. If yes, add it to TARGET_LDFLAGS. Build ID causes
11585 objcopy to generate incorrect binary files (binutils
11586 2.17.50.0.18-1 as shipped by Fedora 8).
11587 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Use LDFLAGS when
11588 linking, so that build ID doesn't break the test.
11590 2007-11-24 Pavel Roskin <proski@gnu.org>
11592 * include/grub/i386/time.h: use "void" in the argument list
11593 of grub_cpu_idle().
11594 * include/grub/powerpc/time.h: Likewise.
11595 * include/grub/sparc64/time.h: Likewise.
11597 2007-11-18 Christian Franke <franke@computer.org>
11599 * util/console.c (grub_ncurses_getkey): Change curses KEY_* mapping,
11600 now return control chars instead of GRUB_CONSOLE_KEY_* constants.
11601 This fixes the problem that function keys did not work in grub-emu.
11603 2007-11-18 Christian Franke <franke@computer.org>
11605 * disk/host.c (grub_host_open): Remove attribute unused from
11606 name parameter. Add check for "host". This fixes the problem
11607 that grub-emu does not find partitions.
11609 2007-11-18 Christian Franke <franke@computer.org>
11611 * util/hostfs.c (is_dir): New function.
11612 (grub_hostfs_dir): Handle missing dirent.d_type case.
11613 (grub_hostfs_read): Add missing fseek().
11614 (grub_hostfs_label): Clear label pointer. This fixes a crash
11615 of grub-emu on "ls (host)".
11617 2007-11-18 Christian Franke <franke@computer.org>
11619 * include/grub/i386/pc/init.h (struct grub_machine_mmap_entry):
11620 Add attribute packed, gcc 3.4.4 on Cygwin aligns this
11621 to 64 bit boundary by default.
11623 2007-11-18 Bean <bean123ch@gmail.com>
11625 * conf/common.rmk (pkgdata_MODULES): Add hexdump.mod.
11626 (hexdump_mod_SOURCES): New variable.
11627 (hexdump_mod_CFLAGS): Likewise.
11628 (hexdump_mod_LDFLAGS): Likewise.
11630 * conf/i386-pc.rmk (grub_emu_SOURCES): Add command/hexdump.c.
11632 * conf/i386-efi.rmk (grub_emu_SOURCES): Add command/hexdump.c.
11634 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add command/hexdump.c.
11636 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add command/hexdump.c.
11638 * include/grub/hexdump.h: New file.
11640 * commands/hexdump.c: New file.
11642 2007-11-10 Robert Millan <rmh@aybabtu.com>
11644 * commands/i386/pc/play.c (beep_off): Switch order of arguments
11645 in grub_outb() calls.
11646 (beep_on): Likewise.
11648 2007-11-10 Christian Franke <franke@computer.org>
11650 * normal/menu.c (run_menu): Check for empty menu to avoid crash.
11651 (grub_menu_run): Likewise.
11653 2007-11-10 Robert Millan <rmh@aybabtu.com>
11655 * include/grub/i386/efi/machine.h: New file.
11656 * include/grub/i386/linuxbios/machine.h: Likewise.
11657 * include/grub/i386/pc/machine.h: Likewise.
11658 * include/grub/powerpc/ieee1275/machine.h: Likewise.
11659 * include/grub/sparc64/ieee1275/machine.h: Likewise.
11661 * term/i386/pc/serial.c: Include <grub/machine/machine.h>.
11662 (serial_hw_io_addr): New variable.
11663 (serial_hw_get_port): Obtain port address from `serial_hw_io_addr'
11664 instead of `(unsigned short *) 0x400'.
11666 2007-11-10 Bean <bean123ch@gmail.com>
11668 * fs/ntfs.c (read_block): Fix a bug caused by adjacent blocks.
11670 2007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
11672 * conf/i386-pc.rmk (pkgdata_MODULES): Added vga.mod.
11673 (vga_mod_SOURCES): Added.
11674 (vga_mod_CFLAGS): Likewise.
11675 (vga_mod_LDFLAGS): Likewise.
11677 * term/i386/pc/vga.c (get_map_mask): Switch order of arguments in
11679 (set_map_mask): Likewise.
11680 (set_read_map): Likewise.
11681 (set_read_address): Likewise.
11682 (vga_font): Removed variable.
11683 (get_vga_glyph): Removed function.
11684 (invalidate_char): Likewise.
11685 (write_char): Changed to use grub_font_get_glyph() for font
11687 (grub_vga_putchar): Likewise.
11688 (grub_vga_getcharwidth): Likewise.
11690 2007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
11692 * conf/i386-pc.rmk (boot_img_LDFLAGS): Use COMMON_LDFLAGS for target
11694 (pxeboot_img_LDFLAGS): Likewise.
11695 (diskboot_img_LDFLAGS): Likewise.
11696 (kernel_img_LDFLAGS): Likewise.
11698 2007-11-06 Robert Millan <rmh@aybabtu.com>
11700 * term/i386/pc/serial.c (serial_hw_put): Switch order of arguments
11701 in grub_outb() calls.
11702 (serial_hw_init): Likewise.
11704 2007-11-05 Robert Millan <rmh@aybabtu.com>
11706 * util/update-grub.in: Allow files in ${update_grub_dir} to contain
11707 spaces. Skip non-regular files.
11709 2007-11-05 Robert Millan <rmh@aybabtu.com>
11711 * kern/disk.c (grub_disk_firmware_fini)
11712 (grub_disk_firmware_is_tainted): New variables.
11714 * include/grub/disk.h (grub_disk_firmware_fini)
11715 (grub_disk_firmware_is_tainted): Likewise.
11717 * disk/i386/pc/biosdisk.c (GRUB_MOD_FINI(biosdisk)): Moved from here ...
11718 (grub_disk_biosdisk_fini): ... to here.
11719 (GRUB_MOD_FINI(biosdisk)): Implement using grub_disk_biosdisk_fini().
11720 (GRUB_MOD_INIT(biosdisk)): Abort when `grub_disk_firmware_is_tainted'
11721 is set. Register grub_disk_biosdisk_fini() in
11722 `grub_disk_firmware_fini'.
11724 * disk/ata.c: Remove `<grub/machine/biosdisk.h>'.
11725 (GRUB_MOD_INIT(ata)): Remove grub_biosdisk_fini() call.
11726 Use `grub_disk_firmware_is_tainted' and `grub_disk_firmware_fini'
11727 to finish existing firmware disk interface.
11729 * conf/i386-linuxbios.rmk (pkgdata_MODULES): Add `ata.mod'.
11730 (ata_mod_SOURCES): New variable.
11731 (ata_mod_CFLAGS): Likewise.
11732 (ata_mod_LDFLAGS): Likewise.
11734 2007-11-05 Robert Millan <rmh@aybabtu.com>
11736 * disk/ata.c: Remove `<grub/machine/time.h>'. Include `<grub/time.h>'.
11737 (grub_ata_wait): Reimplement using grub_millisleep().
11739 * include/grub/misc.h (grub_div_roundup): Fix parenthesization.
11740 * include/grub/i386/time.h (grub_cpu_idle): Disable `hlt' instruction.
11742 2007-11-03 Marco Gerards <marco@gnu.org>
11744 * term/i386/pc/vga_text.c: Include <grub/cpu/io.h>.
11745 (CRTC_ADDR_PORT): New macro.
11746 (CRTC_DATA_PORT): Likewise.
11747 (CRTC_CURSOR): Likewise.
11748 (CRTC_CURSOR_ADDR_HIGH): Likewise.
11749 (CRTC_CURSOR_ADDR_LOW): Likewise.
11750 (update_cursor): New function.
11751 (grub_console_real_putchar): Call `update_cursor'.
11752 (grub_console_gotoxy): Likewise.
11753 (grub_console_cls): Set the default color when clearing the
11755 (grub_console_setcursor): Implemented.
11757 2007-11-03 Marco Gerards <marco@gnu.org>
11759 * disk/ata.c (grub_ata_pio_read): Don't wait for the command to
11761 (grub_ata_pio_write): Likewise.
11763 (grub_atapi_identify): Wait after issuing an ATA command.
11764 (grub_atapi_packet): Likewise.
11765 (grub_ata_identify): Likewise.
11766 (grub_ata_readwrite): Likewise.
11768 2007-11-03 Marco Gerards <marco@gnu.org>
11770 * disk/ata.c (grub_ata_pio_read): Detect and return the error code.
11771 (grub_ata_pio_write): Likewise.
11772 (grub_ata_readwrite): Use `grub_error', instead of
11773 returning `grub_errno'.
11775 2007-11-03 Marco Gerards <marco@gnu.org>
11777 * disk/ata.c (grub_ata_readwrite): Call grub_ata_pio_read and
11778 grub_ata_pio_write once for every single sector, instead of for
11781 2007-10-31 Robert Millan <rmh@aybabtu.com>
11783 * configure.ac: Add `i386-linuxbios' to the list of supported targets.
11785 * conf/i386-linuxbios.rmk: New file.
11787 * kern/i386/pc/hardware.c: Likewise.
11788 * term/i386/pc/at_keyboard.c: Likewise.
11789 * term/i386/pc/vga_text.c: Likewise.
11791 * include/grub/i386/linuxbios/boot.h: Likewise.
11792 * include/grub/i386/linuxbios/console.h: Likewise.
11793 * include/grub/i386/linuxbios/init.h: Likewise.
11794 * include/grub/i386/linuxbios/kernel.h: Likewise.
11795 * include/grub/i386/linuxbios/loader.h: Likewise.
11796 * include/grub/i386/linuxbios/memory.h: Likewise.
11797 * include/grub/i386/linuxbios/serial.h: Likewise.
11798 * include/grub/i386/linuxbios/time.h: Likewise.
11800 * kern/i386/linuxbios/init.c: Likewise.
11801 * kern/i386/linuxbios/startup.S: Likewise.
11802 * kern/i386/linuxbios/table.c: Likewise.
11804 2007-10-31 Marco Gerards <marco@gnu.org>
11806 * conf/i386-pc.rmk (pkgdata_MODULES): Add `ata.mod'.
11807 (ata_mod_SOURCES): New variable.
11808 (ata_mod_CFLAGS): Likewise.
11809 (ata_mod_LDFLAGS): Likewise.
11811 * disk/ata.c: New file.
11813 * include/grub/disk.h (grub_disk_dev_id): Add
11814 `GRUB_DISK_DEV_ATA_ID'.
11816 2007-10-31 Robert Millan <rmh@aybabtu.com>
11818 * include/grub/i386/pc/init.h (grub_lower_mem): Moved from here ...
11819 * include/grub/i386/pc/memory.h (grub_lower_mem): ... to here.
11821 * include/grub/i386/pc/init.h (grub_upper_mem): Moved from here ...
11822 * include/grub/i386/pc/memory.h (grub_upper_mem): ... to here.
11824 * include/grub/i386/pc/memory.h: Include `<grub/symbol.h>' and
11827 * loader/i386/pc/multiboot.c: Include `<grub/machine/memory.h>'.
11829 2007-10-27 Robert Millan <rmh@aybabtu.com>
11831 * include/grub/types.h (ULONG_MAX): Define macro.
11833 2007-10-22 Robert Millan <rmh@aybabtu.com>
11835 * kern/i386/pc/startup.S: Remove `"kern/i386/realmode.S"'. Include
11837 Remove `"kern/i386/loader.S"'. Include `"../loader.S"'.
11839 2007-10-22 Robert Millan <rmh@aybabtu.com>
11841 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove `disk/i386/pc/biosdisk.c'.
11842 (pkgdata_MODULES): Add `biosdisk.mod'.
11843 (biosdisk_mod_SOURCES, biosdisk_mod_CFLAGS, biosdisk_mod_LDFLAGS): New
11846 * disk/i386/pc/biosdisk.c: Include `<grub/dl.h>'.
11847 (grub_biosdisk_init): Replace with ...
11848 (GRUB_MOD_INIT(biosdisk)): ... this.
11849 (grub_biosdisk_fini): Replace with ...
11850 (GRUB_MOD_FINI(biosdisk)): ... this.
11852 * kern/i386/pc/init.c: Remove `<grub/machine/biosdisk.h>'.
11853 (grub_machine_init): Remove call to grub_biosdisk_init().
11854 (grub_machine_fini): Remove call to grub_machine_fini().
11856 * util/i386/pc/grub-install.in (modules): Add `biosdisk'.
11858 2007-10-22 Robert Millan <rmh@aybabtu.com>
11860 * include/grub/time.h: New file.
11861 * include/grub/i386/time.h: Likewise.
11862 * include/grub/powerpc/time.h: Likewise.
11863 * include/grub/sparc64/time.h: Likewise.
11865 * include/grub/i386/pc/time.h (KERNEL_TIME_HEADER): Rename all
11867 (KERNEL_MACHINE_TIME_HEADER): ... this.
11868 * include/grub/powerpc/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
11870 (KERNEL_MACHINE_TIME_HEADER): ... this.
11871 * include/grub/sparc64/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
11873 (KERNEL_MACHINE_TIME_HEADER): ... this.
11875 * kern/i386/efi/init.c: Include `<grub/time.h>'.
11876 (grub_millisleep): New function.
11877 * kern/i386/pc/init.c: Include `<grub/time.h>'.
11878 (grub_millisleep): New function.
11879 * kern/powerpc/ieee1275/init.c: Include `<grub/time.h>'.
11880 Remove `grub/machine/time.h' include.
11881 (grub_millisleep): New function.
11882 * kern/sparc64/ieee1275/init.c: Include `<grub/time.h>'.
11883 Remove `grub/machine/time.h' include.
11884 (grub_millisleep): New function.
11886 * include/grub/misc.h (grub_div_roundup): New function.
11888 * kern/misc.c: Include `<grub/time.h>'.
11889 (grub_millisleep_generic): New function.
11891 * conf/i386-efi.rmk (kernel_mod_HEADERS): Remove `i386/efi/time.h'.
11893 * conf/i386-pc.rmk (kernel_img_HEADERS): Remove `machine/time.h'.
11895 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Remove
11896 `machine/time.h'. Add `time.h'.
11897 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
11899 2007-10-21 Robert Millan <rmh@aybabtu.com>
11901 * include/grub/misc.h (grub_max): New function.
11903 2007-10-21 Robert Millan <rmh@aybabtu.com>
11905 * util/misc.c (grub_util_info): Call fflush() before returning.
11907 2007-10-20 Robert Millan <rmh@aybabtu.com>
11909 * genmk.rb (Image): Copy `extra_flags' from here ...
11910 (PModule): ... to here. Use it in `#{obj}: #{src}' rule.
11912 * commands/i386/cpuid.c (grub_cmd_cpuid): Add __attribute__ ((unused))
11913 to `argc' and `args' arguments.
11915 2007-10-17 Robert Millan <rmh@aybabtu.com>
11917 * kern/i386/loader.S: New file.
11919 * kern/i386/pc/startup.S (grub_linux_prot_size): Moved from here ...
11920 * kern/i386/loader.S (grub_linux_prot_size)... to here.
11921 * kern/i386/pc/startup.S (grub_linux_tmp_addr): Moved from here ...
11922 * kern/i386/loader.S (grub_linux_tmp_addr)... to here.
11923 * kern/i386/pc/startup.S (grub_linux_real_addr): Moved from here ...
11924 * kern/i386/loader.S (grub_linux_real_addr)... to here.
11925 * kern/i386/pc/startup.S (grub_linux_boot_zimage): Moved from here ...
11926 * kern/i386/loader.S (grub_linux_boot_zimage)... to here.
11927 * kern/i386/pc/startup.S (grub_linux_boot_bzimage): Moved from here ...
11928 * kern/i386/loader.S (grub_linux_boot_bzimage)... to here.
11929 * kern/i386/pc/startup.S (grub_multiboot_real_boot): Moved from here ...
11930 * kern/i386/loader.S (grub_multiboot_real_boot)... to here.
11931 * kern/i386/pc/startup.S (grub_multiboot2_real_boot): Moved from here ...
11932 * kern/i386/loader.S (grub_multiboot2_real_boot)... to here.
11934 * kern/i386/realmode.S: New file.
11936 * kern/i386/pc/startup.S (protstack): Moved from here ...
11937 * kern/i386/realmode.S (protstack)... to here.
11938 * kern/i386/pc/startup.S (gdt): Moved from here ...
11939 * kern/i386/realmode.S (gdt)... to here.
11940 * kern/i386/pc/startup.S (prot_to_real): Moved from here ...
11941 * kern/i386/realmode.S (prot_to_real)... to here.
11943 * kern/i386/pc/startup.S: Include `kern/i386/loader.S' and
11944 `kern/i386/realmode.S'.
11946 2007-10-17 Robert Millan <rmh@aybabtu.com>
11948 * include/grub/i386/loader.h: New file.
11950 * include/grub/i386/pc/loader.h (grub_linux_prot_size)
11951 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
11952 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
11953 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
11954 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): Moved from here ...
11955 * include/grub/i386/loader.h (grub_linux_prot_size)
11956 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
11957 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
11958 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
11959 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): ... to here.
11961 * include/grub/i386/pc/loader.h: Include `grub/cpu/loader.h'.
11963 2007-10-15 Robert Millan <rmh@aybabtu.com>
11965 * normal/misc.c (grub_normal_print_device_info): Do not probe for
11966 filesystem when dev->disk is unset.
11967 Do probe for filesystem even when dev->disk->has_partitions is set.
11968 In case a filesystem is found, always report it.
11969 In case it isn't, if dev->disk->has_partitions is set, report that
11970 a partition table was found instead of reporting that no filesystem
11971 could be identified.
11973 2007-10-12 Robert Millan <rmh@aybabtu.com>
11975 * conf/powerpc-ieee1275.rmk (grub_mkimage_SOURCES): Replace reference
11976 to util/powerpc/ieee1275/grub-mkimage.c with util/elf/grub-mkimage.c.
11978 * include/grub/types.h (grub_host_to_target16): New macro.
11979 (grub_host_to_target32): Likewise.
11980 (grub_host_to_target64): Likewise.
11981 (grub_target_to_host16): Likewise.
11982 (grub_target_to_host32): Likewise.
11983 (grub_target_to_host64): Likewise.
11985 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
11986 Renamed from to ...
11987 (GRUB_MOD_ALIGN): ...this. Update all users.
11989 * util/elf/grub-mkimage.c (load_note): Replace grub_cpu_to_be32 with
11990 grub_host_to_target32.
11991 Replace grub_be_to_cpu32 with grub_target_to_host32.
11992 (load_modules): Likewise.
11993 (add_segments): Replace grub_be_to_cpu16 with grub_target_to_host16.
11994 Replace grub_be_to_cpu32 with grub_target_to_host32.
11995 Replace grub_cpu_to_be16 with grub_host_to_target16.
11996 Replace grub_cpu_to_be32 grub_host_to_target32.
11998 2007-10-12 Robert Millan <rmh@aybabtu.com>
12000 * util/powerpc/ieee1275/grub-mkimage.c: Moved to ...
12001 * util/elf/grub-mkimage.c: ... here.
12003 * DISTLIST: Add `util/elf/grub-mkimage.c'. Remove
12004 `util/powerpc/ieee1275/grub-mkimage.c'.
12006 2007-10-07 Robert Millan <rmh@aybabtu.com>
12008 * kern/powerpc/ieee1275/init.c: Rename HEAP_LIMIT to HEAP_MAX_ADDR,
12009 and make it easier to figure out.
12010 Add HEAP_MIN_SIZE and HEAP_MAX_ADDR definitions.
12011 (grub_claim_heap): Use HEAP_MAX_ADDR rather than taking a parameter.
12012 Do not avoid claiming a region above HEAP_MAX_ADDR if that would
12013 leave us with less than HEAP_MIN_SIZE total heap.
12014 Avoid our total amount of heap to surpass HEAP_MAX_SIZE.
12016 2007-10-03 Robert Millan <rmh@aybabtu.com>
12018 * include/grub/i386/io.h: New file.
12019 * commands/i386/pc/play.c (inb): Removed.
12021 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
12023 * term/i386/pc/serial.c (inb): Removed.
12025 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
12027 * term/i386/pc/vga.c (inb): Removed.
12029 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
12032 2007-10-02 Robert Millan <rmh@aybabtu.com>
12034 * conf/i386-efi.rmk (grub_emu_SOURCES): Add util/hostfs.c.
12035 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
12036 Reported by Marcin Kurek.
12038 2007-09-07 Robert Millan <rmh@aybabtu.com>
12040 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_test_flag): Detect
12041 SmartFirmware version updates (as released by Sven Luther), and avoid
12042 setting GRUB_IEEE1275_FLAG_NO_PARTITION_0 or
12043 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS unless the running version is
12046 2007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
12048 From Hitoshi Ozeki:
12049 * kern/i386/pc/init.c (compact_mem_regions): Decrease NUM_REGIONS
12050 when merging two regions.
12052 2007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
12054 * kern/rescue.c (grub_enter_rescue_mode): Free ARGS.
12055 * normal/completion.c (grub_normal_do_completion): Likewise.
12056 Reported by Hitoshi Ozeki.
12058 2007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
12060 Do not use devices at boot in chainloading.
12062 * loader/i386/pc/chainloader.c (boot_drive): New variable.
12063 (boot_part_addr): Likewise.
12064 (grub_chainloader_boot): Simply call grub_chainloader_real_boot
12065 with BOOT_DRIVE and BOOT_PART_ADDR.
12066 (grub_chainloader_cmd): Set BOOT_DRIVE and BOOT_PART_ADDR.
12067 Reported by Hitoshi Ozeki <h-ozeki@ck2.so-net.ne.jp>.
12069 2007-08-29 Robert Millan <rmh@aybabtu.com>
12071 Patch from Simon Peter <dn.tlp@gmx.net>:
12072 * genmk.rb (Utility): Append $(#{src}_DEPENDENCIES) to #{obj} targets.
12073 * conf/i386-pc.rmk: Replace grub-probe_DEPENDENCIES with
12074 util/grub-probe.c_DEPENDENCIES. Replace grub-setup_DEPENDENCIES with
12075 util/i386/pc/grub-setup.c_DEPENDENCIES.
12076 * conf/i386-efi.rmk: Replace grub-probe_DEPENDENCIES with
12077 util/grub-probe.c_DEPENDENCIES.
12078 * conf/powerpc-ieee1275.rmk: Likewise.
12080 2007-08-28 Robert Millan <rmh@aybabtu.com>
12082 * util/i386/get_disk_name.c: New. Implement grub_util_get_disk_name()
12083 to tell grub-mkdevicemap how to name devices.
12084 * util/ieee1275/get_disk_name.c: Likewise (using "ofpathname -a"
12087 * conf/i386-efi.rmk (grub_mkdevicemap_SOURCES): Add
12088 util/i386/get_disk_name.c.
12089 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Likewise.
12090 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Add
12091 util/ieee1275/get_disk_name.c.
12093 * include/grub/util/misc.h: grub_util_get_disk_name() declaration.
12095 * DISTLIST: Add util/i386/get_disk_name.c and
12096 util/ieee1275/get_disk_name.c.
12098 * util/grub-mkdevicemap.c: Replace device naming logic with
12099 grub_util_get_disk_name() calls.
12101 2007-08-20 Robert Millan <rmh@aybabtu.com>
12103 * normal/menu.c (run_menu): Refer to seconds as "s" not "seconds"
12104 (so that it works for both plural and singular quantities).
12106 2007-08-05 Robert Millan <rmh@aybabtu.com>
12108 * util/grub.d/10_linux.in (test_gt): Strip out vmlinu[xz]- prefix
12109 so that [xz] isn't taken into account when determining order.
12111 2007-08-02 Marco Gerards <marco@gnu.org>
12113 * DISTLIST: Add `disk/host.c', `fs/ntfs.c', `include/multiboot.h',
12114 `include/multiboot2.h', `include/grub/elfload.h',
12115 `include/multiboot.h', `include/grub/multiboot.h',
12116 `include/grub/multiboot_loader.h', `include/grub/multiboot2.h',
12117 `include/grub/i386/pc/biosdisk.h', `include/grub/util/biosdisk.h',
12118 `kern/elf.c', `loader/multiboot_loader.c',
12119 `loader/multiboot_loader_normal.c', `loader/multiboot2.c',
12120 `loader/i386/pc/multiboot2.c',
12121 `loader/powerpc/ieee1275/multiboot2.c', `util/hostfs.c' and
12122 `util/i386/pc/grub-mkrescue.in'. Remove
12123 `include/grub/biosdisk.h', `include/grub/i386/pc/multiboot.h',
12124 `include/grub/i386/pc/util/biosdisk.h' and
12125 `include/grub/powerpc/ieee1275/multiboot.h'.
12127 2007-08-02 Bean <bean123ch@gmail.com>
12129 * conf/common.rmk (pkgdata_MODULES): Add ntfs.mod.
12130 (ntfs_mod_SOURCES): New variable.
12131 (ntfs_mod_CFLAGS): Likewise.
12132 (ntfs_mod_LDFLAGS): Likewise.
12134 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfs.c.
12135 (grub_probe_SOURCES): Likewise.
12136 (grub_emu_SOURCES): Likewise.
12138 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
12139 (grub_emu_SOURCES): Likewise.
12141 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
12142 (grub_emu_SOURCES): Likewise.
12144 * conf/misc.c (grub_utf16_to_utf8): Fix unicode conversion bug.
12146 * fs/ntfs.c: New file.
12148 2007-08-02 Bean <bean123ch@gmail.com>
12150 * disk.h (grub_disk): Use NESTED_FUNC_ATTR.
12152 * file.h (grub_file): Likewise.
12154 * fshelp.h (grub_fshelp_read_file): Likewise.
12156 * util/i386/pc/grub-setup.c (setup): Likewise.
12157 (save_first_sector): Likewise.
12158 (save_blocklists): Likewise.
12160 * fs/affs.c (grub_affs_read_file): Likewise.
12162 * fs/ext2.c (grub_ext2_read_file): Likewise.
12164 * fs/fat.c (grub_fat_read_data): Likewise.
12166 * fs/fshelp.c (grub_fshelp_read_file): Likewise.
12168 * fs/hfs.c (grub_hfs_read_file): Likewise.
12170 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
12172 * fs/jfs.c (grub_jfs_read_file): Likewise.
12174 * fs/minix.c (grub_minix_read_file): Likewise.
12176 * fs/sfs.c (grub_sfs_read_file): Likewise.
12178 * fs/ufs.c (grub_ufs_read_file): Likewise.
12180 * fs/xfs.c (grub_xfs_read_file): Likewise.
12182 * command/blocklist.c (read_blocklist): Likewise.
12183 (print_blocklist): Likewise.
12185 2007-08-02 Marco Gerards <marco@gnu.org>
12187 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/host.c' and
12190 * disk/host.c: New file.
12192 * util/hostfs.c: Likewise.
12194 * fs/hfsplus.c (grub_hfsplus_mount): When reading out of disk,
12195 return `GRUB_ERR_BAD_FS'.
12196 * fs/sfs.c (grub_sfs_mount): Likewise.
12197 * fs/xfs.c (grub_xfs_mount): Likewise.
12199 * include/grub/disk.h (enum grub_disk_dev_id): Add
12200 `GRUB_DISK_DEVICE_HOST_ID'.
12202 * util/grub-emu.c (main): Initialize and de-initialize hostfs.
12204 2007-07-24 Jerone Young <jerone@gmail.com>
12206 * conf/i386-pc.rmk: Add Multiboot loader and multiboot 2 to multiboot
12207 modules for compilation.
12208 * conf/powerpc-ieee1275.rmk: Likewise.
12210 * include/multiboot.h: Move multiboot definitions to one file. Rename
12211 many definitions to not get grub specific.
12212 * include/multiboot2.h: Create header with multiboot 2 definitions.
12213 * include/grub/multiboot.h: Header for grub specific function
12214 prototypes and definitions.
12215 * include/grub/multiboot2.h: Likewise.
12216 * include/grub/multiboot_loader.h: Likewise.
12217 * include/grub/i386/pc/multiboot.h: Removed.
12218 * include/grub/powerpc/ieee1275/multiboot.h: Removed.
12220 * loader/multiboot_loader.c: Created to act as a proxy for multiboot 1
12221 and 2 to allow for one multiboot and module commands.
12222 * loader/multiboot2.c: Add multiboot2 functionality.
12223 * loader/i386/pc/multiboot.c: Modify for new multiboot header location
12224 and definition names.
12225 * loader/i386/pc/multiboot2.c: Created to add i386 specific multiboot
12227 * loader/powerpc/ieee1275/multiboot2.c: Created to add powerpc
12228 ieee1275 specific multiboot2 code.
12230 * kern/i386/pc/startup.S: Change headers and definition names for
12231 multiboot. Add function grub_multiboot2_real_boot for multiboot 2.
12233 2007-07-22 Robert Millan <rmh@aybabtu.com>
12235 * geninitheader.sh: Process file specified in first parameter rather
12236 than hardcoding grub_modules_init.lst.
12237 * geninit.sh: Likewise. Also, construct header name dynamically rather
12238 than hardcoding grub_modules_init.h.
12240 * conf/common.rmk: Rename grub_modules_init.[ch] files associated with
12241 grub-emu to grub_emu_init.[ch]. Add rules to build analogous
12242 grub_probe_init.[ch] and grub_setup_init.[ch].
12244 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Replace
12245 grub_modules_init.h with grub_emu_init.h.
12246 (grub_probe_DEPENDENCIES, grub_probe_SOURCES): Add new
12247 grub_probe_init.[ch] files.
12248 * conf/i386-efi.rmk: Likewise.
12249 * conf/i386-pc.rmk: Likewise.
12250 (grub_setup_DEPENDENCIES, grub_setup_SOURCES): Add new
12251 grub_setup_init.[ch] files.
12253 * util/grub-emu.c: Replace grub_modules_init.h with grub_emu_init.h.
12254 * util/grub-probe.c: Include grub_probe_init.h. Use grub_init_all()
12255 to initialize modules rather than a list of hardcoded functions.
12256 * util/i386/pc/grub-setup.c: Include grub_setup_init.h. Use
12257 grub_init_all() to initialize modules rather than a list of hardcoded
12260 2007-07-22 Robert Millan <rmh@aybabtu.com>
12262 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set
12263 GRUB_IEEE1275_FLAG_NO_PARTITION_0 flag when running on SmartFirmware.
12265 2007-07-22 Robert Millan <rmh@aybabtu.com>
12267 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
12268 GRUB_IEEE1275_FLAG_BROKEN_OUTPUT flag.
12269 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set this
12270 flag when running on SmartFirmware.
12271 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid running
12272 "output-device output" command when GRUB_IEEE1275_FLAG_BROKEN_OUTPUT
12275 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
12276 Increase partno when GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS flag is set,
12277 rather than decreasing it.
12279 * util/i386/pc/grub-setup.c (setup): When embedding is required, but
12280 there's not enough space to do it, fail in the same way as when it
12281 can't be done because there are no partitions.
12283 * util/powerpc/ieee1275/grub-install.in: Improve error message shown
12284 when nvsetenv failed.
12286 2007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
12288 * conf/i386-pc.rmk (CLEANFILES): Removed for grub-mkrescue,
12289 because this rule is automatically generated.
12290 (grub-mkrescue): Removed for the same reason as above.
12292 2007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
12294 Migrate to GNU General Public License Version 3.
12296 * COPYING: Replaced with the plain text version of GPLv3.
12298 * config.guess: Updated from gnulib.
12299 * config.sub: Likewise.
12301 * geninit.sh: Output a GPLv3 copyright notice.
12302 * geninitheader.sh: Likewise.
12303 * genmodsrc.sh: Likewise.
12304 * gensymlist.sh.in: Likewise.
12306 * boot/i386/pc/boot.S: Upgraded to GPLv3.
12307 * boot/i386/pc/diskboot.S: Likewise.
12308 * boot/i386/pc/pxeboot.S: Likewise.
12309 * commands/blocklist.c: Likewise.
12310 * commands/boot.c: Likewise.
12311 * commands/cat.c: Likewise.
12312 * commands/cmp.c: Likewise.
12313 * commands/configfile.c: Likewise.
12314 * commands/echo.c: Likewise.
12315 * commands/help.c: Likewise.
12316 * commands/ls.c: Likewise.
12317 * commands/search.c: Likewise.
12318 * commands/terminal.c: Likewise.
12319 * commands/test.c: Likewise.
12320 * commands/videotest.c: Likewise.
12321 * commands/i386/cpuid.c: Likewise.
12322 * commands/i386/pc/halt.c: Likewise.
12323 * commands/i386/pc/play.c: Likewise.
12324 * commands/i386/pc/reboot.c: Likewise.
12325 * commands/i386/pc/vbeinfo.c: Likewise.
12326 * commands/i386/pc/vbetest.c: Likewise.
12327 * commands/ieee1275/halt.c: Likewise.
12328 * commands/ieee1275/reboot.c: Likewise.
12329 * commands/ieee1275/suspend.c: Likewise.
12330 * disk/loopback.c: Likewise.
12331 * disk/lvm.c: Likewise.
12332 * disk/raid.c: Likewise.
12333 * disk/efi/efidisk.c: Likewise.
12334 * disk/i386/pc/biosdisk.c: Likewise.
12335 * disk/ieee1275/ofdisk.c: Likewise.
12336 * font/manager.c: Likewise.
12337 * fs/affs.c: Likewise.
12338 * fs/ext2.c: Likewise.
12339 * fs/fat.c: Likewise.
12340 * fs/fshelp.c: Likewise.
12341 * fs/hfs.c: Likewise.
12342 * fs/hfsplus.c: Likewise.
12343 * fs/iso9660.c: Likewise.
12344 * fs/jfs.c: Likewise.
12345 * fs/minix.c: Likewise.
12346 * fs/sfs.c: Likewise.
12347 * fs/ufs.c: Likewise.
12348 * fs/xfs.c: Likewise.
12349 * hello/hello.c: Likewise.
12350 * include/grub/acorn_filecore.h: Likewise.
12351 * include/grub/arg.h: Likewise.
12352 * include/grub/bitmap.h: Likewise.
12353 * include/grub/boot.h: Likewise.
12354 * include/grub/cache.h: Likewise.
12355 * include/grub/device.h: Likewise.
12356 * include/grub/disk.h: Likewise.
12357 * include/grub/dl.h: Likewise.
12358 * include/grub/elfload.h: Likewise.
12359 * include/grub/env.h: Likewise.
12360 * include/grub/err.h: Likewise.
12361 * include/grub/file.h: Likewise.
12362 * include/grub/font.h: Likewise.
12363 * include/grub/fs.h: Likewise.
12364 * include/grub/fshelp.h: Likewise.
12365 * include/grub/gzio.h: Likewise.
12366 * include/grub/hfs.h: Likewise.
12367 * include/grub/kernel.h: Likewise.
12368 * include/grub/loader.h: Likewise.
12369 * include/grub/lvm.h: Likewise.
12370 * include/grub/misc.h: Likewise.
12371 * include/grub/mm.h: Likewise.
12372 * include/grub/net.h: Likewise.
12373 * include/grub/normal.h: Likewise.
12374 * include/grub/parser.h: Likewise.
12375 * include/grub/partition.h: Likewise.
12376 * include/grub/pc_partition.h: Likewise.
12377 * include/grub/raid.h: Likewise.
12378 * include/grub/rescue.h: Likewise.
12379 * include/grub/script.h: Likewise.
12380 * include/grub/setjmp.h: Likewise.
12381 * include/grub/symbol.h: Likewise.
12382 * include/grub/term.h: Likewise.
12383 * include/grub/terminfo.h: Likewise.
12384 * include/grub/tparm.h: Likewise.
12385 * include/grub/types.h: Likewise.
12386 * include/grub/video.h: Likewise.
12387 * include/grub/efi/api.h: Likewise.
12388 * include/grub/efi/chainloader.h: Likewise.
12389 * include/grub/efi/console.h: Likewise.
12390 * include/grub/efi/console_control.h: Likewise.
12391 * include/grub/efi/disk.h: Likewise.
12392 * include/grub/efi/efi.h: Likewise.
12393 * include/grub/efi/pe32.h: Likewise.
12394 * include/grub/efi/time.h: Likewise.
12395 * include/grub/i386/linux.h: Likewise.
12396 * include/grub/i386/setjmp.h: Likewise.
12397 * include/grub/i386/types.h: Likewise.
12398 * include/grub/i386/efi/kernel.h: Likewise.
12399 * include/grub/i386/efi/loader.h: Likewise.
12400 * include/grub/i386/efi/time.h: Likewise.
12401 * include/grub/i386/pc/biosdisk.h: Likewise.
12402 * include/grub/i386/pc/boot.h: Likewise.
12403 * include/grub/i386/pc/chainloader.h: Likewise.
12404 * include/grub/i386/pc/console.h: Likewise.
12405 * include/grub/i386/pc/init.h: Likewise.
12406 * include/grub/i386/pc/kernel.h: Likewise.
12407 * include/grub/i386/pc/loader.h: Likewise.
12408 * include/grub/i386/pc/memory.h: Likewise.
12409 * include/grub/i386/pc/multiboot.h: Likewise.
12410 * include/grub/i386/pc/serial.h: Likewise.
12411 * include/grub/i386/pc/time.h: Likewise.
12412 * include/grub/i386/pc/vbe.h: Likewise.
12413 * include/grub/i386/pc/vbeblit.h: Likewise.
12414 * include/grub/i386/pc/vbefill.h: Likewise.
12415 * include/grub/i386/pc/vbeutil.h: Likewise.
12416 * include/grub/i386/pc/vga.h: Likewise.
12417 * include/grub/ieee1275/ieee1275.h: Likewise.
12418 * include/grub/ieee1275/ofdisk.h: Likewise.
12419 * include/grub/powerpc/libgcc.h: Likewise.
12420 * include/grub/powerpc/setjmp.h: Likewise.
12421 * include/grub/powerpc/types.h: Likewise.
12422 * include/grub/powerpc/ieee1275/biosdisk.h: Likewise.
12423 * include/grub/powerpc/ieee1275/console.h: Likewise.
12424 * include/grub/powerpc/ieee1275/ieee1275.h: Likewise.
12425 * include/grub/powerpc/ieee1275/kernel.h: Likewise.
12426 * include/grub/powerpc/ieee1275/loader.h: Likewise.
12427 * include/grub/powerpc/ieee1275/multiboot.h: Likewise.
12428 * include/grub/powerpc/ieee1275/time.h: Likewise.
12429 * include/grub/powerpc/ieee1275/util/biosdisk.h: Likewise.
12430 * include/grub/sparc64/libgcc.h: Likewise.
12431 * include/grub/sparc64/setjmp.h: Likewise.
12432 * include/grub/sparc64/types.h: Likewise.
12433 * include/grub/sparc64/ieee1275/console.h: Likewise.
12434 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
12435 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
12436 * include/grub/sparc64/ieee1275/time.h: Likewise.
12437 * include/grub/util/biosdisk.h: Likewise.
12438 * include/grub/util/getroot.h: Likewise.
12439 * include/grub/util/lvm.h: Likewise.
12440 * include/grub/util/misc.h: Likewise.
12441 * include/grub/util/raid.h: Likewise.
12442 * include/grub/util/resolve.h: Likewise.
12443 * io/gzio.c: Likewise.
12444 * kern/device.c: Likewise.
12445 * kern/disk.c: Likewise.
12446 * kern/dl.c: Likewise.
12447 * kern/elf.c: Likewise.
12448 * kern/env.c: Likewise.
12449 * kern/err.c: Likewise.
12450 * kern/file.c: Likewise.
12451 * kern/fs.c: Likewise.
12452 * kern/loader.c: Likewise.
12453 * kern/main.c: Likewise.
12454 * kern/misc.c: Likewise.
12455 * kern/mm.c: Likewise.
12456 * kern/parser.c: Likewise.
12457 * kern/partition.c: Likewise.
12458 * kern/rescue.c: Likewise.
12459 * kern/term.c: Likewise.
12460 * kern/efi/efi.c: Likewise.
12461 * kern/efi/init.c: Likewise.
12462 * kern/efi/mm.c: Likewise.
12463 * kern/i386/dl.c: Likewise.
12464 * kern/i386/efi/init.c: Likewise.
12465 * kern/i386/efi/startup.S: Likewise.
12466 * kern/i386/pc/init.c: Likewise.
12467 * kern/i386/pc/lzo1x.S: Likewise.
12468 * kern/i386/pc/startup.S: Likewise.
12469 * kern/ieee1275/ieee1275.c: Likewise.
12470 * kern/powerpc/cache.S: Likewise.
12471 * kern/powerpc/dl.c: Likewise.
12472 * kern/powerpc/ieee1275/cmain.c: Likewise.
12473 * kern/powerpc/ieee1275/crt0.S: Likewise.
12474 * kern/powerpc/ieee1275/init.c: Likewise.
12475 * kern/powerpc/ieee1275/openfw.c: Likewise.
12476 * kern/sparc64/cache.S: Likewise.
12477 * kern/sparc64/dl.c: Likewise.
12478 * kern/sparc64/ieee1275/init.c: Likewise.
12479 * kern/sparc64/ieee1275/openfw.c: Likewise.
12480 * loader/efi/chainloader.c: Likewise.
12481 * loader/efi/chainloader_normal.c: Likewise.
12482 * loader/i386/efi/linux.c: Likewise.
12483 * loader/i386/efi/linux_normal.c: Likewise.
12484 * loader/i386/pc/chainloader.c: Likewise.
12485 * loader/i386/pc/chainloader_normal.c: Likewise.
12486 * loader/i386/pc/linux.c: Likewise.
12487 * loader/i386/pc/linux_normal.c: Likewise.
12488 * loader/i386/pc/multiboot.c: Likewise.
12489 * loader/i386/pc/multiboot_normal.c: Likewise.
12490 * loader/powerpc/ieee1275/linux.c: Likewise.
12491 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
12492 * normal/arg.c: Likewise.
12493 * normal/cmdline.c: Likewise.
12494 * normal/command.c: Likewise.
12495 * normal/completion.c: Likewise.
12496 * normal/execute.c: Likewise.
12497 * normal/function.c: Likewise.
12498 * normal/lexer.c: Likewise.
12499 * normal/main.c: Likewise.
12500 * normal/menu.c: Likewise.
12501 * normal/menu_entry.c: Likewise.
12502 * normal/misc.c: Likewise.
12503 * normal/parser.y: Likewise.
12504 * normal/script.c: Likewise.
12505 * normal/i386/setjmp.S: Likewise.
12506 * normal/powerpc/setjmp.S: Likewise.
12507 * normal/sparc64/setjmp.S: Likewise.
12508 * partmap/acorn.c: Likewise.
12509 * partmap/amiga.c: Likewise.
12510 * partmap/apple.c: Likewise.
12511 * partmap/gpt.c: Likewise.
12512 * partmap/pc.c: Likewise.
12513 * partmap/sun.c: Likewise.
12514 * term/gfxterm.c: Likewise.
12515 * term/terminfo.c: Likewise.
12516 * term/efi/console.c: Likewise.
12517 * term/i386/pc/console.c: Likewise.
12518 * term/i386/pc/serial.c: Likewise.
12519 * term/i386/pc/vesafb.c: Likewise.
12520 * term/i386/pc/vga.c: Likewise.
12521 * term/ieee1275/ofconsole.c: Likewise.
12522 * util/biosdisk.c: Likewise.
12523 * util/console.c: Likewise.
12524 * util/genmoddep.c: Likewise.
12525 * util/getroot.c: Likewise.
12526 * util/grub-emu.c: Likewise.
12527 * util/grub-mkdevicemap.c: Likewise.
12528 * util/grub-probe.c: Likewise.
12529 * util/lvm.c: Likewise.
12530 * util/misc.c: Likewise.
12531 * util/raid.c: Likewise.
12532 * util/resolve.c: Likewise.
12533 * util/update-grub.in: Likewise.
12534 * util/update-grub_lib.in: Likewise.
12535 * util/grub.d/00_header.in: Likewise.
12536 * util/grub.d/10_hurd.in: Likewise.
12537 * util/grub.d/10_linux.in: Likewise.
12538 * util/i386/efi/grub-install.in: Likewise.
12539 * util/i386/efi/grub-mkimage.c: Likewise.
12540 * util/i386/pc/grub-install.in: Likewise.
12541 * util/i386/pc/grub-mkimage.c: Likewise.
12542 * util/i386/pc/grub-mkrescue.in: Likewise.
12543 * util/i386/pc/grub-setup.c: Likewise.
12544 * util/i386/pc/misc.c: Likewise.
12545 * util/powerpc/ieee1275/grub-install.in: Likewise.
12546 * util/powerpc/ieee1275/grub-mkimage.c: Likewise.
12547 * util/powerpc/ieee1275/misc.c: Likewise.
12548 * video/bitmap.c: Likewise.
12549 * video/video.c: Likewise.
12550 * video/i386/pc/vbe.c: Likewise.
12551 * video/i386/pc/vbeblit.c: Likewise.
12552 * video/i386/pc/vbefill.c: Likewise.
12553 * video/i386/pc/vbeutil.c: Likewise.
12554 * video/readers/tga.c: Likewise.
12556 2007-07-02 Robert Millan <rmh@aybabtu.com>
12558 * conf/i386-efi.rmk: Replace obsolete reference to
12559 util/i386/pc/biosdisk.c with util/biosdisk.c, and util/i386/pc/getroot.c
12560 with util/getroot.c.
12561 * conf/powerpc-ieee1275.rmk: Likewise.
12562 * conf/sparc64-ieee1275.rmk: Likewise.
12564 * util/grub-emu.c (main): Fix unchecked pointer handling.
12566 2007-07-02 Robert Millan <rmh@aybabtu.com>
12568 * util/i386/efi/grub-install.in: Allow `grub_probe --target=partmap'
12569 invocation to fail, in order to support partition-less media.
12571 * util/i386/pc/grub-install.in: Likewise.
12573 * util/powerpc/ieee1275/grub-install.in: Use grub-probe to determine
12574 which fs or partmap modules are needed (akin to its sister scripts).
12576 Also use grub-probe to get rid of unportable /proc/mounts check.
12578 Print the same informational message that the other scripts do, before
12581 2007-06-23 Robert Millan <rmh@aybabtu.com>
12583 * util/update-grub_lib.in (font_path): New function. Determine whether
12584 a font file can be found and, if so, echo the GRUB path to it.
12586 * util/update-grub.in: Handle multiple terminals depending on user
12587 input, platform availability and font file presence. Propagate
12588 variables of our findings to /etc/grub.d/ children.
12590 * util/grub.d/00_header.in: Handle multiple terminals, based on
12591 environment setup by update-grub.
12593 2007-06-23 Robert Millan <rmh@aybabtu.com>
12595 * conf/i386-pc.rmk (pkgdata_MODULES): Add serial.mod.
12597 2007-06-21 Robert Millan <rmh@aybabtu.com>
12599 * include/grub/i386/pc/kernel.h: Define GRUB_KERNEL_MACHINE_DATA_END to
12600 indicate end of data section in kernel image.
12601 * include/grub/i386/efi/kernel.h: Define GRUB_KERNEL_MACHINE_PREFIX and
12602 GRUB_KERNEL_MACHINE_DATA_END.
12604 * kern/i386/pc/startup.S: Do not initialize grub_prefix, only reserve
12606 * kern/i386/efi/startup.S: Likewise.
12608 * util/i386/pc/grub-mkimage.c: Initialize grub_prefix to /boot/grub
12609 during image generation. Implement --prefix option to override this
12611 * util/i386/efi/grub-mkimage.c: Likewise.
12613 * util/update-grub_lib.in (convert_system_path_to_grub_path): Split
12614 code to make path relative to its root into a separate function.
12616 * util/i386/pc/grub-install.in: Use newly provided
12617 make_system_path_relative_to_its_root() to convert ${grubdir}, then
12618 pass the result to grub-install --prefix.
12620 2007-06-13 Robert Millan <rmh@aybabtu.com>
12622 * include/grub/util/misc.h: Define DEFAULT_DIRECTORY and
12623 DEFAULT_DEVICE_MAP.
12624 * util/grub-emu.c: Use above definitions from misc.h instead of
12626 * util/grub-mkdevicemap.c: Likewise.
12627 * util/i386/pc/grub-setup.c: Likewise.
12628 * util/grub-probe.c: Likewise.
12629 (probe): Abort with grub_util_error() when either
12630 grub_guess_root_device or grub_util_get_grub_dev fails.
12632 2007-06-12 Robert Millan <rmh@aybabtu.com>
12634 * normal/command.c (grub_command_execute): Use NULL rather than 0 for
12635 "pager" assignment.
12636 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Likewise for
12638 * util/grub-probe.c (probe): Likewise for "drive_name".
12640 2007-06-11 Robert Millan <rmh@aybabtu.com>
12642 * util/i386/pc/grub-mkrescue.in: Pad both floppy images with zeroes,
12643 not just the cdrom one.
12645 2007-06-11 Robert Millan <rmh@aybabtu.com>
12647 * util/i386/pc/grub-mkrescue.in: Add "set -e".
12648 Add --pkglibdir=DIR option to override pkglibdir.
12649 Mention --image-type=TYPE in help output.
12650 Fix --grub-mkimage (it was a no-op).
12651 Abort gracefully when no parameter is given.
12653 2007-06-11 Robert Millan <rmh@aybabtu.com>
12655 * util/i386/pc/grub-mkrescue.in: New file.
12656 * conf/i386-pc.rmk: Add its build declarations. Put it in bin_SCRIPTS.
12657 * Makefile.in: Handle bin_SCRIPTS.
12659 2007-06-10 Vesa Jaaskelainen <chaac@nic.fi>
12661 * term/gfxterm.c (grub_gfxterm_init): Added support for specifying
12662 list of video modes.
12664 2007-06-06 Robert Millan <rmh@aybabtu.com>
12666 * util/update-grub_lib.in (convert_system_path_to_grub_path): Abort if
12667 file doesn't exist, or if it is in a filesystem grub can't read.
12669 * util/update-grub.in: Set fallback for GRUB_FS check to "unknown". Do
12670 not abort if GRUB_DRIVE could not be defined. Rearrange generated
12671 header comment to fit in 80 columns when the variables are resolved.
12673 * util/grub.d/00_header.in: Only set root variable when GRUB_DRIVE
12674 could be identified by update-grub. Remove redundant check for
12675 unifont.pff existence (since convert_system_path_to_grub_path now
12678 2007-06-04 Robert Millan <rmh@aybabtu.com>
12680 * conf/i386-efi.rmk (grub_probe_SOURCES): Add partmap/apple.c.
12682 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise.
12684 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add partmap/pc.c.
12686 2007-06-04 Robert Millan <rmh@aybabtu.com>
12688 * conf/powerpc-ieee1275.rmk: Enable grub-mkdevicemap and grub-probe.
12690 * include/grub/partition.h: Declare grub_apple_partition_map_init and
12691 grub_apple_partition_map_fini.
12694 (grub_util_biosdisk_open): Replace BLKGETSIZE with BLKGETSIZE64 (needed
12695 to access >2 TiB disks).
12697 Print disk->total_sectors with %llu instead of %lu, since this
12698 variable is always 64-bit (prevents wrong disk size from being displayed
12699 on either >2 TiB disk or big-endian CPU).
12701 (grub_util_biosdisk_get_grub_dev): Convert gpt_partition_map handling
12702 into a generic case that supports all (sane) partition maps.
12704 Stop using grub_cpu_to_le32() on dos_part / bsd_part since it actually
12707 * util/grub-probe.c: Call grub_apple_partition_map_init() before probe()
12708 and grub_apple_partition_map_fini() after that.
12710 2007-06-01 Robert Millan <rmh@aybabtu.com>
12712 * util/update-grub.in: Export GRUB_CMDLINE_LINUX.
12714 * util/grub.d/00_header.in: Only enable gfxterm when
12715 convert_system_path_to_grub_path() succeeds.
12717 2007-05-20 Robert Millan <rmh@aybabtu.com>
12719 * util/update-grub_lib.in: New file.
12720 * DISTLIST: Add update-grub_lib.in.
12721 * conf/common.rmk: Generate update-grub_lib and install it in
12723 * Makefile.in: Add install routine for $(lib_DATA).
12725 * util/grub.d/00_header.in: Use convert_system_path_to_grub_path()
12726 function provided by update-grub_lib to support arbitrary paths of
12728 * util/update-grub.in: Use convert_system_path_to_grub_path() to
12729 initialize GRUB_DRIVE_BOOT and GRUB_DRIVE_BOOT_GRUB variables.
12731 2007-05-19 Robert Millan <rmh@aybabtu.com>
12733 * commands/i386/cpuid.c: New module.
12734 * DISTLIST: Add it.
12735 * conf/i386-efi.rmk: Enable cpuid.mod.
12736 * conf/i386-pc.rmk: Likewise.
12738 2007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
12740 * kern/disk.c (grub_disk_read): Check return value of
12743 2007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
12745 * util/getroot.c (grub_util_get_grub_dev): Support partitionable
12747 * disk/raid.c (grub_raid_open): Likewise.
12749 2007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
12751 * util/biosdisk.c (linux_find_partition): Allocate real_dev on the
12752 stack instead of on the heap.
12754 * kern/disk.c (grub_disk_read): Make sure tmp_buf is big enough
12755 before doing a read on it.
12757 * configure.ac: Only use -fno-stack-protector for the target
12760 2007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
12762 * video/i386/pc/vbe.c (grub_video_vbe_create_render_target): Add
12763 __attribute_ ((unused)) to mode_type argument.
12765 * util/getroot.c (grub_guess_root_device): Fix #endif.
12767 * kern/misc.c (memcmp): Fix prototype.
12769 * include/grub/partition.h [GRUB_UTIL]
12770 (grub_gpt_partition_map_init): Add prototype.
12771 (grub_gpt_partition_map_fini): Likewise.
12773 * fs/jfs.c (struct grub_jfs_inode): Put __attribute__ ((packed)
12774 at the right place.
12776 * fs/fat.c (grub_fat_mount): Replace ~0UL with ~0U.
12777 (grub_fat_read_data): Likewise.
12778 (grub_fat_find_dir): Likewise.
12780 * font/manager.c (find_glyph): Make table a const.
12781 (grub_font_get_glyph): Remove bitmap from if statement.
12783 2007-05-16 Jeroen Dekkers <jeroen@dekkers.cx>
12785 * util/getroot.c (grub_guess_root_device): Remove RAID and LVM
12786 code, first search for device in /dev/mapper, then in /dev.
12787 (grub_util_get_grub_dev): New function.
12788 * include/grub/util/getroot.h (grub_util_get_grub_dev): Add
12790 * util/grub-probe.c (probe): Remove check for RAID, call
12791 grub_util_get_grub_dev() instead of
12792 grub_util_biosdisk_get_grub_dev().
12793 * util/grub-emu.c (main): Call grub_util_get_grub_dev() instead of
12794 grub_util_biosdisk_get_grub_dev().
12795 * util/i386/pc/grub-setup.c (main): Likewise.
12797 2007-05-16 Robert Millan <rmh@aybabtu.com>
12799 * DISTLIST: Update for the latest changes.
12800 * conf/i386-pc.rmk: Use the new paths for util/getroot.c,
12801 util/grub-mkdevicemap.c, util/grub-probe.c and util/biosdisk.c.
12802 * util/grub-emu.c: Replace grub/i386/pc/util/biosdisk.h with
12803 grub/util/biosdisk.h.
12804 * util/i386/pc/grub-setup.c: Replace grub/machine/util/biosdisk.h with
12805 grub/util/biosdisk.h.
12807 2007-05-16 Robert Millan <rmh@aybabtu.com>
12809 * util/grub.d/00_header.in: Set default gfxmode to `640x480'.
12811 2007-05-16 Robert Millan <rmh@aybabtu.com>
12813 * util/i386/efi/grub-install.in: New.
12814 * conf/i386-efi.rmk: Enable grub-mkdevicemap, grub-probe and the
12815 newly added grub-install.
12816 * util/biosdisk.c: Remove unnecessary grub/machine/biosdisk.h
12818 * util/getroot.c: Replace grub/i386/pc/util/biosdisk.h with
12819 grub/util/biosdisk.h.
12820 * util/grub-probe.c: Replace grub/machine/util/biosdisk.h with
12821 grub/util/biosdisk.h.
12823 2007-05-16 Robert Millan <rmh@aybabtu.com>
12825 * include/grub/i386/pc/util/biosdisk.h: Moved to ...
12826 * include/grub/util/biosdisk.h: ... here.
12827 * util/i386/pc/biosdisk.c: Moved to ...
12828 * util/biosdisk.c: ... here.
12829 * util/i386/pc/getroot.c: Moved to ...
12830 * util/getroot.c: ... here.
12831 * util/i386/pc/grub-mkdevicemap.c: Moved to ...
12832 * util/grub-mkdevicemap.c: ... here.
12833 * util/i386/pc/grub-probe.c: Moved to ...
12834 * util/grub-probe.c: ... here.
12836 2007-05-15 Robert Millan <rmh@aybabtu.com>
12838 * util/update-grub.in: Remove duplicated line in grub.cfg header
12841 2007-05-13 Robert Millan <rmh@aybabtu.com>
12843 * util/update-grub.in: Fix a few assumptions about the devices holding
12844 /, /boot and /boot/grub being the same.
12845 * util/grub.d/00_header.in: Likewise.
12846 * util/grub.d/10_hurd.in: Likewise.
12847 * util/grub.d/10_linux.in: Likewise.
12849 * util/grub.d/10_linux.in: Implement Linux image sorting with arbitrary
12850 patterns. Use that to define the `.old' suffix as older than `'.
12852 * util/grub.d/00_header.in: Set default gfxmode to `800x600x16'.
12854 * util/update-grub.in: Add a reference to ${sysconfdir}/default/grub in
12855 the grub.cfg header message.
12857 2007-05-11 Robert Millan <rmh@aybabtu.com>
12859 * util/update-grub.in: Create device.map if it doesn't already exist,
12860 before attempting to run grub-probe.
12861 Check for grub-probe and grub-mkdevicemap with the same code
12862 grub-install is using.
12865 2007-05-09 Jeroen Dekkers <jeroen@dekkers.cx>
12867 * Makefile.in: Add the datarootdir autoconf variable.
12869 2007-05-09 Robert Millan <rmh@aybabtu.com>
12871 * util/i386/pc/grub-probe.c (probe): When detecting partition map,
12872 fail gracefully if dev->disk->partition == NULL.
12874 2007-05-07 Robert Millan <rmh@aybabtu.com>
12876 * util/i386/pc/grub-probe.c: Add `grub-probe -t partmap' parameter to
12877 determine partition map module.
12878 * util/i386/pc/grub-install.in: Use this feature to decide which
12879 partition module to load, instead of hardcoding pc and gpt.
12881 2007-05-07 Robert Millan <rmh@aybabtu.com>
12883 * Makefile.in: Fix assumption that $(srcdir) has a trailing slash when
12884 source directory differs from build directory.
12886 2007-05-05 Robert Millan <rmh@aybabtu.com>
12888 * util/powerpc/ieee1275/grub-install.in: Fix syntax error in pkglibdir
12891 2007-05-05 Robert Millan <rmh@aybabtu.com>
12893 * util/update-grub.in: Create ${grub_prefix} if it doesn't exist.
12895 2007-05-05 Robert Millan <rmh@aybabtu.com>
12897 * util/grub.d/10_linux.in: Allow the administrator to insert Linux
12898 command-line arguments via ${GRUB_CMDLINE_LINUX}.
12900 2007-05-05 Robert Millan <rmh@aybabtu.com>
12902 * conf/i386-pc.rmk (grub_setup_SOURCES): Add partmap/gpt.c.
12903 (grub_probe_SOURCES): Likewise.
12904 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): Detect
12905 GPT and initialize dos_part and bsd_part accordingly.
12906 * util/i386/pc/grub-setup.c (setup): Ditto for install_dos_part and
12908 (main): Activate gpt module for use during partition identification,
12909 and deactivate it afterwards.
12910 * util/i386/pc/grub-install.in: Add gpt module to core.img.
12911 * util/i386/pc/grub-probe.c (main): Activate gpt module for use during
12912 partition identification, and deactivate it afterwards.
12914 2007-05-05 Robert Millan <rmh@aybabtu.com>
12916 * term/i386/pc/console.c (grub_console_fini): Call
12917 grub_term_set_current() before grub_term_unregister().
12919 2007-05-04 Robert Millan <rmh@aybabtu.com>
12921 * DISTLIST: Add util/update-grub.in, util/grub.d/00_header.in,
12922 util/grub.d/10_hurd.in, util/grub.d/10_linux.in and util/grub.d/README.
12923 * Makefile.in: Build update-grub_SCRIPTS. Install update-grub_SCRIPTS
12924 and update-grub_DATA.
12925 * conf/common.rmk: Build and install update-grub components.
12926 * conf/common.mk: Regenerate.
12927 * util/update-grub.in: New. Core of update-grub.
12928 * util/grub.d/00_header.in: New. Generates grub.cfg header.
12929 * util/grub.d/10_hurd.in: New. Generates boot entries for the Hurd.
12930 * util/grub.d/10_linux.in: New. Generates boot entries for Linux.
12931 * util/grub.d/README: New. Document grub.d directory layout.
12933 2007-05-01 Robert Millan <rmh@aybabtu.com>
12935 * util/grub-emu.c: Move initialization functions
12936 grub_util_biosdisk_init() and grub_init_all() before
12937 grub_util_biosdisk_get_grub_dev(), which relies on them.
12939 2007-04-19 Robert Millan <rmh@aybabtu.com>
12941 * util/powerpc/ieee1275/grub-install.in: Initialize ${bindir}, since
12944 2007-04-18 Jerone Young <jerone@gmail.com>
12946 * kernel/elf.c: Add missing parenthesis for conditional statement
12949 2007-04-10 Jerone Young <jerone@gmail.com>
12951 * util/i386/pc/getroot.c: Update so that if root device is /dev/root ,
12952 continue on and look for device node with real device name.
12954 2007-04-10 Jerone Young <jerone@gmail.com>
12956 * configure.ac: Add argument for autoconf to use transformation
12958 * Makefile.in: Add autoconf package transformation code.
12959 * util/i386/pc/grub-install.in: Likewise.
12960 * util/powerpc/ieee1275/grub-install.in: Likewise.
12962 2007-03-19 Yoshinori K. Okuji <okuji@enbug.org>
12964 * fs/ext2.c (EXT2_GOOD_OLD_REVISION): New macro.
12965 (EXT2_GOOD_OLD_INODE_SIZE): Likewise.
12966 (EXT2_REVISION): Likewise.
12967 (EXT2_INODE_SIZE): Likewise.
12968 (struct grub_ext2_block_group): Added a missing member
12970 (grub_ext2_read_inode): Divide by the inode size in a superblock
12971 instead of 128 to obtain INODES_PER_BLOCK.
12972 Use the macro EXT2_INODE_SIZE instead of directly using
12973 SBLOCK->INODE_SIZE.
12975 2007-03-18 Yoshinori K. Okuji <okuji@enbug.org>
12977 * fs/ext2.c (grub_ext2_read_inode): Use the inode size in a
12978 superblock instead of the structure size to compute an
12979 offset. This fixes the problem that GRUB could not read a
12980 filesystem when inode size is different from 128-byte.
12982 2007-03-05 Marco Gerards <marco@gnu.org>
12984 * normal/main.c (read_config_file): When "menu" is not set, create
12985 an initial context.
12987 2007-02-21 Hollis Blanchard <hollis@penguinppc.org>
12989 * kern/powerpc/ieee1275/init.c (HEAP_SIZE): Removed.
12990 (HEAP_LIMIT): New macro.
12991 (grub_claim_heap): Claim memory up to `heaplimit'.
12993 2007-02-21 Hollis Blanchard <hollis@penguinppc.org>
12995 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Link at 64KB.
12996 * kern/powerpc/ieee1275/init.c (_end): Add declaration.
12997 (_start): Likewise.
12998 (grub_arch_modules_addr): Return address after `_end'.
12999 * util/powerpc/ieee1275/grub-mkimage.c: Include grub/misc.h.
13000 (load_modules): Use new parameter as `p_paddr' and `p_vaddr'.
13001 (add_segments): Calculate `_end' from phdr size and location.
13002 (ALIGN_UP): Moved to ...
13003 * include/grub/misc.h: here.
13004 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
13006 (GRUB_IEEE1275_MODULE_BASE): Removed.
13008 2007-02-20 Hollis Blanchard <hollis@penguinppc.org>
13010 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Correct
13013 2007-02-20 Hollis Blanchard <hollis@penguinppc.org>
13015 * include/grub/elfload.h (grub_elf32_load_hook_t): Return grub_err_t.
13017 (grub_elf64_load_hook_t): Likewise.
13018 * kern/elf.c: Call `grub_error_push' before `grub_error'. Improve
13021 2007-02-20 Hollis Blanchard <hollis@penguinppc.org>
13023 * kern/mm.c: Update copyright.
13024 (grub_mm_debug): Correct syntax error.
13025 (grub_mm_dump_free): New function.
13026 (grub_debug_free): Call `grub_free'.
13027 * include/grub/mm.h: Update copyright.
13028 (grub_mm_dump_free): Add declaration.
13030 2007-02-12 Hollis Blanchard <hollis@penguinppc.org>
13032 * include/grub/ieee1275/ieee1275.h: Update copyright.
13033 * kern/powerpc/ieee1275/init.c: Likewise.
13034 * kern/powerpc/ieee1275/openfw.c: Likewise.
13036 * loader/powerpc/ieee1275/linux.c: Likewise.
13037 * include/grub/elfload.h: Likewise.
13038 * kern/elf.c: Likewise.
13039 (grub_elf32_load): Pass `base' and `size' parameters. Update all
13041 (grub_elf64_load): Likewise.
13042 (grub_elf32_load_segment): Move to a nested function.
13043 (grub_elf64_load_segment): Likewise.
13045 2007-02-12 Hollis Blanchard <hollis@penguinppc.org>
13047 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): New
13049 * kern/powerpc/ieee1275/init.c (grub_heap_start): Removed.
13050 (grub_heap_len): Likewise.
13051 (HEAP_SIZE): New macro.
13052 (grub_claim_heap): New function.
13053 (grub_machine_init): Don't claim heap directly. Call
13055 * kern/powerpc/ieee1275/openfw.c: Include alloca.h.
13056 (grub_available_iterate): New function.
13058 2007-02-03 Thomas Schwinge <tschwinge@gnu.org>
13060 * aclocal.m4 (grub_CHECK_STACK_PROTECTOR): New definition.
13061 * configure.ac: Use it for testing the HOST and TARGET compilers.
13063 2006-12-13 Thomas Schwinge <tschwinge@gnu.org>
13065 * Makefile.in (enable_grub_emu): New variable.
13066 * configure.ac (--enable-grub-emu): New option.
13067 Do the checks for (n)curses only if `--enable-grub-emu' is requested.
13068 * conf/i386-efi.rmk (sbin_UTILITIES): Add `grub-emu' only if requested.
13069 * conf/i386-pc.rmk: Likewise.
13070 * conf/powerpc-ieee1275.rmk: Likewise.
13071 * conf/sparc64-ieee1275.rmk (bin_UTILITIES): Likewise.
13073 2006-12-12 Marco Gerards <marco@gnu.org>
13075 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_MENU'.
13077 * kern/env.c (grub_env_unset): Don't free the member `value' when
13078 the type is GRUB_ENV_VAR_DATA, in this case it's a user defined
13081 * normal/main.c (current_menu): Removed.
13082 (free_menu): Unset the `menu' environment variable.
13083 (grub_normal_menu_addentry): Make use of the environment variable
13084 `menu', instead of using the global `current_menu'. Allocate
13085 memory for the sourcecode of this entry.
13086 (read_config_file): New argument `nested', changed all callers.
13087 Only in the case of a new context, initialize a new menu. Set the
13088 `menu' environment variable.
13089 (grub_normal_execute): Don't set and unset the environment
13090 variable `menu' here anymore. Only free the menu when leaving the
13093 * util/i386/pc/biosdisk.c (linux_find_partition): Fixed a memory
13096 2006-12-11 Marco Gerards <marco@gnu.org>
13098 * normal/menu_entry.c (run): Fix off by one bug so the last line
13099 is executed. Move the loader check to outside the loop.
13101 2006-12-08 Hollis Blanchard <hollis@penguinppc.org>
13103 * kern/powerpc/ieee1275/cmain.c (cmain): Mark r3 and r4 as `UNUSED'.
13105 2006-11-25 Yoshinori K. Okuji <okuji@enbug.org>
13107 * util/i386/pc/grub-mkimage.c (generate_image): Fix the offset of
13108 the number of sectors. Reported by Andrey Shuvikov
13109 <mr_hyro@yahoo.com>.
13111 2006-11-11 Jeroen Dekkers <jeroen@dekkers.cx>
13113 * kern/disk.c (grub_disk_read): When there is a read error, always
13114 try to read only the necessary data.
13116 * conf/i386-pc.rmk (grub_probe_SOURCES): Add disk/lvm.c and
13118 * include/grub/disk.h [GRUB_UTIL] (grub_raid_init): New
13120 [GRUB_UTIL] (grub_raid_fini): Likewise.
13121 [GRUB_UTIL] (grub_lvm_init): Likewise.
13122 [GRUB_UTIL] (grub_lvm_fini): Likewise.
13123 * util/i386/pc/grub-probe.c (probe): Check whether DEVICE_NAME is
13124 RAID device and copy DEVICE_NAME to DRIVE_NAME in that case.
13125 (main): Call grub_raid_init(), grub_lvm_init(), grub_lvm_fini()
13126 and grub_raid_fini().
13128 2006-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
13130 * include/grub/types.h (__unused): Rename to UNUSED.
13131 * kern/elf.c (grub_elf32_size): Use UNUSED instead of __unused.
13132 (grub_elf64_size): Likewise.
13134 2006-11-03 Hollis Blanchard <hollis@penguinppc.org>
13136 * kern/elf.c (grub_elf_file): Call grub_file_seek. Call
13137 grub_error_push and grub_error_pop in the error-handling path.
13138 (grub_elf32_load_segment): Only call grub_file_read with non-zero
13141 2006-11-03 Hollis Blanchard <hollis@penguinppc.org>
13143 * conf/i386-efi.rmk (grub_emu_SOURCES): Add kern/elf.c.
13144 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
13145 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
13146 (kernel_elf_SOURCES): Likewise.
13147 * conf/i386-efi.rmk (kernel_mod_HEADERS): Add elfload.h and cache.h.
13148 * conf/i386-pc.rmk (kernel_mod_HEADERS): Likewise.
13149 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
13150 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
13151 * conf/common.rmk (pkgdata_MODULES): Add elf.mod.
13152 (elf_mod_SOURCES): New variable.
13153 (elf_mod_CFLAGS): Likewise.
13154 (elf_mod_LDFLAGS): Likewise.
13155 * include/grub/types.h (__unused): New macro.
13156 * include/grub/elfload.h: New file.
13157 * kern/elf.c: Likewise.
13158 * loader/powerpc/ieee1275/linux.c: Include elfload.h.
13159 (ELF32_LOADMASK): New macro.
13160 (ELF64_LOADMASK): Likewise.
13161 (vmlinux): Removed.
13162 (grub_linux_load32): New function.
13163 (grub_linux_load64): Likewise.
13164 (grub_rescue_cmd_linux): Call grub_linux_load32 or grub_linux_load64.
13165 Use grub_elf_t instead of grub_file_t.
13167 2006-11-02 Hollis Blanchard <hollis@penguinppc.org>
13169 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): Add
13170 `catch_result' to struct set_color_args.
13172 2006-10-28 Yoshinori K. Okuji <okuji@enbug.org>
13174 * normal/menu.c: Include grub/script.h.
13175 * normal/menu_entry.c: Likewise.
13176 * include/grub/normal.h: Do not include grub/script.h.
13178 2006-10-27 Hollis Blanchard <hollis@penguinppc.org>
13180 * kern/disk.c (grub_disk_read): Correct debug printf formatting.
13182 2006-10-27 Hollis Blanchard <hollis@penguinppc.org>
13184 * kern/disk.c (grub_disk_open): Print debug messages when opening a
13186 (grub_disk_close): Print debug messages when closing a disk.
13187 (grub_disk_read): Print debug messages when disk read fails.
13188 * kern/fs.c (grub_fs_probe): Print debug messages when detecting
13190 * kern/partition.c: Include misc.h.
13191 (grub_partition_iterate): Print debug messages when detecting
13194 2006-10-27 Hollis Blanchard <hollis@penguinppc.org>
13196 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Return error if `status'
13198 * kern/ieee1275/ieee1275.c (IEEE1275_IHANDLE_INVALID): Change to 0.
13200 2006-10-26 Hollis Blanchard <hollis@penguinppc.org>
13202 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
13203 Reverse GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS test.
13205 2006-10-25 Jeroen Dekkers <jeroen@dekkers.cx>
13207 * disk/lvm.c (grub_lvm_scan_device): Malloc sizeof(*lv) bytes
13208 instead of sizeof(lv). Patch by Michael Guntsche.
13210 2006-10-18 Jeroen Dekkers <jeroen@dekkers.cx>
13212 * disk/lvm.c: Rename VGS to VG_LIST.
13213 (grub_lvm_iterate): Change VGS->LV to VG-LV.
13214 (grub_lvm_open): Likewise.
13215 Thanks to Michael Guntsche for finding this bug.
13217 2006-10-15 Yoshinori K. Okuji <okuji@enbug.org>
13219 * configure.ac (AC_INIT): Bumped to 1.95.
13221 2006-10-14 Robert Millan <rmh@aybabtu.com>
13223 * util/i386/pc/getroot.c (grub_guess_root_device): Don't compare os_dev
13224 with "/dev/.static/dev/md".
13226 2006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
13228 * util/i386/pc/grub-probe.c (probe): Print DEVICE_NAME instead of
13229 DRIVE_NAME when grub_util_biosdisk_get_grub_dev fails. Open
13230 DRIVE_NAME instead of DEVICE_NAME. Make sure that DEVICE_NAME and
13231 DRIVE_NAME are always freed.
13233 * util/i386/pc/biosdisk.c (make_device_name): Add one into
13234 DOS_PART, as a DOS partition is counted from one instead of zero
13235 now. Reported by Robert Millan.
13237 2006-10-14 Robert Millan <rmh@aybabtu.com>
13239 * util/i386/pc/getroot.c (grub_guess_root_device): Stop using
13240 grub_util_biosdisk_get_grub_dev to convert system device to GRUB device.
13241 * util/grub-emu.c (main): Use grub_util_biosdisk_get_grub_dev with the
13242 string returned by grub_guess_root_device.
13243 * util/i386/pc/grub-setup.c: Likewise.
13244 * util/i386/pc/grub-probefs.c: Likewise.
13246 * util/i386/pc/grub-probefs.c: Rename to ...
13247 * util/i386/pc/grub-probe.c: ... this.
13248 * DISTLIST: Remove grub-probefs, add grub-probe.
13249 * conf/i386-efi.rmk: Likewise.
13250 * conf/i386-pc.rmk: Likewise.
13251 * util/i386/pc/grub-install.in: Likewise.
13253 * util/i386/pc/grub-probe.c: Add --target=(fs|device|drive) option to
13254 choose which information we want to print.
13256 2006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
13258 * DISTLIST: Added commands/echo.c, disk/lvm.c, disk/raid.c,
13259 include/grub/bitmap.h, include/grub/lvm.h, include/grub/raid.h,
13260 include/grub/i386/pc/vbeutil.h, include/grub/util/lvm.h,
13261 include/grub/util/raid.h, util/lvm.c, util/raid.c, video/bitmap.c,
13262 video/readers/tga.c and video/i386/pc/vbeutil.c.
13264 2006-10-14 Jeroen Dekkers <jeroen@dekkers.cx>
13266 Added support for RAID and LVM.
13268 * disk/lvm.c: New file.
13269 * disk/raid.c: Likewise.
13270 * include/grub/lvm.h: Likewise.
13271 * include/grub/raid.h: Likewise.
13272 * include/grub/util/lvm.h: Likewise.
13273 * include/grub/util/raid.h: Likewise.
13274 * util/lvm.c: Likewise.
13275 * util/raid.c: Likewise.
13277 * include/grub/disk.h (grub_disk_dev_id): Add
13278 GRUB_DISK_DEVICE_RAID_ID and GRUB_DISK_DEVICE_LVM_ID.
13279 (grub_disk_get_size): New prototype.
13280 * kern/disk.c (grub_disk_open): Check whether grub_partition_probe()
13281 returns a partition.
13282 (grub_disk_get_size): New function.
13284 * kern/i386/pc/init.c (make_install_device): Copy the prefix
13285 verbatim if grub_install_dos_part is -2.
13287 * util/i386/pc/getroot.c (grub_guess_root_device): Support RAID
13290 * util/i386/pc/grub-setup.c (setup): New argument
13291 MUST_EMBED. Force embedding of GRUB when the argument is
13292 true. Close FILE before returning.
13293 (main): Add support for RAID and LVM.
13295 * conf/common.rmk: Add RAID and LVM modules.
13296 * conf/i386-pc.rmk (grub_setup_SOURCES): Add util/raid.c and
13298 (grub_emu_SOURCES): Add disk/raid.c and disk/lvm.c.
13300 * kern/misc.c (grub_strstr): New function.
13301 * include/grub/misc.h (grub_strstr): New prototype.
13303 2006-10-10 Tristan Gingold <tristan.gingold@bull.net>
13305 * include/grub/efi/api.h (GRUB_EFI_ERROR_CODE): Long constant.
13307 2006-10-05 Tristan Gingold <tristan.gingold@bull.net>
13309 * kern/misc.c (grub_strtoull): Guess the base only if not
13312 2006-10-01 Hollis Blanchard <hollis@penguinppc.org>
13314 * kern/powerpc/ieee1275/cmain.c (cmain): Remove incomplete Old World
13317 2006-10-01 Hollis Blanchard <hollis@penguinppc.org>
13319 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Cast `size' to long.
13321 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_next_property):
13322 Remove `flags' argument. All callers changed.
13323 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_ROOT): Removed.
13324 (IEEE1275_IHANDLE_INVALID): New variable.
13325 (IEEE1275_CELL_INVALID): New variable.
13326 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
13327 grub_ieee1275_get_property_length, grub_ieee1275_instance_to_package,
13328 grub_ieee1275_package_to_path, grub_ieee1275_instance_to_path,
13329 grub_ieee1275_peer, grub_ieee1275_child, grub_ieee1275_open,
13330 grub_ieee1275_claim, grub_ieee1275_set_property): Error-check return
13331 codes from Open Firmware. All callers updated.
13332 (grub_ieee1275_next_property): Directly return Open Firmware return
13334 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
13335 Standardize error checking from `grub_ieee1275_get_property'.
13336 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Rename
13337 `devalias' to `aliases'. Correct comments. Consolidate error paths.
13339 2006-10-01 Hollis Blanchard <hollis@penguinppc.org>
13341 * kern/ieee1275/ieee1275.c (grub_ieee1275_instance_to_path): Rename
13342 `instance_to_package_args' to `instance_to_path_args'.
13344 * kern/powerpc/ieee1275/init.c (grub_machine_init): Use
13345 `grub_ieee1275_chosen'.
13347 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Call
13348 `grub_ieee1275_interpret'.
13350 2006-09-25 Hollis Blanchard <hollis@penguinppc.org>
13352 * util/powerpc/ieee1275/grub-mkimage.c: Include config.h.
13354 2006-09-25 Hollis Blanchard <hollis@penguinppc.org>
13356 * include/grub/powerpc/libgcc.h (__floatdisf): New prototype.
13357 (__cmpdi): Likewise.
13359 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Pass 0 as
13360 `flags' to `grub_ieee1275_next_property'. Change `pathlen' to type
13363 * kern/powerpc/ieee1275/cmain.c: Include grub/misc.h.
13365 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Change `actual'
13366 to type `grub_ssize_t'.
13367 (grub_rescue_cmd_linux): Cast -1 to `grub_off_t'.
13369 2006-09-22 Marco Gerards <marco@gnu.org>
13371 * normal/script.c (grub_script_create_cmdmenu): Skip leading
13374 2006-09-22 Marco Gerards <marco@gnu.org>
13376 * commands/echo.c: New file.
13378 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/echo.c'.
13380 * conf/common.rmk (echo_mod_SOURCES): New variable.
13381 (echo_mod_CFLAGS): Likewise.
13382 (echo_mod_LDFLAGS): Likewise.
13384 2006-09-22 Marco Gerards <marco@gnu.org>
13386 * normal/main.c (get_line): Malloc memory instead of using
13387 preallocated memory. Removed the arguments `cmdline' and
13388 `max_len'. Updated all callers.
13390 2006-09-22 Marco Gerards <marco@gnu.org>
13392 * conf/i386-efi.rmk (grub_emu_DEPENDENCIES): New variable.
13393 (normal_mod_DEPENDENCIES): Likewise.
13395 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Likewise.
13396 (normal_mod_DEPENDENCIES): Likewise.
13398 * conf/sparc64-ieee1275.rmk (normal_mod_DEPENDENCIES): Likewise.
13400 2006-09-22 Johan Rydberg <jrydberg@gnu.org>
13402 * genmk.rb: Add DEPENDENCIES variables to modules, utilities, and
13404 * conf/i386-pc.rmk (grub_emu_DEPENDENCIES): Declare.
13405 (normal_mod_DEPENDENCIES): Likewise.
13406 * conf/i386-pc.mk: Regenerate.
13407 * conf/i386-efi.mk: Likewise
13408 * conf/common.mk: Likewise.
13409 * conf/powerpc-ieee1275.mk: Likewise.
13410 * conf/sparc64-ieee1275.mk: Likewise.
13412 2006-09-22 Robert Millan <rmh@aybabtu.com>
13414 Sync with i386 version.
13415 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Remove grub-emu, add grub-mkimage.
13416 * conf/powerpc-ieee1275.rmk (sbin_UTILITIES): Remove grub-mkimage, add grub-emu.
13418 2006-09-21 Robert Millan <rmh@aybabtu.com>
13420 Import from GRUB Legacy (lib/device.c):
13421 * util/i386/pc/grub-mkdevicemap.c (get_i2o_disk_name): New function.
13422 (init_device_map) [__linux__]: Add support for I2O devices.
13424 2006-09-14 Marco Gerards <marco@gnu.org>
13426 * conf/i386-pc.rmk (COMMON_LDFLAGS): Use `-m32' instead of
13429 2006-09-14 Robert Millan <rmh@aybabtu.com>
13431 * util/i386/pc/grub-install.in: Skip menu.lst when removing
13434 * util/i386/pc/getroot.c: Don't recurse into dotdirs (e.g. ".static").
13436 * util/i386/pc/grub-mkdevicemap.c: Make sure the floppy device exists
13437 before adding it to device.map.
13439 2006-08-15 Johan Rydberg <jrydberg@gnu.org>
13441 * genmk.rb: Let GCC generate dependencies the first time it
13442 compiles a file; using the -MD option.
13443 * conf/common.mk: Regenerate.
13444 * conf/i386-pc.mk: Likewise.
13445 * conf/i386-efi.mk: Likewise.
13446 * conf/powerpc-ieee1275.mk: Likewise.
13447 * conf/sparc64-ieee1275.mk: Likewise.
13449 2006-08-04 Yoshinori K. Okuji <okuji@enbug.org>
13451 Move the prototypes of grub_setjmp and grub_longjmp to
13452 cpu/setjmp.h, so that each architecture may specify different
13455 * include/grub/i386/setjmp.h (grub_setjmp): New prototype.
13456 (grub_longjmp): Likewise.
13457 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise..
13458 (grub_longjmp): Likewise.
13459 * include/grub/sparc64/setjmp.h (grub_setjmp): Likewise..
13460 (grub_longjmp): Likewise.
13462 * include/grub/setjmp.h [!GRUB_UTIL] (grub_setjmp): Removed.
13463 [!GRUB_UTIL] (grub_longjmp): Removed.
13465 2006-08-01 Pelletier Vincent <subdino2004@yahoo.fr>
13467 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): IEEE1275
13468 "color!" method does not return any value.
13470 2006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
13472 * include/grub/bitmap.h: New file.
13474 * include/grub/i386/pc/vbeutil.h: Likewise.
13476 * video/bitmap.c: Likewise.
13478 * video/readers/tga.c: Likewise.
13480 * video/i386/pc/vbeutil.c: Likewise.
13482 * commands/videotest.c: Code cleanup and updated to reflect to new
13485 * term/gfxterm.c: Likewise.
13487 * video/video.c: Likewise.
13489 * conf/i386-pc.rmk (pkgdata_MODULES): Added tga.mod and bitmap.mod.
13490 (vbe_mod_SOURCES): Added video/i386/pc/vbeutil.c.
13491 (bitmap_mod_SOURCES): New entry.
13492 (bitmap_mod_CFLAGS): Likewise.
13493 (bitmap_mod_LDFLAGS): Likewise.
13494 (tga_mod_SOURCES): Likewise.
13495 (tga_mod_CFLAGS): Likewise.
13496 (tga_mod_LDFLAGS): Likewise.
13498 * include/grub/video.h (grub_video_blit_operators): New enum type.
13499 (grub_video_render_target): Changed as forward declaration and moved
13500 actual definition to be video driver specific.
13501 (grub_video_adapter.blit_bitmap): Added blitting operator.
13502 (grub_video_adapter.blit_render_target): Likewise.
13503 (grub_video_blit_bitmap): Likewise.
13504 (grub_video_blit_render_target): Likewise.
13506 * include/grub/i386/pc/vbe.h (grub_video_render_target): Added
13507 driver specific render target definition.
13508 (grub_video_vbe_map_rgba): Added driver internal helper.
13509 (grub_video_vbe_unmap_color): Updated to use
13510 grub_video_i386_vbeblit_info.
13511 (grub_video_vbe_get_video_ptr): Likewise.
13513 * include/grub/i386/pc/vbeblit.h
13514 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8): Updated to use
13515 grub_video_i386_vbeblit_info.
13516 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
13517 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
13518 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
13519 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
13520 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
13521 (grub_video_i386_vbeblit_index_index): Likewise.
13522 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): New blitter function.
13523 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
13524 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
13525 (grub_video_i386_vbeblit_blend): Added generic blitter for blend
13527 (grub_video_i386_vbeblit_replace): Added generic blitter for replace
13530 * video/i386/pc/vbeblit.c: Updated to reflect changes on
13531 include/grub/i386/pc/vbeblit.h.
13533 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8):
13534 Updated to use grub_video_i386_vbeblit_info.
13535 (grub_video_i386_vbefill_R8G8B8): Likewise.
13536 (grub_video_i386_vbefill_index): Likewise.
13537 (grub_video_i386_vbefill): Added generic filler.
13539 * video/i386/pc/vbefill.c: Updated to reflect changes on
13540 include/grub/i386/pc/vbefill.h.
13542 * video/i386/pc/vbe.c (grub_video_vbe_get_video_ptr): Updated to use
13543 grub_video_i386_vbeblit_info.
13544 (grub_video_vbe_unmap_color): Likewise.
13545 (grub_video_vbe_blit_glyph): Likewise.
13546 (grub_video_vbe_scroll): Likewise.
13547 (grub_video_vbe_draw_pixel): Removed function.
13548 (grub_video_vbe_get_pixel): Likewise.
13549 (grub_video_vbe_fill_rect): Moved all blitters to vbefill.c and
13550 updated code to use it.
13551 (common_blitter): Added common blitter for render target and bitmap.
13552 (grub_video_vbe_blit_bitmap): Updated to use common_blitter.
13553 (grub_video_vbe_blit_render_target): Likewise.
13555 2006-07-30 Johan Rydberg <jrydberg@gnu.org>
13557 * kern/efi/efi.c (grub_efi_set_text_mode): Assume console already
13558 is in text mode if there is no console control protocol instance
13561 2006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
13563 * include/grub/video.h: Code cleanup.
13565 * include/grub/i386/pc/vbe.h: Likewise.
13567 * video/i386/pc/vbe.c: Likewise.
13569 * video/i386/pc/vbeblit.c: Likewise.
13571 * video/i386/pc/vbefill.c: Likewise.
13573 * video/video.c: Likewise. Also added more comments.
13575 2006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
13577 * disk/i386/pc/biosdisk.c (struct grub_biosdisk_drp): Moved to ...
13578 (struct grub_biosdisk_dap): Likewise.
13580 * include/grub/i386/pc/biosdisk.h: ... to here. Also corrected
13581 linkage settings for all functions.
13583 2006-07-12 Marco Gerards <marco@gnu.org>
13585 * configure.ac (--enable-mm-debug): Fix typo.
13587 * genkernsyms.sh.in: Use proper quoting for `CC'.
13589 2006-07-02 Jeroen Dekkers <jeroen@dekkers.cx>
13591 * conf/i386-pc.rmk (COMMON_ASFLAGS): Add "-m32".
13592 (normal_mod_ASFLAGS): Remove "-m32".
13594 2006-06-14 Yoshinori K. Okuji <okuji@enbug.org>
13596 * util/misc.c: Include config.h.
13597 [!HAVE_MEMALIGN]: Do not include malloc.h.
13598 (grub_memalign): Use posix_memalign, if present. Then, use
13599 memalign, if present. Otherwise, emit an error.
13601 * util/grub-emu.c: Do not include malloc.h.
13603 * include/grub/util/misc.h: Include unistd.h. This is required for
13604 FreeBSD, because off_t is defined in unistd.h. Reported by Harley
13605 D. Eades III <hde@foobar-qux.org>.
13607 * configure.ac (AC_GNU_SOURCE): Added.
13608 (AC_CHECK_FUNCS): Check posix_memalign and memalign for the host
13611 2006-06-09 Yoshinori K. Okuji <okuji@enbug.org>
13613 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Make sure that
13614 ADDR_MAX does not exceed GRUB_LINUX_INITRD_MAX_ADDRESS.
13616 2006-06-07 Jeroen Dekkers <jeroen@dekkers.cx>
13618 * include/grub/types.h (grub_host_addr_t): Rename to
13619 grub_target_addr_t.
13620 (grub_host_off_t): Rename to grub_target_off_t.
13621 (grub_host_size_t): Rename to grub_target_size_t.
13622 (grub_host_ssize_t): Rename to grub_target_ssize_t.
13623 Refer to GRUB_TARGET_SIZEOF_VOID_P to define those variables.
13625 * include/grub/kernel.h (struct grub_module_header): Change type
13626 of OFFSET to grub_target_off_t and type of SIZE to grub_target_size_t.
13627 (grub_module_info): Likewise.
13629 2006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
13631 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): The conditional
13632 of checking LINUX_MEM_SIZE was reverse. Reported by Jesus
13633 Velazquez <jesus.velazquez@gmail.com>.
13635 2006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
13637 Count partitions from 1 instead of 0 in the string representation
13638 of partitions. Still use 0-based internally.
13640 * partmap/sun.c (grub_sun_is_valid): A cosmetic change.
13641 (sun_partition_map_iterate): Use grub_partition_t instead of
13642 struct grub_partition *. Cast DESC->START_CYLINDER to
13643 grub_uint64_t after converting the endian.
13644 (sun_partition_map_probe): Subtract 1 for PARTNUM.
13645 (sun_partition_map_get_name): Add 1 to P->INDEX.
13647 * partmap/pc.c (grub_partition_parse): Subtract 1 for
13649 (pc_partition_map_get_name): Add 1 into PCDATA->DOS_PART.
13651 * partmap/gpt.c (gpt_partition_map_iterate): Initialize PARTNO to
13652 zero instead of one.
13653 (gpt_partition_map_probe): Subtract 1 for PARTNUM.
13654 (gpt_partition_map_get_name): Add 1 into P->INDEX.
13656 * partmap/apple.c (apple_partition_map_iterate): Change the type
13657 of POS to unsigned.
13658 (apple_partition_map_probe): Subtract 1 for PARTNUM.
13659 (apple_partition_map_get_name): Add 1 into P->INDEX.
13661 * partmap/amiga.c (amiga_partition_map_iterate): Change the type
13662 of POS to unsigned.
13663 (amiga_partition_map_iterate): Cast NEXT to grub_off_t to
13664 calculate the offset of a partition.
13665 (amiga_partition_map_probe): Subtract 1 for PARTNUM.
13666 (amiga_partition_map_get_name): Add 1 into P->INDEX.
13668 * partmap/acorn.c (acorn_partition_map_find): Change the type of
13669 SECTOR to grub_disk_addr_t.
13670 (acorn_partition_map_iterate): Likewise.
13671 (acorn_partition_map_probe): Subtract 1 for PARTNUM.
13672 Change the type of SECTOR to grub_disk_addr_t. Declare P on the
13674 (acorn_partition_map_get_name): Add 1 into P->INDEX.
13676 * kern/i386/pc/init.c (make_install_device): Add 1 into
13677 GRUB_INSTALL_DOS_PART.
13679 * fs/iso9660.c (grub_iso9660_mount): Fixed a reversed
13682 2006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
13684 Clean up the code to support 64-bit addressing in disks and
13685 files. This change is not enough for filesystems yet.
13687 * util/i386/pc/grub-setup.c (struct boot_blocklist): Change the
13688 type of "start" to grub_uint64_t.
13689 (setup): Change the types of KERNEL_SECTOR and FIRST_SECTOR to
13690 grub_disk_addr_t * and grub_disk_addr_t. Fix the format string in
13691 save_first_sector and save_blocklists. Use grub_le_to_cpu64 to
13694 * util/i386/pc/biosdisk.c (open_device): Change the type of SECTOR
13695 to grub_disk_addr_t.
13697 * partmap/gpt.c (gpt_partition_map_iterate): Fix the format
13700 * partmap/pc.c (pc_partition_map_iterate): Likewise.
13702 * partmap/amiga.c (amiga_partition_map_iterate): Cast RDSK.MAGIC
13705 * normal/script.c (grub_script_parse): Remove unused MEMFREE.
13707 * normal/parser.y (YYLTYPE_IS_TRIVIAL): New macro.
13709 * normal/lexer.c (grub_script_yyerror): Specify unused to LEX.
13711 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf64): Cast -1
13712 to grub_off_t, to detect an error from grub_file_seek.
13713 (grub_multiboot_load_elf32): Likewise.
13715 * kern/misc.c (grub_strtoul): Use grub_strtoull. Return the
13716 maximum unsigned long value when an overflow is detected.
13717 (grub_strtoull): New function.
13718 (grub_divmod64): Likewise.
13719 (grub_lltoa): use grub_divmod64.
13721 * kern/fs.c (struct grub_fs_block): Change the type of "offset" to
13723 (grub_fs_blocklist_open): Increase P if P is not NULL to advance
13724 the pointer to next character. Use grub_strtoull instead of
13726 (grub_fs_blocklist_read): Change the types of SECTOR, OFFSET and
13727 SIZE to grub_disk_addr_t, grub_off_t and grub_size_t,
13730 * kern/file.c (grub_file_read): Prevent an overflow of LEN, as the
13731 return value is signed.
13732 (grub_file_seek): Change the type of OLD to grub_off_t. Do not
13733 test if OFFSET is less than zero, as OFFSET is unsigned now.
13735 * kern/disk.c (struct grub_disk_cache): Change the type of
13736 "sector" to grub_disk_addr_t.
13737 (grub_disk_cache_get_index): Change the type of SECTOR to
13738 grub_disk_addr_t. Calculate the hash with SECTOR casted to
13739 unsigned after shifting.
13740 (grub_disk_cache_invalidate): Change the type of SECTOR to
13742 (grub_disk_cache_unlock): Likewise.
13743 (grub_disk_cache_store): Likewise.
13744 (grub_disk_check_range): Change the types of SECTOR, OFFSET, SIZE,
13745 START and LEN to grub_disk_addr_t *, grub_off_t *, grub_size_t,
13746 grub_disk_addr_t and grub_uint64_t, respectively.
13747 (grub_disk_read): Use an unsigned variable REAL_OFFSET for the
13748 body, as the value of OFFSET is tweaked by
13749 grub_disk_check_range. Change the types of START_SECTOR, LEN and
13750 POS to grub_disk_addr_t, grub_size_t and grub_size_t,
13752 (grub_disk_write): Use an unsigned variable REAL_OFFSET for the
13753 body, as the value of OFFSET is tweaked by
13754 grub_disk_check_range. Change the types of LEN and N to
13757 * io/gzio.c (struct grub_gzio): Change the types of "data_offset"
13758 and "saved_offset" to grub_off_t.
13759 (test_header): Cast BUF to char *.
13760 (get_byte): Cast GZIO->DATA_OFFSET to grub_off_t. Cast GZIO->INBUF
13762 (grub_gzio_read): Change the types of OFFSET and SIZE to
13763 grub_off_t and grub_size_t, respectively.
13765 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_FORCE_LBA):
13767 (GRUB_BOOT_MACHINE_BOOT_DRIVE): Changed to 0x4c.
13768 (GRUB_BOOT_MACHINE_KERNEL_ADDRESS): Changed to 0x40.
13769 (GRUB_BOOT_MACHINE_KERNEL_SEGMENT): Changed to 0x42.
13770 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Changed to 0x4e.
13771 (GRUB_BOOT_MACHINE_LIST_SIZE): Increased to 12.
13773 * include/grub/types.h (grub_off_t): Unconditionally set to
13775 (grub_disk_addr_t): Changed to grub_uint64_t.
13777 * include/grub/partition.h (struct grub_partition): Change the
13778 types of "start", "len" and "offset" to grub_disk_addr_t,
13779 grub_uint64_t and grub_disk_addr_t, respectively.
13780 (grub_partition_get_start): Return grub_disk_addr_t.
13781 (grub_partition_get_len): Return grub_uint64_t.
13783 * include/grub/misc.h (grub_strtoull): New prototype.
13784 (grub_divmod64): Likewise.
13786 * include/grub/fshelp.h (grub_fshelp_read_file): Change the types
13787 of SECTOR, LEN and FILESIZE to grub_disk_addr_t, grub_size_t and
13788 grub_off_t, respectively.
13789 All callers and references changed.
13791 * include/grub/fs.h (struct grub_fs): Change the type of LEN to
13792 grub_size_t in "read".
13793 All callers and references changed.
13795 * include/grub/file.h (struct grub_file): Change the types of
13796 "offset" and "size" to grub_off_t and grub_off_t,
13797 respectively. Change the type of SECTOR to grub_disk_addr_t in
13799 (grub_file_read): Change the type of LEN to grub_size_t.
13800 (grub_file_seek): Return grub_off_t. Change the type of OFFSET to
13802 (grub_file_size): Return grub_off_t.
13803 (grub_file_tell): Likewise.
13804 All callers and references changed.
13806 * include/grub/disk.h (struct grub_disk_dev): Change the types of
13807 SECTOR and SIZE to grub_disk_addr_t and grub_size_t in "read" and
13809 (struct grub_disk): Change the type of "total_sectors" to
13810 grub_uint64_t. Change the type of SECTOR to grub_disk_addr_t in
13812 (grub_disk_read): Change the types of SECTOR, OFFSET and SIZE to
13813 grub_disk_addr_t, grub_off_t and grub_size_t, respectively.
13814 (grub_disk_write): Likewise.
13815 All callers and references changed.
13817 * fs/iso9660.c (grub_iso9660_susp_iterate): Cast parameters to
13818 char * for grub_strncmp to silence gcc.
13819 (grub_iso9660_mount): Likewise.
13820 (grub_iso9660_mount): Likewise.
13821 (grub_iso9660_read_symlink): Likewise. Also, remove the nonsense
13823 (grub_iso9660_iterate_dir): Likewise.
13824 (grub_iso9660_label): Cast DATA->VOLDESC.VOLNAME to char *.
13826 * fs/hfs.c (grub_hfs_read_file): Change the types of SECTOR and
13827 LEN to grub_disk_addr_t and grub_size_t, respectively.
13829 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
13831 * fs/jfs.c (grub_jfs_read_file): Likewise.
13833 * fs/minix.c (grub_jfs_read_file): Likewise.
13835 * fs/sfs.c (grub_jfs_read_file): Likewise.
13837 * fs/ufs.c (grub_jfs_read_file): Likewise.
13839 * fs/xfs.c (grub_jfs_read_file): Likewise.
13841 * fs/fat.c (grub_fat_read_data): Change the types of SECTOR, LEN
13842 and SIZE to grub_disk_addr_t, grub_size_t and grub_size_t,
13845 * fs/ext2.c (grub_ext2_read_block): When an error happens, set
13846 BLKNR to -1 instead of returning GRUB_ERRNO.
13847 (grub_ext2_read_file): Change the types of SECTOR and
13848 LEN to grub_disk_addr_t and grub_size_t, respectively.
13850 * fs/affs.c (grub_affs_read_file): Change the types of SECTOR and
13851 LEN to grub_disk_addr_t and grub_size_t, respectively.
13853 * font/manager.c (grub_font_get_glyph): Cast BITMAP to char * for
13856 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Fix the format
13857 string. Do not cast SECTOR explicitly.
13859 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): Change the type of
13860 TOTAL_SECTORS to grub_uint64_t. Do not mask DRP->TOTAL_SECTORS.
13861 (grub_biosdisk_rw): Change the types of SECTOR and SIZE to
13862 grub_disk_addr_t and grub_size_t, respectively. If the sector is
13863 over 2TB and LBA mode is not supported, raise an error.
13864 (get_safe_sectors): New function.
13865 (grub_biosdisk_read): Use get_safe_sectors.
13866 (grub_biosdisk_write): Likewise.
13868 * disk/efi/efidisk.c (grub_efidisk_read): Fix the format string.
13869 (grub_efidisk_write): Likewise.
13871 * disk/loopback.c (delete_loopback): Cosmetic changes.
13872 (grub_cmd_loopback): Likewise. Also, test NEWDEV->FILENAME
13874 (grub_loopback_open): Likewise.
13875 (grub_loopback_read): Likewise. Also, change the type of POS to
13876 grub_off_t, and fix the usage of grub_memset.
13878 * commands/i386/pc/play.c: Include grub/machine/time.h.
13880 * commands/ls.c (grub_ls_list_files): Use "llu" instead of "d" to
13883 * commands/configfile.c: Include grub/env.h.
13885 * commands/cmp.c (grub_cmd_cmp): Do not use ERR, but use
13886 GRUB_ERRNO directly instead. Change the type of POS to
13887 grub_off_t. Follow the coding standard.
13889 * commands/blocklist.c: Include grub/partition.h.
13890 (grub_cmd_blocklist): Return an error if the underlying device is
13891 not a disk. Take the starting sector of a partition into account,
13892 if a partition is used.
13894 * boot/i386/pc/diskboot.S (bootloop): Adapted to the new offset of
13896 (lba_mode): Support 64-bit addresses.
13897 (chs_mode): Likewise.
13898 (copy_buffer): Adapted to the new offsets of a length field and a
13900 (blocklist_default_start): Allocate 64-bit space.
13902 * boot/i386/pc/boot.S (force_lba): Removed.
13903 (boot_drive): Moved to under KERNEL_SECTOR.
13904 (kernel_sector): Moved to under KERNEL_SEGMENT. Allocate 64-bit
13906 (real_start): Set %si earlier. Remove code for FORCE_LBA, since it
13908 (lba_mode): Refactored to support a 64-bit address. More size
13910 (setup_sectors): Likewise.
13912 2006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
13914 * DISTLIST: Added include/grub/i386/linux.h. Removed
13915 include/grub/i386/pc/linux.h
13917 * configure.ac (AC_INIT): Bumped to 1.94.
13919 * config.guess: Updated from gnulib.
13920 * config.sub: Likewise.
13921 * install-sh: Likewise.
13922 * mkinstalldirs: Likewise.
13924 2006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
13926 * conf/common.rmk (grub_modules_init.lst): Depended on
13927 grub_emu_SOURCES, excluding grub_emu_init.c, instead of
13930 * genmk.rb (PModule::rule): Reverted the previous change.
13932 2006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
13934 * conf/common.rmk (grub_modules_init.lst): Depends on
13935 $(MODSRCFILES). Grep only the files in $(MODSRCFILES). Make sure
13936 that the target does not exist before producing.
13937 (grub_modules_init.h): Remove the target before generating.
13938 (grub_emu_init.c): Likewise.
13940 * genmk.rb (PModule::rule): Add source files into MODSRCFILES.
13942 2006-05-31 Jeroen Dekkers <jeroen@dekkers.cx>
13944 * configure.ac: Don't set host_m32 for x86_64. Also reset LIBS
13945 for the target-specific tests. Make sure that we also have the
13946 up-to-date target variables for those tests.
13948 2006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
13950 * genmk.rb (Image::rule): Prefix CFLAGS or ASFLAGS with TARGET_.
13951 (PModule::rule): Likewise.
13953 2006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
13955 * genmk.rb (Image::rule): Set FLAG to CFLAGS or ASFLAGS instead of
13956 TARGET_CFLAGS or TARGET_ASFLAGS. There is no reason why
13957 target-specific flags should be prefixed.
13958 (PModule::rule): Likewise.
13960 2006-05-30 Yoshinori K. Okuji <okuji@enbug.org>
13962 * configure.ac (CMP): Check if cmp is available explicitly.
13964 2006-05-29 Yoshinori K. Okuji <okuji@enbug.org>
13966 * util/powerpc/ieee1275/grub-install.in (host_cpu): Removed.
13967 (target_cpu): New variable.
13968 (pkglibdir): Use target_cpu instead of host_cpu.
13970 * util/i386/pc/grub-install.in (host_cpu): Removed.
13971 (target_cpu): New variable.
13972 (pkglibdir): Use target_cpu instead of host_cpu.
13974 * util/genmoddep.c: Removed.
13976 * kern/efi/mm.c (filter_memory_map): Use GRUB_CPU_SIZEOF_VOID_P
13977 instead of GRUB_HOST_SIZEOF_VOID_P.
13978 * kern/dl.c: Likewise.
13980 * include/grub/i386/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed to
13982 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
13983 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
13984 (GRUB_TARGET_SIZEOF_LONG): ... this.
13985 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
13986 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
13987 * include/grub/powerpc/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
13989 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
13990 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
13991 (GRUB_TARGET_SIZEOF_LONG): ... this.
13992 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
13993 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
13994 * include/grub/sparc64/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
13996 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
13997 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
13998 (GRUB_TARGET_SIZEOF_LONG): ... this.
13999 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
14000 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
14002 * include/grub/types.h [!GRUB_UTIL] (GRUB_CPU_SIZEOF_VOID_P): Use
14003 GRUB_TARGET_SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P.
14004 [!GRUB_UTIL] (GRUB_CPU_SIZEOF_LONG): Use GRUB_TARGET_SIZEOF_LONG
14005 instead of GRUB_HOST_SIZEOF_LONG.
14006 [!GRUB_UTIL]: Refer to GRUB_TARGET_WORDS_BIGENDIAN instead of
14007 GRUB_HOST_WORDS_BIGENDIAN to define or undefine
14008 GRUB_CPU_WORDS_BIGENDIAN.
14009 Refer to SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P to
14010 define grub_host_addr_t, grub_host_off_t, grub_host_size_t and
14013 * conf/i386-efi.rmk (noinst_UTILITIES): Removed.
14014 (genmoddep_SOURCES): Likewise.
14015 * conf/i386-pc.rmk (noinst_UTILITIES): Likewise.
14016 (genmoddep_SOURCES): Likewise.
14017 * conf/conf/powerpc-ieee1275.rmk (noinst_UTILITIES): Likewise.
14018 (genmoddep_SOURCES): Likewise.
14019 * conf/conf/conf/sparc64-ieee1275.rmk (noinst_UTILITIES):
14021 (genmoddep_SOURCES): Likewise.
14023 * genmoddep.awk: New file.
14025 * genmk.rb (Image::rule): Use TARGET_CC, TARGET_CPPFLAGS,
14026 TARGET_CFLAGS, TARGET_ASFLAGS and TARGET_LDFLAGS instead of CC,
14027 CPPFLAGS, CFLAGS, ASFLAGS and LDFLAGS, respectively.
14028 (PModule::rule): Likewise.
14029 (Program::rule): Likewise.
14030 (Utility::rule): Use CC, CPPFLAGS, CFLAGS and LDFLAGS instead of
14031 BUILD_CC, BUILD_CPPFLAGS, BUILD_CFLAGS and BUILD_LDFLAGS,
14034 * configure.ac: Rewritten intensively to use host and target
14035 instead of build and host, respectively.
14037 * Makefile.in (pkglibdir): Use target_cpu instead of host_cpu.
14038 (host_cpu): Removed.
14039 (target_cpu): New variable.
14040 (CPPFLAGS): Added @CPPFLAGS@ and -DGRUB_LIBDIR=\"$(pkglibdir)\".
14041 (BUILD_CC): Removed.
14042 (BUILD_CFLAGS): Likewise.
14043 (BUILD_CPPFLAGS): Likewise.
14044 (TARGET_CC): New variable.
14045 (TARGET_CFLAGS): Likewise.
14046 (TARGET_CPPFLAGS): Likewise.
14047 (TARGET_LDFLAGS): Likewise.
14049 (include): Use target_cpu instead of host_cpu.
14050 (moddep.lst:): Use genmoddep.awk instead of genmoddep.
14052 * DISTLIST: Added genmoddep.awk. Removed util/genmoddep.c.
14054 2006-05-29 Vesa Jaaskelainen <chaac@nic.fi>
14056 * include/grub/script.h (grub_script_cmdif): Renamed field 'bool' to
14057 'exec_to_evaluate'. Renamed field 'true' to 'exec_on_true'. Renamed
14058 field 'false' to 'exec_on_false'.
14059 (grub_script_create_cmdif): Renamed argument names to reflect above
14062 * normal/execute.c (grub_script_execute_cmdif): Likewise.
14064 * normal/script.c (grub_script_create_cmdif): Likewise.
14066 2006-05-28 Yoshinori K. Okuji <okuji@enbug.org>
14068 * fs/hfsplus.c (grub_hfsplus_btree_recoffset): Moved to near the
14070 (grub_hfsplus_btree_recptr): Likewise.
14071 (grub_hfsplus_find_block): Do not take RETRY any longer. Use
14072 FILEBLOCK both to pass a block number and store next block
14074 (grub_hfsplus_read_block): Rewritten heavily to support an extent
14075 overflow file correctly. Specify errors appropriately, because
14076 fshelp expects that GRUB_ERRNO is set when fails. Reuse
14077 grub_hfsplus_btree_recptr to get the pointer to a found key.
14078 (grub_hfsplus_btree_search): Return 1 instead of 0 when no match
14081 * conf/i386-efi.rmk (pkgdata_MODULES): Added _linux.mod and
14083 (_linux_mod_SOURCES): New variable.
14084 (_linux_mod_CFLAGS): Likewise.
14085 (_linux_mod_LDFLAGS): Likewise.
14086 (linux_mod_SOURCES): Likewise.
14087 (linux_mod_CFLAGS): Likewise.
14088 (linux_mod_LDFLAGS): Likewise.
14090 * DISTLIST: Added loader/i386/efi/linux.c,
14091 loader/i386/efi/linux_normal.c and
14092 include/grub/i386/efi/loader.h.
14094 * loader/i386/efi/linux.c: New file.
14095 * loader/i386/efi/linux_normal.c: Likewise.
14096 * include/grub/i386/efi/loader.h: Likewise.
14098 2006-05-27 Yoshinori K. Okuji <okuji@enbug.org>
14100 * commands/blocklist.c: New file.
14102 * DISTLIST: Added commands/blocklist.c.
14104 * term/efi/console.c (grub_console_highlight_color): Use a lighter
14105 color for the background, and a darker color for the foreground.
14106 (grub_console_checkkey): Return READ_KEY.
14107 (grub_console_cls): Set the background to
14108 GRUB_EFI_BACKGROUND_BLACK temporarily to clean out the screen.
14110 * kern/efi/efi.c (grub_efi_exit_boot_services): New function.
14112 * include/grub/i386/linux.h (struct linux_kernel_params): Fixed
14113 the size of "padding5", "hd0_drive_info" and "hd1_drive_info".
14115 * include/grub/efi/efi.h (grub_efi_exit_boot_services): New
14118 * include/grub/efi/api.h (GRUB_EFI_TEXT_ATTR): Do not shift
14119 BG. The spec is wrong again.
14121 * include/grub/normal.h [GRUB_UTIL] (grub_blocklist_init): New
14123 [GRUB_UTIL] (grub_blocklist_fini): Likewise.
14125 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
14126 commands/blocklist.c.
14127 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
14129 * conf/common.rmk (pkgdata_MODULES): Added blocklist.mod.
14130 (blocklist_mod_SOURCES): New variable.
14131 (blocklist_mod_CFLAGS): Likewise.
14132 (blocklist_mod_LDFLAGS): Likewise.
14134 2006-05-20 Yoshinori K. Okuji <okuji@enbug.org>
14136 * boot/i386/pc/boot.S (real_start): Set %si earlier to eliminate
14138 (lba_mode): Use %eax more intensively to reduce the code size.
14140 2006-05-20 Marco Gerards <marco@gnu.org>
14142 * normal/lexer.c (grub_script_yylex): Don't filter out newlines.
14144 * normal/parser.y (commandblock): Defined as <cmd>. A subroutine
14146 (script): Accept leading newlines.
14147 (newlines): New rule to describe 0 or more newlines.
14148 (commands): Accept `command' with trailing newline. Fixed the
14149 order in which arguments were passed to `grub_script_add_cmd'.
14150 Accept commands separated by newlines.
14151 (function): Changed to accept newlines.
14152 (menuentry) Rewritten.
14154 * normal/script.c (grub_script_create_cmdmenu): Add new entries in
14155 front of the list, instead of to the end.
14157 2006-05-19 Yoshinori K. Okuji <okuji@enbug.org>
14159 * util/i386/pc/grub-install.in (bindir): New variable.
14160 (grub_mkimage): Use BINDIR instead of SBINDIR. Reported by Lee
14161 Shaver <lbgwjl@gmail.com>.
14163 2006-05-14 Yoshinori K. Okuji <okuji@enbug.org>
14165 * kern/i386/pc/startup.S: Include grub/cpu/linux.h instead of
14166 grub/machine/linux.h
14167 * loader/i386/pc/linux.c: Likewise.
14169 * include/grub/i386/pc/linux.h: Moved to ...
14170 * include/grub/i386/linux.h: ... here.
14172 * include/grub/i386/linux.h (struct linux_kernel_params): New
14175 2006-05-09 Vesa Jaaskelainen <chaac@nic.fi>
14177 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Corrected bounds
14179 (grub_video_vbe_blit_glyph): Likewise.
14180 (grub_video_vbe_blit_bitmap): Likewise.
14181 (grub_video_vbe_blit_render_target): Likewise.
14183 2006-05-09 Yoshinori K. Okuji <okuji@enbug.org>
14185 * configure.ac (--with-platform): Properly quote the square
14188 2006-05-08 Marco Gerards <marco@gnu.org>
14190 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Renamed from
14192 (kernel_elf_HEADERS): ...to this. Updated all users.
14193 (grubof_symlist.c): Renamed from this...
14194 (kernel_elf_symlist.c): ...to this. Updated all users.
14195 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
14196 (grubof_SOURCES): Renamed from this...
14197 (kernel_elf_SOURCES): ...to this.
14198 (grubof_HEADERS): Renamed from this...
14199 (kernel_elf_HEADERS): ...to this.
14200 (grubof_CFLAGS): Renamed from this...
14201 (kernel_elf_CFLAGS): ...to this.
14202 (grubof_ASFLAGS): Renamed from this...
14203 (kernel_elf_ASFLAGS): ...to this.
14204 (grubof_LDFLAGS): Renamed from this...
14205 (kernel_elf_LDFLAGS): ...to this.
14207 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Renamed from
14209 (kernel_elf_HEADERS): ...to this. Updated all users.
14210 (grubof_symlist.c): Renamed from this...
14211 (kernel_elf_symlist.c): ...to this. Updated all users.
14212 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
14213 (grubof_SOURCES): Renamed from this...
14214 (kernel_elf_SOURCES): ...to this.
14215 (grubof_HEADERS): Renamed from this...
14216 (kernel_elf_HEADERS): ...to this.
14217 (grubof_CFLAGS): Renamed from this...
14218 (kernel_elf_CFLAGS): ...to this.
14219 (grubof_ASFLAGS): Renamed from this...
14220 (kernel_elf_ASFLAGS): ...to this.
14221 (grubof_LDFLAGS): Renamed from this...
14222 (kernel_elf_LDFLAGS): ...to this.
14224 * util/powerpc/ieee1275/grub-mkimage.c (add_segments): Use
14225 `kernel.elf' instead of `grubof'.
14227 2006-05-08 Yoshinori K. Okuji <okuji@enbug.org>
14229 Add --with-platform to configure. Use pkglibdir instead of
14230 pkgdatadir. This is reported by Roger Leigh.
14232 * util/powerpc/ieee1275/grub-install.in (datadir): Removed.
14233 (host_vendor): Likewise.
14234 (host_os): Likewise.
14235 (pkgdatadir): Likewise.
14236 (platform): New variable.
14237 (pkglibdir): Likewise.
14238 Use PKGLIBDIR instead of PKGDATADIR.
14240 * util/i386/pc/grub-install.in (datadir): Removed.
14241 (host_vendor): Likewise.
14242 (host_os): Likewise.
14243 (pkgdatadir): Likewise.
14244 (platform): New variable.
14245 (pkglibdir): Likewise.
14246 Use PKGLIBDIR instead of PKGDATADIR.
14248 * util/powerpc/ieee1275/grub-mkimage.c (usage): Use GRUB_LIBDIR
14249 instead of GRUB_DATADIR.
14251 * util/i386/pc/grub-mkimage.c (usage): Likewise.
14253 * util/i386/efi/grub-mkimage.c (usage): Likewise.
14256 * configure.ac (--with-platform): New option.
14257 Use PLATFORM instead of HOST_VENDOR to specify a platform.
14259 * Makefile.in: Include a makefile based on PLATFORM instead of
14261 (pkgdatadir): Not appended by the machine type.
14262 (pkglibdir): Appended by the machine type.
14263 (host_vendor): Removed.
14264 (platform): New variable.
14265 (BUILD_CPPFLAGS): Specify GRUB_LIBDIR instead of GRUB_DATADIR.
14266 (install-local): Use PKGLIBDIR instead of PKGDATADIR.
14267 (uninstall): Likewise.
14269 2006-05-07 Yoshinori K. Okuji <okuji@enbug.org>
14271 Use the environment context in the menu. Remove the commands
14272 "default" and "timeout", and use variables instead.
14274 * normal/menu.c: Include grub/env.h.
14275 (print_entry): Cast TITLE to silence gcc.
14276 (get_timeout): New function.
14277 (set_timeout): Likewise.
14278 (get_entry_number): Likewise.
14279 (run_menu): Use a default entry, a fallback entry and a timeout
14280 in the environment variables "default", "fallback" and
14281 "timeout". Also, tweak the default entry if it is not within the
14282 current menu entries.
14283 (grub_menu_run): Use a fallback entry in the environment variable
14286 * normal/main.c (read_config_file): Do not initialize
14287 NEWMENU->DEFAULT_ENTRY, NEWMENU->FALLBACK_ENTRY or
14289 (grub_normal_execute): Use a data slot to store the menu.
14291 * include/grub/normal.h (struct grub_menu): Removed default_entry,
14292 fallback_entry and timeout.
14293 (struct grub_menu_list): Removed.
14294 (grub_menu_list_t): Likewise.
14295 (struct grub_context): Likewise.
14296 (grub_context_t): Likewise.
14297 (grub_context_get): Likewise.
14298 (grub_context_get_current_menu): Likewise.
14299 (grub_context_push_menu): Likewise.
14300 (grub_context_pop_menu): Likewise.
14301 (grub_default_init): Likewise.
14302 (grub_default_fini): Likewise.
14303 (grub_timeout_init): Likewise.
14304 (grub_timeout_fini): Likewise.
14306 * conf/sparc64-ieee1275.rmk (pkgdata_MODULES): Removed default.mod
14308 (normal_mod_SOURCES): Removed normal/context.c.
14310 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Removed
14311 commands/default.c, commands/timeout.c and normal/context.c.
14312 (normal_mod_SOURCES): Removed normal/context.c.
14314 * conf/i386-pc.rmk (grub_emu_SOURCES): Removed commands/default.c,
14315 commands/timeout.c and normal/context.c.
14316 (normal_mod_SOURCES): Removed normal/context.c.
14318 * conf/i386-efi.rmk (grub_emu_SOURCES): Removed
14319 commands/default.c, commands/timeout.c and normal/context.c.
14320 (normal_mod_SOURCES): Removed normal/context.c.
14322 * conf/common.rmk (pkgdata_MODULES): Removed default.mod and
14324 (default_mod_SOURCES): Removed.
14325 (default_mod_CFLAGS): Likewise.
14326 (default_mod_LDFLAGS): Likewise.
14327 (timeout_mod_SOURCES): Removed.
14328 (timeout_mod_CFLAGS): Likewise.
14329 (timeout_mod_LDFLAGS): Likewise.
14331 * DISTLIST: Removed commands/default.c, commands/timeout.c and
14334 * commands/default.c: Removed.
14335 * commands/timeout.c: Likewise.
14336 * normal/context.c: Likewise.
14338 2006-05-07 Vesa Jaaskelainen <chaac@nic.fi>
14340 * kern/i386/pc/startup.S (grub_exit): Added missing .code32 tag.
14342 2006-05-02 Yoshinori K. Okuji <okuji@enbug.org>
14344 * kern/env.c (struct grub_env_context): Removed "sorted". Renamed
14345 "next" to "prev" for readability.
14346 (struct grub_env_sorted_var): New struct.
14347 (grub_env_context): Renamed to ...
14348 (initial_context): ... this.
14349 (grub_env_var_context): Renamed to ...
14350 (current_context): ... this.
14351 (grub_env_find): Look only at CURRENT_CONTEXT.
14352 (grub_env_context_open): Rewritten to copy exported variables from
14354 (grub_env_context_close): Rewritten according to the new
14355 scheme. Also, add an assertion to prevent the initial context from
14357 (grub_env_insert): Removed the code for the sorted list.
14358 (grub_env_remove): Likewise.
14359 (grub_env_export): Simply mark the variable with
14360 GRUB_ENV_VAR_GLOBAL.
14361 (grub_env_set): A cosmetic change for naming consistency.
14362 (grub_env_get): Likewise.
14363 (grub_env_unset): Likewise.
14364 (grub_env_iterate): Rewritten to sort variables within this
14366 (grub_register_variable_hook): Fixed for naming consistency. Call
14367 grub_env_find again, only if NAME is not found at the first time.
14368 (mangle_data_slot_name): New function.
14369 (grub_env_set_data_slot): Likewise.
14370 (grub_env_get_data_slot): Likewise.
14371 (grub_env_unset_data_slot): Likewise.
14373 * include/grub/env.h (grub_env_var_type): New enum.
14374 (GRUB_ENV_VAR_LOCAL): New constant.
14375 (GRUB_ENV_VAR_GLOBAL): Likewise.
14376 (GRUB_ENV_VAR_DATA): Likewise.
14377 (struct grub_env_var): Removed "sort_next" and "sort_prevp". Added
14379 (grub_env_set): Replace VAR with NAME for consistency.
14380 (grub_register_variable_hook): Likewise.
14381 (grub_env_export): Specify the name of the argument.
14382 (grub_env_set_data_slot): New prototype.
14383 (grub_env_get_data_slot): Likewise.
14384 (grub_env_unset_data_slot): Likewise.
14386 2006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
14388 Extend the loader so that GRUB can accept a loader which comes
14389 back to GRUB when a loaded image exits. Also, this change adds
14390 support for a chainloader on EFI.
14392 * term/efi/console.c: Include grub/misc.h.
14393 (grub_console_checkkey): Display a scan code on the top for
14394 debugging. This will be removed once the EFI port gets stable.
14395 Correct the scan code mapping.
14397 * kern/efi/mm.c (sort_memory_map): Sort in a descending order to
14398 allocate memory from larger regions, in order to reduce the number
14399 of allocated regions. Otherwise, the MacOSX loader panics.
14400 (filter_memory_map): Avoid less than 1MB for compatibility with
14402 (add_memory_regions): Allocate from the tail of a region, if
14403 possible, to avoid allocating a region near to 1MB, for the MacOSX
14406 * kern/efi/init.c (grub_efi_set_prefix): Specify
14407 GRUB_EFI_IMAGE_HANDLE to grub_efi_get_loaded_image.
14409 * kern/efi/efi.c (grub_efi_get_loaded_image): Accept a new
14410 argument IMAGE_HANDLE and specify it to get a loaded image.
14411 (grub_arch_modules_addr): Specify GRUB_EFI_IMAGE_HANDLE to
14412 grub_efi_get_loaded_image.
14413 (grub_efi_get_filename): Divide the length by the size of
14415 (grub_efi_get_device_path): New function.
14416 (grub_efi_print_device_path): Print End Device Path nodes. Divide
14417 the length by the size of grub_efi_char16_t for a file path device
14420 * kern/loader.c (grub_loader_noreturn): New variable.
14421 (grub_loader_set): Accept a new argument NORETURN. Set
14422 GRUB_LOADER_NORETURN to NORETURN.
14423 All callers changed.
14424 (grub_loader_boot): If GRUB_LOADER_NORETURN is false, do not call
14427 * include/grub/efi/efi.h (grub_efi_get_device_path): New
14429 (grub_efi_get_loaded_image): Take an argument to specify an image
14432 * include/grub/loader.h (grub_loader_set): Added one more argument
14435 * disk/efi/efidisk.c (make_devices): Use grub_efi_get_device_path
14436 instead of grub_efi_open_protocol.
14437 (grub_efidisk_get_device_name): Likewise.
14438 (grub_efidisk_close): Print a newline.
14439 (grub_efidisk_get_device_handle): Fixed to use
14440 GRUB_EFI_DEVICE_PATH_SUBTYPE instead of
14441 GRUB_EFI_DEVICE_PATH_TYPE.
14443 * disk/efi/efidisk.c (device_path_guid): Moved to ...
14444 * kern/efi/efi.c (device_path_guid): ... here.
14446 * conf/i386-efi.rmk (pkgdata_MODULES): Added _chain.mod and
14448 (kernel_mod_HEADERS): Added efi/disk.h.
14449 (_chain_mod_SOURCES): New variable.
14450 (_chain_mod_CFLAGS): Likewise.
14451 (_chain_mod_LDFLAGS): Likewise.
14452 (chain_mod_SOURCES): Likewise.
14453 (chain_mod_CFLAGS): Likewise.
14454 (chain_mod_LDFLAGS): Likewise.
14456 * DISTLIST: Added include/grub/efi/chainloader.h,
14457 loader/efi/chainloader.c and loader/efi/chainloader_normal.c.
14459 * include/grub/efi/chainloader.h: New file.
14460 * loader/efi/chainloader.c: Likewise.
14461 * loader/efi/chainloader_normal.c: Likewise.
14463 2006-04-30 Marco Gerards <marco@gnu.org>
14465 * commands/configfile.c (grub_cmd_source): New function.
14466 (GRUB_MOD_INIT): Register the commands `source' and `.'.
14467 (GRUB_MOD_FINI): De-register the commands `source' and `.'.
14469 2006-04-30 Marco Gerards <marco@gnu.org>
14471 * normal/execute.c (grub_script_execute_cmd): Change the return
14472 type to `grub_err_t'. Correctly return the error.
14473 (grub_script_execute_cmdline): In case a command line is not a
14474 command or a function, try to interpret it as an assignment.
14476 2006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
14478 * fs/hfsplus.c (grub_hfsplus_read_block): Fixed a memory leak.
14479 (grub_hfsplus_iterate_dir): Reordered to skip unknown nodes. Also,
14480 skip a node whose name is obviously invalid as UTF-16,
14481 i.e. contains a NUL character. Stop the iteration when the last
14482 directory entry is found. Instead of using the return value of
14483 grub_hfsplus_btree_iterate_node, store the value in RET and use
14484 it, because the iterator can be stopped by the last directory
14487 2006-04-30 Marco Gerards <marco@gnu.org>
14489 * include/grub/env.h (grub_env_export): New prototype. Reported
14490 by Jan C. Kleinsorge <jan.kleinsorge@udo.edu>.
14492 2006-04-30 Marco Gerards <marco@gnu.org>
14494 * fs/hfsplus.c (grub_hfsplus_iterate_dir): Correctly calculate the
14495 size of the extents in a catalog file record.
14497 2006-04-29 Marco Gerards <marco@gnu.org>
14499 * commands/configfile.c (grub_cmd_configfile): Execute the
14500 configfile within its own context.
14502 * include/grub/env.h (grub_env_context_open): New prototype.
14503 (grub_env_context_close): Likewise.
14505 * kern/env.c (grub_env): Removed.
14506 (grub_env_sorted): Likewise.
14507 (grub_env_context): New variable.
14508 (grub_env_var_context): Likewise.
14509 (grub_env_find): Search both the active context and the global
14511 (grub_env_context_open): New function.
14512 (grub_env_context_close): Likewise.
14513 (grub_env_insert): Likewise.
14514 (grub_env_remove): Likewise.
14515 (grub_env_export): Likewise.
14516 (grub_env_set): Changed to use helper functions to avoid code
14518 (grub_env_iterate): Rewritten so both the current context and the
14519 global context are being used.
14521 * normal/command.c (export_command): New function.
14522 (grub_command_init): Register the `export' function.
14524 2006-04-26 Yoshinori K. Okuji <okuji@enbug.org>
14526 * util/i386/pc/grub-mkimage.c (compress_kernel): Cast arguments
14527 explicitly to suppress gcc's warnings.
14528 * fs/fat.c (grub_fat_find_dir): Likewise.
14529 (grub_fat_label): Likewise.
14530 * fs/xfs.c (grub_xfs_read_inode): Likewise.
14531 (grub_xfs_mount): Likewise.
14532 (grub_xfs_label): Likewise.
14533 * fs/affs.c (grub_affs_mount): Likewise.
14534 (grub_affs_label): Likewise.
14535 (grub_affs_iterate_dir): Likewise.
14536 * fs/sfs.c (grub_sfs_mount): Likewise.
14537 (grub_sfs_iterate_dir): Likewise.
14538 * fs/ufs.c (grub_ufs_lookup_symlink): Likewise.
14539 * fs/hfs.c (grub_hfs_mount): Likewise.
14540 (grub_hfs_cmp_catkeys): Likewise.
14541 (grub_hfs_find_dir): Likewise.
14542 (grub_hfs_dir): Likewise.
14543 (grub_hfs_label): Likewise.
14544 * fs/jfs.c (grub_jfs_mount): Likewise.
14545 (grub_jfs_opendir): Likewise.
14546 (grub_jfs_getent): Likewise.
14547 (grub_jfs_lookup_symlink): Likewise.
14548 (grub_jfs_label): Likewise.
14549 * fs/hfsplus.c (grub_hfsplus_cmp_catkey): Likewise.
14550 (grub_hfsplus_iterate_dir): Likewise.
14551 (grub_hfsplus_btree_iterate_node): Made static.
14553 * util/grub-emu.c (prefix): New variable.
14554 (grub_machine_set_prefix): New function.
14555 (main): Do not set the environment variable "prefix" here. Only
14556 set PREFIX, which is used later by grub_machine_set_prefix.
14558 * include/grub/video.h: Do not include grub/symbol.h.
14559 (grub_video_register): Not exported. This symbol is not defined in
14561 (grub_video_unregister): Likewise.
14562 (grub_video_iterate): Likewise.
14563 (grub_video_setup): Likewise.
14564 (grub_video_restore): Likewise.
14565 (grub_video_get_info): Likewise.
14566 (grub_video_get_blit_format): Likewise.
14567 (grub_video_set_palette): Likewise.
14568 (grub_video_get_palette): Likewise.
14569 (grub_video_set_viewport): Likewise.
14570 (grub_video_get_viewport): Likewise.
14571 (grub_video_map_color): Likewise.
14572 (grub_video_map_rgb): Likewise.
14573 (grub_video_map_rgba): Likewise.
14574 (grub_video_fill_rect): Likewise.
14575 (grub_video_blit_glyph): Likewise.
14576 (grub_video_blit_bitmap): Likewise.
14577 (grub_video_blit_render_target): Likewise.
14578 (grub_video_scroll): Likewise.
14579 (grub_video_swap_buffers): Likewise.
14580 (grub_video_create_render_target): Likewise.
14581 (grub_video_delete_render_target): Likewise.
14582 (grub_video_set_active_render_target): Likewise.
14584 * include/grub/symbol.h [GRUB_SYMBOL_GENERATOR] (EXPORT_FUNC):
14586 [GRUB_SYMBOL_GENERATOR] (EXPORT_VAR): Likewise.
14588 * conf/sparc64-ieee1275.rmk (grubof_symlist.c): Depended on
14589 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
14590 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
14591 instead of $(srcdir)/genkernsyms.sh.
14593 * conf/powerpc-ieee1275.rmk (grubof_symlist.c): Depended on
14594 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
14595 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
14596 instead of $(srcdir)/genkernsyms.sh.
14598 * conf/i386-pc.rmk (symlist.c): Depended on config.h. Use
14599 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
14600 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
14601 instead of $(srcdir)/genkernsyms.sh.
14603 * conf/i386-efi.rmk (symlist.c): Depended on config.h. Use
14604 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
14605 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
14606 instead of $(srcdir)/genkernsyms.sh.
14608 * configure.ac (AC_CONFIG_FILES): Added gensymlist.sh and
14611 * Makefile.in (DISTCLEANFILES): Added gensymlist.sh and
14613 (gensymlist.sh): New target.
14614 (genkernsyms.sh): Likewise.
14616 * DISTLIST: Removed genkernsyms.sh and gensymlist.sh. Added
14617 genkernsyms.sh.in and gensymlist.sh.in.
14619 * genkernsyms.sh: Removed.
14620 * gensymlist.sh: Likewise.
14622 * genkernsyms.sh.in: New file.
14623 * gensymlist.sh.in: Likewise.
14625 2006-04-25 Hollis Blanchard <hollis@penguinppc.org>
14627 * kern/powerpc/ieee1275/init.c (grub_machine_set_prefix): Do not
14628 clobber "prefix", since we may have already set it manually.
14630 2006-04-25 Hollis Blanchard <hollis@penguinppc.org>
14632 * kern/misc.c (abort): New alias for grub_abort.
14634 2006-04-25 Yoshinori K. Okuji <okuji@enbug.org>
14636 A new machine-specific function "grub_machine_set_prefix" is
14637 defined. This is called after loading modules, so that a prefix
14638 initialization can use modules. Also, this change adds an
14639 intensive debugging feature for the memory manager via the
14640 configure option "--enable-mm-debug".
14642 * partmap/gpt.c (gpt_partition_map_iterate): Add one more into
14645 * kern/sparc64/ieee1275/init.c (abort): Removed.
14646 (grub_stop): Likewise.
14647 (grub_exit): New function.
14648 (grub_set_prefix): Renamed to ...
14649 (grub_machine_set_prefix): ... this.
14650 (grub_machine_init): Do not call grub_set_prefix.
14652 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Renamed to ...
14653 (grub_machine_set_prefix): ... this.
14654 (grub_machine_init): Do not call grub_set_prefix.
14656 * kern/i386/pc/init.c (grub_machine_set_prefix): New function.
14657 (grub_machine_init): Do not set the prefix here.
14659 * kern/i386/efi/init.c (grub_machine_set_prefix): New function.
14661 * kern/efi/init.c: Include grub/mm.h.
14662 (grub_efi_set_prefix): New function.
14664 * kern/efi/efi.c (grub_exit): Call grub_efi_fini.
14665 (grub_efi_get_filename): New function.
14666 (grub_print_device_path): Renamed to ...
14667 (grub_efi_print_device_path): ... this.
14669 * kern/mm.c [MM_DEBUG] (grub_malloc): Undefined.
14670 [MM_DEBUG] (grub_realloc): Likewise.
14671 [MM_DEBUG] (grub_free): Likewise.
14672 [MM_DEBUG] (grub_memalign): Likewise.
14673 [MM_DEBUG] (grub_mm_debug): New variable.
14674 [MM_DEBUG] (grub_debug_malloc): New function.
14675 [MM_DEBUG] (grub_debug_free): New function.
14676 [MM_DEBUG] (grub_debug_realloc): New function.
14677 [MM_DEBUG] (grub_debug_memalign): New function.
14679 * kern/misc.c (grub_abort): Print a newline to distinguish
14682 * kern/main.c (grub_main): Call grub_machine_set_prefix and
14683 grub_set_root_dev after loading modules. This is necessary when
14684 setting a prefix depends on modules.
14686 * include/grub/efi/efi.h (grub_print_device_path): Renamed to ...
14687 (grub_efi_print_device_path): ... this.
14688 (grub_efi_get_filename): New prototype.
14689 (grub_efi_set_prefix): Likewise.
14691 * include/grub/efi/disk.h: Include grub/efi/api.h, grub/symbol.h
14693 (grub_efidisk_get_device_handle): New prototype.
14694 (grub_efidisk_get_device_name): Likewise.
14696 * include/grub/mm.h: Include config.h.
14697 (MM_DEBUG): Removed.
14698 [MM_DEBUG && !GRUB_UTIL] (grub_mm_debug): New prototype.
14699 [MM_DEBUG && !GRUB_UTIL] (grub_malloc): New macro.
14700 [MM_DEBUG && !GRUB_UTIL] (grub_realloc): Likewise.
14701 [MM_DEBUG && !GRUB_UTIL] (grub_memalign): Likewise.
14702 [MM_DEBUG && !GRUB_UTIL] (grub_free): Likewise.
14703 [MM_DEBUG && !GRUB_UTIL] (grub_debug_malloc): New prototype.
14704 [MM_DEBUG && !GRUB_UTIL] (grub_debug_realloc): New prototype.
14705 [MM_DEBUG && !GRUB_UTIL] (grub_debug_memalign): New prototype.
14706 [MM_DEBUG && !GRUB_UTIL] (grub_debug_free): New prototype.
14708 * include/grub/kernel.h (grub_machine_set_prefix): New prototype.
14710 * disk/efi/efidisk.c: Include grub/partition.h.
14711 (iterate_child_devices): New function.
14712 (add_device): First, compare only last device path nodes, so that
14713 devices are sorted by the types.
14714 (grub_efidisk_get_device_handle): New function.
14715 (grub_efidisk_get_device_name): Likewise.
14717 * configure.ac (--enable-mm-debug): New option to enable the
14718 memory manager debugging feature. This makes the binary much
14719 bigger, so is disabled by default.
14721 2006-04-23 Yoshinori K. Okuji <okuji@enbug.org>
14723 Use grub_abort instead of grub_stop, and grub_exit must be
14724 define in each architecture now. Also, this change adds support
14727 * util/i386/pc/grub-probefs.c: Include grub/term.h.
14728 (grub_getkey): New function.
14729 (grub_term_get_current): Likewise.
14731 * util/i386/pc/grub-setup.c: Include grub/term.h.
14732 (grub_getkey): New function.
14733 (grub_term_get_current): Likewise.
14735 * util/misc.c (grub_stop): Renamed to ...
14736 (grub_exit): ... this.
14738 * kern/powerpc/ieee1275/init.c (abort): Renamed to ...
14739 (grub_exit): ... this.
14740 (grub_machine_init): Use grub_abort instead of abort.
14741 (grub_stop): Removed.
14743 * kern/powerpc/ieee1275/cmain.c (cmain): Use grub_abort instead of
14746 * kern/i386/pc/startup.S (grub_exit): New function.
14747 (cold_reboot): New label.
14749 * kern/efi/init.c: Include grub/efi/disk.h and grub/env.h.
14750 (grub_efi_init): Call grub_efidisk_init.
14751 (grub_efi_fini): Call grub_efidisk_fini.
14753 * kern/efi/efi.c: Include grub/mm.h.
14754 (grub_efi_console_control_guid): Renamed to ...
14755 (console_control_guid): ... this.
14756 (grub_efi_loaded_image_guid): Renamed to ...
14757 (loaded_image_guid): ... this.
14758 (grub_efi_locate_handle): New function.
14759 (grub_efi_open_protocol): Likewise.
14760 (grub_efi_set_text_mode): Use CONSOLE_CONTROL_GUID instead of
14761 GRUB_EFI_CONSOLE_CONTROL_GUID.
14762 (grub_efi_exit): Removed.
14763 (grub_stop): Likewise.
14764 (grub_efi_get_loaded_image): Use grub_efi_open_protocol.
14765 (grub_exit): New function.
14766 (grub_print_device_path): Likewise.
14768 * kern/rescue.c (grub_rescue_cmd_exit): New function.
14769 (grub_enter_rescue_mode): Register "exit".
14771 * kern/misc.c (grub_real_dprintf): A cosmetic change.
14772 (grub_abort): New function.
14774 * kern/err.c (grub_fatal): Use grub_abort instead of grub_stop.
14776 * include/grub/sparc64/ieee1275/kernel.h (abort): Removed.
14778 * include/grub/powerpc/ieee1275/kernel.h (abort): Removed.
14780 * include/grub/efi/efi.h (grub_efi_exit): Removed.
14781 (grub_print_device_path): New prototype.
14782 (grub_efi_locate_handle): Likewise.
14783 (grub_efi_open_protocol): Likewise.
14785 * include/grub/efi/disk.h (grub_efidisk_fini): New file.
14786 * disk/efi/efidisk.c: Likewise.
14788 * DISTLIST: Added disk/efi/efidisk.c and include/grub/efi/disk.h.
14790 * include/grub/efi/console_control.h
14791 (GRUB_EFI_CONSOLE_CONTROL_GUID): Use an array for the last 8 bytes.
14793 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): Specify the
14794 last 8 bytes as an array.
14795 (GRUB_EFI_DISK_IO_GUID): New macro.
14796 (GRUB_EFI_BLOCK_IO_GUID): Likewise.
14797 (GRUB_EFI_DEVICE_PATH_GUID): Likewise.
14798 (grub_efi_ipv6_address_t): Change the type to grub_uint16_t from
14800 (struct grub_efi_guid): Use an array to specify the last 8 bytes.
14801 (struct grub_efi_device_path): Rename the member "sub_type" to
14803 (GRUB_EFI_DEVICE_PATH_TYPE): New macro.
14804 (GRUB_EFI_DEVICE_PATH_SUBTYPE): Likewise.
14805 (GRUB_EFI_DEVICE_PATH_LENGTH): Likewise.
14806 (GRUB_EFI_END_DEVICE_PATH_TYPE): Likewise.
14807 (GRUB_EFI_END_ENTIRE_DEVICE_PATH_SUBTYPE): Likewise.
14808 (GRUB_EFI_END_THIS_DEVICE_PATH_SUBTYPE): Likewise.
14809 (GRUB_EFI_END_ENTIRE_DEVICE_PATH): Likewise.
14810 (GRUB_EFI_NEXT_DEVICE_PATH): Likewise.
14811 (GRUB_EFI_HARDWARE_DEVICE_PATH_TYPE): Likewise.
14812 (GRUB_EFI_PCI_DEVICE_PATH_SUBTYPE): Likewise.
14813 (struct grub_efi_pci_device_path): New structure.
14814 (grub_efi_pci_device_path_t): New type.
14815 (GRUB_EFI_PCCARD_DEVICE_PATH_SUBTYPE): New macro.
14816 (struct grub_efi_pccard_device_path): New structure.
14817 (grub_efi_pccard_device_path_t): New type.
14818 (GRUB_EFI_MEMORY_MAPPED_DEVICE_PATH_SUBTYPE): New macro.
14819 (struct grub_efi_memory_mapped_device_path): New structure.
14820 (grub_efi_memory_mapped_device_path_t): New type.
14821 (GRUB_EFI_VENDOR_DEVICE_PATH_SUBTYPE): New macro.
14822 (struct grub_efi_vendor_device_path): New structure.
14823 (grub_efi_vendor_device_path_t): New type.
14824 (GRUB_EFI_CONTROLLER_DEVICE_PATH_SUBTYPE): New macro.
14825 (struct grub_efi_controller_device_path): New structure.
14826 (grub_efi_controller_device_path_t): New type.
14827 (GRUB_EFI_ACPI_DEVICE_PATH_TYPE): New macro.
14828 (GRUB_EFI_ACPI_DEVICE_PATH_SUBTYPE): Likewise.
14829 (struct grub_efi_acpi_device_path): New structure.
14830 (grub_efi_acpi_device_path_t): New type.
14831 (GRUB_EFI_EXPANDED_ACPI_DEVICE_PATH_SUBTYPE): New macro.
14832 (struct grub_efi_expanded_acpi_device_path): New structure.
14833 (grub_efi_expanded_acpi_device_path_t): New type.
14834 (GRUB_EFI_EXPANDED_ACPI_HIDSTR): New macro.
14835 (GRUB_EFI_EXPANDED_ACPI_UIDSTR): Likewise.
14836 (GRUB_EFI_EXPANDED_ACPI_CIDSTR): Likewise.
14837 (GRUB_EFI_MESSAGING_DEVICE_PATH_TYPE): Likewise.
14838 (GRUB_EFI_ATAPI_DEVICE_PATH_SUBTYPE): Likewise.
14839 (struct grub_efi_atapi_device_path): New structure.
14840 (grub_efi_atapi_device_path_t): New type.
14841 (GRUB_EFI_FIBRE_CHANNEL_DEVICE_PATH_SUBTYPE): New macro.
14842 (struct grub_efi_fibre_channel_device_path): New structure.
14843 (grub_efi_fibre_channel_device_path_t): New type.
14844 (GRUB_EFI_1394_DEVICE_PATH_SUBTYPE): New macro.
14845 (struct grub_efi_1394_device_path): New structure.
14846 (grub_efi_1394_device_path_t): New type.
14847 (GRUB_EFI_USB_DEVICE_PATH_SUBTYPE): New macro.
14848 (struct grub_efi_usb_device_path): New structure.
14849 (grub_efi_usb_device_path_t): New type.
14850 (GRUB_EFI_USB_CLASS_DEVICE_PATH_SUBTYPE): New macro.
14851 (struct grub_efi_usb_class_device_path): New structure.
14852 (grub_efi_usb_class_device_path_t): New type.
14853 (GRUB_EFI_I2O_DEVICE_PATH_SUBTYPE): New macro.
14854 (struct grub_efi_i2o_device_path): New structure.
14855 (grub_efi_i2o_device_path_t): New type.
14856 (GRUB_EFI_MAC_ADDRESS_DEVICE_PATH_SUBTYPE): New macro.
14857 (struct grub_efi_mac_address_device_path): New structure.
14858 (grub_efi_mac_address_device_path_t): New type.
14859 (GRUB_EFI_IPV4_DEVICE_PATH_SUBTYPE): New macro.
14860 (struct grub_efi_ipv4_device_path): New structure.
14861 (grub_efi_ipv4_device_path_t): New type.
14862 (GRUB_EFI_IPV6_DEVICE_PATH_SUBTYPE): New macro.
14863 (struct grub_efi_ipv6_device_path): New structure.
14864 (grub_efi_ipv6_device_path_t): New type.
14865 (GRUB_EFI_INFINIBAND_DEVICE_PATH_SUBTYPE): New macro.
14866 (struct grub_efi_infiniband_device_path): New structure.
14867 (grub_efi_infiniband_device_path_t): New type.
14868 (GRUB_EFI_UART_DEVICE_PATH_SUBTYPE): New macro.
14869 (struct grub_efi_uart_device_path): New structure.
14870 (grub_efi_uart_device_path_t): New type.
14871 (GRUB_EFI_VENDOR_MESSAGING_DEVICE_PATH_SUBTYPE): New macro.
14872 (struct grub_efi_vendor_messaging_device_path): New structure.
14873 (grub_efi_vendor_messaging_device_path_t): New type.
14874 (GRUB_EFI_MEDIA_DEVICE_PATH_TYPE): New macro.
14875 (GRUB_EFI_HARD_DRIVE_DEVICE_PATH_SUBTYPE): Likewise.
14876 (struct grub_efi_hard_drive_device_path): New structure.
14877 (grub_efi_hard_drive_device_path_t): New type.
14878 (GRUB_EFI_CDROM_DEVICE_PATH_SUBTYPE): New macro.
14879 (struct grub_efi_cdrom_device_path): New structure.
14880 (grub_efi_cdrom_device_path_t): New type.
14881 (GRUB_EFI_VENDOR_MEDIA_DEVICE_PATH_SUBTYPE): New macro.
14882 (struct grub_efi_vendor_media_device_path): New structure.
14883 (grub_efi_vendor_media_device_path_t): New type.
14884 (GRUB_EFI_FILE_PATH_DEVICE_PATH_SUBTYPE): New macro.
14885 (struct grub_efi_file_path_device_path): New structure.
14886 (grub_efi_file_path_device_path_t): New type.
14887 (GRUB_EFI_PROTOCOL_DEVICE_PATH_SUBTYPE): New macro.
14888 (struct grub_efi_protocol_device_path): New structure.
14889 (grub_efi_protocol_device_path_t): New type.
14890 (GRUB_EFI_BIOS_DEVICE_PATH_TYPE): New macro.
14891 (GRUB_EFI_BIOS_DEVICE_PATH_SUBTYPE): Likewise.
14892 (struct grub_efi_bios_device_path): New structure.
14893 (grub_efi_bios_device_path_t): New type.
14894 (struct grub_efi_disk_io): New structure.
14895 (grub_efi_disk_io_t): New type.
14896 (struct grub_efi_block_io_media): New structure.
14897 (grub_efi_block_io_media_t): New type.
14898 (struct grub_efi_block_io): New structure.
14899 (grub_efi_block_io_t): New type.
14901 * include/grub/misc.h (grub_stop): Removed.
14902 (grub_exit): New prototype.
14903 (grub_abort): Likewise.
14905 * include/grub/disk.h (enum grub_disk_dev_id): Added
14906 GRUB_DISK_DEVICE_EFIDISK_ID.
14908 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added
14909 disk/efi/efidisk.c.
14910 (kernel_syms.lst): Remove the target if an error occurs.
14912 2006-04-22 Yoshinori K. Okuji <okuji@enbug.org>
14914 * kern/misc.c (grub_lltoa): Rewritten the decimal conversion part,
14915 as it was simply too buggy.
14917 2006-04-21 Yoshinori K. Okuji <okuji@enbug.org>
14919 * kern/misc.c (grub_lltoa): New function.
14920 (grub_vsprintf): Added support for the long long suffix,
14923 2006-04-20 Hollis Blanchard <hollis@penguinppc.org>
14925 * Makefile.in (LDFLAGS): Add variable.
14926 (LD): Remove variable.
14927 * configure.ac: Add -m32 to LDFLAGS.
14928 * genmk.rb (PModule#rule): Use $(CC) instead of $(LD).
14929 * conf/powerpc-ieee1275.rmk (COMMON_LDFLAGS): Add variable.
14930 (grubof_LDFLAGS): Use $(COMMON_LDFLAGS).
14931 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS, normal_mod_LDFLAGS,
14932 suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS): New
14934 * conf/sparc64-ieee1275.rmk (COMMON_LDFLAGS): Add -nostdlib.
14935 * conf/i386-pc.rmk (COMMON_LDFLAGS): Add -nostdlib.
14936 * conf/i386-efi.rmk (COMMON_LDFLAGS): Add -nostdlib.
14938 2006-04-20 Vesa Jaaskelainen <chaac@nic.fi>
14940 * term/gfxterm.c (grub_gfxterm_getcharwidth): Fixed character
14941 length for unknown glyph.
14943 2006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
14945 Add support for pre-loaded modules into the EFI port.
14947 * util/i386/efi/grub-mkimage.c (make_mods_section): Rewritten
14948 completely. Accept one more argument DIR. The caller has changed.
14950 * kern/i386/efi/init.c (grub_arch_modules_addr): Removed.
14952 * kern/efi/efi.c: Include grub/efi/pe32.h and grub/kernel.h.
14953 (grub_efi_loaded_image_guid): New variable.
14954 (grub_efi_get_loaded_image): New function.
14955 (grub_arch_modules_addr): Likewise.
14957 * include/grub/efi/efi.h (grub_efi_get_loaded_image): New
14960 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): New macro.
14961 (struct grub_efi_loaded_image): New structure.
14962 (grub_efi_loaded_image_t): New type.
14964 2006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
14966 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Compare the file
14967 size with GRUB_OS_AREA_SIZE as grub_size_t instead of
14968 grub_ssize_t. Reported by Jeff Chua <jeff84@silk.corp.fedex.com>.
14970 2006-04-19 Roger Leigh <rleigh@whinlatter.ukfsn.org>
14972 * DISTLIST: Added `util/powerpc/ieee1275/grub-install.in'.
14974 2006-04-19 Yoshinori K. Okuji <okuji@enbug.org>
14976 * DISTLIST: Added include/grub/efi/console.h,
14977 include/grub/efi/time.h, include/grub/i386/efi/kernel.h,
14978 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
14980 * include/grub/efi/console.h: New file.
14981 * include/grub/efi/time.h: Likewise.
14982 * include/grub/i386/efi/kernel.h: Likewise.
14983 * kern/efi/init.c: Likewise.
14984 * kern/efi/mm.c: Likewise.
14985 * term/efi/console.c: Likewise.
14987 * kern/i386/efi/init.c: Do not include grub/machine/time.h.
14988 (grub_stop): Removed.
14989 (grub_get_rtc): Likewise.
14990 (grub_machine_init): Simply call grub_efi_init.
14991 (grub_machine_fini): Call grub_efi_fini.
14993 * kern/efi/efi.c: Include grub/machine/time.h and grub/term.h.
14994 (grub_efi_output_string): Removed.
14995 (grub_efi_stall): New function.
14996 (grub_stop): Likewise.
14997 (grub_get_rtc): Likewise.
14999 * include/grub/efi/efi.h (grub_efi_output_string): Removed.
15000 (grub_efi_stall): New prototype.
15001 (grub_efi_allocate_pages): Likewise.
15002 (grub_efi_free_pages): Likewise.
15003 (grub_efi_get_memory_map): Likewise.
15004 (grub_efi_mm_init): Likewise.
15005 (grub_efi_mm_fini): Likewise.
15006 (grub_efi_init): Likewise.
15007 (grub_efi_fini): Likewise.
15009 * include/grub/i386/efi/time.h: Do not include
15010 grub/symbol.h. Include grub/efi/time.h.
15011 (GRUB_TICKS_PER_SECOND): Removed.
15012 (grub_get_rtc): Likewise.
15014 * include/grub/efi/api.h (struct grub_efi_memory_descriptor):
15015 Added padding. The EFI spec is buggy.
15016 (GRUB_EFI_BLACK): New macro.
15017 (GRUB_EFI_BLUE): Likewise.
15018 (GRUB_EFI_GREEN): Likewise.
15019 (GRUB_EFI_CYAN): Likewise.
15020 (GRUB_EFI_RED): Likewise.
15021 (GRUB_EFI_MAGENTA): Likewise.
15022 (GRUB_EFI_BROWN): Likewise.
15023 (GRUB_EFI_LIGHTGRAY): Likewise.
15024 (GRUB_EFI_BRIGHT): Likewise.
15025 (GRUB_EFI_DARKGRAY): Likewise.
15026 (GRUB_EFI_LIGHTBLUE): Likewise.
15027 (GRUB_EFI_LIGHTGREEN): Likewise.
15028 (GRUB_EFI_LIGHTCYAN): Likewise.
15029 (GRUB_EFI_LIGHTRED): Likewise.
15030 (GRUB_EFI_LIGHTMAGENTA): Likewise.
15031 (GRUB_EFI_YELLOW): Likewise.
15032 (GRUB_EFI_WHITE): Likewise.
15033 (GRUB_EFI_BACKGROUND_BLACK): Likewise.
15034 (GRUB_EFI_BACKGROUND_BLUE): Likewise.
15035 (GRUB_EFI_BACKGROUND_GREEN): Likewise.
15036 (GRUB_EFI_BACKGROUND_CYAN): Likewise.
15037 (GRUB_EFI_BACKGROUND_RED): Likewise.
15038 (GRUB_EFI_BACKGROUND_MAGENTA): Likewise.
15039 (GRUB_EFI_BACKGROUND_BROWN): Likewise.
15040 (GRUB_EFI_BACKGROUND_LIGHTGRAY): Likewise.
15041 (GRUB_EFI_TEXT_ATTR): Likewise.
15043 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added kern/efi/efi.c,
15044 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
15045 (kernel_mod_HEADERS): Added efi/time.h.
15047 2006-04-18 Yoshinori K. Okuji <okuji@enbug.org>
15049 * DISTLIST: Added conf/i386-efi.mk, conf/i386-efi.rmk,
15050 include/grub/efi/api.h, include/grub/efi/console_control.h,
15051 include/grub/efi/efi.h, include/grub/efi/pe32.h,
15052 include/grub/i386/efi/time.h, kern/efi/efi.c,
15053 kern/i386/efi/init.c, kern/i386/efi/startup.S,
15054 and util/i386/efi/grub-mkimage.c.
15056 * Makefile.in (RMKFILES): Added i386-efi.rmk.
15058 * genmk.rb (PModule#rule): Do not export symbols if
15059 #{prefix}_EXPORTS is set to "no".
15061 * conf/i386-efi.mk: New file.
15062 * conf/i386-efi.rmk: Likewise.
15063 * include/grub/efi/api.h: Likewise.
15064 * include/grub/efi/console_control.h: Likewise.
15065 * include/grub/efi/efi.h: Likewise.
15066 * include/grub/efi/pe32.h: Likewise.
15067 * include/grub/i386/efi/time.h: Likewise.
15068 * kern/efi/efi.c: Likewise.
15069 * kern/i386/efi/init.c: Likewise.
15070 * kern/i386/efi/startup.S: Likewise.
15071 * util/i386/efi/grub-mkimage.c: Likewise.
15073 2006-04-17 Marco Gerards <marco@gnu.org>
15075 * include/grub/script.h: Include <grub/parser.h> and
15076 "grub_script.tab.h".
15077 (struct grub_lexer_param): New struct.
15078 (struct grub_parser_param): Likewise.
15079 (grub_script_create_arglist): Pass the state in an argument.
15080 (grub_script_add_arglist): Likewise.
15081 (grub_script_create_cmdline): Likewise.
15082 (grub_script_create_cmdblock): Likewise.
15083 (grub_script_create_cmdif): Likewise.
15084 (grub_script_create_cmdmenu): Likewise.
15085 (grub_script_add_cmd): Likewise.
15086 (grub_script_arg_add): Likewise.
15087 (grub_script_lexer_ref): Likewise.
15088 (grub_script_lexer_deref): Likewise.
15089 (grub_script_lexer_record_start): Likewise.
15090 (grub_script_lexer_record_stop): Likewise.
15091 (grub_script_mem_record): Likewise.
15092 (grub_script_mem_record_stop): Likewise.
15093 (grub_script_malloc): Likewise.
15094 (grub_script_yylex): Likewise.
15095 (grub_script_yyparse): Likewise.
15096 (grub_script_yyerror): Likewise.
15097 (grub_script_yylex): Likewise.
15098 (grub_script_lexer_init): Return the state.
15100 * normal/lexer.c (grub_script_lexer_state): Removed variable.
15101 (grub_script_lexer_done): Likewise.
15102 (grub_script_lexer_getline): Likewise.
15103 (grub_script_lexer_refs): Likewise.
15104 (script): Likewise.
15105 (newscript): Likewise.
15106 (record): Likewise.
15107 (recording): Likewise.
15108 (recordpos): Likewise.
15109 (recordlen): Likewise.
15110 (grub_script_lexer_init): Return the state instead of setting
15112 (grub_script_lexer_ref): Use the newly added argument for state
15113 instead of globals.
15114 (grub_script_lexer_deref): Likewise.
15115 (grub_script_lexer_record_start): Likewise.
15116 (grub_script_lexer_record_stop): Likewise.
15117 (recordchar): Likewise.
15118 (nextchar): Likewise.
15119 (grub_script_yylex2): Likewise.
15120 (grub_script_yylex): Likewise.
15121 (grub_script_yyerror): Likewise.
15123 * normal/parser.y (func_mem): Removed variable.
15124 (menu_entry): Likewise.
15126 (%lex-param): New parser option.
15127 (%parse-param): Likewise.
15128 (script): Always return the AST.
15129 (argument): Pass the state around.
15130 (arguments): Likewise.
15131 (grubcmd): Likewise.
15132 (commands): Likewise.
15133 (function): Likewise.
15134 (menuentry): Likewise.
15135 (if_statement): Likewise.
15138 * normal/script.c (grub_script_memused): Removed variable.
15139 (grub_script_parsed): Likewise.
15140 (grub_script_malloc): Added a state argument. Use that instead of
15142 (grub_script_mem_record): Likewise.
15143 (grub_script_mem_record_stop): Likewise.
15144 (grub_script_arg_add): Likewise.
15145 (grub_script_add_arglist): Likewise.
15146 (grub_script_create_cmdline): Likewise.
15147 (grub_script_create_cmdif): Likewise.
15148 (grub_script_create_cmdmenu): Likewise.
15149 (grub_script_add_cmd): Likewise.
15150 (grub_script_parse): Setup the state before calling the parser.
15152 2006-04-16 Marco Gerards <marco@gnu.org>
15154 * normal/command.c (grub_command_init): Remove the title command.
15156 * normal/lexer.c (grub_script_yylex): Renamed from this...
15157 (grub_script_yylex2): ... to this.
15158 (grub_script_yylex): New function. Temporary
15159 introduced to filter some tokens.
15160 (grub_script_yyerror): Print a newline.
15162 * normal/main.c (read_config_file): Output information about the
15163 lines that contain errors. Wait for a key after all lines have
15164 been processed. Don't return an empty menu.
15166 * normal/parser.y (func_mem): Don't initialize.
15167 (menu_entry): Likewise.
15168 (err): New variable.
15169 (script): Don't return anything when an error was encountered.
15170 (ws, returns): Removed rules.
15171 (argument): Disabled concatenated variable support.
15172 (arguments): Remove explicit separators.
15173 (grubcmd): Likewise.
15174 (function): Likewise.
15175 (menuentry): Likewise.
15177 (commands): Likewise. Add error handling.
15179 * normal/script.c (grub_script_create_cmdline): If
15180 `grub_script_parsed' is 0, assume the parser encountered an error.
15182 2006-04-02 Yoshinori K. Okuji <okuji@enbug.org>
15184 * configure.ac: Add support for EFI. Fix the typo
15185 BUILD_LDDFLAGS. Restore the LDFLAGS after testing.
15187 2006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
15189 * util/unifont2pff.rb: Removed unnecessary byte ordering. Now
15190 foreign multibyte characters should be shown correctly.
15192 2006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
15194 * normal/main.c (grub_normal_menu_addentry): Fixed menu size
15196 (read_config_file): Made it to close file before returning.
15198 2006-03-31 Vesa Jaaskelainen <chaac@nic.fi>
15200 * DISTLIST: Added include/grub/i386/pc/vbeblit.h,
15201 include/grub/i386/pc/vbefill.h, video/i386/pc/vbeblit.c,
15202 video/i386/pc/vbefill.c.
15204 * conf/i386-pc.rmk (vbe_mod_SOURCES): Added video/i386/pc/vbeblit.c,
15205 video/i386/pc/vbefill.c.
15207 * include/grub/video.h (grub_video_blit_format): New enum.
15208 (grub_video_mode_info): Added new member blit_format.
15209 (grub_video_get_blit_format): New function prototype.
15211 * include/grub/i386/pc/vbe.h (grub_video_vbe_get_video_ptr): New
15212 function prototype.
15213 (grub_video_vbe_map_rgb): Likewise.
15214 (grub_video_vbe_unmap_color): Likewise.
15216 * include/grub/i386/pc/vbeblit.h: New file.
15218 * include/grub/i386/pc/vbefill.h: New file.
15220 * video/video.c (grub_video_get_blit_format): New function.
15221 (grub_video_vbe_get_video_ptr): Re-declared as non-static.
15222 (grub_video_vbe_map_rgb): Likewise.
15223 (grub_video_vbe_unmap_color): Likewise.
15225 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Changed to use more
15227 (grub_video_vbe_blit_render_target): Changed to use more optimized
15229 (grub_video_vbe_setup): Added detection for optimized settings.
15230 (grub_video_vbe_create_render_target): Likewise.
15232 * video/i386/pc/vbeblit.c: New file.
15234 * video/i386/pc/vbefill.c: New file.
15236 2006-03-30 Vesa Jaaskelainen <chaac@nic.fi>
15238 * font/manager.c (grub_font_get_glyph): Removed font fixup from
15241 * util/unifont2pff.rb: ... and moved it to here. Improved argument
15242 parsing to support both hex and dec ranges. If filename was missing
15243 show usage information.
15245 2006-03-14 Vesa Jaaskelainen <chaac@nic.fi>
15247 * DISTLIST: Added include/grub/video.h, term/gfxterm.c,
15248 video/video.c, commands/videotest.c. Removed term/i386/pc/vesafb.c.
15250 * conf/i386-pc.rmk (pkgdata_MODULES): Added video.mod,
15251 gfxterm.mod, videotest.mod. Removed vga.mod, vesafb.mod.
15252 (video_mod_SOURCES): Added.
15253 (video_mod_CFLAGS): Likewise.
15254 (video_mod_LDFLAGS): Likewise.
15255 (gfxterm_mod_SOURCES): Likewise.
15256 (gfxterm_mod_CFLAGS): Likewise.
15257 (gfxterm_mod_LDFLAGS): Likewise.
15258 (videotest_mod_SOURCES): Likewise.
15259 (videotest_mod_CFLAGS): Likewise.
15260 (videotest_mod_LDFLAGS): Likewise.
15261 (vesafb_mod_SOURCES): Removed.
15262 (vesafb_mod_CFLAGS): Likewise.
15263 (vesafb_mod_LDFLAGS): Likewise.
15264 (vga_mod_SOURCES): Likewise.
15265 (vga_mod_CFLAGS): Likewise.
15266 (vga_mod_LDFLAGS): Likewise.
15268 * commands/videotest.c: New file.
15270 * font/manager.c (fill_with_default_glyph): Modified to use
15272 (grub_font_get_glyph): Likewise.
15273 (fontmanager): Renamed from this...
15274 (font_manager): ... to this.
15276 * include/grub/font.h (grub_font_glyph): Added new structure.
15277 (grub_font_get_glyph): Modified to use grub_font_glyph.
15279 * include/grub/misc.h (grub_abs): Added as inline function.
15281 * include/grub/video.h: New file.
15283 * include/grub/i386/pc/vbe.h (GRUB_VBE_STATUS_OK): New macro.
15284 (GRUB_VBE_MEMORY_MODEL_PACKED_PIXEL): Likewise.
15285 (GRUB_VBE_MEMORY_MODEL_DIRECT_COLOR): Likewise.
15286 (grub_vbe_get_controller_info): Renamed from this...
15287 (grub_vbe_bios_get_controller_info): ... to this.
15288 (grub_vbe_get_mode_info): Renamed from this...
15289 (grub_vbe_bios_get_mode_info): ... to this.
15290 (grub_vbe_set_mode): Renamed from this...
15291 (grub_vbe_bios_set_mode): ... to this.
15292 (grub_vbe_get_mode): Renamed from this...
15293 (grub_vbe_bios_get_mode): ... to this.
15294 (grub_vbe_set_memory_window): Renamed from this...
15295 (grub_vbe_bios_set_memory_window): ... to this.
15296 (grub_vbe_get_memory_window): Renamed from this...
15297 (grub_vbe_bios_get_memory_window): ... to this.
15298 (grub_vbe_set_scanline_length): Renamed from this...
15299 (grub_vbe_set_scanline_length): ... to this.
15300 (grub_vbe_get_scanline_length): Renamed from this...
15301 (grub_vbe_bios_get_scanline_length): ... to this.
15302 (grub_vbe_set_display_start): Renamed from this...
15303 (grub_vbe_bios_set_display_start): ... to this.
15304 (grub_vbe_get_display_start): Renamed from this...
15305 (grub_vbe_bios_get_display_start): ... to this.
15306 (grub_vbe_set_palette_data): Renamed from this...
15307 (grub_vbe_bios_set_palette_data): ... to this.
15308 (grub_vbe_set_pixel_rgb): Removed.
15309 (grub_vbe_set_pixel_index): Likewise.
15311 * kern/i386/pc/startup.S (grub_vbe_get_controller_info): Renamed
15313 (grub_vbe_bios_get_controller_info): ... to this.
15314 (grub_vbe_get_mode_info): Renamed from this...
15315 (grub_vbe_bios_get_mode_info): ... to this.
15316 (grub_vbe_set_mode): Renamed from this...
15317 (grub_vbe_bios_set_mode): ... to this.
15318 (grub_vbe_get_mode): Renamed from this...
15319 (grub_vbe_bios_get_mode): ... to this.
15320 (grub_vbe_set_memory_window): Renamed from this...
15321 (grub_vbe_bios_set_memory_window): ... to this.
15322 (grub_vbe_get_memory_window): Renamed from this...
15323 (grub_vbe_bios_get_memory_window): ... to this.
15324 (grub_vbe_set_scanline_length): Renamed from this...
15325 (grub_vbe_set_scanline_length): ... to this.
15326 (grub_vbe_get_scanline_length): Renamed from this...
15327 (grub_vbe_bios_get_scanline_length): ... to this.
15328 (grub_vbe_set_display_start): Renamed from this...
15329 (grub_vbe_bios_set_display_start): ... to this.
15330 (grub_vbe_get_display_start): Renamed from this...
15331 (grub_vbe_bios_get_display_start): ... to this.
15332 (grub_vbe_set_palette_data): Renamed from this...
15333 (grub_vbe_bios_set_palette_data): ... to this.
15334 (grub_vbe_bios_get_controller_info): Fixed problem with registers
15335 getting corrupted after calling it. Added more pushes and pops.
15336 (grub_vbe_bios_set_mode): Likewise.
15337 (grub_vbe_bios_get_mode): Likewise.
15338 (grub_vbe_bios_get_memory_window): Likewise.
15339 (grub_vbe_bios_set_scanline_length): Likewise.
15340 (grub_vbe_bios_get_scanline_length): Likewise.
15341 (grub_vbe_bios_get_display_start): Likewise.
15342 (grub_vbe_bios_set_palette_data): Likewise.
15344 * normal/cmdline.c (cl_set_pos): Refresh the screen.
15345 (cl_insert): Likewise.
15346 (cl_delete): Likewise.
15348 * term/gfxterm.c: New file.
15350 * term/i386/pc/vesafb.c: Removed file.
15352 * video/video.c: New file.
15354 * video/i386/pc/vbe.c (real2pm): Added new function.
15355 (grub_video_vbe_draw_pixel): Likewise.
15356 (grub_video_vbe_get_video_ptr): Likewise.
15357 (grub_video_vbe_get_pixel): Likewise
15358 (grub_video_vbe_init): Likewise.
15359 (grub_video_vbe_fini): Likewise.
15360 (grub_video_vbe_setup): Likewise.
15361 (grub_video_vbe_get_info): Likewise.
15362 (grub_video_vbe_set_palette): Likewise.
15363 (grub_video_vbe_get_palette): Likewise.
15364 (grub_video_vbe_set_viewport): Likewise.
15365 (grub_video_vbe_get_viewport): Likewise.
15366 (grub_video_vbe_map_color): Likewise.
15367 (grub_video_vbe_map_rgb): Likewise.
15368 (grub_video_vbe_map_rgba): Likewise.
15369 (grub_video_vbe_unmap_color): Likewise.
15370 (grub_video_vbe_fill_rect): Likewise.
15371 (grub_video_vbe_blit_glyph): Likewise.
15372 (grub_video_vbe_blit_bitmap): Likewise.
15373 (grub_video_vbe_blit_render_target): Likewise.
15374 (grub_video_vbe_scroll): Likewise.
15375 (grub_video_vbe_swap_buffers): Likewise.
15376 (grub_video_vbe_create_render_target): Likewise.
15377 (grub_video_vbe_delete_render_target): Likewise.
15378 (grub_video_vbe_set_active_render_target): Likewise.
15379 (grub_vbe_set_pixel_rgb): Remove function.
15380 (grub_vbe_set_pixel_index): Likewise.
15381 (index_color_mode): Remove static variable.
15382 (active_mode): Likewise.
15383 (framebuffer): Likewise.
15384 (bytes_per_scan_line): Likewise.
15385 (grub_video_vbe_adapter): Added new static variable.
15386 (framebuffer): Likewise.
15387 (render_target): Likewise.
15388 (initial_mode): Likewise.
15389 (mode_in_use): Likewise.
15390 (mode_list): Likewise.
15392 2006-03-10 Marco Gerards <marco@gnu.org>
15394 * configure.ac (AC_INIT): Bumped to 1.93.
15396 * DISTLIST: Added `include/grub/hfs.h'.
15398 2006-02-01 Yoshinori K. Okuji <okuji@enbug.org>
15400 * boot/i386/pc/boot.S (general_error): Before looping, try INT
15401 18H, which might help the BIOS falling back to next boot media.
15403 2006-01-25 Yoshinori K. Okuji <okuji@enbug.org>
15405 * util/i386/pc/grub-install.in: Escape a backslash. Reported by
15406 Poe Chen <poe.poechen@gmail.com>.
15408 2006-01-17 Marco Gerards <marco@gnu.org>
15410 * include/grub/normal.h: Include <grub/script.h>.
15411 (grub_command_list): Removed struct.
15412 (grub_command_list_t): Removed type.
15413 (grub_menu_entry): Remove members `num' and `command_list'. Add
15414 members `commands' and `sourcecode'.
15415 * include/grub/script.h: Add inclusion guards.
15416 (grub_script_cmd_menuentry): New struct.
15417 (grub_script_execute_menuentry): New prototype.
15418 (grub_script_lexer_record_start): Likewise.
15419 (grub_script_lexer_record_stop): Likewise.
15420 * normal/execute.c (grub_script_execute_menuentry): New function.
15421 * normal/lexer.c (record, recording, recordpos, recordlen): New
15423 (grub_script_lexer_record_start): New function.
15424 (grub_script_lexer_record_stop): Likewise.
15425 (recordchar): Likewise.
15426 (nextchar): Likewise.
15427 (grub_script_yylex): Use `nextchar' to fetch new characters. Use
15428 2048 as the buffer size. Add the tokens `menuentry' and `@'.
15429 * normal/main.c: Include <grub/parser.h> and <grub/script.h>
15430 (current_menu): New variable.
15431 (free_menu): Mainly rewritten.
15432 (grub_normal_menu_addentry): New function.
15433 (read_config_file): Rewritten.
15434 * normal/menu.c (run_menu_entry): Mainly rewritten.
15435 * normal/menu_entry.c (make_screen): Rewritten the code to insert
15437 (run): Mainly rewritten.
15438 * normal/parser.y (menu_entry): New variable.
15439 (GRUB_PARSER_TOKEN_MENUENTRY): New token.
15440 (menuentry): New rule.
15441 (command): Add `menuentry'.
15442 (if_statement): Allow additional returns before `fi'.
15443 * normal/script.c (grub_script_create_cmdmenu): New function.
15445 2006-01-03 Marco Gerards <marco@gnu.org>
15447 * INSTALL: GNU Bison is required.
15448 * configure.ac: Rewritten the test to detect Bison.
15449 * Makefile.in (YACC): New variable. Reported by Xun Sun
15450 <xun.sun.cn@gmail.com>.
15452 2006-01-03 Marco Gerards <marco@gnu.org>
15454 * fs/hfsplus.c (grub_hfsplus_read_block): Convert the offset of
15455 the HFS+ filesystem to filesystem blocks.
15456 (grub_hfsplus_iterate_dir): Cast the `fileinfo' assignment so a
15457 GCC warning is silenced.
15459 2006-01-03 Marco Gerards <marco@gnu.org>
15461 * partmap/apple.c (apple_partition_map_iterate): Convert the data
15462 read from disk from big endian to host byte order.
15464 2006-01-03 Hollis Blanchard <hollis@penguinppc.org>
15466 * fs/hfs.c: Include <grub/hfs.h>. Added reference to the official
15468 (GRUB_HFS_EMBED_HFSPLUS_SIG): New macro.
15469 (grub_hfs_mount): Grammar fix in error. Make sure this is not an
15470 embedded HFS+ filesystem.
15471 (GRUB_HFS_MAGIC, grub_hfs_extent, grub_hfs_datarecord_t)
15472 (grub_hfs_sblock): Move from here...
15473 * include/grub/hfs.h: To here... New file.
15474 * fs/hfsplus.c: Include <grub/hfs.h>. Added reference to the official
15476 (GRUB_HFSPLUS_MAGIC, GRUB_HFSPLUSX_MAGIC, GRUB_HFSPLUS_SBLOCK):
15478 (grub_hfsplus_volheader): Change type of member `magic' to
15480 (grub_hfsplus_data): Add new member `embedded_offset'.
15481 (grub_hfsplus_read_block): Add the HFS+ wrapper offset to the
15483 (grub_hfsplus_mount): Read the HFS+ wrapper if it exists.
15484 Calculate the offset.
15486 2005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
15488 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRP_ADDR):
15490 (GRUB_BOOT_MACHINE_DRP_SIZE): Likewise.
15492 2005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
15494 * kern/env.c (grub_env_set): Check if ENV->VALUE instead of
15495 ENV->NAME is NULL after allocating ENV->VALUE.
15497 2005-12-25 Marco Gerards <marco@gnu.org>
15499 * kern/env.c (grub_env_set): Rewritten the error handling code.
15501 2005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
15503 * geninit.sh: Made more robust, and more portable.
15505 2005-12-25 Marco Gerards <marco@gnu.org>
15507 Add support for Apple HFS+ filesystems.
15509 * fs/hfsplus.c: New file.
15511 * DISTLIST: Added `fs/hfsplus.c'.
15513 * conf/common.rmk (pkgdata_MODULES): Add `hfsplus.mod'.
15514 (hfsplus_mod_SOURCES): New variable.
15515 (hfsplus_mod_CFLAGS): Likewise.
15516 (hfsplus_mod_LDFLAGS): Likewise.
15517 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/hfsplus.c'.
15518 (grub_setup_SOURCES): Likewise.
15519 (grub_mkdevicemap_SOURCES): Likewise.
15520 (grub_emu_SOURCES): Likewise.
15521 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
15523 * fs/fshelp.c (grub_fshelp_log2blksize): New function.
15525 * include/grub/fshelp.h (grub_fshelp_log2blksize): new prototype.
15527 2005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
15529 * DISTLIST: Added geninitheader.sh, geninit.sh, commands/test.c,
15530 commands/i386/pc/play.c, conf/common.mk, conf/common.rmk,
15531 include/grub/parser.h, include/grub/script.h, kern/parser.c,
15532 kern/sparc64/cache.S, normal/execute.c, normal/function.c,
15533 normal/lexer.c, normal/parser.y, normal/script.c, and
15535 Removed kern/sparc64/cache.c.
15537 * conf/common.rmk (DISTCLEANFILES): Added grub_script.tab.c,
15538 grub_script.tab.h, grub_modules_init.lst, grub_modules_init.h,
15541 * configure.ac (AC_INIT): Bumped to 1.92.
15543 2005-12-24 Vesa Jaaskelainen <chaac@nic.fi>
15545 * kern/err.c (grub_error_push): Added new function to support error
15547 (grub_error_pop): Likewise.
15548 (grub_error_stack_items): New local variable to support error stacks.
15549 (grub_error_stack_pos): Likewise.
15550 (grub_error_stack_assert): Likewise.
15551 (GRUB_ERROR_STACK_SIZE): Added new define to configure maximum error
15553 (grub_print_error): Added support to print errors from error stack.
15555 * include/grub/err.h (grub_error_push): Added function prototype.
15556 (grub_error_pop): Likewise.
15558 2005-12-09 Hollis Blanchard <hollis@penguinppc.org>
15560 * configure.ac: Accept `powerpc64' as host_cpu.
15561 (amd64): Rename to `biarch32'.
15563 * kern/powerpc/cache.S (grub_arch_sync_caches): Handle
15564 non-cacheline-aligned addresses.
15566 * kern/dl.c (grub_dl_load_core): Add grub_dprintf messages.
15567 (grub_dl_flush_cache): Likewise. Only call `grub_arch_sync_caches'
15568 if `size' is non-zero.
15570 2005-12-03 Marco Gerards <mgerards@xs4all.nl>
15572 * conf/common.rmk (grub_modules_init.lst): Use `-printf "%P\n"'
15573 and `cd' to make sure the filename is not prefixed with a
15575 (pkgdata_MODULES): Add `gpt.mod'.
15576 (gpt_mod_SOURCES): New variable.
15577 (gpt_mod_CFLAGS): Likewise.
15578 (gpt_mod_LDFLAGS): Likewise.
15580 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/gpt.c'.
15582 * include/grub/pc_partition.h (GRUB_PC_PARTITION_TYPE_GPT_DISK):
15585 * partmap/gpt.c: New file.
15587 * partmap/pc.c (pc_partition_map_iterate): Don't continue when a
15588 GPT partition map is detected.
15590 2005-12-03 Vincent Pelletier <subdino2004@yahoo.fr>
15592 * commands/i386/pc/play.c: New file.
15593 * conf/i386-pc.rmk (pkgdata_MODULES): Added play.mod.
15594 (play_mod_SOURCES, play_mod_CFLAGS, play_mod_LDFLAGS): New
15597 2005-11-27 Marco Gerards <mgerards@xs4all.nl>
15599 * include/grub/dl.h (GRUB_MOD_INIT): Use `__attribute__
15600 ((unused))' to silence gcc warning.
15602 2005-11-26 Hollis Blanchard <hollis@penguinppc.org>
15604 * configure.ac: Correct `AC_PROG_YACC' test.
15606 2005-11-22 Hollis Blanchard <hollis@penguinppc.org>
15608 * util/powerpc/ieee1275/grub-install.in: Run the mount point
15609 check before installing files.
15611 2005-11-22 Mike Small <smallm@panix.com>
15613 * util/powerpc/ieee1275/grub-install.in (grubdir): Fixed partition
15614 number regex so multidigit numbers are recognized correctly.
15616 2005-11-22 Mike Small <smallm@panix.com>
15618 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Add a
15619 debugging message before attempting to claim memory.
15620 (grub_rescue_cmd_initrd): Add a claim debugging message and try
15621 multiple addresses in case of failure.
15623 2005-11-22 Hollis Blanchard <hollis@penguinppc.org>
15625 * term/tparm.c (get_space): Remove empty `if' statement.
15627 * fs/ufs.c (grub_ufs_find_file): Remove `grub_le_to_cpu32'.
15629 * kern/parser.c (check_varstate): Rename `state' to 's'.
15631 2005-11-22 Hollis Blanchard <hollis@penguinppc.org>
15633 * partmap/acorn.c: Change `unsigned' to `unsigned int'. Move all
15634 variable definitions to the beginning of each function. Sort stack
15636 (find): Rename to `acorn_partition_map_find'. Cast `grub_disk_read'
15637 `buf' argument to `char *'.
15639 2005-11-22 Hollis Blanchard <hollis@penguinppc.org>
15641 * conf/powerpc-ieee1275.rmk: Include conf/common.mk.
15642 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
15643 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
15644 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
15645 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
15646 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
15647 configfile.mod, search.mod, gzio.mod and test.mod.
15648 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
15649 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
15650 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
15651 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
15652 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
15653 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
15654 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
15655 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
15656 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
15657 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
15658 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
15659 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
15660 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
15661 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
15662 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
15663 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
15664 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
15665 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
15666 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
15667 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
15668 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
15669 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
15670 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Removed.
15672 * conf/common.mk (grub_modules_init.lst): Use `find' instead of
15674 (pkgdata_MODULES): Add test.mod.
15676 2005-11-18 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
15678 * genmk.rb: Fixed list rules moved to Makefile.in. Recognise
15679 appending to variables with "+=".
15680 (PModule): Use full pathname to generate *.lst filenames.
15682 * Makefile.in: Fixed list rules moved from genmk.rb.
15683 (.DELETE_ON_ERROR): New special target.
15684 (RMKFILES): Add common.rmk and sparc64-ieee1275.rmk.
15686 * conf/i386-pc.rmk: Include conf/common.mk.
15687 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
15688 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
15689 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
15690 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
15691 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
15692 configfile.mod, search.mod, gzio.mod and test.mod.
15693 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
15694 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
15695 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
15696 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
15697 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
15698 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
15699 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
15700 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
15701 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
15702 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
15703 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
15704 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
15705 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
15706 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
15707 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
15708 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
15709 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
15710 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
15711 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
15712 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
15713 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
15714 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
15715 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Move from
15717 * conf/common.rmk: ... to here. New file.
15719 * conf/common.mk: New file.
15721 2005-11-18 Yoshinori K. Okuji <okuji@enbug.org>
15723 * conf/powerpc-ieee1275.rmk (grub_script.tab.h): Unified to ...
15724 (grub_script.tab.c): ... here.
15726 * conf/sparc64-ieee1275.rmk (grub_script.tab.h): Unified to ...
15727 (grub_script.tab.c): ... here.
15729 * conf/i386-pc.rmk (grub_script.tab.h): Unified to ...
15730 (grub_script.tab.c): ... here.
15732 * normal/command.c (grub_command_find): Fixed a memory leak of
15733 MODULE_NAME. Reported by Mike Small <smallm@panix.com>.
15735 2005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
15737 * include/grub/symbol.h: (FUNCTION): Use double quotes instead of
15738 "@" which marks the start of a comment on ARM.
15739 (VARIABLE): Likewise.
15741 2005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
15743 Add support for Linux/ADFS partition tables.
15745 * partmap/acorn.c: New file.
15747 * include/grub/acorn_filecore.h: Likewise.
15749 * DISTLIST: Added `partmap/acorn.c' and
15750 `include/grub/acorn_filecore.h'.
15752 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
15754 (pkgdata_MODULES): Add `acorn.mod'.
15755 (acorn_mod_SOURCES): New variable.
15756 (acorn_mod_CFLAGS): Likewise.
15758 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
15760 (pkgdata_MODULES): Add `acorn.mod'.
15761 (acorn_mod_SOURCES): New variable.
15762 (acorn_mod_CFLAGS): Likewise.
15764 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/acorn.c'.
15765 (pkgdata_MODULES): Add `acorn.mod'.
15766 (acorn_mod_SOURCES): New variable.
15767 (acorn_mod_CFLAGS): Likewise.
15768 (acorn_mod_LDFLAGS): Likewise.
15770 * include/types.h (grub_disk_addr_t): New typedef.
15772 2005-11-13 Marco Gerards <mgerards@xs4all.nl>
15774 * geninit.sh: New file.
15776 * geninitheader.sh: Likewise.
15778 * commands/boot.c (grub_boot_init, grub_boot_fini): Removed.
15779 * commands/cat.c (grub_cat_init, grub_cat_fini): Likewise.
15780 * commands/cmp.c (grub_cmp_init, grub_cmp_fini): Likewise.
15781 * commands/configfile.c (grub_configfile_init)
15782 (grub_configfile_fini): Likewise.
15783 * commands/default.c (grub_default_init, grub_default_fini):
15785 * commands/help.c (grub_help_init, grub_help_fini): Likewise.
15786 * commands/ls.c (grub_ls_init, grub_ls_fini): Likewise.
15787 * commands/search.c (grub_search_init, grub_search_fini): Likewise.
15788 * commands/terminal.c (grub_terminal_init, grub_terminal_fini):
15790 * commands/test.c (grub_test_init, grub_test_fini): Likewise.
15791 * commands/timeout.c (grub_timeout_init, grub_timeout_fini):
15793 * commands/i386/pc/halt.c (grub_halt_init, grub_halt_fini): Likewise.
15794 * commands/ieee1275/halt.c (grub_halt_init, grub_halt_fini):
15796 * commands/i386/pc/reboot.c (grub_reboot_init, grub_reboot_fini):
15798 * commands/ieee1275/reboot.c (grub_reboot_init, grub_reboot_fini):
15800 * disk/loopback.c (grub_loop_init, grub_loop_fini): Likewise.
15801 * fs/affs.c (grub_affs_init, grub_affs_fini): Likewise.
15802 * fs/ext2.c (grub_ext2_init, grub_ext2_fini): Likewise.
15803 * fs/fat.c (grub_fat_init, grub_fat_fini): Likewise.
15804 * fs/hfs.c (grub_hfs_init, grub_hfs_fini): Likewise.
15805 * fs/iso9660.c (grub_iso9660_init, grub_iso9660_fini): Likewise.
15806 * fs/jfs.c (grub_jfs_init, grub_jfs_fini): Likewise.
15807 * fs/minix.c (grub_minix_init, grub_minix_fini): Likewise.
15808 * fs/sfs.c (grub_sfs_init, grub_sfs_fini): Likewise.
15809 * fs/ufs.c (grub_ufs_init, grub_ufs_fini): Likewise.
15810 * fs/xfs.c (grub_xfs_init, grub_xfs_fini): Likewise.
15811 * normal/main.c (grub_normal_init, grub_normal_fini): Likewise.
15812 * partmap/amiga.c (grub_amiga_partition_map_init)
15813 (grub_amiga_partition_map_fini): Likewise.
15814 * partmap/apple.c (grub_apple_partition_map_init)
15815 (grub_apple_partition_map_fini): Likewise.
15816 * partmap/pc.c (grub_pc_partition_map_init)
15817 (grub_pc_partition_map_fini): Likewise.
15818 * partmap/sun.c (grub_sun_partition_map_init,
15819 grub_sun_partition_map_fini): Likewise.
15820 * term/terminfo.c (grub_terminal_init, grub_terminal_fini):
15823 * util/grub-emu.c: Include <grub_modules_init.h>.
15824 (main): Don't initialize and de-initialize any modules directly,
15825 use `grub_init_all' and `grub_fini_all' instead.
15827 * term/i386/pc/vesafb.c (grub_vesafb_init): Renamed to
15828 `grub_vesafb_mod_init'.
15829 (grub_vesafb_fini): Renamed to `grub_vesafb_mod_fini'. Updated
15831 * term/i386/pc/vga.c (grub_vga_init): Renamed to
15832 `grub_vga_mod_init'. Updated all users.
15833 (grub_vga_fini): Renamed to `grub_vga_mod_fini'.
15835 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `grub_emu_init.c'.
15836 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c): New
15839 * include/grub/dl.h (GRUB_MOD_INIT): Add argument `name'.
15840 Generate a function to initialize the module in utilities.
15841 Updated all callers.
15842 (GRUB_MOD_FINI): Add argument `name'. Generate a function to
15843 initialize the module in utilities. Updated all callers.
15845 2005-11-09 Hollis Blanchard <hollis@penguinppc.org>
15847 * term/ieee1275/ofconsole.c (grub_ofconsole_cls): Use both the ANSI
15848 escape sequence and a literal ^L to clear the screen.
15850 * commands/ieee1275/suspend.c (grub_cmd_suspend): Clear the screen
15851 when returning from Open Firmware.
15853 2005-11-09 Hollis Blanchard <hollis@penguinppc.org>
15855 * term/ieee1275/ofconsole.c (grub_ofconsole_width): New variable.
15856 (grub_ofconsole_height): Likewise.
15857 (grub_ofconsole_putchar): If `grub_curr_x' exceeds console width,
15858 manually insert a '\n'.
15859 (grub_ofconsole_getwh): Set and return `grub_ofconsole_width' and
15860 `grub_ofconsole_height'. Return early if these are already set.
15862 2005-11-07 Vincent Pelletier <subdino2004@yahoo.fr>
15864 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
15865 `commands/test.c', `fs/affs.c', `fs/sfs.c', `fs/xfs.c',
15866 `normal/execute.c', `normal/lexer.c', `io/gzio.c',
15867 `kern/parser.c', `grub_script.tab.c', `normal/function.c'
15868 and `normal/script.c'.
15869 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
15870 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
15871 (test_mod_SOURCES): New variable.
15872 (test_mod_CFLAGS): Likewise.
15873 (test_mod_LDFLAGS): Likewise.
15874 (pkgdata_MODULES): Add `test.mod'.
15875 (grub_script.tab.c): New rule.
15876 (grub_script.tab.h): Likewise.
15878 2005-11-07 Marco Gerards <mgerards@xs4all.nl>
15880 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
15881 `commands/test.c', `normal/execute.c', `normal/lexer.c',
15882 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
15883 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
15884 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
15885 (test_mod_SOURCES): New variable.
15886 (test_mod_CFLAGS): Likewise.
15887 (pkgdata_MODULES): Add `test.mod'.
15888 (grub_script.tab.c): New rule.
15889 (grub_script.tab.h): Likewise.
15891 2005-11-06 Marco Gerards <mgerards@xs4all.nl>
15893 Add initial scripting support.
15895 * commands/test.c: New file.
15896 * include/grub/script.h: Likewise.
15897 * normal/execute.c: Likewise.
15898 * normal/function.c: Likewise.
15899 * normal/lexer.c: Likewise.
15900 * normal/parser.y: Likewise.
15901 * normal/script.c: Likewise.
15903 * configure.ac: Add `AC_PROG_YACC' test.
15905 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/test.c',
15906 `normal/execute.c', `normal/lexer.c', `grub_script.tab.c',
15907 `normal/function.c' and `normal/script.c'.
15908 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
15909 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
15910 (test_mod_SOURCES, test_mod_CFLAGS, test_mod_LDFLAGS): New
15912 (pkgdata_MODULES): Add `test.mod'.
15913 (grub_script.tab.c): New rule.
15914 (grub_script.tab.h): Likewise.
15916 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TEST_FAILURE'.
15918 * include/grub/normal.h (grub_test_init): New prototype.
15919 (grub_test_fini): Likewise.
15921 * normal/command.c: Include <grub/script.h>.
15922 (grub_command_execute): Rewritten.
15924 * util/grub-emu.c (main): Call `grub_test_init' and
15927 2005-11-03 Hollis Blanchard <hollis@penguinppc.org>
15929 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Initialize `msecs'
15931 * term/ieee1275/ofconsole.c (grub_ofconsole_checkkey): Return -1 if
15932 there are no pending characters.
15934 2005-11-03 Hollis Blanchard <hollis@penguinppc.org>
15936 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_get_devname): Use
15937 `grub_strndup' to drop device arguments. Replace unnecessary
15938 `grub_strndup' with `grub_strdup'.
15940 2005-11-03 Hollis Blanchard <hollis@penguinppc.org>
15942 * kern/term.c (grub_cls): Do not call grub_cur_term->cls() if the
15943 `debug' environment variable has been set.
15945 2005-11-02 Hollis Blanchard <hollis@penguinppc.org>
15947 * Makefile.in (install-local): Use $(DATA).
15948 (uninstall): Likewise.
15949 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Move grub-mkimage...
15950 (sbin_UTILITIES): ... to here.
15951 (sbin_SCRIPTS): New variable.
15952 (grub_install_SOURCES): New variable.
15953 * util/powerpc/ieee1275/grub-install.in: New file.
15954 * util/powerpc/ieee1275/grub-mkimage.c (kernel_path): Remove
15956 (add_segments): Call `grub_util_get_path'.
15958 2005-10-28 Yoshinori K. Okuji <okuji@enbug.org>
15960 From Timothy Baldwin:
15961 * commands/ls.c (grub_ls_list_files): Close FILE with
15963 * kern/misc.c (grub_vsprintf): Terminate the string S with NUL.
15965 2005-10-24 Marco Gerards <mgerards@xs4all.nl>
15967 * include/grub/parser.h: New file.
15969 * kern/parser.c: Likewise.
15971 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/parser.c'.
15972 (grub_setup_SOURCES): Likewise.
15973 (grub_probefs_SOURCES): Likewise.
15974 (grub_emu_SOURCES): Likewise.
15975 (kernel_img_HEADERS): Add `parser.h'.
15977 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
15978 (grub_emu_SOURCES): Add `kern/parser.c'.
15979 (grubof_SOURCES): Likewise.
15981 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
15982 (grubof_SOURCES): Add `kern/parser.c'.
15984 * include/grub/misc.h (grub_split_cmdline): Removed prototype.
15986 * kern/misc.c (grub_split_cmdline): Removed function.
15988 * kern/rescue.c: Include <grub/parser.h>.
15989 (grub_enter_rescue_mode): Use `grub_parser_split_cmdline' instead
15990 of `grub_split_cmdline'.
15992 * normal/command.c: Include <grub/parser.h>.
15993 (grub_command_execute): Use `grub_parser_split_cmdline' instead
15994 of `grub_split_cmdline'.
15996 * normal/completion.c: Include <grub/parser.h>.
15997 (cmdline_state): New variable.
15998 (iterate_dir): End the filename with a quote depending on the
15999 command line state.
16000 (get_state): new function.
16001 (grub_normal_do_completion): Use `grub_parser_split_cmdline' to
16002 split the arguments and determine the current argument. When the
16003 argument string is not quoted, escape all spaces.
16005 2005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
16007 * normal/sparc64/setjmp.S: New file.
16009 2005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
16011 * include/grub/sparc64/libgcc.h: New file.
16012 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Remove -Av9.
16013 (normal_mod_SOURCES): Use normal/sparc64/setjmp.S instead of
16014 normal/sparc64/setjmp.c.
16016 2005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
16018 * kern/sparc64/dl.c: Rewritten for SPARCV9 ELF.
16019 * kern/sparc64/cache.S: New file.
16020 * kern/sparc64/cache.c: Removed.
16021 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Add -Av9.
16022 (COMMON_CFLAGS): Add -mno-app-regs. Remove -mcpu=v9 and
16024 (COMMON_LDFLAGS): Add -melf64_sparc.
16025 (grubof_HEADERS): Add sparc64/libgcc.h and machine/kernel.h.
16026 (grubof_SOURCES): Use cache.S instead of cache.c.
16027 (grubof_LDFLAGS): Add -mno-app-regs. Replace "-Xlinker
16028 --oformat -Xlinker elf64-sparc" by "-Bstatic,-melf64_sparc".
16029 (pkgdata_MODULES): Uncomment. Leave linux.mod and _linux.mod
16031 (normal_mod_SOURCES): Add normal/completion.c and normal/misc.c.
16032 (_linux_mod_SOURCES, _linux_mod_CFLAGS, linux_mod_SOURCES)
16033 (linux_mod_CFLAGS): Commented out.
16034 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS): New macro, commented
16035 out because module isn't built.
16036 (fshelp_mod_LDFLAGS, fat_mod_LDFLAGS, ext2_mod_LDFLAGS)
16037 (ufs_mod_LDFLAGS, minix_mod_LDFLAGS, hfs_mod_LDFLAGS)
16038 (jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS, normal_mod_LDFLAGS)
16039 (hello_mod_LDFLAGS, boot_mod_LDFLAGS, terminal_mod_LDFLAGS)
16040 (ls_mod_LDFLAGS, cmp_mod_LDFLAGS, cat_mod_LDFLAGS)
16041 (font_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
16042 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
16043 (suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS)
16044 (help_mod_LDFLAGS, default_mod_LDFLAGS, timeout_mod_LDFLAGS)
16045 (configfile_mod_LDFLAGS, search_mod_LDFLAGS, xfs_mod_SOURCES)
16046 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
16047 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
16048 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, gzio_mod_SOURCES)
16049 (gzio_mod_CFLAGS, gzio_mod_LDFLAGS): New macro.
16051 2005-10-20 Yoshinori K. Okuji <okuji@enbug.org>
16053 * util/i386/pc/grub-probefs.c (main): Call grub_xfs_init and
16054 grub_xfs_fini. Do not call grub_hfs_init or grub_hfs_fini any
16055 longer, because HFS should not be used on PC.
16057 2005-10-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
16059 * io/gzio.c (grub_gzio_read): Use OFFSET instead of FILE->OFFSET
16060 consistently within the loop.
16062 2005-10-15 Marco Gerards <mgerards@xs4all.nl>
16064 * fs/xfs.c (grub_xfs_iterate_dir): Detect an error if part of a
16065 directory can not be read.
16067 2005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
16069 * configure.ac (AC_INIT): Increase the version number to 1.91.
16071 * DISTLIST: Added include/grub/terminfo.h, include/grub/tparm.h,
16072 include/grub/i386/pc/serial.h, term/terminfo.c, term/tparm.c and
16073 term/i386/pc/serial.c.
16075 2005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
16077 * kern/file.c (grub_file_seek): Seeking to an offset equal to a
16078 file size must be permitted.
16080 * kern/i386/pc/startup.S (multiboot_trampoline): Fix a mistake
16081 between %ah and %al.
16083 2005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
16085 * fs/xfs.c (grub_xfs_iterate_dir): Change the type of BLK to
16087 Call the hook with a NUL-terminated filename.
16088 (grub_xfs_mount): Use grub_be_to_cpu32 instead of
16091 * kern/term.c (cursor_state): New variable.
16092 (grub_term_set_current): Reset the cursor state on a new
16094 (grub_setcursor): Rewritten to use CURSOR_STATE.
16095 (grub_getcursor): New function.
16097 * include/grub/term.h (grub_getcursor): New prototype.
16099 * io/gzio.c (test_header): Align BUF for accessing it as 32-bit
16100 integers on ARM. Reported by Timothy Baldwin
16101 <T.E.Baldwin99@members.leeds.ac.uk>.
16103 2005-10-11 Marco Gerards <mgerards@xs4all.nl>
16105 * fs/sfs.c (grub_sfs_open): Don't free `data->label' if it is not
16107 (grub_sfs_dir): Likewise.
16109 2005-10-09 Marco Gerards <mgerards@xs4all.nl>
16111 Add support for the SFS filesystem.
16113 * fs/sfs.c: New file.
16115 * DISTLIST: Added `fs/sfs.c'.
16117 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/sfs.c'.
16118 (grub_probefs_SOURCES): Likewise.
16119 (grub_emu_SOURCES): Likewise.
16120 (pkgdata_MODULES): Add `sfs.mod'.
16121 (sfs_mod_SOURCES): New variable.
16122 (sfs_mod_CFLAGS): Likewise.
16123 (sfs_mod_LDFLAGS): Likewise.
16125 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/sfs.c'.
16126 (pkgdata_MODULES): Add `sfs.mod'.
16127 (sfs_mod_SOURCES): New variable.
16128 (sfs_mod_CFLAGS): Likewise.
16130 * util/grub-emu.c (main): Call `grub_sfs_init' and
16133 * include/grub/fs.h (grub_sfs_init): New prototype.
16134 (grub_sfs_fini): Likewise.
16136 2005-10-07 Marco Gerards <mgerards@xs4all.nl>
16138 Add support for the AFFS filesystem.
16140 * fs/affs.c: New file.
16142 * DISTLIST: Added `fs/affs.c'.
16144 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/affs.c'.
16145 (grub_probefs_SOURCES): Likewise.
16146 (grub_emu_SOURCES): Likewise.
16147 (pkgdata_MODULES): Add `affs.mod'.
16148 (affs_mod_SOURCES): New variable.
16149 (affs_mod_CFLAGS): Likewise.
16150 (affs_mod_LDFLAGS): Likewise.
16152 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/affs.c'.
16153 (pkgdata_MODULES): Add `affs.mod'.
16154 (affs_mod_SOURCES): New variable.
16155 (affs_mod_CFLAGS): Likewise.
16157 * util/grub-emu.c (main): Call `grub_affs_init' and
16160 * include/grub/fs.h (grub_affs_init): New prototype.
16161 (grub_affs_fini): Likewise.
16163 2005-10-01 Marco Gerards <mgerards@xs4all.nl>
16165 * fs/xfs.c (grub_xfs_iterate_dir): Add parentheses.
16167 2005-10-01 Marco Gerards <mgerards@xs4all.nl>
16169 * configure.ac: Accept `x86_64' as host_cpu. In that case add
16172 * genmk.rb (class PModule): Always use `$(#{prefix}_LDFLAGS)' when
16175 * conf/i386-pc.rmk (COMMON_CFLAGS): Add `-m32'.
16176 (COMMON_LDFLAGS): New variable.
16177 (kernel_img_LDFLAGS): Include `COMMON_FLAGS'.
16178 (_chain_mod_LDFLAGS, fshelp_mod_LDFLAGS, fat_mod_LDFLAGS)
16179 (ext2_mod_LDFLAGS, ufs_mod_LDFLAGS, minix_mod_LDFLAGS)
16180 (hfs_mod_LDFLAGS, jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS)
16181 (xfs_mod_LDFLAGS, _linux_mod_LDFLAGS, linux_mod_LDFLAGS)
16182 (normal_mod_LDFLAGS, hello_mod_LDFLAGS, boot_mod_LDFLAGS)
16183 (terminal_mod_LDFLAGS, ls_mod_LDFLAGS, cmp_mod_LDFLAGS)
16184 (cat_mod_LDFLAGS, help_mod_LDFLAGS, reboot_mod_LDFLAGS)
16185 (halt_mod_LDFLAGS, vga_mod_LDFLAGS, font_mod_LDFLAGS)
16186 (terminfo_mod_LDFLAGS, serial_mod_LDFLAGS, _multiboot_mod_LDFLAGS)
16187 (multiboot_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
16188 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
16189 (default_mod_LDFLAGS, timeout_mod_LDFLAGS, configfile_mod_LDFLAGS)
16190 (vbe_mod_LDFLAGS, vesafb_mod_LDFLAGS, vbeinfo_mod_LDFLAGS)
16191 (vbetest_mod_LDFLAGS, search_mod_LDFLAGS, gzio_mod_LDFLAGS): New
16193 (normal_mod_ASFLAGS): Add `-m32'.
16195 * include/grub/types.h (grub_host_addr_t, grub_host_off_t)
16196 (grub_host_size_t, grub_host_ssize_t): New types.
16197 (grub_addr_t, grub_off_t, grub_size_t, grub_ssize_t): Make type
16198 dependent of `GRUB_CPU_SIZEOF_VOID_P' instead on
16199 `GRUB_HOST_SIZEOF_VOID_P'.
16201 * include/grub/kernel.h (struct grub_module_header): Type of
16202 member offset changed to `grub_host_off_t'. Type of member size
16203 changed to `grub_host_size_t'.
16204 (struct grub_module_info): Type of member offset changed to
16205 `grub_host_off_t'. Type of member size changed to
16206 `grub_host_size_t'.
16208 2005-09-29 Yoshinori K. Okuji <okuji@enbug.org>
16210 Make GRUB's kernel compliant to Multiboot Specification.
16212 * kern/i386/pc/startup.S (multiboot_header): New label.
16213 (multiboot_entry): Likewise.
16214 (multiboot_trampoline): Likewise.
16216 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
16217 Increased to 0x4A0.
16219 * fs/xfs.c (grub_xfs_iterate_dir): Fix a syntax error. You may not
16220 put parentheses after a question mark.
16221 [!GRUB_UTIL] (my_mod): New variable.
16223 * util/grub-emu.c (main): Call grub_xfs_init and grub_xfs_fini.
16225 2005-09-28 Marco Gerards <mgerards@xs4all.nl>
16227 Adds support for the XFS filesystem. Btrees are not supported
16230 * fs/xfs.c: New file.
16232 * DISTLIST: Added `fs/xfs.c'.
16234 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/xfs.c'.
16235 (grub_probefs_SOURCES): Likewise.
16236 (grub_emu_SOURCES): Likewise.
16237 (pkgdata_MODULES): Add `xfs.mod'.
16238 (xfs_mod_SOURCES): New variable.
16239 (xfs_mod_CFLAGS): Likewise.
16241 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/xfs.c'.
16242 (pkgdata_MODULES): Add `xfs.mod'.
16243 (xfs_mod_SOURCES): New variable.
16244 (xfs_mod_CFLAGS): Likewise.
16246 * util/grub-emu.c (main): Call `grub_xfs_init' and
16249 * include/grub/fs.h (grub_xfs_init): New prototype.
16250 (grub_xfs_fini): Likewise.
16253 2005-09-18 Vesa Jaaskelainen <chaac@nic.fi>
16255 * video/i386/pc/vbe.c (grub_vbe_set_video_mode): In indexed
16256 color modes, allow greater than 16 colors to be configured as
16259 2005-09-03 Yoshinori K. Okuji <okuji@enbug.org>
16261 * normal/completion.c (complete_arguments): Add the qualifier
16262 const into OPTIONS.
16264 From Omniflux <omniflux+lists@omniflux.com>:
16265 * include/grub/terminfo.h: New file.
16266 * include/grub/tparm.h: Likewise.
16267 * include/grub/i386/pc/serial.h: Likewise.
16268 * term/terminfo.c: Likewise.
16269 * term/tparm.c: Likewise.
16270 * term/i386/pc/serial.c: Likewise.
16271 * conf/i386-pc.rmk (pkgdata_MODULES): Added terminfo.mod and
16273 (terminfo_mod_SOURCES): New variable.
16274 (terminfo_mod_CFLAGS): Likewise.
16275 (serial_mod_SOURCES): Likewise.
16276 (serial_mod_CFLAGS): Likewise.
16278 2005-08-31 Yoshinori K. Okuji <okuji@enbug.org>
16280 * DISTLIST: Replaced boot/powerpc/ieee1275/crt0.S and
16281 boot/powerpc/ieee1275/cmain.c with kern/powerpc/ieee1275/crt0.S
16282 and kern/powerpc/ieee1275/cmain.c, respectively.
16284 * boot/powerpc/ieee1275/crt0.S: Moved to ...
16285 * kern/powerpc/ieee1275/crt0.S: ... here.
16287 * boot/powerpc/ieee1275/cmain.c: Moved to ...
16288 * kern/powerpc/ieee1275/cmain.c: ... here.
16290 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Use
16291 kern/powerpc/ieee1275/crt0.S and kern/powerpc/ieee1275/cmain.c
16292 instead of boot/powerpc/ieee1275/crt0.S and
16293 boot/powerpc/ieee1275/cmain.c, respectively.
16295 * boot/i386/pc/boot.S (lba_mode): Do not store the total number of
16296 sectors. It was not used anyway.
16298 2005-08-30 Hollis Blanchard <hollis@penguinppc.org>
16300 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): Fix
16301 `unused parameter' warning.
16303 2005-08-30 Hollis Blanchard <hollis@penguinppc.org>
16305 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): New
16307 (grub_ofconsole_term): Specify grub_ofconsole_getcharwidth as
16310 2005-08-28 Marco Gerards <metgerards@student.han.nl>
16312 * include/grub/normal.h (enum grub_completion_type): Added
16313 `GRUB_COMPLETION_TYPE_ARGUMENT'.
16315 * normal/cmdline.c (print_completion): Handle
16316 the `GRUB_COMPLETION_TYPE_ARGUMENT' type.
16317 * normal/menu_entry.c (store_completion): Likewise.
16319 * normal/completion.c (complete_arguments): New function.
16320 (grub_normal_do_completion): Call `complete_arguments' when the
16321 current words start with a dash.
16323 2005-08-27 Marco Gerards <metgerards@student.han.nl>
16325 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Fix typo (use
16326 `gzio.mod' instead of `io.mod').
16328 2005-08-22 Yoshinori K. Okuji <okuji@enbug.org>
16330 * gendistlist.sh (EXTRA_DISTFILES): Added genfslist.sh.
16331 (DISTDIRS): Added io and video.
16332 Rewrite the search routine to make an output consistently.
16334 * DISTLIST: Added conf/sparc64-ieee1275.mk,
16335 conf/sparc64-ieee1275.rmk, include/grub/gzio.h,
16336 include/grub/ieee1275/ieee1275.h, include/grub/ieee1275/ofdisk.h,
16337 io/gzio.c, kern/sparc64/cache.c, kern/sparc64/dl.c,
16338 kern/sparc64/ieee1275/init.c, kern/sparc64/ieee1275/openfw.c and
16339 util/powerpc/ieee1275/misc.c.
16341 * include/grub/gzio.h: New file.
16342 * io/gzio.c: Likewise.
16344 * kern/file.c (grub_file_close): Call grub_device_close only if
16345 FILE->DEVICE is not NULL.
16347 * include/grub/mm.h [!NULL] (NULL): New macro.
16349 * include/grub/err.h (GRUB_ERR_BAD_GZIP_DATA): New constant.
16351 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added io/gzip.c.
16352 (pkgdata_MODULES): Added gzio.mod.
16353 (gzio_mod_SOURCES): New variable.
16354 (gzio_mod_CFLAGS): Likewise.
16356 * conf/i386-pc.rmk (grub_emu_SOURCES): Added io/gzip.c.
16357 (pkgdata_MODULES): Added gzio.mod.
16358 (gzio_mod_SOURCES): New variable.
16359 (gzio_mod_CFLAGS): Likewise.
16361 * commands/cat.c: Include grub/gzio.h.
16362 (grub_cmd_cat): Use grub_gzfile_open instead of
16365 * commands/cmp.c: Include grub/gzio.h.
16366 (grub_cmd_cmp): Use grub_gzfile_open instead of
16369 * loader/i386/pc/multiboot.c: Include grub/gzio.h.
16370 (grub_rescue_cmd_multiboot): Use grub_gzfile_open instead of
16372 (grub_rescue_cmd_module): Likewise.
16374 2005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
16376 * conf/sparc64-ieee1275.rmk (grubof_SOURCES): The first file must be
16377 kern/sparc64/ieee1275/init.c because it contains _start.
16378 * conf/sparc64-ieee1275.mk: Generated from conf/sparc64-ieee1275.rmk.
16380 2005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
16382 * configure.ac: Add support for sparc64 host with ieee1275
16384 * configure: Generated from configure.ac.
16385 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Use grub_ssize_t
16387 (grub_ofdisk_read): Likewise.
16388 (grub_ofdisk_open): Use %p to print pointer values, and cast the
16389 pointers as (void *) to remove a warning.
16390 (grub_ofdisk_close): Likewise.
16391 (grub_ofdisk_read): Likewise.
16392 * kern/ieee1275/ieee1275.c (grub_ieee1275_exit): This never
16393 returns, so make it return void to remove a warning.
16394 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_exit):
16395 Corresponding prototype change.
16396 * kern/mm.c (grub_mm_init_region): Use %p to print pointer
16397 values, and cast the pointers as (void *) to remove a warning.
16398 (grub_mm_dump): Likewise.
16399 * conf/sparc64-ieee1275.mk: New file.
16400 * conf/sparc64-ieee1275.rmk: Likewise.
16401 * include/grub/sparc64/setjmp.h: Likewise.
16402 * include/grub/sparc64/types.h: Likewise.
16403 * include/grub/sparc64/ieee1275/console.h: Likewise.
16404 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
16405 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
16406 * include/grub/sparc64/ieee1275/time.h: Likewise.
16407 * kern/sparc64/cache.c: Likewise.
16408 * kern/sparc64/dl.c: Likewise.
16409 * kern/sparc64/ieee1275/init.c: Likewise.
16410 * kern/sparc64/ieee1275/openfw.c: Likewise.
16412 2005-08-21 Yoshinori K. Okuji <okuji@enbug.org>
16414 * util/console.c (grub_ncurses_putchar): If C is greater than
16415 0x7f, set C to a question mark.
16416 (grub_ncurses_getcharwidth): New function.
16417 (grub_ncurses_term): Specify grub_ncurses_getcharwidth as
16420 * normal/menu.c (print_entry): Made aware of Unicode. First,
16421 convert TITLE to UCS-4, and predict the cursor position by
16424 * include/grub/misc.h (grub_utf8_to_ucs4): Specify the qualifier
16426 * kern/misc.c (grub_utf16_to_utf8): Likewise.
16428 2005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
16430 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Specify
16431 the boot file by the option BOOT_IMAGE. Use grub_stpcpy instead of
16434 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Specify the boot
16435 file by the option BOOT_IMAGE. Use grub_stpcpy instead of
16436 grub_strcpy and grub_strlen. Take it into account that a space
16437 character is inserted as a delimiter.
16439 2005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
16441 * partmap/pc.c (pc_partition_map_iterate): Include the value of an
16442 invalid magic in the error.
16444 * commands/search.c: New file.
16446 * util/grub-emu.c (main): Call grub_search_init and
16449 * kern/rescue.c (grub_rescue_print_disks): Removed.
16450 (grub_rescue_print_devices): New function.
16451 (grub_rescue_cmd_ls): Use grub_device_iterate with
16452 grub_rescue_print_devices instead of grub_disk_dev_iterate with
16453 grub_rescue_print_disks.
16455 * kern/partition.c (grub_partition_iterate): Return the result of
16456 PARTMAP->ITERATE instead of GRUB_ERRNO.
16458 * kern/device.c: Include grub/partition.h.
16459 (grub_device_iterate): New function.
16461 * include/grub/partition.h (grub_partition_iterate): Return int
16462 instead of grub_err_t.
16464 * include/grub/normal.h [GRUB_UTIL] (grub_search_init): New
16466 [GRUB_UTIL] (grub_search_fini): Likewise.
16468 * include/grub/device.h (grub_device_iterate): New prototype.
16470 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
16472 (pkgdata_MODULES): Added search.mod.
16473 (search_mod_SOURCES): New variable.
16474 (search_mod_CFLAGS): Likewise.
16476 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/search.c.
16477 (pkgdata_MODULES): Added search.mod.
16478 (search_mod_SOURCES): New variable.
16479 (search_mod_CFLAGS): Likewise.
16481 * commands/ls.c (grub_ls_list_disks): Renamed to ...
16482 (grub_ls_list_devices): ... this, and use grub_device_iterate.
16483 All callers changed.
16485 * DISTLIST: Added commands/search.c.
16487 2005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
16489 * kern/term.c (grub_putchar): Use grub_utf8_to_ucs4 for the
16491 (grub_getcharwidth): New function.
16493 * kern/misc.c (grub_utf8_to_ucs4): New function.
16495 * include/grub/term.h (struct grub_term): Added a new member
16497 (grub_getcharwidth): New prototype.
16499 * include/grub/misc.h (grub_utf8_to_ucs4): New prototype.
16501 * term/i386/pc/console.c (map_char): New function. Segregated from
16502 grub_console_putchar.
16503 (grub_console_putchar): Use map_char.
16504 (grub_console_getcharwidth): New function.
16505 (grub_console_term): Specified grub_console_getcharwidth as
16508 * term/i386/pc/vga.c (grub_vga_getcharwidth): New function.
16509 (grub_vga_term): Specified grub_vga_getcharwidth as getcharwidth.
16511 * term/i386/pc/vesafb.c (grub_virtual_screen_setup): Return
16513 (grub_vesafb_init): Do not use RC. Instead, use GRUB_ERRNO. Rely
16514 on grub_strtoul completely.
16515 (write_char): Declare local variables in the beginning of the
16517 (grub_vesafb_getcharwidth): New function.
16518 (grub_vesafb_term): Specified grub_vesafb_getcharwidth as
16521 2005-08-19 Yoshinori K. Okuji <okuji@enbug.org>
16523 * DISTLIST: Replace commands/i386/pc/vbe_list_modes.c and
16524 commands/i386/pc/vbe_test.c with commands/i386/pc/vbeinfo.c and
16525 commands/i386/pc/vbetest.c.
16527 * video/i386/pc/vbe.c (grub_vbe_probe): If INFOBLOCK is not NULL,
16528 call grub_vbe_get_controller_info again, because the returned
16529 information is volatile.
16530 (grub_vbe_set_video_mode): Mostly rewritten.
16531 (grub_vbe_get_video_mode): Use grub_vbe_probe and use
16532 grub_vbe_status_t correctly.
16533 (grub_vbe_get_video_mode_info): Likewise.
16534 (grub_vbe_set_pixel_rgb): Use a switch statement rather than
16535 several if statements.
16537 * commands/i386/pc/vbe_list_modes.c: Renamed to ...
16538 * commands/i386/pc/vbeinfo.c: ... this.
16540 * commands/i386/pc/vbe_test.c: Renamed to ...
16541 * commands/i386/pc/vbetest.c: ... this.
16543 * commands/i386/pc/vbeinfo.c (grub_cmd_vbe_list_modes): Renamed to
16545 (grub_cmd_vbeinfo): ... this. Save video modes before
16546 iterating. Skip a video mode, if it is not available, not enough
16547 information is given or it is monochrome. Show the memory
16548 model. Leave the interpretation of MODEVAR to grub_strtoul
16550 (GRUB_MOD_INIT): Rename vbe_list_modes to vbeinfo.
16551 (GRUB_MOD_FINI): Likewise.
16553 * commands/i386/pc/vbetest.c (grub_cmd_vbe_test): Renamed to ...
16554 (grub_cmd_vbetest): ... this. Don't print unnecessarily. Use
16555 grub_err_t instead of grub_uint32_t. Don't use SPTR. Remove a
16556 duplicated grub_env_get. Leave the interpretation of MODEVAR to
16557 grub_strtoul completely.
16558 (real2pm): Removed.
16559 (GRUB_MOD_INIT): Rename vbe_test to vbetest.
16560 (GRUB_MOD_FINI): Likewise.
16562 * normal/misc.c: Include grub/mm.h.
16564 * conf/i386-pc.rmk (pkgdata_MODULES): Replaced vbe_test.mod and
16565 vbe_list_modes with vbetest.mod and vbeinfo.mod.
16566 (vbe_list_modes_mod_SOURCES): Removed.
16567 (vbe_list_modes_mod_CFLAGS): Likewise.
16568 (vbe_test_mod_SOURCES): Likewise.
16569 (vbe_test_mod_CFLAGS): Likewise.
16570 (vbeinfo_mod_SOURCES): New variable.
16571 (vbeinfo_mod_CFLAGS): Likewise.
16572 (vbetest_mod_SOURCES): Likewise.
16573 (vbetest_mod_CFLAGS): Likewise.
16575 2005-08-18 Yoshinori K. Okuji <okuji@enbug.org>
16577 * normal/misc.c: New file.
16579 * DISTLIST: Added normal/misc.c.
16581 * partmap/amiga.c (amiga_partition_map_iterate): Add an argument
16582 DISK to HOOK. Call HOOK with DISK.
16583 * partmap/apple.c (apple_partition_map_iterate): Likewise.
16584 * partmap/pc.c (pc_partition_map_iterate): Likewise.
16585 * partmap/sun.c (sun_partition_map_iterate): Likewise.
16587 * normal/menu_entry.c (struct screen): Added a new member
16588 "completion_shown".
16589 (completion_buffer): New global variable.
16590 (make_screen): Set SCREEN->COMPLETION_SHOWN to zero.
16591 (store_completion): New function.
16592 (complete): Likewise.
16593 (clear_completions): Likewise.
16594 (grub_menu_entry_run): If SCREEN->COMPLETION_SHOWN is non-zero,
16595 call clear_completions and reset SCREEN->COMPLETION_SHOWN. If C is
16596 a tab, call complete.
16598 * normal/completion.c (disk_dev): Removed.
16599 (print_simple_completion): Likewise.
16600 (print_partition_completion): Likewise.
16601 (print_func): New global variable.
16602 (add_completion): Do not take the arguments WHAT or PRINT any
16603 longer. Added a new argument TYPE. Instead of printing directly,
16604 call PRINT_FUNC if not NULL.
16605 All callers changed.
16606 (complete_device): Use a local variable DEV instead of
16607 DISK_DEV. Do not move CURRENT_WORD to the end of a device name.
16608 (grub_normal_do_completion): Take a new argument HOOK. Do not
16609 initialize DISK_DEV. Initialize PRINT_FUNC to HOOK. If RET is an
16610 empty string, return NULL instead.
16611 All callers changed.
16613 * normal/cmdline.c (print_completion): New function.
16615 * kern/partition.c (grub_partition_iterate): Add an argument DISK
16617 All callers changed.
16619 * kern/disk.c (grub_print_partinfo): Removed.
16621 * include/grub/partition.h (struct grub_partition_map): Add a new
16622 argument DISK into HOOK of ITERATE.
16623 (grub_partition_iterate): Add a new argument DISK to HOOK.
16625 * include/grub/normal.h (enum grub_completion_type): New enum.
16626 (grub_completion_type_t): New type.
16627 (GRUB_COMPLETION_TYPE_COMMAND): New constant.
16628 (GRUB_COMPLETION_TYPE_DEVICE): Likewise.
16629 (GRUB_COMPLETION_TYPE_PARTITION): Likewise.
16630 (GRUB_COMPLETION_TYPE_FILE): Likewise.
16631 (grub_normal_do_completion): Added a new argument HOOK.
16632 (grub_normal_print_device_info): New prototype.
16634 * include/grub/disk.h (grub_print_partinfo): Removed.
16636 * conf/i386-pc.rmk (grub_emu_SOURCES): Added normal/misc.c.
16637 (normal_mod_SOURCES): Likewise.
16638 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
16639 (normal_mod_SOURCES): Likewise.
16641 * commands/ls.c (grub_ls_list_disks): Use
16642 grub_normal_print_device_info instead of grub_print_partinfo. Free
16644 (grub_ls_list_files): Use grub_normal_print_device_info instead of
16645 duplicating the code.
16647 2005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
16649 * commands/i386/pc/vbe_list_modes.c: Update source formatting to
16650 follow GCS more precisely.
16651 * commands/i386/pc/vbe_test.c: Likewise.
16652 * include/grub/i386/pc/vbe.h: Likewise.
16653 * term/i386/pc/vesafb.c: Likewise.
16654 * video/i386/pc/vbe.c: Likewise.
16656 2005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
16658 * DISTLIST: Added term/i386/pc/vesafb.c
16659 DISTLIST: Added video/i386/pc/vbe.c
16660 DISTLIST: Added commands/i386/pc/vbe_list_modes.c.
16661 DISTLIST: Added commands/i386/pc/vbe_test.c.
16662 * commands/i386/pc/vbe_list_modes.c: New file.
16663 * commands/i386/pc/vbe_test.c: Likewise.
16664 * term/i386/pc/vesafb.c: Likewise.
16665 * video/i386/pc/vbe.c: Likewise.
16666 * include/grub/i386/pc/vbe.h (GRUB_VBE_DEFAULT_VIDEO_MODE): Added define.
16667 (grub_vbe_probe) Added prototype.
16668 (grub_vbe_set_video_mode) Likewise.
16669 (grub_vbe_get_video_mode) Likewise.
16670 (grub_vbe_get_video_mode_info) Likewise.
16671 (grub_vbe_set_pixel_rgb) Likewise.
16672 (grub_vbe_set_pixel_index) Likewise.
16673 * conf/i386-pc.rmk (pkgdata_MODULES): Added vbe.mod.
16674 (pkgdata_MODULES): Added vesafb.mod.
16675 (pkgdata_MODULES): Added vbe_list_modes.mod.
16676 (pkgdata_MODULES): Added vbe_test.mod.
16677 (vbe_mod_SOURCES): Added.
16678 (vbe_mod_CFLAGS): Likewise.
16679 (vesafb_mod_SOURCES): Likewise.
16680 (vesafb_mod_CFLAGS): Likewise.
16681 (vbe_list_modes_mod_SOURCES): Likewise.
16682 (vbe_list_modes_mod_CFLAGS): Likewise.
16683 (vbe_test_mod_SOURCES): Likewise.
16684 (vbe_test_mod_CFLAGS): Likewise.
16686 2005-08-14 Yoshinori K. Okuji <okuji@enbug.org>
16688 * normal/command.c (grub_command_execute): If INTERACTIVE is
16689 false and GRUB_COMMAND_FLAG_NO_ECHO is not specified, print
16690 CMDLINE. Disable the pager if INTERACTIVE is true.
16691 All callers are changed.
16693 * normal/main.c (grub_normal_execute): Read command.lst and fs.lst
16694 before reading a config file.
16695 * normal/main.c (read_config_file): Even if a command is not
16696 found, register it if it is within an entry.
16698 * util/grub-emu.c: Include sys/types.h and unistd.h.
16699 (options): Added --hold.
16700 (struct arguments): Added a new member "hold".
16701 (parse_opt): If KEY is 'H', set ARGS->HOLD to ARG or -1 if ARG is
16703 (main): Initialize ARGS.HOLD to zero. Wait until ARGS.HOLD is
16704 cleared by a debugger, if it is not zero.
16706 * include/grub/normal.h (grub_command_execute): Add an argument
16709 2005-08-14 Vesa Jaaskelainen <chaac@nic.fi>
16711 * DISTLIST: Added include/grub/i386/pc/vbe.h.
16713 2005-08-13 Yoshinori K. Okuji <okuji@enbug.org>
16715 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Replace the test
16716 program with another one, because the old one didn't detect a bug
16717 in gcc-3.4. Always use regparm 2, because the new test is still
16718 not enough for gcc-4.0. Someone must investigate a simple test
16719 case which detects a bug in gcc-4.0.
16721 2005-08-12 Yoshinori K. Okuji <okuji@enbug.org>
16723 * DISTLIST: Added normal/completion.c.
16725 * normal/completion.c: New file.
16727 * term/i386/pc/console.c (grub_console_getwh): New function.
16728 (grub_console_term): Assign grub_console_getwh to getwh.
16730 * normal/cmdline.c (grub_tab_complete): Removed. Now the same
16731 function is defined in normal/completion.c as
16732 grub_normal_do_completion.
16733 (grub_cmdline_get): Use grub_normal_do_completion instead of
16736 * kern/partition.c (grub_partition_map_iterate): Return 1 if HOOK
16737 returns non-zero, otherwise return 0.
16738 (grub_partition_iterate): First, probe the partition map. Then,
16739 call ITERATE only for this partition map.
16741 * kern/misc.c (grub_strncmp): Rewritten.
16743 * kern/disk.c (grub_disk_dev_iterate): Return 1 if P->ITERATE
16744 returns non-zero. Otherwise return 0.
16746 * include/grub/partition.h (grub_partition_map_iterate): Return
16747 int instead of void.
16749 * include/grub/normal.h (grub_normal_do_completion): New prototype.
16751 * include/grub/misc.h (grub_strncmp): Change the type of N to
16754 * include/grub/disk.h (grub_disk_dev_iterate): Return int instead
16757 * normal/menu.c (draw_border): Cast GRUB_TERM_BORDER_WIDTH to
16758 unsigned explicitly before comparing it with I.
16760 * kern/main.c (grub_env_write_root): Add the attribute unused into
16763 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
16764 normal/completion.c.
16765 (normal_mod_SOURCES): Likewise.
16766 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
16767 (normal_mod_SOURCES): Likewise.
16769 * normal/command.c (grub_iterate_commands): If ITERATE returns
16770 non-zero, return one immediately.
16772 2005-08-09 Vesa Jaaskelainen <chaac@nic.fi>
16774 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vbe.h.
16775 * kern/i386/pc/startup.S: Updated Global Descriptor table's
16777 (grub_vbe_get_controller_info): New function.
16778 (grub_vbe_get_mode_info): Likewise.
16779 (grub_vbe_set_mode): Likewise.
16780 (grub_vbe_get_mode): Likewise.
16781 (grub_vbe_set_memory_window): Likewise.
16782 (grub_vbe_get_memory_window): Likewise.
16783 (grub_vbe_set_scanline_length): Likewise.
16784 (grub_vbe_get_scanline_length): Likewise.
16785 (grub_vbe_set_display_start): Likewise.
16786 (grub_vbe_get_display_start): Likewise.
16787 (grub_vbe_set_palette_data): Likewise.
16788 * include/grub/i386/pc/vbe.h: New file.
16790 2005-08-08 Hollis Blanchard <hollis@penguinppc.org>
16792 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
16793 kern/ieee1275/of.c with kern/ieee1275/ieee1275.c.
16794 * DISTLIST: Likewise.
16795 * kern/ieee1275/of.c: Moved to ...
16796 * kern/ieee1275/ieee1275.c: ... here.
16798 2005-08-08 Hollis Blanchard <hollis@penguinppc.org>
16800 * term/ieee1275/ofconsole.c: Include <grub/mm.h>.
16801 (grub_ofconsole_getwh): Cast -1 to type grub_ieee1275_ihandle_t.
16802 Pass 0 as `end' parameter to grub_strtoul().
16804 2005-08-08 Hollis Blanchard <hollis@penguinppc.org>
16806 * include/grub/powerpc/ieee1275/console.h: Do not include
16807 <grub/types.h>. Do not include <grub/symbol.h>. Remove ASM_FILE
16809 (grub_console_cur_color): Remove i386-specific prototype.
16810 (grub_console_real_putchar): Likewise.
16811 (grub_console_checkkey): Likewise.
16812 (grub_console_getkey): Likewise.
16813 (grub_console_getxy): Likewise.
16814 (grub_console_gotoxy): Likewise.
16815 (grub_console_cls): Likewise.
16816 (grub_console_setcursor): Likewise.
16817 * kern/powerpc/ieee1275/init.c: Don't include <grub/console.h>.
16818 Include <grub/machine/console.h>.
16819 * term/ieee1275/ofconsole.c: Likewise.
16821 2005-08-08 Yoshinori K. Okuji <okuji@enbug.org>
16823 * Makefile.in (LIBLZO): New variable.
16825 * configure.ac: Check for LZO version 2.
16827 * util/i386/pc/grub-mkimage.c [HAVE_LZO_LZO1X_H]: Include
16828 lzo/lzo1x.h instead of lzo1x.h.
16830 * conf/i386-pc.rmk (grub_mkimage_LDFLAGS): Use $(LIBLZO) instead
16833 * util/i386/pc/grub-setup.c (main): Do not free PREFIX
16834 twice. Reported by Vladimir Serbinenko <phcoder@gmail.com>.
16836 * partmap/pc.c (pc_partition_map_probe): Restore P->DATA after
16837 copying the data from PARTITION to P.
16839 2005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
16841 * kern/rescue.c (grub_rescue_cmd_rmmod): If the reference count is
16842 negative, unload the module.
16844 * util/i386/pc/grub-setup.c (setup): The name of the PC partition
16845 map is "pc_partition_map" but not "pc".
16846 (usage): Fix the description. The options are --boot-image and
16847 --core-image but not --boot-file or --core-file.
16848 (main): If not specified explicitly, make BOOT_FILE and CORE_FILE
16849 based on DEFAULT_BOOT_FILE and DEFAULT_CORE_FILE with DIR or
16852 * util/i386/pc/grub-install.in: Do not specify --boot-file or
16853 --core-file. Specify INSTALL_DEVICE as an argument.
16855 * util/console.c: Include config.h.
16856 [HAVE_NCURSeS_CURSES_H]: Include ncurses/curses.h.
16857 [HAVE_NCURSES_H]: Include ncurses.h.
16858 [HAVE_CURSES_H]: Include curses.h.
16859 [!A_NORMAL] (A_NORMAL): Defined as zero.
16860 [!A_STANDOUT] (A_STANDOUT): Likewise.
16862 * conf/i386-pc.rmk (grub_emu_LDFLAGS): Use $(LIBCURSES) instead of
16864 * conf/powerpc-ieee1275.rmk (grub_emu_LDFLAGS): Likewise.
16866 * configure.ac: Check for curses libraries and headers.
16868 * Makefile.in (LIBCURSES): New variable.
16870 * genmk.rb (Script::rule): Set the executable bits.
16872 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): The
16873 name of the PC partition map is "pc_partition_map" but not "pc".
16875 2005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
16877 * util/i386/pc/grub-install.in (grub_probefs): New variable.
16878 (modules): Likewise.
16879 (usage): Added descriptions for --modules and --grub-probefs.
16880 Handle --modules and --grub-probefs. Save the arguments in MODULES
16881 and GRUB_PROBEFS, respectively.
16882 Auto-detect a filesystem module against GRUBDIR. If the result is
16883 empty and modules are not specified explicitly, abort the
16884 installation. Add the result to MODULES.
16886 * DISTLIST: Removed boot/powerpc/ieee1275/ieee1275.c,
16887 disk/powerpc/ieee1275/ofdisk.c,
16888 include/grub/powerpc/ieee1275/init.h and
16889 term/powerpc/ieee1275/ofconsole.c.
16890 Added disk/ieee1275/ofdisk.c, kern/ieee1275/of.c and
16891 term/ieee1275/ofconsole.c.
16893 * include/grub/powerpc/ieee1275/console.h: Resurrected.
16895 * COPYING: Upgraded to the latest version. Only the address of the
16896 FSF office has changed.
16898 2005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
16900 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
16901 kern/ieee1275.c with kern/ieee1275/of.c.
16903 * kern/ieee1275.c: Moved to ...
16904 * kern/ieee1275/of.c: ... here.
16906 2005-08-06 Yoshinori K. Okuji <okuji@enbug.org>
16908 * conf/i386-pc.rmk (kernel_img_HEADERS): Reordered for
16911 * config.guess: Updated to the latest version from gnulib.
16912 * config.sub: Likewise.
16913 * install.sh: Likewise.
16914 * mkinstalldirs: Likewise.
16916 * include/grub/console.h: Removed. This file is arch-specific. Do
16917 not put this in include/grub.
16919 * include/grub/i386/pc/console.h: Resurrected.
16921 * util/console.c: Include grub/machine/console.h instead of
16923 * util/grub-emu.c: Likewise.
16925 2005-08-04 Marco Gerards <metgerards@student.han.nl>
16927 * kern/term.c (grub_putcode): Use `grub_getwh' instead of
16930 From Vincent Pelletier <subdino2004@yahoo.fr>
16931 * include/grub/term.h (GRUB_TERM_WIDTH, GRUB_TERM_HEIGHT):
16932 Redefined to use grub_getwh.
16933 (grub_term): New member named getwh.
16934 (grub_getwh): New prototype.
16935 * kern/term.c (grub_getwh): New function.
16936 * term/i386/pc/console.c (grub_console_getwh): New function.
16937 (grub_console_term): New member `getwh'.
16938 * term/i386/pc/vga.c (grub_vga_getwh): New function.
16939 (grub_vga_term): New member `getwh'.
16940 * term/ieee1275/ofconsole.c (grub_ofconsole_readkey): Use
16942 (grub_ofconsole_getw): New function.
16943 (grub_ofconsole_init): Use grub_ssize_t and unsigned char.
16944 (grub_ofconsole_term): New field named getwh and new initial
16947 2005-08-03 Hollis Blanchard <hollis@penguinppc.org>
16949 * include/grub/powerpc/ieee1275/ieee1275.h: Move ...
16950 * include/grub/ieee1275/ieee1275.h: ... to here. All users updated.
16951 Move `abort', `grub_reboot', and `grub_halt' prototypes ...
16952 * include/grub/powerpc/ieee1275/kernel.h: ... to here.
16953 * commands/ieee1275/halt.c: Include <grub/machine/kernel.h> instead
16954 of <grub/machine/ieee1275.h>.
16955 * commands/ieee1275/reboot.c: Likewise.
16956 * boot/powerpc/ieee1275/ieee1275.c: Move ...
16957 * kern/ieee1275.c: ... to here. All users updated. Change all
16958 parameter structs to use new type `grub_ieee1275_cell_t'.
16959 * term/powerpc/ieee1275/ofconsole.c: Move ...
16960 * term/ieee1275/ofconsole.c: ... to here. All users updated.
16961 * disk/powerpc/ieee1275/ofdisk.c: Move ...
16962 * disk/ieee1275/ofdisk.c: ... to here. All users updated.
16963 * boot/powerpc/ieee1275/cmain.c: Change `grub_ieee1275_entry_fn' type
16965 * include/grub/i386/pc/console.h: Move to include/grub/console.h.
16966 Remove unused prototypes. All users updated.
16967 * include/grub/powerpc/ieee1275/console.h: Removed.
16968 * include/grub/powerpc/ieee1275/ieee1275.h: Define
16969 `grub_ieee1275_cell_t'.
16970 * kern/powerpc/ieee1275/openfw.c: Include <grub/machine/kernel.h>.
16971 Cast comparisons with -1 to the correct type.
16972 * loader/powerpc/ieee1275/linux.c (kernel_entry_t): Change parameter
16973 type to match `grub_ieee1275_entry_fn'.
16975 2005-08-01 Yoshinori K. Okuji <okuji@enbug.org>
16977 * DISTLIST: Added util/i386/pc/grub-probefs.c.
16979 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-probefs.
16980 (grub_setup_SOURCES): Removed partmap/amiga.c, partmap/apple.c and
16982 (grub_probefs_SOURCES): New variable.
16984 * util/i386/pc/grub-probefs.c: New file.
16986 * util/i386/pc/grub-setup.c (main): Call
16987 grub_pc_partition_map_init, grub_ufs_init, grub_minix_init,
16988 grub_hfs_init and grub_jfs_init to initialize the system. Call
16989 grub_ufs_fini, grub_minix_fini, grub_hfs_fini, grub_jfs_init and
16990 grub_pc_partition_map_fini to finish the system.
16992 2005-07-31 Yoshinori K. Okuji <okuji@enbug.org>
16994 * loader/i386/pc/multiboot.c (grub_multiboot_is_elf32): New
16996 (grub_multiboot_load_elf32): Likewise.
16997 (grub_multiboot_is_elf64): Likewise.
16998 (grub_multiboot_load_elf64): Likewise.
16999 (grub_multiboot_load_elf): Likewise.
17000 (grub_rescue_cmd_multiboot): Call grub_multiboot_load_elf to load
17001 an ELF32 or ELF64 file.
17002 This is based on a patch from Ruslan Nikolaev <nruslan@mail.com>.
17004 From Serbinenko Vladimir <serbinenko.vova@list.ru>:
17005 * kern/disk.c (grub_print_partinfo): Check if FS->LABEL is not
17006 NULL before calling FS->LABEL.
17007 * fs/fat.c (grub_fat_dir): Initialize DIRNAME to NULL.
17008 * commands/ls.c (grub_ls_list_files): Show labels, if possible.
17009 (grub_ls_list_disks): Check if FS and FS->LABEL are not NULL
17010 before calling FS->LABEL.
17012 2005-07-26 Yoshinori K. Okuji <okuji@enbug.org>
17014 * util/i386/pc/grub-install.in (datadir): New variable.
17016 (pkgdatadir): New variable.
17017 (pkglibdir): Removed.
17019 2005-07-24 Yoshinori K. Okuji <okuji@enbug.org>
17021 * DISTLIST: Added util/i386/pc/grub-install.in.
17023 * util/i386/pc/grub-install.in: New file.
17025 * conf/i386-pc.rmk (sbin_SCRIPTS): New variable.
17026 (grub_install_SOURCES): Likewise.
17028 * genmk.rb: Added support for scripts.
17029 (Script): New class.
17030 (scripts): New variable.
17032 * Makefile.in (install-local): Install sbin_SCRIPTS by
17034 (uninstall): Remove sbin_SCRIPTS.
17036 * util/i386/pc/grub-setup.c (main): If the argument is not a GRUB
17037 device, try to get a GRUB device by
17038 grub_util_biosdisk_get_grub_dev.
17041 * util/i386/pc/grub-mkdevicemap.c (usage): Remove a duplicated
17042 description for --device-map.
17044 2005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
17046 Change the semantics of variable hooks. They now return strings
17047 instead of error values.
17049 * util/i386/pc/grub-setup.c: Include grub/env.h.
17050 (setup): Use grub_device_set_root instead of grub_env_set.
17052 * kern/rescue.c (grub_rescue_cmd_root): Use grub_env_set and
17053 grub_env_get instead of grub_device_set_root and
17054 grub_device_get_root, respectively.
17056 * kern/main.c (grub_env_write_root): New function.
17057 (grub_set_root_dev): Register grub_env_write_hook for "root". Use
17058 grub_env_set instead of grub_device_set_root.
17060 * kern/env.c (HASHSZ): Reduced to 13, because GRUB does not need
17062 (grub_env_set): Set ENV->VALUE to the result of ENV->WRITE_HOOK
17063 rather than calling ENV->WRITE_HOOK afterwards.
17064 (grub_env_get): Return the result of ENV->READ_HOOK rather than
17065 passing a pointer of a pointer.
17066 (grub_register_variable_hook): Change the types of "read_hook" and
17067 "write_hook" to grub_env_read_hook_t and grub_env_write_hook_t,
17069 Allocate the default empty string on the heap, because this string
17070 may be freed later.
17072 * kern/device.c: Include grub/env.h.
17073 (grub_device_set_root): Removed.
17074 (grub_device_get_root): Likewise.
17075 (grub_device_open): Use grub_env_get instead of
17076 grub_device_get_root.
17078 * include/grub/env.h (grub_env_read_hook_t): New type.
17079 (grub_env_write_hook_t): Likewise.
17080 (grub_env_var): Change the types of "read_hook" and "write_hook"
17081 to grub_env_read_hook_t and grub_env_write_hook_t, respectively.
17082 (grub_register_variable_hook): Likewise.
17084 * include/grub/device.h (grub_device_set_root): Removed.
17085 (grub_device_set_root): Likewise.
17087 * fs/fat.c (grub_fat_dir): Make a copy of PATH in DIRNAME, and
17088 make sure that DIRNAME terminates with '/', so that
17089 grub_fat_find_dir will fail if PATH is not a directory.
17091 * commands/ls.c (grub_ls_list_files): Remove the qualifier const
17093 Use the qualifier auto for print_files and print_files_long.
17094 If FS->DIR sets GRUB_ERRNO to GRUB_ERR_BAD_FILE_TYPE, try DIRNAME
17096 Put a newline only if there is no error.
17097 (grub_cmd_ls): Remove grub_ls_print_files, because this is not
17100 2005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
17102 * kern/partition.c (grub_partition_probe): Initialize PART to
17103 NULL. Otherwise, when no partition map is registered, this returns
17106 2005-07-19 Yoshinori K. Okuji <okuji@enbug.org>
17108 * partmap/apple.c (apple_partition_map_iterate): Check if POS
17109 equals GRUB_DISK_SECTOR_SIZE to see if the partition table is
17112 2005-07-18 Yoshinori K. Okuji <okuji@enbug.org>
17114 * commands/ls.c (grub_ls_list_disks): Print the filesystem
17115 information on each device, if it does not have partitions. Print
17116 "Device" instead of "Disk", because this function is not specific
17119 * normal/main.c (grub_rescue_cmd_normal): Make the variable CONFIG
17120 static to ensure that it is put on the memory rather than a
17123 2005-07-17 Yoshinori Okuji <okuji@enbug.org>
17125 * commands/cat.c (GRUB_MOD_INIT): Use better documentation.
17126 (grub_cat_init): Likewise.
17127 * loader/i386/pc/chainloader_normal.c (GRUB_MOD_INIT): Likewise.
17128 (options): Likewise.
17129 * commands/configfile.c (GRUB_MOD_INIT): Likewise.
17130 (grub_configfile_init): Likewise.
17131 * font/manager.c (GRUB_MOD_INIT): Likewise.
17132 * commands/help.c (GRUB_MOD_INIT): Likewise.
17133 (grub_help_init): Likewise.
17134 * normal/command.c (grub_command_init): Likewise.
17135 * loader/i386/pc/linux_normal.c (GRUB_MOD_INIT): Likewise.
17136 * disk/loopback.c (grub_loop_init): Likewise.
17137 (GRUB_MOD_INIT): Likewise.
17138 * commands/ls.c (grub_ls_init): Likewise.
17139 (GRUB_MOD_INIT): Likewise.
17140 (options): Likewise.
17141 * commands/boot.c (grub_boot_init): Likewise.
17142 (GRUB_MOD_INIT): Likewise.
17143 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Likewise.
17144 * commands/i386/pc/reboot.c (grub_reboot_init): Likewise.
17145 (GRUB_MOD_INIT): Likewise.
17146 * commands/cmp.c (grub_cmp_init): Likewise.
17147 (GRUB_MOD_INIT): Likewise.
17149 * normal/arg.c: Use <> instead of "" to include header files.
17150 (SHORT_ARG_HELP): New macro.
17151 (SHORT_ARG_USAGE): Likewise.
17152 (help_options): Specify SHORT_ARG_HELP and SHORT_ARG_USAGE instead
17153 of 'h' and 'u' for help and usage, respectively. Use more GNU-like
17155 (find_short): Check if C is 'h' or 'u' explicitly.
17156 (grub_arg_show_help): Use space characters instead of tabs. Treat
17157 SHORT_ARG_HELP and SHORT_ARG_USAGE exceptionally so that -h and -u
17158 are shown with --help and --usage only if they are not used for
17159 the command itself.
17160 (parse_option): Use SHORT_ARG_HELP and SHORT_ARG_USAGE instead of
17163 * include/grub/arg.h (struct grub_arg_option): Add the qualifier
17164 const into "longarg". Change the type of "shortarg" to int.
17166 2005-07-17 Yoshinori Okuji <okuji@enbug.org>
17168 * boot/i386/pc/boot.S (boot_drive_check): New label.
17170 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRIVE_CHECK): New
17173 * util/i386/pc/grub-setup.c (setup): Added a workaround for BIOSes
17174 which do not pass a boot drive correctly. Copied from GRUB Legacy.
17176 2005-07-17 Yoshinori Okuji <okuji@enbug.org>
17178 * kern/i386/pc/startup.S (gate_a20_try_system_control_port_a):
17179 When turning off Gate A20, skip the check and return immediately,
17180 because this is not fatal usually.
17182 2005-07-17 Yoshinori Okuji <okuji@enbug.org>
17184 * conf/i386-pc.rmk (pxeboot_img_LDFLAGS): The text address should
17185 be 0x7C00 instead of 0x8000.
17187 * boot/i386/pc/pxeboot.S: Rewritten.
17189 * kern/i386/pc/startup.S (gate_a20_try_bios): No need to specify
17191 (gate_a20_check_state): Read a byte from 0x108000. Invert the
17194 2005-07-16 Yoshinori K. Okuji <okuji@enbug.org>
17196 * kern/i386/pc/startup.S (grub_gate_a20): Rewritten for
17197 robustness. This routine now supports a BIOS call and System
17198 Control Port A to modify the gate A20.
17200 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
17201 Increased to 0x440.
17203 2005-07-12 Hollis Blanchard <hollis@penguinppc.org>
17205 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): dprintf the
17206 device path and resulting ihandle.
17207 (grub_ofdisk_close): dprintf the ihandle being closed.
17208 (grub_ofdisk_read): dprintf function parameters.
17209 * kern/mm.c (grub_mm_init_region): Likewise.
17210 * loader/powerpc/ieee1275/linux.c: Remove extra whitespace.
17211 (grub_linux_boot): dprintf the Linux entry point, initrd address and
17212 size, and boot arguments.
17213 (grub_rescue_cmd_linux): dprintf each ELF segment's address and size
17214 before loading into memory.
17215 (grub_rescue_cmd_initrd): dprintf the initrd's address and size
17216 before loading into memory.
17218 2005-07-12 Yoshinori K. Okuji <okuji@enbug.org>
17220 * kern/mm.c: Added much documentation.
17221 (GRUB_MM_ALIGN_LOG2): When GRUB_CPU_SIZEOF_VOID_P is
17222 8, set to 5 instead of 8.
17224 2005-07-10 Yoshinori Okuji <okuji@enbug.org>
17226 * DISTLIST: Added util/i386/pc/grub-mkimage.c.
17228 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-mkdevicemap.
17229 (grub_mkdevicemap_SOURCES): New variable.
17231 * util/i386/pc/grub-mkdevicemap.c: New file. Mostly copied from
17232 lib/device.c of GRUB Legacy.
17234 2005-07-10 Yoshinori Okuji <okuji@enbug.org>
17236 * commands/ls.c (grub_ls_list_files): Check if *PATH is NUL
17237 instead of PATH is NULL.
17239 2005-07-09 Vincent Pelletier <subdino2004@yahoo.fr>
17241 * commands/cmp.c (BUFFER_SIZE): New macro.
17242 (grub_cmd_cmp): Close the right file at the right time. Compare
17243 only data just read. Don't report files of different size as
17244 identical. Dynamically allocate buffers. Move variable
17245 declarations at the beginning of function.
17247 2005-07-09 Yoshinori Okuji <okuji@enbug.org>
17249 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): The return value was
17252 2004-07-04 Vincent Pelletier <subdino2004@yahoo.fr>
17254 * normal/cmdline.c (grub_cmdline_get): Don't fallback on ctrl-d
17255 when backspace is pressed at beginning of line.
17257 2005-07-03 Yoshinori Okuji <okuji@enbug.org>
17259 * DISTLIST: Added genfslist.sh.
17261 * normal/main.c (fs_module_list): New variable.
17262 (autoload_fs_module): New function.
17263 (read_fs_list): Likewise.
17264 (grub_normal_execute): Call read_fs_list.
17266 * kern/fs.c (grub_fs_autoload_hook): New variable.
17267 (grub_fs_probe): Added support for auto-loading.
17269 * include/grub/normal.h (struct grub_fs_module_list): New struct.
17270 (grub_fs_module_list_t): New type.
17272 * include/grub/fs.h (grub_fs_autoload_hook_t): New type.
17273 (grub_fs_autoload_hook): New prototype.
17275 * genfslist.sh: New file.
17277 * genmk.rb: Added a rule to generate a filesystem list.
17279 2005-06-30 Marco Gerards <metgerards@student.han.nl>
17281 * configure.ac: Fix the test for cross-compiling.
17283 * genmk.rb (Program): Use `$(CC)' instead of `$(BUILD_CC)'. Don't
17284 define GRUB_UTIL anymore.
17286 * util/powerpc/ieee1275/grub-mkimage.c (load_note): Endian fixes
17287 so this function works on other systems than just big endian.
17288 (load_modules): Likewise.
17289 (add_segments): Likewise.
17291 2005-06-23 Hollis Blanchard <hollis@penguinppc.org>
17293 * kern/misc.c (grub_vsprintf): Add `longfmt'. If format string
17294 contains `l' modifier, get a long from va_arg().
17296 2005-06-23 Yoshinori K. Okuji <okuji@enbug.org>
17298 * kern/mm.c (grub_free): If the next free block which is being
17299 merged is the first free block, set the first block to the block
17301 Reported by Vincent Guffens <guffens@inma.ucl.ac.be>.
17303 2005-05-08 Hollis Blanchard <hollis@penguinppc.org>
17305 * boot/powerpc/ieee1275/cmain.c (cmain): Initialize
17306 `grub_ieee1275_chosen'.
17308 2005-05-08 Hollis Blanchard <hollis@penguinppc.org>
17310 * boot/powerpc/ieee1275/cmain.c (module_info): Remove definition.
17311 (grub_ieee1275_chosen): New variable.
17312 (cmain): Initialize and use `grub_ieee1275_chosen' instead of
17314 * boot/powerpc/ieee1275/crt0.S (init_stack): Remove stack space.
17315 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
17316 Rename first argument to `phandle' for consistency.
17317 (grub_ieee1275_get_property_length): Likewise.
17318 (grub_ieee1275_next_property): Likewise. Change type of first argument
17319 to grub_ieee1275_phandle_t.
17320 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_entry_fn):
17321 Move export next to declaration.
17322 (grub_ieee1275_chosen): New variable.
17323 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MODULE_BASE):
17324 Correct cosmetic typo.
17325 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Use
17326 `grub_ieee1275_chosen'.
17327 * kern/powerpc/ieee1275/openfw.c (grub_map): Likewise.
17328 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Likewise.
17329 (grub_rescue_cmd_linux): Set `initrd_addr' to 0.
17330 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_refresh): Use
17331 `grub_ieee1275_chosen'.
17333 2005-05-10 Hollis Blanchard <hollis@penguinppc.org>
17335 * boot/powerpc/ieee1275/cmain.c (cmain): Remove code to parse
17337 * kern/powerpc/ieee1275/init.c (grub_machine_init): Parse
17338 /chosen/bootargs as "variable=value" pairs.
17340 2005-05-08 Vincent Pelletier <subdino2004@yahoo.fr>
17342 * include/grub/misc.h (grub_dprintf): New macro.
17343 (grub_real_dprintf): New prototype.
17344 (grub_strword): Likewise.
17345 (grub_iswordseparator): Likewise.
17346 * kern/misc.c (grub_real_dprintf): New function.
17347 (grub_strword): Likewise.
17348 (grub_iswordseparator): Likewise.
17350 2005-04-30 Hollis Blanchard <hollis@penguinppc.org>
17352 * boot/powerpc/ieee1275/cmain.c: Don't include grub/machine/init.h.
17353 (roundup): Remove macro.
17354 (grub_ieee1275_flags): Make static.
17355 (grub_ieee1275_realmode): Remove.
17356 (grub_ieee1275_test_flag): New function.
17357 (grub_ieee1275_set_flag): Likewise.
17358 (find_options): Rename to `grub_ieee1275_find_options'; update
17359 callers. Set GRUB_IEEE1275_FLAG_REAL_MODE and
17360 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS.
17361 (cmain): New prototype.
17362 (cmain): Use `grub_ieee1275_set_flag' instead of accessing
17363 `grub_ieee1275_flags' directly.
17364 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Remove
17365 machine/biosdisk.h.
17366 * disk/powerpc/ieee1275/ofdisk.c: Include grub/machine/ofdisk.h.
17367 Don't include grub/machine/init.h.
17368 (grub_ofdisk_open): Call `grub_ieee1275_test_flag'.
17369 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
17371 (grub_ieee1275_realmode): Likewise.
17372 (grub_ieee1275_flag): New enum.
17373 (grub_ieee1275_test_flag): New prototype.
17374 (grub_ieee1275_set_flag): New prototype.
17375 * include/grub/powerpc/ieee1275/init.h: Remove file.
17376 * include/grub/powerpc/ieee1275/ofdisk.h: New file.
17377 * kern/powerpc/ieee1275/init.c: Don't include grub/machine/init.h.
17378 Include grub/machine/console.h. Include grub/machine/ofdisk.h.
17379 (grub_machine_fini): Don't call `grub_ieee1275_release'. Remove
17381 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Call
17382 `grub_ieee1275_test_flag'.
17383 (grub_ieee1275_encode_devname): Likewise.
17385 2005-04-21 Hollis Blanchard <hollis@penguinppc.org>
17387 * include/grub/powerpc/ieee1275/ieee1275.h
17388 (grub_ieee1275_encode_devname): New prototype.
17389 (grub_ieee1275_get_filename): Likewise.
17390 * kern/powerpc/ieee1275/init.c (grub_translate_ieee175_path): New
17392 (grub_set_prefix): Likewise.
17393 (grub_machine_init): Call grub_set_prefix.
17394 * kern/powerpc/ieee1275/openfw.c: Fix typos.
17395 (grub_parse_type): New enum.
17396 (grub_ieee1275_get_devargs): New function.
17397 (grub_ieee1275_get_devname): Likewise.
17398 (grub_ieee1275_parse_args): Likewise.
17399 (grub_ieee1275_get_filename): Likewise.
17400 (grub_ieee1275_encode_devname): Likewise.
17402 2005-03-30 Marco Gerards <metgerards@student.han.nl>
17404 * kern/powerpc/ieee1275/init.c (grub_machine_fini): Don't call
17405 `grub_loader_unset'.
17407 2005-03-26 Hollis Blanchard <hollis@penguinppc.org>
17409 * commands/ieee1275/halt.c (grub_cmd_halt): Call grub_halt
17410 instead of grub_ieee1275_interpret.
17411 (grub_halt_init): New function.
17412 (grub_halt_fini): Likewise.
17413 (GRUB_MOD_INIT): Correct message grammar.
17414 * commands/ieee1275/reboot.c (grub_cmd_reboot): Call grub_reboot
17415 instead of grub_ieee1275_interpret.
17416 (grub_reboot_init): New function.
17417 (grub_reboot_fini): Likewise.
17418 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace
17419 commands/i386/pc/halt.c, commands/i386/pc/reboot.c, and
17420 util/i386/pc/misc.c with commands/ieee1275/halt.c,
17421 commands/ieee1275/reboot.c, and util/powerpc/ieee1275/misc.c.
17422 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_fini): New
17424 * include/grub/powerpc/ieee1275/console.h (grub_console_fini):
17426 * include/grub/powerpc/ieee1275/ieee1275.h (grub_reboot): Add
17428 (grub_halt): Likewise.
17429 * include/grub/powerpc/ieee1275/init.h: Remove inaccurate comment.
17430 (cmain): Remove __attribute__((unused)).
17431 * kern/powerpc/ieee1275/init.c (grub_heap_start): New variable.
17432 (grub_heap_len): Likewise.
17433 (grub_machine_fini): New function.
17434 * kern/powerpc/ieee1275/openfw.c (grub_reboot): New function.
17435 (grub_halt): Likewise.
17436 * term/powerpc/ieee1275/ofconsole.c (grub_console_fini): New
17438 * util/powerpc/ieee1275/misc.c: New file.
17440 2005-03-19 Yoshinori K. Okuji <okuji@enbug.org>
17442 * DISTLIST: New file.
17443 * gendistlist.sh: Likewise.
17445 * Makefile.in (COMMON_DISTFILES): Removed.
17446 (BOOT_DISTFILES): Likewise.
17447 (CONF_DISTFILES): Likewise.
17448 (DISK_DISTFILES): Likewise.
17449 (FS_DISTFILES): Likewise.
17450 (INCLUDE_DISTFILES): Likewise.
17451 (KERN_DISTFILES): Likewise.
17452 (LOADER_DISTFILES): Likewise.
17453 (TERM_DISTFILES): Likewise.
17454 (UTIL_DISTFILES): Likewise.
17455 (DISTFILES): Likewise.
17456 (uninstall): Uninstall files in $(pkgdata_DATA).
17457 (DISTLIST): New target.
17458 (distdir): Use the contents of the file DISTLIST to get a list of
17461 2005-03-18 Yoshinori K. Okuji <okuji@enbug.org>
17463 * fs/fat.c (grub_fat_mount): Ignore the 3rd bit of a media
17464 descriptor. This is ported from GRUB Legacy.
17466 * gencmdlist.sh: Added an extra semicolon to make it work with
17467 old sed versions. Reported by Robert Bihlmeyer
17468 <robbe@orcus.priv.at>.
17470 2005-03-08 Yoshinori Okuji <okuji@enbug.org>
17472 Automatic loading of commands is supported.
17474 * normal/main.c (read_command_list): New function.
17475 (grub_normal_execute): Call read_command_list.
17477 * normal/command.c (grub_register_command): Return zero or CMD.
17478 Allocate CMD->NAME from the heap.
17479 Initialize CMD->MODULE_NAME to zero.
17480 Find the same name as well. If the same command is found and it is
17481 a dummy command, overwrite members. If it is not a dummy command,
17483 (grub_unregister_command): Free Q->NAME and Q->MODULE_NAME.
17484 (grub_command_find): If a dummy command is found, load a module
17485 and retry to find a command only once.
17487 * normal/cmdline.c (grub_tab_complete): Call grub_command_find to
17488 make sure that each command is loaded.
17490 * include/grub/normal.h (GRUB_COMMAND_FLAG_NOT_LOADED): New
17492 (struct grub_command): Remove const from the member `name'.
17493 Add a new member `module_name'.
17494 (grub_register_command): Return grub_command_t.
17496 * commands/help.c (grub_cmd_help): Call grub_command_find to make
17497 sure that each command is loaded.
17499 * genmk.rb (PModule::rule): Specify a module name without the
17500 suffix ".mod" to gencmdlist.sh.
17502 2005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
17504 * gencmdlist.sh: New file.
17506 * genmk.rb (PModule::rule): Generate a rule for a command list.
17508 Generate command.lst from $(COMMANDFILES).
17510 * Makefile.in (COMMON_DISTFILES): Added gencmdlist.sh.
17511 (DATA): Added $(pkgdata_DATA).
17512 (install-local): Install files in $(pkgdata_DATA).
17514 2005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
17516 * term/i386/pc/vga.c (debug_command): Removed.
17517 (GRUB_MOD_INIT): Do not register the command "debug".
17519 From Hollis Blanchard:
17520 * commands/configfile.c: New file.
17521 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
17522 commands/configfile.c.
17523 (pkgdata_MODULES): Added configfile.mod.
17524 (configfile_mod_SOURCES): New variable.
17525 (configfile_mod_CFLAGS): Likewise.
17526 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
17527 commands/configfile.c.
17528 (pkgdata_MODULES): Added configfile.mod.
17529 (configfile_mod_SOURCES): New variable.
17530 (configfile_mod_CFLAGS): Likewise.
17531 * util/grub-emu.c (main): Call grub_configfile_init and
17532 grub_configfile_fini.
17533 * include/grub/normal.h [GRUB_UTIL] (grub_configfile_init): New
17535 [GRUB_UTIL] (grub_configfile_fini): Likewise.
17537 2005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
17539 * normal/arg.c (grub_arg_show_help): Do not show the bug report
17542 * commands/help.c (grub_cmd_help): Do not print newlines after
17543 the last command in print_command_help.
17545 2005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
17547 * commands/default.h: New file.
17548 * commands/timeout.h: Likewise.
17549 * normal/context.c: Likewise.
17551 * util/misc.c: Do not include sys/times.h.
17552 Include sys/time.h and grub/machine/time.h.
17553 (grub_get_rtc): Rewritten with gettimeofday.
17555 * util/grub-emu.c (main): Call grub_default_init and
17556 grub_timeout_init before grub_normal_init, and call
17557 grub_timeout_fini and grub_default_fini after grub_main.
17559 * util/console.c (grub_ncurses_checkkey): Return the read
17562 * normal/menu.c (run_menu): Set MENU->TIMEOUT to -1 once it
17565 * normal/main.c (read_config_file): Push MENU. If this fails,
17566 print an error and wait for a user input.
17567 Print an error only if GRUB_ERRNO is not GRUB_ERR_NONE.
17568 If a menu is empty or an error occurs, pop MENU.
17569 (grub_normal_execute): Pop and free MENU after grub_menu_run
17572 * kern/loader.c (grub_loader_boot): Call grub_machine_fini.
17574 * include/grub/powerpc/ieee1275/time.h [GRUB_UTIL]: Do not
17576 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
17578 * include/grub/i386/pc/time.h [GRUB_UTIL]: Do not include
17580 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
17583 * include/grub/normal.h (struct grub_menu_list): New struct.
17584 (grub_menu_list_t): New type.
17585 (struct grub_context): New struct.
17586 (grub_context_t): New type.
17587 (grub_register_command): Got rid of EXPORT_FUNC.
17588 (grub_unregister_command): Likewise.
17589 (grub_context_get): New prototype.
17590 (grub_context_get_current_menu): Likewise.
17591 (grub_context_push_menu): Likewise.
17592 (grub_context_pop_menu): Likewise.
17593 [GRUB_UTIL] (grub_default_init): Likewise.
17594 [GRUB_UTIL] (grub_default_fini): Likewise.
17595 [GRUB_UTIL] (grub_timeout_init): Likewise.
17596 [GRUB_UTIL] (grub_timeout_fini): Likewise.
17598 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/default.c,
17599 commands/timeout.c and normal/context.c.
17600 (pkgdata_MODULES): Added default.mod and timeout.mod.
17601 (normal_mod_SOURCES): Added normal/context.c.
17602 (default_mod_SOURCES): New variable.
17603 (default_mod_CFLAGS): Likewise.
17604 (timeout_mod_SOURCES): Likewise.
17605 (timeout_mod_CFLAGS): Likewise.
17606 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Copied from
17608 (pkgdata_MODULES): Added default.mod and timeout.mod.
17609 (normal_mod_SOURCES): Added normal/context.c.
17610 (default_mod_SOURCES): New variable.
17611 (default_mod_CFLAGS): Likewise.
17612 (timeout_mod_SOURCES): Likewise.
17613 (timeout_mod_CFLAGS): Likewise.
17615 * Makefile.in (all-local): Added $(MKFILES).
17617 2005-02-21 Vincent Pelletier <subdino2004@yahoo.fr>
17619 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `partmap/sun.c'.
17620 (grub_emu_SOURCES): Likewise.
17621 (pkgdata_MODULES): Add `sun.mod'.
17622 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
17623 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
17625 (pkgdata_MODULES): Add `sun.mod'.
17626 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
17627 * include/grub/partition.h (grub_sun_partition_map_init): New
17629 (grub_sun_partition_map_fini): Likewise.
17630 * partmap/sun.c: New file.
17631 * util/grub-emu.c (main): Initialize and de-initialize the sun
17632 partitionmap support.
17634 2005-02-19 Yoshinori K. Okuji <okuji@enbug.org>
17636 This implements an Emacs-like menu entry editor.
17638 * normal/menu_entry.c: New file.
17640 * util/console.c (grub_ncurses_putchar): Translate some Unicode
17641 characters to ASCII.
17642 (saved_char): New variable.
17643 (grub_ncurses_checkkey): Rewritten completely.
17644 (grub_ncurses_getkey): Likewise.
17645 (grub_ncurses_init): Call raw instead of cbreak.
17647 * normal/menu.c (print_entry): Do not put a space.
17648 (init_page): Renamed to ...
17649 (grub_menu_init_page): ... this. All callers changed.
17650 (edit_menu_entry): Removed.
17651 (run_menu): Call grub_menu_entry_run instead of edit_menu_entry.
17653 * normal/cmdline.c (grub_cmdline_run): Call grub_setcursor.
17655 * kern/misc.c (grub_vprintf): Call grub_refresh.
17657 * normal/menu.c (DISP_LEFT): Renamed to ...
17658 * include/grub/term.h (GRUB_TERM_DISP_LEFT): ... this.
17659 * normal/menu.c (DISP_UP): Renamed to ...
17660 * include/grub/term.h (GRUB_TERM_DISP_UP): ... this.
17661 * normal/menu.c (DISP_RIGHT): Renamed to ...
17662 * include/grub/term.h (GRUB_TERM_DISP_RIGHT): ... this.
17663 * normal/menu.c (DISP_DOWN): Renamed to ...
17664 * include/grub/term.h (GRUB_TERM_DISP_DOWN): ... this.
17665 * normal/menu.c (DISP_HLINE): Renamed to ...
17666 * include/grub/term.h (GRUB_TERM_DISP_HLINE): ... this.
17667 * normal/menu.c (DISP_VLINE): Renamed to ...
17668 * include/grub/term.h (GRUB_TERM_DISP_VLINE): ... this.
17669 * normal/menu.c (DISP_UL): Renamed to ...
17670 * include/grub/term.h (GRUB_TERM_DISP_UL): ... this.
17671 * normal/menu.c (DISP_UR): Renamed to ...
17672 * include/grub/term.h (GRUB_TERM_DISP_UR): ... this.
17673 * normal/menu.c (DISP_LL): Renamed to ...
17674 * include/grub/term.h (GRUB_TERM_DISP_LL): ... this.
17675 * normal/menu.c (DISP_LR): Renamed to ...
17676 * include/grub/term.h (GRUB_TERM_DISP_LR): ... this.
17677 * normal/menu.c (TERM_WIDTH): Renamed to ...
17678 * include/grub/term.h (GRUB_TERM_WIDTH): ... this.
17679 * normal/menu.c (TERM_HEIGHT): Renamed to ...
17680 * include/grub/term.h (GRUB_TERM_HEIGHT): ... this.
17681 * normal/menu.c (TERM_INFO_HEIGHT): Renamed to ...
17682 * include/grub/term.h (GRUB_TERM_INFO_HEIGHT): ... this.
17683 * normal/menu.c (TERM_MARGIN): Renamed to ...
17684 * include/grub/term.h (GRUB_TERM_MARGIN): ... this.
17685 * normal/menu.c (TERM_SCROLL_WIDTH): Renamed to ...
17686 * include/grub/term.h (GRUB_TERM_SCROLL_WIDTH): ... this.
17687 * normal/menu.c (TERM_TOP_BORDER_Y): Renamed to ...
17688 * include/grub/term.h (GRUB_TERM_TOP_BORDER_Y): ... this.
17689 * normal/menu.c (TERM_LEFT_BORDER_X): Renamed to ...
17690 * include/grub/term.h (GRUB_TERM_LEFT_BORDER_X): ... this.
17691 * normal/menu.c (TERM_BORDER_WIDTH): Renamed to ...
17692 * include/grub/term.h (GRUB_TERM_BORDER_WIDTH): ... this.
17693 * normal/menu.c (TERM_MESSAGE_HEIGHT): Renamed to ...
17694 * include/grub/term.h (GRUB_TERM_MESSAGE_HEIGHT): ... this.
17695 * normal/menu.c (TERM_BORDER_HEIGHT): Renamed to ...
17696 * include/grub/term.h (GRUB_TERM_BORDER_HEIGHT): ... this.
17697 * normal/menu.c (TERM_NUM_ENTRIES): Renamed to ...
17698 * include/grub/term.h (GRUB_TERM_NUM_ENTRIES): ... this.
17699 * normal/menu.c (TERM_FIRST_ENTRY_Y): Renamed to ...
17700 * include/grub/term.h (GRUB_TERM_FIRST_ENTRY_Y): ... this.
17701 * normal/menu.c (TERM_ENTRY_WIDTH): Renamed to ...
17702 * include/grub/term.h (GRUB_TERM_ENTRY_WIDTH): ... this.
17703 * normal/menu.c (TERM_CURSOR_X): Renamed to ...
17704 * include/grub/term.h (GRUB_TERM_CURSOR_X): ... this.
17705 All callers changed.
17707 * include/grub/normal.h: New prototype.
17709 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
17710 normal/menu_entry.c.
17711 (normal_mod_SOURCES): Likewise.
17712 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
17713 (normal_mod_SOURCES): Likewise.
17715 2005-02-15 Yoshinori K. Okuji <okuji@enbug.org>
17717 * include/grub/normal.h (grub_halt_init): New prototype.
17718 (grub_halt_fini): Likewise.
17719 (grub_reboot_init): Likewise.
17720 (grub_reboot_fini): Likewise.
17722 * util/grub-emu.c: Include signal.h.
17723 (main_env): New global variable.
17724 (grub_machine_init): Ignore SIGINT. Otherwise grub-emu cannot
17726 (grub_machine_fini): New function.
17727 (main): Call grub_halt_init and grub_reboot_init before
17728 grub_main, and grub_reboot_fini and grub_halt_fini after it.
17729 Call setjmp with MAIN_ENV to go back afterwards.
17730 Call grub_machine_fini right before return.
17732 * include/grub/util/misc.h: Include setjmp.h.
17733 (main_env): New prototype.
17735 * include/grub/kernel.h (grub_machine_fini): New prototype.
17736 * include/grub/i386/pc/biosdisk.h (grub_biosdisk_fini): Likewise.
17737 * include/grub/i386/pc/console.h (grub_console_fini): Likewise.
17739 * disk/i386/pc/biosdisk.c (grub_biosdisk_fini): New function.
17740 * kern/i386/pc/init.c (grub_machine_fini): Likewise.
17741 * term/i386/pc/console.c (grub_console_fini): Likewise.
17743 * util/i386/pc/misc.c: New file.
17745 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
17746 util/i386/pc/misc.c, commands/i386/pc/halt.c and
17747 commands/i386/pc/reboot.c.
17749 2005-02-14 Guillem Jover <guillem@hadrons.org>
17751 * include/grub/dl.h (grub_dl_check_header): New prototype.
17752 (grub_arch_dl_check_header): Change return type to grub_err_t,
17753 remove size parameter and export function. Update all callers.
17754 * kern/dl.c (grub_dl_check_header): New function.
17755 (grub_dl_load_core): Use `grub_dl_check_header' instead of
17756 `grub_arch_dl_check_header'. Check ELF type. Check if sections
17757 are inside the core.
17758 * kern/i386/dl.c (grub_arch_dl_check_header): Remove arch
17759 independent ELF header checks.
17760 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
17761 * loader/i386/pc/multiboot.c (grub_rescue_cmd_multiboot): Use
17762 `grub_dl_check_header' instead of explicit checks. Check for the
17764 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Use
17765 `grub_dl_check_header' instead of explicit checks. Remove arch
17766 specific ELF header checks.
17768 * util/grub-emu.c (grub_arch_dl_check_header): Remove the
17771 2005-02-13 Hollis Blanchard <hollis@penguinppc.org>
17773 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add ls.mod.
17774 * include/grub/powerpc/libgcc.h (__mulsf3): New prototype.
17776 2005-02-12 Hollis Blanchard <hollis@penguinppc.org>
17778 * kern/partition.c (grub_partition_probe): Clear `grub_errno' and
17779 return 0 if `grub_errno' is GRUB_ERR_BAD_PART_TABLE.
17780 (part_map_iterate): Clear `grub_errno' and return 0 if
17781 `partmap->iterate' returns GRUB_ERR_BAD_PART_TABLE.
17782 * partmap/amiga.c (amiga_partition_map_iterate): Return
17783 GRUB_ERR_BAD_PART_TABLE if no partition map magic is found.
17784 * partmap/apple.c (apple_partition_map_iterate): Likewise.
17786 2005-02-01 Guillem Jover <guillem@hadrons.org>
17788 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Fix module
17791 2005-01-31 Marco Gerards <metgerards@student.han.nl>
17793 * include/grub/powerpc/ieee1275/loader.h (grub_load_linux):
17795 (grub_rescue_cmd_linux): New prototype.
17796 (grub_rescue_cmd_initrd): Likewise.
17797 * powerpc/ieee1275/linux.c (grub_linux_boot): Remove struct
17799 (grub_linux_release_mem): Release the memory for the initrd.
17800 (grub_load_linux): Renamed from this...
17801 (grub_rescue_cmd_linux): ...To this. Changed all callers.
17802 Changed `entry' not to be static. Loop over memory regions to
17803 find another one when the default fails.
17804 (grub_rescue_cmd_initrd): New function.
17805 (grub_linux_init): Remove function.
17806 (grub_linux_fini): Likewise.
17807 (GRUB_MOD_INIT): Register `initrd'.
17808 (GRUB_MOD_FINI): Unregister `initrd'.
17809 * powerpc/ieee1275/linux_normal.c (grub_linux_normal_init):
17811 (grub_linux_normal_fini): Likewise.
17812 (GRUB_MOD_INIT): Register `initrd'.
17813 (GRUB_MOD_FINI): Unregister `initrd'.
17815 2005-01-31 Marco Gerards <metgerards@student.han.nl>
17817 * commands/help.c: New file.
17818 * normal/arg.c (show_help): Renamed to...
17819 (grub_arg_show_help): ... this.
17820 * commands/i386/pc/halt.c: New file.
17821 * commands/i386/pc/reboot.c: Likewise.
17822 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/help.c'.
17823 (pkgdata_MODULES): Add `reboot.mod', `halt.mod' and `help.mod'.
17824 (help_mod_SOURCES, help_mod_CFLAGS, reboot_mod_SOURCES)
17825 (reboot_mod_CFLAGS, halt_mod_SOURCES, halt_mod_CFLAGS): New
17827 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
17829 (pkgdata_MODULES): Add `help.mod'.
17830 (help_mod_SOURCES, help_mod_CFLAGS): New variables.
17831 * grub/i386/pc/init.h (grub_reboot): New prototype.
17832 (grub_halt): Likewise.
17833 * include/grub/normal.h (grub_arg_show_help): New prototype.
17834 (grub_help_init): Likewise.
17835 (grub_help_fini): Likewise.
17836 * util/grub-emu.c (main): Initialize and deinitialize the help
17839 * normal/cmdline.c (grub_cmdline_get): Doc fix.
17841 * normal/command.c (grub_command_init): Fixed the description of
17842 the `set' and `unset' commands.
17844 2005-01-31 Marco Gerards <metgerards@student.han.nl>
17846 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_interpret): New
17848 * commands/ieee1275/halt.c: New file.
17849 * commands/ieee1275/reboot.c: Likewise.
17850 * commands/ieee1275/suspend.c (grub_cmd_suspend): Use
17851 `__attribute__ ((unused))'. Some GCS related fixed.
17852 (grub_suspend_init) [GRUB_UTIL]: Function removed.
17853 (grub_suspend_fini): Likewise.
17854 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add `reboot.mod'
17856 (reboot_mod_SOURCES, reboot_mod_CFLAGS, halt_mod_SOURCES)
17857 (halt_mod_CFLAGS): New variables.
17858 * include/grub/powerpc/ieee1275/ieee1275.h
17859 (grub_ieee1275_interpret): New prototype.
17861 2005-01-29 Yoshinori K. Okuji <okuji@enbug.org>
17863 * include/grub/misc.h (memmove): New prototype.
17864 (memcpy): Likewise.
17866 2005-01-22 Hollis Blanchard <hollis@penguinppc.org>
17868 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Don't initialize
17869 `devpath' to 0. Use `name' instead of `devpath' with `grub_strndup'.
17871 2005-01-22 Marco Gerards <metgerards@student.han.nl>
17873 * kern/misc.c (grub_strndup): Function rewritten.
17875 2005-01-22 Vincent Pelletier <subdino2004@yahoo.fr>
17877 * normal/menu.c (TERM_WIDTH): Macro redefined.
17878 (TERM_TOP_BORDER_Y): Likewise.
17879 (draw_border): Replaced while-loop by a for-loop. Make the number
17880 of lines consistent with the number of lines displayed in
17881 print_entries. Added a margin below the rectangle.
17882 (print_entry): Make the entry fit in the rectangle.
17883 (print_entries): Display the scroll arrows next to the right
17886 2005-01-21 Marco Gerards <metgerards@student.han.nl>
17888 * fs/minix.c (grub_minix_find_file): Reserve more space for
17889 `fpath' so the \0 can be stored. Use `grub_strcpy' instead of
17890 `grub_strncpy' to copy `path' into it.
17892 2005-01-21 Marco Gerards <metgerards@student.han.nl>
17894 Add the loopback device, a device via which files can be accessed
17897 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/loopback.c'.
17898 (pkgdata_MODULES): Add loopback.mod.
17899 (loopback_mod_SOURCES): New variable.
17900 (loopback_mod_CFLAGS): Likewise.
17901 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
17903 (pkgdata_MODULES): Add loopback.mod.
17904 (loopback_mod_SOURCES): New variable.
17905 (loopback_mod_CFLAGS): Likewise.
17906 * disk/loopback.c: new file.
17907 * include/grub/normal.h (grub_loop_init): New prototype.
17908 (grub_loop_fini): New prototype.
17909 * util/grub-emu.c (main): Initialize and de-initialize loopback
17911 * include/grub/disk.h (grub_disk_dev_id): Add
17912 `GRUB_DISK_DEVICE_LOOPBACK_ID'.
17914 2005-01-20 Hollis Blanchard <hollis@penguinppc.org>
17916 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_enter): New
17918 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add suspend.mod.
17919 (suspend_mod_SOURCES): New variable.
17920 (suspend_mod_CFLAGS): Likewise.
17921 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_enter):
17923 * commands/ieee1275/suspend.c: New file.
17925 2005-01-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17927 * include/grub/dl.h (GRUB_MOD_INIT): Changed `__attribute__
17928 ((unused))' to `__attribute__ ((used))'.
17929 (GRUB_MOD_FINI): Likewise.
17930 * kern/dl.c (grub_dl_load_file): Fix null pointer dereference.
17931 * genmk.rb (PModule): Assign space to common symbols when linking
17934 2005-01-20 Marco Gerards <metgerards@student.han.nl>
17936 * include/grub/mm.h (grub_mm_init_region): Change the type of the
17937 `unsigned' arguments to `grub_size_t'.
17938 (grub_malloc): Likewise.
17939 (grub_realloc): Likewise.
17940 (grub_memalign): Likewise.
17941 * kern/i386/dl.c (grub_arch_dl_check_header): Likewise.
17942 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
17943 * util/misc.c (grub_malloc): Likewise.
17944 (grub_realloc): Likewise.
17945 * kern/mm.c (get_header_from_pointer): Change the casts to
17946 `unsigned' into a cast to `grub_size_t'.
17948 * fs/fshelp.c (grub_fshelp_find_file): The `oldnode' should always
17949 point to `currnode' when `currnode' is changed.
17951 * util/grub-emu.c (main): Initialize `progname'. Reported by Nico
17952 Schottelius <nico-linux@schottelius.org>.
17954 2005-01-09 Hollis Blanchard <hollis@penguinppc.org>
17956 * util/powerpc/ieee1275/grub-mkimage.c: Include <string.h>.
17957 (note_path): Remove variable.
17958 (GRUB_IEEE1275_NOTE_NAME): New macro.
17959 (GRUB_IEEE1275_NOTE_TYPE): Likewise.
17960 (grub_ieee1275_note_hdr): New structure.
17961 (grub_ieee1275_note_desc): Likewise.
17962 (grub_ieee1275_note): Likewise.
17963 (load_note): Remove `dir' argument. All callers updated. Remove
17964 `note_img' and `path'. Do not load a file from `note_path'.
17965 Initialize a struct grub_ieee1275_note and write that to `out'.
17966 Use GRUB_IEEE1275_MODULE_BASE instead of MODULE_BASE.
17968 2005-01-05 Marco Gerards <metgerards@student.han.nl>
17970 * util/misc.c (grub_util_read_image): Revert last change. It
17971 called `grub_util_read_at', which seeks from the beginning of the
17974 2005-01-04 Hollis Blanchard <hollis@penguinppc.org>
17976 * TODO: Add note about endianness in grub-mkimage.
17977 * boot/powerpc/ieee1275/crt0.S (note): Remove unused .note
17979 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Add grub-mkimage.
17980 (grub_mkimage_SOURCES): New target.
17981 * include/grub/kernel.h (grub_start_addr): Remove variable.
17982 (grub_end_addr): Likewise.
17983 (grub_total_module_size): Likewise.
17984 (grub_kernel_image_size): Likewise.
17985 (GRUB_MODULE_MAGIC): New constant.
17986 (grub_module_info): New structure.
17987 (grub_arch_modules_addr): New prototype.
17988 (grub_get_end_addr): Remove prototype.
17989 * include/grub/i386/pc/kernel.h (grub_end_addr): New prototype.
17990 * include/grub/powerpc/ieee1275/kernel.h: New file.
17991 * include/grub/util/misc.h (grub_util_get_fp_size): New
17993 (grub_util_read_at): Likewise.
17994 (grub_util_write_image_at): Likewise.
17995 * kern/main.c (grub_get_end_addr): Remove function.
17996 (grub_load_modules): Call grub_arch_modules_addr instead of using
17997 grub_end_addr. Look for a grub_module_info struct in memory. Use
17998 the grub_module_info fields instead of calling grub_get_end_addr
17999 as loop conditions. Move grub_add_unused_region code here.
18000 (grub_add_unused_region): Remove function.
18001 * kern/i386/pc/init.c: Include grub/cache.h.
18002 (grub_machine_init): Remove call to grub_get_end_addr. Remove
18003 one call to add_mem_region.
18004 (grub_arch_modules_addr): New function.
18005 * kern/powerpc/ieee1275/init.c (grub_end_addr): Remove variable.
18006 (grub_total_module_size): Likewise.
18007 Include grub/machine/kernel.h.
18008 (grub_arch_modules_addr): New function.
18009 * util/grub-emu.c (grub_end_addr): Remove variable.
18010 (grub_total_module_size): Likewise.
18011 (grub_arch_modules_addr): New function.
18012 * util/misc.c: Include unistd.h.
18013 (grub_util_get_fp_size): New function.
18014 (grub_util_read_at): Likewise.
18015 (grub_util_write_image_at): Likewise.
18016 (grub_util_read_image): Call grub_util_read_at.
18017 (grub_util_write_image): Call grub_util_write_image_at.
18018 * util/i386/pc/grub-mkimage.c (generate_image): Allocate
18019 additional memory in kernel_img for a struct grub_module_info.
18020 Fill in that grub_module_info.
18021 * util/powerpc/ieee1275/grub-mkimage.c: New file.
18023 2005-01-03 Hollis Blanchard <hollis@penguinppc.org>
18025 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_milliseconds):
18027 * include/grub/powerpc/ieee1275/ieee1275.h
18028 (grub_ieee1275_milliseconds): New prototype.
18029 * include/grub/powerpc/ieee1275/time.h (GRUB_TICKS_PER_SECOND):
18031 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Call
18032 grub_ieee1275_milliseconds.
18034 2005-01-03 Hollis Blanchard <hollis@penguinppc.org>
18036 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_realmode): New
18038 (find_options): New function.
18039 (cmain): Call find_options.
18040 * include/grub/powerpc/ieee1275/ieee1275.h
18041 (grub_ieee1275_realmode): New extern variable.
18042 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Only call
18043 grub_map if grub_ieee1275_realmode is false.
18045 2004-12-29 Marco Gerards <metgerards@student.han.nl>
18047 * normal/cmdline.c (grub_cmdline_get): Redone logic so no empty
18048 lines are inserted and make it work like readline. Reported by
18049 Vincent Pelletier <subdino2004@yahoo.fr>.
18051 2004-12-28 Marco Gerards <metgerards@student.han.nl>
18053 * boot/powerpc/ieee1275/crt0.S (_start): Don't set up the stack.
18055 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCE): Remove
18056 `kern/powerpc/cache.S'.
18058 2004-12-27 Marco Gerards <metgerards@student.han.nl>
18060 * genmk.rb: Handle the `Program' class in the main loop. Written
18061 by Johan Rydberg <jrydberg@gnu.org>.
18062 (Program): New class.
18063 (programs): New variable.
18064 * boot/powerpc/ieee1275/cmain.c: Include <grub/machine/ieee1275.h>
18065 instead of "grub/machine/ieee1275.h". Include <grub/kernel.h>
18066 instead of "grub/kernel.h". Include <grub/machine/init.h>.
18067 (help_arch): Function removed.
18068 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add
18069 `powerpc/libgcc.h' and `loader.h'.
18070 (pkgdata_PROGRAMS): New variable.
18071 (sbin_UTILITIES): Variable removed.
18072 (grub_emu_SOURCES): Added kern/powerpc/cache.S.
18073 (grubof_SOURCES): Variable re-defined so it only includes the
18074 core functionality.
18075 (grubof_CFLAGS): Remove `-DGRUBOF'.
18076 (pkgdata_MODULES, fshelp_mod_SOURCES, fshelp_mod_CFLAGS,
18077 (fat_mod_SOURCES, fat_mod_CFLAGS, ext2_mod_SOURCES)
18078 (ext2_mod_CFLAGS, ufs_mod_SOURCES, ufs_mod_CFLAGS)
18079 (minix_mod_SOURCES, minix_mod_CFLAGS, hfs_mod_SOURCES)
18080 (hfs_mod_CFLAGS, jfs_mod_SOURCES, jfs_mod_CFLAGS)
18081 (iso9660_mod_SOURCES, iso9660_mod_CFLAGS, _linux_mod_SOURCES)
18082 (_linux_mod_CFLAGS, linux_mod_SOURCES, linux_mod_CFLAGS)
18083 (normal_mod_SOURCES, normal_mod_CFLAGS, normal_mod_ASFLAGS)
18084 (hello_mod_SOURCES, hello_mod_CFLAGS, boot_mod_SOURCES)
18085 (boot_mod_CFLAGS, terminal_mod_SOURCES, terminal_mod_CFLAGS)
18086 (ls_mod_SOURCES, ls_mod_CFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
18087 (cat_mod_SOURCES, cat_mod_CFLAGS, font_mod_SOURCES)
18088 (font_mod_CFLAGS, amiga_mod_SOURCES, amiga_mod_CFLAGS)
18089 (apple_mod_SOURCES, apple_mod_CFLAGS, pc_mod_SOURCES)
18090 (pc_mod_CFLAGS): New variables.
18091 * disk/powerpc/ieee1275/ofdisk.c: Include <grub/machine/init.h>.
18092 (grub_ofdisk_iterate): Add a prototype for `dev_iterate'.
18093 * include/grub/dl.h (grub_arch_dl_sync_caches): New prototype.
18094 * include/grub/loader.h (grub_os_area_addr, grub_os_area_size):
18096 * include/grub/i386/pc/init.h (grub_os_area_addr)
18097 (rub_os_area_size): ... to here.
18098 * include/grub/powerpc/ieee1275/ieee1275.h
18099 (grub_ieee1275_entry_fn): Export symbol.
18100 * include/grub/powerpc/ieee1275/init.h: New file.
18101 * include/grub/powerpc/libgcc.h: Likewise.
18102 * include/grub/cache.h: Likewise.
18103 * kern/powerpc/cache.S: Likewise. Written by Hollis Blanchard
18104 <hollis@penguinppc.org>.
18105 * kern/dl.c: Include <grub/cache.h>.
18106 (grub_dl_flush_cache): New function.
18107 (grub_dl_load_core): Call `grub_dl_flush_cache' to flush the cache
18109 * kern/powerpc/ieee1275/init.c (grub_ofdisk_init)
18110 (grub_console_init): Removed prototypes.
18111 (grub_machine_init): Don't initialize the modules anymore.
18112 * kern/powerpc/ieee1275/openfw.c (grub_map): Make the function
18114 * include/grub/powerpc/types.h (GRUB_HOST_WORDS_LITTLEENDIAN):
18115 Macro undef removed.
18116 (GRUB_HOST_WORDS_BIGENDIAN): New macro.
18117 * kern/powerpc/dl.c (grub_arch_dl_relocate_symbols): Add
18118 relocation `R_PPC_REL32'. Return an error when the relocation is
18120 * Makefile.in (DATA): Add `$(pkgdata_PROGRAMS)'.
18121 * kern/i386/pc/init.c (grub_arch_sync_caches): New function.
18122 * util/misc.c (grub_arch_sync_caches): Likewise.
18124 2004-12-19 Marco Gerards <metgerards@student.han.nl>
18126 * conf/powerpc-ieee1275.rmk (MOSTLYCLEANFILES): Remove
18127 `symlist.c', add `grubof_symlist.c'.
18128 (symlist.c): Variable removed.
18129 (grubof_HEADERS): Variable added.
18130 (grubof_symlist.c): New target.
18131 (kernel_syms.lst): Use `grubof_HEADERS' instead of
18132 `kernel_img_HEADERS'.
18133 (grubof_SOURCES): Add `kern/powerpc/dl.c' and `grubof_symlist.c'.
18134 * kern/powerpc/dl.c: New file.
18135 * kern/powerpc/ieee1275/init.c (grub_arch_dl_check_header):
18137 (grub_arch_dl_relocate_symbols): Likewise.
18138 (grub_register_exported_symbols): Likewise.
18140 2004-12-13 Marco Gerards <metgerards@student.han.nl>
18142 * fs/ext2.c (grub_ext2_open): Don't use data after freeing it.
18143 (grub_ext2_dir): Likewise. Don't return in case of an error, jump
18144 to fail instead. Reported by Vincent Pelletier
18145 <subdino2004@yahoo.fr>.
18147 * fs/fshelp.c (grub_fshelp_find_file): Don't free `oldnode' when
18148 it is not allocated. Reported by Vincent Pelletier
18149 <subdino2004@yahoo.fr>.
18151 * normal/cmdline.c (grub_tab_complete): Add a blank line to the
18152 output so the output looks better.
18154 2004-12-04 Marco Gerards <metgerards@student.han.nl>
18156 Modulize the partition map support and add support for the amiga
18159 * commands/ls.c: Include <grub/partition.h> instead of
18160 <grub/machine/partition.h>.
18161 * kern/disk.c: Likewise.
18162 * kern/rescue.c: Likewise.
18163 * loader/i386/pc/chainloader.c: Likewise.
18164 * normal/cmdline.c: Likewise.
18165 * kern/powerpc/ieee1275/init.c: Likewise.
18166 (grub_machine_init): Call `grub_pc_partition_map_init',
18167 `grub_amiga_partition_map_init' and
18168 `grub_apple_partition_map_init'.
18169 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove
18170 `disk/i386/pc/partition.c'. Add `kern/partition.c'.
18171 (kernel_img_HEADERS): Remove `machine/partition.h'. Add
18172 `partition.h' and `pc_partition.h'.
18173 (grub_setup_SOURCES): Remove
18174 `disk/i386/pc/partition.c'. Add `kern/partition.c',
18175 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
18176 (grub_emu_SOURCES): Likewise.
18177 (pkgdata_MODULES): Add `amiga.mod', `apple.mod' and `pc.mod'.
18178 (amiga_mod_SOURCES, amiga_mod_CFLAGS, apple_mod_SOURCES)
18179 (apple_mod_CFLAGS, pc_mod_SOURCES, pc_mod_CFLAGS): New variables.
18180 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
18181 `disk/powerpc/ieee1275/partition.c'. Add `kern/partition.c',
18182 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
18183 (grubof_SOURCES): Likewise.
18184 * disk/i386/pc/partition.c: File removed.
18185 * disk/powerpc/ieee1275/partition.c: Likewise.
18186 * include/grub/powerpc/ieee1275/partition.h: Likewise.
18187 * include/grub/i386/pc/partition.h: Likewise.
18188 * kern/partition.c: New file.
18189 * partmap/amiga.c: Likewise.
18190 * partmap/apple.c: Likewise.
18191 * partmap/pc.c: Likewise.
18192 * include/grub/partition.h: Likewise..
18193 * include/grub/pc_partition.h: Likewise.
18194 * util/grub-emu.c: Include <grub/partition.h> instead of
18195 <grub/machine/partition.h>.
18196 (main): Call `grub_pc_partition_map_init',
18197 `grub_amiga_partition_map_init' and
18198 `grub_apple_partition_map_init' and deinitialize afterwards.
18199 * util/i386/pc/biosdisk.c: Include `#include
18200 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
18201 `<grub/machine/partition.h>'.
18202 * util/i386/pc/grub-setup.c: Likewise.
18203 * util/i386/pc/biosdisk.c: Likewise.
18204 (grub_util_biosdisk_get_grub_dev): Only access the PC specific
18205 partition information in case of a PC partition.
18206 * util/i386/pc/grub-setup.c: Include `#include
18207 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
18208 `<grub/machine/partition.h>'.
18209 (setup): Only access the PC specific partition information in case
18212 2004-11-17 Hollis Blanchard <hollis@penguinppc.org>
18214 * kern/powerpc/ieee1275/init.c (grub_setjmp): Remove function.
18215 (grub_longjmp): Likewise.
18216 * include/grub/powerpc/setjmp.h (grub_jmp_buf): Set array size to
18218 * normal/powerpc/setjmp.S: New file.
18219 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
18220 `normal/powerpc/setjmp.S'.
18221 (grubof_CFLAGS): Add `-DGRUBOF'.
18222 * include/grub/setjmp.h [GRUB_UTIL]: Changed condition to
18223 [GRUB_UTIL && !GRUBOF].
18225 2004-11-16 Marco Gerards <metgerards@student.han.nl>
18227 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Skip any
18228 property named `name'. Correctly handle the error returned by
18229 `grub_ieee1275_finddevice' if a device can not be opened.
18231 2004-11-02 Hollis Blanchard <hollis@penguinppc.org>
18233 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_readkey): Test
18234 `actual' for negativity.
18235 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
18238 2004-11-01 Marco Gerards <metgerards@student.han.nl>
18240 * term/i386/pc/vga.c (VGA_HEIGHT): Changed to 350.
18241 (PAGE_OFFSET): New macro.
18242 (CRTC_ADDR_PORT): Likewise.
18243 (CRTC_DATA_PORT): Likewise.
18244 (START_ADDR_HIGH_REGISTER): Likewise.
18245 (START_ADDR_LOW_REGISTER): Likewise.
18246 (GRAPHICS_ADDR_PORT): Likewise.
18247 (GRAPHICS_DATA_PORT): Likewise.
18248 (READ_MAP_REGISTER): Likewise.
18249 (INPUT_STATUS1_REGISTER): Likewise.
18250 (INPUT_STATUS1_VERTR_BIT): Likewise.
18251 (page): New variable.
18252 (wait_vretrace): New function.
18253 (set_read_map): Likewise.
18254 (set_start_address): Likewise.
18255 (grub_vga_init): Use mode 0x10 instead of mode 0x12. Switch to
18257 (check_vga_mem): Take the page into account.
18258 (write_char): Likewise.
18259 (write_cursor): Likewise.
18260 (scroll_up): Likewise. Copy the page to the page that is not
18261 shown and switch between both pages.
18262 (grub_vga_putchar): Fix off by one error.
18263 (grub_vga_cls): Wait for the vertical retrace. Take the page into
18266 2004-11-01 Marco Gerards <metgerards@student.han.nl>
18268 Add support for iso9660 (including rockridge).
18270 * conf/i386-pc.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
18271 (iso9660_mod_SOURCES): New variable.
18272 (iso9660_mod_CFLAGS): Likewise.
18273 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
18274 * include/grub/fs.h (grub_iso9660_init): New prototype.
18275 * util/grub-emu.c (main): Call `grub_iso9660_init'.
18276 * fs/iso9660.c: New file.
18278 * include/grub/misc.h (grub_strncat): New prototype.
18279 * kern/misc.c (grub_strncat): New function.
18281 * fs/hfs.c (grub_hfs_mount): Translate the error
18282 `GRUB_ERR_OUT_OF_RANGE' to `GRUB_ERR_BAD_FS'.
18283 * fs/jfs.c (grub_jfs_mount): Likewise.
18284 * fs/ufs.c (grub_ufs_mount): Likewise.
18286 2004-10-28 Hollis Blanchard <hollis@penguinppc.org>
18288 * boot/powerpc/ieee1275/cmain.c (cmain): Remove asm statements
18289 which initialized BAT registers.
18290 * boot/powerpc/ieee1275/ieee1275.c (IEEE1275_CALL_ENTRY_FN,
18291 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
18293 * include/grub/powerpc/ieee1275/ieee1275.h (IEEE1275_CALL_ENTRY_FN,
18294 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
18296 * kern/powerpc/ieee1275/openfw.c (grub_map): New function.
18297 (grub_mapclaim): Likewise.
18298 * loader/powerpc/ieee1275/linux.c (grub_load_linux): Use
18299 grub_mapclaim instead of grub_ieee1275_claim. Assign linux_addr by
18302 2004-10-19 Hollis Blanchard <hollis@penguinppc.org>
18304 * conf/powerpc-ieee1275.rmk (COMMON_ASFLAGS): Remove -fno-builtin.
18305 (COMMON_CFLAGS): Remove -fno-builtin and -D__ASSEMBLY__. Add
18306 -ffreestanding and -msoft-float.
18308 2004-10-15 Hollis Blanchard <hollis@penguinppc.org>
18310 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Do not
18311 append ":0" to devpath if the GRUB_IEEE1275_NO_PARTITION_0 flag is
18312 set in grub_ieee1275_flags.
18314 2004-10-14 Hollis Blanchard <hollis@penguinppc.org>
18316 * include/grub/powerpc/ieee1275/ieee1275.h (abort): Add function
18318 * kern/powerpc/ieee1275/init.c (grub_machine_init): Call
18319 grub_console_init first.
18320 Change the memory range used for grub_ieee1275_claim and
18321 grub_mm_init_region.
18322 Print an error message if the claim fails.
18323 Include <grub/misc.h>.
18325 2004-10-13 Hollis Blanchard <hollis@penguinppc.org>
18327 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_iterate):
18328 Call grub_children_iterate for device nodes of type `scsi',
18330 (grub_ofdisk_open): Remove manual device alias resolution.
18331 Fix memory leak when device cannot be opened.
18332 * include/grub/powerpc/ieee1275/ieee1275.h
18333 (grub_children_iterate): New prototype.
18334 * kern/powerpc/ieee1275/openfw.c (grub_children_iterate):
18336 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
18337 Return -1 if args.size was -1.
18339 2004-10-11 Hollis Blanchard <hollis@penguinppc.org>
18341 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_flags): New global.
18342 (cmain): Accept 3 parameters. Test for 0xdeadbeef, indicating Old
18343 World Macintosh. If Old Wold, set flag in grub_ieee1275_flags; claim
18344 Open Firmware's memory for it; claim memory from _start to _end.
18345 * boot/powerpc/ieee1275/crt0.S (__bss_start): New extern.
18346 (_end): New extern.
18347 (_start): Zero BSS from __bss_start to _end.
18348 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
18350 (GRUB_IEEE1275_NO_PARTITION_0): New #define.
18352 2004-10-11 Hollis Blanchard <hollis@penguinppc.org>
18354 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): Return
18355 -1 if args.base was -1.
18357 2004-10-08 Hollis Blanchard <hollis@penguinppc.org>
18359 * term/powerpc/ieee1275/ieee1275.c (grub_ofconsole_cls): Use an ANSI
18360 escape sequence instead of a literal ^L. Also call
18361 grub_ofconsole_gotoxy.
18363 2004-10-03 Hollis Blanchard <hollis@penguinppc.org>
18365 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): change
18366 void * arguments to grub_addr_t. All callers updated. Also make
18367 the `result' argument optional.
18368 (grub_ieee1275_release): change void * arguments to grub_addr_t.
18369 All callers updated.
18371 2004-09-22 Hollis Blanchard <hollis@penguinppc.org>
18373 * commands/ls.c (grub_ls_list_files): Use the string following the
18374 initial ')', if present, as the filesystem path.
18375 * kern/rescue.c (grub_rescue_cmd_ls): Likewise.
18377 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): List crt0.S first.
18379 2004-09-18 Yoshinori K. Okuji <okuji@enbug.org>
18381 Make the source code of the menu interface more readable.
18383 * normal/menu.c: Include grub/mm.h.
18384 (TERM_WIDTH): New macro.
18385 (TERM_HEIGHT): Likewise.
18386 (TERM_INFO_HEIGHT): Likewise.
18387 (TERM_MARGIN): Likewise.
18388 (TERM_SCROLL_WIDTH): Likewise.
18389 (TERM_TOP_BORDER_Y): Likewise.
18390 (TERM_LEFT_BORDER_X): Likewise.
18391 (TERM_BORDER_WIDTH): Likewise.
18392 (TERM_MESSAGE_HEIGHT): Likewise.
18393 (TERM_BORDER_HEIGHT): Likewise.
18394 (TERM_NUM_ENTRIES): Likewise.
18395 (TERM_FIRST_ENTRY_Y): Likewise.
18396 (TERM_ENTRY_WIDTH): Likewise.
18397 (TERM_CURSOR_X): Likewise.
18398 (draw_border): Use macros instead of magic numbers.
18399 (print_entry): Likewise.
18400 (print_entries): Likewise.
18401 (run_menu): Likewise. Also, handle the key 'e'.
18402 (run_menu_entry): Ignore empty command lines.
18403 (print_message): Added a new argument EDIT. If EDIT is true,
18404 print a different message.
18405 (init_page): Likewise.
18406 (edit_menu_entry): New function. Not implemented yet.
18408 2004-09-17 Marco Gerards <metgerards@student.han.nl>
18410 Add `linux.mod' and `multiboot.mod' so linux and multiboot kernels
18411 can be loaded from normal mode.
18413 * conf/i386-pc.rmk (pkgdata_MODULES): Add `linux.mod' and
18415 (linux_mod_SOURCES, linux_mod_CFLAGS, multiboot_mod_SOURCES)
18416 (multiboot_mod_CFLAGS): New variables.
18417 * loader/i386/pc/linux_normal.c: New file.
18418 * loader/i386/pc/multiboot_normal.c: Likewise.
18420 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Don't use the
18421 attribute `unused'.
18423 * fs/ext2.c (grub_ext2_iterate_dir): Fix typos in inode type. Use
18424 `fdiro' to read the mode information from instead of `diro'.
18426 * fs/fshelp.c (grub_fshelp_find_file): Set type to foundtype after
18427 looking up a symlink.
18429 * include/grub/normal.h (GRUB_COMMAND_FLAG_NO_ARG_PARSE): New
18431 * normal/command.c (grub_command_execute): Don't parse the
18432 arguments when `GRUB_COMMAND_FLAG_NO_ARG_PARSE' is set in the
18433 flags of the command.
18435 * normal/menu.c (grub_menu_run): Fix typo.
18437 2004-09-14 Hollis Blanchard <hollis@penguinppc.org>
18439 * kern/powerpc/ieee1275/init.c (abort): Trap into Open Firmware.
18441 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_gotoxy): Use
18442 `y + 1' instead of `y - 1'.
18444 * conf/powerpc-ieee1275.rmk (grubof_LDFLAGS): Add `-N' and `-S'.
18446 2004-09-14 Yoshinori K. Okuji <okuji@enbug.org>
18448 From Hollis Blanchard <hollis@penguinppc.org>:
18449 * kern/misc.c (memmove): New alias for grub_memmove.
18450 (memcmp): New alias for grub_memcmp.
18451 (memset): New alias for grub_memset.
18452 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
18453 Change "int handle" to "grub_ieee1275_phandle_t handle".
18454 * include/grub/powerpc/ieee1275/ieee1275.h
18455 (grub_ieee1275_get_property): Likewise.
18457 2004-09-12 Tomas Ebenlendr <ebik@ucw.cz>
18459 Added normal mode command `chainloader' as module chain.mod, which
18460 depends on normal.mod and _chain.mod.
18462 * conf/i386-pc.rmk (pkgdata_MODULES): Add `chain.mod'.
18463 (chain_mod_SOURCES, chain_mod_CFLAGS): Variables added.
18464 * include/grub/i386/pc/loader.h (grub_rescue_cmd_chainloader):
18466 * loader/i386/pc/chainloader.c (grub_rescue_cmd_chainloader): All
18467 but arguments parsing moved to ...
18468 (grub_chainloader_cmd): ... here. New function.
18469 * include/grub/i386/pc/chainloader.h: New file.
18470 * loader/i386/pc/chainloader_normal.c: Likewise.
18472 2004-09-11 Marco Gerards <metgerards@student.han.nl>
18474 * conf/i386-pc.rmk (kernel_img_SOURCES): Added kern/fshelp.c.
18475 (grub_mkimage_LDFLAGS): Likewise.
18476 (grub_emu_SOURCES): Likewise.
18477 (kernel_img_HEADERS): Added fshelp.h.
18478 * fs/ext2.c: Include <grub/fshelp.h>.
18479 (FILETYPE_REG): New macro.
18480 (FILETYPE_INO_REG): Likewise.
18481 (grub_ext_sblock): Renamed to `grub_ext2_sblock'.
18483 (ext2_block_group): Renamed to `grub_ext2_block_group'. Changed
18485 (grub_fshelp_node): New struct.
18486 (grub_ext2_data): Added member `diropen'. Changed member `inode'
18488 (grub_ext2_get_file_block): Removed function.
18489 (grub_ext2_read_block): New function.
18490 (grub_ext2_read_file): Replaced parameter `data' by `node'.
18491 This function was written.
18492 (grub_ext2_mount): Read the root inode. Create a diropen struct.
18493 (grub_ext2_find_file): Removed function.
18494 (grub_ext2_read_symlink): New function.
18495 (grub_ext2_iterate_dir): Likewise.
18496 (grub_ext2_open): Rewritten.
18497 (grub_ext2_dir): Rewritten.
18498 * include/grub/fshelp.h: New file.
18499 * fs/fshelp.c: Likewise.
18501 2004-09-10 Yoshinori K. Okuji <okuji@enbug.org>
18503 * normal/menu.c: Include grub/loader.h and grub/machine/time.h.
18504 (print_message): Add a missing newline.
18505 (run_menu): Added timeout support.
18506 (run_menu_entry): New local function.
18507 (grub_menu_run): Added support for booting.
18509 * kern/loader.c (grub_loader_is_loaded): New function.
18511 * include/grub/powerpc/ieee1275/time.h: Include grub/symbol.h.
18512 (grub_get_rtc): Exported.
18514 * include/grub/i386/pc/time.h: Include grub/symbol.h.
18515 (grub_get_rtc): Exported.
18517 * include/grub/normal.h (struct grub_command_list): Remove
18518 constant from the member `command'.
18520 * include/grub/loader.h (grub_loader_is_loaded): Declared.
18522 * include/grub/err.h (GRUB_ERR_INVALID_COMMAND): New constant.
18524 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/time.h.
18526 2004-08-28 Marco Gerards <metgerards@student.han.nl>
18528 Add support for the JFS filesystem.
18530 * fs/jfs.c: New file.
18531 * include/grub/fs.h (grub_jfs_init): New prototype.
18532 (grub_jfs_fini): New prototype.
18533 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/jfs.c.
18534 (grub_emu_SOURCES): Likewise.
18535 (pkgdata_MODULES): Add jfs.mod.
18536 (jfs_mod_SOURCES): New variable.
18537 (jfs_mod_CFLAGS): Likewise.
18538 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs.jfs.c.
18539 (grubof_SOURCES): Likewise.
18540 * util/grub-emu.c (main): Initialize and deinitialize JFS support.
18542 * fs/fat.c (grub_fat_find_dir): Convert the filename little
18543 endian to the host endian.
18544 (grub_fat_utf16_to_utf8): Move function from there...
18545 * kern/misc.c (grub_utf16_to_utf8): ...to here. Do not convert
18546 the endianness of the source string anymore.
18547 * include/grub/misc.h (grub_utf16_to_utf8): New prototype.
18549 2004-08-24 Marco Gerards <metgerards@student.han.nl>
18551 * commands/boot.c (grub_boot_init) [GRUB_UTIL]: Make conditional.
18552 (grub_boot_fini) [GRUB_UTIL]: Likewise.
18553 (GRUB_MOD_INIT) [!GRUB_UTIL]: Likewise.
18554 (GRUB_MOD_FINI) [!GRUB_UTIL]: Likewise.
18556 * fs/hfs.c (grub_hfs_find_node): Add a prototype for `node_found'.
18557 (grub_hfs_iterate_dir): Make the function static. Add prototypes
18558 for `node_found' and `it_dir'.
18559 (grub_hfs_dir): Add prototype for `dir_hook'.
18561 * fs/minix.c (grub_minix_get_file_block): Add prototype for
18562 `grub_get_indir'. Rename `indir' in two blocks to `indir16'
18563 and `indir32' to silence a gcc warning.
18565 * include/grub/fs.h (grub_hfs_init): New prototype.
18566 (grub_hfs_fini): Likewise.
18569 2004-08-21 Yoshinori K. Okuji <okuji@enbug.org>
18571 Each disk device has its own id now. This is useful to make use
18572 of multiple disk devices.
18574 * include/grub/disk.h (grub_disk_dev_id): New enum.
18575 (GRUB_DISK_DEVICE_BIOSDISK_ID): New constant.
18576 (GRUB_DISK_DEVICE_OFDISK_ID): Likewise.
18578 * disk/i386/pc/biosdisk.c (grub_biosdisk_dev): Specify
18579 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
18581 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_dev): Specify
18582 GRUB_DISK_DEVICE_OFDISK_ID as an id.
18584 * util/i386/pc/biosdisk.c (grub_util_biosdisk_dev): Specify
18585 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
18587 * include/grub/disk.h (struct grub_disk_dev): Added a new member
18588 "id" which is used by the cache manager.
18590 * normal/main.c (grub_normal_init_page): Use "GNU GRUB" instead
18593 2004-08-18 Marco Gerards <metgerards@student.han.nl>
18595 * fs/hfs.c: New file.
18596 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/hfs.c.
18597 (grub_emu_SOURCES): Likewise.
18598 (pkgdata_MODULES): Add hfs.mod.
18599 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/hfs.c.
18600 (grubof_SOURCES): Likewise.
18601 * util/grub-emu.c (main): Initialize and deinitialize HFS support.
18603 * include/grub/misc.h (grub_strncasecmp): Add prototype.
18604 * kern/misc.c (grub_strncasecmp): Add function.
18606 2004-08-14 Marco Gerards <metgerards@student.han.nl>
18608 * include/grub/arg.h (GRUB_ARG_OPTION_OPTIONAL): Surround macro
18611 * fs/ext2.c (FILETYPE_UNKNOWN): New macro.
18612 (grub_ext2_dir): In case the directory entry type is unknown, read
18615 2004-08-02 Peter Bruin <pjbruin@dds.nl>
18617 * loader/powerpc/ieee1275/linux.c (grub_linux_init): Pass
18618 grub_load_linux instead of grub_rescue_cmd_linux as second
18619 argument of grub_rescue_register_command.
18621 * Makefile.in (RMKFILES): Add conf/powerpc-ieee1275.rmk.
18623 2004-07-27 Marco Gerards <metgerards@student.han.nl>
18625 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_release): New
18627 * commands/boot.c: Remove the check for `GRUB_UTIL'.
18628 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
18629 `loader/powerpc/ieee1275/linux.c',
18630 `loader/powerpc/ieee1275/linux_normal.c' and `commands/boot.c'.
18631 * include/grub/powerpc/ieee1275/ieee1275.h
18632 (grub_ieee1275_release): New prototype.
18633 * include/grub/powerpc/ieee1275/loader.h: Rewritten.
18634 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize
18635 normal, boot, linux and linux_normal.
18636 * loader/powerpc/ieee1275/linux.c: New file.
18637 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
18639 2004-07-12 Marco Gerards <metgerards@student.han.nl>
18641 * normal/arg.c (grub_arg_parse): Correct error handling after
18642 reallocating the argumentlist (check if `argl' is not null instead
18643 of checking if `args' is not null).
18644 * kern/mm.c (grub_realloc): Return the same pointer when using the
18645 same region, instead of returning the header address.
18647 2004-07-11 Marco Gerards <metgerards@student.han.nl>
18649 * disk/powerpc/ieee1275/partition.c (grub_partition_iterate): Skip
18650 one block instead of two when looking for the initial partition.
18651 (grub_partition_probe): Initialize the local variable `p' with 0.
18652 Use base 10 for the grub_strtoul call.
18653 * kern/misc.c (grub_strncpy): Fix off by one bug. Eliminated the
18654 need for one local variable.
18655 (grub_strtoul): Don't add the new value to `num', instead of that
18658 2004-07-11 Marco Gerards <metgerards@student.han.nl>
18660 * conf/i386-pc.rmk (pkgdata_IMAGE): Add pxeboot.img.
18661 (pxeboot_img_SOURCES): New variable.
18662 (pxeboot_img_ASFLAGS): Likewise.
18663 (pxeboot_img_LDFLAGS): Likewise.
18664 * boot/i386/pc/pxeboot.S: New file. Based on pxeloader.S from
18665 GRUB Legacy and boot.S. Adopted for GRUB 2 by lode leroy
18666 <lode_leroy@hotmail.com>.
18668 2004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
18670 * kern/rescue.c (grub_enter_rescue_mode): Don't continue when
18671 there was no input.
18673 2004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
18675 * normal/cmdline.c (grub_set_history): Fix off by one bug. Fixed
18676 the history buffer logic.
18678 2004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
18680 * fs/ext2.c (FILETYPE_INO_MASK, FILETYPE_INO_DIRECTORY)
18681 (FILETYPE_INO_SYMLINK): New macros.
18682 (grub_ext2_find_file): Check if the node is a directory using the
18683 inode stat information instead of using the filetype in the
18684 dirent. Exclude the first character of an absolute symlink.
18685 (grub_ext2_dir): Mask out the filetype part of the mode member of
18688 2004-05-24 Marco Gerards <metgerards@student.han.nl>
18690 Add support for UFS version 1 and 2. Add support for the minix
18691 filesystem version 1 and 2, both the variants with 14 and 30 long
18694 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ufs.c and
18696 (grub_emu_SOURCES): Likewise.
18697 (pkgdata_MODULES): Add ufs.mod and minix.mod.
18698 (ufs_mod_SOURCES): New variable.
18699 (ufs_mod_CFLAGS): Likewise.
18700 (minix_mod_SOURCES): Likewise.
18701 (minix_mod_CFLAGS): Likewise.
18702 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/ufs.c and
18704 (grubof_SOURCES): Likewise.
18705 * fs/ufs.c: New file.
18706 * fs/minix.c: New file.
18707 * include/grub/fs.h (grub_ufs_init): New prototype.
18708 (grub_ufs_fini): Likewise.
18709 (grub_minix_init): Likewise.
18710 (grub_minix_fini): Likewise.
18711 * util/grub-emu.c (main): Initialize and deinitialize UFS and
18714 2004-04-30 Jeroen Dekkers <jeroen@dekkers.cx>
18716 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add normal/arg.c,
18717 commands/ls.c, commands/terminal.c, commands/boot.c,
18718 commands/cmp.c and commands/cat.c.
18719 (grubof_LDFLAGS): Add -nostdlib -static-libgcc -lgcc.
18721 * kern/powerpc/ieee1275/init.c: Include "grub/env.h" instead of
18724 2004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
18726 All symbols prefixed with PUPA_ and pupa_ are renamed to GRUB_
18727 and grub_, respectively. Because the conversion is trivial and
18728 mechanical, I omit the details here. Please refer to the CVS
18729 if you need more information.
18731 2004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
18733 * include/pupa: Renamed to ...
18734 * include/grub: ... this.
18735 * util/i386/pc/pupa-mkimage.c: Renamed to ...
18736 * util/i386/pc/grub-mkimage.c: ... this.
18737 * util/i386/pc/pupa-setup.c: Renamed to ...
18738 * util/i386/pc/grub-setup.c: ... this.
18739 * util/pupa-emu.c: Renamed to ...
18740 * util/grub-emu.c: ... this.
18742 2004-03-29 Marco Gerards <metgerards@student.han.nl>
18744 Add support for the newworld apple macintosh (PPC). This has been
18745 tested on the powerbook 2000 only. It only adds support for
18746 generic ieee1275 functions, console and disk support. This should
18747 be easy to port to other architectures with support for Open
18750 * configure.ac: Accept the powerpc as host_cpu. In the case of
18751 the powerpc cpu set the host_vendor to ieee1275. Make sure the i386
18752 specific tests are only executed while building for the i386.
18753 Inverse test for crosscompile.
18754 * genmk.rb (Utility): Allow assembler files.
18755 * normal/cmdline.c (pupa_tab_complete): Reset pupa_errno.
18756 * conf/powerpc-ieee1275.rmk: New file.
18757 * disk/powerpc/ieee1275/ofdisk.c: Likewise.
18758 * disk/powerpc/ieee1275/partition.c: Likewise.
18759 * include/pupa/powerpc/ieee1275/biosdisk.h: Likewise.
18760 * include/pupa/powerpc/ieee1275/console.h: Likewise.
18761 * include/pupa/powerpc/ieee1275/partition.h: Likewise.
18762 * include/pupa/powerpc/ieee1275/time.h: Likewise.
18763 * include/pupa/powerpc/ieee1275/util/biosdisk.h: Likewise.
18764 * include/pupa/powerpc/ieee1275/multiboot.h: Likewise.
18765 * include/pupa/powerpc/ieee1275/loader.h
18766 * include/pupa/powerpc/setjmp.h: Likewise.
18767 * include/pupa/powerpc/types.h: Likewise.
18768 * kern/powerpc/ieee1275/init.c: Likewise.
18769 * kern/powerpc/ieee1275/openfw.c: Likewise.
18770 * term/powerpc/ieee1275/ofconsole.c: Likewise.
18772 These files were written by Johan Rydberg
18773 (jrydberg@night.trouble.net) and I only modified them slightly.
18775 * boot/powerpc/ieee1275/cmain.c: New file.
18776 * boot/powerpc/ieee1275/crt0.S: Likewise.
18777 * boot/powerpc/ieee1275/ieee1275.c: Likewise.
18778 * include/pupa/powerpc/ieee1275/ieee1275.h: Likewise.
18780 2004-03-14 Jeroen Dekkers <jeroen@dekkers.cx>
18782 * Makefile.in: Update copyright.
18783 * genmodsrc.sh: Likewise.
18784 * gensymlist.sh: Likewise.
18785 * term/i386/pc/vga.c: Indent correctly.
18787 * util/i386/pc/pupa-mkimage.c (usage): Use PACKAGE_BUGREPORT as
18788 bugreporting address.
18789 * util/i386/pc/pupa-setup.c (usage): Likewise,
18790 (main): Call pupa_ext2_init and pupa_ext2_fini.
18792 * fs/fat.c (log2): Renamed to ...
18793 (fat_log2): ... this.
18794 All callers changed.
18795 * kern/misc.c (memcpy): Alias to pupa_memmove.
18796 * loader/i386/pc/multiboot.c (pupa_rescue_cmd_multiboot): Fix
18798 * util/console.c (pupa_ncurses_fini): Return 0.
18800 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open)[__linux__]:
18801 Move fail label here.
18802 [__GNU__]: Don't warn when using stat.
18803 (open_device)[!__linux__]: Check if FD < 0 instead of !FD.
18804 (pupa_util_biosdisk_get_pupa_dev)[__GNU__]: Change type of N to
18805 long int. Use strtol instead of strtoul.
18807 2004-03-14 Marco Gerards <metgerards@student.han.nl>
18809 * commands/boot.c: New file.
18810 * commands/cat.c: Likewise.
18811 * commands/cmp.c: Likewise.
18812 * commands/ls.c: Likewise.
18813 * commands/terminal.c: Likewise.
18814 * normal/command.c: Include <pupa/env.h> and <pupa/dl.h>.
18815 (pupa_register_command): Changed interface to match the new
18817 (pupa_command_execute): Changed (almost rewritten) so it uses
18818 pupa_split_command. Added support for setting variables using the
18820 (rescue_command): Changed to work with the new argument parser.
18821 (terminal_command): Moved from here to commands/terminal.c.
18822 (set_command): New function.
18823 (unset_command): New function.
18824 (insmod_command): New function.
18825 (rmmod_command): New function.
18826 (lsmod_command): New function.
18827 (pupa_command_init): Don't initialize the command terminal
18828 anymore. Initialize the commands set, unset, insmod, rmmod and
18830 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/env.c.
18831 (kernel_img_HEADERS): Add arg.h and env.h.
18832 (pupa_mkimage_LDFLAGS): Add kern/env.c.
18833 (pupa_emu_SOURCES): Add kern/env.c, commands/ls.c,
18834 commands/terminal.c commands/boot.c commands/cmp.c commands/cat.c,
18836 (pkgdata_MODULES): Add ls.mod, boot.mod, cmp.mod, cat.mod and
18838 (normal_mod_SOURCES): Add normal/arg.c and normal/arg.c.
18839 (boot_mod_SOURCES): New variable.
18840 (terminal_mod_SOURCES): Likewise.
18841 (ls_mod_SOURCES): Likewise.
18842 (cmp_mod_SOURCES): Likewise.
18843 (cat_mod_SOURCES): Likewise.
18845 * normal/arg.c: New file.
18846 * kern/env.c: Likewise.
18847 * include/pupa/arg.h: Likewise.
18848 * include/pupa/env.h: Likewise.
18849 * font/manager.c (font_command): Changed to match argument parsing
18851 (PUPA_MOD_INIT): Likewise.
18852 * hello/hello.c (pupa_cmd_hello): Likewise.
18853 (PUPA_MOD_INIT): Likewise.
18854 * include/pupa/disk.h: Include <pupa/device.h>.
18855 (pupa_print_partinfo): New prototype.
18856 * include/pupa/dl.h (pupa_dl_set_prefix): Prototype removed.
18857 (pupa_dl_get_prefix): Likewise.
18858 * include/pupa/misc.h: Include <pupa/err.h>.
18859 (pupa_isgraph): New prototype.
18860 (pupa_isdigit): Likewise.
18861 (pupa_split_cmdline): Likewise.
18862 * include/pupa/normal.h: Include <pupa/arg.h>.
18863 (pupa_command): Changed the prototype of the member `func' to
18864 match the argument parsing interface. Added member `options'.
18865 (pupa_register_command): Updated to match function.
18866 (pupa_arg_parse): New prototype.
18867 (pupa_hello_init) [PUPA_UTIL]: New prototype.
18868 (pupa_hello_fini) [PUPA_UTIL]: Likewise.
18869 (pupa_ls_init) [PUPA_UTIL]: Likewise.
18870 (pupa_ls_fini) [PUPA_UTIL]: Likewise.
18871 (pupa_cat_init) [PUPA_UTIL]: Likewise.
18872 (pupa_cat_fini) [PUPA_UTIL]: Likewise.
18873 (pupa_boot_init) [PUPA_UTIL]: Likewise.
18874 (pupa_boot_fini) [PUPA_UTIL]: Likewise.
18875 (pupa_cmp_init) [PUPA_UTIL]: Likewise.
18876 (pupa_cmp_fini) [PUPA_UTIL]: Likewise.
18877 (pupa_terminal_init) [PUPA_UTIL]: Likewise.
18878 (pupa_terminal_fini) [PUPA_UTIL]: Likewise.
18879 * kern/disk.c: Include <pupa/file.h>.
18880 (pupa_print_partinfo): New function.
18881 * kern/dl.c: Include <pupa/env.h>.
18882 (pupa_dl_dir): Variable removed.
18883 (pupa_dl_load): Use the environment variable `prefix' instead of
18884 the variable pupa_dl_dir.
18885 (pupa_dl_set_prefix): Function removed.
18886 (pupa_dl_get_prefix): Likewise.
18887 * kern/i386/pc/init.c: Include <pupa/env.h>.
18888 (pupa_machine_init): Use the environment variable `prefix' instead of
18889 using pupa_dl_set_prefix to set the prefix.
18890 * kern/main.c: Include <pupa/env.h>.
18891 (pupa_set_root_dev): Use the environment variable `prefix' instead of
18892 using pupa_dl_get_prefix to get the prefix.
18893 * kern/misc.c: Include <pupa/env.h>.
18894 (pupa_isdigit): New function.
18895 (pupa_isgraph): Likewise.
18896 (pupa_ftoa): Likewise.
18897 (pupa_vsprintf): Added support for printing values of the type
18898 `double'. Make it possible to format variable output when using
18899 formatting like `%1.2%f'.
18900 (pupa_split_cmdline): New function.
18901 * kern/rescue.c: Include <pupa/env.h>.
18902 (next_word): Removed function.
18903 (pupa_rescue_cmd_prefix): Likewise.
18904 (pupa_rescue_cmd_set): New function.
18905 (pupa_rescue_cmd_unset): New function.
18906 (pupa_enter_rescue_mode): Use the `pupa_split_cmdline' function to
18907 split the command line instead of splitting it here. Added
18908 support for setting variables using the syntax `foo=bar'. Don't
18909 initialize the prefix command anymore. Initialized the set and
18911 * normal/cmdline.c: Include <pupa/env.h>.
18912 (pupa_tab_complete): Added prototypes for print_simple_completion,
18913 print_partition_completion, add_completion, iterate_commands,
18914 iterate_dev, iterate_part and iterate_dir. Moved code to print
18915 partition information from here to kern/disk.c.
18916 (pupa_cmdline_run): Don't check if the function exists anymore.
18917 * normal/main.c: Include <pupa/env.h>.
18918 (pupa_rescue_cmd_normal): Use the environment variable `prefix'
18919 instead of using pupa_dl_get_prefix to get the prefix.
18920 * term/i386/pc/vga.c: Include <pupa/arg.h>.
18921 (check_vga_mem): Cast pointers to `void *' to silence a gcc
18923 (pupa_vga_putchar) [! DEBUG_VGA]: Removed for this case.
18924 (pupa_vga_setcolor): Declare unused variables with `__attribute__
18925 ((unused))' to silence a gcc warning.
18926 (pupa_vga_setcolor): Likewise.
18927 (debug_command): Changed to match argument parsing
18929 * util/pupa-emu.c: Include <pupa/env.h>.
18930 (options): Added 0's for unused fields to silence a gcc warning.
18932 (main): Use the environment variable `prefix' instead of using
18933 pupa_dl_set_prefix to set the prefix. Initialize the commands ls,
18934 boot, cmp, cat and terminal. Finish the commands boot, cmp, cat
18937 * util/i386/pc/getroot.c: Include <pupa/i386/pc/util/biosdisk.h>.
18938 * util/misc.c: Include <malloc.h>.
18939 (pupa_malloc): Rewritten so errors are correctly reported.
18940 (pupa_realloc): Likewise.
18941 (pupa_memalign): Likewise.
18942 (pupa_mm_init_region): Declare unused variables with
18943 `__attribute__ ((unused))' to silence a gcc warning.
18944 * normal/i386/setjmp.S: Remove tab at the end of the file to
18945 silence a gcc warning.
18946 * loader/i386/pc/linux.c (pupa_rescue_cmd_initrd): Declare unused
18947 variables with `__attribute__ ((unused))' to silence a gcc
18949 * loader/i386/pc/multiboot.c (pupa_multiboot_unload): Make the
18950 local variable i unsigned to silence a gcc warning.
18952 * kern/term.c: Include <pupa/misc.h>.
18953 (pupa_more_lines): New variable.
18954 (pupa_more): Likewise.
18955 (pupa_putcode): When the pager is active pause at the end of every
18957 (pupa_set_more): New function.
18958 * include/pupa/term.h (pupa_set_more): New prototype.
18961 2004-03-07 Yoshinori K. Okuji <okuji@enbug.org>
18963 Now this project is GRUB 2 rather than PUPA. The location of
18964 the CVS repository was moved to GRUB's.
18966 * configure.ac: Use bug-grub as the reporting address.
18967 Use GRUB instead of PUPA.
18968 Change the version number to 1.90.
18970 2004-02-24 Yoshinori K. Okuji <okuji@enbug.org>
18972 * genkernsyms.sh: Updated copyright information.
18973 * genmk.rb: Likewise.
18974 * genmodsrc.sh: Likewise.
18975 * gensymlist.sh: Likewise.
18976 * boot/i386/pc/boot.S: Likewise.
18977 * boot/i386/pc/diskboot.S: Likewise.
18978 * disk/i386/pc/biosdisk.c: Likewise.
18979 * disk/i386/pc/partition.c: Likewise.
18980 * font/manager.c: Likewise.
18981 * fs/ext2.c: Likewise.
18982 * fs/fat.c: Likewise.
18983 * include/pupa/boot.h: Likewise.
18984 * include/pupa/device.h: Likewise.
18985 * include/pupa/disk.h: Likewise.
18986 * include/pupa/dl.h: Likewise.
18987 * include/pupa/elf.h: Likewise.
18988 * include/pupa/err.h: Likewise.
18989 * include/pupa/file.h: Likewise.
18990 * include/pupa/font.h: Likewise.
18991 * include/pupa/fs.h: Likewise.
18992 * include/pupa/kernel.h: Likewise.
18993 * include/pupa/loader.h: Likewise.
18994 * include/pupa/misc.h: Likewise.
18995 * include/pupa/mm.h: Likewise.
18996 * include/pupa/net.h: Likewise.
18997 * include/pupa/normal.h: Likewise.
18998 * include/pupa/rescue.h: Likewise.
18999 * include/pupa/setjmp.h: Likewise.
19000 * include/pupa/symbol.h: Likewise.
19001 * include/pupa/term.h: Likewise.
19002 * include/pupa/types.h: Likewise.
19003 * include/pupa/i386/setjmp.h: Likewise.
19004 * include/pupa/i386/types.h: Likewise.
19005 * include/pupa/i386/pc/biosdisk.h: Likewise.
19006 * include/pupa/i386/pc/boot.h: Likewise.
19007 * include/pupa/i386/pc/console.h: Likewise.
19008 * include/pupa/i386/pc/init.h: Likewise.
19009 * include/pupa/i386/pc/kernel.h: Likewise.
19010 * include/pupa/i386/pc/linux.h: Likewise.
19011 * include/pupa/i386/pc/loader.h: Likewise.
19012 * include/pupa/i386/pc/memory.h: Likewise.
19013 * include/pupa/i386/pc/multiboot.h: Likewise.
19014 * include/pupa/i386/pc/partition.h: Likewise.
19015 * include/pupa/i386/pc/time.h: Likewise.
19016 * include/pupa/i386/pc/vga.h: Likewise.
19017 * include/pupa/i386/pc/util/biosdisk.h: Likewise.
19018 * include/pupa/util/getroot.h: Likewise.
19019 * include/pupa/util/misc.h: Likewise.
19020 * include/pupa/util/resolve.h: Likewise.
19021 * kern/device.c: Likewise.
19022 * kern/disk.c: Likewise.
19023 * kern/dl.c: Likewise.
19024 * kern/err.c: Likewise.
19025 * kern/file.c: Likewise.
19026 * kern/fs.c: Likewise.
19027 * kern/loader.c: Likewise.
19028 * kern/main.c: Likewise.
19029 * kern/misc.c: Likewise.
19030 * kern/mm.c: Likewise.
19031 * kern/rescue.c: Likewise.
19032 * kern/term.c: Likewise.
19033 * kern/i386/dl.c: Likewise.
19034 * kern/i386/pc/init.c: Likewise.
19035 * kern/i386/pc/lzo1x.S: Likewise.
19036 * kern/i386/pc/startup.S: Likewise.
19037 * loader/i386/pc/chainloader.c: Likewise.
19038 * loader/i386/pc/linux.c: Likewise.
19039 * loader/i386/pc/multiboot.c: Likewise.
19040 * normal/cmdline.c: Likewise.
19041 * normal/command.c: Likewise.
19042 * normal/main.c: Likewise.
19043 * normal/menu.c: Likewise.
19044 * normal/i386/setjmp.S: Likewise.
19045 * term/i386/pc/console.c: Likewise.
19046 * term/i386/pc/vga.c: Likewise.
19047 * util/console.c: Likewise.
19048 * util/genmoddep.c: Likewise.
19049 * util/misc.c: Likewise.
19050 * util/pupa-emu.c: Likewise.
19051 * util/resolve.c: Likewise.
19052 * util/unifont2pff.rb: Likewise.
19053 * util/i386/pc/biosdisk.c: Likewise.
19054 * util/i386/pc/getroot.c: Likewise.
19055 * util/i386/pc/pupa-mkimage.c: Likewise.
19056 * util/i386/pc/pupa-setup.c: Likewise.
19058 2004-02-15 Jeroen Dekkers <jeroen@dekkers.cx>
19060 * fs/ext2.c (pupa_ext2_read_file): Correct the value of BLOCKEND
19061 when it is EXT2_BLOCK_SIZE (data). New argument READ_HOOK, all
19062 callers changed. Set DATA->DISK->READ_HOOK to READ_HOOK before
19063 reading and reset it after reading.
19064 (pupa_ext2_close): Return PUPA_ERR_NONE.
19066 * include/pupa/i386/pc/linux.h (PUPA_LINUX_INITRD_MAX_ADDRESS):
19068 (struct linux_kernel_header): Add kernel_version and
19070 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Check whether
19071 pupa_file_read succeeds.
19072 (pupa_rescue_cmd_initrd): Implement.
19074 2003-12-03 Marco Gerards <metgerards@student.han.nl>
19076 * fs/ext2.c (pupa_ext2_label): New function.
19077 (pupa_ext2_fs): Added label.
19078 * fs/fat.c (pupa_fat_label): New function.
19079 (pupa_fat_fs): Added label.
19080 * include/pupa/fs.h (struct pupa_fs): Added prototype label.
19082 * kern/misc.c (pupa_strndup): New function.
19083 * include/pupa/misc.h (pupa_strndup): New prototype.
19085 * include/pupa/normal.h: Include <pupa/err.h>.
19086 (pupa_set_history): New prototype.
19087 (pupa_iterate_commands): New prototype.
19088 * normal/cmdline.c: Include <pupa/machine/partition.h>,
19089 <pupa/disk.h>, <pupa/file.h>.
19090 (hist_size): New variable.
19091 (hist_lines): Likewise.
19092 (hist_end): Likewise.
19093 (hist_used): Likewise.
19094 (pupa_set_history): New function.
19095 (pupa_history_get): Likewise.
19096 (pupa_history_add): Likewise.
19097 (pupa_history_replace): Likewise.
19098 (pupa_tab_complete): Likewise.
19099 (pupa_cmdline_run): Added tab completion and history buffer. Tab
19100 completion shows partitionnames while completing partitions, this
19101 feature was suggested by Jeff Bailey.
19102 * normal/command.c (pupa_iterate_commands): New function.
19103 * normal/main.c (PUPA_DEFAULT_HISTORY_SIZE): New macro.
19104 (pupa_normal_init): Initialize history buffer.
19105 (PUPA_MOD_INIT): Likewise.
19106 (pupa_normal_fini): Free the history buffer.
19107 (PUPA_MOD_FINI): Likewise.
19109 * util/console.c (pupa_ncurses_getkey): Accept 127 as backspace
19112 * aclocal.m4 (pupa_I386_CHECK_REGPARM_BUG): New DEFUN.
19113 * configure.ac [i386]: Check for regparam bug.
19114 (NESTED_FUNC_ATTR) [! i386]: Defined.
19116 2003-11-17 Marco Gerards <metgerards@student.han.nl>
19118 * conf/i386-pc.rmk (sbin_UTILITIES): Added pupa-emu.
19119 (pupa_setup_SOURCES): Added util/i386/pc/getroot.c.
19120 (pupa_emu_SOURCES): New variable.
19121 (pupa_emu_LDFLAGS): Likewise.
19122 * include/pupa/fs.h (pupa_ext2_init) [PUPA_UTIL]: New prototype.
19123 (pupa_ext2_fini) [PUPA_UTIL]: Likewise.
19124 * include/pupa/normal.h (pupa_normal_init) [PUPA_UTIL]: Likewise.
19125 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
19126 * include/pupa/setjmp.h [PUPA_UTIL]: Include <setjmp.h>.
19127 (pupa_jmp_buf): New typedef.
19128 (pupa_setjmp) [PUPA_UTIL]: New macro.
19129 (pupa_longjmp) [PUPA_UTIL]: Likewise.
19130 * include/pupa/term.h (struct pupa_term): New member `refresh'.
19131 (pupa_refresh): New prototype.
19132 * include/pupa/util/getroot.h: New file.
19133 * kern/misc.c (pupa_vsprintf): Refresh the screen after updating
19135 * kern/rescue.c (pupa_rescue_get_command_line): Likewise.
19136 (pupa_rescue_cmd_cat): Likewise.
19137 (pupa_rescue_cmd_ls): Likewise.
19138 (pupa_rescue_cmd_testload): Likewise.
19139 (pupa_rescue_cmd_lsmod): Likewise.
19140 * normal/cmdline.c (pupa_cmdline_get): Likewise.
19141 * normal/menu.c (run_menu): Likewise.
19142 * kern/term.c (pupa_cls): Likewise.
19143 (pupa_refresh): New function.
19144 * normal/normal.c (pupa_normal_init) [PUPA_UTIL]: New function.
19145 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
19146 * util/console.c: New file.
19148 * util/i386/pc/getroot.c: New file.
19149 * util/i386/pc/pupa-setup.c: Include <pupa/util/getroot.h>.
19150 (pupa_putchar): New function.
19151 (pupa_refresh): Likewise.
19152 (xgetcwd): Function moved to ...
19153 (strip_extra_slashes): Likewise.
19154 (get_prefix): Likewise.
19155 * util/i386/pc/getroot.c: ... here.
19156 (find_root_device): Function moved and renamed to...
19157 * util/i386/pc/getroot.c (pupa_find_root_device): ... here.
19158 Changed all callers.
19159 * util/i386/pc/pupa-setup.c (guess_root_device): Function moved
19161 * util/i386/pc/getroot.c (pupa_guess_root_device): ... here.
19162 Changed all callers.
19163 * util/misc.c (pupa_memalign): New function.
19164 (pupa_mm_init_region): Likewise.
19165 (pupa_register_exported_symbols): Likewise.
19166 (pupa_putchar): Function removed.
19167 * util/pupa-emu.c: New file.
19169 2003-11-16 Jeroen Dekkers <jeroen@dekkers.cx>
19171 * conf/i386-pc.rmk (pkgdata_MODULES): Add _multiboot.mod.
19172 (_multiboot_mod_SOURCES): New variable.
19173 (_multiboot_mod_CFLAGS): Likewise.
19174 * loader/i386/pc/multiboot.c: New file.
19175 * include/pupa/i386/pc/multiboot.h: Likewise.
19176 * kern/i386/pc/startup.S: Include pupa/machine/multiboot.h.
19177 (pupa_multiboot_real_boot): New function.
19178 * include/pupa/i386/pc/loader.h: Include pupa/machine/multiboot.h.
19179 (pupa_multiboot_real_boot): New prototype.
19180 (pupa_rescue_cmd_multiboot): Likewise
19181 (pupa_rescue_cmd_module): Likewise.
19183 * kern/loader.c (pupa_loader_set): Continue when
19184 pupa_loader_unload_func() fails.
19185 (pupa_loader_unset): New function.
19186 * include/pupa/loader.h (pupa_loader_unset): New prototype.
19188 * kern/misc.c (pupa_stpcpy): New function.
19189 * include/pupa/misc.h (pupa_stpcpy): New prototype.
19191 2003-11-12 Marco Gerards <metgerards@student.han.nl>
19193 * disk/i386/pc/biosdisk.c (pupa_biosdisk_open): Correctly check
19194 for available extensions.
19196 * include/pupa/i386/pc/time.h: New file.
19197 * kern/disk.c: Include <pupa/machine/time.h>.
19198 (PUPA_CACHE_TIMEOUT): New macro.
19199 (pupa_last_time): New variable.
19200 (pupa_disk_open): Flush the cache when there was a timeout.
19201 (pupa_disk_close): Reset the timer.
19202 * kern/i386/pc/startup.S (pupa_get_rtc): Renamed from
19204 * util/misc.c: Include <sys/times.h>
19205 (pupa_get_rtc): New function.
19207 2003-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
19209 * fs/ext2.c (struct pupa_ext2_inode): Declare struct datablocks
19211 (pupa_ext2_get_file_block): Use blocks member.
19213 * fs/ext2.c (pupa_ext2_read_file): Only set skipfirst for the
19214 first block. Return -1 instead of pupa_errno on error.
19216 2003-10-27 Marco Gerards <metgerards@student.han.nl>
19218 * README: In the pupa-mkimage example use _chain instead of chain
19219 and ext2 instead of fat.
19220 * TODO: Replace ext2fs with jfs as an example. Add an item for
19221 adding journal playback for ext2fs.
19222 * conf/i386-pc.rmk (pupa_setup_SOURCES): Added fs/ext2.c.
19223 (pkgdata_MODULES): Added ext2.mod.
19224 (ext2_mod_SOURCES): New variable.
19225 (ext2_mod_CFLAGS): Likewise.
19226 * include/pupa/err.h (pupa_err_t): Added PUPA_ERR_SYMLINK_LOOP.
19227 * include/pupa/misc.h (pupa_strncpy): New prototype.
19228 (pupa_strcat): Likewise.
19229 (pupa_strncmp): Likewise.
19230 * kern/misc.c (pupa_strcat): Enable function.
19231 (pupa_strncpy): New function.
19232 (pupa_strncmp): Likewise.
19233 * fs/ext2.c: New file.
19235 * kern/disk.c (pupa_disk_read): Set pupa_errno to PUPA_ERR_NONE
19236 when the read failed before retrying.
19237 * util/i386/pc/biosdisk.c (_LARGEFILE_SOURCE): Removed.
19238 (_FILE_OFFSET_BITS): Likewise.
19239 * configure.ac: Added AC_SYS_LARGEFILE.
19241 2003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
19243 * genmk.rb (PModule#rule): Make sure to get only symbol names
19244 from the output of nm.
19245 Reported by Robert Millan <zeratul2@wanadoo.es>.
19247 2003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
19249 I forgot to check in these changes for a long time. This adds
19250 incomplete support for VGA console, and this is still very
19251 buggy. Also, a lot of consideration is required for I18N,
19252 UNICODE, and VGA font issues. Therefore, assume that this is
19253 such that "better than nothing".
19255 * font/manager.c: New file.
19256 * include/pupa/font.h: Likewise.
19257 * include/pupa/i386/pc/vga.h: Likewise.
19258 * term/i386/pc/vga.c: Likewise.
19259 * util/unifont2pff.rb: Likewise.
19261 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vga.h.
19262 (pkgdata_MODULES): Added vga.mod and font.mod.
19263 (vga_mod_SOURCES): New variables.
19264 (vga_mod_CFLAGS): Likewise.
19265 (font_mod_SOURCES): Likewise.
19266 (font_mod_CFLAGS): Likewise.
19268 * include/pupa/err.h (PUPA_ERR_BAD_FONT): New constant.
19270 * include/pupa/term.h: Include pupa/err.h.
19271 (struct pupa_term): Added init and fini.
19272 Changed the argument of putchar to pupa_uint32_t.
19274 * include/pupa/i386/pc/console.h: Include pupa/symbol.h.
19275 (pupa_console_real_putchar): New prototype.
19276 (pupa_console_putchar): Removed.
19277 (pupa_console_checkkey): Exported.
19278 (pupa_console_getkey): Likewise.
19280 * kern/misc.c (pupa_vsprintf): Add support for UNICODE
19283 * kern/term.c (pupa_term_set_current): Rewritten.
19284 (pupa_putchar): Likewise.
19285 (pupa_putcode): New function.
19287 * kern/i386/pc/startup.S (pupa_console_putchar): Renamed to ...
19288 (pupa_console_real_putchar): ... this.
19289 (pupa_vga_set_mode): New function.
19290 (pupa_vga_get_font): Likewise.
19292 * normal/command.c: Include pupa/term.h.
19293 (terminal_command): New function.
19294 (pupa_command_init): Register the command "terminal".
19296 * normal/menu.c (DISP_LEFT): Changed to a UNICODE value.
19297 (DISP_UP): Likewise.
19298 (DISP_RIGHT): Likewise.
19299 (DISP_DOWN): Likewise.
19300 (DISP_HLINE): Likewise.
19301 (DISP_VLINE): Likewise.
19302 (DISP_UL): Likewise.
19303 (DISP_UR): Likewise.
19304 (DISP_LL): Likewise.
19305 (DISP_LR): Likewise.
19307 * term/i386/pc/console.c (pupa_console_putchar): New function.
19309 2003-02-08 NIIBE Yutaka <gniibe@m17n.org>
19311 * util/resolve.c (pupa_util_resolve_dependencies): BUG
19312 FIX. Reverse the path_list.
19314 * include/pupa/normal.h: Export pupa_register_command and
19315 pupa_unregister_command.
19317 * hello/hello.c (pupa_cmd_hello): New module.
19318 * conf/i386-pc.rmk: Added hello.mod.
19320 2003-01-31 Yoshinori K. Okuji <okuji@enbug.org>
19322 * kern/i386/pc/lzo1x.S: New file.
19324 * util/i386/pc/pupa-mkimage.c: Include lzo1x.h.
19325 (compress_kernel): New variable.
19326 (generate_image): Heavily modified to support compressing a
19327 large part of the core image.
19329 * util/misc.c (pupa_util_read_image): Fix a file descriptor
19331 (pupa_util_load_image): New function.
19333 * kern/i386/pc/startup.S: Include pupa/machine/kernel.h.
19334 (pupa_compressed_size): New variable.
19335 (codestart): Enable Gate A20 here.
19336 Decompress the compressed part of the core image.
19337 Rearrange the code to put functions and variables which are
19338 required for initialization in the non-compressed part.
19341 * kern/i386/pc/init.c (pupa_machine_init): Don't enable Gate A20
19344 * include/pupa/util/misc.h (pupa_util_write_image): Declared.
19346 * include/pupa/i386/pc/kernel.h
19347 (PUPA_KERNEL_MACHINE_COMPRESSED_SIZE): New macro.
19348 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): Increased by 4.
19349 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
19350 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
19351 (PUPA_KERNEL_MACHINE_RAW_SIZE): New macro.
19353 * conf/i386-pc.rmk (pupa_mkimage_LDFLAGS): New variable.
19355 * genmk.rb (Image#rule): Put LDFLAGS at the end of a line.
19356 (Utility#rule): Likewise.
19358 * configure.ac: Check if LZO is available.
19360 2003-01-20 Yoshinori K. Okuji <okuji@enbug.org>
19362 * include/pupa/normal.h: New file.
19363 * include/pupa/setjmp.h: Likewise.
19364 * include/pupa/i386/setjmp.h: Likewise.
19365 * normal/cmdline.c: Likewise.
19366 * normal/command.c: Likewise.
19367 * normal/main.c: Likewise.
19368 * normal/menu.c: Likewise.
19369 * normal/i386/setjmp.S: Likewise.
19371 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Made global.
19372 (pupa_rescue_cmd_initrd): Likewise.
19374 * loader/i386/pc/chainloader.c (pupa_rescue_cmd_chainloader):
19377 * kern/i386/pc/startup.S (translation_table): New variable.
19378 (translate_keycode): New function.
19379 (pupa_console_getkey): Call translate_keycode.
19381 * kern/rescue.c (attempt_normal_mode): New function.
19382 (pupa_enter_rescue_mode): Attempt to execute the normal mode. If
19383 it failed, print a message.
19385 * kern/mm.c (pupa_real_malloc): Print more information when a
19386 free magic is broken.
19387 (pupa_free): If the first free header is not free actually, set
19390 * kern/main.c (pupa_load_normal_mode): Just load the module
19392 (pupa_main): Don't print the message
19393 "Entering into rescue mode..." here.
19395 * include/pupa/i386/pc/loader.h (pupa_rescue_cmd_initrd):
19397 (pupa_rescue_cmd_initrd): Likewise.
19398 (pupa_rescue_cmd_initrd): Likewise.
19400 * include/pupa/symbol.h (FUNCTION): Specify the type.
19401 (VARIABLE): Likewise.
19403 * include/pupa/err.h (pupa_err_t): Added
19404 PUPA_ERR_UNKNOWN_COMMAND.
19406 * include/pupa/dl.h (pupa_dl_set_prefix): Exported.
19407 (pupa_dl_get_prefix): Likewise.
19409 * conf/i386-pc.rmk (pkgdata_MODULES): Added normal.mod.
19410 Added _chain.mod and _linux.mod instead of chain.mod and
19412 (chain_mod_SOURCES): Renamed to ...
19413 (_chain_mod_SOURCES): ... this.
19414 (chain_mod_CFLAGS): Renamed to ...
19415 (_chain_mod_CFLAGS): ... this.
19416 (linux_mod_SOURCES): Renamed to ...
19417 (_linux_mod_SOURCES): ... this.
19418 (linux_mod_CFLAGS): Renamed to ...
19419 (_linux_mod_CFLAGS): ... this.
19420 (normal_mod_SOURCES): New variable.
19421 (normal_mod_CFLAGS): Likewise.
19422 (normal_mod_ASFLAGS): Likewise.
19424 2003-01-18 Yoshinori K. Okuji <okuji@enbug.org>
19426 * kern/rescue.c (pupa_rescue_cmd_rmmod): Call pupa_dl_unload, if
19429 * kern/dl.c (pupa_dl_ref): Refer depending modules
19431 (pupa_dl_unref): Unrefer depending modules recursively.
19432 Don't call pupa_dl_unload implicitly, because PUPA can crash if
19433 a module is unloaded before one depending on that module is
19435 (pupa_dl_unload): Unload depending modules explicitly,
19438 2003-01-17 Yoshinori K. Okuji <okuji@enbug.org>
19440 * include/pupa/i386/pc/linux.h: New file.
19441 * loader/i386/pc/linux.c: Likewise.
19443 * loader/i386/pc/chainloader.c (pupa_chainloader_boot_sector):
19445 (pupa_chainloader_unload): Return PUPA_ERR_NONE.
19446 (pupa_rescue_cmd_chainloader): Read the image to 0x7C00 instead
19447 of PUPA_CHAINLOADER_BOOT_SECTOR.
19449 * kern/i386/pc/startup.S: Include pupa/machine/linux.h.
19450 (pupa_linux_prot_size): New variable.
19451 (pupa_linux_tmp_addr): Likewise.
19452 (pupa_linux_real_addr): Likewise.
19453 (pupa_linux_boot_zimage): New function.
19454 (pupa_linux_boot_bzimage): Likewise.
19456 * kern/i386/pc/init.c (struct mem_region): New structure.
19457 (MAX_REGIONS): New macro.
19458 (mem_regions): New variable.
19459 (num_regions): Likewise.
19460 (pupa_os_area_addr): Likewise.
19461 (pupa_os_area_size): Likewise.
19462 (pupa_lower_mem): Likewise.
19463 (pupa_upper_mem): Likewise.
19464 (add_mem_region): New function.
19465 (compact_mem_regions): Likewise.
19466 (pupa_machine_init): Set PUPA_LOWER_MEM and PUPA_UPPER_MEM to
19467 the size of the conventional memory and that of so-called upper
19468 memory (before the first memory hole).
19469 Instead of adding each found region to free memory, use
19470 add_mem_region and add them after removing overlaps.
19471 Also, add only 1/4 of the upper memory to free memory. The rest
19472 is used for loading OS images. Maybe this is ad hoc, but this
19473 makes it much easier to relocate OS images when booting.
19475 * kern/rescue.c (pupa_rescue_cmd_module): Removed.
19476 (pupa_enter_rescue_mode): Don't register initrd and module.
19478 * kern/mm.c: Include pupa/dl.h.
19480 * kern/main.c: Include pupa/file.h and pupa/device.h.
19482 * kern/loader.c (pupa_loader_load_module_func): Removed.
19483 (pupa_loader_load_module): Likewise.
19485 * kern/dl.c (pupa_dl_load): Use the suffix ``.mod'' instead of
19488 * include/pupa/i386/pc/loader.h (pupa_linux_prot_size): Declared.
19489 (pupa_linux_tmp_addr): Likewise.
19490 (pupa_linux_real_addr): Likewise.
19491 (pupa_linux_boot_zimage): Likewise.
19492 (pupa_linux_boot_bzimage): Likewise.
19494 * include/pupa/i386/pc/init.h (pupa_lower_mem): Declared.
19495 (pupa_upper_mem): Likewise.
19496 (pupa_gate_a20): Don't export, because turning off Gate A20 in a
19497 module is too dangerous.
19499 * include/pupa/loader.h (pupa_os_area_addr): Declared.
19500 (pupa_os_area_size): Likewise.
19501 (pupa_loader_set): Remove the first argument. Loader doesn't
19502 manage modules or initrd any longer.
19503 (pupa_loader_load_module): Removed.
19505 * conf/i386-pc.rmk (pkgdata_MODULES): Added linux.mod.
19506 (linux_mod_SOURCES): New variable.
19507 (linux_mod_CFLAGS): Likewise.
19509 2003-01-07 Yoshinori K. Okuji <okuji@enbug.org>
19511 * util/i386/pc/pupa-setup.c (setup): Convert the endianness of
19512 the length of a blocklist correctly.
19514 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open) [__linux__]:
19515 Use ioctl only if the OS file is a block device.
19516 (pupa_util_biosdisk_open): Don't use ST.ST_BLOCKS, because it is
19517 not very useful for normal files.
19519 * kern/main.c (pupa_set_root_dev): New function.
19520 (pupa_load_normal_mode): Likewise.
19521 (pupa_main): Call those above.
19523 * include/pupa/types.h (pupa_swap_bytes16): Cast the result to
19526 * include/pupa/kernel.h (pupa_enter_normal_mode): Removed.
19528 2003-01-06 Yoshinori K. Okuji <okuji@enbug.org>
19530 * util/i386/pc/pupa-setup.c: Include pupa/machine/kernel.h.
19531 (setup): Configure the installed partition information and the
19534 * loader/i386/pc/chainloader.c (my_mod): New variable.
19535 (pupa_chainloader_unload): New function.
19536 (pupa_rescue_cmd_chainloader): Refer itself.
19537 (PUPA_MOD_INIT): Save its own module in MY_MOD.
19539 * kern/i386/pc/startup.S (install_partition): Removed.
19540 (version_string): Likewise.
19541 (config_file): Likewise.
19542 (pupa_install_dos_part): New variable.
19543 (pupa_install_bsd_part): Likewise.
19544 (pupa_prefix): Likewise.
19545 (pupa_chainloader_real_boot): Call pupa_dl_unload_all.
19547 * kern/i386/pc/init.c: Include pupa/machine/kernel.h, pupa/dl.h
19549 (make_install_device): New function.
19550 (pupa_machine_init): Set the dl prefix.
19552 * kern/rescue.c: Include pupa/rescue.h and pupa/dl.h.
19553 (buf): Renamed to ...
19554 (linebuf): ... this.
19555 (pupa_rescue_cmd_prefix): New function.
19556 (pupa_rescue_cmd_insmod): Likewise.
19557 (pupa_rescue_cmd_rmmod): Likewise.
19558 (pupa_rescue_cmd_lsmod): Likewise.
19559 (pupa_enter_rescue_mode): Register new commands: prefix, insmod,
19562 * kern/mm.c (pupa_memalign): If failed even after invalidating
19563 disk caches, unload unneeded modules and retry.
19565 * kern/misc.c (pupa_memmove): New function.
19566 (pupa_memcpy): Removed.
19567 (pupa_strcpy): New function.
19568 (pupa_itoa): Made static.
19570 * kern/dl.c (pupa_dl_iterate): New function.
19571 (pupa_dl_ref): Likewise.
19572 (pupa_dl_unref): Likewise.
19573 (pupa_dl_unload): Return if succeeded or not.
19574 (pupa_dl_unload_unneeded): New function.
19575 (pupa_dl_unload_all): Likewise.
19576 (pupa_dl_init): Renamed to ...
19577 (pupa_dl_set_prefix): ... this.
19578 (pupa_dl_get_prefix): New function.
19580 * include/pupa/i386/pc/kernel.h: Include pupa/types.h.
19581 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): New macro.
19582 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
19583 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
19584 (pupa_install_dos_part): Declared.
19585 (pupa_install_bsd_part): Likewise.
19586 (pupa_prefix): Likewise.
19587 (pupa_boot_drive): Likewise.
19589 * include/pupa/types.h: Fix a typo.
19591 * include/pupa/misc.h (pupa_memcpy): New macro. Just an alias to
19593 (pupa_memmove): Declared.
19594 (pupa_strcpy): Likewise.
19596 * include/pupa/dl.h (PUPA_MOD_INIT): Change the prototype. Now
19597 pupa_mod_init takes one argument, its own module.
19598 (pupa_dl_unload_unneeded): Declared.
19599 (pupa_dl_unload_all): Likewise.
19600 (pupa_dl_ref): Likewise.
19601 (pupa_dl_unref): Likewise.
19602 (pupa_dl_iterate): Likewise.
19603 (pupa_dl_init): Renamed to ...
19604 (pupa_dl_set_prefix): ... this.
19605 (pupa_dl_get_prefix): Declared.
19607 * fs/fat.c [!PUPA_UTIL] (my_mod): New variable.
19608 (pupa_fat_dir) [!PUPA_UTIL]: Prevent the fat module from being
19610 (pupa_fat_open) [!PUPA_UTIL]: Refer itself if succeeded.
19611 (pupa_fat_close) [!PUPA_UTIL]: Unrefer itself.
19613 * configure.ac (tmp_CFLAGS): Added -Wshadow, -Wpointer-arith,
19614 -Wmissing-prototypes, -Wundef and -Wstrict-prototypes.
19616 2003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
19618 * util/i386/pc/pupa-setup.c (setup): Define the internal
19619 function find_first_partition_start at the top level, because GCC
19620 3.0.x cannot compile internal functions in deeper scopes
19622 (find_root_device): Use lstat instead of stat.
19623 Don't follow symbolic links.
19624 Fix the path-constructing code.
19626 * util/i386/pc/biosdisk.c [__linux__] (BLKFLSBUF): New macro.
19627 (pupa_util_biosdisk_open) [__linux__]: Get the size of a device
19628 by a BLKGETSIZE ioctl first, because block devices don't fill
19629 the member st_mode of the structure stat on Linux.
19630 [__linux__] (linux_find_partition): Use a temporary buffer
19631 REAL_DEV for the working space. Copy it to DEV before returning.
19632 (open_device) [__linux__]: Call ioctl with BLKFLSBUF to make the
19633 buffer cache consistent.
19634 (get_os_disk) [__linux__]: Use the length 5 instead of 4 for
19635 strncmp. The previous value was merely wrong.
19636 (pupa_util_biosdisk_get_pupa_dev): Use stat instead of lstat.
19638 * fs/fat.c (pupa_fat_read_data): Shift 4 instead of 12 when the
19639 FAT size is 12. The previous value was merely wrong.
19641 * kern/main.c (pupa_main): Don't split the starting message from
19644 * kern/term.c (pupa_putchar): Put CR after LF instead of before
19645 LF, because BIOS goes crazy about character attributes in this
19648 2003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
19650 * include/i386/pc/util/biosdisk.h: New file.
19651 * util/i386/pc/biosdisk.c: Likewise.
19652 * util/i386/pc/pupa-setup.c: Likewise.
19654 * Makefile.in (INCLUDE_DISTFILES): Added
19655 include/pupa/i386/pc/util/biosdisk.h.
19656 (UTIL_DISTFILES): Added biosdisk.c and pupa-setup.c under the
19657 directory util/i386/pc.
19658 (install-local): Added a rule for sbin_UTILITIES.
19659 (uninstall): Likewise.
19661 * util/i386/pc/pupa-mkimage.c (usage): Fix a typo in the doc.
19663 * util/misc.c (xrealloc): New function.
19664 (pupa_malloc): Likewise.
19665 (pupa_free): Likewise.
19666 (pupa_realloc): Likewise.
19667 (pupa_stop): Likewise.
19668 (pupa_putchar): Likewise.
19670 * kern/disk.c (pupa_disk_read): Prevent L from underflowing.
19672 * include/pupa/util/misc.h (xrealloc): Declared.
19674 * include/pupa/i386/pc/boot.h (PUPA_BOOT_MACHINE_BPB_START): New
19676 (PUPA_BOOT_MACHINE_BPBEND): Renamed to ...
19677 (PUPA_BOOT_MACHINE_BPB_END): ... this.
19679 * include/pupa/fs.h [PUPA_UTIL] (pupa_fat_init): Declared.
19680 [PUPA_UTIL] (pupa_fat_fini): Likewise.
19682 * fs/fat.c [PUPA_UTIL] (pupa_fat_init): Defined. Maybe a better
19683 way should be implemented.
19684 [PUPA_UTIL] (pupa_fat_fini): Likewise.
19686 * disk/i386/pc/biosdisk.c (pupa_biosdisk_call_hook): Increase
19687 the size of NAME for safety.
19688 (pupa_biosdisk_iterate): Search hard disks to 0x90 instead of
19691 * conf/i386-pc.rmk (sbin_UTILITIES): New variable.
19692 (pupa_setup_SOURCES): Likewise.
19694 * genmk.rb (Utility#rule): Add $(BUILD_CFLAGS) into the rules.
19696 2002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
19698 * kern/i386/pc/startup.S (push_get_mmap_entry): Revert to a
19699 bunch of pushl's from pusha, because this destroys the return
19702 2002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
19704 Use -mrtd and -mregparm=3 to reduce the generated code sizes.
19705 This means that any missing prototypes could be fatal. Also, you
19706 must take care when writing assembly code. See the comments at
19707 the beginning of startup.S, for more details.
19709 * kern/i386/pc/startup.S (pupa_halt): Modified for the new
19710 compilation mechanism.
19711 (pupa_chainloader_real_boot): Likewise.
19712 (pupa_biosdisk_rw_int13_extensions): Likewise.
19713 (pupa_biosdisk_rw_standard): Likewise.
19714 (pupa_biosdisk_check_int13_extensions): Likewise.
19715 (pupa_biosdisk_get_diskinfo_int13_extensions): Likewise.
19716 (pupa_biosdisk_get_diskinfo_standard): Likewise.
19717 (pupa_get_memsize): Likewise.
19718 (pupa_get_mmap_entry): Likewise.
19719 (pupa_console_putchar): Likewise.
19720 (pupa_console_setcursor): Likewise.
19721 (pupa_getrtsecs): Use pushl instead of push.
19723 * kern/i386/pc/init.c (pupa_machine_init): Use the scratch
19724 memory instead of the stack for a mmap entry, because some
19725 BIOSes may ignore the maximum size and overflow.
19727 * conf/i386-pc.rmk (COMMON_CFLAGS): Added -mrtd and -mregparm=3.
19729 * genmk.rb (PModule#rule): Compile automatically generated
19730 sources with module-specific CFLAGS as well as other sources.
19732 2002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
19734 * configure.ac: Check ld.
19735 Replace CFLAGS and CPPFLAGS with BUILD_CFLAGS and BUILD_CPPFLAGS
19736 respectively, before checking endianness and sizes.
19738 * Makefile.in (LD): New variable.
19740 2002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
19742 * Makefile.in (BUILD_CC): CC -> BUILD_CC.
19744 2002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
19746 * Changelog: New file.