]> git.proxmox.com Git - grub2.git/blob - ChangeLog
2009-07-07 Pavel Roskin <proski@gnu.org>
[grub2.git] / ChangeLog
1 2009-07-07 Pavel Roskin <proski@gnu.org>
2
3 * lib/arg.c (find_long_option): Remove.
4 (find_long): Add `len' argument, make `s' const char *.
5 (grub_arg_parse): Parse long options in place, not in a
6 temporary buffer.
7
8 2009-07-06 Pavel Roskin <proski@gnu.org>
9
10 * commands/search.c (search_fs): Fix potential NULL pointer
11 dereference.
12
13 * commands/search.c (search_fs): Replace QUID macro with quid_fn
14 function pointer.
15
16 2009-07-06 Daniel Mierswa <impulze@impulze.org>
17
18 * commands/search.c (search_fs): Use grub_strcasecmp() for UUID
19 comparison.
20
21 2009-07-05 Pavel Roskin <proski@gnu.org>
22
23 * include/grub/i386/linux.h (struct linux_kernel_params):
24 Restore padding3, it's still needed.
25
26 * util/grub.d/10_freebsd.in: Fix spelling of `device.hints' on
27 FreeBSD.
28 * util/osdetect.lua: Likewise.
29
30 2009-07-05 Bean <bean123ch@gmail.com>
31
32 * conf/common.rmk (lua_mode_SOURCES): Add script/lua/lstrlib.c.
33
34 * script/lua/grub_lib.c (grub_lua_run): Check input parameter.
35 (grub_lua_getenv): Likewise.
36 (grub_lua_setenv): Likewise.
37 (save_errno): New function.
38 (push_result): Likewise.
39 (grub_lua_enum_device): Likewise.
40 (grub_lua_enum_file): Likewise.
41 (grub_lua_file_open): Likewise.
42 (grub_lua_file_close): Likewise.
43 (grub_lua_file_seek): Likewise.
44 (grub_lua_file_read): Likewise.
45 (grub_lua_file_getline): Likewise.
46 (grub_lua_file_getsize): Likewise.
47 (grub_lua_file_getpos): Likewise.
48 (grub_lua_file_eof): Likewise.
49 (grub_lua_file_exist): Likewise.
50 (grub_lua_add_menu): Likewise.
51
52 * script/lua/grub_lua.h (isupper): New inline function.
53 (islower): Likewise.
54 (ispunct): Likewise.
55 (isxdigit): Likewise.
56 (strcspn): Change to normal function.
57 (strpbkr): New function declaration.
58 (memchr): Likewise.
59
60 * script/lua/grub_main.c (scan_str): New function.
61 (strcspn): Likewise.
62 (strpbrk): Likewise.
63 (memchr): Likewise.
64
65 * script/lua/linit.c (lualibs): Enable the string library.
66
67 * util/osdetect.lua: New file.
68
69 2009-07-04 Robert Millan <rmh.grub@aybabtu.com>
70
71 * include/grub/i386/linux.h (struct linux_kernel_params): Add
72 `capabilities' member.
73
74 2009-07-02 Pavel Roskin <proski@gnu.org>
75
76 * genparttoollist.sh: Add missing newline at the end.
77
78 2009-07-01 Pavel Roskin <proski@gnu.org>
79
80 * kern/x86_64/efi/callwrap.S: Add missing newline at the end.
81
82 * util/hostdisk.c (open_device): Remove `const' from
83 `sysctl_size', as sysctlbyname() can change it (in this case it
84 doesn't actually happen).
85
86 * include/grub/types.h: Define GRUB_LONG_MAX and GRUB_LONG_MIN
87 using signed long int constants.
88
89 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): Make `p'
90 constant to avoid a warning on FreeBSD.
91
92 * util/hostdisk.c (device_is_wholedisk): Compile only on systems
93 where it's needed.
94
95 * Makefile.in: Install include/grub/machine symlink.
96
97 * Makefile.in: When installing symlinks, use "cp -fR", which
98 works on FreeBSD and MacOSX.
99 From Yves Blusseau <cl7m42e02@sneakemail.com>
100
101 * kern/dl.c (grub_dl_resolve_symbol): Make static.
102 * include/grub/dl.h: Remove grub_dl_resolve_symbol().
103
104 * util/misc.c: Move grub_reboot() and grub_halt() ...
105 * util/grub-emu.c: ... here. Make main_env static.
106 * include/grub/util/misc.h: Remove main_env.
107
108 * kern/mm.c: Use correct format to print size_t.
109
110 * include/grub/elf.h: Define Elf_Sword and Elf_Xword.
111 * kern/i386/dl.c: Use ELF symbols without "32" or "64".
112 * kern/powerpc/dl.c: Likewise.
113 * kern/sparc64/dl.c: Likewise.
114 * kern/x86_64/dl.c: Likewise.
115
116 2009-07-01 Robert Millan <rmh.grub@aybabtu.com>
117
118 Fix grub-emu build on sparc64-ieee1275.
119
120 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Syncronize with ...
121 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): ... this.
122
123 2009-07-01 Robert Millan <rmh.grub@aybabtu.com>
124
125 * util/misc.c: Include `<setjmp.h>' and `<grub/machine/machine.h>'.
126 (grub_reboot, grub_halt): New functions.
127
128 * util/i386/pc/misc.c: Delete. Update all users.
129 * util/sparc64/ieee1275/misc.c: Likewise.
130 * util/powerpc/ieee1275/misc.c: Likewise.
131
132 2009-07-01 Robert Millan <rmh.grub@aybabtu.com>
133
134 * conf/i386.rmk (setjmp_mod_SOURCES)
135 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): Move to ...
136 * conf/common.rmk (setjmp_mod_SOURCES)
137 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): ... here, and modify
138 to use $(target_cpu).
139 * conf/x86_64-efi.rmk (setjmp_mod_SOURCES)
140 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): Remove.
141 * conf/powerpc-ieee1275.rmk: Likewise.
142 * conf/sparc64-ieee1275.rmk: Likewise.
143
144 * conf/i386-pc.rmk (kernel_img_SOURCES): Use
145 $(target_cpu) for kern/$(target_cpu)/dl.c.
146 * conf/i386-efi.rmk: Likewise.
147 * conf/i386-ieee1275.rmk: Likewise.
148 * conf/x86_64-efi.rmk: Likewise.
149 * conf/i386-coreboot.rmk: Likewise.
150 * conf/powerpc-ieee1275.rmk (kernel_img_SOURCES): Use
151 $(target_cpu) for kern/$(target_cpu)/dl.c and for
152 kern/$(target_cpu)/cache.S.
153 * conf/sparc64-ieee1275.rmk: Likewise.
154
155 2009-07-01 Robert Millan <rmh.grub@aybabtu.com>
156
157 * include/grub/i386/linux.h (linux_kernel_params): Change `mmap_size'
158 type to `grub_uint8_t', and adjust `padding9' accordingly.
159
160 2009-06-29 Robert Millan <rmh.grub@aybabtu.com>
161
162 * include/grub/i386/linux.h (GRUB_VIDEO_TYPE_TEXT): New macro.
163
164 * loader/i386/linux.c [__i386__] (grub_linux_boot): Simplify inline
165 assembly in final jump, using register constraints.
166
167 (grub_linux_boot): For text mode, initialize `have_vga' using
168 GRUB_VIDEO_TYPE_TEXT rather than 0 (this changes its value to 1).
169
170 Initialize `video_cursor_x' and `video_cursor_y' as late as possible,
171 right before the final jump.
172
173 Set `video_mode' to 0x3.
174
175 Document initialization of `video_page', `video_mode' and
176 `video_ega_bx'.
177
178 2009-06-29 Robert Millan <rmh.grub@aybabtu.com>
179
180 * include/grub/i386/linux.h (GRUB_LINUX_FLAG_QUIET): New macro.
181 * loader/i386/linux.c (grub_cmd_linux): Recognize "quiet" option,
182 and set GRUB_LINUX_FLAG_QUIET appropiately.
183
184 2009-06-29 Robert Millan <rmh.grub@aybabtu.com>
185
186 Fix build on Debian / sparc.
187
188 * configure.ac: Recognize `sparc' target_cpu (as sparc64).
189
190 2009-06-28 Pavel Roskin <proski@gnu.org>
191
192 * kern/i386/qemu/mmap.c (grub_machine_mmap_iterate): Use cast to
193 fix a warning.
194
195 * util/grub.d/10_linux.in: Match SUSE style initrd names.
196
197 2009-06-27 Robert Millan <rmh.grub@aybabtu.com>
198
199 * loader/i386/linux.c (grub_linux_boot): Fix uninitialized use of
200 `err'.
201
202 2009-06-27 Robert Millan <rmh.grub@aybabtu.com>
203
204 Revert r2338.
205
206 * loader/i386/linux.c (grub_cmd_linux): Don't call grub_error when
207 file can't be opened. grub_file_open() is already supposed to set
208 grub_errno / grub_errmsg appropiately.
209 * loader/i386/pc/linux.c (grub_cmd_linux): Likewise.
210
211 2009-06-27 Pavel Roskin <proski@gnu.org>
212 2009-06-27 Robert Millan <rmh.grub@aybabtu.com>
213
214 * include/grub/dl.h: Include grub/elf.h.
215 (struct grub_dl): Add symtab field.
216 * kern/dl.c [GRUB_MACHINE_QEMU]: Define
217 GRUB_MODULES_MACHINE_READONLY.
218 (grub_dl_resolve_symbols): Populate mod->symtab, making a copy
219 of the header for read-only modules.
220 (grub_dl_unload): Free mod->symtab for read-only modules.
221 * kern/i386/dl.c: Use mod->symtab.
222 * kern/powerpc/dl.c: Likewise.
223 * kern/sparc64/dl.c: Likewise.
224 * kern/x86_64/dl.c: Likewise.
225
226 * conf/i386-qemu.rmk: New file.
227 * kern/i386/qemu/startup.S: Likewise.
228 * kern/i386/qemu/mmap.c: Likewise.
229 * boot/i386/qemu/boot.S: Likewise.
230 * include/grub/i386/qemu/time.h: Likewise.
231 * include/grub/i386/qemu/serial.h: Likewise.
232 * include/grub/i386/qemu/kernel.h: Likewise.
233 * include/grub/i386/qemu/console.h: Likewise.
234 * include/grub/i386/qemu/boot.h: Likewise.
235 * include/grub/i386/qemu/init.h: Likewise.
236 * include/grub/i386/qemu/machine.h: Likewise.
237 * include/grub/i386/qemu/loader.h: Likewise.
238 * include/grub/i386/qemu/memory.h: Likewise.
239
240 * conf/i386-coreboot.rmk (GRUB_BOOT_MACHINE_LINK_ADDR)
241 (GRUB_KERNEL_MACHINE_LINK_ADDR): New variables.
242 [qemu] (pkglib_IMAGES): Add `boot.img'.
243 [qemu] (boot_img_SOURCES, boot_img_ASFLAGS, boot_img_LDFLAGS)
244 [qemu] (boot_img_FORMAT): New variables.
245 [qemu] (bin_UTILITIES): Add `grub-mkimage'.
246 [qemu] (grub_mkimage_SOURCES, grub_mkimage_CFLAGS): New variables.
247 [qemu] (kernel_img_SOURCES, kernel_img_HEADERS, kernel_img_CFLAGS)
248 [qemu] (kernel_img_ASFLAGS, kernel_img_LDFLAGS)
249 [qemu] (kernel_img_FORMAT): New variables.
250
251 * configure.ac: Recognise `i386-qemu'.
252
253 * util/i386/pc/grub-mkimage.c (compress_kernel): Add dummy variant
254 (for no compression).
255 [GRUB_MACHINE_QEMU] (generate_image): Misc adjustments to produce
256 a valid i386 ROM image. Make `GRUB_KERNEL_MACHINE_COMPRESSED_SIZE',
257 `GRUB_KERNEL_MACHINE_INSTALL_DOS_PART' and
258 `GRUB_KERNEL_MACHINE_INSTALL_BSD_PART' optional features (with
259 ifdefs).
260
261 2009-06-27 Pavel Roskin <proski@gnu.org>
262
263 * efiemu/prepare.c: Eliminate TYPE macro, it makes code hard to
264 read.
265 * efiemu/prepare32.c: Likewise.
266 * efiemu/prepare64.c: Likewise.
267
268 2009-06-26 Pavel Roskin <proski@gnu.org>
269
270 * include/grub/types.h: Define GRUB_TARGET_WORDSIZE.
271 * include/grub/elf.h: Define symbols without "32" or "64" based
272 on GRUB_TARGET_WORDSIZE.
273 * include/grub/multiboot2.h: Use GRUB_TARGET_WORDSIZE.
274 * efiemu/loadcore32.c: Redefine GRUB_TARGET_WORDSIZE, remove own
275 ELF definitions.
276 * efiemu/loadcore64.c: Likewise.
277 * loader/i386/bsd32.c: Likewise.
278 * loader/i386/bsd64.c: Likewise.
279 * kern/dl.c: Remove own ELF definitions.
280 * util/i386/efi/grub-mkimage.c: Likewise.
281
282 2009-06-23 Robert Millan <rmh.grub@aybabtu.com>
283
284 * kern/i386/pc/startup.S (real_to_prot): Access `gdtdesc' using
285 segment 0x0 unconditionally, because the reference generated by
286 GAS is an absolute address.
287
288 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
289
290 * include/grub/i386/kernel.h: Include `<grub/machine/machine.h>'.
291 [! GRUB_MACHINE_IEEE1275]: Set `GRUB_MOD_ALIGN' to 0x1.
292
293 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
294
295 * commands/search.c (grub_cmd_search): Macroify hardcoded args[]
296 indexes. Check for -f explicitly.
297 (search_file): Improve error message.
298 (GRUB_MOD_INIT(search)): Add missing `-n' to help output.
299
300 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
301
302 * conf/i386-pc.rmk (GRUB_MEMORY_MACHINE_LINK_ADDR): Rename to ...
303 (GRUB_KERNEL_MACHINE_LINK_ADDR): ... this. Update all users.
304
305 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
306
307 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/misc.S'.
308 * conf/i386-ieee1275.rmk: Likewise.
309 * conf/i386-coreboot.rmk: Likewise.
310
311 * kern/i386/pc/startup.S (grub_stop): Remove function.
312 * kern/i386/ieee1275/startup.S: Likewise.
313 * kern/i386/coreboot/startup.S: Likewise.
314 * kern/i386/misc.S (grub_stop): New function.
315
316 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
317
318 * kern/i386/pc/startup.S (real_to_prot): Move from here ...
319 * kern/i386/realmode.S (real_to_prot): ... to here.
320
321 2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
322
323 * conf/i386-ieee1275.rmk (pkglib_PROGRAMS): Replace `kernel.elf'
324 with `kernel.img'.
325 (kernel_elf_SOURCES): Rename to ...
326 (kernel_img_SOURCES): ... this.
327 (kernel_elf_HEADERS): Rename to ...
328 (kernel_img_HEADERS): ... this. Update all users.
329 (kernel_elf_ASFLAGS): Rename to ...
330 (kernel_img_ASFLAGS): ... this.
331 (kernel_elf_CFLAGS): Rename to ...
332 (kernel_img_CFLAGS): ... this.
333 (kernel_elf_LDFLAGS): Rename to ...
334 (kernel_img_LDFLAGS): ... this.
335 * conf/i386-coreboot.rmk: Likewise.
336 * conf/powerpc-ieee1275.rmk: Likewise.
337
338 * util/elf/grub-mkimage.c (add_segments): Replace "kernel.elf"
339 with "kernel.img".
340
341 2009-06-21 Pavel Roskin <proski@gnu.org>
342
343 * loader/powerpc/ieee1275/linux.c (offset_phdr): Fix prototypes
344 to match nested functions.
345 * loader/sparc64/ieee1275/linux.c: Likewise.
346
347 * conf/i386-ieee1275.rmk: Define kernel_elf_ASFLAGS.
348
349 2009-06-21 Robert Millan <rmh.grub@aybabtu.com>
350
351 * configure.ac: Enable `END_SYMBOL' / `BSS_START_SYMBOL' test on
352 all i386 platforms.
353
354 2009-06-21 Robert Millan <rmh.grub@aybabtu.com>
355
356 Fix asm file handling on ELF, and remove workarounds.
357
358 * genmk.rb (class Programs): Detect assembly files, and set ASFLAGS
359 and -DASM_FILE=1 appropiately (copied from `class Images' stanza).
360 * kern/i386/ieee1275/startup.S (ASM_FILE): Remove macro.
361 * kern/i386/coreboot/startup.S (ASM_FILE): Likewise.
362
363 2009-06-21 Vladimir Serbinenko <phcoder@gmail.com>
364
365 Load BSD ELF modules
366
367 * conf/i386-pc.rmk (bsd_mod_SOURCES): Add loader/i386/bsd32.c
368 and loader/i386/bsd64.c
369 * include/grub/i386/bsd.h (FREEBSD_MODTYPE_MODULE): Remove
370 (FREEBSD_MODTYPE_ELF_MODULE): New definition
371 (FREEBSD_MODTYPE_ELF_MODULE_OBJ): Likewise
372 (grub_freebsd_load_elfmodule32): New declaration
373 (grub_freebsd_load_elfmoduleobj64): Likewise
374 (grub_freebsd_load_elf_meta32): Likewise
375 (grub_freebsd_load_elf_meta64): Likewise
376 (grub_freebsd_add_meta): Likewise
377 (grub_freebsd_add_meta_module): Likewise
378 * loader/i386/bsd.c (grub_freebsd_add_meta): Make global
379 (grub_freebsd_add_meta_module): Likewise and move module-specific
380 parts to grub_cmd_freebsd and grub_cmd_freebsd_module
381 (grub_cmd_freebsd): Add elf-kernel specific parts
382 based on grub_freebsd_add_meta_module
383 (grub_cmd_freebsd_module): Add type parsing moved from
384 grub_freebsd_add_meta_module
385 (grub_cmd_freebsd_module_elf): New function
386 (cmd_freebsd_module_elf): New variable
387 (GRUB_MOD_INIT): Register freebsd_module_elf
388 * loader/i386/bsd32.c: New file
389 * loader/i386/bsd64.c: Likewise
390 * loader/i386/bsdXX.c: Likewise
391 * kern/elf.c (grub_elf32_load): Let hook decide which pheaders to load
392 (grub_elf64_load): Likewise
393 * include/grub/elfload.h (grub_elf32_load_hook_t): New parameter do_load
394 All users updated
395 (grub_elf64_load_hook_t): Likewise
396
397 2009-06-21 Colin Watson <cjwatson@ubuntu.com>
398
399 * util/grub-mkconfig.in (GRUB_DISABLE_LINUX_RECOVERY): Export
400 variable.
401 * util/grub.d/10_linux.in: If GRUB_DISABLE_LINUX_RECOVERY is true,
402 don't write a menu entry for recovery mode.
403
404 2009-06-20 Robert Millan <rmh.grub@aybabtu.com>
405
406 * util/i386/pc/grub-mkimage.c (main): Oops, free `output' only
407 after it's no longer needed.
408
409 2009-06-20 Robert Millan <rmh.grub@aybabtu.com>
410
411 * include/grub/i386/loader.h (grub_linux_prot_size)
412 (grub_linux_tmp_addr, grub_linux_real_addr)
413 (grub_linux_is_bzimage, grub_linux16_boot): Declare only on
414 GRUB_MACHINE_PCBIOS.
415 * util/i386/pc/grub-mkimage.c (compress_kernel): Move
416 common grub_util_info() call to ...
417 (generate_image): ... here.
418 Fix use of uninitialized memory, comparison of signed with
419 unsigned integers and memory leak.
420 Remove bogus module address message.
421
422 2009-06-20 Vladimir Serbinenko <phcoder@gmail.com>
423
424 * disk/mdraid_linux.c (GRUB_MOD_FINI): use grub_raid_unregister and not
425 grub_raid_register
426 * disk/dmraid_nvidia.c (GRUB_MOD_FINI): likewise
427
428 2009-06-19 Pavel Roskin <proski@gnu.org>
429
430 * configure.ac: Remove stray AC_MSG_CHECKING.
431
432 2009-06-19 Vladimir Serbinenko <phcoder@gmail.com>
433
434 * disk/scsi.c (grub_scsi_open): use continue instead of big if
435
436 2009-06-18 Pavel Roskin <proski@gnu.org>
437
438 * conf/common.rmk: Add fs_file.mod.
439 * disk/fs_file.c: New file.
440 * include/grub/disk.h (enum grub_disk_dev_id): Add
441 GRUB_DISK_DEVICE_FILE_ID.
442
443 2009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
444
445 Fix build with Apple's toolchain. Part 2
446
447 * aclocal.m4 (grub_PROG_TARGET_CC): add missing prototype for main and
448 a fake start
449
450 2009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
451
452 Fix build with Apple's toolchain. Part 1
453
454 * commands/i386/pc/drivemap_int13h.S: use assembly-time constants
455 for long calls
456 * configure.ac: remove a leftover AC_MSG_RESULT
457 (CFLAGS): don't add -Wl,--defsym,___main=0x8100 when building with
458 Apple's toolchain
459
460 2009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
461
462 Fix warnings
463
464 * fs/ntfscomp.c (decomp_get16): initialize c1 and c2
465 (decomp_block): initialize ch
466 use grub_memcpy instead of memcpy
467
468 2009-06-17 Pavel Roskin <proski@gnu.org>
469
470 * include/grub/i386/coreboot/console.h: Don't use the i386-pc
471 version, use declarations needed to use vga_text as the startup
472 console.
473
474 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Remove
475 term/i386/pc/at_keyboard.c, it doesn't need to be compiled into
476 the kernel.
477 * kern/i386/coreboot/init.c: Don't call grub_at_keyboard_init()
478 and grub_at_keyboard_fini(), it's done on module load and
479 unload.
480
481 2009-06-17 Felix Zielcke <fzielcke@z-51.de>
482
483 * loader/i386/linux.c (grub_cmd_linux): Set grub_error if the
484 file can't be found.
485 * loader/i386/pc/linux.c (grub_cmd_linux): Likewise.
486
487 2009-06-17 Vladimir Serbinenko <phcoder@gmail.com>
488
489 Fix newline handling
490
491 * include/grub/script_sh.h (grub_lexer_param): new field was_newline
492 * script/sh/lexer.c (grub_script_lexer_init): initialize was_newline
493 (grub_script_yylex): don't segfault on unterminated script
494 newline terminates command and variable
495
496 2009-06-17 Vladimir Serbinenko <phcoder@gmail.com>
497
498 avoid double grub_adjust_range call. Bug reported by David Simner
499
500 * kern/disk.c (grub_disk_write): change to raw disk access before
501 calling disk_read
502
503 2009-06-17 Colin Watson <cjwatson@ubuntu.com>
504
505 * util/elf/grub-mkimage.c (usage): Prefix each option line with two
506 spaces, for the benefit of help2man.
507 * util/i386/efi/grub-mkimage.c (usage): Likewise.
508
509 2009-06-16 Pavel Roskin <proski@gnu.org>
510
511 * kern/i386/halt.c: Include grub/machine/init.h.
512 * kern/i386/reboot.c: Include grub/cpu/reboot.h.
513
514 2009-06-16 Felix Zielcke <fzielcke@z-51.de>
515
516 * util/grub.d/30_os-prober.in: Use ${root} in the generated
517 drivemap menuentry.
518
519 2009-06-16 James Jarvis <James.Jarvis@ed.ac.uk>
520
521 * commands/help.c GRUB_MOD_INIT(echo): Fix the help output of
522 `echo' command.
523
524 2009-06-16 Pavel Roskin <proski@gnu.org>
525
526 * boot/i386/pc/boot.S: Remove root_drive. Assert offset of
527 boot_drive_check by using GRUB_BOOT_MACHINE_DRIVE_CHECK. Don't
528 save %dx, we only need %dl and we never change it.
529 * boot/i386/pc/cdboot.S: Don't set the root drive.
530 * boot/i386/pc/pxeboot.S: Likewise.
531 * include/grub/i386/pc/boot.h: Remove
532 GRUB_BOOT_MACHINE_ROOT_DRIVE, adjust
533 GRUB_BOOT_MACHINE_DRIVE_CHECK.
534 * include/grub/i386/pc/kernel.h: Remove grub_root_drive.
535 * kern/i386/pc/init.c (make_install_device): Remove references
536 to grub_root_drive.
537 * kern/i386/pc/startup.S: Likewise.
538 * util/i386/pc/grub-setup.c (setup): Don't set root_drive.
539
540 2009-06-16 Vladimir Serbinenko <phcoder@gmail.com>
541
542 xnu_uuid command
543
544 * commands/xnu_uuid.c: new file
545 * conf/common.rmk (pkglib_MODULES): add xnu_uuid.mod
546 (xnu_uuid_mod_SOURCES): new variable
547 (xnu_uuid_mod_CFLAGS): likewise
548 (xnu_uuid_mod_LDFLAGS): likewise
549 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/probe.c
550 * conf/i386-ieee1275.rmk: likewise
551 * conf/i386-pc.rmk: likewise
552 * conf/powerpc-ieee1275.rmk: likewise
553 * conf/sparc64-ieee1275.rmk: likewise
554 * util/grub.d/30_os-prober.in: use UUID for Mac OS X/Darwin
555
556 2009-06-16 Pavel Roskin <proski@gnu.org>
557
558 * configure.ac: Avoid '==' in test command, it's not portable.
559
560 2009-06-16 Vladimir Serbinenko <phcoder@gmail.com>
561
562 Probe command
563
564 * commands/probe.c: new file
565 * conf/common.rmk (pkglib_MODULES): add probe.mod
566 (probe_mod_SOURCES): new variable
567 (probe_mod_CFLAGS): likewise
568 (probe_mod_LDFLAGS): likewise
569 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/probe.c
570 * conf/i386-ieee1275.rmk: likewise
571 * conf/i386-pc.rmk: likewise
572 * conf/powerpc-ieee1275.rmk: likewise
573 * conf/sparc64-ieee1275.rmk: likewise
574
575 2009-06-15 Vladimir Serbinenko <phcoder@gmail.com>
576
577 Fix handling of string like \"hello\" and "a
578 b"
579
580 * script/sh/lexer.c (check_textstate): accept GRUB_PARSER_STATE_ESC
581 (grub_script_yylex): fix parsing of quoting, escaping and newline
582
583 2009-06-13 Vladimir Serbinenko <phcoder@gmail.com>
584
585 * loader/i386/multiboot.c (grub_multiboot_get_bootdev): fix partition
586 handling
587
588 2009-06-13 Jun Inoue <jun.lambda@gmail.com>
589
590 * util/grub-mkconfig.in: Fix parsing of --output option.
591
592 2009-06-12 Pavel Roskin <proski@gnu.org>
593
594 * Makefile.in (pkgdata_SRCDIR): Remove. genmodsrc.sh and
595 genmk.rb don't need to be generated or installed.
596
597 2009-06-12 Vladimir Serbinenko <phcoder@gmail.com>
598
599 * commands/i386/pc/drivemap_int13h.S: add more comments
600
601 2009-06-11 Pavel Roskin <proski@gnu.org>
602
603 * Makefile.in (uninstall): Uninstall manuals.
604
605 * Makefile.in: Rename lib_DATA to lib_SCRIPTS, move it from
606 PKGLIB to SCRIPTS. This fixes installation of grub-mkconfig_lib
607 and update-grub_lib in two places.
608 * conf/common.rmk: Rename lib_DATA to lib_SCRIPTS.
609
610 * disk/usbms.c (grub_usbms_transfer): Initialize `err' to fix
611 a compiler warning.
612
613 * loader/i386/bsd.c (grub_freebsd_boot): Rename `entry' to
614 `entry_lo' to fix variable shadowing.
615
616 2009-06-11 Christian Franke <franke@computer.org>
617
618 * kern/misc.c (__enable_execute_stack): Add missing return type
619 to prevent gcc warning.
620
621 2009-06-11 Felix Zielcke <fzielcke@z-51.de>
622
623 * conf/i386-ieee1275.rmk (COMMON_LDFLAGS): Remove `-static -lgcc'.
624
625 2009-06-11 Pavel Roskin <proski@gnu.org>
626
627 * Makefile.in: Don't rely on any scripts being executable.
628 Always use $(SHELL) to run shell scripts.
629
630 * configure.ac: Always define ___main if using -nostdlib. This
631 fixes tests on Cygwin.
632
633 2009-06-11 Giuseppe Caizzone <acaizzo@gmail.com>
634
635 UDF fix
636
637 * fs/udf.c (grub_udf_read_block): handle the fact that ad->length
638 is in bytes and not in blocks
639
640 2009-06-11 Pavel Roskin <proski@gnu.org>
641
642 * kern/i386/halt.c (grub_halt): Make `i' unsigned to fix a
643 warning.
644
645 2009-06-11 Felix Zielcke <fzielcke@z-51.de>
646
647 * util/grub.d/30_os-prober.in: Fix a comment. Source
648 ${libdir}/grub/grub-mkconfig_lib. Use prepare_grub_to_access_device
649 to set the root device. Place drivemap command in the generated
650 chain entry.
651
652 2009-06-11 Pavel Roskin <proski@gnu.org>
653
654 * configure.ac: Remove host_m32. Issues with 64-bit utilities
655 have long been resolved.
656
657 2009-06-11 Colin Watson <cjwatson@ubuntu.com>
658
659 * util/grub.d/10_linux.in: Capitalise "Linux".
660
661 * util/grub-pe2elf.c (usage): Fix references to grub-editenv.
662
663 2009-06-11 Pavel Roskin <proski@gnu.org>
664
665 * kern/efi/efi.c (grub_exit): Add infinite loop at the end to
666 fix a gcc warning and ensure that the function won't ever exit.
667
668 * kern/i386/ieee1275/init.c: Add missing prototype for
669 grub_stop_floppy().
670
671 * loader/ieee1275/multiboot2.c [__i386__]: Include
672 grub/cpu/multiboot.h.
673
674 * term/i386/pc/serial.c (serial_translate_key_sequence): Avoid
675 casts to short - they are not portable and cause warnings. Fix
676 use of uninitialized values in input_buf. Use ARRAY_SIZE.
677
678 2009-06-11 Vladimir Serbinenko <phcoder@gmail.com>
679
680 Drivemap fixes
681
682 * commands/i386/pc/drivemap.c (grub_get_root_biosnumber_drivemap):
683 new function
684 (grub_get_root_biosnumber_saved): new variable
685 (GRUB_MOD_INIT): register grub_get_root_biosnumber_drivemap
686 (GRUB_MOD_FINI): unregister grub_get_root_biosnumber_drivemap
687 * commands/i386/pc/drivemap_int13h.S (grub_drivemap_handler): restore
688 %dx after the call if necessary
689 * conf/common.rmk (pkglib_MODULES): remove boot.mod
690 (boot_mod_SOURCES): remove
691 (boot_mod_CFLAGS): remove
692 (boot_mod_LDFLAGS): remove
693 * conf/i386-coreboot.rmk (pkglib_MODULES): add boot.mod
694 (boot_mod_SOURCES): new variable
695 (boot_mod_CFLAGS): likewise
696 (boot_mod_LDFLAGS): likewise
697 * conf/i386-efi.rmk: likewise
698 * conf/i386-ieee1275.rmk: likewise
699 * conf/i386-pc.rmk: likewise
700 * conf/powerpc-ieee1275.rmk: likewise
701 * conf/sparc64-ieee1275.rmk: likewise
702 * conf/x86_64-efi.rmk: likewise
703 * include/grub/i386/pc/biosnum.h: new file
704 * lib/i386/pc/biosnum.c: likewise
705 * loader/i386/bsd.c (grub_bsd_get_device): use grub_get_root_biosnumber
706 * loader/i386/multiboot.c (grub_multiboot_get_bootdev): likewise
707 * loader/i386/pc/chainloader.c (grub_chainloader_cmd): likewise
708
709 2009-06-10 Pavel Roskin <proski@gnu.org>
710
711 * io/gzio.c (test_header): Don't reuse one buffer for all data.
712 Use separate variables. Read only the file size at the end, but
713 not the checksum that we don't use.
714
715 * kern/file.c (grub_file_read): Use void pointer for the buffer.
716 Adjust all callers.
717
718 * kern/ieee1275/openfw.c: Remove libc includes.
719 * kern/ieee1275/cmain.c: Likewise.
720 * include/grub/ieee1275/ieee1275.h: Likewise.
721
722 * kern/i386/coreboot/init.c: Include grub/cpu/tsc.h to fix
723 compiler warnings.
724
725 2009-06-10 Felix Zielcke <fzielcke@z-51.de>
726
727 * gendistlist.sh (EXTRA_DISTFILES): Add `genhandlerlist.sh' and
728 `genparttoollist.sh'.
729 (DISTDIRS): Add `efiemu', `mmap', `parttool' and `script'.
730 Add `*.sh' to the list find searches for and change `mdate.sh'
731 to `mdate-sh'.
732
733 2009-06-10 Pavel Roskin <proski@gnu.org>
734
735 * include/grub/multiboot2.h: Provide compatibility defines for
736 multiboot2.h.
737 * include/multiboot2.h: Include stdint.h only if needed, using
738 angle brackets.
739 * loader/i386/pc/multiboot2.c: Include multiboot2.h after
740 grub/multiboot2.h.
741 * loader/ieee1275/multiboot2.c: Likewise.
742 * loader/multiboot2.c: Likewise.
743 * loader/multiboot_loader.c: Likewise.
744
745 * configure.ac: Use -nostdlib when probing for the target. It
746 should not be required to have libc for the target.
747
748 * configure.ac: Remove checks for __bswapsi2 and __bswapdi2,
749 they fail without libc headers for the target.
750 * include/grub/powerpc/libgcc.h: Use weak attribute for all
751 exports.
752 * include/grub/sparc64/libgcc.h: Likewise. Don't use
753 preprocessor conditionals.
754
755 * conf/common.rmk: Compile tar.mod from tar.c, not cpio.c. The
756 build system doesn't need to be aware of the tar.c internals.
757
758 2009-06-09 Michel Hermier <michel.hermier@gmail.com>
759
760 * fs/i386/pc/pxe.c (grub_pxefs_read): Fix returned values.
761
762 2009-06-09 Robert Millan <rmh.grub@aybabtu.com>
763
764 * util/deviceiter.c (grub_util_iterate_devices): Increase number of
765 disk limit to 26 for IDE, Virtio, Xen and SCSI.
766
767 2009-06-09 Felix Zielcke <fzielcke@z-51.de>
768
769 * util/i386/pc/grub-install.in: Change the error message if UUIDs
770 aren't available if ata.mod gets used.
771
772 2009-06-09 Oliver Henshaw <oliver.henshaw@gmail.com>
773
774 * bus/usb/ohci.c (grub_ohci_pci_iter): Link struct only after
775 initialising controller.
776 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
777
778 2009-06-08 Felix Zielcke <fzielcke@z-51.de>
779
780 * util/i386/pc/grub-install.in: Add a parameter --disk-module
781 to choose between ata and biosdisk module on i386-pc.
782
783 2009-06-08 Oliver Henshaw <oliver.henshaw@gmail.com>
784
785 * bus/usb/ohci.c (grub_ohci_pci_iter): Define the Class,
786 Subclass and Programming Interface fields in terms of the 3 byte
787 Class Code register.
788 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
789
790 * bus/usb/ohci.c (grub_ohci_pci_iter): Check that programming
791 interface is OHCI. Add grub_dprintf for symmetry with
792 bus/usb/uhci.c.
793 * bus/usb/uhci.c (grub_uhci_pci_iter): Check that programming
794 interface is UHCI. Add interf variable for programming
795 interface. Print interface with class/subclass.
796
797 * bus/usb/ohci.c: Set interf with correct field.
798
799 * bus/usb/uhci.c: Remove unneeded doubled lines.
800 * bus/usb/ohci.c: Likewise. Change interf to grub_uint32_t.
801 Remove whitespace inside comment.
802
803 2009-06-08 Robert Millan <rmh.grub@aybabtu.com>
804
805 * loader/i386/linux.c (grub_cmd_linux): When processing `vga=', use
806 as fallback an equivalent option without depth.
807
808 2009-06-08 Vladimir Serbinenko <phcoder@gmail.com>
809
810 Not fail if unable to retrieve C/H/S on LBA disks
811
812 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): behave gracefully
813 if unable to retrieve C/H/S on LBA disks
814
815 2009-06-08 Pavel Roskin <proski@gnu.org>
816
817 * fs/hfs.c (grub_hfs_find_dir): Use union to avoid a warning
818 about aliasing.
819
820 2009-06-08 Felix Zielcke <fzielcke@z-51.de>
821
822 * Makefile.in (uninstall): Remove all $lib_DATA files.
823
824 2009-06-08 Vladimir Serbinenko <phcoder@gmail.com>
825
826 Bugfix: install on partitionless device
827
828 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): check if os_dev
829 is a whole disk
830
831 2009-06-08 Felix Zielcke <fzielcke@z-51.de>
832
833 * Makefile.in (uninstall): Remove all $include_DATA files.
834
835 2009-06-08 Felix Zielcke <fzielcke@z-51.de>
836
837 * commands/true.c: New file. Implement the true and false commands.
838 * conf/common.rmk.c (pkglib_MODULES): Add `true.mod'.
839 (true_mod_SOURCES): New variable.
840 (true_mod_CFLAGS): Likewise.
841 (true_mod_LDFLAGS): Likewise.
842
843 2009-06-05 Colin D Bennett <colin@gibibit.com>
844
845 Optimized font character lookup using binary search instead of linear
846 search. Fonts now are required to have the character index ordered by
847 code point.
848
849 * font/font.c (load_font_index): Verify that fonts have ordered
850 character indices.
851 (find_glyph): Use binary search instead of linear search to find a
852 character in a font.
853
854 2009-06-05 Michael Scherer <misc@mandriva.org>
855
856 * fs/hfsplus.c (grub_hfsplus_mount): Determine if the filesystem
857 uses case sensitive btree.
858 (grub_hfsplus_iterate_dir): Use GRUB_FSHELP_CASE_INSENSITIVE
859 only for case insensitive filesystems.
860
861 2009-06-05 Vladimir Serbinenko <phcoder@gmail.com>
862
863 * conf/i386-pc.rmk (efiemu_mod_CFLAGS): remove -Werror -Wall
864 * conf/common.rmk (search_mod_CFLAGS): likewise
865
866 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
867
868 * kern/i386/pc/startup.S [APPLE_CC]: block of nops to
869 compensate a compiler bug
870
871 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
872
873 * include/grub/term.h (GRUB_TERM_BACKSPACE): explicitly define as 8
874 instead of '\b'
875
876 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
877
878 Definitions for creating asm symbols with Apple's CC
879
880 * include/grub/symbol.h [APPLE_CC] (FUNCTION): new macro
881 [APPLE_CC] (VARIABLE): likewise
882
883 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
884
885 Disable lnxboot.img when compiled
886 with Apple's CC
887
888 * conf/i386-pc.rmk (pkglib_IMAGES): remove lnxboot.img
889 pkglib_IMAGES [! TARGET_APPLE_CC] (pkglib_IMAGES): add lnxboot.img
890 * boot/i386/pc/lnxboot.S [APPLE_CC]: define an #error
891 [! APPLE_CC] (CODE_LENG): skip
892 [! APPLE_CC] (setup_sects): likewise
893 [! APPLE_CC]: skip filling
894
895 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
896
897 Address in trampolines based on 32-bit registers when compiled
898 with Apple's CC
899
900 * loader/i386/xnu_helper.S [APPLE_CC]: use 32-bit registers
901 for addresses
902 * loader/i386/linux_trampoline.S [APPLE_CC]: likewise
903
904 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
905
906 Avoid aliases when compiling with Apple's CC for PCBIOS machine
907
908 * kern/misc.c [APPLE_CC] (memcpy): new function
909 [APPLE_CC] (memmove): likewise
910 [APPLE_CC && !GRUB_UTIL] (grub_err_printf): likewise
911 (memcpy): define alias conditionally on !APPLE_CC
912 (memset): likewise
913 (abort): likewise
914 * include/grub/misc.h (memove): don't define when both GRUB_UTIL and
915 APPLE_CC are defined
916 * include/grub/list.h [APPLE_CC] (grub_assert_fail): new function
917 (grub_assert_fail): make prototype conditional
918
919 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
920
921 Use grub-macho2img when compiling with Apple's CC for PCBIOS machine
922
923 * conf/common.rmk (bin_UTILITIES): add (on false on condition)
924 grub-macho2img
925 (CLEANFILES): add grub-macho2img
926 (grub_macho2img_SOURCES): new variable
927 * kern/i386/pc/startup.S (bss_start): new variable
928 (bss_end): likewise
929 * genmk.rb: use grub-macho2img for *.img when compiled with Apple's CC
930 * util/grub-macho2img.c: new file
931
932 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
933
934 Use objconv when compiling with Apple's CC
935
936 * conf/i386-pc.rmk (efiemu32.o): use OBJCONV if defined
937 (efiemu64.o): likewise
938 (efiemu64_c.o): omit -mcmodel=large and add -DAPPLE_CC=1
939 when compiling with Apple's CC
940 (efiemu64_s.o): likewise
941 * configure.ac: check for objconv when compiling with Apple's CC
942 * genmk.rb: use objconv for modules when compiled with Apple's CC
943
944 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
945
946 Define segment as well as section when compiling with
947 Apple's CC
948
949 * efiemu/runtime/efiemu.c (PHYSICAL_ATTRIBUTE): new definition
950 (efiemu_set_virtual_address_map): declare with PHYSICAL_ATTRIBUTE
951 (efiemu_convert_pointer): likewise
952 (efiemu_set_virtual_address_map): likewise
953 (efiemu_convert_pointer): likewise
954 (efiemu_getcrc32): likewise
955 (init_crc32_table): likewise
956 (reflect): likewise
957 * include/grub/dl.h (GRUB_MOD_NAME): define segment with Apple's CC
958 (GRUB_MOD_DEP): likewise
959
960 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
961
962 Allow a compilation without -mcmodel=large
963
964 * kern/efi/mm.c (grub_efi_allocate_pages): don't allocate >4GiB
965 when compiled without -mcmodel=large
966 (filter_memory_map): remove memory post 4 GiB when compiled
967 without -mcmodel=large
968 * configure.ac: fail gracefully and add -DMCMODEL_SMALL=1 to
969 TARGET_CFLAGS when -mcmodel=large isn't supported
970
971 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
972
973 Remove nested functions in efiemu core
974
975 * efiemu/runtime/efiemu.c (reflect): make static instead of nested
976
977 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
978
979 Avoid clobbering %ebx/%rbx in inline assembly with Apple's CC
980
981 * efiemu/runtime/efiemu.c (write_cmos): use %cl instead of %bl as
982 temporary storage
983 * include/grub/i386/tsc.h (grub_get_tsc): restore %rbx/%ebx when
984 using Apple's CC
985 (grub_cpu_is_tsc_supported): likewise
986 * loader/i386/xnu.c (guessfsb): restore %rbx/%ebx in inline assembly
987
988 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
989
990 Absolute addressing through constant with Apple's cc
991
992 * kern/i386/pc/startup.S: Define necessary constants
993 and address through it when using ABS with Apple's CC
994 * boot/i386/pc/diskboot.S: likewise
995 * boot/i386/pc/boot.S: likewise
996 * boot/i386/pc/lnxboot.S: likewise
997 * boot/i386/pc/cdboot.S: likewise
998 * mmap/i386/pc/mmap_helper.S: likewise
999 * commands/i386/pc/drivemap_int13h.S: likewise
1000
1001 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1002
1003 Check if compiler is apple cc
1004
1005 * Makefile.in (ASFLAGS): new variable
1006 (TARGET_ASFLAGS): likewise
1007 (TARGET_MODULE_FORMAT): likewise
1008 (TARGET_APPLE_CC): likewise
1009 (OBJCONV): likewise
1010 (TARGET_IMG_CFLAGS): likewise
1011 (TARGET_CPPFLAGS): add includedir
1012 * configure.ac: call grub_apple_cc and grub_apple_target_cc
1013 (TARGET_IMG_LDFLAGS): Add -Wl,-Ttext,. All users updated
1014 Check for linker script only if compiler isn't Apple's CC
1015 (TARGET_MODULE_FORMAT): set
1016 (TARGET_APPLE_CC): likewise
1017 (TARGET_ASFLAGS): likewise
1018 (ASFLAGS): likewise
1019 Check for objcopy only if compiler isn't Apple's CC
1020 Check for BSS symbol only if compiler isn't Apple's CC
1021 * genmk.rb: adapt nm options if we use Apple's utils
1022 * aclocal.m4 (grub_apple_cc): new test
1023 (grub_apple_target_cc): likewise
1024
1025 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1026
1027 Simplify sed expressions and improve awk
1028
1029 * Makefile.in (install-local): simplify sed expression
1030 * gencmdlist.sh: likewise
1031 * genmoddep.awk: avoid adding module as a dependency of itself
1032
1033 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1034
1035 Add missing start symbols
1036
1037 * boot/i386/pc/boot.S: add start
1038 * boot/i386/pc/pxeboot.S: likewise
1039
1040 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1041
1042 Fix wrong assumptions with grub-mkimage on EFI
1043
1044 * i386/efi/grub-mkimage.c (read_kernel_module): don't write prefix here
1045 (relocate_addresses): consider both r_addend and value at offset
1046 (make_mods_section): zerofill modinfo and header
1047 (convert_elf): write prefix here
1048
1049 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1050
1051 Use .asciz instead of .string
1052
1053 * i386/pc/diskboot.S: use .asciz instead of .string
1054 * i386/pc/boot.S: likewise
1055 * include/grub/dl.h (GRUB_MOD_DEP): likewise
1056 (GRUB_MOD_NAME): likewise
1057
1058 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1059
1060 gfxpayload support
1061
1062 * commands/videotest.c (grub_cmd_videotest): use grub_video_set_mode
1063 * include/grub/video.h (GRUB_VIDEO_MODE_TYPE_PURE_TEXT): new definition
1064 (grub_video_setup): remove
1065 (grub_video_set_mode): new prototype
1066 * loader/i386/linux.c (DEFAULT_VIDEO_MODE): new definition
1067 (vid_mode): remove
1068 (linux_vesafb_res): compile only on PCBIOS
1069 (grub_linux_boot): support gfxpayload
1070 * loader/i386/pc/xnu.c (video_hook): new function
1071 (grub_xnu_set_video): support gfxpayload
1072 * term/gfxterm.c (DEFAULT_VIDEO_WIDTH): removed
1073 (DEFAULT_VIDEO_HEIGHT): likewise
1074 (DEFAULT_VIDEO_FLAGS): likewise
1075 (DEFAULT_VIDEO_MODE): new definition
1076 (video_hook): new function
1077 (grub_gfxterm_init): use grub_video_set_mode
1078 * util/grub.d/30_os-prober.in: remove explicit modesetting before
1079 loading xnu
1080 * video/video.c (grub_video_setup): removed
1081 (grub_video_set_mode): new function based on grub_gfxterm_init and
1082 grub_video_setup
1083
1084 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1085
1086 Avoid calling biosdisk in drivemap
1087
1088 * commands/i386/pc/drivemap.c (parse_biosdisk): remove
1089 (revparse_biosdisk): likewise
1090 (list_mappings): derive name from id directly
1091 (grub_cmd_drivemap): use tryparse_diskstring
1092
1093 2009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
1094
1095 Script fixes
1096
1097 * include/grub/script_sh.h (grub_script_cmdline): remove cmdline
1098 (grub_lexer_param): add tokenonhold
1099 (grub_script_create_cmdline): remove cmdline. All callers updated
1100 (grub_script_function_create): make functionname
1101 grub_script_arg. All callers updated
1102 (grub_script_execute_argument_to_string): new prototype
1103 * kern/parser.c (state_transitions): reorder
1104 (grub_parser_cmdline_state): fix a bug and make more compact
1105 * script/sh/execute.c (grub_script_execute_argument_to_string):
1106 make global
1107 (grub_script_execute_cmdline): use new format
1108 * script/sh/function.c (grub_script_function_create): make functionname
1109 grub_script_arg. All callers updated
1110 * script/sh/lexer.c (grub_script_lexer_init): initialize tokenonhold
1111 (grub_script_yylex): remove
1112 (grub_script_yylex2): renamed to ...
1113 (grub_script_yylex): ...renamed
1114 parse the expressions like a${b}c
1115 * script/sh/parser.y (GRUB_PARSER_TOKEN_ARG): new typed terminal
1116 (GRUB_PARSER_TOKEN_VAR): remove
1117 (GRUB_PARSER_TOKEN_NAME): likewise
1118 ("if"): declare as typeless
1119 ("while"): likewise
1120 ("function"): likewise
1121 ("else"): likewise
1122 ("then"): likewise
1123 ("fi"): likewise
1124 (text): remove
1125 (argument): likewise
1126 (script): accept empty scripts and make exit on error
1127 (arguments): use GRUB_PARSER_TOKEN_ARG
1128 (function): likewise
1129 (command): move error handling to script
1130 (menuentry): move grub_script_lexer_ref before
1131 * script/sh/script.c (grub_script_create_cmdline): remove cmdline
1132 argument. All callers updated
1133
1134 2009-06-04 Robert Millan <rmh.grub@aybabtu.com>
1135
1136 Prevent GRUB from probing floppies during boot.
1137
1138 * conf/common.rmk (search_mod_CFLAGS): Use `-Werror -Wall'.
1139 * commands/search.c (options): Add --no-floppy.
1140 (search_fs, search_file, grub_cmd_search): Support --no-floppy.
1141 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Use
1142 --no-floppy when searching for UUIDs.
1143
1144 2009-06-04 Robert Millan <rmh.grub@aybabtu.com>
1145
1146 Simplify the code duplication in commands/search.c.
1147
1148 * commands/search.c (search_label, search_fs_uuid): Merge into ...
1149 (search_fs): ... this. Update all users.
1150
1151 2009-06-03 Felix Zielcke <fzielcke@z-51.de>
1152
1153 * util/grub-mkconfig.in (update_grub_dir): Rename to grub_mkconfig_dir.
1154
1155 2009-05-28 Pavel Roskin <proski@gnu.org>
1156
1157 * Makefile.in: Don't use "cp -d", it doesn't work on FreeBSD.
1158 Remove the original symlink explicitly.
1159
1160 * fs/hfs.c (grub_hfs_find_dir): Skip sequences of slashes, not
1161 just one slash. That's how grub_fshelp_find_file() does it.
1162
1163 2009-05-26 Pavel Roskin <proski@gnu.org>
1164
1165 * genmk.rb: Avoid shadowing variable `s', rename the outer `s'
1166 to `str'.
1167
1168 * util/getroot.c (grub_util_get_dev_abstraction): Mark os_dev as
1169 possibly unused.
1170
1171 2009-05-25 Christian Franke <franke@computer.org>
1172
1173 * disk/ata.c (grub_ata_wait_not_busy): Add debug output of status
1174 register.
1175 (grub_atapi_identify): Add wait after drive select.
1176 (grub_ata_identify): Do more strict status register check before
1177 calling grub_atapi_identify (). Suppress error message if status
1178 register is 0x00 after command failure. Add status register
1179 check after PIO read to avoid bogus identify due to stuck DRQ.
1180 Thanks to Pavel Roskin for testing.
1181 (grub_device_initialize): Remove unsafe status register check.
1182 Thanks to 'phcoder' for problem report and patch.
1183 Prevent sign extension in debug message.
1184
1185 2009-05-23 Colin D Bennett <colin@gibibit.com>
1186
1187 Cleaned up `include/grub/normal.h'. Grouped prototypes by
1188 definition file, and functions defined in `normal/menu.c' have had
1189 their prototypes moved to `include/grub/menu.h' for consistency.
1190
1191 * include/grub/menu.h (grub_menu_execute_callback): Added; moved
1192 from normal.h.
1193 (grub_menu_get_entry): Likewise.
1194 (grub_menu_get_timeout): Likewise.
1195 (grub_menu_set_timeout): Likewise.
1196 (grub_menu_execute_entry): Likewise.
1197 (grub_menu_execute_with_fallback): Likewise.
1198 (grub_menu_entry_run): Likewise.
1199
1200 * include/grub/normal.h: Re-ordered and grouped function
1201 prototypes by file that the function is defined in.
1202 (grub_menu_execute_callback): Removed; moved to menu.h.
1203 (grub_menu_get_entry): Likewise.
1204 (grub_menu_get_timeout): Likewise.
1205 (grub_menu_set_timeout): Likewise.
1206 (grub_menu_execute_entry): Likewise.
1207 (grub_menu_execute_with_fallback): Likewise.
1208 (grub_menu_entry_run): Likewise.
1209 (grub_menu_addentry): Renamed from this ...
1210 (grub_normal_add_menu_entry): ... to this.
1211
1212 * normal/main.c (grub_menu_addentry): Renamed from this ...
1213 (grub_normal_add_menu_entry): ... to this.
1214
1215 * script/sh/execute.c (grub_script_execute_menuentry): Update
1216 reference to renamed grub_menu_addentry function.
1217
1218 2009-05-23 Felix Zielcke <fzielcke@z-51.de>
1219
1220 * commands/i386/pc/drivemap.c (MODNAME): Remove. Update all users.
1221
1222 2009-05-22 Pavel Roskin <proski@gnu.org>
1223
1224 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Remove.
1225 * configure.ac: Don't call grub_I386_CHECK_REGPARM_BUG. Define
1226 NESTED_FUNC_ATTR using AH_BOTTOM. Use regparm(1) only when
1227 compiling for the i386 targets, but not for the utilities.
1228
1229 * include/grub/i386/pc/kernel.h (grub_boot_drive): Change type
1230 to grub_uint8_t.
1231 (grub_root_drive): Likewise.
1232 * kern/i386/pc/startup.S (grub_boot_drive): Change size to byte,
1233 remove alignment.
1234 (grub_root_drive): Change size to byte.
1235 (grub_start_addr): Remove.
1236 (grub_end_addr): Likewise.
1237 (grub_apm_bios_info): Likewise.
1238
1239 2009-05-21 Felix Zielcke <fzielcke@z-51.de>
1240
1241 * normal/i386: Remove.
1242 * normal/powerpc: Likewise.
1243 * normal/sparc64: Likewise.
1244 * normal/x86_64: Likewise.
1245
1246 2009-05-19 Vladimir Serbinenko <phcoder@gmail.com>
1247
1248 * conf/x86_64-efi.rmk (linux_mod_ASFLAGS): Add missing variable
1249 * loader/i386/linux_trampoline.S: Fix indentation
1250 * loader/i386/xnu_helper.S: Likewise
1251
1252 2009-05-18 Colin D Bennett <colin@gibibit.com>
1253
1254 Display error messages when parsing a Lua statement fails.
1255 Previously, executing a syntactically invalid statement like
1256 ")foo" or "bar;" would silently fail.
1257
1258 * script/lua/grub_main.c (handle_lua_error): New function.
1259 (grub_lua_parse_line): Improved reporting of Lua parser and
1260 execution errors.
1261
1262 2009-05-17 Vladimir Serbinenko <phcoder@gmail.com>
1263
1264 Remove -Werror which causes build to fail on some systems
1265
1266 * conf/i386-pc.rmk (xnu_mod_CFLAGS): Remove -Werror -Wall
1267 * conf/i386-efi.rmk (xnu_mod_CFLAGS): Likewise
1268 * conf/x86_64-efi.rmk (xnu_mod_CFLAGS): Likewise
1269
1270 2009-05-17 Vladimir Serbinenko <phcoder@gmail.com>
1271
1272 trampoline for linux on 64-bit platform
1273
1274 * conf/x86_64-efi.rmk (linux_mod_SOURCES): added
1275 loader/i386/efi/linux_trampoline.S
1276 * include/grub/x86_64/efi/loader.h (grub_linux_real_boot): removed
1277 declaration
1278 * kern/x86_64/efi/startup.S (grub_linux_real_boot): moved from
1279 here
1280 * loader/i386/linux_trampoline.S: moved here
1281 * loader/i386/efi/linux.c (allocate_pages): reserve space for
1282 trampoline
1283 (jumpvector): removed
1284 (grub_linux_trampoline_start): new declaration
1285 (grub_linux_trampoline_end): likewise
1286 (grub_linux_boot): use trampoline when on 64-bit platform
1287 * loader/i386/linux.c: likewise
1288
1289 2009-05-16 Pavel Roskin <proski@gnu.org>
1290
1291 * script/lua/grub_lib.c (grub_lua_getenv): Make name and value
1292 const to avoid a warning.
1293 (grub_lua_setenv): Likewise.
1294 * script/lua/grub_main.c (grub_lua_parse_line): Use size_t for
1295 lmsg to fix a warning.
1296
1297 2009-05-16 Felix Zielcke <fzielcke@z-51.de>
1298
1299 * conf/i386.rmk (setjmp_mod_CFLAGS): Rename to ...
1300 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
1301 * conf/x86_64-efi.rmk (setjmp_mod_CFLAGS): Rename to ...
1302 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
1303 * conf/powerpc-ieee1275.rmk (setjmp_mod_CFLAGS): Rename to ...
1304 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
1305 * conf/sparc64-ieee1275.rmk (setjmp_mod_CFLAGS): Rename to ...
1306 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
1307
1308 2009-05-16 Felix Zielcke <fzielcke@z-51.de>
1309
1310 * util/grub-mkconfig.in: Export GRUB_TERMINAL_INPUT.
1311
1312 2009-05-16 Bean <bean123ch@gmail.com>
1313
1314 * conf/common.rmk (pkglib_MODULES): Add lua.mod.
1315 (lua_mod_SOURCES): New variable.
1316 (lua_mod_CFLAGS): Likewise.
1317 (lua_mod_LDFLAGS): Likewise.
1318
1319 * conf/i386.rmk (pkglib_MODULES): Add setjmp.mod.
1320 (setjmp_mod_SOURCES): New variable.
1321 (setjmp_mod_CFLAGS): Likewise.
1322 (setjmp_LDFLAGS): Likewise.
1323
1324 * conf/x86_64-efi.rmk (pkglib_MODULES): Add setjmp.mod.
1325 (setjmp_mod_SOURCES): New variable.
1326 (setjmp_mod_CFLAGS): Likewise.
1327 (setjmp_LDFLAGS): Likewise.
1328
1329 * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add setjmp.mod.
1330 (setjmp_mod_SOURCES): New variable.
1331 (setjmp_mod_CFLAGS): Likewise.
1332 (setjmp_LDFLAGS): Likewise.
1333
1334 * conf/sparc64-ieee1275.rmk (pkglib_MODULES): Add setjmp.mod.
1335 (setjmp_mod_SOURCES): New variable.
1336 (setjmp_mod_CFLAGS): Likewise.
1337 (setjmp_LDFLAGS): Likewise.
1338
1339 * normal/i386/setjmp.S: Moved from here ...
1340 * lib/i386/setjmp.S: ... Moved here
1341 * normal/x86_64/setjmp.S: Moved from here ...
1342 * lib/x86_64/setjmp.S: ... Moved here
1343 * normal/powerpc/setjmp.S: Moved from here ...
1344 * lib/powerpc/setjmp.S: ... Moved here
1345 * normal/sparc64/setjmp.S: Moved from here ...
1346 * lib/sparc64/setjmp.S: ... Moved here
1347
1348 * include/grub/i386/setjmp.h (grub_setjmp): Don't use attribute
1349 returns_twice in mingw.
1350
1351 * script/lua/grub_lib.c: New file.
1352 * script/lua/grub_lib.h: Likewise.
1353 * script/lua/grub_lua.h: Likewise.
1354 * script/lua/grub_main.c: Likewise.
1355 * script/lua/lapi.c: Likewise.
1356 * script/lua/lapi.h: Likewise.
1357 * script/lua/lauxlib.c: Likewise.
1358 * script/lua/lauxlib.h: Likewise.
1359 * script/lua/lbaselib.c: Likewise.
1360 * script/lua/lcode.c: Likewise.
1361 * script/lua/lcode.h: Likewise.
1362 * script/lua/ldblib.c: Likewise.
1363 * script/lua/ldebug.c: Likewise.
1364 * script/lua/ldebug.h: Likewise.
1365 * script/lua/ldo.c: Likewise.
1366 * script/lua/ldo.h: Likewise.
1367 * script/lua/ldump.c: Likewise.
1368 * script/lua/lfunc.c: Likewise.
1369 * script/lua/lfunc.h: Likewise.
1370 * script/lua/lgc.c: Likewise.
1371 * script/lua/lgc.h: Likewise.
1372 * script/lua/linit.c: Likewise.
1373 * script/lua/liolib.c: Likewise.
1374 * script/lua/llex.c: Likewise.
1375 * script/lua/llex.h: Likewise.
1376 * script/lua/llimits.h: Likewise.
1377 * script/lua/lmathlib.c: Likewise.
1378 * script/lua/lmem.c: Likewise.
1379 * script/lua/lmem.h: Likewise.
1380 * script/lua/loadlib.c: Likewise.
1381 * script/lua/lobject.c: Likewise.
1382 * script/lua/lobject.h: Likewise.
1383 * script/lua/lopcodes.c: Likewise.
1384 * script/lua/lopcodes.h: Likewise.
1385 * script/lua/loslib.c: Likewise.
1386 * script/lua/lparser.c: Likewise.
1387 * script/lua/lparser.h: Likewise.
1388 * script/lua/lstate.c: Likewise.
1389 * script/lua/lstate.h: Likewise.
1390 * script/lua/lstring.c: Likewise.
1391 * script/lua/lstring.h: Likewise.
1392 * script/lua/lstrlib.c: Likewise.
1393 * script/lua/ltable.c: Likewise.
1394 * script/lua/ltable.h: Likewise.
1395 * script/lua/ltablib.c: Likewise.
1396 * script/lua/ltm.c: Likewise.
1397 * script/lua/ltm.h: Likewise.
1398 * script/lua/lua.h: Likewise.
1399 * script/lua/luaconf.h: Likewise.
1400 * script/lua/lualib.h: Likewise.
1401 * script/lua/lundump.c: Likewise.
1402 * script/lua/lundump.h: Likewise.
1403 * script/lua/lvm.c: Likewise.
1404 * script/lua/lvm.h: Likewise.
1405 * script/lua/lzio.c: Likewise.
1406 * script/lua/lzio.h: Likewise.
1407
1408 2009-05-16 Bean <bean123ch@gmail.com>
1409
1410 * include/grub/kernel.h (grub_module_header_types): Add type
1411 OBJ_TYPE_CONFIG.
1412
1413 * kern/main.c (grub_load_config): New function.
1414 (grub_main): Call grub_load_config to read boot config.
1415
1416 * grub-mkimage (generate_image): New parameter config_path.
1417 (options): New option --config.
1418 (main): Parse --config option, and pass it to generate_image.
1419
1420 2009-05-14 Christian Franke <franke@computer.org>
1421
1422 * commands/i386/pc/drivemap_int13h.S: Add missing EXT_C for symbols.
1423 This fixes build on Cygwin.
1424
1425 2009-05-14 Pavel Roskin <proski@gnu.org>
1426
1427 * commands/i386/pc/drivemap_int13h.S: Eliminate unconditional
1428 jump. This saves two bytes, so the typical case of 2 swapped
1429 drives would fit 32 bytes.
1430
1431 2009-05-13 Pavel Roskin <proski@gnu.org>
1432
1433 * loader/i386/multiboot.c (grub_multiboot): Cast mmap_addr to
1434 grub_uint32_t to avoid a warning.
1435
1436 * loader/i386/linux.c (allocate_pages): When assigning
1437 real_mode_mem, cast through grub_size_t to fix a warning. The
1438 code already makes sure that the value would fit a pointer.
1439 (grub_linux_setup_video): Cast render_target->data to
1440 grub_size_t to fix a warning.
1441
1442 2009-05-13 Javier Martín <lordhabbit@gmail.com>
1443
1444 * commands/i386/pc/drivemap.c: New file - implement drivemap
1445 command.
1446 * commands/i386/pc/drivemap_int13h.S: New file - int13 handler.
1447 * conf/i386-pc.rmk: Add drivemap.c and drivemap_int13h.S.
1448
1449 2009-05-13 Pavel Roskin <proski@gnu.org>
1450
1451 * util/i386/pc/grub-setup.c (setup): Remove unused variable
1452 embedding_area_exists.
1453
1454 2009-05-13 Robert Millan <rmh.grub@aybabtu.com>
1455
1456 * util/i386/pc/grub-setup.c (setup): Restructure code flow to make
1457 it easier to understand / work with.
1458 Improve warning messages for cases where there's no embedding area,
1459 or when it is too small (or core.img too large).
1460
1461 2009-05-13 Pavel Roskin <proski@gnu.org>
1462
1463 * loader/i386/pc/multiboot2.c: Add necessary includes for
1464 grub_multiboot2_real_boot().
1465
1466 * fs/iso9660.c (grub_iso9660_iterate_dir): The file mode in the
1467 PX record is always little-endian. We only need the lower 2
1468 bytes of the mode.
1469
1470 * fs/cpio.c: Use the same name "struct head" for tar and cpio to
1471 facilitate code reuse.
1472 (grub_cpio_mount): Use "struct head", not a char buffer. This
1473 fixes a warning reported by gcc 4.4.
1474
1475 * kernel/disk.c (grub_disk_read): Use void pointer for the
1476 buffer.
1477 (grub_disk_write): Use const void pointer for the buffer.
1478 Adjust all callers. Remove unnecessary casts.
1479
1480 2009-05-10 Robert Millan <rmh.grub@aybabtu.com>
1481
1482 * util/i386/pc/grub-install.in: Update copyright year.
1483
1484 2009-05-09 Vladimir Serbinenko <phcoder@gmail.com>
1485
1486 gptsync
1487
1488 * commands/gptsync.c: new file
1489 * conf/common.rmk (pkglib_MODULES): add gptsync.mod
1490 (gptsync_mod_SOURCES): new variable
1491 (gptsync_mod_CFLAGS): likewise
1492 (gptsync_mod_LDFLAGS): likewise
1493 * include/grub/pc_partition.h (GRUB_PC_PARTITION_TYPE_NTFS):
1494 new definition
1495 (GRUB_PC_PARTITION_TYPE_HFS): likewise
1496 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/gptsync.c
1497 * conf/i386-ieee1275.rmk: likewise
1498 * conf/i386-pc.rmk: likewise
1499 * conf/powerpc-ieee1275.rmk: likewise
1500
1501 2009-05-09 Vladimir Serbinenko <phcoder@gmail.com>
1502
1503 Fixed grub-emu
1504
1505 * kern/dl.c (grub_dl_ref): omit when compiling grub-emu
1506 (grub_dl_ref): likewise
1507
1508 2009-05-08 Robert Millan <rmh.grub@aybabtu.com>
1509
1510 * util/i386/pc/grub-setup.c (setup): Factorize find_usable_region(),
1511 split in two functions (one for msdos and one for gpt).
1512
1513 2009-05-08 Pavel Roskin <proski@gnu.org>
1514
1515 * disk/raid.c (grub_raid_block_xor): Make buf2 constant, it's
1516 not modified.
1517
1518 * disk/raid6_recover.c (grub_raid6_recover): Fix warnings about
1519 uninitialized err[0] and err[1]. Rename them to bad1 and bad2.
1520 Initialize them with -1. Add sanity check for bad1. Eliminate
1521 nerr variable.
1522
1523 2009-05-08 David S. Miller <davem@davemloft.net>
1524
1525 * util/sparc64/ieee1275/grub-ofpathname.c (main): Set progname.
1526
1527 2009-05-06 Robert Millan <rmh.grub@aybabtu.com>
1528
1529 * util/i386/pc/grub-setup.c (setup): Fix check for embed region
1530 existence.
1531
1532 2009-05-05 Felix Zielcke <fzielcke@z-51.de>
1533
1534 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
1535 `kern/rescue_reader.c', `kern/rescue_parser.c' and `normal/autofs.c'.
1536
1537 2009-05-05 David S. Miller <davem@davemloft.net>
1538
1539 * util/sparc64/ieee1275/grub-install.in: Fix sed arg quoting.
1540
1541 2009-05-05 Pavel Roskin <proski@gnu.org>
1542
1543 * include/grub/dl.h [GRUB_UTIL]: Provide inline implementations
1544 of grub_dl_ref() and grub_dl_unref().
1545 * commands/parttool.c: Remove preprocessor conditionals around
1546 grub_dl_ref() and grub_dl_unref().
1547 * fs/affs.c: Likewise.
1548 * fs/afs.c: Likewise.
1549 * fs/cpio.c: Likewise.
1550 * fs/ext2.c: Likewise.
1551 * fs/fat.c: Likewise.
1552 * fs/hfs.c: Likewise.
1553 * fs/hfsplus.c: Likewise.
1554 * fs/iso9660.c: Likewise.
1555 * fs/jfs.c: Likewise.
1556 * fs/minix.c: Likewise.
1557 * fs/ntfs.c: Likewise.
1558 * fs/reiserfs.c: Likewise.
1559 * fs/sfs.c: Likewise.
1560 * fs/udf.c: Likewise.
1561 * fs/ufs.c: Likewise.
1562 * fs/xfs.c: Likewise.
1563 * include/grub/dl.h: Likewise.
1564 * loader/xnu.c: Likewise.
1565
1566 2009-05-04 Pavel Roskin <proski@gnu.org>
1567
1568 * commands/acpi.c: Remove unused variable my_mod.
1569 * partmap/amiga.c: Likewise.
1570 * partmap/apple.c: Likewise.
1571 * partmap/gpt.c: Likewise.
1572 * partmap/pc.c: Likewise.
1573 * partmap/sun.c: Likewise.
1574 * term/gfxterm.c: Likewise.
1575 * term/i386/pc/vesafb.c: Likewise.
1576 * term/i386/pc/vga.c: Likewise.
1577
1578 2009-05-04 David S. Miller <davem@davemloft.net>
1579
1580 * kern/ieee1275/openfw.c (grub_children_iterate): Fix string
1581 pointer args to grub_ieee1275_get_property().
1582
1583 * conf/sparc64-ieee1275.rmk: Fix build due to missing '\'.
1584
1585 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Bypass cdrom
1586 devices, and do not traverse down under controller nodes.
1587
1588 * disk/ieee1275/ofdisk.c (compute_dev_path): New.
1589 (grub_ofdisk_open): Use it to un-escape "," characters.
1590 * kern/disk.c (find_part_sep): New.
1591 (grub_disk_open): Use it to find the first non-escaped ','
1592 character in the disk name.
1593 * util/ieee1275/devicemap.c (escape_of_path): New.
1594 (grub_util_emit_devicemap_entry): Use it.
1595 * util/sparc64/ieee1275/grub-install.in: Update script to
1596 strip partition specifiers properly by not triggering on
1597 '\' escaped ',' characters.
1598
1599 2009-05-04 Robert Millan <rmh.grub@aybabtu.com>
1600
1601 * include/grub/i386/linux.h (GRUB_LINUX_VID_MODE_VESA_START): Set
1602 to 0x300.
1603 * loader/i386/linux.c (vga_modes, linux_vesafb_res): Add a few
1604 resolutions.
1605 (linux_vesafb_modes): Add a lot of additional modes to the list (based
1606 on documentation from Wikipedia).
1607
1608 2009-05-04 Pavel Roskin <proski@gnu.org>
1609
1610 * disk/ata.c: Spelling fixes.
1611 * disk/raid.c: Likewise.
1612 * disk/usbms.c: Likewise.
1613 * disk/dmraid_nvidia.c: Likewise.
1614 * kern/ieee1275/openfw.c: Likewise.
1615 * kern/ieee1275/init.c: Likewise.
1616 * kern/ieee1275/cmain.c: Likewise.
1617 * boot/i386/pc/cdboot.S: Likewise.
1618 * video/readers/png.c: Likewise.
1619 * video/i386/pc/vbe.c: Likewise.
1620 * fs/udf.c: Likewise.
1621 * fs/hfs.c: Likewise.
1622 * fs/reiserfs.c: Likewise.
1623 * efiemu/runtime/efiemu.c: Likewise.
1624 * efiemu/main.c: Likewise.
1625 * efiemu/mm.c: Likewise.
1626 * include/grub/elf.h: Likewise.
1627 * include/grub/xnu.h: Likewise.
1628 * include/grub/usbdesc.h: Likewise.
1629 * include/grub/usb.h: Likewise.
1630 * include/grub/script_sh.h: Likewise.
1631 * include/grub/lib/LzmaEnc.h: Likewise.
1632 * include/grub/efiemu/efiemu.h: Likewise.
1633 * include/grub/command.h: Likewise.
1634 * normal/menu.c: Likewise.
1635 * normal/main.c: Likewise.
1636 * normal/datetime.c: Likewise.
1637 * bus/usb/uhci.c: Likewise.
1638 * mmap/i386/uppermem.c: Likewise.
1639 * mmap/mmap.c: Likewise.
1640 * commands/acpi.c: Likewise.
1641 * commands/test.c: Likewise.
1642 * partmap/apple.c: Likewise.
1643 * font/font.c: Likewise.
1644 * loader/sparc64/ieee1275/linux.c: Likewise.
1645 * loader/macho.c: Likewise.
1646 * loader/i386/bsd_trampoline.S: Likewise.
1647 * loader/i386/bsd.c: Likewise.
1648 * loader/xnu.c: Likewise.
1649 * term/i386/pc/vesafb.c: Likewise.
1650 * term/usb_keyboard.c: Likewise.
1651 * util/resolve.c: Likewise.
1652 * util/getroot.c: Likewise.
1653
1654 2009-05-04 Felix Zielcke <fzielcke@z-51.de>
1655
1656 * conf/i386-pc.rmk (libpkg_DATA): Rename to pkglib_DATA.
1657
1658 2009-05-04 Robert Millan <rmh.grub@aybabtu.com>
1659
1660 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS] (grub_cmd_linux): Fix
1661 build error.
1662
1663 2009-05-04 Robert Millan <rmh.grub@aybabtu.com>
1664
1665 * loader/i386/linux.c (grub_cmd_linux): Make "vga=" compatibility
1666 parameter only available on BIOS.
1667
1668 2009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
1669
1670 Removed wrong semicolon in declaration
1671
1672 * grub/misc.h (grub_dprintf): remove semicolon
1673
1674 2009-05-04 Robert Millan <rmh.grub@aybabtu.com>
1675
1676 * loader/i386/linux.c (GRUB_ASSUME_LINUX_HAS_FB_SUPPORT): New macro.
1677 (grub_linux_boot): Don't check for `linux_vesafb_modes' bounds (this
1678 is done by grub_cmd_linux() now).
1679 [! GRUB_ASSUME_LINUX_HAS_FB_SUPPORT]: If "vga=" parameter wasn't set,
1680 restore video to text mode.
1681 (grub_cmd_linux): Default `vid_mode' initialization to 0, which
1682 indicates lack of "vga=" parameter. "vga=0" is mapped to
1683 `GRUB_LINUX_VID_MODE_NORMAL'.
1684
1685 2009-05-04 Felix Zielcke <fzielcke@z-51.de>
1686
1687 * conf/i386-efi.rmk (grub_emu_SOURCES): Remove `normal/execute.c',
1688 `normal/lexer.c', `kern/rescue.c', `normal/function.c', `normal/misc.c'
1689 and `normal/script.c'. Add `kern/rescue_reader.c',
1690 `kern/rescue_parser.c', `script/sh/main.c', `script/sh/execute.c',
1691 `script/sh/function.c', `script/sh/lexer.c', `script/sh/script.c' and
1692 `grub_script.tab.c'.
1693
1694 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1695 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
1696 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1697 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
1698 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1699
1700 * Makefile.in: Remove duplicated 2008 in Copyright line.
1701
1702 2009-05-04 Robert Millan <rmh.grub@aybabtu.com>
1703
1704 * util/misc.c (grub_util_warn): New function. Emits a warning
1705 unconditionally.
1706 * include/grub/util/misc.h (grub_util_warn): New declaration.
1707
1708 * util/i386/pc/grub-install.in: Understand --force and pass it down
1709 to grub-setup.
1710
1711 * util/i386/pc/grub-setup.c (main): Understand --force and pass it
1712 down to setup().
1713 (setup): Improve error messages and add warnings when requested to
1714 install in odd layouts. Refuse to install using blocklists unless
1715 --force was set.
1716
1717 2009-05-04 martin f. krafft <madduck@madduck.net>
1718
1719 * disk/raid.c (grub_raid_scan_device): Improve debug message.
1720
1721 2009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
1722
1723 Updated copyright year
1724
1725 * fs/hfsplus.c: updated copyright year
1726
1727 2009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
1728
1729 HFS+ UUID
1730
1731 * fs/hfsplus.c (grub_hfsplus_volheader): added num_serial field
1732 in the space previously used by unused3
1733 (grub_hfsplus_uuid): new function
1734 (grub_hfsplus_fs): added uuid field
1735
1736 2009-05-03 Pavel Roskin <proski@gnu.org>
1737
1738 * disk/ata.c: Don't cast mod to void in GRUB_MOD_INIT to
1739 suppress warnings. It's no longer needed.
1740 * disk/host.c: Likewise.
1741 * disk/ata_pthru.c: Likewise.
1742 * disk/loopback.c: Likewise.
1743 * hook/datehook.c: Likewise.
1744 * parttool/pcpart.c: Likewise.
1745 * fs/i386/pc/pxe.c: Likewise.
1746 * fs/ntfscomp.c: Likewise.
1747 * efiemu/main.c: Likewise.
1748 * mmap/mmap.c: Likewise.
1749 * commands/crc.c: Likewise.
1750 * commands/hexdump.c: Likewise.
1751 * commands/hdparm.c: Likewise.
1752 * commands/acpi.c: Likewise.
1753 * commands/echo.c: Likewise.
1754 * commands/minicmd.c: Likewise.
1755 * commands/blocklist.c: Likewise.
1756 * commands/memrw.c: Likewise.
1757 * commands/loadenv.c: Likewise.
1758 * commands/usbtest.c: Likewise.
1759 * commands/lsmmap.c: Likewise.
1760 * commands/boot.c: Likewise.
1761 * commands/parttool.c: Likewise.
1762 * commands/configfile.c: Likewise.
1763 * commands/search.c: Likewise.
1764 * commands/ieee1275/suspend.c: Likewise.
1765 * commands/cat.c: Likewise.
1766 * commands/i386/pc/pxecmd.c: Likewise.
1767 * commands/i386/pc/play.c: Likewise.
1768 * commands/i386/pc/halt.c: Likewise.
1769 * commands/i386/pc/vbeinfo.c: Likewise.
1770 * commands/i386/pc/vbetest.c: Likewise.
1771 * commands/lspci.c: Likewise.
1772 * commands/date.c: Likewise.
1773 * commands/handler.c: Likewise.
1774 * commands/ls.c: Likewise.
1775 * commands/test.c: Likewise.
1776 * commands/cmp.c: Likewise.
1777 * commands/efi/loadbios.c: Likewise.
1778 * commands/efi/fixvideo.c: Likewise.
1779 * commands/halt.c: Likewise.
1780 * commands/help.c: Likewise.
1781 * commands/reboot.c: Likewise.
1782 * hello/hello.c: Likewise.
1783 * script/sh/main.c: Likewise.
1784 * loader/xnu.c: Likewise.
1785 * term/terminfo.c: Likewise.
1786 * term/i386/pc/serial.c: Likewise.
1787 * term/usb_keyboard.c: Likewise.
1788
1789 2009-05-03 David S. Miller <davem@davemloft.net>
1790
1791 * normal/menu.c: Include grub/parser.h
1792
1793 2009-05-03 Pavel Roskin <proski@gnu.org>
1794
1795 * mmap/efi/mmap.c (grub_mmap_malign_and_register): Return void*,
1796 not char*.
1797 * mmap/i386/mmap.c (grub_mmap_malign_and_register): Likewise.
1798 Suggested by Javier Martín <lordhabbit@gmail.com>
1799
1800 * util/i386/pc/grub-mkrescue.in: Allow for the case when
1801 efiemu??.o doesn't exist.
1802 * util/i386/pc/grub-install.in: Likewise. Use "cp -f" for
1803 copying.
1804
1805 2009-05-03 Bean <bean123ch@gmail.com> Vladimir Serbinenko <phcoder@gmail.com>
1806
1807 FreeBSD 64-bit support
1808
1809 * conf/i386-pc.rmk (bsd_mod_SOURCES): add loader/i386/bsd_helper.S
1810 and loader/i386/bsd_trampoline.S
1811 (bsd_mod_ASFLAGS): new variable
1812 * include/grub/i386/bsd.h (FREEBSD_MODINFOMD_SMAP): new definition
1813 (FREEBSD_MODTYPE_KERNEL64): likewise
1814 (grub_bsd64_trampoline_start): likewise
1815 (grub_bsd64_trampoline_end): likewise
1816 (grub_bsd64_trampoline_selfjump): likewise
1817 (grub_bsd64_trampoline_gdt): likewise
1818 * include/grub/i386/loader.h (grub_unix_real_boot): moved from here ...
1819 * include/grub/i386/bsd.h (grub_unix_real_boot): ... moved here
1820 * kern/i386/loader.S (grub_unix_real_boot): moved from here ...
1821 * loader/i386/bsd_helper.S (grub_unix_real_boot): moved here
1822 * include/grub/gpt_partition.h (grub_gpt_partentry): Corrected the type
1823 of "attrib" member
1824 * loader/i386/bsd_pagetable.c: new file
1825 * loader/i386/bsd_trampoline.S: likewise
1826 * loader/i386/bsd.c (ALIGN_QWORD): new macro
1827 (ALIGN_VAR): likewise
1828 (entry_hi): new variable
1829 (kern_end_mdofs): likewise
1830 (is_64bit): likewise
1831 (grub_freebsd_add_meta): use ALIGN_VAR
1832 (grub_e820_mmap): new declaration
1833 (grub_freebsd_add_mmap): new function
1834 (grub_freebsd_add_meta_module): support 64 bit kernels
1835 (grub_freebsd_list_modules): use ALIGN_VAR
1836 (gdt_descriptor): new declaration
1837 (grub_freebsd_boot): support 64 bit kernels
1838 (grub_bsd_elf64_hook): new function
1839 (grub_bsd_load_elf): support elf64
1840
1841 2009-05-03 Bean <bean123ch@gmail.com>
1842
1843 * script/sh/execute.c (grub_script_execute_cmdif): Reset grub_errno
1844 after we get the result of if statement.
1845
1846 2009-05-03 Bean <bean123ch@gmail.com>
1847
1848 * Makefile.in (enable_efiemu): New variable.
1849
1850 * conf/i386-pc.rmk: Only compile efiemu runtimes when enable_efiemu is
1851 set.
1852 (efiemu32.o): Use macro $< for source file, add $(srcdir) to include
1853 path.
1854 (efi64_c.o): Use macro $< for source file, add $(srcdir) to include
1855 path, add -mno-red-zone option.
1856 (efiemu64_s.o): Likewise.
1857 (efiemu64.o): Use macro $^ for source file.
1858
1859 * configure.ac (--enable-efiemu): New option.
1860
1861 2009-05-03 Vladimir Serbinenko <phcoder@gmail.com>
1862
1863 xnu support
1864
1865 * conf/i386-efi.rmk (kernel_mod_HEADERS): added i386/pit.h
1866 (pkglib_MODULES): add xnu.mod
1867 (xnu_mod_SOURCES): new variable
1868 (xnu_mod_CFLAGS): likewise
1869 (xnu_mod_LDFLAGS): likewise
1870 (xnu_mod_ASFLAGS): likewise
1871 * conf/i386-pc.rmk: likewise
1872 * conf/x86_64-efi.rmk: likewise
1873 * include/grub/efi/efi.h (grub_efi_finish_boot_services):
1874 new declaration
1875 * include/grub/i386/macho.h: new file
1876 * include/grub/i386/xnu.h: likewise
1877 * include/grub/macho.h: likewise
1878 * include/grub/machoload.h: likewise
1879 * include/grub/x86_64/macho.h: likewise
1880 * include/grub/x86_64/xnu.h: likewise
1881 * include/grub/xnu.h: likewise
1882 * kern/efi/efi.c (grub_efi_finish_boot_services): new function
1883 * kern/efi/mm.c (MAX_HEAP_SIZE): increase
1884 * loader/i386/efi/xnu.c: new file
1885 * loader/i386/pc/xnu.c: likewise
1886 * loader/i386/xnu.c: likewise
1887 * loader/i386/xnu_helper.S: likewise
1888 * loader/macho.c: likewise
1889 * loader/xnu.c: likewise
1890 * loader/xnu_resume.c: likewise
1891 * util/grub-dumpdevtree: likewise
1892 * include/grub/i386/pit.h: include grub/err.h
1893 (grub_pit_wait): export
1894 * util/grub.d/30_os-prober.in: support Darwin/Mac OS X
1895
1896 2009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
1897
1898 Efiemu
1899
1900 * conf/i386-pc.rmk: new modules efiemu, efiemu_acpi, efiemu_pnvram,
1901 _linux_efi, linux_efi.
1902 new files in grub-emu
1903 new targets efiemu32.o and efiemu64.o
1904 * loader/linux_normal_efiemu.c: likewise
1905 * loader/i386/efi/linux.c: added preliminary efiemu support
1906 * util/i386/pc/grub-install.in: add efiemu??.o to the list of
1907 files to copy
1908 * include/grub/autoefi.h: new file
1909 * include/grub/i386/efiemu.h: likewise
1910 * include/grub/i386/pc/efiemu.h: likewise
1911 * include/grub/efi/api.h: add LL suffix when necessary
1912 new definitions relating to tables
1913 * include/grub/efiemu/efiemu.h: new file
1914 * include/grub/efiemu/runtime.h: likewise
1915 * efiemu/prepare.c: likewise
1916 * efiemu/loadcore_common.c: likewise
1917 * efiemu/loadcore64.c: likewise
1918 * efiemu/runtime/efiemu.sh: likewise
1919 * efiemu/runtime/efiemu.S: likewise
1920 * efiemu/runtime/efiemu.c: likewise
1921 * efiemu/runtime/config.h: likewise
1922 * efiemu/prepare32.c: likewise
1923 * efiemu/main.c: likewise
1924 * efiemu/modules/pnvram.c: likewise
1925 * efiemu/modules/i386: likewise
1926 * efiemu/modules/i386/pc: likewise
1927 * efiemu/modules/acpi.c: likewise
1928 * efiemu/i386/pc/cfgtables.c: likewise
1929 * efiemu/i386/loadcore64.c: likewise
1930 * efiemu/i386/loadcore32.c: likewise
1931 * efiemu/prepare64.c: likewise
1932 * efiemu/loadcore.c: likewise
1933 * efiemu/symbols.c: likewise
1934 * efiemu/mm.c: likewise
1935 * efiemu/loadcore32.c: likewise
1936
1937 2009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
1938
1939 ACPI spoofing
1940
1941 * commands/acpi.c: new file
1942 * commands/i386/pc/acpi.c: likewise
1943 * commands/efi/acpi.c: likewise
1944 * include/grub/acpi.h: likewise
1945 * conf/i386-pc.rmk (pkglib_MODULES): added acpi.mod
1946 (acpi_mod_SOURCES): new variable
1947 (acpi_mod_CFLAGS): likewise
1948 (acpi_mod_LDFLAGS): likewise
1949 * conf/i386-efi.rmk: likewise
1950 * conf/x86_64-efi.rmk: likewise
1951
1952 2009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
1953
1954 Missing part from mmap patch
1955
1956 * mmap/efi/mmap.c (grub_machine_mmap_unregister): renamed to
1957 (grub_mmap_unregister)
1958 (grub_mmap_free_and_unregister): use grub_mmap_register
1959
1960 2009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
1961
1962 Mmap services
1963
1964 * loader/i386/efi/linux.c (grub_linux_boot): use grub_mmap_iterate
1965 * loader/i386/linux.c (find_mmap_size): likewise
1966 (allocate_pages): likewise
1967 * loader/i386/multiboot.c (grub_get_multiboot_mmap_len): likewise
1968 (grub_fill_multiboot_mmap): likewise
1969 (grub_multiboot): use grub_mmap_get_lower and grub_mmap_get_upper
1970 * loader/i386/pc/linux.c (grub_cmd_linux): use grub_mmap_get_lower
1971 * include/grub/i386/bsd.h (OPENBSD_MMAP_AVAILABLE): new definition
1972 (OPENBSD_MMAP_RESERVED): likewise
1973 * include/grub/i386/pc/memory.h: include grub/memory.h
1974 (grub_lower_mem): removed
1975 (grub_upper_mem): likewise
1976 (GRUB_MACHINE_MEMORY_ACPI): new definition
1977 (GRUB_MACHINE_MEMORY_NVS): likewise
1978 (GRUB_MACHINE_MEMORY_MAX_TYPE): likewise
1979 (GRUB_MACHINE_MEMORY_HOLE): likewise
1980 (grub_machine_mmap_register): likewise
1981 (grub_machine_mmap_unregister): likewise
1982 (grub_machine_get_upper): likewise
1983 (grub_machine_get_lower): likewise
1984 (grub_machine_get_post64): likewise
1985 * include/grub/i386/efi/memory.h: new file
1986 * include/grub/x86_64/efi/memory.h: likewise
1987 * include/grub/efi/memory.h: likewise
1988 * conf/i386-pc.rmk (pkglib_MODULES): added mmap.mod
1989 (mmap_mod_SOURCES): new variable
1990 (mmap_mod_LDFLAGS): likewise
1991 (mmap_mod_ASFLAGS): likewise
1992 * conf/i386-coreboot.rmk: likewise
1993 * conf/i386-ieee1275.rmk: likewise
1994 * conf/i386-efi.rmk: likewise
1995 * conf/x86_64-efi.rmk: likewise
1996 * include/grub/types.h (UINT_TO_PTR): new macro
1997 (PTR_TO_UINT32): likewise
1998 (PTR_TO_UINT64): likewise
1999 * include/grub/memory.h: new file
2000 * mmap/i386/pc/mmap.c: likewise
2001 * mmap/i386/pc/mmap_helper.S: likewise
2002 * mmap/i386/uppermem.c: likewise
2003 * mmap/mmap.c: likewise
2004 * mmap/efi/mmap.c: likewise
2005 * kern/i386/coreboot/init.c (grub_machine_init): don't use
2006 grub_upper_mem
2007 * kern/i386/pc/init.c (grub_lower_mem): removed variable
2008 (grub_upper_mem): likewise
2009 (grub_machine_init): don't use grub_upper_mem,
2010 make grub_lower_mem local
2011 * loader/i386/bsd.c (grub_openbsd_boot): use grub_mmap_get_lower,
2012 grub_mmap_iterate and grub_mmap_get_upper
2013 (grub_netbsd_boot): use grub_mmap_get_lower and grub_mmap_get_upper
2014
2015 2009-05-02 Bean <bean123ch@gmail.com>
2016
2017 * conf/common.rmk (grub_script.tab.c): Change normal/parser.y to
2018 script/sh/parser.y.
2019 (pkglib_MODULES): Add normal.mod and sh.mod.
2020 (normal_SOURCES): New variable.
2021 (normal_mod_CFLAGS): Likewise.
2022 (normal_mod_LDFLAGS): Likewise.
2023 (sh_mod_SOURCES): Likewise.
2024 (sh_mod_CFLAGS): Likewise.
2025 (sh_mod_LDFLAGS): Likewise.
2026
2027 * conf/i386-pc.rmk (normal/lexer.c_DEPENDENCIES): Changed to
2028 script/sh/lexer.c_DEPENDENCIES.
2029 (kernel_img_SOURCES): Remove kern/rescue.c, and kern/reader.c,
2030 kern/rescue_reader.c and kern/rescue_parser.c.
2031 (kernel_img_HEADERS): Remove rescue.h, add reader.h.
2032 (grub_emu_SOURCES): Change source files.
2033 (pkglib_MODULES): Remove normal.mod.
2034 (normal_SOURCES): Removed.
2035 (normal_mod_CFLAGS): Likewise.
2036 (normal_mod_LDFLAGS): Likewise.
2037 * conf/i386-coreboot.rmk: Likewise.
2038 * conf/i386-efi.rmk: Likewise.
2039 * conf/i386-ieee1276.rmk: Likewise.
2040 * conf/powerpc-ieee1275.rmk: Likewise.
2041 * conf/sparc64-ieee1275.rmk: Likewise.
2042 * conf/x86_64-efi.rmk: Likewise.
2043
2044 * include/grub/command.h (grub_command_execute): New inline function.
2045
2046 * include/grub/menu.h (grub_menu_entry): Removed commands field.
2047
2048 * include/grub/normal.h: Remove <grub/setjmp.h>.
2049 (grub_fs_module_list): Moved to normal/autofs.c.
2050 (grub_exit_env): Removed.
2051 (grub_command_execute): Likewise.
2052 (grub_normal_menu_addentry): Renamed to grub_menu_addentry, removed
2053 parameter script.
2054 (read_command_list): New function declaration.
2055 (read_fs_list): Likewise.
2056
2057 * include/parser.h: Include <grub/reader.h>.
2058 (grub_parser_split_cmdline): Change type of getline parameter.
2059 (grub_parser): New structure.
2060 (grub_parser_class): New variable.
2061 (grub_parser_execute): New function declaration.
2062 (grub_register_rescue_parser): Likewise.
2063 (grub_parser_register): New inline function.
2064 (grub_parser_unregister): Likewise.
2065 (grub_parser_get_current): Likewise.
2066 (grub_parser_set_current): Likewise.
2067
2068 * include/grub/reader.h: New file.
2069 * kern/reader.c: Likewise.
2070 * kern/rescue_parser.c: Likewise.
2071 * kern/rescue_reader.c: Likewise.
2072 * normal/autofs.c: Likewise.
2073 * normal/dyncmd.c: Likewise.
2074
2075 * include/grub/rescue.h: Removed.
2076 * normal/command.h: Likewise.
2077
2078 * include/grub/script.h: Moved to ...
2079 * include/grub/script_sh.h: ... Moved here.
2080 * normal/execute.c: Moved to ...
2081 * script/sh/execute.c: ... Moved here.
2082 * normal/function.c: Moved to ...
2083 * script/sh/function.c: ... Moved here.
2084 * normal/lexer.c: Moved to ...
2085 * script/sh/lexer.c: ... Moved here.
2086 * normal/parser.y: Moved to ...
2087 * script/sh/parser.y: ... Moved here.
2088 * normal/script.c: Moved to ...
2089 * script/sh/script.c: ... Moved here.
2090
2091 * normal/main.c: Remove <grub/rescue.h> and <grub/script.h>, include
2092 <grub/reader.h>.
2093 (grub_exit_env): Removed.
2094 (fs_module_list): Moved to normal/autofs.c.
2095 (grub_file_getline): Don't handle comment here.
2096 (free_menu): Skip removed field entry->commands.
2097 (grub_normal_menu_addentry): Removed as grub_menu_entry, removed
2098 script parameter.
2099 (read_config_file): Removed nested parameter, change getline function.
2100 (grub_enter_normal_mode): Removed.
2101 (grub_dyncmd_dispatcher): Moved to normal/dyncmd.c.
2102 (read_command_list): Likewise.
2103 (autoload_fs_module): Moved to normal/autofs.c.
2104 (read_fs_list): Likewise.
2105 (reader_nested): New variable.
2106 (grub_normal_execute): Run parser.sh to switch to sh parser.
2107 (grub_cmd_rescue): Removed.
2108 (cmd_normal): Removed.
2109 (grub_cmd_normal): Unregister itself at the beginning. Don't register
2110 rescue command.
2111 (grub_cmdline_run): New function.
2112 (grub_normal_reader_init): Likewise.
2113 (grub_normal_read_line): Likewise.
2114 (grub_env_write_pager): Likewise.
2115 (cmdline): New variable.
2116 (grub_normal_reader): Likewise.
2117 (GRUB_MOD_INIT): Register normal reader and set as current, register
2118 pager hook, register normal command with grub_register_command_prio,
2119 so that it won't show up in command.lst.
2120 (GRUB_MOD_FINI): Unregister normal reader, unhook pager, clear
2121 grub_fs_autoload_hook.
2122
2123 * normal/menu.c: Remove <grub/script.h>, add <grub/command.h>.
2124 (grub_menu_execute_entry): Replace grub_script_execute with
2125 grub_parser_execute, change parameter to grub_command_execute.
2126
2127 * normal/menu_text.c: Remove <grub/script.h>.
2128
2129 * normal/menu_entry.c: Remove <grub/script.h>, add <grub/command.h>
2130 and <grub/parser.h>.
2131 (run): Change editor_getline to use new parser interface. Change
2132 parameter to grub_command_execute.
2133
2134 * kern/main.c: Remove <grub/rescue.h>, include <grub/command.h>,
2135 <grub/reader.h> and <grub/parser.h>.
2136 (grub_load_normal_mode): Execute normal command.
2137 (grub_main): Call grub_register_core_commands,
2138 grub_register_rescue_parser and grub_register_rescue_reader, use
2139 grub_reader_loop to enter input loop.
2140
2141 * kern/parser.c (grub_parser_split_cmdline): Change type of
2142 getline parameter.
2143 (grub_parser_class): New variable.
2144 (grub_parser_execute): New function.
2145
2146 * loader/i386/multiboot.c: Remove <grub/rescue.h>.
2147 * loader/multiboot2.c: Likewise.
2148 * loader/sparc64/ieee1275/linux.c: Likewise.
2149
2150 * util/grub-emu.c (read_command_list): New dummy function.
2151
2152 2009-05-02 Robert Millan <rmh.grub@aybabtu.com>
2153
2154 * util/deviceiter.c (grub_util_iterate_devices): Increase max drive
2155 count to 16 for CCISS and IDA.
2156
2157 2009-05-02 Robert Millan <rmh.grub@aybabtu.com>
2158
2159 * normal/menu_text.c (grub_wait_after_message): Print a newline
2160 after waiting for user input.
2161
2162 * loader/i386/linux.c: Include `<grub/normal.h>'.
2163 (grub_cmd_linux): Improve the error message about `ask' mode, by
2164 waiting for user input so it's not missed (we can do this, since
2165 user requested interaction).
2166
2167 2009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
2168
2169 Added missing lst to grub-mkrescue
2170
2171 * util/i386/pc/grub-mkrescue.in: added ${input_dir}/handler.lst
2172 and ${input_dir}/parttool.lst
2173
2174 2009-04-30 David S. Miller <davem@davemloft.net>
2175
2176 * util/hostdisk.c (device_is_wholedisk): New function.
2177 (grub_util_biosdisk_get_grub_dev): Shortcut when hdg.start is
2178 zero only if device_is_wholedisk() returns true.
2179
2180 * util/hostdisk.c (convert_system_partition_to_system_disk):
2181 Handle virtual disk devices named /dev/vdiskX as found on sparc
2182 and powerpc.
2183
2184 * kern/sparc64/ieee1275/init.c (grub_machine_set_prefix): If
2185 lettered partition specifier is found, convert to numbered.
2186
2187 2009-04-29 David S. Miller <davem@davemloft.net>
2188
2189 * include/grub/powerpc/ieee1275/memory.h: Include ieee1275.h.
2190 * include/grub/sparc64/ieee1275/memory.h: Likewise.
2191
2192 * normal/command.c: Add missing newline at end of file.
2193
2194 * commands/lsmmap.c (grub_cmd_lsmmap): Add casts to avoid printf
2195 warnings.
2196 * kern/ieee1275/openfw.c (grub_claimmap): Likewise.
2197 * disk/ieee1275/ofdisk.c (grub_ofdisk_open, grub_ofdisk_close,
2198 grub_ofdisk_read): Likewise, and deal similarly with the fact that
2199 ihandles have a 32-bit type but need to be stored in a "void *".
2200
2201 2009-04-28 Pavel Roskin <proski@gnu.org>
2202
2203 * disk/fs_uuid.c (grub_fs_uuid_open): Use parent->data for dev,
2204 not disk. Adjust all dependencies.
2205 (grub_fs_uuid_close): Use grub_device_close(), not
2206 grub_disk_close().
2207
2208 * disk/fs_uuid.c (grub_fs_uuid_open): Allocate memory to copy
2209 parent's partition, don't copy it by reference, as it gets freed
2210 on close.
2211
2212 2009-04-27 Vladimir Serbinenko <phcoder@gmail.com>
2213
2214 Preboot hooks support
2215
2216 * commands/boot.c (struct grub_preboot_t): new declaration
2217 (preboots_head): new variable
2218 (preboots_tail): likewise
2219 (grub_loader_register_preboot_hook): new function
2220 (grub_loader_unregister_preboot_hook): likewise
2221 (grub_loader_set): launch preboot hooks
2222 * include/grub/loader.h (grub_loader_preboot_hook_prio_t): new type
2223 (grub_loader_register_preboot_hook): new declaration
2224 (grub_loader_unregister_preboot_hook): likewise
2225
2226 2009-04-27 Vladimir Serbinenko <phcoder@gmail.com>
2227
2228 Warning fix
2229
2230 * disk/scsi.c (grub_scsi_open): added missing cast when
2231 calling grub_dprintf
2232
2233 2009-04-26 Vladimir Serbinenko <phcoder@gmail.com>
2234
2235 Bug and warning fixes
2236
2237 * include/grub/i386/pc/init.h (grub_stop_floppy): added missing
2238 declaration
2239 * commands/test.c (test_parse): fixed bug with file tests and corrected
2240 declaration of find_file
2241
2242 2009-04-26 Pavel Roskin <proski@gnu.org>
2243
2244 * Makefile.in: Don't install empty manual pages if help2man is
2245 missing. Use help2man option for output, not shell redirection.
2246
2247 2009-04-26 David S. Miller <davem@davemloft.net>
2248
2249 * util/grub-mkdevicemap.c (make_device_map): Add missing
2250 NESTED_FUNC_ATTR to process_device().
2251
2252 2009-04-25 Vladimir Serbinenko <phcoder@gmail.com>
2253
2254 Test command
2255
2256 * commands/test.c: rewritten to use bash-like test
2257
2258 2009-04-25 Vladimir Serbinenko <phcoder@gmail.com>
2259
2260 Parttool autoloading and improvements
2261
2262 * Makefile.in (pkglib_DATA): add parttool.lst
2263 (parttool.lst): new target
2264 * genmk.rb: generate parttool-*
2265 (CLEANFILES): add #{parttool}
2266 (PARTTOOLFILES): new variable
2267 * genparttoollist.sh: new file
2268 * parttool/pcpart.c (grub_pcpart_boot): more feedback
2269 (grub_pcpart_type): likewise
2270 * commands/parttool.c (helpmsg): new variable
2271 (grub_cmd_parttool): output help if not enough arguments are supplied
2272 autoload modules
2273 (GRUB_MOD_INIT(parttool)): use helpmsg
2274
2275 2009-04-24 David S. Miller <davem@davemloft.net>
2276
2277 Avoiding opening same device multiple times in device iterator.
2278
2279 * kern/device.c: (grub_device_iterate): Define struct part_ent,
2280 and use it to build a list of partitions in iterate_disk() and
2281 iterate_partition().
2282
2283 * disk/fs_uuid.c (grub_fs_uuid_close): Call grub_disk_close()
2284 on disk->data.
2285
2286 * disk/ieee1275/nand.c (grub_nand_iterate): Return
2287 grub_devalias_iterate() result instead of unconditional 0.
2288 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Likewise.
2289 Also, capture hook return value, either directly or via
2290 grub_children_iterate(), and propagate to caller.
2291 * include/grub/ieee1275/ieee1275.h (grub_devalias_iterate,
2292 grub_children_iterate): Return value is now 'int' instead of
2293 'grub_err_t'.
2294 * kern/ieee1275/openfw.c (grub_children_iterate): Fix to behave
2295 like a proper iterator, stopping when hooks return non-zero.
2296 (grub_devalias_iterate): Likewise.
2297
2298 2009-04-23 David S. Miller <davem@davemloft.net>
2299
2300 * kern/sparc64/ieee1275/openfw.c: Unused, delete.
2301
2302 2009-04-22 David S. Miller <davem@davemloft.net>
2303
2304 * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): If size_cells
2305 is larger than address_cells, use that value for address_cells too.
2306
2307 * include/grub/ieee1275/ieee1275.h (IEEE1275_MAX_PROP_LEN,
2308 IEEE1275_MAX_PATH_LEN): Define.
2309 * kern/ieee1275/openfw.c (grub_children_iterate): Dynamically
2310 allocate 'childtype', 'childpath', 'childname', and 'fullname'.
2311 (grub_devalias_iterate): Dynamically allocate 'aliasname' and
2312 'devtype'. Explicitly NULL terminate devalias expansion.
2313
2314 * util/sparc64/ieee1275/misc.c: New file.
2315 * util/sparc64/ieee1275/grub-setup.c: New file.
2316 * util/sparc64/ieee1275/grub-ofpathname.c: New file.
2317 * util/sparc64/ieee1275/grub-mkimage.c: New file.
2318 * util/sparc64/ieee1275/grub-install.in: New file.
2319 * util/ieee1275/ofpath.c: New file.
2320 * util/ieee1275/devicemap.c: New file.
2321 * util/devicemap.c: New file.
2322 * util/deviceiter.c: New file.
2323 * kern/sparc64/ieee1275/init.c: New file.
2324 * include/grub/util/ofpath.h: New file.
2325 * include/grub/util/deviceiter.h: New file.
2326 * util/grub-mkdevicemap.c: Include deviceiter.h.
2327 Implement using grub_util_emit_devicemap_entry and
2328 grub_util_iterate_devices.
2329 * conf/i386-corebook.rmk: Build util/deviceiter.c and
2330 util/devicemap.c into grub-mkdevicemap
2331 * conf/i386-efi.rmk: Likewise.
2332 * conf/i386-ieee1275.rmk: Likewise.
2333 * conf/i386-pc.rmk: Likewise.
2334 * conf/powerpc-ieee1275.rmk: Likewise.
2335 * conf/sparc64-ieee1275.rmk: Add rules to build boot block
2336 images and installation utilities. Build kernel as image
2337 instead of as elf binary. Use common rules as much as possible.
2338
2339 2009-04-19 Vladimir Serbinenko <phcoder@gmail.com>
2340
2341 Correct GPT definition
2342
2343 * include/grub/gpt_partition.h (grub_gpt_partentry): Corrected the type
2344 of "attrib" member
2345
2346 2009-04-19 Felix Zielcke <fzielcke@z-51.de>
2347
2348 * INSTALL: Replace `autogen.sh' with `./autogen.sh'.
2349
2350 2009-04-19 David S. Miller <davem@davemloft.net>
2351
2352 * loader/sparc64/ieee1275/linux.c: Include grub/command.h
2353 (grub_rescue_cmd_linux): Rename to...
2354 (grub_cmd_linux): and fix prototype.
2355 (grub_rescue_cmd_initrd): Rename to...
2356 (grub_cmd_initrd): and fix prototype.
2357 (cmd_linux, cmd_initrd): New.
2358 (GRUB_MOD_INIT(linux)): Use grub_register_command().
2359 (GRUB_MOD_FINI(linux): Use grub_unregister_command().
2360
2361 2009-04-17 Pavel Roskin <proski@gnu.org>
2362
2363 * bus/usb/ohci.c (grub_ohci_transaction): Fix incorrect printf
2364 format.
2365 (grub_ohci_transfer): Likewise.
2366
2367 * bus/usb/usbtrans.c (grub_usb_control_msg): Warning fix.
2368
2369 * loader/multiboot_loader.c (grub_cmd_multiboot_loader): Fix
2370 return without a value. Fix inconsistent indentation.
2371
2372 * fs/i386/pc/pxe.c (grub_pxefs_dir): Fix function prototype to
2373 match struct grub_fs.
2374
2375 * disk/ata.c (grub_ata_pciinit): Use NESTED_FUNC_ATTR.
2376 * bus/usb/ohci.c (grub_ohci_pci_iter): Likewise.
2377 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
2378 * commands/lspci.c (grub_lspci_iter): Likewise.
2379
2380 2009-04-16 Bean <bean123ch@gmail.com>
2381
2382 * commands/efi/loadbios.c (grub_cmd_fakebios): Add missing return
2383 value.
2384
2385 2009-04-15 Pavel Roskin <proski@gnu.org>
2386
2387 * include/grub/types.h: Rename ULONG_MAX to GRUB_ULONG_MAX and
2388 LONG_MAX to GRUB_LONG_MAX. Introduce GRUB_LONG_MIN. Update all
2389 users of ULONG_MAX, LONG_MAX and LONG_MIN to use the new
2390 definitions.
2391
2392 2009-04-15 Felix Zielcke <fzielcke@z-51.de>
2393
2394 * disk/lvm.c (grub_lvm_scan_device): Add `LVM' to the error messages,
2395 that no multiple data or metadata areas are supported and `Unknown
2396 metadata header'.
2397
2398 2009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
2399
2400 Move loader out of the kernel
2401
2402 * kern/loader.c: moved to ...
2403 * commands/boot.c: ... moved here
2404 * commands/minicmd.c (grub_mini_cmd_boot): moved to ...
2405 * commands/boot.c (grub_cmd_boot): moved here. All users updated
2406 * include/grub/kernel.h (grub_machine_fini): export
2407 * include/grub/loader.h (grub_loader_is_loaded): update declaration
2408 (grub_loader_set): likewise
2409 (grub_loader_unset): likewise
2410 (grub_loader_boot): likewise
2411 * conf/common.rmk: new module boot.mod
2412 (pkglib_MODULES): add boot.mod
2413 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): remove kern/loader.c
2414 (grub_emu_SOURCES): likewise
2415 * conf/i386-efi.rmk (kernel_elf_SOURCES): likewise
2416 (grub_emu_SOURCES): likewise
2417 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): likewise
2418 (grub_emu_SOURCES): likewise
2419 * conf/i386-pc.rmk (kernel_elf_SOURCES): likewise
2420 (grub_emu_SOURCES): likewise
2421 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): likewise
2422 (grub_emu_SOURCES): likewise
2423 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): likewise
2424 (grub_emu_SOURCES): likewise
2425 * conf/x86_64-efi.rmk (kernel_elf_SOURCES): likewise
2426 (grub_emu_SOURCES): likewise
2427
2428 2009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
2429
2430 use grub_lltoa instead of grub_itoa and grub_ltoa for all purposes
2431
2432 * kern/misc.c (grub_itoa): Removed function
2433 (grub_ltoa): likewise
2434 (grub_vsprintf): use grub_lltoa
2435
2436 2009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
2437
2438 Restore grub-emu
2439
2440 * conf/i386-pc.rmk (grub_emu_SOURCES): add normal/handler.c
2441 * conf/i386-coreboot.rmk: likewise
2442 * conf/i386-ieee1275.rmk: likewise
2443 * conf/powerpc-ieee1275.rmk: likewise
2444
2445 2009-04-15 Felix Zielcke <fzielcke@z-51.de>
2446
2447 * INSTALL: Add that `./autogen.sh' needs to be run before
2448 `./configure.'.
2449
2450 2009-04-14 Bean <bean123ch@gmail.com>
2451
2452 * Makefile.in (pkglib_DATA): Add handler.lst.
2453 (handler.lst): New rule.
2454
2455 * conf/i386-pc.rmk (normal_mod_SOURCES): Add normal/handler.c.
2456 * conf/i386-coreboot.rmk: Likewise.
2457 * conf/i386-ieee1275.rmk: Likewise.
2458 * conf/i386-efi.rmk: Likewise.
2459 * conf/x86_64-efi.rmk: Likewise.
2460 * conf/powerpc-ieee1275.rmk: Likewise.
2461 * conf/sparc64-ieee1275.rmk: Likewise.
2462
2463 * genhandlerlist.sh: New file.
2464
2465 * genmk.rb: Add rules to generate handler.lst.
2466
2467 * include/grub/normal.h (grub_file_getline): New function definition.
2468 (read_handler_list): Likewise.
2469 (free_handler_list): Likewise.
2470
2471 * include/grub/term.h (grub_term_register_input): Add name parameter
2472 for auto generation of handler.lst.
2473 (grub_term_register_output): Likewise.
2474
2475 * normal/handler.c: New file.
2476
2477 * normal/main.c (get_line): Renamed to grub_file_getline.
2478 (read_config_file): Use the newly renamed grub_file_getline.
2479 (read_command_list): Likewise.
2480 (read_fs_list): Likewise.
2481 (grub_normal_execute): Call read_handler_list to parse handler.lst.
2482 (GRUB_MOD_FINI): Call free_handler_list to free handler list.
2483
2484 * term/efi/console.c (grub_console_init): Add name parameter for auto
2485 generation of handler.lst.
2486 * term/gfxterm.c: Likewise.
2487 * term/i386/pc/at_keyboard.c: Likewise.
2488 * term/i386/pc/console.c: Likewise.
2489 * term/i386/pc/serial.c: Likewise.
2490 * term/i386/pc/vesafb.c: Likewise.
2491 * term/i386/pc/vga.c: Likewise.
2492 * term/i386/pc/vga_text.c: Likewise.
2493 * term/ieee1275/ofconsole.c: Likewise.
2494 * term/usb_keyboard.c: Likewise.
2495
2496 2009-04-14 Bean <bean123ch@gmail.com>
2497
2498 * util/grub-pe2elf.c (write_symbol_table): Terminate short name symbol
2499 properly with null character.
2500
2501 2009-04-14 Felix Zielcke <fzielcke@z-51.de>
2502
2503 * configure: Remove.
2504 * config.h.in: Likewise.
2505 * stamp-h.in: Likewise.
2506 * DISTLIST: Likewise.
2507 * conf/common.mk: Likewise.
2508 * conf/i386-coreboot.mk: Likewise.
2509 * conf/i386-efi.mk: Likewise.
2510 * conf/i386-ieee1275.mk: Likewise.
2511 * conf/i386.mk: Likewise.
2512 * conf/i386-pc.mk: Likewise.
2513 * conf/powerpc-ieee1275.mk: Likewise.
2514 * conf/sparc64-ieee1275.mk: Likewise.
2515 * conf/x86_64-efi.mk: Likewise.
2516
2517 * INSTALL: Remove the sentence that Ruby and autoconf are only required if you
2518 develop on GRUB.
2519
2520 2009-04-14 John Stanley <jpsinthemix@verizon.net>
2521 David S. Miller <davem@davemloft.net>
2522
2523 * util/hostdisk.c (make_device_name): Fix buffer length
2524 calculations.
2525
2526 2009-04-14 Felix Zielcke <fzielcke@z-51.de>
2527
2528 * util/hostdisk.c [__FreeBSD__ || __FreeBSD_kernel__]: Include
2529 <sys/param.h> and <sys/sysctl.h>.
2530 (open_device) [__FreeBSD__ || __FreeBSD_kernel_]: Use sysctlgetbyname()
2531 to add 0x10 to `kern.geom.debugflags' if it's not already set, before
2532 opening the device and reset them afterwards.
2533
2534 2009-04-13 Pavel Roskin <proski@gnu.org>
2535
2536 * conf/common.rmk (grub_fstest_SOURCES): Add normal/datetime.c.
2537 Reported by John Stanley <jpsinthemix@verizon.net>
2538
2539 2009-04-13 Robert Millan <rmh@aybabtu.com>
2540
2541 * util/grub.d/10_freebsd.in: Detect Debian GNU/kFreeBSD and use
2542 that name for menuentries when appropriate.
2543
2544 2009-04-13 Felix Zielcke <fzielcke@z-51.de>
2545
2546 * util/grub.d/10_freebsd.in: Add a missing `fi'.
2547
2548 2009-04-13 Robert Millan <rmh@aybabtu.com>
2549
2550 * loader/i386/linux.c (grub_cmd_linux): Don't pass `vga=ask' parameter
2551 to Linux, simply abort telling the user it's no longer supported.
2552
2553 2009-04-13 Felix Zielcke <fzielcke@z-51.de>
2554
2555 * util/grub.d/10_freebsd.in: Don't exit if /boot/devices.hints
2556 doesn't exist. Check also for /boot/kernel/kernel.gz. Print
2557 `freebsd_loadenv' only when devices.hints exist.
2558
2559 2009-04-13 Pavel Roskin <proski@gnu.org>
2560
2561 * term/usb_keyboard.c (grub_usb_keyboard_getkey): Warning fixes.
2562
2563 2009-04-13 Felix Zielcke <fzielcke@z-51.de>
2564
2565 * util/i386/pc/grub-install.in (install_drive): Remove the BSD
2566 partition number.
2567 (grub_drive): Likewise.
2568
2569 2009-04-13 David S. Miller <davem@davemloft.net>
2570
2571 * kern/sparc64/ieee1275/ieee1275.c: New file.
2572 * include/grub/sparc64/ieee1275/ieee1275.h (IEEE1275_MAP_WRITE,
2573 IEEE1275_MAP_READ, IEEE1275_MAP_EXEC, IEEE1275_MAP_LOCKED,
2574 IEEE1275_MAP_CACHED, IEEE1275_MAP_SE, IEEE1275_MAP_GLOBAL,
2575 IEEE1275_MAP_IE, IEEE1275_MAP_DEFAULT): Define.
2576 (grub_ieee1275_map_physical, grub_ieee1275_claim_vaddr,
2577 grub_ieee1275_alloc_physmem): Declare new exported functions.
2578
2579 * include/grub/sparc64/ieee1275/loader.h: New file.
2580 * include/grub/sparc64/ieee1275/memory.h: Likewise.
2581 * include/grub/sparc64/kernel.h: Likewise.
2582 * loader/sparc64/ieee1275/linux.c: Likewise.
2583
2584 * conf/common.rmk (grub_probe_SOURCES): Add Sun partition module.
2585 (grub_fstest_SOURCES): Likewise.
2586
2587 * util/hostdisk.c (make_device_name): Do not make any assumptions
2588 about the length of drive names.
2589
2590 * kern/dl.c (grub_dl_load_file): Close file immediately when
2591 we are done using it.
2592
2593 2009-04-12 David S. Miller <davem@davemloft.net>
2594
2595 * kern/misc.c (grub_ltoa): Fix cast when handling negative
2596 values. Noticed by Pavel Roskin.
2597
2598 * configure.ac: Check for __bswapsi2 and__bswapdi2 using
2599 target compiler.
2600
2601 * genmk.rb: Add more flexible image type specification, also
2602 pass --strip-unneeded to objcopy.
2603 * conf/i386-pc.rmk: Use *_FORMAT.
2604 * conf/i386-pc.mk: Rebuilt.
2605
2606 * disk/ieee1275/ofdisk.c (struct ofdisk_hash_ent): New struct.
2607 (OFDISK_HASH_SZ): Define.
2608 (ofdisk_hash): New hash table.
2609 (ofdisk_hash_fn, ofdisk_hash_find, ofdisk_hash_add): New functions.
2610 (grub_ofdisk_open): Use ofdisk_hash_ent address as disk->id
2611 instead of device phandle which is not unique.
2612
2613 * kern/sparc64/ieee1275/init.c: Delete, replace with...
2614 * kern/sparc64/ieee1275/crt0.S: assembler implementation.
2615 * include/grub/sparc64/ieee1275/kernel.h: Declare grub_prefix[].
2616 (GRUB_MOD_ALIGN, GRUB_MOD_GAP, GRUB_KERNEL_MACHINE_TOTAL_MODULE_SIZE,
2617 GRUB_KERNEL_MACHINE_KERNEL_IMAGE_SIZE,
2618 GRUB_KERNEL_MACHINE_COMPRESSED_SIZE, GRUB_KERNEL_MACHINE_PREFIX,
2619 GRUB_KERNEL_MACHINE_DATA_END): Define.
2620 (grub_kernel_image_size, grub_total_module_size): Declare.
2621
2622 2009-04-12 Pavel Roskin <proski@gnu.org>
2623
2624 * configure.ac: Change the logic when we check for target tools.
2625 Do it when the target is specified and it's different from the
2626 specified value of the host.
2627
2628 2009-04-11 Felix Zielcke <fzielcke@z-51.de>
2629
2630 * util/hostdisk.c [__FreeBSD_kernel__]: Include sys/disk.h.
2631 (grub_util_biosdisk_open) [__FreeBSD_kernel__]: Add support for
2632 GNU/kFreeBSD. Check if a device is a character device. Use
2633 DIOCGMEDIASIZE to get the size.
2634 (convert_system_partition_to_system_disk) [__FreeBSD_kernel__]: Add
2635 support for GNU/kFreeBSD.
2636 (grub_util_biosdisk_get_grub_dev) [__FreeBSD_kernel__]: Check if OS_DEV
2637 is a character device instead of a block device. Add support for
2638 FreeBSD device names.
2639
2640 * util/getroot.c (find_root_device) [__FreeBSD_kernel__]: Check if ENT
2641 is a character device instead of a block device.
2642
2643 * util/grub-probe.c (probe) [__FreeBSD_kernel__]: Check if DEVICE_NAME
2644 is a character device instead of a block device.
2645
2646 2009-04-11 Andrey Shuvikov <mr_hyro@yahoo.com>
2647
2648 * util/hostdisk.c [__FreeBSD__]: Include sys/disk.h.
2649 (grub_util_biosdisk_open) [__FreeBSD__]: Add support for
2650 FreeBSD. Check if a device is a character device. Use
2651 DIOCGMEDIASIZE to get the size.
2652 (convert_system_partition_to_system_disk) [__FreeBSD__]: Add
2653 support for FreeBSD.
2654 (grub_util_biosdisk_get_grub_dev) [__FreeBSD__]: Check if OS_DEV
2655 is a character device instead of a block device. Add support for
2656 FreeBSD device names.
2657
2658 * util/getroot.c (find_root_device) [__FreeBSD__]: Check if ENT is
2659 a character device instead of a block device.
2660 (grub_util_check_char_device): New function.
2661
2662 * util/grub-probe.c (probe) [__FreeBSD__]: Check if DEVICE_NAME is
2663 a character device instead of a block device.
2664
2665 * include/grub/util/getroot.h (grub_util_check_char_device): New
2666 prototype.
2667
2668 2009-04-11 David S. Miller <davem@davemloft.net>
2669
2670 * conf/sparc64-ieee1275.rmk (kernel_img_LDFLAGS): Link with
2671 static libgcc.
2672 * configure.ac: Check for __bswapsi2 and __bswapdi2 presence.
2673 * include/grub/sparc64/libgcc.h (__bswapsi2): Export libgcc
2674 function, if present.
2675 (__bswapdi2): Likewise.
2676
2677 * include/grub/sparc64/ieee1275/boot.h: New file.
2678 * boot/sparc64/ieee1275/boot.S: Likewise.
2679 * boot/sparc64/ieee1275/diskboot.S: Likewise.
2680
2681 * kern/misc.c (grub_ltoa): New function.
2682 (grub_vsprintf): Use it to format 'long' integers.
2683
2684 2009-04-10 David S. Miller <davem@davemloft.net>
2685
2686 * disk/ieee1275/nand.c (grub_nand_open): All ieee1275 call arg
2687 slots are of type grub_ieee1275_cell_t.
2688 (grub_nand_read): Likewise.
2689 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_INVALID,
2690 IEEE1275_IHANDLE_INVALID): Use grub_ieee1275_cell_t since these
2691 macros are used to compare values in arg/ret block of the call.
2692 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
2693 grub_ieee1275_next_property, grub_ieee1275_get_property_length,
2694 grub_ieee1275_instance_to_package, grub_ieee1275_package_to_path,
2695 grub_ieee1275_instance_to_path, grub_ieee1275_write,
2696 grub_ieee1275_read, grub_ieee1275_seek, grub_ieee1275_peer,
2697 grub_ieee1275_child, grub_ieee1275_parent, grub_ieee1275_open,
2698 grub_ieee1275_close, grub_ieee1275_set_property,
2699 grub_ieee1275_set_color): All ieee1275 call arg slots are of type
2700 grub_ieee1275_cell_t.
2701 * kern/ieee1275/openfw.c (grub_map): Likewise.
2702 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_ihandle_t,
2703 grub_ieee1275_phandle_t): Define as grub_unit32_t type.
2704
2705 * kern/ieee1275/init.c (grub_machine_init): Make 'actual' grub_ssize_t.
2706 * kern/ieee1275/openfw.c (grub_children_iterate): Likewise.
2707 (grub_devalias_iterate): Likewise.
2708
2709 2009-04-10 Vladimir Serbinenko <phcoder@gmail.com>
2710
2711 UFS improvements
2712
2713 * fs/ufs.c (INODE_NBLOCKS): new definition
2714 (struct grub_ufs_dirent): added fields for non-BSD dirents
2715 (grub_ufs_get_file_block): fixed double indirect handling
2716 (grub_ufs_lookup_symlink): use more robust way to determine whether
2717 symlink is inline
2718 (grub_ufs_find_file): support for non-BSD dirents
2719 (grub_ufs_dir): support for non-BSD dirents
2720
2721 2009-04-10 Bean <bean123ch@gnail.com>
2722
2723 * include/grub/efi/api.h (grub_efi_configuration_table): Add packed
2724 attribute, otherwise the size would be wrong for i386 platform.
2725
2726 * include/grub/pci.h (grub_pci_read_word): New inline function.
2727 (grub_pci_read_byte): Likewise.
2728 (grub_pci_write): Likewise.
2729 (grub_pci_write_word): Likewise.
2730 (grub_pci_write_byte): Likewise.
2731
2732 * include/grub/pci.h (grub_pci_iteratefunc_t): Add NESTED_FUNC_ATTR.
2733
2734 * loader/i386/efi/linux.c (fake_bios_data): Moved to loadbios module.
2735 (find_framebuf): Scan pci to locate the frame buffer address.
2736
2737 * commands/efi/fixvideo.c: New file.
2738
2739 * commands/efi/loadbios.c: Likewise.
2740
2741 * commands/memrw.c: Likewise.
2742
2743 * util/grub-dumpbios.in: Likewise.
2744
2745 * conf/common.rmk (grub-dumpbios): New utility.
2746 (pkglib_MODULES): New module memrw.mod.
2747 (memrw_mod_SOURCE): New macro.
2748 (memrw_mod_CFLAGS): Likewise.
2749 (memrw_mod_LDFLAGS): Likewise.
2750
2751 * conf/i386-efi.rmk (pkglib_MODULES): New module loadbios.mod and
2752 fixvideo.mod.
2753 (loadbios_mod_SOURCE): New macro.
2754 (loadbios_mod_CFLAGS): Likewise.
2755 (loadbios_mod_LDFLAGS): Likewise.
2756 (fixvideo_mod_SOURCE): Likewise.
2757 (fixvideo_mod_CFLAGS): Likewise.
2758 (fixvideo_mod_LDFLAGS): Likewise.
2759
2760 * conf/x86_64.rmk (pkglib_MODULES): New module loadbios.mod and
2761 fixvideo.mod.
2762 (loadbios_mod_SOURCE): New macro.
2763 (loadbios_mod_CFLAGS): Likewise.
2764 (loadbios_mod_LDFLAGS): Likewise.
2765 (fixvideo_mod_SOURCE): Likewise.
2766 (fixvideo_mod_CFLAGS): Likewise.
2767 (fixvideo_mod_LDFLAGS): Likewise.
2768
2769 2009-04-08 Felix Zielcke <fzielcke@z-51.de>
2770
2771 * disk/lvm.c (grub_lvm_scan_device): Add a missing NULL check.
2772
2773 2009-04-07 David S. Miller <davem@davemloft.net>
2774
2775 * kern/sparc64/dl.c (grub_arch_dl_relocate_symbols): Add
2776 support for R_SPARC_OLO10 relocations. Fix compile warning for
2777 R_SPARC_WDISP30 case.
2778 * kern/sparc64/cache.S: Fix grub_arch_sync_caches implementation.
2779
2780 2009-04-06 Pavel Roskin <proski@gnu.org>
2781
2782 * include/grub/misc.h (ARRAY_SIZE): New macro.
2783 * include/grub/i386/linux.h (GRUB_LINUX_VID_MODE_VESA_START):
2784 New macro.
2785 * loader/i386/linux.c (allocate_pages): Use free_pages().
2786 (grub_linux_unload): Don't use free_pages().
2787 (grub_linux_boot): Prevent accessing linux_vesafb_modes with a
2788 wrong index. Treat all other modes as text modes.
2789 (grub_cmd_linux): Initialize vid_mode unconditionally to
2790 GRUB_LINUX_VID_MODE_NORMAL. Recognize and support "vga=ask".
2791
2792 * commands/help.c (print_command_help): Use cmd->prio, not
2793 cmd->flags to check for GRUB_PRIO_LIST_FLAG_ACTIVE.
2794
2795 2009-04-06 Vladimir Serbinenko <phcoder@gmail.com>
2796
2797 Parttool
2798
2799 * parttool/pcpart.c: new file
2800 * commands/parttool.c: likewise
2801 * conf/common.rmk (pkglib_MODULES): Added parttool.mod and pcpart.mod
2802 (parttool_mod_SOURCES): new variable
2803 (parttool_mod_CFLAGS): likewise
2804 (parttool_mod_LDFLAGS): likewise
2805 (pcpart_mod_SOURCES): likewise
2806 (pcpart_mod_CFLAGS): likewise
2807 (pcpart_mod_LDFLAGS): likewise
2808 * conf/i386-coreboot.rmk (grub_emu_SOURCES): added commands/parttool.c
2809 and parttool/pcpart.c
2810 * conf/i386-efi.rmk: likewise
2811 * conf/i386-ieee1275.rmk: likewise
2812 * conf/i386-pc.rmk: likewise
2813 * conf/powerpc-ieee1275.rmk: likewise
2814 * conf/sparc64-ieee1275.rmk: likewise
2815 * conf/x86_64-ieee1275.rmk: likewise
2816
2817 2009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
2818
2819 Support for mtime and further expandability of dir command
2820
2821 * include/grub/lib/datetime.h: moved to ...
2822 * include/grub/datetime.h: ... moved here and added
2823 declaration of grub_unixtime2datetime. All users updated
2824 * include/grub/fs.h: new syntax for dir and mtime functions in
2825 struct grub_fs
2826 * include/grub/fshelp.h: new declarations of GRUB_FSHELP_TYPE_MASK
2827 and GRUB_FSHELP_FLAGS_MASK
2828 * commands/ls.c (grub_ls_list_files): Write mtime in long format
2829 * fs/ext2.c (grub_ext2_dir): use new dir syntax and supply mtime
2830 (grub_ext2_mtime): new function
2831 * fs/hfsplus.c (grub_hfsplus_dir): use new dir syntax and supply mtime
2832 (grub_hfsplus_mtime): new function
2833 * fs/ufs.c (GRUB_UFS_ATTR_TYPE): new definition
2834 (GRUB_UFS_ATTR_FILE): likewise
2835 (GRUB_UFS_ATTR_LNK): likewise
2836 (struct grub_ufs_sblock): new fields mtime
2837 (grub_ufs_read_inode): new parameter to read inode to a separate buffer
2838 all users updated
2839 (grub_ufs_dir): mtime support
2840 (grub_ufs_mtime): new function
2841 * fs/affs.c (grub_affs_dir): use new dir syntax
2842 * fs/afs.c (grub_afs_dir): likewise
2843 * fs/cpio.c (grub_cpio_dir): likewise
2844 * fs/fat.c (grub_fat_find_dir): likewise
2845 * fs/hfs.c (grub_hfs_dir): likewise
2846 * fs/iso9660.c (grub_iso9660_dir): likewise
2847 * fs/jfs.c (grub_jfs_dir): likewise
2848 * fs/minix.c (grub_minix_dir): likewise
2849 * fs/ntfs.c (grub_ntfs_dir): likewise
2850 * fs/reiserfs.c (grub_reiserfs_dir): likewise
2851 * fs/sfs.c (grub_sfs_dir): likewise
2852 * fs/xfs.c (grub_xfs_dir): likewise
2853 * util/hostfs.c (grub_hostfs_dir): likewise
2854 * lib/datetime.c: moved to ...
2855 * normal/datetime.c: ... moved here
2856 (grub_unixtime2datetime): new function
2857 * kern/rescue.c (grub_rescue_print_files): use new dir syntax
2858 * normal/completion.c (iterate_dir): use new dir syntax
2859 * normal/misc.c (grub_normal_print_device_info): tell the
2860 last modification time of a volume
2861 * kern/fs.c (grub_fs_probe): updated dummy function to use new syntax
2862 * conf/common.rmk: added lib/datetime.c to ls.mod
2863 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add normal/datetime.c
2864 (normal_mod_SOURCES): likewise
2865 (datetime_mod_SOURCES): Removed lib/datetime.c
2866 * conf/i386-efi.rmk: likewise
2867 * conf/i386-ieee1275.rmk: likewise
2868 * conf/i386-pc.rmk: likewise
2869 * conf/powerpc-ieee1275.rmk: likewise
2870 * conf/sparc64-ieee1275.rmk: likewise
2871 * conf/x86_64-efi.rmk: likewise
2872
2873 2009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
2874
2875 Trim trailing spaces in FAT label and support mtools-like labels
2876
2877 * fs/fat.c (grub_fat_iterate_dir): New function based
2878 on grub_fat_find_dir
2879 (grub_fat_find_dir): use grub_fat_iterate_dir
2880 (grub_fat_label): likewise
2881
2882 2009-04-04 Vladimir Serbinenko <phcoder@gmail.com>
2883
2884 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): add list.h
2885 and command.h
2886 remove extraneous kernel_elf_HEADERS
2887
2888 2009-04-04 Bean <bean123ch@gnail.com>
2889
2890 * include/grub/util/misc.h: Add dummy function fsync for mingw.
2891
2892 * util/misc.c: Likewise.
2893
2894 2009-04-04 Yoshinori K. Okuji <okuji@enbug.org>
2895
2896 * loader/i386/efi/linux.c (fake_bios_data): Use grub_dprintf
2897 instead of grub_printf.
2898
2899 2009-04-03 Robert Millan <rmh@aybabtu.com>
2900
2901 * loader/i386/linux.c (grub_linux_setup_video): Fill
2902 `params->{red,green,blue,reserved}_{mask_size,field_pos}' with
2903 values from `mode info' structure instead of hardcoded
2904 values.
2905
2906 2009-04-01 Pavel Roskin <proski@gnu.org>
2907
2908 * Makefile.in: Remove all references to MODULE_LDFLAGS, it's
2909 unused now.
2910 * genmk.rb: Likewise.
2911 * configure.ac: Likewise.
2912
2913 2009-04-01 Manoel Abranches <mrabran@linux.vnet.ibm.com>
2914
2915 * aclocal.m4: Move --build-id=none from MODULE_LDFLAGS to
2916 TARGET_LDFLAGS. This corrects a problem with grub-mkelfimage.
2917
2918 2009-04-01 David S. Miller <davem@davemloft.net>
2919
2920 * normal/sparc64/setjmp.S: Fix setjmp implementation.
2921 * include/grub/sparc64/setjmp.h (grub_jmp_buf): Update.
2922 (grub_setjmp): Mark with 'returns_twice' attribute.
2923 * include/grub/i386/setjmp.h (grub_setjmp): Likewise
2924 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise.
2925 * include/grub/x86_64/setjmp.h (grub_setjmp): Likewise.
2926
2927 2009-04-01 Robert Millan <rmh@aybabtu.com>
2928
2929 Reapply fix from 2008-07-28 which was accidentally reverted; also
2930 perform the same fix to a similar check in same function.
2931
2932 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
2933 with the same number are found, just use issue a warning with
2934 grub_dprintf(), as this error has been reported to be non-fatal.
2935
2936 2009-03-31 Pavel Roskin <proski@gnu.org>
2937
2938 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Provide safe default
2939 for cross-compilation.
2940
2941 2009-03-30 Robert Millan <rmh@aybabtu.com>
2942
2943 Fix i386-ieee1275 build.
2944
2945 * include/grub/i386/ieee1275/loader.h (grub_multiboot2_real_boot):
2946 Remove declaration.
2947
2948 2009-03-30 Pavel Roskin <proski@gnu.org>
2949
2950 * fs/hfs.c (grub_hfs_strncasecmp): Integrate into ...
2951 (grub_hfs_cmp_catkeys): ... this. Don't assume strings to be
2952 zero-terminated, rely only on the strlen value. Fix comparison
2953 of strings differing in length.
2954
2955 2009-03-30 Robert Millan <rmh@aybabtu.com>
2956
2957 * loader/i386/linux.c (grub_cmd_linux): Check for zImage before
2958 checking for abi version. Improve error messages on BIOS to notify
2959 user about `linux16' command.
2960
2961 2009-03-29 Vladimir Serbinenko <phcoder@gmail.com>
2962
2963 Leak fixes
2964
2965 * kern/disk.c (grub_disk_cache_store): Invalidate previous cache
2966 in case of collision
2967 * disk/scsi.c (grub_scsi_open): free scsi in case of error
2968
2969 2009-03-29 Robert Millan <rmh@aybabtu.com>
2970
2971 * loader/i386/linux.c (grub_cmd_linux): Parse "vga=" parameter and
2972 set `vid_mode' accordingly.
2973 (grub_linux_boot): Process `vid_mode' and set video mode.
2974
2975 2009-03-29 Robert Millan <rmh@aybabtu.com>
2976
2977 * util/grub.d/10_linux.in (linux_entry): New function.
2978 Factorize generation of Linux boot entries.
2979
2980 2009-03-29 Yoshinori K. Okuji <okuji@enbug.org>
2981
2982 Make the format of Environment Block plain text. The boot loader
2983 part is not tested well yet.
2984
2985 * util/grub-editenv.c (DEFAULT_ENVBLK_SIZE): New macro.
2986 (buffer): Removed.
2987 (envblk): Likewise.
2988 (usage): Remove "info" and "clear". Add "unset". Update the
2989 description of "set", as this does not delete variables any
2990 longer.
2991 (create_envblk_file): Complete rewrite.
2992 (open_envblk_file): Likewise.
2993 (cmd_info): Removed.
2994 (cmd_list): Likewise.
2995 (cmd_set): Likewise.
2996 (cmd_clear): Likewise.
2997 (list_variables): New function.
2998 (write_envblk): Likewise.
2999 (set_variables): Likewise.
3000 (unset_variables): Likewise.
3001 (main): Complete rewrite.
3002
3003 * commands/loadenv.c (buffer): Removed.
3004 (envblk): Likewise.
3005 (open_envblk_file): New function.
3006 (read_envblk_file): Complete rewrite.
3007 (grub_cmd_load_env): Likewise.
3008 (grub_cmd_list_env): Likewise.
3009 (struct blocklist): New struct.
3010 (free_blocklists): New function.
3011 (check_blocklists): Likewise.
3012 (write_blocklists): Likewise.
3013 (grub_cmd_save_env): Complete rewrite.
3014
3015 * include/grub/lib/envblk.h (GRUB_ENVBLK_SIGNATURE): Replaced with
3016 a plain text signature.
3017 (GRUB_ENVBLK_MAXLEN): Removed.
3018 (struct grub_envblk): Complete rewrite.
3019 (grub_envblk_find): Removed.
3020 (grub_envblk_insert): Likewise.
3021 (grub_envblk_open): New prototype.
3022 (grub_envblk_set): Likewise.
3023 (grub_envblk_delete): Put const to VALUE.
3024 (grub_envblk_iterate): Put const to NAME and VALUE.
3025 (grub_envblk_close): New prototype.
3026 (grub_envblk_buffer): New inline function.
3027 (grub_envblk_size): Likewise.
3028
3029 * lib/envblk.c: Include grub/mm.h.
3030 (grub_env_find): Removed.
3031 (grub_envblk_open): New function.
3032 (grub_envblk_close): Likewise.
3033 (escaped_value_len): Likewise.
3034 (find_next_line): Likewise.
3035 (grub_envblk_insert): Removed.
3036 (grub_envblk_set): New function.
3037 (grub_envblk_delete): Complete rewrite.
3038 (grub_envblk_iterate): Likewise.
3039
3040 2009-03-28 Robert Millan <rmh@aybabtu.com>
3041
3042 * conf/i386-pc.rmk (pkglib_MODULES): Add `linux16.mod'.
3043 (linux16_mod_SOURCES, linux16_mod_CFLAGS, linux16_mod_LDFLAGS): New
3044 variables. Use 16-bit loader.
3045 (linux_mod_SOURCES, linux_mod_CFLAGS, linux_mod_LDFLAGS): Use 32-bit
3046 loader.
3047 * kern/i386/loader.S (grub_linux_boot): Rename to ...
3048 (grub_linux16_boot): ... this. Update all users.
3049 * loader/i386/linux.c (grub_linux32_boot): Rename to ...
3050 (grub_linux_boot): ... this. Update all users.
3051
3052 * loader/i386/pc/linux.c (GRUB_MOD_INIT(linux)): Rename to ...
3053 (GRUB_MOD_INIT(linux16)): ... this. Rename `linux' and `initrd'
3054 commands to `linux16' and `initrd16'.
3055 (GRUB_MOD_FINI(linux)): Rename to ...
3056 (GRUB_MOD_FINI(linux16)): ... this.
3057
3058 2009-03-24 Pavel Roskin <proski@gnu.org>
3059
3060 * genmk.rb: Define ASM_FILE for *.S files for *.lst generation,
3061 not just for compilation.
3062
3063 2009-03-22 Vladimir Serbinenko <phcoder@gmail.com>
3064
3065 Move multiboot helper out of kernel
3066
3067 * conf/i386-pc.rmk (multiboot_mod_SOURCES): Add
3068 `loader/i386/multiboot_helper.S'.
3069 * conf/i386-coreboot.rmk: Likewise
3070 * conf/i386-ieee1275.rmk: Likewise
3071
3072 * kern/i386/loader.S: Move multiboot helpers from here...
3073 * loader/i386/multiboot_helper.S: ...moved here
3074 * include/grub/i386/loader.h: Move declarations of multiboot
3075 helpers from here...
3076 * include/grub/i386/multiboot.h: ...moved here
3077 * loader/i386/multiboot.c: Added include of grub/cpu/multiboot.h
3078
3079 2009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
3080
3081 * kern/env.c (grub_env_context_open): Added an argument to specify
3082 whether a new context inherits exported variables from current
3083 one. This is useful when making a sandbox to interpret a config
3084 file.
3085 All callers updated.
3086
3087 * include/grub/env.h (grub_env_context_open): Updated the prototype.
3088
3089 2009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
3090
3091 * kern/env.c (grub_env_context_close): Fix memory leaks.
3092
3093 2009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
3094
3095 * normal/main.c (grub_normal_execute): Added an argument
3096 BATCH to specify if an interactive interface should be provided
3097 after reading a config file.
3098 All callers updated.
3099 (read_command_list): Prevent being executed twice.
3100 (read_fs_list): Likewise.
3101
3102 * include/grub/normal.h (grub_normal_execute): Updated the
3103 prototype.
3104
3105 2009-03-22 Pavel Roskin <proski@gno.org>
3106
3107 * kern/powerpc/ieee1275/startup.S: Replace EXT_C(start) with
3108 _start.
3109 * kern/i386/pc/startup.S: Likewise.
3110 * kern/i386/efi/startup.S: Likewise.
3111 * kern/i386/ieee1275/startup.S: Likewise.
3112 * kern/i386/coreboot/startup.S: Likewise.
3113 * kern/x86_64/efi/startup.S: Likewise.
3114
3115 * aclocal.m4 (grub_CHECK_START_SYMBOL): Remove.
3116 * configure.ac: Don't call grub_CHECK_START_SYMBOL.
3117 * kern/i386/pc/startup.S: Use _start instead of START_SYMBOL.
3118
3119 2009-03-21 Vladimir Serbinenko <phcoder@gmail.com>
3120
3121 Bugfixes in multiboot for bugs uncovered by solaris kernel.
3122
3123 * loader/i386/multiboot_elfxx.c (grub_multiboot_load_elf): Corrected
3124 limit detection.
3125 Use vaddr of correct segment for entry_point.
3126
3127 2009-03-21 Bean <bean123ch@gmail.com>
3128
3129 * commands/blocklist.c: Add include file <grub/command.h>, remove
3130 <grub/normal.h> and <grub/arg.h>.
3131 (grub_cmd_blocklist): Use the new command interface.
3132 (GRUB_MOD_INIT): Likewise.
3133 (GRUB_MOD_FINI): Likewise.
3134 * commands/boot.c: Likewise.
3135 * commands/cat.c: Likewise.
3136 * commands/cmp.c: Likewise.
3137 * commands/configfile.c: Likewise.
3138 * commands/crc.c: Likewise.
3139 * commands/echo.c: Likewise.
3140 * commands/halt.c: Likewise.
3141 * commands/handler.c: Likewise.
3142 * commands/hdparm.c: Likewise.
3143 * commands/help.c: Likewise.
3144 * commands/hexdump.c: Likewise.
3145 * commands/loadenv.c: Likewise.
3146 * commands/ls.c: Likewise.
3147 * commands/lsmmap.c: Likewise.
3148 * commands/lspci.c: Likewise.
3149 * commands/loadenv.c: Likewise.
3150 * commands/read.c: Likewise.
3151 * commands/reboot.c: Likewise.
3152 * commands/search.c: Likewise.
3153 * commands/sleep.c: Likewise.
3154 * commands/test.c: Likewise.
3155 * commands/usbtest.c: Likewise.
3156 * commands/videotest.c: Likewise.
3157 * commands/i386/cpuid.c: Likewise.
3158 * commands/i386/pc/halt.c: Likewise.
3159 * commands/i386/pc/play.c: Likewise.
3160 * commands/i386/pc/pxecmd.c: Likewise.
3161 * commands/i386/pc/vbeinfo.c: Likewise.
3162 * commands/i386/pc/vbetest.c: Likewise.
3163 * commands/ieee1275/suspend.c: Likewise.
3164 * disk/loopback.c: Likewise.
3165 * font/font_cmd.c: Likewise.
3166 * hello/hello.c: Likewise.
3167 * loader/efi/appleloader.c: Likewise.
3168 * loader/efi/chainloader.c: Likewise.
3169 * loader/i386/bsd.c: Likewise.
3170 * loader/i386/efi/linux.c: Likewise.
3171 * loader/i386/ieee1275/linux.c: Likewise.
3172 * loader/i386/linux.c: Likewise.
3173 * loader/i386/pc/chainloader.c: Likewise.
3174 * loader/i386/pc/linux.c: Likewise.
3175 * loader/powerpc/ieee1275/linux.c: Likewise.
3176 * loader/multiboot_loader.c: Likewise.
3177 * term/gfxterm.c: Likewise.
3178 * term/i386/pc/serial.c: Likewise.
3179 * term/terminfo.c: Likewise.
3180
3181 * term/i386/pc/vesafb.c: Removed <grub/arg.h>.
3182 * term/i386/pc/vga.c: Likewise.
3183 * video/readers/jpeg.c: Likewise.
3184 * video/readers/png.c: Likewise.
3185 * video/readers/tga.c: Likewise.
3186
3187 * util/grub-fstest (cmd_loopback): Removed.
3188 (cmd_blocklist): Likewise.
3189 (cmd_ls): Likewise.
3190 (grub_register_command): Likewise.
3191 (grub_unregister_command): Likewise.
3192 (execute_command): Use grub_command_find to locate command and execute
3193 it.
3194
3195 * include/grub/efi/chainloader.h: Removed.
3196 * loader/efi/chainloader_normal.c: Likewise.
3197 * loader/i386/bsd_normal.c: Likewise.
3198 * loader/i386/pc/chainloader_normal.c: Likewise.
3199 * loader/i386/pc/multiboot_normal.c: Likewise.
3200 * loader/linux_normal.c: Likewise.
3201 * loader/multiboot_loader_normal.c: Likewise.
3202 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
3203
3204 * gencmdlist.sh: Scan new registration command grub_register_extcmd
3205 and grub_register_command_p1.
3206
3207 * conf/common.rmk (grub_fstest_SOURCES): Add kern/list.c,
3208 kern/command.c, lib/arg.c and commands/extcmd.c.
3209 (pkglib_MODULES): Remove boot.mod, and minicmd.mod and extcmd.mod.
3210 (minicmd_mod_SOURCES): New variable.
3211 (minicmd_mod_CFLAGS): Likewise.
3212 (minicmd_mod_LDFLAGS): Likewise.
3213 (extcmd_mod_SOURCES): Likewise.
3214 (extcmd_mod_CFLAGS): Likewise.
3215 (extcmd_mod_LDFLAGS): Likewise.
3216 (boot_mod_SOURCES): Removed.
3217 (boot_mod_CFLAGS): Likewise.
3218 (boot_mod_LDFLAGS): Likewise.
3219
3220 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/command.c and
3221 kern/corecmd.c.
3222 (kernel_img_HEADERS): Add command.h.
3223 (grub_emu_SOURCES): Remove commands/boot.c and normal/arg.c, add
3224 commands/minicmd.c, kern/command.c, kern/corecmd.c, commands/extcmd.c
3225 and lib/arg.c.
3226 (pkglib_MODULES): Change _linux.mod, _chain.mod, _bsd.mod and
3227 _multiboot.mod as linux.mod, chain.mod, bsd.mod and multiboot.mod,
3228 remove the corresponding normal mode command.
3229 (normal_mod_SOURCES): Remove normal/arg.c.
3230 * conf/i386-coreboot.rmk: Likewise.
3231 * conf/i386-efi.rmk: Likewise.
3232 * conf/i386-ieee1275.rmk: Likewise.
3233 * conf/powerpc-ieee1275.rmk: Likewise.
3234 * conf/x86_64-efi.rmk: Likewise.
3235
3236 * include/grub/arg.h: Move from here ...
3237 * include/grub/lib/arg.h: ... to here.
3238
3239 * normal/arg.c: Move from here ...
3240 * lib/arg.c: ... to here.
3241
3242 * commands/extcmd.c: New file.
3243 * commands/minicmd.c: Likewise.
3244 * include/grub/command.h: Likewise.
3245 * include/grub/extcmd.h: Likewise.
3246 * kern/command.c: Likewise.
3247 * kern/corecmd.c: Likewise.
3248
3249 * kern/list.c (grub_list_iterate): Return int instead of void.
3250 (grub_list_insert): New function.
3251 (grub_prio_list_insert): Likewise.
3252
3253 * kern/rescue.c (grub_rescue_command): Removed.
3254 (grub_rescue_command_list): Likewise.
3255 (grub_rescue_register_command): Likewise.
3256 (grub_rescue_unregister_command): Likewise.
3257 (grub_rescue_cmd_boot): Move to minicmd.c
3258 (grub_rescue_cmd_help): Likewise.
3259 (grub_rescue_cmd_info): Likewise.
3260 (grub_rescue_cmd_boot): Likewise.
3261 (grub_rescue_cmd_testload): Likewise.
3262 (grub_rescue_cmd_dump): Likewise.
3263 (grub_rescue_cmd_rmmod): Likewise.
3264 (grub_rescue_cmd_lsmod): Likewise.
3265 (grub_rescue_cmd_exit): Likewise.
3266 (grub_rescue_print_devices): Moved to corecmd.c.
3267 (grub_rescue_print_files): Likewise.
3268 (grub_rescue_cmd_ls): Likewise.
3269 (grub_rescue_cmd_insmod): Likewise.
3270 (grub_rescue_cmd_set): Likewise.
3271 (grub_rescue_cmd_unset): Likewise.
3272 (attempt_normal_mode): Use grub_command_find to get normal module.
3273 (grub_enter_rescue_mode): Use grub_register_core_commands to register
3274 commands, remove grub_rescue_register_command calls.
3275
3276 * normal/command.c (grub_register_command): Removed.
3277 (grub_unregister_command): Likewise.
3278 (grub_command_find): Likewise.
3279 (grub_iterate_commands): Likewise.
3280 (rescue_command): Likewise.
3281 (export_command): Moved to corecmd.c.
3282 (set_command): Removed.
3283 (unset_command): Likewise.
3284 (insmod_command): Likewise.
3285 (rmmod_command): Likewise.
3286 (lsmod_command): Likewise.
3287 (grub_command_init): Likewise.
3288
3289 * normal/completion.c (iterate_command): Use cmd->prio to check for
3290 active command.
3291 (complete_arguments): Use grub_extcmd_t structure to find options.
3292 (grub_normal_do_completion): Change function grub_iterate_commands to
3293 grub_command_iterate.
3294
3295 * normal/execute.c (grub_script_execute_cmd): No need to parse
3296 argument here.
3297
3298 * normal/main.c (grub_dyncmd_dispatcher): New function.
3299 (read_command_list): Register unload commands as dyncmd.
3300 (grub_cmd_normal): Use new command interface, register rescue,
3301 unregister normal at entry, register normal, unregister rescue at exit.
3302
3303 * include/grub/list.h (grub_list_test_t): New type.
3304 (grub_list_iterate): Return int instead of void.
3305 (grub_list_insert): New function.
3306 (GRUB_AS_NAMED_LIST_P): New macro.
3307 (GRUB_AS_PRIO_LIST): Likewise.
3308 (GRUB_AS_PRIO_LIST_P): Likewise.
3309 (GRUB_PRIO_LIST_PRIO_MASK): New constant.
3310 (GRUB_PRIO_LIST_FLAG_ACTIVE): Likewise.
3311 (grub_prio_list): New structure.
3312 (grub_prio_list_insert): New function.
3313 (grub_prio_list_remove): New inline function.
3314
3315 * include/grub/normal.h: Remove <grub/arg.h>, add <grub/command.h>.
3316 (GRUB_COMMAND_FLAG_CMDLINE): Moved to command.h.
3317 (GRUB_COMMAND_FLAG_MENU): Likewise.
3318 (GRUB_COMMAND_FLAG_BOTH): Likewise.
3319 (GRUB_COMMAND_FLAG_TITLE): Likewise.
3320 (GRUB_COMMAND_FLAG_NO_ECHO): Likewise.
3321 (GRUB_COMMAND_FLAG_NO_ARG_PARSE): Removed.
3322 (GRUB_COMMAND_FLAG_NOT_LOADED): Likewise.
3323 (grub_command): Likewise.
3324 (grub_register_command): Likewise.
3325 (grub_command_find): Likewise.
3326 (grub_iterate_commands): Likewise.
3327 (grub_command_init): Likewise.
3328 (grub_arg_parse): Likewise.
3329 (grub_arg_show_help): Likewise.
3330
3331 * include/grub/rescue.h (grub_rescue_register_command): Removed.
3332 (grub_rescue_unregister_command): Likewise.
3333
3334 * include/grub/i386/bsd.h: Remove grub_rescue_cmd_freebsd,
3335 grub_rescue_cmd_openbsd, grub_rescue_cmd_netbsd,
3336 grub_rescue_cmd_freebsd_loadenv and grub_rescue_cmd_freebsd_module.
3337
3338 * include/grub/i386/efi/loader.h: Remove grub_rescue_cmd_linux and
3339 grub_rescue_cmd_initrd.
3340 * include/grub/i386/loader.h: Likewise.
3341 * include/grub/x86_64/loader.h: Likewise.
3342
3343 * include/grub/i386/pc/chainloader.h: Remove grub_chainloader_cmd.
3344
3345 2009-03-21 Bean <bean123ch@gmail.com>
3346
3347 * util/hostdisk.c (read_device_map): Use grub_util_get_disk_size
3348 instead of stat in mingw environment.
3349
3350 * util/misc.c (grub_millisleep): Use Sleep in mingw environment.
3351
3352 * aclocal.m4 (grub_CHECK_LINK_DIR): New function.
3353
3354 * configure.ac: Use grub_CHECK_LINK_DIR to determine whether to use
3355 AC_CONFIG_LINKS.
3356
3357 2009-03-21 Bean <bean123ch@gmail.com>
3358
3359 * fs/ext2.c (grub_ext2_mount): Change errno to GRUB_ERR_BAD_FS for
3360 out of range error.
3361
3362 2009-03-18 Michel Dänzer <michel@daenzer.net>
3363
3364 * fs/ext2.c (grub_ext2_read_block): Take endianness into account when
3365 checking inode flags for EXT4_EXTENTS_FLAG.
3366
3367 2009-03-18 Robert Millan <rmh@aybabtu.com>
3368
3369 * loader/i386/linux.c: Include `<grub/video.h>' and
3370 `<grub/i386/pc/vbe.h>'..
3371 (grub_linux_setup_video): New function. Loosely based on the EFI one.
3372 (grub_linux32_boot): Attempt to configure video settings with
3373 grub_linux_setup_video().
3374 (grub_rescue_cmd_linux): Set noreturn=0 in grub_loader_set, in order
3375 to avoid grub_console_fini() which would step out of graphical mode
3376 unconditionally.
3377
3378 2009-03-14 Robert Millan <rmh@aybabtu.com>
3379
3380 Fix build on powerpc.
3381 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Add `handler.h'.
3382
3383 2009-03-12 Vladimir Serbinenko <phcoder@gmail.com>
3384
3385 * term/gfxterm.c (GRUB_MOD_FINI(term_gfxterm)): Correct name of
3386 background image command.
3387
3388 2009-03-12 Colin D Bennett <colin@gibibit.com>
3389
3390 * term/gfxterm.c (draw_cursor): Ensure character is redrawn.
3391 (grub_gfxterm_putchar): Extract pairs of identical calls to
3392 draw_cursor out of conditional blocks.
3393
3394 2009-03-11 Pavel Roskin <proski@gnu.org>
3395
3396 * fs/hfs.c (grub_hfs_strncasecmp): New function.
3397 (grub_hfs_cmp_catkeys): Use HFS specific string comparison.
3398
3399 2009-03-11 Robert Millan <rmh@aybabtu.com>
3400
3401 * loader/i386/multiboot_elfxx.c
3402 (CONCAT(grub_multiboot_load_elf, XX)): Do not reject ET_DYN files.
3403
3404 2009-03-11 Felix Zielcke <fzielcke@z-51.de>
3405
3406 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add `kern/list.c' and
3407 `kern/handler.c'.
3408
3409 2009-03-11 Robert Millan <rmh@aybabtu.com>
3410
3411 * loader/i386/multiboot.c (code_size): New variable.
3412 (grub_multiboot): Define offsets by adding to `code_size' rather
3413 than subtracting from `grub_multiboot_payload_size'. Provide
3414 4-byte alignment to MBI and others by increasing
3415 `boot_loader_name_length' appropriately.
3416
3417 * loader/i386/multiboot_elfxx.c
3418 (CONCAT(grub_multiboot_load_elf, XX)): Initialize `code_size'.
3419
3420 2009-03-09 Felix Zielcke <fzielcke@z-51.de>
3421
3422 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove duplicated
3423 `fs/ext2.c'.
3424
3425 2009-03-08 Robert Millan <rmh@aybabtu.com>
3426
3427 Make loader/i386/linux.c usable on i386-pc again.
3428
3429 * kern/i386/pc/init.c (grub_machine_init): Disable addition of low
3430 memory to heap.
3431 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS] (allocate_pages): Remove
3432 `#error' stanza.
3433
3434 2009-03-07 Bean <bean123ch@gmail.com>
3435
3436 * loader/i386/efi/linux.c (grub_rescue_cmd_initrd): Fix a bug in initrd
3437 allocation.
3438
3439 2009-03-06 Robert Millan <rmh@aybabtu.com>
3440
3441 Fix display issue on terminals with screen size other than 80x25
3442 (e.g. gfxterm with resolution higher than 640x480).
3443
3444 * normal/main.c (grub_normal_init_page): Display title text in a
3445 position relative to the center of the terminal instead of relying
3446 on a hardcoded offset.
3447
3448 2009-03-04 Robert Millan <rmh@aybabtu.com>
3449
3450 Filter /etc/grub.d/10_* so that only add-ons for native kernels are
3451 installed.
3452
3453 * Makefile.in (host_kernel): New variable.
3454 * conf/common.rmk (grub-mkconfig_SCRIPTS): Conditionalize all 10_*.in
3455 scripts instead of just the windows one.
3456 * configure.ac: Initialize and AC_SUBST `host_kernel'.
3457
3458 2009-03-04 Felix Zielcke <fzielcke@z-51.de>
3459
3460 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `kern/list.c' and
3461 `kern/handler.c'.
3462 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
3463 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
3464 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
3465 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3466 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3467 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3468
3469 2009-03-04 Felix Zielcke <fzielcke@z-51.de>
3470
3471 * partmap/pc.c (pc_partition_map_iterate): Skip over invalid BSD partitions
3472 or if there's no space for the disk label and print the partition number on a
3473 invalid magic.
3474
3475 2009-03-04 Felix Zielcke <fzielcke@z-51.de>
3476
3477 * util/misc.c: Include <time.h>.
3478 (grub_millisleep): New function.
3479
3480 2009-03-04 Bean <bean123ch@gmail.com>
3481
3482 * configure.ac: Only test -mcmodel=large option in x86_64-efi, also add
3483 another option -mno-red-zone.
3484
3485 * commands/handler.c: Change module description.
3486
3487 * kern/handler.c: Add missing space at the end of description line.
3488
3489 * kern/list.c: Likewise.
3490
3491 2009-03-03 Robert Millan <rmh@aybabtu.com>
3492
3493 Move more components to the relocation area, and fix mbi pointer
3494 handling to use the destination rather than the origin (thanks to
3495 Vladimir Serbinenko for spotting).
3496
3497 * loader/i386/multiboot.c (mbi_dest): New variable.
3498 (grub_multiboot_boot): Use `mbi_dest' instead of `mbi'.
3499 (grub_multiboot): Put cmdline, boot_loader_name and mbi in the
3500 relocation area.
3501
3502 2009-03-01 Bean <bean123ch@gmail.com>
3503
3504 * include/grub/efi/api.h (GRUB_EFI_MPS_TABLE_GUID): New constant.
3505 (GRUB_EFI_ACPI_TABLE_GUID): Likewise.
3506 (GRUB_EFI_ACPI_20_TABLE_GUID): Likewise.
3507 (GRUB_EFI_SMBIOS_TABLE_GUID): Likewise.
3508
3509 * loader/i386/efi/linux.c (acpi_guid): New variable.
3510 (acpi_guid): Likewise.
3511 (EBDA_SEG_ADDR): New constant.
3512 (LOW_MEM_ADDR): Likewise.
3513 (FAKE_EBDA_SEG): Likewise.
3514 (fake_bios_data): New function.
3515 (grub_linux_boot): Call fake_bios_data.
3516
3517 2009-03-01 Bean <bean123ch@gmail.com>
3518
3519 * commands/terminal.c: Removed.
3520
3521 * commands/handler.c: New file.
3522
3523 * include/grub/list.h: Likewise.
3524
3525 * include/grub/handler.h: Likewise.
3526
3527 * kern/list.c: Likewise.
3528
3529 * kern/handler.c: Likewise.
3530
3531 * kern/term.h: Include header file <grub/handler.h>.
3532 (grub_term_input): Move next field to the beginning.
3533 (grub_term_output): Likewise.
3534 (grub_term_input_class): New variable.
3535 (grub_term_output_class): Likewise.
3536 (grub_term_register_input): Changed to inline function.
3537 (grub_term_register_output): Likewise.
3538 (grub_term_unregister_input): Likewise.
3539 (grub_term_unregister_output): Likewise.
3540 (grub_term_set_current_input): Likewise.
3541 (grub_term_set_current_output): Likewise.
3542 (grub_term_get_current_input): Likewise.
3543 (grub_term_get_current_output): Likewise.
3544 (grub_term_iterate_input): Removed.
3545 (grub_term_iterate_output): Likewise.
3546
3547 * kern/term.c (grub_term_list_input): Removed.
3548 (grub_term_list_output): Likewise.
3549 (grub_term_input_class): New variable.
3550 (grub_term_output_class): Likewise.
3551 (grub_cur_term_input): Change variable as macro.
3552 (grub_cur_term_output): Likewise.
3553 (grub_term_register_input): Removed.
3554 (grub_term_register_output): Likewise.
3555 (grub_term_unregister_input): Likewise.
3556 (grub_term_unregister_output): Likewise.
3557 (grub_term_set_current_input): Likewise.
3558 (grub_term_set_current_output): Likewise.
3559 (grub_term_iterate_input): Likewise.
3560 (grub_term_iterate_output): Likewise.
3561 (grub_term_get_current_input): Likewise.
3562 (grub_term_get_current_output): Likewise.
3563
3564 * util/grub-editenv.c: Include header file <grub/handler.h>.
3565 (grub_term_get_current_input): Removed.
3566 (grub_term_get_current_output): Likewise.
3567 (grub_term_input_class): New variable.
3568 (grub_term_output_class): Likewise.
3569
3570 * util/grub-fstest.c (grub_term_get_current_input): Removed.
3571 (grub_term_get_current_output): Likewise.
3572 (grub_term_input_class): New variable.
3573 (grub_term_output_class): Likewise.
3574
3575 * util/grub-probe.c (grub_term_get_current_input): Removed.
3576 (grub_term_get_current_output): Likewise.
3577 (grub_term_input_class): New variable.
3578 (grub_term_output_class): Likewise.
3579
3580 * util/i386/pc/grub-setup.c (grub_term_get_current_input): Removed.
3581 (grub_term_get_current_output): Likewise.
3582 (grub_term_input_class): New variable.
3583 (grub_term_output_class): Likewise.
3584
3585 * conf/common.rmk (pkglib_MODULES): Replace terminal with handler.
3586 (terminal_mod_SOURCES): Likewise.
3587 (terminal_mod_CFLAGS): Likewise.
3588 (terminal_mod_LDFLAGS): Likewise.
3589
3590 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace terminal.c with
3591 handler.c.
3592 (kernel_img_SOURCES): Add list.c and handler.c.
3593 (kernel_img_HEADERS): Add list.h and handler.h.
3594
3595 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
3596 handler.c.
3597 (kernel_mod_SOURCES): Add list.c and handler.c.
3598 (kernel_mod_HEADERS): Add list.h and handler.h.
3599
3600 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Replace terminal.c with
3601 handler.c.
3602 (kernel_elf_SOURCES): Add list.c and handler.c.
3603 (kernel_elf_HEADERS): Add list.h and handler.h.
3604
3605 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
3606 handler.c.
3607 (kernel_elf_SOURCES): Add list.c and handler.c.
3608 (kernel_elf_HEADERS): Add list.h and handler.h.
3609
3610 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
3611 handler.c.
3612 (kernel_mod_SOURCES): Add list.c and handler.c.
3613 (kernel_mod_HEADERS): Add list.h and handler.h.
3614
3615 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
3616 handler.c.
3617 (kernel_elf_SOURCES): Add list.c and handler.c.
3618 (kernel_elf_HEADERS): Add list.h and handler.h.
3619
3620 2009-02-27 Robert Millan <rmh@aybabtu.com>
3621
3622 Factorize elf32 / elf64 code in Multiboot loader. This will
3623 prevent it from getting out of sync again.
3624
3625 * loader/i386/multiboot.c (grub_multiboot_is_elf32,
3626 grub_multiboot_load_elf32, grub_multiboot_is_elf64,
3627 grub_multiboot_load_elf64): Move from here ...
3628 * loader/i386/multiboot_elfxx.c (grub_multiboot_is_elf,
3629 grub_multiboot_load_elf): ... to here (new file).
3630
3631 2009-02-27 Robert Millan <rmh@aybabtu.com>
3632
3633 * util/grub.d/10_linux.in: Rename "single-user mode" to
3634 "recovery mode".
3635
3636 2009-02-27 Vladimir Serbinenko <phcoder@gmail.com>
3637
3638 Don't leak in SCSI code.
3639 * disk/scsi.c (grub_scsi_close): free `scsi'.
3640
3641 2009-02-27 Robert Millan <rmh@aybabtu.com>
3642
3643 * loader/i386/pc/multiboot.c: Move from here ...
3644 * loader/i386/multiboot.c: ... to here. Update all users.
3645
3646 2009-02-27 Robert Millan <rmh@aybabtu.com>
3647
3648 Patch from Alexandre Bique <bique.alexandre@gmail.com>
3649 * util/i386/pc/grub-setup.c (setup): Fix directory path.
3650
3651 2009-02-27 Krzysztof Smiechowicz <deadwood@wp.pl>
3652
3653 * fs/sfs.c (grub_sfs_read_extent): Correction to traversing extent
3654 b-tree.
3655
3656 2009-02-27 Robert Millan <rmh@aybabtu.com>
3657
3658 * kern/misc.c (grub_strtoull): Fix bug (it mistakenly parsed the
3659 `0x' qualifier as 0 when base is specified as parameter).
3660
3661 2009-02-24 Bean <bean123ch@gmail.com>
3662
3663 * configure.ac: Check for -mcmodel=large in x86_64 target.
3664
3665 * include/grub/efi/api.h (efi_call_10): New macro.
3666 (efi_wrap_10): New function.
3667
3668 * include/grub/efi/pe32.h (GRUB_PE32_REL_BASE_HIGH): New macro.
3669 (GRUB_PE32_REL_BASED_HIGH): Likewise.
3670 (GRUB_PE32_REL_BASED_LOW): Likewise.
3671 (GRUB_PE32_REL_BASED_HIGHLOW): Likewise.
3672 (GRUB_PE32_REL_BASED_HIGHADJ): Likewise.
3673 (GRUB_PE32_REL_BASED_MIPS_JMPADDR): Likewise.
3674 (GRUB_PE32_REL_BASED_SECTION): Likewise.
3675 (GRUB_PE32_REL_BASED_REL): Likewise.
3676 (GRUB_PE32_REL_BASED_IA64_IMM64): Likewise.
3677 (GRUB_PE32_REL_BASED_DIR64): Likewise.
3678 (GRUB_PE32_REL_BASED_HIGH3ADJ): Likewise.
3679
3680 * kern/x86_64/dl.c (grub_arch_dl_relocate_symbols): Fixed relocation
3681 issue.
3682
3683 * kern/x86_64/efi/callwrap.S (efi_wrap_6): Bug fix.
3684 (efi_wrap_10): New function.
3685
3686 * kern/x86_64/efi/startup.S (codestart): Use relative addressing.
3687
3688 * loader/efi/appleloader.c (devpath_5): Add support for late 2008
3689 MB/MBP model (NV chipset).
3690 (devdata_devs): Add devpath_5 to the list.
3691
3692 * load/i386/efi/linux.c (video_base): Remove variable.
3693 (RGB_MASK): New macro.
3694 (RGB_MAGIC): Likewise.
3695 (LINE_MIN): Likewise.
3696 (LINE_MAX): Likewise.
3697 (FBTEST_STEP): Likewise.
3698 (FBTEST_COUNT): Likewise.
3699 (fb_list): New variable.
3700 (grub_find_video_card): Remove function.
3701 (find_framebuf): New function.
3702 (grub_linux_setup_video): Use find_framebuf to get frame buffer and
3703 line length.
3704
3705 * util/i386/efi/grub-mkimage.c (grub_reloc_section): Fix relocation
3706 problem for x86_64.
3707
3708 2009-02-22 Vesa Jääskeläinen <chaac@nic.fi>
3709
3710 Patch #25624 by Kevin Lacquement <kevin@lacqui>.
3711
3712 * util/grub-mkconfig.in: Use ${grub_mkdevicemap} instead of hard
3713 coding tool name.
3714
3715 2009-02-22 Robert Millan <rmh@aybabtu.com>
3716
3717 * include/multiboot.h (MULTIBOOT_INFO_ALIGN): New macro.
3718 * loader/i386/pc/multiboot.c (grub_multiboot): Include the MBI
3719 in our relocation, instead of using it directly from heap. Also
3720 use `MULTIBOOT_INFO_ALIGN' to ensure it is aligned.
3721
3722 2009-02-21 Robert Millan <rmh@aybabtu.com>
3723
3724 Implement USB keyboard support (based on patch by Marco Gerards)
3725
3726 * conf/i386-pc.rmk (pkglib_MODULES): Add `usb_keyboard.mod'.
3727 (usb_keyboard_mod_SOURCES, usb_keyboard_mod_CFLAGS)
3728 (usb_keyboard_mod_LDFLAGS): New variables.
3729
3730 * term/usb_keyboard.c: New file.
3731
3732 2009-02-14 Vladimir Serbinenko <phcoder@gmail.com>
3733
3734 Corrected wrong declaration
3735
3736 * kern/disk.c: corrected declaration of grub_disk_ata_pass_through.
3737
3738 2009-02-14 Christian Franke <franke@computer.org>
3739
3740 * commands/lspci.c (grub_pci_classes): Add `SATA Controller'.
3741 (grub_lspci_iter): Print class code and programming interface byte.
3742
3743 2009-02-14 Christian Franke <franke@computer.org>
3744
3745 * gendistlist.sh: Ignore `.svn' directories.
3746
3747 2009-02-14 Felix Zielcke <fzielcke@z-51.de>
3748
3749 * fs/fat.c: Add 2009 to Copyright line.
3750
3751 2009-02-14 Christian Franke <franke@computer.org>
3752
3753 * commands/hdparm.c: New file. Provides `hdparm' command
3754 which sends ATA commands via grub_disk_ata_pass_through ().
3755
3756 * conf/i386-pc.rmk: Add ata_pthru.mod and hdparm.mod.
3757
3758 * disk/ata.c: Include <grub/ata.h>. Move <grub/misc.h>
3759 and <grub/cpu/io.h> to include/grub/ata.h.
3760 (enum grub_ata_addressing_t): Move to include/grub/ata.h.
3761 (GRUB_CDROM_SECTOR_SIZE): Remove.
3762 (GRUB_ATA_*): Move to include/grub/ata.h.
3763 (GRUB_ATAPI_*): Likewise.
3764 (enum grub_ata_commands): Likewise.
3765 (enum grub_ata_timeout_milliseconds): Likewise.
3766 (struct grub_ata_device): Likewise.
3767 (grub_ata_regset): Likewise.
3768 (grub_ata_regget): Likewise.
3769 (grub_ata_regset2): Likewise.
3770 (grub_ata_regget2): Likewise.
3771 (grub_ata_check_ready): Likewise.
3772 (grub_ata_wait_not_busy): Remove static, exported in
3773 include/grub/ata.h.
3774 (grub_ata_wait_drq): Likewise.
3775 (grub_ata_pio_read): Likewise.
3776
3777 * disk/ata_pthru.c: New file. Provides grub_ata_pass_through ()
3778 function for hdparm.mod.
3779
3780 * include/grub/ata.h: New file, contains declarations from
3781 disk/ata.c.
3782 (enum grub_ata_commands): Add new commands for commands/hdparm.c.
3783
3784 * include/grub/disk.h (grub_disk_ata_pass_through_parms): New struct.
3785 (grub_disk_ata_pass_through): New exported variable.
3786
3787 * kern/disk.c (grub_disk_ata_pass_through): New variable.
3788
3789 2009-02-13 Colin D Bennett <colin@gibibit.com>
3790
3791 Support multiple fallback entries, and provide an API to support
3792 executing default+fallback menu entries. Renamed the `terminal' menu
3793 viewer to `text'.
3794
3795 * include/grub/normal.h (grub_normal_text_menu_viewer): New global
3796 variable declaration.
3797 (grub_menu_execute_callback): New structure declaration.
3798 (grub_menu_execute_callback_t): New typedef.
3799 (grub_menu_execute_with_fallback): New function declaration.
3800 (grub_menu_get_entry): Likewise.
3801 (grub_menu_get_timeout): Likewise.
3802 (grub_menu_set_timeout): Likewise.
3803
3804 * normal/main.c (GRUB_MOD_INIT(normal)): Refer to new variable name.
3805
3806 * normal/menu.c (grub_wait_after_message): Moved to
3807 `normal/menu_text.c'.
3808 (draw_border): Likewise.
3809 (print_message): Likewise.
3810 (print_entry): Likewise.
3811 (print_entries): Likewise.
3812 (grub_menu_init_page): Likewise.
3813 (get_entry_number): Likewise.
3814 (print_timeout): Likewise.
3815 (run_menu): Likewise.
3816 (grub_menu_execute_entry): Likewise.
3817 (show_text_menu): Likewise.
3818 (get_and_remove_first_entry_number): New function.
3819 (grub_menu_execute_with_fallback): Likewise.
3820 (get_entry): Renamed to ...
3821 (grub_menu_get_entry): .. this and made it global.
3822 (get_timeout): Renamed to ...
3823 (grub_menu_get_timeout): ... this and made it global.
3824 (set_timeout): Renamed to ...
3825 (grub_menu_set_timeout): ... this and made it global.
3826 (grub_normal_terminal_menu_viewer): Renamed to ...
3827 (grub_normal_text_menu_viewer): ... this.
3828
3829 * normal/menu_text.c: New file. Extracted text-menu-specific code
3830 from normal/menu.c.
3831
3832 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add `normal/menu_text.c'.
3833 (normal_mod_SOURCES): Likewise.
3834
3835 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
3836 (normal_mod_SOURCES): Likewise.
3837
3838 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3839 (normal_mod_SOURCES): Likewise.
3840
3841 * conf/i386-pc.rmk, (grub_emu_SOURCES): Likewise.
3842 (normal_mod_SOURCES): Likewise.
3843
3844 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3845 (normal_mod_SOURCES): Likewise.
3846
3847 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3848 (normal_mod_SOURCES): Likewise.
3849
3850 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
3851 (normal_mod_SOURCES): Likewise.
3852
3853 2009-02-11 Robert Millan <rmh@aybabtu.com>
3854
3855 * util/grub.d/00_header.in: Update old reference to `font' command.
3856
3857 2009-02-10 Felix Zielcke <fzielcke@z-51.de>
3858
3859 * fs/fat.c (grub_fat_mount): Fix wrong comparison.
3860
3861 Based on patch from Javier Martín.
3862
3863 2009-02-09 Felix Zielcke <fzielcke@z-51.de>
3864
3865 * conf/common.rmk (grub_probe_SOURCES): Move fs/ext2.c before fs/fat.c
3866 to avoid false positives with FAT.
3867 (grub_fstest_SOURCES): Likewise.
3868 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
3869 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
3870 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3871 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
3872 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3873 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3874
3875 2009-02-09 Felix Zielcke <fzielcke@z-51.de>
3876
3877 * fs/fat.c (grub_fat_mount): Try to avoid false positives by checking
3878 bpb.version_specific.fat12_or_fat16.fstype and
3879 bpb.version_specific.fat32.fstype.
3880
3881 2009-02-08 Robert Millan <rmh@aybabtu.com>
3882
3883 * fs/tar.c: Replace "fs/cpio.c" with "cpio.c".
3884
3885 2009-02-08 Robert Millan <rmh@aybabtu.com>
3886
3887 * Makefile.in (host_os, host_cpu): New variables.
3888 (target_os): Remove. Update all users.
3889
3890 2009-02-08 Marco Gerards <marco@gnu.org>
3891
3892 * Makefile.in (enable_grub_emu_usb): New variable.
3893 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/scsi.c'.
3894 (grub_emu_SOURCES) [grub_emu_SOURCES]: Add `disk/usbms.c',
3895 `util/usb.c', `bus/usb/usb.c' and `commands/usbtest.c'.
3896 (grub_emu_LDFLAGS): Add `$(LIBUSB)'.
3897 (pkglib_MODULES): Add `usb.mod', `uhci.mod', `ohci.mod',
3898 `usbtest.mod' and `usbms.mod'.
3899 (usb_mod_SOURCES, usb_mod_CFLAGS, usb_mod_LDFLAGS)
3900 (usbtest_mod_SOURCES, usbtest_mod_CFLAGS, usbtest_mod_LDFLAGS)
3901 (uhci_mod_SOURCES, uhci_mod_CFLAGS, uhci_mod_LDFLAGS,
3902 (ohci_mod_SOURCES, ohci_mod_CFLAGS, ohci_mod_LDFLAGS)
3903 (usbms_mod_SOURCES, usbms_mod_CFLAGS, usbms_mod_LDFLAGS): New
3904 variables.
3905
3906 * disk/usbms.c: New file.
3907
3908 * include/grub/usb.h: Likewise.
3909
3910 * include/grub/usbtrans.h: Likewise.
3911
3912 * include/grub/usbdesc.h: Likewise.
3913
3914 * bus/usb/usbtrans.c: Likewise.
3915
3916 * bus/usb/ohci.c: Likewise.
3917
3918 * bus/usb/uhci.c: Likewise.
3919
3920 * bus/usb/usbhub.c: Likewise.
3921
3922 * bus/usb/usb.c: Likewise.
3923
3924 * commands/usbtest.c: Likewise.
3925
3926 * util/usb.c: Likewise.
3927
3928 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_IO'.
3929
3930 * configure.ac: Test for libusb presence.
3931
3932 * util/grub-emu.c (main) [HAVE_LIBUSB_H]: Call `grub_libusb_init'.
3933
3934 2009-02-08 Vesa Jääskeläinen <chaac@nic.fi>
3935
3936 * kern/mm.c: Add more comments.
3937
3938 2009-02-08 Robert Millan <rmh@aybabtu.com>
3939
3940 Patch from Javier Martín.
3941 * fs/ext2.c (EXT2_DRIVER_SUPPORTED_INCOMPAT): Add
3942 `EXT4_FEATURE_INCOMPAT_FLEX_BG'.
3943
3944 2009-02-08 Robert Millan <rmh@aybabtu.com>
3945
3946 * fs/cpio.c: Split tar functionality to ...
3947 * fs/tar.c: ... here (new file). Update all users.
3948
3949 2009-02-07 Robert Millan <rmh@aybabtu.com>
3950
3951 * fs/ext2.c (grub_ext2_mount): Avoid mounting filesystems with
3952 backward-incompatible features.
3953
3954 Based on patch from Javier Martín, with some adjustments.
3955
3956 2009-02-07 Michael Scherer <misc@mandriva.org>
3957
3958 * fs/hfs.c (grub_hfsplus_iterate_dir): Treat hfs+ as case insensitive.
3959
3960 2009-02-07 Robert Millan <rmh@aybabtu.com>
3961
3962 * conf/common.rmk (grub_probe_SOURCES, grub_fstest_SOURCES): Move
3963 position of `disk/lvm.c' to ensure grub_init_all() always picks it
3964 after the RAID stuff.
3965
3966 2009-02-05 Vesa Jääskeläinen <chaac@nic.fi>
3967
3968 Fixes problem when running vbetest command as reported by
3969 Vladimir Serbinenko <phcoder@gmail.com>.
3970
3971 * (grub_vbe_set_video_mode): Fixed problem with text modes.
3972
3973 2009-02-04 Felix Zielcke <fzielcke@z-51.de>
3974
3975 util/getroot.c (grub_util_get_grub_dev): Add support for /dev/mdNpN and
3976 /dev/md/NpN style mdraid devices.
3977
3978 2009-02-03 Felix Zielcke <fzielcke@z-51.de>
3979
3980 * util/unifont2pff.rb: Remove.
3981
3982 2009-02-03 Felix Zielcke <fzielcke@z-51.de>
3983
3984 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add a missing trailing
3985 `#'.
3986
3987 2009-02-03 Felix Zielcke <fzielcke@z-51.de>
3988
3989 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/menu_viewer.c'.
3990 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
3991 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
3992 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
3993 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3994 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3995 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3996
3997 2009-02-02 Christian Franke <franke@computer.org>
3998
3999 * lib/hexdump.c (hexdump): Print at most 3 lines if data is identical.
4000
4001 2009-02-01 Felix Zielcke <fzielcke@z-51.de>
4002
4003 * INSTALL: Note that we now require at least autoconf 2.59 and
4004 that LZO is optional.
4005
4006 2009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
4007
4008 Base on patch on bug #24154 created by Tomas Tintera
4009 <trosos@seznam.cz>.
4010
4011 * video/i386/pc/vbe.c (grub_video_vbe_scroll): Fix downward scrolling.
4012
4013 2009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
4014
4015 Based on patch on bug #25318 created by Bernhard Rosenkraenzer
4016 <bero@arklinux.org>.
4017
4018 * normal/parser.y (script_init): Add missing semicolon.
4019
4020 2009-01-31 Colin D Bennett <colin@gibibit.com>
4021
4022 * normal/main.c: Add include to grub/menu_viewer.h.
4023 (free_menu_entry_classes): Added.
4024 (grub_normal_menu_addentry): Added class property handling.
4025 (grub_normal_execute): Changed to use new menu viewer for menu viewing.
4026 (GRUB_MOD_INIT(normal)): Added register for text based menu viewer.
4027
4028 * normal/menu_viewer.c: New file.
4029
4030 * normal/menu.c (run_menu_entry): Renamed to ...
4031 (grub_menu_execute_entry): ... this and made it as global.
4032 (grub_menu_run): Renamed to ...
4033 (show_text_menu): ... this and made it local.
4034 (show_text_menu): Adapt to new function names.
4035 (grub_normal_terminal_menu_viewer): New global variable.
4036
4037 * include/grub/menu.h: New file.
4038
4039 * include/grub/menu_viewer.h: New file.
4040
4041 * include/grub/normal.h: Added include to grub/menu.h.
4042 (grub_menu_entry): Moved to include/grub/menu.h.
4043 (grub_menu_entry_t): Likewise.
4044 (grub_menu): Likewise.
4045 (grub_menu_t): Likewise.
4046 (grub_normal_terminal_menu_viewer): Added.
4047 (grub_menu_execute_entry): Likewise.
4048 (grub_menu_run): Removed.
4049
4050 * DISTLIST: Added include/grub/menu.h.
4051 Added include/grub/menu_viewer.h.
4052 Added normal/menu_viewer.c.
4053
4054 2009-01-31 Vesa Jääskeläinen <chaac@nic.fi>
4055
4056 * normal/execute.c (grub_script_execute_menuentry): Changed to use
4057 arglist for menutitle arguments.
4058
4059 * normal/main.c (grub_normal_menu_addentry): Likewise.
4060
4061 * normal/parser.y (menuentry): Likewise.
4062
4063 * normal/script.c (grub_script_create_cmdmenu): Likewise.
4064
4065 * include/grub/script.h (grub_script_cmd_menuentry): Likewise.
4066 (grub_script_create_cmdmenu): Likewise.
4067
4068 * include/grub/normal.h (grub_normal_menu_addentry): Likewise.
4069
4070 * conf/i386-pc.rmk (normal_mod_SOURCES): Adapt Colin D Bennett's
4071 changes.
4072
4073 * conf/x86_64-efi.rmk (normal_mod_SOURCES): Likewise.
4074
4075 * conf/i386-coreboot.rmk (normal_mod_SOURCES): Likewise.
4076
4077 * conf/i386-efi.rmk (normal_mod_SOURCES): Likewise.
4078
4079 * conf/i386-ieee1275.rmk (normal_mod_SOURCES): Likewise.
4080
4081 * conf/powerpc-ieee1275.rmk (normal_mod_SOURCES): Likewise.
4082
4083 * conf/sparc64-ieee1275.rmk (normal_mod_SOURCES): Likewise.
4084
4085 2009-01-30 Christian Franke <franke@computer.org>
4086
4087 * normal/arg.c (grub_arg_show_help): Add indentation if '\n' appears
4088 in option help text.
4089
4090 2009-01-27 Pavel Roskin <proski@gnu.org>
4091
4092 * disk/fs_uuid.c (search_fs_uuid): Ignore case of the UUID.
4093
4094 2009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
4095
4096 * commands/lsmmap.c: Add include to grub/machine/memory.h.
4097
4098 * fs/i386/pc/pxe.c (grub_pxefs_open): Fix sign problem.
4099
4100 * term/i386/pc/at_keyboard.c (GRUB_MOD_FINI(at_keyboard)): Use proper
4101 unregister function.
4102
4103 2009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
4104
4105 * disk/scsi.c (grub_scsi_read): Fix sign problem.
4106
4107 * term/i386/pc/vga_text.c (grub_vga_text_init_fini). Fix declaration.
4108
4109 * util/grub-mkfont.c (usage): Fix typo.
4110
4111 * util/elf/grub-mkimage.c (load_modules): Fix warning.
4112
4113 2009-01-26 Daniel Mierswa <impulze@impulze.org>
4114
4115 * fs/fat.c (grub_fat_uuid): Fix shift of the first two bytes.
4116
4117 * commands/search.c (search_fs_uuid): Ignore case of the UUID.
4118
4119 * kern/misc.c (grub_strcasecmp): New function.
4120 (grub_strcasecmp): Use grub_size_t instead of int for length.
4121 Fix return value.
4122 * include/grub/misc.h: Update function prototypes.
4123
4124 2009-01-26 Robert Millan <rmh@aybabtu.com>
4125
4126 * configure.ac: Fix cross-compilation check.
4127
4128 2009-01-22 Christian Franke <franke@computer.org>
4129
4130 * kern/misc.c (grub_vsprintf): Fix size and termination of `format2'
4131 (precision) digit string. Allow `.format2' without `format1' (width).
4132 Limit input chars for `%s' output to `format2' if specified. This is
4133 compatible with standard printf ().
4134
4135 2009-01-22 Christian Franke <franke@computer.org>
4136
4137 * disk/ata.c (grub_ata_wait_status): Replace by ...
4138 (grub_ata_wait_not_busy): ... this function. Checks only BSY bit,
4139 other status bits may be invalid while BSY is asserted.
4140 (grub_ata_check_ready): New function.
4141 (grub_ata_cmd): Removed.
4142 (grub_ata_wait_drq): New function.
4143 (grub_ata_strncpy): Remove inline.
4144 (grub_ata_pio_read): Reduce to actual block transfer. BSY wait
4145 and error check now done by grub_ata_wait_drq ().
4146 (grub_ata_pio_write): Likewise.
4147 (grub_atapi_identify): Set DEV before check for !BSY. Use
4148 grub_ata_wait_drq () to wait for data.
4149 (grub_ata_device_initialize): Add status register check to
4150 detect missing SATA slave devices. Add debug messages.
4151 (grub_atapi_wait_drq): Use grub_ata_wait_not_busy ().
4152 (grub_atapi_packet): Set DEV before check for !BSY. Replace
4153 transfer loop by grub_ata_pio_write ().
4154 (grub_ata_identify): Set DEV before check for !BSY. Use
4155 grub_ata_wait_drq () to wait for data.
4156 (grub_ata_setaddress): Set DEV before check for !BSY.
4157 (grub_ata_readwrite): Remove duplicate code, handle batch/rest and
4158 read/write in one loop. Fix invalid command on write. Fix incomplete
4159 command on (size % batch) == 0. Add missing error check after write of
4160 last block. Add debug messages.
4161 (grub_atapi_read): Replace transfer loop by grub_ata_pio_read ().
4162
4163 2009-01-19 Christian Franke <franke@computer.org>
4164
4165 * disk/ata.c (GRUB_ATAPI_REG_*): New defines.
4166 (GRUB_ATAPI_IREASON_*): Likewise.
4167 (grub_ata_pio_write): Fix timeout error return.
4168 (grub_atapi_identify): Add grub_ata_wait () after cmd.
4169 (grub_atapi_wait_drq): New function.
4170 (grub_atapi_packet): New parameter `size'.
4171 Use grub_atapi_wait_drq () and direct write instead of
4172 grub_ata_pio_write ().
4173 (grub_atapi_read): Replace grub_ata_pio_read () by a loop which
4174 reads the number of bytes requested by the device for each DRQ
4175 assertion.
4176 (grub_atapi_write): Remove old implementation, return not
4177 implemented instead.
4178
4179 2009-01-19 Christian Franke <franke@computer.org>
4180
4181 * disk/scsi.c (grub_scsi_read10): Use scsi->blocksize instead
4182 of 512 to calculate data size.
4183 (grub_scsi_read12): Likewise.
4184 (grub_scsi_write10): Likewise.
4185 (grub_scsi_write12): Likewise.
4186 (grub_scsi_read): Adjust size according to blocksize.
4187 Add checks for invalid blocksize and unaligned transfer.
4188
4189 2009-01-19 Vesa Jääskeläinen <chaac@nic.fi>
4190
4191 * font/font.c (grub_font_loader_init): Re-position unknown glyph.
4192
4193 * term/gfxterm.c (write_char): Fix background rendering for wide
4194 width glyphs.
4195
4196 2009-01-19 Robert Millan <rmh@aybabtu.com>
4197
4198 * config.guess: Update to latest version from config git.
4199 * config.sub: Likewise.
4200
4201 2009-01-17 Felix Zielcke <fzielcke@z-51.de>
4202
4203 * Makefile.in: Change font compilation to use new grub-mkfont instead
4204 of java version.
4205
4206 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: Remove.
4207 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
4208 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
4209 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
4210 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
4211 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
4212 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
4213 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
4214 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
4215
4216 2009-01-16 Christian Franke <franke@computer.org>
4217
4218 * disk/ata.c (enum grub_ata_commands): Remove EXEC_DEV_DIAGNOSTICS.
4219 (enum grub_ata_timeout_milliseconds): New enum.
4220 (grub_ata_wait_status): Add parameter milliseconds.
4221 (grub_ata_cmd): Remove variable `err'. Remove wait for !DRQ to allow
4222 recovery from timed-out commands.
4223 (grub_ata_pio_read): Add parameter milliseconds. Fix error return,
4224 return grub_errno instead of REG_ERROR.
4225 (grub_ata_pio_write): Add parameter milliseconds.
4226 (grub_atapi_identify): Fix size of ATAPI IDENTIFY sector.
4227 Pass milliseconds to grub_ata_wait_status () and
4228 grub_ata_pio_read ().
4229 (grub_atapi_packet): Pass milliseconds to grub_ata_pio_write ().
4230 (grub_ata_identify): Remove variable `ataerr'. Pass milliseconds to
4231 grub_ata_wait_status (). Fix IDENTIFY timeout check.
4232 (grub_ata_device_initialize): Remove EXECUTE DEVICE DIAGNOSTICS.
4233 It is not suitable for device detection, because DEV bit is ignored,
4234 the command may run too long, and not all devices set the signature
4235 properly.
4236 (grub_ata_pciinit): Clear grub_errno before grub_ata_device_initialize ().
4237 (grub_ata_setaddress): Pass milliseconds to grub_ata_wait_status ().
4238 Fix device selection, DEV bit must be set first to address the registers
4239 of the correct device.
4240 (grub_ata_readwrite): Pass milliseconds to grub_ata_wait_status () and
4241 grub_ata_pio_read/write ().
4242 (grub_atapi_read): Pass milliseconds to grub_ata_pio_read ().
4243 (grub_atapi_write): Pass milliseconds to grub_ata_pio_write ().
4244
4245 2009-01-13 Carles Pina i Estany <carles@pina.cat>
4246
4247 * util/grub-editenv.c (main): Use fseeko(), not fseek().
4248
4249 2009-01-13 Bean <bean123ch@gmail.com>
4250
4251 * util/grub-mkfont.c (write_font): forget to remove some debug code.
4252
4253 2009-01-13 Bean <bean123ch@gmail.com>
4254
4255 * Makefile.in: (enable_grub_mkfont): New variable.
4256 (freetype_cflags): Likewise.
4257 (freetype_libs): Likewise.
4258
4259 * common.rmk (bin_UTILITIES): Add `grub-mkfont' if requested.
4260 (grub_mkfont_SOURCES): New variable.
4261 (grub_mkfont_CFLAGS): Likewise.
4262 (grub_mkfont_LDFLAGS): Likewise.
4263
4264 * configure.ac (--enable-grub-mkfont): New option. Check for freetype2
4265 library if `--enable-grub-mkfont' is requested.
4266 (enable_grub_mkfont): New variable.
4267 (freetype_cflags): Likewise.
4268 (freetype_libs): Likewise.
4269
4270 * util/grub-mkfont.c: New file.
4271
4272 2009-01-12 Christian Franke <franke@computer.org>
4273
4274 * disk/ata.c (grub_ata_pciinit): Fix bit numbers of compatibility
4275 mode check. Fix setting of compat_use[].
4276
4277 2009-01-10 Robert Millan <rmh@aybabtu.com>
4278
4279 Update a few copyright years which we forgot to do in 2008 (only for
4280 files whose changes made in 2008 were copyright-significant)
4281
4282 * Makefile.in: Add 2008 to Copyright line.
4283 * disk/ieee1275/ofdisk.c: Likewise.
4284 * disk/efi/efidisk.c: Likewise.
4285 * kern/dl.c: Likewise.
4286 * kern/sparc64/ieee1275/init.c: Likewise.
4287 * kern/mm.c: Likewise.
4288 * kern/efi/mm.c: Likewise.
4289 * boot/i386/pc/boot.S: Likewise.
4290 * genfslist.sh: Likewise.
4291 * fs/iso9660.c: Likewise.
4292 * fs/hfs.c: Likewise.
4293 * fs/jfs.c: Likewise.
4294 * fs/minix.c: Likewise.
4295 * fs/ufs.c: Likewise.
4296 * gensymlist.sh.in: Likewise.
4297 * genkernsyms.sh.in: Likewise.
4298 * include/grub/misc.h: Likewise.
4299 * include/grub/types.h: Likewise.
4300 * include/grub/symbol.h: Likewise.
4301 * include/grub/elf.h: Likewise.
4302 * include/grub/kernel.h: Likewise.
4303 * include/grub/disk.h: Likewise.
4304 * include/grub/dl.h: Likewise.
4305 * include/grub/i386/linux.h: Likewise.
4306 * include/grub/i386/pc/biosdisk.h: Likewise.
4307 * include/grub/efi/api.h: Likewise.
4308 * include/grub/efi/pe32.h: Likewise.
4309 * include/grub/util/misc.h: Likewise.
4310 * normal/execute.c: Likewise.
4311 * normal/arg.c: Likewise.
4312 * normal/completion.c: Likewise.
4313 * normal/lexer.c: Likewise.
4314 * normal/parser.y: Likewise.
4315 * normal/misc.c: Likewise.
4316 * commands/i386/pc/vbeinfo.c: Likewise.
4317 * commands/hexdump.c: Likewise.
4318 * commands/terminal.c: Likewise.
4319 * commands/ls.c: Likewise.
4320 * commands/help.c: Likewise.
4321 * partmap/pc.c: Likewise.
4322 * loader/efi/chainloader.c: Likewise.
4323 * loader/multiboot_loader.c: Likewise.
4324 * loader/i386/pc/multiboot2.c: Likewise.
4325 * term/efi/console.c: Likewise.
4326 * term/i386/pc/serial.c: Likewise.
4327 * util/lvm.c: Likewise.
4328 * util/console.c: Likewise.
4329 * util/i386/efi/grub-mkimage.c: Likewise.
4330 * util/raid.c: Likewise.
4331
4332 2009-01-06 Vesa Jääskeläinen <chaac@nic.fi>
4333
4334 * commands/videotest.c: Removed include to grub/machine/memory.h.
4335
4336 * conf/i386-pc.rmk (pkglib_MODULES): Removed video.mod, gfxterm.mod,
4337 videotest.mod, bitmap.mod, tga.mod, jpeg.mod, png.mod.
4338 (video_mod_SOURCES): Removed.
4339 (video_mod_CFLAGS): Likewise.
4340 (video_mod_LDFLAGS): Likewise.
4341 (gfxterm_mod_SOURCES): Likewise.
4342 (gfxterm_mod_CFLAGS): Likewise.
4343 (gfxterm_mod_LDFLAGS): Likewise.
4344 (videotest_mod_SOURCES): Likewise.
4345 (videotest_mod_CFLAGS): Likewise.
4346 (videotest_mod_LDFLAGS): Likewise.
4347 (bitmap_mod_SOURCES): Likewise.
4348 (bitmap_mod_CFLAGS): Likewise.
4349 (bitmap_mod_LDFLAGS): Likewise.
4350 (tga_mod_SOURCES): Likewise.
4351 (tga_mod_CFLAGS): Likewise.
4352 (tga_mod_LDFLAGS): Likewise.
4353 (jpeg_mod_SOURCES): Likewise.
4354 (jpeg_mod_CFLAGS): Likewise.
4355 (jpeg_mod_LDFLAGS): Likewise.
4356 (png_mod_SOURCES): Likewise.
4357 (png_mod_CFLAGS): Likewise.
4358 (png_mod_LDFLAGS): Likewise.
4359
4360 * conf/common.rmk (pkglib_MODULES): Added video.mod, videotest.mod,
4361 bitmap.mod, tga.mod, jpeg.mod, png.mod, font.mod, gfxterm.mod
4362 (video_mod_SOURCES): Added.
4363 (video_mod_CFLAGS): Likewise.
4364 (video_mod_LDFLAGS): Likewise.
4365 (videotest_mod_SOURCES): Likewise.
4366 (videotest_mod_CFLAGS): Likewise.
4367 (videotest_mod_LDFLAGS): Likewise.
4368 (bitmap_mod_SOURCES): Likewise.
4369 (bitmap_mod_CFLAGS): Likewise.
4370 (bitmap_mod_LDFLAGS): Likewise.
4371 (tga_mod_SOURCES): Likewise.
4372 (tga_mod_CFLAGS): Likewise.
4373 (tga_mod_LDFLAGS): Likewise.
4374 (jpeg_mod_SOURCES): Likewise.
4375 (jpeg_mod_CFLAGS): Likewise.
4376 (jpeg_mod_LDFLAGS): Likewise.
4377 (png_mod_SOURCES): Likewise.
4378 (png_mod_CFLAGS): Likewise.
4379 (png_mod_LDFLAGS): Likewise.
4380 (gfxterm_mod_SOURCES): Likewise.
4381 (gfxterm_mod_CFLAGS): Likewise.
4382 (gfxterm_mod_LDFLAGS): Likewise.
4383
4384 * term/gfxterm.c: Removed include to grub/machine/memory.h,
4385 grub/machine/console.h.
4386
4387 2009-01-04 Jerone Young <jerone@gmail.com>
4388
4389 Make on screen instructions clearer
4390
4391 Based on patch created by Jidanni <jidanni@jidanni.org>
4392
4393 * normal/menu.c: print clearer instructions on the screen
4394
4395 2009-01-02 Colin D Bennett <colin@gibibit.com>
4396
4397 New font engine.
4398
4399 Additional changes by Vesa Jääskeläinen <chaac@nic.fi> to adapt to
4400 build system and fixed gfxterm.c to work with different sized fonts.
4401
4402 * configure.ac: Changed UNIFONT_HEX to UNIFONT_BDF.
4403
4404 * configure: Re-generated.
4405
4406 * DISTLIST: Removed font/manager.c.
4407 Added font/font.c.
4408 Added font/font_cmd.c.
4409
4410 * Makefile.in: Changed UNIFONT_HEX to UNIFONT_BDF. Added Font tool
4411 compilation.
4412
4413 * include/grub/misc.h (grub_utf8_to_ucs4): Changed prototype. Changed users.
4414
4415 * kern/misc.c (grub_utf8_to_ucs4): Changed prototype.
4416
4417 * kern/term.c: Changed users of grub_utf8_to_ucs4.
4418
4419 * normal/menu.c: Likewise.
4420
4421 * conf/common.rmk (font_mod_SOURCES): Removed font/manager.c.
4422 (font_mod_SOURCES): Added font/font_cmd.c, font/font.c.
4423
4424 * include/grub/font.h: Replaced with new file.
4425
4426 * include/grub/video.h (GRUB_VIDEO_MODE_TYPE_ALPHA): Changed value.
4427 (GRUB_VIDEO_MODE_TYPE_DOUBLE_BUFFERED): Likewise.
4428 (GRUB_VIDEO_MODE_TYPE_COLOR_MASK): Likewise.
4429 (GRUB_VIDEO_MODE_TYPE_1BIT_BITMAP): Added.
4430 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_1BIT_PACKED.
4431 (grub_video_mode_info): Added bg_red, bg_green, bg_blue, bg_alpha,
4432 fg_red, fg_green, fg_blue, fg_alpha.
4433 (grub_video_adapter): Removed blit_glyph.
4434 (grub_video_blit_glyph): Removed.
4435
4436 * font/manager.c: Removed file.
4437
4438 * font/font.c: New file.
4439
4440 * font/font_cmd.c: Likewise.
4441
4442 * video/video.c (grub_video_blit_glyph): Removed.
4443
4444 * video/i386/pc/vbe.c (grub_video_vbe_map_rgb): Added 1-bit support.
4445 (grub_video_vbe_map_rgba): Likewise.
4446 (grub_video_vbe_unmap_color_int): Likewise.
4447 (grub_video_vbe_blit_glyph): Removed.
4448 (grub_video_vbe_adapter): Removed blit_glyph.
4449
4450 * video/i386/pc/vbeutil.c (get_data_ptr): Added 1-bit support.
4451 (get_pixel): Likewise.
4452 (set_pixel): Likewise.
4453
4454 * commands/videotest.c (grub_cmd_videotest): Added more tests for fonts.
4455
4456 * term/gfxterm.c: Adapted to new font engine.
4457
4458 * term/i386/pc/vesafb.c: Marked as deprecated. Made it compile.
4459
4460 * term/i386/pc/vga.c: Likewise.
4461
4462 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: New file.
4463
4464 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
4465
4466 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
4467
4468 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
4469
4470 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
4471
4472 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
4473
4474 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
4475
4476 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
4477
4478 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
4479
4480 * util/grub.d/00_header.in: Changed to use new loadfont command.
4481
4482 * util/grub-mkconfig_lib.in: Changed font extension.
4483
4484 2008-12-28 Felix Zielcke <fzielcke@z-51.de>
4485
4486 * util/getroot.c (grub_util_get_grub_dev): Add support for
4487 /dev/md/dNNpNN style partitionable mdraid devices.
4488
4489 2008-12-12 Alex Smith <alex@alex-smith.me.uk>
4490
4491 * fs/i386/pc/pxe.c (grub_pxefs_open): Handle the one open connection
4492 at a time limit of the PXE TFTP API correctly.
4493 (grub_pxefs_close): Likewise.
4494
4495 2008-11-29 Robert Millan <rmh@aybabtu.com>
4496
4497 * disk/ata.c (grub_ata_pciinit): Handle errors raised by
4498 grub_ata_device_initialize() calls.
4499
4500 2008-11-28 Krzysztof Smiechowicz <deadwood@wp.pl>
4501
4502 * fs/affs.c (grub_affs_iterate_dir): Return failure when directory
4503 iteration failed.
4504 * fs/sfs.c (grub_sfs_iterate_dir): Likewise.
4505
4506 2008-11-28 Robert Millan <rmh@aybabtu.com>
4507
4508 Fix build on powerpc-ieee1275. Based on patch created by
4509 Manoel Abranches <mrabran@linux.vnet.ibm.com>.
4510 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
4511 `kern/ieee1275/mmap.c'.
4512 * include/grub/powerpc/ieee1275/memory.h: New file.
4513
4514 Provide grub-install on coreboot.
4515 * conf/i386-coreboot.rmk (sbin_SCRIPTS): Add `grub-install'.
4516 (grub_install_SOURCES): New variable.
4517 * util/i386/pc/grub-install.in: Add a few condition checks to make it
4518 usable on coreboot.
4519
4520 2008-11-25 Felix Zielcke <fzielcke@z-51.de>
4521
4522 * util/grub-fstest.c (grub_term_get_current_input): Change return type
4523 to `grub_term_input_t'.
4524 (grub_term_get_current_output): Change return type to
4525 `grub_term_output_t'.
4526
4527 2008-11-22 Robert Millan <rmh@aybabtu.com>
4528
4529 Fix breakage on coreboot due to declaration mismatch.
4530 * term/i386/pc/vga_text.c (grub_vga_text_init_fini): New function.
4531 (grub_vga_text_term): Use grub_vga_text_init_fini() instead of
4532 grub_vga_text_cls().
4533
4534 * kern/i386/loader.S (grub_multiboot_backward_relocator): Improve
4535 comments. Avoid copying one more byte than necessary (just in case).
4536
4537 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Change link address
4538 to 0x200000 (avoids trouble with some OFW implementations, and matches
4539 with the one in Yaboot).
4540 Reported by Manoel Abranches
4541
4542 2008-11-20 Robert Millan <rmh@aybabtu.com>
4543
4544 * kern/i386/coreboot/init.c (grub_time_tics): Remove variable.
4545 (grub_get_rtc, grub_exit): Abort with grub_fatal() if called.
4546
4547 * util/grub-mkconfig_lib.in (grub_warn): New function.
4548 (convert_system_path_to_grub_path): Use grub_warn() when issuing
4549 warnings, to obtain consistent formatting.
4550 * util/grub.d/00_header.in: Likewise.
4551 * util/update-grub_lib.in: Likewise.
4552
4553 * loader/i386/linux.c (allocate_pages): Fix a warning.
4554 Move comment text to `#error' stanza.
4555
4556 Harmonize ieee1275's grub_available_iterate() with the generic
4557 grub_machine_mmap_iterate() interface (fixes a recently-introduced
4558 build problem on i386-ieee1275):
4559 * kern/ieee1275/openfw.c (grub_available_iterate): Moved from here ...
4560 * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): ... here. Add third
4561 parameter `type'. Update all users of this function.
4562 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
4563 `kern/ieee1275/mmap.c'.
4564 * kern/ieee1275/init.c
4565 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): Replace
4566 with ...
4567 (grub_machine_mmap_iterate): ... this.
4568 * include/grub/i386/pc/memory.h (grub_machine_mmap_iterate): Change
4569 return type to `grub_err_t'. Update all implementations of this
4570 function prototype.
4571 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_iterate):
4572 Likewise.
4573
4574 Add `lsmmap' command (lists firmware-provided memory map):
4575 * commands/lsmmap.c: New file.
4576 * conf/i386-pc.rmk (pkglib_MODULES): Add `lsmmap.mod'.
4577 (lsmmap_mod_SOURCES, lsmmap_mod_CFLAGS, lsmmap_mod_LDFLAGS): New
4578 variables.
4579 * conf/powerpc-ieee1275.rmk: Likewise.
4580 * conf/i386-coreboot.rmk: Likewise.
4581 * conf/i386-ieee1275.rmk: Likewise.
4582
4583 2008-11-19 Robert Millan <rmh@aybabtu.com>
4584
4585 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Fix a typo.
4586 * loader/i386/linux.c (grub_rescue_cmd_initrd): Implement a few needed
4587 constraints to initrd allocation (based on code from
4588 loader/i386/pc/linux.c). Without them, initrd was allocated too high
4589 for Linux to find it.
4590
4591 2008-11-14 Robert Millan <rmh@aybabtu.com>
4592
4593 * fs/cpio.c (grub_cpio_open): Compare `name' and `fn' by hand in
4594 order to cope with duplicate slashes.
4595
4596 2008-11-14 Robert Millan <rmh@aybabtu.com>
4597
4598 * include/grub/i386/coreboot/memory.h (GRUB_MEMORY_MACHINE_LOWER_SIZE):
4599 Redefine to match with GRUB_MEMORY_MACHINE_UPPER_START (0x100000). We
4600 don't want to mess with lower memory, because it is used in the Linux
4601 loader.
4602
4603 * loader/i386/linux.c (allocate_pages): Allocate `real_mode_mem' in
4604 an appropriate place in lower memory, between 0x10000 and 0x90000,
4605 like loader/i386/efi/linux.c does. Linux often panics if real_mode_mem
4606 is in our heap (probably as a result of it being corrupted during
4607 decompression). Add #error instance with comment to explain why this
4608 loader isn't currently usable on PC/BIOS.
4609
4610 2008-11-14 Robert Millan <rmh@aybabtu.com>
4611
4612 * term/i386/pc/serial.c [! GRUB_MACHINE_PCBIOS]
4613 (GRUB_SERIAL_PORT_NUM): Fix miscalculation.
4614
4615 2008-11-12 Robert Millan <rmh@aybabtu.com>
4616
4617 Make loader/i386/linux.c buildable on i386-pc (although disabled).
4618
4619 * include/grub/i386/pc/init.h: Include `<grub/machine/memory.h>'.
4620 (struct grub_machine_mmap_entry, grub_machine_mmap_iterate): Move
4621 from here ...
4622 * include/grub/i386/pc/memory.h: ... to here.
4623
4624 2008-11-12 Robert Millan <rmh@aybabtu.com>
4625
4626 Fix build problems on i386-ieee1275 and *-efi (introduced by vga_text
4627 split).
4628
4629 * include/grub/i386/pc/console.h: Include `<grub/i386/vga_common.h>'.
4630 (grub_console_cur_color, grub_console_real_putchar)
4631 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
4632 (grub_console_setcolorstate, grub_console_setcolor)
4633 (grub_console_getcolor): Move from here ...
4634 * include/grub/i386/vga_common.h: ... to here (new file).
4635
4636 * term/i386/pc/vga_text.c: Replace `<grub/machine/console.h>' with
4637 `<grub/i386/vga_common.h>' and `<grub/cpu/io.h>' with
4638 `<grub/i386/io.h>'.
4639 * term/i386/vga_common.c: Replace `<grub/machine/console.h>' with
4640 `<grub/i386/vga_common.h>'.
4641
4642 2008-11-12 Robert Millan <rmh@aybabtu.com>
4643
4644 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `term/i386/vga_common.c'.
4645 * conf/i386.rmk (pkglib_MODULES): Add `vga_text.mod'.
4646 (vga_text_mod_SOURCES, vga_text_mod_CFLAGS, vga_text_mod_LDFLAGS): New
4647 variables.
4648 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
4649 `term/i386/pc/console.c' with `term/i386/vga_common.c'.
4650
4651 * kern/i386/coreboot/init.c (grub_machine_init): Replace call to
4652 grub_console_init() with call to grub_vga_text_init().
4653 (grub_machine_fini): Replace call to
4654 grub_console_fini() with call to grub_vga_text_fini() and
4655 grub_at_keyboard_fini().
4656
4657 * include/grub/i386/pc/console.h: Include `<grub/term.h>'.
4658 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
4659 (grub_console_setcolorstate, grub_console_setcolor)
4660 (grub_console_getcolor): New function prototypes.
4661
4662 * term/i386/pc/vga_text.c: Include `<grub/dl.h>'.
4663 (grub_vga_text_getxy, grub_vga_text_gotoxy, grub_vga_text_cls)
4664 (grub_vga_text_setcursor): Static-ize.
4665 (grub_vga_text_term): New structure.
4666 (GRUB_MOD_INIT(vga_text), GRUB_MOD_FINI(vga_text)): New functions.
4667
4668 * term/i386/pc/console.c: Remove `<grub/machine/machine.h>'.
4669 (grub_console_cur_color, grub_console_standard_color)
4670 (grub_console_normal_color, grub_console_highlight_color)
4671 (map_char, grub_console_putchar, grub_console_getcharwidth)
4672 (grub_console_getwh, grub_console_setcolorstate, grub_console_setcolor)
4673 (grub_console_getcolor): Move from here ...
4674 * term/i386/vga_common.c: ... to here (same function names).
4675
4676 2008-11-12 Robert Millan <rmh@aybabtu.com>
4677
4678 Use newly-added Multiboot support in coreboot.
4679
4680 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
4681 `kern/i386/coreboot/mmap.c' with `kern/i386/multiboot_mmap.c'.
4682
4683 * kern/i386/coreboot/startup.S: Enable Multiboot header, fix its
4684 alignment, set `MULTIBOOT_MEMORY_INFO' flag.
4685 (codestart): Store the MBI in `startup_multiboot_info' when we're
4686 being loaded using Multiboot.
4687
4688 * kern/i386/coreboot/init.c (grub_machine_init): Move
4689 grub_at_keyboard_init() call to beginning of function (useful for
4690 debugging). Call grub_machine_mmap_init() before attempting to use
4691 grub_machine_mmap_iterate().
4692 (grub_lower_mem, grub_upper_mem): Move from here ...
4693 * kern/i386/multiboot_mmap.c (grub_lower_mem, grub_upper_mem): ... to
4694 here (new file).
4695
4696 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_init): New
4697 function prototype.
4698
4699 2008-11-12 Robert Millan <rmh@aybabtu.com>
4700
4701 Fix a regression introduced by the at_keyboard.mod split. Because
4702 some terminals are default on some platforms and non-default on
4703 others, the first terminal being registered determines which is
4704 going to be default.
4705
4706 * kern/term.c (grub_term_register_input): If this is the first
4707 terminal being registered, set it as the current one.
4708 (grub_term_register_output): Likewise.
4709
4710 * term/efi/console.c (grub_console_init): Do not call
4711 grub_term_set_current_output() or grub_term_set_current_input().
4712 * term/ieee1275/ofconsole.c (grub_console_init): Likewise.
4713 * term/i386/pc/console.c (grub_console_init): Likewise.
4714 (grub_console_fini): Do not call grub_term_set_current_input()
4715 (but leave grub_term_set_current_output() to restore text mode).
4716
4717 2008-11-10 Robert Millan <rmh@aybabtu.com>
4718
4719 * util/grub.d/00_header.in: Add backward compatibility check for
4720 versions of terminal.mod that don't understand `terminal_input' or
4721 `terminal_output'.
4722
4723 2008-11-09 Robert Millan <rmh@aybabtu.com>
4724
4725 * commands/terminal.c (GRUB_MOD_FINI(terminal)): Unregister
4726 `terminal_input' / `terminal_output', not `terminal'.
4727
4728 2008-11-08 Robert Millan <rmh@aybabtu.com>
4729
4730 * Makefile.in (include_DATA): Fix srcdir=. assumption.
4731 (DISTCLEANFILES): Add `build_env.mk'.
4732
4733 2008-11-08 Robert Millan <rmh@aybabtu.com>
4734
4735 * term/i386/pc/vesafb.c (grub_vesafb_term): Change type to
4736 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
4737 members. Update all users.
4738 * util/console.c (grub_ncurses_term): Split in ...
4739 (grub_ncurses_term_input): ... this, and ...
4740 (grub_ncurses_term_output): ... this. Update all users.
4741 * term/ieee1275/ofconsole.c: Remove stale `#endif'.
4742
4743 2008-11-08 Robert Millan <rmh@aybabtu.com>
4744
4745 * Makefile.in (PKGLIB): Add $(pkglib_BUILDDIR).
4746 (PKGDATA): Add $(pkgdata_SRCDIR).
4747 (pkglib_BUILDDIR): New variable.
4748 (pkgdata_SRCDIR): New variable.
4749 (build_env.mk): New target.
4750 (include_DATA): New variable.
4751 (install-local): Install $(include_DATA) files in $(includedir).
4752
4753 2008-11-07 Pavel Roskin <proski@gnu.org>
4754
4755 * gendistlist.sh: Use C locale for sorting to ensure consistent
4756 output on all systems.
4757
4758 * util/grub.d/00_header.in: Remove incorrect space before
4759 "serial".
4760
4761 2008-11-07 Robert Millan <rmh@aybabtu.com>
4762
4763 * include/multiboot2.h (struct multiboot_header): Add `flags' member as
4764 per specification.
4765 * loader/multiboot2.c (grub_multiboot2): Fix Multiboot2 header check.
4766 * loader/multiboot_loader.c (find_multi_boot2_header): New function
4767 (based on find_multi_boot1_header).
4768 (grub_rescue_cmd_multiboot_loader): Check for Multiboot2 header,
4769 using find_multi_boot2_header(), and abort if neither Multiboot or
4770 Multiboot headers were found.
4771
4772 2008-11-07 Robert Millan <rmh@aybabtu.com>
4773
4774 Modularize at_keyboard.mod:
4775
4776 * conf/i386.rmk (pkglib_MODULES): Add `at_keyboard.mod'.
4777 (at_keyboard_mod_SOURCES, at_keyboard_mod_CFLAGS)
4778 (at_keyboard_mod_LDFLAGS): New variables.
4779
4780 Actual terminal split:
4781
4782 * include/grub/term.h (struct grub_term): Split in ...
4783 (struct grub_term_input): ... this, and ...
4784 (struct grub_term_output): ... this. Update all users.
4785 (grub_term_set_current): Split in ...
4786 (grub_term_set_current_input): ... this, and ...
4787 (grub_term_set_current_output): ... this.
4788 (grub_term_get_current): Split in ...
4789 (grub_term_get_current_input): ... this, and ...
4790 (grub_term_get_current_output): ... this.
4791 (grub_term_register): Split in ...
4792 (grub_term_register_input): ... this, and ...
4793 (grub_term_register_output): ... this.
4794 (grub_term_unregister): Split in ...
4795 (grub_term_unregister_input): ... this, and ...
4796 (grub_term_unregister_output): ... this.
4797 (grub_term_iterate): Split in ...
4798 (grub_term_iterate_input): ... this, and ...
4799 (grub_term_iterate_output): ... this.
4800
4801 * kern/term.c (grub_term_list): Split in ...
4802 (grub_term_list_input): ... this, and ...
4803 (grub_term_list_output): ... this. Update all users.
4804 (grub_cur_term): Split in ...
4805 (grub_cur_term_input): ... this, and ...
4806 (grub_cur_term_output): ... this. Update all users.
4807 (grub_term_set_current): Split in ...
4808 (grub_term_set_current_input): ... this, and ...
4809 (grub_term_set_current_output): ... this.
4810 (grub_term_get_current): Split in ...
4811 (grub_term_get_current_input): ... this, and ...
4812 (grub_term_get_current_output): ... this.
4813 (grub_term_register): Split in ...
4814 (grub_term_register_input): ... this, and ...
4815 (grub_term_register_output): ... this.
4816 (grub_term_unregister): Split in ...
4817 (grub_term_unregister_input): ... this, and ...
4818 (grub_term_unregister_output): ... this.
4819 (grub_term_iterate): Split in ...
4820 (grub_term_iterate_input): ... this, and ...
4821 (grub_term_iterate_output): ... this.
4822
4823 * kern/misc.c (grub_abort): Split use of grub_term_get_current() into
4824 a check for input and one for output (and only attempt to get keys
4825 from user when input works).
4826
4827 * util/grub-probe.c (grub_term_get_current): Split in ...
4828 (grub_term_get_current_input): ... this, and ...
4829 (grub_term_get_current_output): ... this.
4830 * util/grub-fstest.c: Likewise.
4831 * util/i386/pc/grub-setup.c: Likewise.
4832 * util/grub-editenv.c: Likewise.
4833
4834 Portability adjustments:
4835
4836 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Remove
4837 `term/i386/pc/at_keyboard.c'.
4838 * kern/ieee1275/init.c [__i386__] (grub_machine_init): Remove call to
4839 grub_keyboard_controller_init() (now handled by terminal .init).
4840 * kern/i386/coreboot/init.c (grub_machine_init): Add call to
4841 grub_at_keyboard_init().
4842 * include/grub/i386/ieee1275/console.h (grub_keyboard_controller_init)
4843 (grub_console_checkkey, grub_console_getkey): Remove (now provided by
4844 at_keyboard.mod via input terminal interface).
4845 * include/grub/i386/coreboot/console.h: Convert into a stub for
4846 `<grub/i386/pc/console.h>'.
4847
4848 Migrate full terminals to new API:
4849
4850 * term/efi/console.c (grub_console_term): Split into ...
4851 (grub_console_term_input): ... this, and ...
4852 (grub_console_term_output): ... this. Update all users.
4853 * term/ieee1275/ofconsole.c: Remove __i386__ hack.
4854 (grub_ofconsole_init): Split into ...
4855 (grub_ofconsole_init_input): ... this, and ...
4856 (grub_ofconsole_init_output): ... this.
4857 (grub_ofconsole_term): Split into ...
4858 (grub_ofconsole_term_input): ... this, and ...
4859 (grub_ofconsole_term_output): ... this. Update all users.
4860 * term/i386/pc/serial.c (grub_serial_term): Split into ...
4861 (grub_serial_term_input): ... this, and ...
4862 (grub_serial_term_output): ... this. Update all users.
4863 * term/i386/pc/console.c (grub_console_term): Split into ...
4864 (grub_console_term_input): ... this, and ...
4865 (grub_console_term_output): ... this. Update all users.
4866 (grub_console_term_input): Only enable it on PC/BIOS platform.
4867 (grub_console_init): Remove grub_keyboard_controller_init() call.
4868
4869 Migrate input terminals to new API:
4870
4871 * term/i386/pc/at_keyboard.c: Replace `cpu' and `machine' with
4872 `i386' and `i386/pc' to enable build on x86_64 (this driver is
4873 i386-specific anyway).
4874 (grub_console_checkkey): Rename to ...
4875 (grub_at_keyboard_checkkey): ... this. Static-ize. Update all
4876 users.
4877 (grub_keyboard_controller_orig): New variable.
4878 (grub_console_getkey): Rename to ...
4879 (grub_at_keyboard_getkey): ... this. Static-ize. Update all
4880 users.
4881 (grub_keyboard_controller_init): Static-ize. Save original
4882 controller value so that it can be restored ...
4883 (grub_keyboard_controller_fini): ... here (new function).
4884 (grub_at_keyboard_term): New structure.
4885 (GRUB_MOD_INIT(at_keyboard), GRUB_MOD_FINI(at_keyboard)): New
4886 functions.
4887
4888 Migrate output terminals to new API:
4889
4890 * term/i386/pc/vga.c (grub_vga_term): Change type to
4891 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
4892 members. Update all users.
4893 * term/gfxterm.c (grub_video_term): Change type to
4894 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
4895 members. Update all users.
4896 * include/grub/i386/pc/console.h (grub_console_checkkey)
4897 (grub_console_getkey): Do not export (no longer needed by gfxterm,
4898 etc).
4899
4900 Migrate `terminal' command and userland tools to new API:
4901
4902 * commands/terminal.c (grub_cmd_terminal): Split into ...
4903 (grub_cmd_terminal_input): ... this, and ...
4904 (grub_cmd_terminal_output): ... this.
4905 (GRUB_MOD_INIT(terminal)): Split `terminal' command in two commands:
4906 `terminal_input' and `terminal_output'.
4907 * util/grub.d/00_header.in: Adjust `terminal' calls to new
4908 `terminal_input' / `terminal_output' API.
4909 * util/grub-mkconfig.in: Export ${GRUB_TERMINAL_INPUT} and
4910 ${GRUB_TERMINAL_OUTPUT} instead of ${GRUB_TERMINAL} (and if user
4911 provided ${GRUB_TERMINAL}, convert it).
4912
4913 2008-11-04 Robert Millan <rmh@aybabtu.com>
4914
4915 * util/grub.d/10_freebsd.in: New file. Generate grub configuration
4916 for FreeBSD.
4917 * conf/common.rmk (grub-mkconfig_SCRIPTS): Add 10_freebsd.
4918
4919 2008-11-03 Bean <bean123ch@gmail.com>
4920
4921 * kern/elf.c (grub_elf32_load): Revert to previous code.
4922 (grub_elf64_load): Likewise.
4923
4924 * loader/i386/bsd.c (grub_bsd_elf32_hook): Change return address.
4925
4926 2008-11-01 Robert Millan <rmh@aybabtu.com>
4927
4928 * Makefile.in (CPPFLAGS): Fix builddir=. assumption.
4929 (TARGET_CPPFLAGS): Likewise.
4930 * genmk.rb (mod_src): Fix builddir=. and srcdir=. assumptions.
4931
4932 2008-11-01 Carles Pina i Estany <carles@pina.cat>
4933
4934 * normal/menu.c (run_menu): Add Previous and Next Page keys in menu.
4935
4936 2008-10-29 Guillem Jover <guillem.jover@nokia.com>
4937
4938 * disk/lvm.c (grub_lvm_scan_device): Fix error recovery by delaying the
4939 addition of objects until the code is not going to be able to fail.
4940
4941 2008-10-29 Guillem Jover <guillem.jover@nokia.com>
4942
4943 * disk/lvm.c (grub_lvm_scan_device): Fix possible NULL value handling
4944 (add a missing NULL check, and correct them by moving the pointer
4945 operations after the actual check).
4946
4947 2008-10-29 Robert Millan <rmh@aybabtu.com>
4948
4949 * util/i386/pc/grub-install.in: Handle empty string as output from
4950 make_system_path_relative_to_its_root().
4951
4952 2008-10-05 Hans Lambermont <hans@lambermont.dyndns.org>
4953
4954 * disk/lvm.c (grub_lvm_scan_device): Allocate buffer space for the
4955 circular metadata worst case scenario. If the metadata is circular
4956 then copy the wrap in place.
4957 * include/grub/lvm.h: Add GRUB_LVM_MDA_HEADER_SIZE, from the LVM2
4958 project lib/format_text/layout.h
4959 Circular metadata bug found and patch debugged by Jan Derk Gerlings.
4960
4961 2008-10-03 Felix Zielcke <fzielcke@z-51.de>
4962
4963 * util/i386/pc/grub-install.in: Source grub-mkconfig_lib instead of update-grub_lib.
4964
4965 2008-10-03 Felix Zielcke <fzielcke@z-51.de>
4966
4967 * util/update-grub_lib.in: Mention filename in warning message.
4968
4969 2008-09-29 Felix Zielcke <fzielcke@z-51.de>
4970
4971 * NEWS: Update for rename of update-grub to grub-mkconfig.
4972
4973 2008-09-29 Felix Zielcke <fzielcke@z-51.de>
4974
4975 * util/update-grub_lib.in: Copy to ...
4976 * util/grub-mkconfig_lib.in: ... this. Update all users.
4977 * util/update-grub_lib.in: Make it a stub to `grub-mkconfig_lib.in'.
4978 * util/update-grub.in: Rename to ...
4979 * util/grub-mkconfig.in: ... this. Update all users. Remove `-y'
4980 option. Add `--output' option to allow users to specify the generated
4981 configuration file. Default to stdout.
4982 (update_grub_dir): Rename to ...
4983 (grub_mkconfig_dir): ... this.
4984 (grub_cfg): Default to an empty string.
4985 * conf/common.rmk (update-grub): Rename to ...
4986 (grub-mkconfig): ... this.
4987 (update-grub_lib): Copy to ...
4988 (grub-mkconfig_lib): ... this.
4989 (update-grub_SCRIPTS): Copy to ...
4990 (grub-mkconfig_SCRIPTS): ... this. Update all users.
4991 (update-grub_DATA): Rename to ...
4992 (grub-mkconfig_DATA): ... this.
4993
4994 2008-09-28 Robert Millan <rmh@aybabtu.com>
4995
4996 * fs/iso9660.c (struct grub_iso9660_primary_voldesc): Rename `created'
4997 to `modified'. Add the real `created' field.
4998 (grub_iso9660_uuid): Use `modified' rather than `created' for
4999 constructing the UUID.
5000
5001 2008-09-28 Felix Zielcke <fzielcke@z-51.de>
5002
5003 fs/jfs.c (grub_jfs_find_file): Treat multiple slashes like one.
5004 Based on code from Tomas Ebenlendr <ebik@ucw.cz>.
5005
5006 2008-09-28 Bean <bean123ch@gmail.com>
5007
5008 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a bug in the previous patch.
5009 Thanks to Christian Franke for finding this bug.
5010
5011 2008-09-25 Robert Millan <rmh@aybabtu.com>
5012
5013 * util/grub-mkdevicemap.c (make_device_map): Actually replace all
5014 instances of grub_util_get_disk_name() (see previous commit).
5015
5016 2008-09-25 Robert Millan <rmh@aybabtu.com>
5017
5018 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Remove
5019 `util/i386/get_disk_name.c'.
5020 * conf/i386-efi.rmk: Likewise.
5021 * conf/x86_64-efi.rmk: Likewise.
5022 * conf/i386-coreboot.rmk: Likewise.
5023 * conf/i386-ieee1275.rmk: Likewise.
5024 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Remove
5025 `util/ieee1275/get_disk_name.c'.
5026 * include/grub/util/misc.h (grub_util_get_disk_name): Remove.
5027 * util/ieee1275/get_disk_name.c: Remove file.
5028 * util/i386/get_disk_name.c: Remove file.
5029 * util/grub-mkdevicemap.c (make_device_map): Back to hardcoding
5030 "hd%d" for device.map entries, rather than using
5031 grub_util_get_disk_name().
5032
5033 2008-09-24 Carles Pina i Estany <carles@pina.cat>
5034
5035 * disk/dmraid_nvidia.c (grub_dmraid_nv_detect): Fix `unused parameter'
5036 warning.
5037 * commands/i386/pc/pxecmd.c (dmraid_nvidia): Likewise.
5038
5039 2008-09-24 Carles Pina i Estany <carles@pina.cat>
5040
5041 * include/grub/i386/pc/console.h (GRUB_TERM_NPAGE):
5042 Changed to 0x5100.
5043 (GRUB_TERM_PPAGE): Changed to 0x4900.
5044
5045 2008-09-24 Robert Millan <rmh@aybabtu.com>
5046
5047 * include/grub/powerpc/ieee1275/console.h (GRUB_CONSOLE_KEY_*): Remove
5048 macros (they were i386-pc specific).
5049 * include/grub/sparc64/ieee1275/console.h: Likewise.
5050 * include/grub/efi/console.h: Likewise.
5051
5052 2008-09-22 Bean <bean123ch@gmail.com>
5053
5054 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a rare case where $BITMAP is
5055 resident and in attribute list.
5056
5057 * include/grub/ntfs.h (BMP_LEN): Removed.
5058
5059 2008-09-22 Bean <bean123ch@gmail.com>
5060
5061 * disk/ata.c (grub_atapi_open): Initialize devfnd, no need to set
5062 scsi->name and scsi->luns, as they will be set in grub_scsi_open.
5063
5064 * disk/scsi.c (grub_scsi_open): Don't call p->close (scsi) here when
5065 error occurs, as grub_disk_open will call grub_disk_close, which will
5066 call p->close (scsi).
5067
5068 2008-09-21 Felix Zielcke <fzielcke@z-51.de>
5069
5070 * configure.ac (AC_INIT): Quote `GRUB' string and version number.
5071 (AC_PREREQ): Bumped to 2.59.
5072 (AC_TRY_COMPILE): Replace obsolete macro with ...
5073 (AC_COMPILE_IFELSE): ... this.
5074 * aclocal.m4 (AC_TRY_LINK): Replace obsolete macro with ...
5075 (AC_LINK_IFELSE): ... this.
5076
5077 2008-09-21 Felix Zielcke <fzielcke@z-51.de>
5078
5079 * autogen.sh: Add a call to `gendistlist.sh'.
5080
5081 2008-09-19 Christian Franke <franke@computer.org>
5082
5083 * aclocal.m4 (grub_CHECK_ENABLE_EXECUTE_STACK): New function.
5084 * configure.ac: Call grub_CHECK_ENABLE_EXECUTE_STACK.
5085 * include/grub/misc.h [NEED_ENABLE_EXECUTE_STACK]:
5086 Export __enable_execute_stack() to modules.
5087 * kern/misc.c [NEED_ENABLE_EXECUTE_STACK] (__enable_execute_stack):
5088 New function.
5089
5090 2008-09-09 Felix Zielcke <fzielcke@z-51.de>
5091
5092 * Makefile.in (RMKFILES): Add `i386.rmk' and `x86_64-efi.rmk'.
5093 Sort the list.
5094
5095 2008-09-09 Felix Zielcke <fzielcke@z-51.de>
5096
5097 * util/hostdisk.c: Replace #include <grub/util/biosdisk.h> with
5098 #include <grub/util/hostdisk.h>.
5099
5100 2008-09-08 Robert Millan <rmh@aybabtu.com>
5101
5102 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Skip
5103 segments when their filesz is zero (grub_file_read() interprets
5104 zero-size as "read until EOF", which results in memory corruption).
5105 Use `lowest_segment' rather than 0 for calculating the current
5106 segment load address.
5107
5108 2008-09-08 Robert Millan <rmh@aybabtu.com>
5109
5110 * util/hostdisk.c (open_device): Replace a grub_util_info() call
5111 with grub_dprintf("hostdisk", ...), as it was so verbose that it
5112 clobbered useful information.
5113
5114 2008-09-08 Robert Millan <rmh@aybabtu.com>
5115
5116 * include/grub/util/biosdisk.h: Move to ...
5117 * include/grub/util/hostdisk.h: ... here. Update all users.
5118 * util/biosdisk.c: Move to ...
5119 * util/hostdisk.c: ... here. Update all users.
5120
5121 2008-09-07 Robert Millan <rmh@aybabtu.com>
5122
5123 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): Remove
5124 variables.
5125 (grub_multiboot): Move `mbi' allocation upwards, so that mmap address
5126 and length can be stored directly in the `mbi->mmap_addr' and
5127 `mbi->mmap_length' struct fields.
5128
5129 2008-09-07 Robert Millan <rmh@aybabtu.com>
5130
5131 * conf/i386.rmk: New file. Provides declaration for building
5132 `cpuid.mod'.
5133 * conf/i386-pc.rmk (pkglib_MODULES): Remove `cpuid.mod'.
5134 (cpuid_mod_SOURCES, cpuid_mod_CFLAGS, cpuid_mod_LDFLAGS): Remove
5135 variables.
5136 Include `conf/i386.mk'.
5137 * conf/i386-efi.rmk: Likewise.
5138 * conf/x86_64-efi.rmk: Likewise.
5139 * conf/i386-coreboot.rmk: Likewise.
5140 * conf/i386-ieee1275.rmk: Likewise.
5141
5142 2008-09-07 Vesa Jääskeläinen <chaac@nic.fi>
5143
5144 Based on patch created by Colin D Bennett <colin@gibibit.com>.
5145 Adds optimization support for BGR based modes.
5146
5147 * include/grub/i386/pc/vbeblit.h (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8) Removed.
5148 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
5149 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
5150 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
5151 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
5152 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
5153 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
5154 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
5155 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
5156 (grub_video_i386_vbeblit_index_index): Likewise.
5157 (grub_video_i386_vbeblit_replace_directN): Added.
5158 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
5159 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
5160 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
5161 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
5162 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
5163 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
5164 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
5165 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
5166 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
5167 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
5168 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
5169 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
5170 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
5171
5172 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8) Removed.
5173 (grub_video_i386_vbefill_R8G8B8): Likewise.
5174 (grub_video_i386_vbefill_index): Likewise.
5175 (grub_video_i386_vbefill_direct32): Added.
5176 (grub_video_i386_vbefill_direct24): Likewise.
5177 (grub_video_i386_vbefill_direct16): Likewise.
5178 (grub_video_i386_vbefill_direct8): Likewise.
5179
5180 * include/grub/video.h (grub_video_blit_format): Removed
5181 GRUB_VIDEO_BLIT_FORMAT_R8G8B8A8, GRUB_VIDEO_BLIT_FORMAT_R8G8B8.
5182 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_RGBA_8888,
5183 GRUB_VIDEO_BLIT_FORMAT_BGRA_8888, GRUB_VIDEO_BLIT_FORMAT_RGB_888,
5184 GRUB_VIDEO_BLIT_FORMAT_BGR_888, GRUB_VIDEO_BLIT_FORMAT_RGB_565,
5185 GRUB_VIDEO_BLIT_FORMAT_BGR_565.
5186
5187 * video/video.c (grub_video_get_blit_format): Updated to use new
5188 blit formats. Added handling for 16 bit color modes.
5189
5190 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Updated to use new
5191 fillers.
5192 (common_blitter): Updated to use new blitters.
5193
5194 * video/i386/pc/vbeblit.c (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8):
5195 Removed.
5196 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
5197 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
5198 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
5199 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
5200 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
5201 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
5202 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
5203 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
5204 (grub_video_i386_vbeblit_index_index): Likewise.
5205 (grub_video_i386_vbeblit_replace_directN): Added.
5206 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
5207 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
5208 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
5209 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
5210 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
5211 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
5212 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
5213 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
5214 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
5215 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
5216 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
5217 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
5218 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
5219
5220 * video/i386/pc/vbefill.c (grub_video_i386_vbefill_R8G8B8A8): Removed.
5221 (grub_video_i386_vbefill_R8G8B8): Likewise.
5222 (grub_video_i386_vbefill_index): Likewise.
5223 (grub_video_i386_vbefill_direct32): Added.
5224 (grub_video_i386_vbefill_direct24): Likewise.
5225 (grub_video_i386_vbefill_direct16): Likewise.
5226 (grub_video_i386_vbefill_direct8): Likewise.
5227
5228 * video/readers/jpeg.c (grub_jpeg_decode_sos): Adapt to new blitter
5229 types.
5230
5231 * video/readers/tga.c (grub_video_reader_tga): Adapt to new blitter
5232 types.
5233
5234 * video/readers/png.c (grub_png_decode_image_header): Adapt to new
5235 blitter types.
5236
5237 * video/bitmap.c (grub_video_bitmap_create): Adapt to new blitter
5238 types.
5239
5240 2008-09-06 Felix Zielcke <fzielcke@z-51.de>
5241
5242 * disk/raid.c (insert_array): Set `array->chunk_size' to 64 for
5243 RAID level 1.
5244
5245 2008-09-06 Felix Zielcke <fzielcke@z-51.de>
5246
5247 * fs/iso9660.c (grub_iso9660_date): New structure.
5248 (grub_iso9660_primary_voldesc): Add `grub_iso9660_date' member.
5249 (grub_iso9660_uuid): New function.
5250
5251 2008-09-05 Bean <bean123ch@gmail.com>
5252
5253 * fs/fshelp.c (grub_fshelp_find_file): Handle case insensitive names.
5254
5255 * fs/ntfs.c (list_file): Ignore names in DOS namespace, set the case
5256 insensitive bit for names in Win32 and Win32 & DOS namespace.
5257
5258 * include/grub/fshelp.h (GRUB_FSHELP_CASE_INSENSITIVE): New macro.
5259
5260 * include/grub/types.h (LONG_MAX): Likewise.
5261
5262 2008-09-04 Felix Zielcke <fzielcke@z-51.de>
5263
5264 * util/getroot.c: Include <config.h>.
5265 (grub_util_get_grub_dev): Rewrite to use asprintf for mdraid devices,
5266 add support for /dev/md/N devices and handle LVM double dash escaping.
5267
5268 2008-09-04 Felix Zielcke <fzielcke@z-51.de>
5269
5270 * config.guess: Update to latest version from config git.
5271 * config.sub: Likewise.
5272
5273 2008-09-03 Robert Millan <rmh@aybabtu.com>
5274
5275 * disk/scsi.c (grub_scsi_open): Remove size limit when printing
5276 `disk->total_sectors'.
5277
5278 2008-09-01 Colin D Bennett <colin@gibibit.com>
5279
5280 * include/grub/normal.h: Fixed incorrect comment for
5281 GRUB_COMMAND_FLAG_NO_ARG_PARSE.
5282
5283 2008-09-01 Colin D Bennett <colin@gibibit.com>
5284
5285 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Replaced constant
5286 values with defines.
5287
5288 * include/grub/i386/pc/vbe.h (GRUB_VBE_MODEATTR_SUPPORTED): Added.
5289 (GRUB_VBE_MODEATTR_RESERVED_1): Likewise.
5290 (GRUB_VBE_MODEATTR_BIOS_TTY_OUTPUT_SUPPORT): Likewise.
5291 (GRUB_VBE_MODEATTR_COLOR): Likewise.
5292 (GRUB_VBE_MODEATTR_GRAPHICS): Likewise.
5293 (GRUB_VBE_MODEATTR_VGA_COMPATIBLE): Likewise.
5294 (GRUB_VBE_MODEATTR_VGA_WINDOWED_AVAIL): Likewise.
5295 (GRUB_VBE_MODEATTR_LFB_AVAIL): Likewise.
5296 (GRUB_VBE_MODEATTR_DOUBLE_SCAN_AVAIL): Likewise.
5297 (GRUB_VBE_MODEATTR_INTERLACED_AVAIL): Likewise.
5298 (GRUB_VBE_MODEATTR_TRIPLE_BUF_AVAIL): Likewise.
5299 (GRUB_VBE_MODEATTR_STEREO_AVAIL): Likewise.
5300 (GRUB_VBE_MODEATTR_DUAL_DISPLAY_START): Likewise.
5301 (GRUB_VBE_MEMORY_MODEL_TEXT): Likewise.
5302 (GRUB_VBE_MEMORY_MODEL_CGA): Likewise.
5303 (GRUB_VBE_MEMORY_MODEL_HERCULES): Likewise.
5304 (GRUB_VBE_MEMORY_MODEL_PLANAR): Likewise.
5305 (GRUB_VBE_MEMORY_MODEL_NONCHAIN4_256): Likewise.
5306 (GRUB_VBE_MEMORY_MODEL_YUV): Likewise.
5307
5308 2008-08-31 Robert Millan <rmh@aybabtu.com>
5309
5310 * loader/i386/pc/multiboot.c (grub_get_multiboot_mmap_len): Fix
5311 declaration.
5312 (grub_multiboot): Fix a few warnings.
5313
5314 2008-08-31 Robert Millan <rmh@aybabtu.com>
5315
5316 * loader/i386/pc/multiboot.c: Update comment not to say that
5317 boot_device support is unimplemented.
5318
5319 2008-08-31 Robert Millan <rmh@aybabtu.com>
5320
5321 * loader/i386/pc/multiboot.c: Update comment not to say that a.out
5322 or memory map support are unimplemented.
5323
5324 2008-08-31 Colin D Bennett <colin@gibibit.com>
5325
5326 * util/i386/pc/grub-mkrescue.in: Support multiple overlay directories.
5327
5328 2008-08-31 Colin D Bennett <colin@gibibit.com>
5329
5330 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Show VBE version and
5331 total video memory in 'vbeinfo' output; show color format details for
5332 each video mode.
5333
5334 2008-08-30 Pavel Roskin <proski@gnu.org>
5335
5336 * util/genmoddep.c: Remove for real this time.
5337 * DISTLIST: Remove util/genmoddep.c.
5338
5339 2008-08-30 Robert Millan <rmh@aybabtu.com>
5340
5341 * kern/i386/pc/startup.S (multiboot_header): Force 4-byte alignment
5342 as required by Multiboot spec (it was already 4-byte aligned, but
5343 only by chance).
5344
5345 2008-08-29 Pavel Roskin <proski@gnu.org>
5346
5347 * kern/powerpc/ieee1275/crt0.S: Rename to ...
5348 * kern/powerpc/ieee1275/startup.S: ... this.
5349 * conf/powerpc-ieee1275.rmk: Adjust for the above.
5350 * DISTLIST: Likewise.
5351
5352 * kern/powerpc/ieee1275/crt0.S: Include grub/symbol.h and
5353 grub/cpu/kernel.h. Add start label for consistency with other
5354 platforms. Add grub_prefix immediately after start. Add jump
5355 to the code after grub_prefix.
5356 * include/grub/powerpc/kernel.h: Provide valid values for
5357 GRUB_KERNEL_CPU_PREFIX and GRUB_KERNEL_CPU_DATA_END.
5358
5359 2008-08-29 Bean <bean123ch@gmail.com>
5360
5361 * configure.ac: Change host_os to cygwin for mingw.
5362 (asprintf): New check for function.
5363
5364 * include/grub/symbol.h: Replace #ifndef __CYGWIN__ with
5365 #if ! defined (__CYGWIN__) && ! defined (__MINGW32__).
5366
5367 * include/grub/util/misc.h: #include <config.h> and <grub/types.h>,
5368 declare asprintf if HAVE_ASPRINTF is not set, declare fseeko, ftello,
5369 sync, sleep and grub_util_get_disk_size for mingw.
5370
5371 * util/biosdisk.c (grub_util_biosdisk_open): Use grub_util_get_disk_size
5372 to get size in mingw.
5373 (open_device): Use flag O_BINARY if it's defined.
5374 (find_root_device): Add dummy code for mingw.
5375
5376 * util/grub-mkdevicemap.c (get_floppy_disk_name): Return 0 for mingw.
5377 (get_ide_disk_name): Return //./PHYSICALDRIVE%d for mingw.
5378 (get_scsi_disk_name): Return 0 for mingw.
5379
5380 * util/hostfs.c: #include <grub/util/misc.h>.
5381 (grub_hostfs_open): Use "rb" flag to open file, use
5382 grub_util_get_disk_size to get disk size for mingw.
5383
5384 * util/misc.c: #include <windows.h> and <winioctl.h> in mingw.
5385 (asprintf): New function if HAVE_ASPRINTF is not set.
5386 (sync): New function for mingw.
5387 (sleep): Likewise.
5388 (grub_util_get_disk_size): Likewise.
5389
5390 2008-08-28 Pavel Roskin <proski@gnu.org>
5391
5392 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
5393 kern/time.c.
5394
5395 2008-08-28 Robert Millan <rmh@aybabtu.com>
5396
5397 * util/biosdisk.c (find_grub_drive): Declare missing `i' variable.
5398
5399 2008-08-28 Robert Millan <rmh@aybabtu.com>
5400
5401 Change find_grub_drive() syntax so it doesn't prevent it from
5402 detecting NULL names as errors.
5403
5404 * util/biosdisk.c (find_grub_drive): Move free slot search code
5405 from here ...
5406 (find_free_slot): ... to here.
5407 (read_device_map): Use find_free_slot() to search for free slots.
5408
5409 2008-08-27 Marco Gerards <marco@gnu.org>
5410
5411 * conf/common.rmk (pkglib_MODULES): Add scsi.mod.
5412 (scsi_mod_SOURCES): New variable.
5413 (scsi_mod_CFLAGS): Likewise
5414 (scsi_mod_LDFLAGS): Likewise.
5415
5416 * disk/scsi.c: New file.
5417
5418 * include/grub/scsi.h: Likewise.
5419
5420 * include/grub/scsicmd.h: Likewise.
5421
5422 * disk/ata.c: Include <grub/scsi.h>.
5423 (grub_atapi_packet): Do not use grub_ata_cmd, use registers
5424 instead.
5425 (grub_ata_iterate): Skip ATAPI devices.
5426 (grub_ata_open): Only handle ATAPI devices.
5427 (struct grub_atapi_read): Removed.
5428 (grub_atapi_readsector): Likewise.
5429 (grub_ata_read): No longer handle ATAPI devices.
5430 (grub_ata_write): Likewise.
5431 (grub_atapi_iterate): New function.
5432 (grub_atapi_read): Likewise.
5433 (grub_atapi_write): Likewise.
5434 (grub_atapi_open): Likewise.
5435 (grub_atapi_close): Likewise.
5436 (grub_atapi_dev): New variable.
5437 (GRUB_MOD_INIT(ata)): Register ATAPI as SCSI device.
5438 (GRUB_MOD_FINI(ata)): Unregister ATAPI.
5439
5440 * include/grub/disk.h (enum grub_disk_dev_id): Add
5441 `GRUB_DISK_DEVICE_SCSI_ID'.
5442
5443 2008-08-26 Robert Millan <rmh@aybabtu.com>
5444
5445 * util/biosdisk.c (grub_util_biosdisk_open, open_device)
5446 (grub_util_biosdisk_get_grub_dev): Make error messages a bit more
5447 descriptive.
5448
5449 2008-08-23 Bean <bean123ch@gmail.com>
5450
5451 * conf/common.rmk (grub_probe_SOURCES): Add disk/mdraid_linux.c.
5452 (grub_fstest_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
5453 disk/mdraid_linux.c and disk/dmraid_nvidia.c and lib/crc.c.
5454 (pkglib_MODULES): Add raid5rec.mod, raid6rec.mod, mdraid.mod and
5455 dm_nv.mod.
5456 (raid5rec_mod_SOURCES): New macro.
5457 (raid5rec_mod_CFLAGS): Likewise.
5458 (raid5rec_mod_LDFLAGS): Likewise.
5459 (raid6rec_mod_SOURCES): Likewise.
5460 (raid6rec_mod_CFLAGS): Likewise.
5461 (raid6rec_mod_LDFLAGS): Likewise.
5462 (mdraid_mod_SOURCES): Likewise.
5463 (mdraid_mod_CFLAGS): Likewise.
5464 (mdraid_mod_LDFLAGS): Likewise.
5465 (dm_nv_mod_SOURCES): Likewise.
5466 (dm_nv_mod_CFLAGS): Likewise.
5467 (dm_nv_mod_LDFLAGS): Likewise.
5468
5469 * conf/i386-pc.rmk (grub_setup_SOURCES): Add disk/mdraid_linux.c.
5470 (grub_emu_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
5471 disk/mdraid_linux.c and disk/dmraid_nvidia.c.
5472
5473 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add disk/raid5_recover.c,
5474 disk/raid6_recover.c, disk/mdraid_linux.c and disk/dmraid_nvidia.c.
5475
5476 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
5477
5478 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
5479
5480 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5481
5482 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5483
5484 * disk/raid5_recover.c: New file.
5485
5486 * disk/raid6_recover.c: Likewise.
5487
5488 * disk/mdraid_linux.c: Likewise.
5489
5490 * disk/dmraid_nvidia.c: Likewise.
5491
5492 * disk/i386/pc/biosdisk.c: Set total_sectors of cdrom device to
5493 ULONG_MAX.
5494
5495 * disk/raid.c (grub_raid_open): Use the size of the smallest disk to
5496 calculate the size of raid device.
5497 (grub_raid_read): Simplify raid0 code. Support raid4, raid6 and four
5498 different layout of raid5.
5499 (grub_raid_scan_device): Remove code specific to mdraid.
5500 (grub_raid_list): New variable.
5501 (free_array): New function.
5502 (grub_raid_register): Likewise.
5503 (grub_raid_unregister): Likewise.
5504 (grub_raid_rescan): Likewise.
5505 (GRUB_MOD_INIT): Don't iterate device here.
5506 (GRUB_MOD_FINI): Use free_array to release resource.
5507
5508 * include/grub/raid.h: Remove macro and structure specific to mdraid.
5509 (grub_raid5_recover_func_t): New function variable type.
5510 (grub_raid6_recover_func_t): Likewise.
5511 (grub_raid5_recover_func): New variable.
5512 (grub_raid6_recover_func): Likewise.
5513 (grub_raid_register): New function.
5514 (grub_raid_unregister): Likewise.
5515 (grub_raid_rescan): Likewise.
5516 (grub_raid_block_xor): Likewise.
5517
5518 * util/grub-fstest.c: Add #include <grub/raid.h> and <grub/lib/crc.h>.
5519 (CMD_CRC): New macro.
5520 (part): Removed.
5521 (read_file): Handle device as well as file.
5522 (cmd_crc): New function.
5523 (fstest): Handle multiple disks.
5524 (options): Remove part, raw and long, add root and diskcount.
5525 (usage): Add crc, remove -p, -r, -l, add -r and -c.
5526 (main): Find the first non option entry and ignore subsequent options,
5527 add handling for the new options, support multiple disks.
5528
5529 * util/grub-probe.c (probe): Add mdraid to abstraction_name.
5530
5531 2008-08-23 Bean <bean123ch@gmail.com>
5532
5533 * normal/x86_64/setjmp.S (grub_longjmp): Return 1 when val = 0.
5534
5535 * genfslist.sh: Ignore kernel.mod.
5536
5537 * genpartmaplist.sh: Likewise.
5538
5539 2008-08-23 Robert Millan <rmh@aybabtu.com>
5540
5541 * util/getroot.c (find_root_device): Skip anything that starts with
5542 a dot, not just directories. This avoids things like /dev/.tmp.md0.
5543
5544 2008-08-22 Felix Zielcke <fzielcke@z-51.de>
5545
5546 * util/update-grub.in (GRUB_GFXMODE): Export variable.
5547 * util/grub.d/00_header.in: Allow the administrator to change default
5548 gfxmode via ${GRUB_GFXMODE}.
5549
5550 2008-08-21 Felix Zielcke <fzielcke@z-51.de>
5551
5552 * fs/ntfs.c (grub_ntfs_mount): Fix a memory leak.
5553
5554 2008-08-21 Robert Millan <rmh@aybabtu.com>
5555
5556 * loader/i386/linux.c: New file. Implements generic 32-bit Linux
5557 loader.
5558 * conf/i386-coreboot.rmk (_linux_mod_SOURCES): Replace
5559 `loader/i386/pc/linux.c' with `loader/i386/linux.c'.
5560
5561 2008-08-20 Carles Pina i Estany <carles@pina.cat>
5562
5563 * menu/normal.c (run_menu): Replace hardcoded numbers with macros
5564 (16 for GRUB_TERM_UP and 14 for GRUB_TERM_DOWN)
5565
5566 2008-08-19 Robert Millan <rmh@aybabtu.com>
5567
5568 * term/gfxterm.c (DEFAULT_CURSOR_COLOR): Remove.
5569 (struct grub_virtual_screen): Remove `cursor_color'.
5570 (grub_virtual_screen_setup): Remove `virtual_screen.cursor_color'
5571 initialization.
5572 (write_cursor): Use `virtual_screen.fg_color' to draw cursor.
5573
5574 2008-08-18 Robert Millan <rmh@aybabtu.com>
5575
5576 Unify (identical) linux_normal.c files.
5577 * loader/i386/efi/linux_normal.c: Move from here ...
5578 * loader/linux_normal.c: ... to here. Update all users.
5579 * loader/i386/pc/linux_normal.c: Delete. Update all users.
5580 * loader/i386/ieee1275/linux_normal.c: Likewise.
5581
5582 2008-08-18 Robert Millan <rmh@aybabtu.com>
5583
5584 * include/grub/i386/linux.h (LINUX_LOADER_ID_LILO)
5585 (LINUX_LOADER_ID_LOADLIN, LINUX_LOADER_ID_BOOTSECT)
5586 (LINUX_LOADER_ID_SYSLINUX, LINUX_LOADER_ID_ETHERBOOT)
5587 (LINUX_LOADER_ID_ELILO, LINUX_LOADER_ID_GRUB, LINUX_LOADER_ID_UBOOT)
5588 (LINUX_LOADER_ID_XEN, LINUX_LOADER_ID_GUJIN, LINUX_LOADER_ID_QEMU):
5589 New macros.
5590 (GRUB_LINUX_CL_OFFSET, GRUB_LINUX_CL_END_OFFSET): Move from here ...
5591 * loader/i386/pc/linux.c (GRUB_LINUX_CL_OFFSET)
5592 (GRUB_LINUX_CL_END_OFFSET): ... to here.
5593 * loader/i386/efi/linux.c (GRUB_EFI_CL_OFFSET): Rename to ...
5594 (GRUB_LINUX_CL_OFFSET): ... this. Update all users.
5595 (GRUB_EFI_CL_END_OFFSET): Rename to ...
5596 (GRUB_LINUX_CL_END_OFFSET): ... this. Update all users.
5597 (grub_rescue_cmd_linux): Macroify `type_of_loader' initialization.
5598 Initialize `params->video_cursor_x' and `params->video_cursor_y'
5599 portably using grub_getxy().
5600 Replace `-EFI' with `-bzImage' in boot message.
5601
5602 2008-08-17 Robert Millan <rmh@aybabtu.com>
5603
5604 * include/grub/x86_64/kernel.h: New file (<grub/i386/kernel.h> stub).
5605
5606 2008-08-17 Robert Millan <rmh@aybabtu.com>
5607
5608 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pc/mmap.c'.
5609
5610 * include/grub/i386/pc/init.h (GRUB_MACHINE_MEMORY_AVAILABLE)
5611 (GRUB_MACHINE_MEMORY_RESERVED): New macros.
5612 (grub_machine_mmap_iterate): New function declaration.
5613 * include/grub/multiboot.h (struct grub_multiboot_mmap_entry): New
5614 structure.
5615 (GRUB_MMAP_MEMORY_AVAILABLE, GRUB_MMAP_MEMORY_RESERVED): New
5616 macros.
5617
5618 * kern/i386/pc/init.c (grub_machine_init): Replace hardcoded region
5619 type check value with `GRUB_MACHINE_MEMORY_AVAILABLE'.
5620 Move e820 parsing from here ...
5621 * kern/i386/pc/mmap.c: New file.
5622 (grub_machine_mmap_iterate): ... to here.
5623
5624 * include/grub/i386/coreboot/memory.h: Remove `<grub/err.h>'.
5625 (GRUB_LINUXBIOS_MEMORY_AVAILABLE): Rename (for consistency) to ...
5626 (GRUB_MACHINE_MEMORY_AVAILABLE): ... this. Update all users.
5627 (grub_available_iterate): Redeclare to return `void', and redeclare
5628 its hook to use grub_uint64_t as addr and size parameters, and rename
5629 to ...
5630 (grub_machine_mmap_iterate): ... this. Update all users.
5631
5632 * kern/i386/coreboot/mmap.c (grub_mmap_iterate): Simplify parser loop
5633 to make it more readable. Rename to ...
5634 (grub_machine_mmap_iterate): ... this.
5635
5636 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): New variables.
5637 (grub_get_multiboot_mmap_len, grub_fill_multiboot_mmap): New functions.
5638 (grub_multiboot): Allocate an extra region after the payload, and fill
5639 it with a Multiboot memory map. Adjust a.out loader to calculate size
5640 with the extra space.
5641 (grub_multiboot_load_elf32): Adjust elf32 loader to calculate size
5642 with the extra space.
5643
5644 2008-08-17 Carles Pina i Estany <carles@pina.cat>
5645
5646 * menu/normal.c (run_menu): Add Home and End keys in grub-menu.
5647
5648 2008-08-17 Felix Zielcke <fzielcke@z-51.de>
5649
5650 * gendistlist.sh: Add *.y, *.tex, *.texi, grub.cfg, README, *.sc,
5651 mdate-sh to the list `find' searches for.
5652 * DISTLIST: Regenerated.
5653
5654 2008-08-16 Felix Zielcke <fzielcke@z-51.de>
5655
5656 * gendistlist.sh (EXTRA_DISTFILES): Remove gensymlist.sh,
5657 genkernsyms.sh. Add geninit.sh, geninitheader.sh, genkernsyms.sh.in,
5658 genmoddep.awk, gensymlist.sh.in.
5659 (DISTDIRS): Add bus, docs, hook, lib.
5660 * DISTLIST: Regenerated.
5661 * NEWS: Add cygwin support and change the `os-prober' entry a bit.
5662
5663 2008-08-16 Robert Millan <rmh@aybabtu.com>
5664
5665 * disk/raid.c (grub_raid_init): Handle/report errors set by
5666 grub_device_iterate().
5667 * disk/lvm.c (grub_lvm_init): Likewise.
5668
5669 2008-08-15 Bean <bean123ch@gmail.com>
5670
5671 * conf/i386-pc.rmk (pkglib_MODULES): Add datetime.mod, date.mod
5672 and datehook.mod.
5673 (datetime_mod_SOURCES): New macro.
5674 (datetime_mod_CFLAGS): Likewise.
5675 (datetime_mod_LDFLAGS): Likewise.
5676 (date_mod_SOURCES): Likewise.
5677 (date_mod_CFLAGS): Likewise.
5678 (date_mod_LDFLAGS): Likewise.
5679 (datehook_mod_SOURCES): Likewise.
5680 (datehook_mod_CFLAGS): Likewise.
5681 (datehook_mod_LDFLAGS): Likewise.
5682
5683 * conf/i386-coreboot.rmk (pkglib_MODULES): Add datetime.mod, date.mod
5684 and datehook.mod.
5685 (datetime_mod_SOURCES): New macro.
5686 (datetime_mod_CFLAGS): Likewise.
5687 (datetime_mod_LDFLAGS): Likewise.
5688 (date_mod_SOURCES): Likewise.
5689 (date_mod_CFLAGS): Likewise.
5690 (date_mod_LDFLAGS): Likewise.
5691 (datehook_mod_SOURCES): Likewise.
5692 (datehook_mod_CFLAGS): Likewise.
5693 (datehook_mod_LDFLAGS): Likewise.
5694
5695 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add datetime.mod, date.mod
5696 and datehook.mod.
5697 (datetime_mod_SOURCES): New macro.
5698 (datetime_mod_CFLAGS): Likewise.
5699 (datetime_mod_LDFLAGS): Likewise.
5700 (date_mod_SOURCES): Likewise.
5701 (date_mod_CFLAGS): Likewise.
5702 (date_mod_LDFLAGS): Likewise.
5703 (datehook_mod_SOURCES): Likewise.
5704 (datehook_mod_CFLAGS): Likewise.
5705 (datehook_mod_LDFLAGS): Likewise.
5706
5707 * conf/i386-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
5708 and datehook.mod.
5709 (datetime_mod_SOURCES): New macro.
5710 (datetime_mod_CFLAGS): Likewise.
5711 (datetime_mod_LDFLAGS): Likewise.
5712 (date_mod_SOURCES): Likewise.
5713 (date_mod_CFLAGS): Likewise.
5714 (date_mod_LDFLAGS): Likewise.
5715 (datehook_mod_SOURCES): Likewise.
5716 (datehook_mod_CFLAGS): Likewise.
5717 (datehook_mod_LDFLAGS): Likewise.
5718
5719 * conf/x86_64-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
5720 and datehook.mod.
5721 (datetime_mod_SOURCES): New macro.
5722 (datetime_mod_CFLAGS): Likewise.
5723 (datetime_mod_LDFLAGS): Likewise.
5724 (date_mod_SOURCES): Likewise.
5725 (date_mod_CFLAGS): Likewise.
5726 (date_mod_LDFLAGS): Likewise.
5727 (datehook_mod_SOURCES): Likewise.
5728 (datehook_mod_CFLAGS): Likewise.
5729 (datehook_mod_LDFLAGS): Likewise.
5730
5731 * kern/env.c (grub_env_insert): Fix a bug in prevp pointer.
5732
5733 * commands/date.c: New file.
5734
5735 * hook/datehook.c: Likewise.
5736
5737 * include/grub/lib/datetime.h: Likewise.
5738
5739 * include/grub/i386/cmos.h: Likewise.
5740
5741 * lib/datetime.c: Likewise.
5742
5743 * lib/i386/datetime.c: Likewise.
5744
5745 * lib/efi/datetime.c: Likewise.
5746
5747 2008-08-14 Robert Millan <rmh@aybabtu.com>
5748
5749 * conf/common.rmk (bin_UTILITIES): Add `grub-mkelfimage'.
5750 (grub_mkelfimage_SOURCES): New variable.
5751 (util/elf/grub-mkimage.c_DEPENDENCIES): Likewise.
5752
5753 * conf/i386-coreboot.rmk (bin_UTILITIES, grub_mkimage_SOURCES)
5754 (grub_mkimage_LDFLAGS, util/elf/grub-mkimage.c_DEPENDENCIES): Remove.
5755 * conf/powerpc-ieee1275.rmk: Likewise.
5756 * conf/i386-ieee1275.rmk: Likewise.
5757
5758 * kern/ieee1275/init.c: Include `<grub/cpu/kernel.h>'.
5759 * kern/i386/coreboot/init.c: Likewise.
5760
5761 * kern/i386/ieee1275/startup.S: Replace `<grub/machine/kernel.h>'
5762 with `<grub/cpu/kernel.h>'.
5763 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Renamed
5764 to ...
5765 (GRUB_KERNEL_CPU_PREFIX, GRUB_KERNEL_CPU_DATA_END): ... this.
5766 * kern/i386/coreboot/startup.S: Likewise.
5767
5768 * include/grub/powerpc/ieee1275/kernel.h (GRUB_MOD_ALIGN)
5769 (GRUB_MOD_GAP): Remove.
5770 * include/grub/powerpc/kernel.h: New file.
5771 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX)
5772 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
5773 * include/grub/i386/kernel.h: New file.
5774 * include/grub/i386/coreboot/kernel.h (GRUB_MOD_ALIGN)
5775 (GRUB_MOD_GAP, GRUB_KERNEL_MACHINE_PREFIX)
5776 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
5777
5778 * util/ieee1275/grub-install.in (grub_mkimage): Initialize to use
5779 `grub-mkelfimage'.
5780 Use --directory when invoking grub_mkimage.
5781
5782 * util/elf/grub-mkimage.c: Include `<grub/cpu/kernel.h>'.
5783 (add_segments): Replace GRUB_KERNEL_MACHINE_DATA_END and
5784 GRUB_KERNEL_MACHINE_PREFIX with GRUB_KERNEL_CPU_DATA_END
5785 and GRUB_KERNEL_CPU_PREFIX.
5786
5787 2008-08-14 Felix Zielcke <fzielcke@z-51.de>
5788
5789 * include/grub/err.h (grub_err_printf): New function prototype.
5790 * util/misc.c (grub_err_printf): New function.
5791 * kern/misc.c [! GRUB_UTIL] (grub_err_printf): New alias for
5792 grub_printf.
5793 * kern/err.c (grub_print_error): Use grub_err_printf.
5794
5795 2008-08-13 Robert Millan <rmh@aybabtu.com>
5796
5797 * docs/grub.cfg: Remove `/dev/' prefix in GNU/Hurd boot entry.
5798
5799 2008-08-13 Robert Millan <rmh@aybabtu.com>
5800
5801 * docs/grub.cfg: Use the native device name for the example GNU/Hurd
5802 boot entry.
5803
5804 2008-08-12 Robert Millan <rmh@aybabtu.com>
5805
5806 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Move part
5807 of the relocation code from here ...
5808 (grub_multiboot): ... to here.
5809 (forward_relocator, backward_relocator): Move from here ...
5810 * kern/i386/loader.S (grub_multiboot_forward_relocator)
5811 (grub_multiboot_backward_relocator): ... to here.
5812 (grub_multiboot_real_boot): Use %edx for entry offset. Put Multiboot
5813 magic in %eax. Use %ebp for jumping (so %edx is not trashed).
5814 * include/grub/i386/loader.h (grub_multiboot_forward_relocator)
5815 (grub_multiboot_forward_relocator_end)
5816 (grub_multiboot_backward_relocator)
5817 (grub_multiboot_backward_relocator_end): New variables.
5818
5819 2008-08-12 Bean <bean123ch@gmail.com>
5820
5821 * disk/raid.c (grub_raid_read): Fix a bug in raid0 code.
5822
5823 2008-08-11 Robert Millan <rmh@aybabtu.com>
5824
5825 * kern/i386/linuxbios/startup.S: Move from here ...
5826 * kern/i386/coreboot/startup.S: ... to here.
5827
5828 * kern/i386/linuxbios/init.c: Move from here ...
5829 * kern/i386/coreboot/init.c: ... to here.
5830
5831 * kern/i386/linuxbios/table.c: Move from here ...
5832 * kern/i386/coreboot/mmap.c: ... to here.
5833
5834 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Update moved files.
5835
5836 2008-08-11 Robert Millan <rmh@aybabtu.com>
5837
5838 * kern/device.c (grub_device_open): Do not handle grub_disk_open()
5839 errors. Leave it to the upper layer to handle them.
5840
5841 2008-08-09 Christian Franke <franke@computer.org>
5842
5843 * Makefile.in: Add `target_os' and `enable_grub_pe2elf'.
5844 * conf/common.rmk: Install `grub-pe2elf' only if requested.
5845 Install `grub.d/10_windows' only on Cygwin.
5846 * configure.ac: Add subst of `target_os'.
5847 Check `target_os' also before setting TARGET_OBJ2ELF.
5848 Add `--enable-grub-pe2elf'.
5849
5850 2008-08-08 Robert Millan <rmh@aybabtu.com>
5851
5852 * kern/disk.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
5853 (grub_last_time): Change type to grub_uint64_t.
5854 (grub_disk_open): Migrate code from to using grub_get_time_ms().
5855 (grub_disk_close): Likewise.
5856
5857 * normal/menu.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
5858 (run_menu): Migrate code from to using grub_get_time_ms().
5859
5860 * util/misc.c (grub_get_time_ms): New function.
5861
5862 2008-08-08 Marco Gerards <marco@gnu.org>
5863
5864 * disk/ata.c (grub_ata_regget): Change return type to
5865 `grub_uint8_t'.
5866 (grub_ata_regget2): Likewise.
5867 (grub_ata_wait_status): New function.
5868 (grub_ata_wait_busy): Removed function, updated all users to use
5869 `grub_ata_wait_status'.
5870 (grub_ata_wait_drq): Likewise.
5871 (grub_ata_cmd): New function.
5872 (grub_ata_pio_read): Change return type to `grub_uint8_t'. Add
5873 error handling.
5874 (grub_ata_pio_write): Add error handling.
5875 (grub_atapi_identify): Likewise.
5876 (grub_atapi_packet): Use `grub_ata_cmd' and improve error
5877 handling.
5878 (grub_ata_identify): Use `grub_ata_cmd' and improve error
5879 handling. Actually use the detected registers. Reorder the
5880 detection logic such that it is easier to read.
5881 (grub_ata_pciinit): Do not assign the same ID to each controller.
5882 (grub_ata_setaddress): Use `grub_ata_cmd' and improve error
5883 handling.
5884 (grub_atapi_readsector): Check the result of `grub_ata_pio_read'.
5885
5886 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TIMEOUT'.
5887
5888 2008-08-08 Marco Gerards <marco@gnu.org>
5889
5890 * NEWS: Update.
5891
5892 2008-08-07 Bean <bean123ch@gmail.com>
5893
5894 * include/grub/x86_64/pci.h: New file.
5895
5896 2008-08-07 Christian Franke <franke@computer.org>
5897
5898 * kern/i386/pit.c (TIMER2_SPEAKER): New define.
5899 (TIMER2_GATE): Likewise.
5900 (grub_pit_wait): Add enable/disable of the timer2 gate
5901 bit of port 0x61. This fixes a possible infinite loop.
5902
5903 2008-08-07 Bean <bean123ch@gmail.com>
5904
5905 * conf/x86_64-efi.rmk (kernel_mod_SOURCES): Add kern/time.c,
5906 kern/i386/tsc.c and kern/i386/pit.c.
5907
5908 * include/grub/i386/tsc.h (grub_cpu_is_cpuid_supported): Handle
5909 x86_64 platform.
5910
5911 * kern/i386/efi/init.c: Replace <grub/cpu/tsc.h> with
5912 <grub/i386/tsc.h>.
5913
5914 * kern/i386/pit.c: Replace <grub/cpu/io.h> with <grub/i386/io.h>.
5915
5916 2008-08-07 Bean <bean123ch@gmail.com>
5917
5918 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add kern/time.c.
5919
5920 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add kern/time.c,
5921
5922 * include/grub/i386/pit.h: Use macro KERNEL_CPU_PIT_HEADER to avoid
5923 multiple inclusion. Add #include <grub/types.h>.
5924
5925 2008-08-06 Christian Franke <franke@computer.org>
5926
5927 * conf/common.rmk: Build and install `10_windows'.
5928 * util/grub.d/10_windows.in: New script.
5929
5930 2008-08-06 Pavel Roskin <proski@gnu.org>
5931
5932 * kern/i386/pit.c: Include `<grub/i386/pit.h>'.
5933
5934 2008-08-06 Robert Millan <rmh@aybabtu.com>
5935
5936 * conf/i386-coreboot.rmk (kernel_elf_ASFLAGS): New variable.
5937 * kern/i386/tsc.c: Include `<grub/i386/pit.h>'.
5938
5939 2008-08-06 Bean <bean123ch@gmail.com>
5940
5941 * fs/i386/pc/pxe.c (grub_pxe_data): New member block_size.
5942 (grub_pxefs_fs_int): Remove dummy definition.
5943 (grub_pxefs_open): Use data->block_size to store the current block
5944 size setting.
5945 (grub_pxefs_read): Use block size stored in data->block_size. As the
5946 value of grub_pxe_blksize can be changed after the file is opened.
5947
5948 2008-08-06 Bean <bean123ch@gmail.com>
5949
5950 * fs/i386/pc/pxe.c (curr_file): new variable.
5951 (grub_pxefs_open): Simply the handling of pxe file system. Don't
5952 require the dummy internal file system anymore.
5953 (grub_pxefs_read): Removed.
5954 (grub_pxefs_close): Likewise.
5955 (grub_pxefs_fs_int): Likewise.
5956 (grub_pxefs_read_int): Renamed to grub_pxefs_read. Reinitialize tftp
5957 connection when we switch file.
5958 (grub_pxefs_close_int): Renamed to grub_pxefs_close.
5959
5960 2008-08-06 Robert Millan <rmh@aybabtu.com>
5961
5962 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `reboot.mod' and
5963 `halt.mod'.
5964 (reboot_mod_SOURCES, reboot_mod_CFLAGS, reboot_mod_LDFLAGS)
5965 (halt_mod_SOURCES, halt_mod_CFLAGS, halt_mod_LDFLAGS): New variables.
5966
5967 * kern/i386/halt.c: New file.
5968 * kern/i386/reboot.c: Likewise.
5969 * include/grub/i386/reboot.h: Likewise.
5970 * include/grub/i386/halt.h: Likewise.
5971
5972 * commands/halt.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]:
5973 Include `<grub/cpu/halt.h>'.
5974 * commands/reboot.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]
5975 [! GRUB_MACHINE_PCBIOS]: Include `<grub/cpu/reboot.h>'.
5976
5977 * term/i386/pc/at_keyboard.c: Include `<grub/cpu/at_keyboard.h>'.
5978 (SHIFT_L, SHIFT_R, CTRL, ALT, CAPS_LOCK, KEYBOARD_REG_DATA)
5979 (KEYBOARD_REG_STATUS, KEYBOARD_COMMAND_ISREADY, KEYBOARD_COMMAND_READ)
5980 (KEYBOARD_COMMAND_WRITE, KEYBOARD_COMMAND_REBOOT)
5981 (KEYBOARD_SCANCODE_SET1, KEYBOARD_ISMAKE, KEYBOARD_ISREADY)
5982 (KEYBOARD_SCANCODE, OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): Move
5983 from here ...
5984 * include/grub/i386/at_keyboard.h: ... to here.
5985
5986 2008-08-05 Robert Millan <rmh@aybabtu.com>
5987
5988 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pit.c'.
5989 * conf/i386-efi.rmk (kernel_mod_SOURCES): Likewise.
5990 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Likewise. Also add
5991 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
5992 `kern/generic/millisleep.c'.
5993
5994 * kern/i386/tsc.c (calibrate_tsc): Rewrite using grub_pit_wait()
5995 instead of grub_get_rtc().
5996 (grub_tsc_init): Initialize `tsc_boot_time'.
5997
5998 * kern/i386/linuxbios/init.c (grub_millisleep): Remove stub.
5999 (grub_machine_init): Use grub_tsc_init() rather than
6000 installing an RTC-based handler via grub_install_get_time_ms().
6001
6002 * kern/i386/pit.c: New file.
6003 * include/grub/i386/pit.h: Likewise.
6004
6005 2008-08-05 Bean <bean123ch@gmail.com>
6006
6007 * boot/i386/pc/pxeboot.S (_start): Use drive number 0x7F for pxe.
6008
6009 * conf/i386-pc.rmk (kernel_img_HEADERS): Add machine/pxe.h.
6010 (pkglib_MODULES): Add pxe.mod and pxecmd.mod.
6011 (pxe_mod_SOURCES): New macro.
6012 (pxe_mod_CFLAGS): Likewise.
6013 (pxe_mod_LDFLAGS): Likewise.
6014 (pxecmd_mod_SOURCES): Likewise.
6015 (pxecmd_mod_CFLAGS): Likewise.
6016 (pxecmd_mod_LDFLAGS): Likewise.
6017
6018 * kern/i386/pc/startup.S (grub_pxe_scan): New function.
6019 (grub_pxe_call): Likewise.
6020
6021 * include/grub/disk.h (grub_disk_dev_id): Add GRUB_DISK_DEVICE_PXE_ID.
6022
6023 * commands/i386/pc/pxecmd.c: New file.
6024
6025 * fs/i386/pc/pxe.c: Likewise.
6026
6027 * include/grub/i386/pc/pxe.h: Likewise.
6028
6029 2008-08-05 Bean <bean123ch@gmail.com>
6030
6031 * util/console.c (grub_console_cur_color): New variable.
6032 (grub_console_standard_color): Likewise.
6033 (grub_console_normal_color): Likewise.
6034 (grub_console_highlight_color): Likewise.
6035 (color_map): Likewise.
6036 (use_color): Likewise.
6037 (NUM_COLORS): New macro.
6038 (grub_ncurses_setcolorstate): Handle color properly.
6039 (grub_ncurses_setcolor): Don't change color here, just remember the
6040 settings, color will be set in grub_ncurses_setcolorstate.
6041 (grub_ncurses_getcolor): New function.
6042 (grub_ncurses_init): Initialize color pairs.
6043 (grub_ncurses_term): New member grub_ncurses_getcolor.
6044
6045 2008-08-05 Colin D Bennett <colin@gibibit.com>
6046
6047 High resolution timer support. Implemented for x86 CPUs using TSC.
6048 Extracted generic grub_millisleep() so it's linked in only as needed.
6049 This requires a Pentium compatible CPU; if the RDTSC instruction is
6050 not supported, then it falls back on the generic grub_get_time_ms()
6051 implementation that uses the machine's RTC.
6052
6053 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/time.c',
6054 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
6055 `kern/generic/millisleep.c'.
6056
6057 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add `kern/i386/tsc.c',
6058 `kern/generic/rtc_get_time_ms.c' and `kern/generic/millisleep.c'.
6059
6060 * conf/x86_64-efi.rml (kernel_mod_SOURCES): Add
6061 `kern/generic/millisleep.c' and `kern/generic/rtc_get_time_ms.c'.
6062
6063 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
6064
6065 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
6066 `kern/generic/millisleep.c'.
6067
6068 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
6069
6070 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Add `kern/time.c'.
6071
6072 * kern/generic/rtc_get_time_ms.c: New file.
6073
6074 * kern/generic/millisleep.c: New file.
6075
6076 * kern/misc.c: Don't include
6077 <kern/time.h> anymore.
6078 (grub_millisleep_generic): Removed.
6079
6080 * commands/sleep.c (grub_interruptible_millisleep): Uses
6081 grub_get_time_ms() instead of grub_get_rtc().
6082
6083 * include/grub/i386/tsc.h (grub_get_tsc): New file. New inline
6084 function.
6085 (grub_cpu_is_cpuid_supported): New inline function.
6086 (grub_cpu_is_tsc_supported): New inline function.
6087 (grub_tsc_init): New function prototype.
6088 (grub_tsc_get_time_ms): New function prototype.
6089
6090 * kern/i386/tsc.c (grub_get_time_ms): New file.
6091
6092 * include/grub/time.h: Include <grub/types.h.
6093 (grub_millisleep_generic): Removed.
6094 (grub_get_time_ms): New prototype.
6095 (grub_install_get_time_ms): New prototype.
6096 (grub_rtc_get_time_ms): New prototype.
6097
6098 * kern/time.c (grub_get_time_ms): New function.
6099 (grub_install_get_time_ms): New function.
6100
6101 * kern/i386/efi/init.c: Include <grub/cpu/tsc.h>. Don't include
6102 <grub/time.h> anymore.
6103 (grub_millisleep): Removed.
6104 (grub_machine_init): Call grub_tsc_init.
6105
6106 * kern/i386/linuxbios/init.c (grub_machine_init): Install the RTC
6107 get_time_ms() implementation.
6108
6109 * kern/sparc64/ieee1275/init.c (grub_millisleep): Removed.
6110 (ieee1275_get_time_ms): New function.
6111 (grub_machine_init): Install get_time_ms() implementation.
6112
6113 * kern/i386/pc/init.c: Include <grub/cpu/tsc.h>.
6114 (grub_machine_init): Call grub_tsc_init().
6115 (grub_millisleep): Removed.
6116
6117 * kern/ieee1275/init.c (grub_millisleep): Removed.
6118 (grub_machine_init): Install ieee1275_get_time_ms()
6119 implementation.
6120 (ieee1275_get_time_ms): New function.
6121 (grub_get_rtc): Now calls ieee1275_get_time_ms(), which does the
6122 real work.
6123
6124 2008-08-05 Marco Gerards <marco@gnu.org>
6125
6126 * disk/ata.c: Include <grub/pci.h>.
6127 (enum grub_ata_commands): Add `GRUB_ATA_CMD_EXEC_DEV_DIAGNOSTICS'.
6128 (grub_ata_initialize): Rewritten.
6129 (grub_ata_device_initialize): New function.
6130
6131 2008-08-04 Pavel Roskin <proski@gnu.org>
6132
6133 * kern/main.c: Include grub/mm.h.
6134
6135 2008-08-04 Robert Millan <rmh@aybabtu.com>
6136
6137 * conf/i386-coreboot.rmk (COMMON_ASFLAGS, COMMON_CFLAGS)
6138 (COMMON_LDFLAGS): Harmonize with i386-pc version (fixes a code
6139 corruption problem).
6140
6141 2008-08-04 Robert Millan <rmh@aybabtu.com>
6142
6143 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Fix misc
6144 warnings introduced in my last commit.
6145
6146 2008-08-03 Robert Millan <rmh@aybabtu.com>
6147
6148 Make PCI available on all i386 architectures.
6149
6150 * include/grub/i386/pc/pci.h: Move from here ...
6151 * include/grub/i386/pci.h: ... to here.
6152
6153 * include/grub/i386/pc/pci.h: Remove.
6154 * include/grub/i386/efi/pci.h: Remove.
6155 * include/grub/x86_64/efi/pci.h: Remove.
6156
6157 * include/grub/pci.h: Replace `<grub/machine/pci.h>' with
6158 `<grub/cpu/pci.h>'.
6159
6160 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `pci' and `lspci'.
6161 (pci_mod_SOURCES, pci_mod_CFLAGS, pci_mod_LDFLAGS, lspci_mod_SOURCES)
6162 (lspci_mod_CFLAGS, lspci_mod_LDFLAGS): New variables.
6163
6164 * conf/i386-ieee1275.rmk: Likewise.
6165
6166 2008-08-03 Robert Millan <rmh@aybabtu.com>
6167
6168 * term/i386/pc/vga_text.c (CRTC_CURSOR_DISABLE): New macro.
6169 (grub_console_setcursor): Make it possible to set cursor off.
6170
6171 2008-08-03 Robert Millan <rmh@aybabtu.com>
6172
6173 * util/grub.d/00_header.in: Be platform-agnostic. Probe for existence
6174 of modules instead of assuming which platform provides what.
6175 * util/update-grub.in: Likewise.
6176
6177 2008-08-03 Robert Millan <rmh@aybabtu.com>
6178
6179 * kern/i386/pc/init.c (make_install_device): Check for `grub_prefix'
6180 instead of `grub_install_dos_part' to determine whether a drive needs
6181 to be prepended to prefix (`grub_install_dos_part' is not reliable,
6182 because it can be overridden when loading GRUB via Multiboot).
6183
6184 2008-08-02 Robert Millan <rmh@aybabtu.com>
6185
6186 * util/i386/pc/grub-install.in: Remove trailing slash from prefix.
6187
6188 2008-08-02 Robert Millan <rmh@aybabtu.com>
6189
6190 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Add a pair
6191 of informational grub_dprintf() calls.
6192
6193 2008-08-02 Robert Millan <rmh@aybabtu.com>
6194
6195 * disk/memdisk.c (memdisk_size): Don't initialize.
6196 (GRUB_MOD_INIT(memdisk)): Find memdisk using grub_module_iterate().
6197
6198 * include/grub/i386/pc/kernel.h
6199 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): Remove macro.
6200 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Shift.
6201 (grub_memdisk_image_size, grub_arch_memdisk_addr)
6202 (grub_arch_memdisk_size): Remove.
6203
6204 * include/grub/kernel.h (struct grub_module_header): Remove `offset'
6205 field (was only used to transfer a constant). Add `type' field to
6206 support multiple module types.
6207 (grub_module_iterate): New function.
6208
6209 * kern/device.c (grub_device_open): Do not hide error messages
6210 when grub_disk_open() fails. Use grub_print_error() instead.
6211
6212 * kern/i386/pc/init.c (grub_arch_modules_addr)
6213 (grub_arch_memdisk_size): Remove functions.
6214 (grub_arch_modules_addr): Return the module address in high memory
6215 (now that it isn't copied anymore).
6216
6217 * kern/i386/pc/startup.S (grub_memdisk_image_size): Remove variable.
6218 (codestart): Don't add grub_memdisk_image_size to %ecx in LZMA
6219 decompression routine (grub_total_module_size already includes that
6220 now). Don't copy modules back to low memory.
6221
6222 * kern/main.c: Include `<grub/mm.h>'.
6223 (grub_load_modules): Split out (and use) ...
6224 (grub_module_iterate): ... this function, which iterates through
6225 module objects and runs a hook.
6226 Comment out grub_mm_init_region() call, as it would cause non-ELF
6227 modules to be overwritten.
6228
6229 * util/i386/pc/grub-mkimage.c (generate_image): Instead of appending
6230 the memdisk image in its own region, make it part of the module list.
6231 * util/elf/grub-mkimage.c (options): Add "memdisk"|'m' option.
6232 (main): Parse --memdisk|-m option, and pass user-provided path as
6233 parameter to generate_image().
6234 (add_segments): Pass `memdisk_path' down to load_modules().
6235 (load_modules): Embed memdisk image in module section when requested.
6236 * util/i386/efi/grub-mkimage.c (make_mods_section): Initialize
6237 `header.type' instead of `header.offset'.
6238
6239 * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add `memdisk.mod'.
6240 (memdisk_mod_SOURCES, memdisk_mod_CFLAGS)
6241 (memdisk_mod_LDFLAGS): New variables.
6242 * conf/i386-coreboot.rmk: Likewise.
6243 * conf/i386-ieee1275.rmk: Likewise.
6244
6245 2008-08-02 Robert Millan <rmh@aybabtu.com>
6246
6247 * loader/i386/pc/multiboot.c (playground, forward_relocator)
6248 (backward_relocator): New variables. Used to allocate and relocate
6249 the payload, respectively.
6250 (grub_multiboot_load_elf32): Load into heap instead of requested
6251 address, install the appropriate relocator code in each bound of
6252 the payload, and set the entry point such that
6253 grub_multiboot_real_boot() will jump to one of them.
6254
6255 * kern/i386/loader.S (grub_multiboot_payload_size)
6256 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
6257 (grub_multiboot_payload_entry_offset): New variables.
6258 (grub_multiboot_real_boot): Set cpu context to what the relocator
6259 expects, and jump to the relocator instead of the payload.
6260
6261 * include/grub/i386/loader.h (grub_multiboot_payload_size)
6262 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
6263 (grub_multiboot_payload_entry_offset): Export.
6264
6265 2008-08-01 Bean <bean123ch@gmail.com>
6266
6267 * normal/menu_entry.c (editor_getline): Don't return the original
6268 string as result, as it will be released by lexer once it has done
6269 using it.
6270
6271 2008-08-01 Robert Millan <rmh@aybabtu.com>
6272
6273 * util/grub.d/10_linux.in: Use prepare_grub_to_access_device() from
6274 within menuentries, not before them.
6275 util/grub.d/10_hurd.in: Likewise.
6276
6277 2008-08-01 Bean <bean123ch@gmail.com>
6278
6279 * conf/common.rmk (pkglib_MODULES): Add bufio.mod.
6280 (bufio_mod_SOURCES): New macro.
6281 (bufio_mod_CFLAGS): Likewise.
6282 (bufio_mod_LDFLAGS): Likewise.
6283
6284 * include/grub/bufio.h: New file.
6285
6286 * io/bufio.c: Likewise.
6287
6288 * video/png.c: Replace <grub/file.h> with <grub/bufio.h>.
6289 (grub_video_reader_png): Use grub_buffile_open to open file.
6290
6291 * video/jpeg.c: Replace <grub/file.h> with <grub/bufio.h>.
6292 (grub_video_reader_jpeg): Use grub_buffile_open to open file.
6293
6294 * video/tga.c: Replace <grub/file.h> with <grub/bufio.h>.
6295 (grub_video_reader_tga): Use grub_buffile_open to open file.
6296
6297 * font/manager.c: Include <grub/bufio.h>.
6298 (add_font): Use grub_buffile_open to open file.
6299
6300 2008-07-31 Robert Millan <rmh@aybabtu.com>
6301
6302 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): When loading
6303 ELF segments, use a macro for arbitrarily accessing any of them instead
6304 of preparing a pointer that allows access to one at a time.
6305 (grub_multiboot_load_elf64): Likewise.
6306
6307 2008-07-31 Bean <bean123ch@gmail.com>
6308
6309 * boot/i386/pc/lnxboot.S (real_code_2): Replace 0x50 with
6310 GRUB_KERNEL_MACHINE_DATA_END.
6311
6312 2008-07-30 Robert Millan <rmh@aybabtu.com>
6313
6314 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_DATA_END):
6315 Increase from 0x50 to 0x60.
6316 * util/i386/pc/grub-install.in: Detect cross-disk installs, and
6317 use UUIDs to identify the root drive for them. If that's not
6318 possible, abort.
6319 * util/i386/pc/grub-setup.c (setup): Do not special-case, or even
6320 check, for cross-disk installs.
6321
6322 2008-07-30 Robert Millan <rmh@aybabtu.com>
6323
6324 * kern/ieee1275/init.c (grub_machine_set_prefix): If `grub_prefix'
6325 is non-empty, use it to set the `prefix' environment variable instead
6326 of the usual approach.
6327 * kern/i386/linuxbios/init.c (make_install_device): Remove function.
6328 (grub_machine_set_prefix): Use `grub_prefix' to set the `prefix'
6329 environment variable instead of dummy make_install_device().
6330
6331 * kern/i386/ieee1275/startup.S: Include `<grub/machine/kernel.h>'.
6332 (start): Insert a data section, with `grub_prefix' variable.
6333 * kern/i386/linuxbios/startup.S: Likewise.
6334
6335 * include/grub/powerpc/ieee1275/kernel.h [!ASM_FILE] (grub_prefix):
6336 New variable reference.
6337 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX):
6338 New macro. Defines offset of `grub_prefix' within startup.S (relative
6339 to `start').
6340 (GRUB_KERNEL_MACHINE_DATA_END): New macro. Defines the end of data
6341 section within startup.S (relative to `start').
6342 * include/grub/i386/coreboot/kernel.h: Likewise.
6343
6344 * util/elf/grub-mkimage.c (add_segments): Receive `prefix' parameter.
6345 Overwrite grub_prefix with its contents, at the beginning of the
6346 first segment.
6347 (main): Understand -p|--prefix.
6348
6349 2008-07-30 Robert Millan <rmh@aybabtu.com>
6350
6351 * util/grub.d/10_hurd.in: Source ${libdir}/grub/update-grub_lib.
6352
6353 2008-07-30 Robert Millan <rmh@aybabtu.com>
6354
6355 * term/i386/pc/vga_text.c (grub_console_cls): Use
6356 grub_console_gotoxy() to go back to beginning of the screen.
6357 Found by Patrick Georgi <patrick.georgi@coresystems.de>
6358
6359 2008-07-29 Christian Franke <franke@computer.org>
6360
6361 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
6362 Add conversion of emulated mount points on Cygwin.
6363
6364 2008-07-29 Christian Franke <franke@computer.org>
6365
6366 * util/update-grub.in: Add a check for admin
6367 group on Cygwin.
6368 Remove old `grub.cfg.new' before creation.
6369 Add `-f' to `mv' to handle the different filesystem
6370 semantics of Windows.
6371
6372 2008-07-29 Bean <bean123ch@gmail.com>
6373
6374 * normal/main.c (get_line): Fix buffer overflow bug.
6375
6376 2008-07-28 Robert Millan <rmh@aybabtu.com>
6377
6378 * partmap/apple.c (GRUB_APPLE_HEADER_MAGIC): New macro.
6379 (struct grub_apple_header): New struct. Describes the layout of
6380 the partmap header.
6381 (apple_partition_map_iterate): Check the header magic as well as the
6382 partition magic (which was already being checked).
6383
6384 2008-07-28 Pavel Roskin <proski@gnu.org>
6385
6386 * genmk.rb: Add a warning to the beginning of the output that
6387 it's a generated file and should not be edited.
6388
6389 2008-07-28 Robert Millan <rmh@aybabtu.com>
6390
6391 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
6392 with the same number are found, just use issue a warning with
6393 grub_dprintf(), as this error has been reported to be non-fatal.
6394
6395 2008-07-27 Robert Millan <rmh@aybabtu.com>
6396
6397 * disk/ata.c (grub_ata_dumpinfo): Use grub_dprintf() for debugging
6398 information.
6399
6400 2008-07-27 Bean <bean123ch@gmail.com>
6401
6402 * fs/fat.c (GRUB_FAT_MAXFILE): New constant.
6403 (grub_fat_find_dir): Ignore case when comparing filename.
6404
6405 2008-07-27 Bean <bean123ch@gmail.com>
6406
6407 * fs/xfs.c (grub_xfs_dir_header): Change field i8count back to
6408 smallino, as it's more descriptive, and i8count can be confused with
6409 the other field count.
6410 (grub_xfs_iterate_dir): Adjust grub_xfs_dir_entry pointer for small
6411 inode type.
6412
6413 2008-07-27 Bean <bean123ch@gmail.com>
6414
6415 * commands/crc.c: New file.
6416
6417 * lib/crc.c: Likewise.
6418
6419 * include/grub/lib/crc.h: Likewise.
6420
6421 * util/grub-fstest.c: grub/hexdump.h => grub/lib/hexdump.h.
6422
6423 * commands/hexdump.c: grub/hexdump.h => grub/lib/hexdump.h.
6424 (hexdump): Move this function to ...
6425
6426 * lib/hexdump.c: ... here.
6427
6428 * include/grub/hexdump.h: Renamed to ...
6429
6430 * include/grub/lib/hexdump.h: ... this.
6431
6432 * commands/loadenv.c: grub/envblk.h => grub/lib/envblk.h
6433
6434 * util/grub-editenv.c: Likewise.
6435
6436 * include/envblk.h: Renamed to ...
6437
6438 * include/lib/envblk.h: ... this.
6439
6440 * util/envblk.c: Renamed to ...
6441
6442 * lib/envblk.c: ... this.
6443
6444 * conf/common.rmk (grub_fstest_SOURCES): commands/hexdump.c =>
6445 lib/hexdump.c.
6446 (grub_editenv_SOURCES): util/envblk.c => lib/envblk.c
6447 (pkglib_MODULES): Add crc.mod.
6448 (hexdump_mod_SOURCES): Add lib/hexdump.c.
6449 (loadenv_mod_SOURCES): util/envblk.c => lib/envblk.c.
6450 (crc_mod_SOURCES): New macro.
6451 (crc_mod_CFLAGS): Likewise.
6452 (crc_mod_LDFLAGS): Likewise.
6453
6454 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add lib/hexdump.c.
6455
6456 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
6457
6458 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
6459
6460 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6461
6462 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
6463
6464 2008-07-27 Felix Zielcke <fzielcke@z-51.de>
6465
6466 * commands/help.c: Include <grub/term.h>.
6467 (TERM_WIDTH): Removed. Updated all users.
6468
6469 2008-07-27 Pavel Roskin <proski@gnu.org>
6470
6471 * util/getroot.c (find_root_device): Rephrase a comment to avoid
6472 spurious warnings about a comment within a comment.
6473
6474 2008-07-25 Robert Millan <rmh@aybabtu.com>
6475
6476 * util/getroot.c (find_root_device): Skip devices that match
6477 /dev/dm-[0-9]. This lets the real device be found for any type of
6478 abstraction (LVM, EVMS, RAID..).
6479 (grub_guess_root_device): Do not traverse /dev/mapper (for LVM)
6480 and /dev/evms (for EVMS) before traversing /dev. If a /dev/dm-[0-9]
6481 device is found first, find_root_device() will now skip it.
6482
6483 2008-07-24 Pavel Roskin <proski@gnu.org>
6484
6485 * include/grub/types.h: Use __builtin_bswap32() and
6486 __builtin_bswap64() with gcc 4.3 and newer.
6487
6488 2008-07-24 Christian Franke <franke@computer.org>
6489
6490 * util/i386/pc/grub-install.in: If `--debug' is specified,
6491 pass `--verbose' to grub-setup.
6492 Abort script if make_system_path_relative_to_its_root() fails.
6493
6494 2008-07-24 Bean <bean123ch@gmail.com>
6495
6496 * configure.ac: Fixed a bug caused by the previous cygwin patch,
6497 variable `target_platform' should be `platform'.
6498
6499 2008-07-24 Bean <bean123ch@gmail.com>
6500
6501 * video/reader/png.c (DEFLATE_HLIT_MAX): Change value.
6502 (grub_png_init_fixed_block): New function.
6503 (grub_png_decode_image_data): Handle fixed huffman code compression.
6504
6505 2008-07-24 Bean <bean123ch@gmail.com>
6506
6507 * common.rmk (bin_UTILITIES): Add grub-pe2elf.
6508 (grub_pe2elf_SOURCES): New macro.
6509 (CLEANFILES): Add grub-pe2elf.
6510
6511 * include/grub/efi/pe32.h (GRUB_PE32_SCN_ALIGN_1BYTES): New constant.
6512 (GRUB_PE32_SCN_ALIGN_2BYTES): Likewise.
6513 (GRUB_PE32_SCN_ALIGN_4BYTES): Likewise.
6514 (GRUB_PE32_SCN_ALIGN_8BYTES): Likewise.
6515 (GRUB_PE32_SCN_ALIGN_16BYTES): Likewise.
6516 (GRUB_PE32_SCN_ALIGN_32BYTES): Likewise.
6517 (GRUB_PE32_SCN_ALIGN_64BYTES): Likewise.
6518 (GRUB_PE32_SCN_ALIGN_SHIFT): Likewise.
6519 (GRUB_PE32_SCN_ALIGN_MASK): Likewise.
6520 (GRUB_PE32_SYM_CLASS_EXTERNAL): Likewise.
6521 (GRUB_PE32_SYM_CLASS_STATIC): Likewise.
6522 (GRUB_PE32_SYM_CLASS_FILE): Likewise.
6523 (GRUB_PE32_DT_FUNCTION): Likewise.
6524 (GRUB_PE32_REL_I386_DIR32): Likewise.
6525 (GRUB_PE32_REL_I386_REL32): Likewise.
6526 (grub_pe32_symbol): New structure.
6527 (grub_pe32_reloc): Likewise.
6528
6529 * util/grub-pe2elf.c: New file.
6530
6531 * configure.ac: Set TARGET_OBJ2ELF if host os is cygwin. Don't test for
6532 start symbol in non pc platform.
6533
6534 * genmk.rb: Use TARGET_OBJ2ELF to convert native object format to elf.
6535
6536 The following patches are from Christian Franke.
6537
6538 * include/grub/dl.h: Remove .previous, gas supports this only
6539 for ELF format.
6540
6541 * include/grub/symbol.h [__CYGWIN__] (#define FUNCTION/VARIABLE):
6542 Remove .type, gas supports this only for ELF format.
6543
6544 * kern/dl.c (grub_dl_resolve_dependencies): Add check for trailing
6545 nullbytes in symbol table. This fixes an infinite loop if table is
6546 zero filled.
6547
6548 * Makefile.in: Add autoconf replacements TARGET_IMG_LDSCRIPT,
6549 TARGET_IMG_LDFLAGS and EXEEXT.
6550
6551 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Replace -Wl,-N by
6552 TARGET_IMG_LDFLAGS_AC.
6553 (grub_CHECK_STACK_ARG_PROBE): New function.
6554
6555 * conf/i386-pc.rmk: Replace -Wl,-N by TARGET_IMG_LDFLAGS.
6556
6557 * conf/i386-pc-cygwin-ld-img.sc: New linker script.
6558
6559 * configure.ac: Add check for linker script "conf/${target}-img-ld.c"
6560 to set TARGET_IMG_LD* accordingly.
6561 Add check for Cygwin to set TARGET_MOD_OBJCOPY accordingly.
6562 Add call to grub_CHECK_STACK_ARG_PROBE.
6563 Use TARGET_IMG_LDFLAGS to check start, bss_start, end symbols.
6564
6565 * genkernsyms.sh.in: Handle HAVE_ASM_USCORE case.
6566
6567 * genmk.rb: Add EXEEXT to CLEANFILES.
6568
6569 2008-07-23 Robert Millan <rmh@aybabtu.com>
6570
6571 * Makefile.in (UNICODE_ARROWS, UNICODE_LINES): New variables (they
6572 define the codes for arrows and lines used for the menu).
6573 (ascii.pff): Generate fonts for $(UNICODE_ARROWS) and $(UNICODE_LINES)
6574 as well.
6575
6576 * util/update-grub_lib.in (font_path): Prefer ascii.pff over complete
6577 fonts, because the latter are too slow.
6578
6579 2008-07-21 Bean <bean123ch@gmail.com>
6580
6581 * kern/i386/pc/startup.S (gate_a20_try_bios): Change test order for
6582 a20. Run keyboard test last, as it will cause macbook to halt.
6583
6584 2008-07-18 Pavel Roskin <proski@gnu.org>
6585
6586 * kern/dl.c: Go back to using GRUB_CPU_SIZEOF_VOID_P. We cannot
6587 load foreign architecture modules correctly anyway. Keep
6588 support for loading host architecture modules, whether we
6589 compile them or not.
6590
6591 2008-07-17 Pavel Roskin <proski@gnu.org>
6592
6593 * configure.ac: Use -m32 or -m64 regardless of whether we had to
6594 change target_cpu. The compiler default can mismatch target_cpu
6595 in any case.
6596
6597 * disk/efi/efidisk.c: Fix format warnings on x86_64.
6598 * kern/efi/efi.c: Likewise.
6599
6600 * aclocal.m4 (grub_PROG_TARGET_CC): New macro. Check if the
6601 target compiler is functional.
6602 * configure.ac: Call grub_PROG_TARGET_CC once all target flags
6603 are set up.
6604
6605 * configure.ac: Default to efi platform for x86_64-apple. Allow
6606 powerpc64 CPU, default to ieee1275 platform for it. Split CPU
6607 adjustments from the rest, only do them if target is not
6608 explicitly given. Merge other adjustments with the final sanity
6609 check. Remove an extraneous check for supported CPU. Be
6610 specific which CPU and which platform is not supported.
6611
6612 * configure.ac: Default to pc platform for x86_64.
6613
6614 2008-07-17 Robert Millan <rmh@aybabtu.com>
6615
6616 Partial LinuxBIOS -> Coreboot rename.
6617
6618 * conf/i386-linuxbios.rmk: Renamed to ...
6619 * conf/i386-coreboot.rmk: ... this.
6620 * Makefile.in (RMKFILES): s/i386-linuxbios.rmk/i386-coreboot.rmk/g.
6621 * configure.ac: Accept "coreboot" as input platform (but maintain
6622 compatibility with "linuxbios").
6623 * include/grub/i386/linuxbios: Renamed to ...
6624 * include/grub/i386/coreboot: ... this.
6625
6626 2008-07-17 Bean <bean123ch@gmail.com>
6627
6628 * conf/i386/efi.rmk (pkglib_MODULES): add pci.mod and lspci.mod.
6629 (appleldr_mod_SOURCE): New variable.
6630 (appleldr_mod_CFLAGS): Likewise.
6631 (appleldr_mod_LDFLAGS): Likewise.
6632 (pci_mod_SOURCES): Likewise.
6633 (pci_mod_CFLAGS): Likewise.
6634 (pci_mod_LDFLAGS): Likewise.
6635 (lspci_mod_SOURCES): Likewise.
6636 (lspci_mod_CFLAGS): Likewise.
6637 (lspci_mod_LDFLAGS): Likewise.
6638
6639 * conf/x86_64-efi.rmk: New file.
6640
6641 * disk/efi/efidisk.c (grub_efidisk_read): Wrap efi calls with efi_call_N
6642 macro.
6643 (grub_efidisk_write): Likewise.
6644
6645 * include/efi/api.h (efi_call_0): New macro.
6646 (efi_call_1): Likewise.
6647 (efi_call_2): Likewise.
6648 (efi_call_3): Likewise.
6649 (efi_call_4): Likewise.
6650 (efi_call_5): Likewise.
6651 (efi_call_6): Likewise.
6652
6653 * include/grub/efi/chainloader.h (grub_chainloader_cmd): Rename to
6654 grub_rescue_cmd_chainloader.
6655
6656 * include/grub/efi/pe32.h (GRUB_PE32_MACHINE_X86_64): New macro.
6657 (grub_pe32_optional_header): Change some fields based on i386 or
6658 x86_64 platform.
6659 (GRUB_PE32_PE32_MAGIC): Likewise.
6660
6661 * include/grub/efi/uga_draw.h: New file.
6662
6663 * include/grub/elf.h (STN_ABS): New constant.
6664 (R_X86_64_NONE): Relocation constant for x86_64.
6665 (R_X86_64_64): Likewise.
6666 (R_X86_64_PC32): Likewise.
6667 (R_X86_64_GOT32): Likewise.
6668 (R_X86_64_PLT32): Likewise.
6669 (R_X86_64_COPY): Likewise.
6670 (R_X86_64_GLOB_DAT): Likewise.
6671 (R_X86_64_JUMP_SLOT): Likewise.
6672 (R_X86_64_RELATIVE): Likewise.
6673 (R_X86_64_GOTPCREL): Likewise.
6674 (R_X86_64_32): Likewise.
6675 (R_X86_64_32S): Likewise.
6676 (R_X86_64_16): Likewise.
6677 (R_X86_64_PC16): Likewise.
6678 (R_X86_64_8): Likewise.
6679 (R_X86_64_PC8): Likewise.
6680
6681 * include/grub/i386/efi/pci.h: New file.
6682
6683 * include/grub/i386/linux.h (GRUB_LINUX_EFI_SIGNATURE):
6684 Change it value based on platform.
6685 (GRUB_LINUX_EFI_SIGNATURE_0204): New constant.
6686 (GRUB_E820_RAM): Likewise.
6687 (GRUB_E820_RESERVED): Likewise.
6688 (GRUB_E820_ACPI): Likewise.
6689 (GRUB_E820_NVS): Likewise.
6690 (GRUB_E820_EXEC_CODE): Likewise.
6691 (GRUB_E820_MAX_ENTRY): Likewise.
6692 (grub_e820_mmap): New structure.
6693 (linux_kernel_header): Change the efi field according to different
6694 kernel version, also field from linux_kernel_header.
6695
6696 * include/grub/kernel.h (grub_module_info): Add padding for x86_64.
6697
6698 * include/grub/pci.h (GRUB_PCI_ADDR_SPACE_MASK): New constant.
6699 (GRUB_PCI_ADDR_SPACE_MEMORY): Likewise.
6700 (GRUB_PCI_ADDR_SPACE_IO): Likewise.
6701 (GRUB_PCI_ADDR_MEM_TYPE_MASK): Likewise.
6702 (GRUB_PCI_ADDR_MEM_TYPE_32): Likewise.
6703 (GRUB_PCI_ADDR_MEM_TYPE_1M): Likewise.
6704 (GRUB_PCI_ADDR_MEM_TYPE_64): Likewise.
6705 (GRUB_PCI_ADDR_MEM_PREFETCH): Likewise.
6706 (GRUB_PCI_ADDR_MEM_MASK): Likewise.
6707 (GRUB_PCI_ADDR_IO_MASK): Likewise.
6708
6709 * include/grub/x86_64/efi/kernel.h: New file.
6710
6711 * include/grub/x86_64/efi/loader.h: Likewise.
6712
6713 * include/grub/x86_64/efi/machine.h: Likewise.
6714
6715 * include/grub/x86_64/efi/pci.h: Likewise.
6716
6717 * include/grub/x86_64/efi/time.h: Likewise.
6718
6719 * include/grub/x86_64/linux.h: Likewise.
6720
6721 * include/grub/x86_64/setjmp.h: Likewise.
6722
6723 * include/grub/x86_64/time.h: Likewise.
6724
6725 * include/grub/x86_64/types.h: Likewise.
6726
6727 * kern/dl.c (GRUB_CPU_SIZEOF_VOID_P): Changed to
6728 GRUB_TARGET_SIZEOF_VOID_P.
6729
6730 * kern/efi/efi.c (grub_efi_locate_protocol): Wrap efi calls.
6731 (grub_efi_locate_handle): Likewise.
6732 (grub_efi_open_protocol): Likewise.
6733 (grub_efi_set_text_mode): Likewise.
6734 (grub_efi_stall): Likewise.
6735 (grub_exit): Likewise.
6736 (grub_reboot): Likewise.
6737 (grub_halt): Likewise.
6738 (grub_efi_exit_boot_services): Likewise.
6739 (grub_get_rtc): Likewise.
6740
6741 * kern/efi/mm.c (MEMORY_MAP_SIZE): Change to 0x3000 for new models.
6742 (GRUB_CPU_SIZEOF_VOID_P): Changed to GRUB_TARGET_SIZEOF_VOID_P.
6743 (grub_efi_allocate_pages): Wrap efi calls.
6744 (grub_efi_free_pages): Wrap efi calls.
6745 (grub_efi_get_memory_map): Wrap efi calls.
6746
6747 * kern/x86_64/dl.c: New file.
6748
6749 * kern/x86_64/efi/callwrap.S: Likewise.
6750
6751 * kern/x86_64/efi/startup.S: Likewise.
6752
6753 * loader/efi/appleloader.c: Likewise.
6754
6755 * loader/efi/chainloader.c (cmdline): New variable.
6756 (grub_chainloader_unload): Wrap efi calls.
6757 (grub_chainloader_boot): Likewise.
6758 (grub_rescue_cmd_chainloader): Wrap efi calls, handle
6759 command line.
6760
6761 * loader/efi/chainloader_normal.c (chainloader_command):
6762 Change grub_chainloader_cmd to grub_rescue_cmd_chainloader, pass
6763 command line.
6764
6765 * loader/i386/efi/linux.c (allocate_pages): Change allocation
6766 method.
6767 (grub_e820_add_region): New function.
6768 (grub_linux_boot): Construct e820 map from efi map, handle x86_64
6769 booting.
6770 (grub_find_video_card): New function.
6771 (grub_linux_setup_video): New function.
6772 (grub_rescue_cmd_linux): Probe for video information.
6773
6774 * normal/x86_64/setjmp.S: New file.
6775
6776 * term/efi/console.c (map_char): New function.
6777 (grub_console_putchar): Map unicode char.
6778 (grub_console_checkkey): Wrap efi calls.
6779 (grub_console_getkey): Likewise.
6780 (grub_console_getwh): Likewise.
6781 (grub_console_gotoxy): Likewise.
6782 (grub_console_cls): Likewise.
6783 (grub_console_setcolorstate): Likewise.
6784 (grub_console_setcursor): Likewise.
6785
6786 * util/i386/efi/grub-mkimage.c: Add support for x86_64.
6787
6788 2008-07-16 Pavel Roskin <proski@gnu.org>
6789
6790 * loader/i386/efi/linux.c (allocate_pages): Fix warnings in
6791 format strings.
6792
6793 * util/i386/efi/grub-mkimage.c (get_target_address): Return a
6794 pointer, not an integer. This fixes a warning and prevents
6795 precision loss on 64-bit systems.
6796 (relocate_addresses): Remove unneeded cast.
6797
6798 2008-07-15 Pavel Roskin <proski@gnu.org>
6799
6800 * kern/i386/ieee1275/init.c: Include grub/cache.h.
6801
6802 * term/ieee1275/ofconsole.c: Disable code unused on i386.
6803
6804 * kern/ieee1275/ieee1275.c (grub_ieee1275_get_integer_property):
6805 Fix comparison between signed and unsigned.
6806
6807 * include/grub/i386/ieee1275/console.h: Declare
6808 grub_console_init() and grub_console_fini().
6809
6810 * loader/i386/ieee1275/linux.c (grub_set_bootpath): Remove.
6811 It's empty and unused.
6812
6813 * fs/ext2.c (grub_ext2_read_block): Initialize blknr in the
6814 beginning to avoid warnings with some compilers.
6815
6816 * loader/ieee1275/multiboot2.c: Include grub/machine/loader.h.
6817 [__i386__] (grub_mb2_arch_boot): Avoid unnecessary cast.
6818
6819 2008-07-14 Pavel Roskin <proski@gnu.org>
6820
6821 * kern/env.c (grub_register_variable_hook): Don't copy empty
6822 string, it leaks memory. Pass "" to grub_env_set(), it should
6823 handle constant strings.
6824
6825 * commands/blocklist.c (grub_cmd_blocklist): Fix format warning.
6826 * commands/cmp.c (grub_cmd_cmp): Likewise.
6827 * kern/dl.c (grub_dl_flush_cache): Likewise.
6828 (grub_dl_load_core): Likewise.
6829 * kern/elf.c (grub_elf32_load_phdrs): Likewise.
6830 (grub_elf64_load_phdrs): Likewise.
6831
6832 2008-07-13 Pavel Roskin <proski@gnu.org>
6833
6834 * lib/LzmaEnc.c (LzmaEnc_SetProps): Fix warning about comparison
6835 between signed and unsigned.
6836 (LzmaEnc_Finish): Fix warning about an unused parameter.
6837
6838 2008-07-13 Bean <bean123ch@gmail.com>
6839
6840 * Makefile.in (enable_lzo): New rule.
6841
6842 * conf/i386-pc.rmk (grub_mkimage_SOURCES): New test with enable_lzo.
6843
6844 * configure.ac (ENABLE_LZO): New option --enable-lzo.
6845
6846 * boot/i386/pc/lnxboot.S: #include <config.h>.
6847
6848 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE): Change
6849 its value according to the compression algorithm used, lzo or lzma.
6850
6851 * util/i386/pc/grub-mkimage.c (compress_kernel): Use different
6852 compression algorithm according to configure macro.
6853
6854 * kern/i386/pc/startup.S (codestart): Likewise.
6855
6856 * kern/i386/pc/lzma_decode.S: New file.
6857
6858 * include/grub/lib/LzFind.h: Likewise.
6859
6860 * include/grub/lib/LzHash.h: Likewise.
6861
6862 * include/grub/lib/LzmaDec.h: Likewise.
6863
6864 * include/grub/lib/LzmaEnc.h: Likewise.
6865
6866 * include/grub/lib/LzmaTypes.h: Likewise.
6867
6868 * lib/LzFind.c: Likewise.
6869
6870 * lib/LzmaDec.c: Likewise.
6871
6872 * lib/LzmaEnc.c: Likewise.
6873
6874 2008-07-13 Bean <bean123ch@gmail.com>
6875
6876 * fs/ext2.c (EXT4_EXTENTS_FLAG): New macro.
6877 (grub_ext4_extent_header): New structure.
6878 (grub_ext4_extent): Likewise.
6879 (grub_ext4_extent_idx): Likewise.
6880 (grub_ext4_find_leaf): New function.
6881 (grub_ext2_read_block): Handle extents.
6882
6883 2008-07-12 Robert Millan <rmh@aybabtu.com>
6884
6885 * util/i386/pc/grub-mkrescue.in: s/grub-install/grub-mkrescue/g.
6886
6887 2008-07-11 Robert Millan <rmh@aybabtu.com>
6888
6889 * util/grub.d/40_custom.in: New file. Example on how to add custom
6890 entries to /etc/grub.d.
6891 * conf/common.rmk (%, update-grub_SCRIPTS, CLEANFILES): Install
6892 40_custom (implicitly, by merging all the grub.d rules).
6893
6894 2008-07-11 Pavel Roskin <proski@gnu.org>
6895
6896 * commands/read.c (grub_getline): Fix invalid memory access.
6897 Don't add newline to the variable value.
6898
6899 * term/i386/pc/serial.c (GRUB_SERIAL_PORT_NUM): New constant.
6900 [!GRUB_MACHINE_PCBIOS] (serial_hw_io_addr): Add COM2 and COM3.
6901 (serial_hw_get_port): Check validity of the port number.
6902 (grub_cmd_serial): Check return value of serial_hw_get_port().
6903
6904 2008-07-07 Pavel Roskin <proski@gnu.org>
6905
6906 * boot/i386/pc/diskboot.S (notification_string): Replace
6907 "Loading kernel" with just "loading". This is shorter, less
6908 confusing and saves a few bytes for possible future changes.
6909
6910 2008-07-05 Pavel Roskin <proski@gnu.org>
6911
6912 * disk/ata.c (grub_ata_dumpinfo): Don't output addressing and
6913 size for ATAPI devices, they are undefined. Output sector
6914 number in decimal form.
6915
6916 * disk/ata.c: Use named constants for status bits.
6917
6918 2008-07-04 Pavel Roskin <proski@gnu.org>
6919
6920 * kern/i386/linuxbios/init.c (grub_machine_init): Cast addr to
6921 grub_addr_t before casting it to the void pointer to fix a
6922 warning. Non-addressable regions are discarded earlier.
6923 (grub_arch_modules_addr): Cast _end to grub_addr_t.
6924 * kern/i386/linuxbios/table.c: Include grub/misc.h.
6925 (check_signature): Don't shadow table_header.
6926 (grub_linuxbios_table_iterate): Cast numeric constants to
6927 grub_linuxbios_table_header_t.
6928 * include/grub/i386/linuxbios/init.h: Add noreturn attribute to
6929 grub_stop().
6930
6931 * kern/ieee1275/init.c: Cast _start and _end to grub_addr_t to
6932 prevent warnings.
6933
6934 * include/grub/misc.h (ALIGN_UP): Avoid unnecessary cast to a
6935 pointer, which can cause warnings. Support 64-bit addresses.
6936
6937 * util/elf/grub-mkimage.c: Use GRUB_TARGET_SIZEOF_LONG instead
6938 of sizeof(long). This fixes PowerPC image generation on x86_64.
6939
6940 2008-07-04 Robert Millan <rmh@aybabtu.com>
6941
6942 This fixes a performance issue when pc & gpt partmap iterators
6943 didn't abort iteration even after our hook found what it was
6944 looking for (often causing expensive probes of non-existent drives).
6945
6946 Some callers relied on previous buggy behaviour, since they would
6947 raise an error when their own hooks caused early abortion of its
6948 iteration.
6949
6950 * kern/device.c (grub_device_open): Improve error message.
6951 * disk/lvm.c (grub_lvm_open): Likewise.
6952 * disk/raid.c (grub_raid_open): Likewise.
6953
6954 * partmap/pc.c (pc_partition_map_iterate): Abort parent iteration
6955 when hook requests it, independently of grub_errno.
6956 (pc_partition_map_probe): Do not fail when find_func() caused
6957 early abortion of pc_partition_map_iterate().
6958
6959 * partmap/gpt.c (gpt_partition_map_iterate): Abort parent iteration
6960 when hook requests it, independently of grub_errno.
6961 (gpt_partition_map_probe): Do not fail when find_func() caused
6962 early abortion of gpt_partition_map_iterate().
6963
6964 * kern/partition.c (grub_partition_iterate): Abort parent iteration
6965 when hook requests it, independently of grub_errno. Do not fail when
6966 part_map_iterate_hook() caused early abortion of p->iterate().
6967
6968 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Do not fail
6969 when grub_partition_iterate() returned with non-zero.
6970
6971 2008-07-03 Pavel Roskin <proski@gnu.org>
6972
6973 * disk/ata.c (grub_ata_pio_write): Check status before writing,
6974 like we do in grub_ata_pio_read().
6975 (grub_ata_readwrite): Always write individual sectors. Fix the
6976 sector count for the remainder.
6977 (grub_ata_write): Enable writing to ATA devices. Correctly
6978 report error for ATAPI devices.
6979
6980 2008-07-02 Pavel Roskin <proski@gnu.org>
6981
6982 * boot/i386/pc/cdboot.S: Add _start entry to fix a linker
6983 warning.
6984
6985 * disk/ata.c (grub_ata_readwrite): Don't increment sector number
6986 for every read sector, we already increment it for the whole
6987 batch. This fixes reading more than 256 sectors at once.
6988
6989 * util/grub-editenv.c (cmd_info): Cast argument to long
6990 explicitly. ptrdiff_t reduces to int on i386.
6991
6992 * util/grub-editenv.c (main): Be specific which parameter is
6993 missing.
6994
6995 * disk/memdisk.c (memdisk_addr): Make a pointer to fix warnings.
6996 (memdisk): Make memdisk_orig_addr a pointer.
6997
6998 * fs/reiserfs.c (grub_reiserfs_read): Fix misuse of grub_size_t
6999 for file offsets, use grub_off_t instead. Fix printf format
7000 warnings.
7001
7002 * fs/reiserfs.c: Remove #warning, TODO list items don't belong
7003 there. Real unexpected warnings should not drown in the noise
7004 about known problems.
7005
7006 * commands/hexdump.c (grub_cmd_hexdump): Fix misuse of
7007 grub_disk_addr_t for memory addresses.
7008
7009 * loader/aout.c (grub_aout_load): Cast load_addr to pointer
7010 explicitly to fix a warning.
7011
7012 * util/grub-editenv.c (cmd_info): Fix warning in printf format.
7013
7014 * Makefile.in (MODULE_LDFLAGS): New variable.
7015 * aclocal.m4 (grub_PROG_LD_BUILD_ID_NONE): New macro. Check if
7016 the linker accepts --build-id=none.
7017 * configure.ac: Call grub_PROG_LD_BUILD_ID_NONE. Substitute
7018 MODULE_LDFLAGS.
7019 * genmk.rb: Use MODULE_LDFLAGS when linking modules.
7020
7021 * fs/xfs.c (struct grub_xfs_dir_header): Use names similar to
7022 those in Linux XFS code. Provide a way to access 64-bit parent
7023 inode.
7024 (grub_xfs_iterate_dir): Use the new names. Avoid reading past
7025 the end of struct grub_xfs_dir_header.
7026
7027 2008-07-02 Bean <bean123ch@gmail.com>
7028
7029 * include/grub/ieee1275.h (grub_ieee1275_flag): New constant
7030 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
7031 and GRUB_IEEE1275_FLAG_NO_ANSI.
7032
7033 * kern/ieee1275/cmain.c (grub_ieee1275_find_options): Set flag
7034 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
7035 and GRUB_IEEE1275_FLAG_NO_ANSI for Open Hackware.
7036
7037 * kern/ieee1275/ieee1275.c (grub_ieee1275_interpret): Return
7038 immediately if GRUB_IEEE1275_FLAG_CANNOT_INTERPRET is set.
7039
7040 * kern/ieee1275/init.c (grub_claim_heap): Claim memory directly if
7041 GRUB_IEEE1275_FLAG_FORCE_CLAIM is set.
7042
7043 * term/ieee1275/ofconsole.c (grub_ofconsole_writeesc): Don't output
7044 esc sequence on non ANSI terminal.
7045 (grub_ofconsole_gotoxy): Emulate backspace key on non ANSI terminal.
7046
7047 * util/elf/grub-mkimage.c (add_segments): Move ELF header to the
7048 beginning of file.
7049
7050 2008-07-02 Bean <bean123ch@gmail.com>
7051
7052 * conf/common.rmk (bin_UTILITIES): Add grub-editenv.
7053 (grub_editenv_SOURCES): New variable.
7054 (pkglib_MODULES): Add loadenv.mod.
7055 (loadenv_mod_SOURCES): New variable.
7056 (loadenv_mod_CFLAGS): Likewise.
7057 (loadenv_mod_LDFLAGS): Likewise.
7058
7059 * include/grub/envblk.h: New file.
7060
7061 * util/envblk.c: New file.
7062
7063 * util/grub-editenv.c: New file.
7064
7065 * commands/loadenv.c: New file.
7066
7067 2008-07-01 Pavel Roskin <proski@gnu.org>
7068
7069 * include/multiboot2.h (struct multiboot_tag_module): Use char,
7070 not unsigned char. This fixes warnings and is consistent with
7071 other tags.
7072
7073 * disk/fs_uuid.c (search_fs_uuid): Correctly increment count.
7074
7075 * normal/parser.y: Define YYENABLE_NLS as 0 to fix warnings.
7076
7077 * term/tparm.c (analyze): Always set *popcount.
7078
7079 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Remove useless
7080 cast to fix a warning.
7081
7082 * loader/i386/pc/multiboot2.c (grub_mb2_arch_module_alloc): Use
7083 cast to suppress a warning.
7084
7085 * fs/afs.c (grub_afs_read_block): Return grub_disk_addr_t, as
7086 grub_fshelp_read_file() expects.
7087
7088 * fs/fat.c: Fix UUID calculation on big-endian systems. We
7089 write uuid as a 32-bit value in CPU byte order, so declare and
7090 use it as such.
7091
7092 * disk/raid.c: Cast grub_dprintf() arguments to unsigned long
7093 long if the format specifier expects it.
7094 * partmap/gpt.c (gpt_partition_map_iterate): Likewise.
7095 * partmap/pc.c (pc_partition_map_iterate): Likewise.
7096 * fs/ntfs.c (grub_ntfs_uuid): Cast data->uuid to unsigned long
7097 long to fix a warning.
7098 * fs/reiserfs.c (grub_reiserfs_read): Change casts in
7099 grub_dprintf() arguments to fix warnings.
7100
7101 2008-06-30 Pavel Roskin <proski@gnu.org>
7102
7103 * util/i386/pc/grub-setup.c (setup): Write install_dos_part and
7104 install_bsd_part immediately before core.img is embedded or
7105 modified on disk. This fixes core.img verification if core.img
7106 cannot be embedded.
7107
7108 * util/i386/pc/grub-setup.c (setup): Use core_path_dev, not
7109 core_path to calculate the blocklist.
7110 Patch from Javier Martín <lordhabbit@gmail.com>
7111
7112 2008-06-29 Robert Millan <rmh@aybabtu.com>
7113
7114 * fs/xfs.c (GRUB_XFS_FSB_TO_BLOCK): New macro. Maps filesystem
7115 block to disk block.
7116 (grub_xfs_read_block): Use GRUB_XFS_FSB_TO_BLOCK() on result.
7117 Patch from Niels Böhm <bitbucket@arcor.de>
7118
7119 2008-06-29 Robert Millan <rmh@aybabtu.com>
7120
7121 * util/update-grub_lib.in (font_path): Search for fonts in
7122 /boot/grub first, which is more likely to be readable (we aren't
7123 deciding where fonts live, just looking for them).
7124
7125 2008-06-26 Pavel Roskin <proski@gnu.org>
7126
7127 * util/biosdisk.c (read_device_map): Don't leave dead map
7128 entries for devices failing stat() check.
7129
7130 * util/i386/pc/grub-setup.c (setup): Don't reuse core_path, use
7131 core_path_dev for the core.img path on the target device.
7132
7133 2008-06-26 Robert Millan <rmh@aybabtu.com>
7134
7135 * disk/fs_uuid.c: New file.
7136 * conf/common.rmk (pkglib_MODULES): Add `fs_uuid.mod'.
7137 (fs_uuid_mod_SOURCES, fs_uuid_mod_CFLAGS)
7138 (fs_uuid_mod_LDFLAGS): New variables.
7139 * include/grub/disk.h (grub_disk_dev_id): Add
7140 `GRUB_DISK_DEVICE_UUID_ID'.
7141 * kern/disk.c (grub_disk_dev_iterate): Allow disk devices not to
7142 implement iterate().
7143
7144 2008-06-26 Robert Millan <rmh@aybabtu.com>
7145
7146 * util/grub.d/10_linux.in: Avoid passing UUIDs to Linux when either
7147 "/dev/disk/by-uuid/${GRUB_DEVICE_UUID}" does not exist, or when a
7148 Linux image includes no initrd.
7149
7150 2008-06-21 Javier Martín <lordhabbit@gmail.com>
7151
7152 * util/i386/pc/grub-setup.c (setup): Remove literal "core.img" in a
7153 call to resolve the core image location that effectively appended the
7154 name twice.
7155
7156 2008-06-21 Robert Millan <rmh@aybabtu.com>
7157
7158 * util/grub.d/00_header.in: Move last prepare_grub_to_access_device()
7159 call from here ...
7160
7161 * util/grub.d/10_hurd.in: ... to here ...
7162 * util/grub.d/10_linux.in: ... and here.
7163
7164 2008-06-19 Robert Millan <rmh@aybabtu.com>
7165
7166 * kern/main.c (grub_main): Export `prefix' variable immediately
7167 after it has been set by grub_machine_set_prefix().
7168
7169 2008-06-19 Robert Millan <rmh@aybabtu.com>
7170
7171 * commands/search.c (search_label, search_fs_uuid, search_file): Print
7172 search result when not saving to variable, not the other way around.
7173 When saving to variable, abort iteration as soon as a match is found.
7174
7175 2008-06-19 Robert Millan <rmh@aybabtu.com>
7176
7177 * util/update-grub_lib.in (prepare_grub_to_access_device): Remove
7178 check for partition that provides /boot/grub. Its logic is flawed,
7179 as it prevents prepare_grub_to_access_device() from being called
7180 multiple times.
7181
7182 2008-06-19 Robert Millan <rmh@aybabtu.com>
7183
7184 * util/update-grub_lib.in (prepare_grub_to_access_device): Issue
7185 "insmod" command directly when abstraction modules are needed,
7186 instead of relying on GRUB_PRELOAD_MODULES (which had no effect
7187 since it had already been processed).
7188
7189 2008-06-19 Pavel Roskin <proski@gnu.org>
7190
7191 * conf/i386-efi.rmk: Recompile grub-mkimage.c if Makefile has
7192 changed. This is needed in case GRUB_LIBDIR changes.
7193 * conf/i386-ieee1275.rmk: Likewise.
7194 * conf/i386-linuxbios.rmk: Likewise.
7195 * conf/i386-pc.rmk: Likewise.
7196 * conf/powerpc-ieee1275.rmk: Likewise.
7197
7198 2008-06-18 Pavel Roskin <proski@gnu.org>
7199
7200 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Rename
7201 kernel_elf_symlist.c to symlist.c for consistency with other
7202 architectures. Update all users.
7203 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
7204
7205 2008-06-18 Robert Millan <rmh@aybabtu.com>
7206
7207 * util/i386/pc/grub-install.in: If the drive is LVM or RAID, prepend
7208 it in prefix.
7209
7210 * util/i386/pc/grub-setup.c (main): Don't handle prefix at all. Set
7211 `must_embed' to 1 when root_dev is a RAID device. When dest_dev is
7212 a RAID device, run setup() for all members independently on whether
7213 LVM abstraction is being used.
7214 (setup): Don't handle prefix at all; let grub-mkimage take care of it.
7215 If grub-mkimage has set `*install_dos_part == -2', don't override this
7216 value.
7217 Perform *install_dos_part adjustments independently on whether
7218 we're embedding or not.
7219 Clarify error message when image is too big for embedding.
7220 Remove duplicate *install_dos_part stanza.
7221
7222 2008-06-17 Robert Millan <rmh@aybabtu.com>
7223
7224 * term/ieee1275/ofconsole.c (fgcolor, bgcolor): Remove variables.
7225 (grub_ofconsole_normal_color, grub_ofconsole_highlight_color): New
7226 variables.
7227 (grub_ofconsole_setcolor, grub_ofconsole_getcolor): Load/store
7228 values in grub_ofconsole_normal_color and
7229 grub_ofconsole_highlight_color (they're not directly related to
7230 background and foreground).
7231 (grub_ofconsole_setcolorstate): Extract background and foreground
7232 from grub_ofconsole_normal_color and grub_ofconsole_highlight_color.
7233
7234 2008-06-17 Robert Millan <rmh@aybabtu.com>
7235
7236 * util/update-grub_lib.in (prepare_grub_to_access_device): Use
7237 /boot/grub for the check in last commit, not /boot (they could be
7238 different partitions).
7239
7240 2008-06-16 Robert Millan <rmh@aybabtu.com>
7241
7242 * util/update-grub_lib.in (prepare_grub_to_access_device): If we were
7243 asked to setup access for the same partition that provides /boot,
7244 don't bother using UUIDs since our root already has the value we
7245 want.
7246
7247 2008-06-16 Robert Millan <rmh@aybabtu.com>
7248
7249 * util/biosdisk.c (convert_system_partition_to_system_disk): Detect
7250 I2O devices.
7251 Patch from Sven Mueller <sven@debian.org>.
7252
7253 2008-06-16 Robert Millan <rmh@aybabtu.com>
7254
7255 * util/update-grub.in: Check for $EUID instead of $UID.
7256 Reported by Vincent Zweije.
7257
7258 2008-06-16 Bean <bean123ch@gmail.com>
7259
7260 * fs/ext2.c (grub_ext2_blockgroup): Revert to pre-journal state.
7261 (grub_ext2_read_block): Likewise.
7262 (grub_ext2_read_inode): Likewise.
7263 (grub_ext2_mount): Likewise.
7264 (grub_ext2_close): Likewise.
7265 (grub_ext3_get_journal): Removed.
7266
7267 * fs/reiserfs.c (grub_reiserfs_get_item): Revert to pre-journal state.
7268 (grub_reiserfs_read_symlink): Likewise.
7269 (grub_reiserfs_mount): Likewise.
7270 (grub_reiserfs_open): Likewise.
7271 (grub_reiserfs_read): Likewise.
7272 (grub_reiserfs_close): Likewise.
7273 (grub_reiserfs_get_journal): Removed.
7274
7275 * fs/fshelp.c (grub_fshelp_read): Removed.
7276 (grub_fshelp_map_block): Likewise.
7277
7278 * include/grub/fshelp.h (grub_fshelp_journal_type): Removed.
7279 (grub_fshelp_journal): Likewise.
7280 (grub_fshelp_read): Likewise.
7281 (grub_fshelp_map_block): Likewise.
7282
7283 2008-06-16 Pavel Roskin <proski@gnu.org>
7284
7285 * conf/powerpc-ieee1275.rmk: Remove -msoft-float, we don't use
7286 floating point anymore.
7287 * include/grub/powerpc/libgcc.h: Leave only necessary exports.
7288
7289 2008-06-15 Pavel Roskin <proski@gnu.org>
7290
7291 * commands/ls.c (grub_ls_list_files): Use integer calculations
7292 for human readable format, avoid floating point use.
7293 * kern/misc.c (grub_ftoa): Remove.
7294 (grub_vsprintf): Remove floating point support.
7295
7296 2008-06-15 Robert Millan <rmh@aybabtu.com>
7297
7298 * util/grub.d/10_linux.in: Use the underlying device for loop-AES
7299 devices.
7300 Reported by Max Vozeler.
7301
7302 2008-06-15 Robert Millan <rmh@aybabtu.com>
7303
7304 * util/i386/pc/grub-mkimage.c (generate_image): If we included a drive
7305 in our prefix, set install_{dos,bsd}_part = -2 to indicate this can be
7306 skipped later.
7307 (main): If a memdisk was requested, add "(memdisk)" drive explicitly to
7308 the beginning of the prefix.
7309
7310 * kern/i386/pc/init.c (make_install_device): Remove memdisk check.
7311 It is assumed that if we have a memdisk, grub-mkimage has set
7312 grub_prefix to include the "(memdisk)" drive in it.
7313
7314 2008-06-15 Robert Millan <rmh@aybabtu.com>
7315
7316 * term/i386/pc/console.c [GRUB_MACHINE_LINUXBIOS] (grub_console_init):
7317 Initialize keyboard controller after registering the terminal, so that
7318 grub_printf() can be called from grub_keyboard_controller_init().
7319
7320 2008-06-15 Robert Millan <rmh@aybabtu.com>
7321
7322 * fs/sfs.c (grub_sfs_read_extent): Fix the count of nodes in
7323 extent-btree which is written as big endian on disk.
7324 Reported by Alain Greppin <al@chilibi.org>.
7325
7326 2008-06-14 Robert Millan <rmh@aybabtu.com>
7327
7328 * util/i386/efi/grub-install.in (modules): Remove `_chain'.
7329 * util/i386/pc/grub-install.in (modules): Likewise.
7330
7331 2008-06-13 Pavel Roskin <proski@gnu.org>
7332
7333 * commands/ls.c (grub_ls_list_files): Fix format warnings.
7334
7335 2008-06-13 Bean <bean123ch@gmail.com>
7336
7337 * commands/hexdump.c (grub_cmd_hexdump): Adjust offset for partition.
7338
7339 * fs/ext2.c (grub_ext3_get_journal): Fix revoke block handling.
7340
7341 * fs/fshelp.c (grub_fshelp_map_block): Don't map block 0 as it's used
7342 to indicate sparse block.
7343
7344 2008-06-12 Pavel Roskin <proski@gnu.org>
7345
7346 * fs/ext2.c (grub_ext2_read_inode): Don't normalize block
7347 number, grub_fshelp_read() does it for us.
7348
7349 * fs/fshelp.c (grub_fshelp_read): New function. Implement
7350 linear disk read with journal translation.
7351 * fs/ext2.c: Use grub_fshelp_read() instead of grub_disk_read().
7352 * include/grub/fshelp.h: Declare grub_fshelp_read().
7353
7354 2008-06-09 Pavel Roskin <proski@gnu.org>
7355
7356 * fs/minix.c (grub_minix_mount): Handle error reading
7357 superblock.
7358
7359 2008-06-08 Robert Millan <rmh@aybabtu.com>
7360
7361 * util/i386/pc/grub-setup.c (main): If install drive is an LVM,
7362 don't append the RAID prefix afterwards.
7363 Reported by Clint Adams.
7364
7365 2008-06-08 Robert Millan <rmh@aybabtu.com>
7366
7367 Based on description from Pavel:
7368 * kern/disk.c (grub_disk_check_range): Rename to ...
7369 (grub_disk_adjust_range): ... this. Add a comment explaining the
7370 tasks performed by this function.
7371
7372 2008-06-08 Robert Millan <rmh@aybabtu.com>
7373
7374 * include/grub/ntfs.h (struct grub_ntfs_bpb): Rename `serial_number' to
7375 `num_serial' (for consistency with other variables).
7376 (struct grub_ntfs_data): Add `uuid' member.
7377 * fs/ntfs.c (grub_ntfs_mount): Initialize `data->uuid'.
7378 (grub_ntfs_uuid): New function.
7379 (grub_ntfs_fs): Reference grub_ntfs_uuid() in `uuid' struct member.
7380
7381 2008-06-07 Pavel Roskin <proski@gnu.org>
7382
7383 * util/biosdisk.c (open_device): Revert last change to the
7384 function, it broke installation. The sector needs to be
7385 different dependent on which device is opened.
7386
7387 2008-06-06 Robert Millan <rmh@aybabtu.com>
7388
7389 Ensure GRUB_KERNEL_MACHINE_DATA_END is always consistent with the
7390 rest of GRUB, and breakage doesn't happen if its value were modified.
7391
7392 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
7393 Redefine as an offset from `GRUB_KERNEL_MACHINE_DATA_END' instead of
7394 a constant (same value).
7395 * kern/i386/pc/startup.S: Replace hardcoded `0x50' with
7396 `GRUB_KERNEL_MACHINE_DATA_END' (same value).
7397
7398 2008-06-06 Robert Millan <rmh@aybabtu.com>
7399
7400 * util/biosdisk.c (open_device): Do not modify sector offset when
7401 accessing a partition. kern/disk.c already handles this for us.
7402
7403 2008-06-06 Robert Millan <rmh@aybabtu.com>
7404
7405 * util/grub-emu.c (grub_machine_init): Move code in this function from
7406 here ...
7407 (main): ... to here (before grub_util_biosdisk_init() call, to prevent
7408 segfault in case grub_printf() is called).
7409
7410 * util/i386/pc/grub-install.in: Append `--device-map=${device_map}' to
7411 grub_probe. Update all users not to explicitly add it again.
7412 (grub_device): New variable; contains corresponding device for grubdir.
7413 (fs_module, partmap_module, devabstraction_module): Pass
7414 `--device ${grub_device}' to grub_probe to avoid traversing /dev
7415 every time.
7416
7417 2008-06-05 Robert Millan <rmh@aybabtu.com>
7418
7419 * normal/misc.c (grub_normal_print_device_info): When a filesystem UUID
7420 is found, print it (same layout as with labels).
7421
7422 2008-06-04 Robert Millan <rmh@aybabtu.com>
7423
7424 * util/biosdisk.c (get_drive): Rename to ...
7425 (find_grub_drive): ... this. Update all users.
7426
7427 (get_os_disk): Rename to ...
7428 (convert_system_partition_to_system_disk): ... this. Update all users.
7429
7430 (find_drive): Rename to ...
7431 (find_system_device): ... this. Update all users.
7432
7433 2008-06-04 Robert Millan <rmh@aybabtu.com>
7434
7435 * util/biosdisk.c (get_os_disk): Handle IDA devices.
7436 * util/grub-mkdevicemap.c (get_mmc_disk_name)
7437 (make_device_map): Likewise.
7438
7439 2008-06-01 Robert Millan <rmh@aybabtu.com>
7440
7441 * util/biosdisk.c (get_drive): Verify that `map[i].drive' is non-NULL
7442 before dereferencing it.
7443
7444 * fs/fat.c (struct grub_fat_bpb): Move fat32-specific fields into a
7445 union with fat12/fat16-specific ones. Add some new fields, including
7446 `num_serial' for both versions.
7447 (struct grub_fat_data): Add `uuid' member.
7448 (grub_fat_mount): Refer to fat32-specific fields in `bpb' by their new
7449 names. Initialize `data->uuid' using `num_serial'.
7450 (grub_fat_uuid): New function.
7451 (grub_fat_fs): Reference grub_fat_uuid() in `uuid' struct member.
7452
7453 * fs/reiserfs.c (grub_reiserfs_superblock): Add `uuid' field.
7454 (grub_reiserfs_uuid): New function.
7455 (grub_reiserfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct
7456 member.
7457
7458 * fs/xfs.c (grub_xfs_sblock): Add `uuid' field.
7459 (grub_xfs_uuid): New function.
7460 (grub_xfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct member.
7461
7462 2008-06-01 Robert Millan <rmh@aybabtu.com>
7463
7464 * util/update-grub_lib.in (prepare_grub_to_access_device): Generate
7465 code that is backward compatible with pre-uuid search command.
7466
7467 2008-05-31 Robert Millan <rmh@aybabtu.com>
7468
7469 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Iterate through
7470 floppies after everything else, to ensure floppy drive isn't accessed
7471 unnecessarily (patch from Bean).
7472
7473 2008-05-31 Robert Millan <rmh@aybabtu.com>
7474
7475 * commands/search.c (search_label, search_fs_uuid, search_file): Do
7476 not print device names when we were asked to set a variable.
7477
7478 2008-05-31 Robert Millan <rmh@aybabtu.com>
7479
7480 * term/ieee1275/ofconsole.c (grub_ofconsole_setcursor): Implement
7481 using "cursor-on" and "cursor-off" commands (understood at least by
7482 the Open Firmware flavour on OLPC).
7483
7484 2008-05-31 Michael Gorven <michael@gorven.za.net>
7485
7486 * term/terminfo.c (grub_terminfo_set_current): Correct vt100 cursor
7487 on and off sequences.
7488
7489 2008-05-31 Robert Millan <rmh@aybabtu.com>
7490
7491 * util/update-grub_lib.in: Replace `grub-probe' with `${grub_probe}'.
7492 * util/update-grub.in: Likewise.
7493
7494 2008-05-30 Pavel Roskin <proski@gnu.org>
7495
7496 * util/biosdisk.c (linux_find_partition): Simplify logic and
7497 make the code more universal. Keep special processing for
7498 devfs, but use a simple rule for all other devices. If the
7499 device ends with a number, append 'p' and the partition number.
7500 Otherwise, append only the partition number.
7501
7502 2008-05-30 Robert Millan <rmh@aybabtu.com>
7503
7504 * util/update-grub.in (GRUB_DISABLE_LINUX_UUID): Export variable.
7505 * util/grub.d/10_linux.in: If GRUB_DEVICE_UUID is set, and
7506 GRUB_DISABLE_LINUX_UUID isn't true, use the filesystem UUIDs as
7507 the `root' parameter to Linux.
7508
7509 2008-05-30 Robert Millan <rmh@aybabtu.com>
7510
7511 * commands/search.c (options): Rename --fs_uuid to --fs-uuid.
7512 * util/update-grub_lib.in (prepare_grub_to_access_device): Replace
7513 --fs_uuid with --fs-uuid.
7514 * util/update-grub.in: Allow filesystem UUID probes to fail (since not
7515 all filesystems support them).
7516
7517 2008-05-30 Robert Millan <rmh@aybabtu.com>
7518
7519 * fs/ext2.c (grub_ext2_uuid): Use `04x' instead of '02x' as
7520 grub_printf() flags, since we're printing in units of 2 bytes.
7521
7522 2008-05-30 Robert Millan <rmh@aybabtu.com>
7523
7524 * util/grub.d/00_header.in: Remove obsolete comment referencing
7525 convert_system_path_to_grub_path().
7526 * util/update-grub.in: Likewise.
7527 * util/update-grub_lib.in (is_path_readable_by_grub): New function.
7528 (convert_system_path_to_grub_path): Add a warning message explaining
7529 that this function is deprecated. Rely on is_path_readable_by_grub()
7530 for the readability checks.
7531 (font_path): Use is_path_readable_by_grub() for the readability
7532 check rather than convert_system_path_to_grub_path().
7533
7534 2008-05-30 Robert Millan <rmh@aybabtu.com>
7535
7536 * util/update-grub_lib.in (prepare_grub_to_access_device): New function.
7537 * util/update-grub.in: Set `GRUB_FONT_PATH' to the system path, without
7538 converting it first.
7539 * util/grub.d/00_header.in: Use prepare_grub_to_access_device() to setup
7540 grub.cfg for access to font file, and afterwards call it again to set
7541 the root device.
7542
7543 2008-05-30 Robert Millan <rmh@aybabtu.com>
7544
7545 * commands/search.c (options): Add --fs_uuid option.
7546 (search_fs_uuid): New function.
7547 (grub_cmd_search): Fix --set argument passing.
7548 Use search_fs_uuid() when requested via --fs_uuid.
7549 (grub_search_init): Update help message.
7550 * fs/ext2.c (struct grub_ext2_sblock): Rename `unique_id' to `uuid'
7551 and redeclare it as an array of 16-bit words.
7552 (grub_ext2_uuid): New function.
7553 (grub_ext2_fs): Reference grub_ext2_uuid() in `uuid' struct member.
7554 * include/grub/fs.h (struct grub_fs): Add `uuid' struct member.
7555 * util/update-grub.in (GRUB_DEVICE_UUID, GRUB_DEVICE_BOOT)
7556 (GRUB_DEVICE_BOOT_UUID): New variables.
7557 (GRUB_DRIVE. GRUB_DRIVE_BOOT. GRUB_DRIVE_BOOT_GRUB): Remove.
7558 * util/grub.d/00_header.in: Set root using `search --fs_uuid' command
7559 whenever possible.
7560 * util/grub.d/10_hurd.in: Avoid explicit use of root drive. Instead,
7561 just assume `root' variable has the right value.
7562 * util/grub.d/10_linux.in: Likewise.
7563 * util/grub-probe.c (probe): Probe for filesystem UUID when requested
7564 via PRINT_FS_UUID.
7565 (main): Recognise `-t fs_uuid' argument.
7566
7567 2008-05-30 Robert Millan <rmh@aybabtu.com>
7568
7569 * util/biosdisk.c (map): Redefine structure to hold information
7570 about GRUB drive name.
7571 (get_drive): Reimplement without assuming (and verifying) BIOS-like
7572 drive names.
7573 (call_hook): Remove.
7574 (grub_util_biosdisk_iterate): Access drive names via `.drive' struct
7575 member. Assume drive has partitions.
7576 (grub_util_biosdisk_open): Access device names via `.device' struct
7577 member.
7578 (open_device): Likewise.
7579 (find_drive): Likewise.
7580 (read_device_map): Adjust map[] usage to match the new struct
7581 definition. Don't check for duplicates (still possible, but not cheap
7582 anymore).
7583 (grub_util_biosdisk_fini): Free malloced buffers referenced by map[].
7584 (make_device_name): Remove assumption of BIOS-like drive names.
7585
7586 2008-05-30 Pavel Roskin <proski@gnu.org>
7587
7588 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Remove, as
7589 compiling execute.c doesn't need grub_script.tab.h anymore.
7590 (normal/command.c_DEPENDENCIES): Likewise.
7591 (normal/function.c_DEPENDENCIES): Likewise.
7592 * conf/i386-ieee1275.rmk: Likewise.
7593 * conf/i386-linuxbios.rmk: Likewise.
7594 * conf/i386-pc.rmk: Likewise.
7595 * conf/powerpc-ieee1275.rmk: Likewise.
7596 * conf/sparc64-ieee1275.rmk: Likewise.
7597
7598 2008-05-29 Pavel Roskin <proski@gnu.org>
7599
7600 * disk/lvm.c (grub_lvm_scan_device): Check for the buffer end
7601 when scanning metadata for volume group name.
7602
7603 * include/grub/script.h: Don't include grub_script.tab.h. It's
7604 a generated file, which may only be included from the files with
7605 DEPENDENCIES rules in the makefile. Don't use typedef YYSTYPE,
7606 use union YYSTYPE, as the later allows forward declaration.
7607 * normal/lexer.c: Don't use typedef YYSTYPE, use union YYSTYPE.
7608
7609 2008-05-29 Robert Millan <rmh@aybabtu.com>
7610
7611 * term/i386/pc/at_keyboard.c: Include `grub/machine/machine.h'.
7612 (OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): New macros.
7613 [GRUB_MACHINE_IEEE1275] (keyboard_map): Add OLPC scan codes
7614 (grub_console_checkkey): Add grub_dprintf() call to report unknown
7615 scan codes.
7616
7617 2008-05-29 Robert Millan <rmh@aybabtu.com>
7618
7619 * term/i386/pc/at_keyboard.c (grub_console_checkkey): Add support for
7620 control key combinations.
7621
7622 2008-05-29 Robert Millan <rmh@aybabtu.com>
7623
7624 * util/powerpc/ieee1275/grub-install.in: Move from here ...
7625 * util/ieee1275/grub-install.in: ... to here.
7626 * powerpc-ieee1275.rmk (grub_install_SOURCES): Update location.
7627 * i386-ieee1275.rmk (sbin_SCRIPTS): New variable.
7628 (grub_install_SOURCES): Likewise.
7629
7630 2008-05-29 Robert Millan <rmh@aybabtu.com>
7631
7632 * fs/affs.c: Update copyright year.
7633 * fs/ext2.c: Likewise.
7634 * fs/fshelp.c: Likewise.
7635 * fs/hfsplus.c: Likewise.
7636 * fs/ntfs.c: Likewise.
7637 * fs/xfs.c: Likewise.
7638 * include/grub/fshelp.h: Likewise.
7639 * util/grub-mkdevicemap.c: Likewise.
7640
7641 2008-05-28 Robert Millan <rmh@aybabtu.com>
7642
7643 * util/update-grub.in: Allow chmod call to fail, since /boot/grub/
7644 might need to be fatfs to support some firmware implementations
7645 (e.g. OFW or EFI).
7646
7647 2008-05-28 Robert Millan <rmh@aybabtu.com>
7648
7649 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle MMC
7650 devices.
7651 * util/grub-mkdevicemap.c (get_mmc_disk_name)
7652 (make_device_map): Likewise.
7653
7654 2008-05-20 Bean <bean123ch@gmail.com>
7655
7656 * fs/fshelp.c (grub_fshelp_map_block): New function.
7657 (grub_fshelp_find_file): Use 64-bit type for pos and block address.
7658 Use `>>' and `&' operator to avoid 64-bit divide and modulo.
7659
7660 * include/grub/fshelp.h (grub_fshelp_journal_type): New enum.
7661 (GRUB_FSHELP_JOURNAL_UNUSED_MAPPING): New macro.
7662 (grub_fshelp_journal): New structure.
7663 (grub_fshelp_map_block): New function prototype.
7664 (grub_fshelp_read_file): Use grub_disk_addr_t as block type.
7665 (grub_fshelp_map_block): Likewise.
7666
7667 * fs/ext2.c (EXT3_FEATURE_COMPAT_HAS_JOURNAL): New macro.
7668 (EXT3_JOURNAL_MAGIC_NUMBER): Likewise.
7669 (EXT3_JOURNAL_DESCRIPTOR_BLOCK): Likewise.
7670 (EXT3_JOURNAL_COMMIT_BLOCK): Likewise.
7671 (EXT3_JOURNAL_SUPERBLOCK_V1): Likewise.
7672 (EXT3_JOURNAL_SUPERBLOCK_V2): Likewise.
7673 (EXT3_JOURNAL_REVOKE_BLOCK): Likewise.
7674 (EXT3_JOURNAL_FLAG_ESCAPE): Likewise.
7675 (EXT3_JOURNAL_FLAG_SAME_UUID): Likewise.
7676 (EXT3_JOURNAL_FLAG_DELETED): Likewise.
7677 (EXT3_JOURNAL_FLAG_LAST_TAG): Likewise.
7678 (grub_ext2_sblock): New members for journal support.
7679 (grub_ext3_journal_header): New structure.
7680 (grub_ext3_journal_revoke_header): Likewise.
7681 (grub_ext3_journal_block_tag): Likewise.
7682 (grub_ext3_journal_sblock): Likewise.
7683 (grub_fshelp_node): New members logfile and journal.
7684 (grub_ext2_read_block): Change block type to grub_disk_addr_t. Use
7685 grub_fshelp_map_block to get real block number.
7686 (grub_ext2_blockgroup): Use grub_fshelp_map_block to get real block
7687 number.
7688 (grub_ext2_read_inode): Likewise.
7689 (grub_ext3_get_journal): New function.
7690 (grub_read_inode): Initialize journal using grub_ext3_get_journal.
7691 (grub_ext2_close): Release memory used by journal.
7692
7693 * fs/reiserfs.c (REISERFS_MAGIC_STRING): Changed to "ReIsEr".
7694 (REISERFS_MAGIC_DESC_BLOCK): New macro.
7695 (grub_reiserfs_transaction_header): Renamed to
7696 grub_reiserfs_description_block, replace field data with real_blocks.
7697 (grub_reiserfs_commit_block): New structure.
7698 (grub_reiserfs_data): New member journal.
7699 (grub_reiserfs_get_item): Use grub_fshelp_map_block to get real block
7700 number.
7701 (grub_reiserfs_read_symlink): Likewise.
7702 (grub_reiserfs_iterate_dir): Likewise.
7703 (grub_reiserfs_open): Likewise.
7704 (grub_reiserfs_read): Likewise.
7705 (grub_reiserfs_get_journal): New function.
7706 (grub_reiserfs_mount): Use "ReIsEr" as super block magic, as there are
7707 three varieties ReIsErFs, ReIsEr2Fs and ReIsEr3Fs. Initialize journal
7708 using grub_reiserfs_get_journal.
7709 (grub_reiserfs_close): Release memory used by journal.
7710
7711 * fs/affs.c (grub_affs_read_block): Change block type to
7712 grub_disk_addr_t. Use grub_divmod64 to do 64-bit division.
7713
7714 * fs/afs.c (grub_afs_read_block): Change block type to grub_disk_addr_t.
7715
7716 * fs/hfsplus.c (grub_hfsplus_read_block): Likewise.
7717
7718 * fs/ntfs.c (grub_ntfs_read_block): Likewise.
7719
7720 * fs/udf.c (grub_udf_read_block): Change block type to
7721 grub_disk_addr_t. Use type cast to avoid warning.
7722
7723 * fs/xfs.c (grub_xfs_read_block): Likewise.
7724
7725 2008-05-16 Christian Franke <franke@computer.org>
7726
7727 * commands/cat.c (grub_cmd_cat): Remove non-ESC keys from keyboard queue
7728 to ensure that break with ESC will always work.
7729 * commands/sleep.c (grub_interruptible_millisleep): Likewise.
7730 Remove ESC from keyboard queue.
7731
7732 2008-05-16 Christian Franke <franke@computer.org>
7733
7734 * util/biosdisk.c: [__CYGWIN__] Add includes.
7735 (grub_util_biosdisk_open): Use Linux code also for Cygwin.
7736 (get_os_disk): Move variable declarations to OS specific
7737 parts to avoid warning.
7738 [__GNU__] (get_os_disk): Fix /dev/sdXsN case.
7739 [__CYGWIN__] (get_os_disk): Add Cygwin /dev/sdXN device names.
7740 (grub_util_biosdisk_get_grub_dev): Use Linux code also for
7741 Cygwin.
7742 * util/getroot.c: [__CYGWIN__] Add includes.
7743 (strip_extra_slashes): Fix "/" case.
7744 [__CYGWIN__] (get_win32_path): New function.
7745 [__CYGWIN__] (grub_get_prefix): Add conversion to win32 path.
7746 [__CYGWIN__] (find_root_device): Disable.
7747 [__CYGWIN__] (get_bootsec_serial): New function.
7748 [__CYGWIN__] (find_cygwin_root_device): Likewise.
7749 [__linux__] (grub_guess_root_device): Add early returns to simplify
7750 structure.
7751 [__CYGWIN__] (grub_guess_root_device): Call find_cygwin_root_device.
7752 [__linux__] (grub_util_get_dev_abstraction): Enable LVM and RAID
7753 check for Linux only.
7754
7755 2008-05-15 Bean <bean123ch@gmail.com>
7756
7757 * kern/i386/pc/startup.S (grub_console_getkey): Workaround for the
7758 keyboard hang problem in apple's intel mac.
7759
7760 2008-05-09 Robert Millan <rmh@aybabtu.com>
7761
7762 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle Virtio
7763 devices.
7764 * util/grub-mkdevicemap.c (get_virtio_disk_name)
7765 (make_device_map): Likewise.
7766 Reported by Aurelien Jarno <aurel32@debian.org>
7767
7768 2008-05-07 Ian Campbell <ijc@hellion.org.uk>
7769
7770 * util/biosdisk.c (get_os_disk): Recognise xvd type disks.
7771 * util/grub-mkdevicemap.c (get_xvd_disk_name): New function.
7772 (make_device_map): Output entries for xvd type disks.
7773
7774 2008-05-07 Robert Millan <rmh@aybabtu.com>
7775
7776 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle CCISS
7777 devices.
7778 * util/grub-mkdevicemap.c (get_cciss_disk_name)
7779 (make_device_map): Likewise.
7780 Reported by Roland Dreier <rdreier@cisco.com>
7781
7782 2008-05-07 Robert Millan <rmh@aybabtu.com>
7783
7784 * disk/lvm.c (grub_lvm_scan_device): Detect errors in an additional
7785 grub_strstr() call. Correct a few mistakes in failure path handling.
7786
7787 2008-05-06 Robert Millan <rmh@aybabtu.com>
7788
7789 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
7790 Do not print a trailing slash (therefore, the root directory is an
7791 empty string).
7792 (convert_system_path_to_grub_path): Do not remove trailing slash
7793 from make_system_path_relative_to_its_root() output.
7794
7795 * util/i386/pc/grub-install.in: Add trailing slash to output from
7796 make_system_path_relative_to_its_root().
7797
7798 2008-05-06 Robert Millan <rmh@aybabtu.com>
7799
7800 * util/grub-fstest.c (grub_refresh): Call `fflush (stdout)'. This
7801 ensures that output lines aren't intermangled with those sent to
7802 stderr (via grub_util_info()).
7803 * util/grub-probe.c (grub_refresh): Likewise.
7804 * util/i386/pc/grub-setup.c (grub_refresh): Likewise.
7805
7806 2008-05-05 Christian Franke <franke@computer.org>
7807
7808 * util/grub-mkdevicemap.c (get_floppy_disk_name) [__CYGWIN__]:
7809 Add Cygwin device names.
7810 (get_ide_disk_name) [__CYGWIN__]: Likewise.
7811 (get_scsi_disk_name) [__CYGWIN__]: Likewise.
7812 (check_device): Return error instead of success on empty name.
7813 (make_device_map): Move label inside linux specific code to
7814 prevent compiler warning.
7815
7816 2008-04-30 Robert Millan <rmh@aybabtu.com>
7817
7818 Based on patch from Fabian Greffrath <greffrath@leat.rub.de>
7819 * util/grub.d/10_linux.in: Add ${GRUB_CMDLINE_LINUX_DEFAULT} to the
7820 first boot option.
7821 * util/update-grub.in: Export GRUB_CMDLINE_LINUX_DEFAULT.
7822
7823 2008-04-29 Robert Millan <rmh@aybabtu.com>
7824
7825 * docs/grub.cfg: New file (example GRUB configuration).
7826
7827 2008-04-26 Robert Millan <rmh@aybabtu.com>
7828
7829 * DISTLIST: Sort (sort -u < DISTLIST | sponge DISTLIST). Add
7830 `loader/i386/ieee1275/linux.c', `loader/i386/ieee1275/linux_normal.c'
7831 and `disk/ieee1275/nand.c'.
7832
7833 2008-04-25 Bean <bean123ch@gmail.com>
7834
7835 * Makefile.in (RMKFILES): Add missing arch i386-ieee1275 and
7836 i386-linuxbios.
7837
7838 * commands/hexdump.c (grub_cmd_hexdump): Support dumping of device,
7839 change the buffer size to 4096 for cdrom device.
7840
7841 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add _linux.mod, linux.mod
7842 and nand.mod.
7843 (_linux_mod_SOURCES): New variable.
7844 (_linux_mod_CFLAGS): Likewise.
7845 (_linux_mod_LDFLAGS): Likewise.
7846 (linux_mod_SOURCES): Likewise.
7847 (linux_mod_CFLAGS): Likewise.
7848 (linux_mod_LDFLAGS): Likewise.
7849 (nand_mod_SOURCES): Likewise.
7850 (nand_mod_CFLAGS): Likewise.
7851 (nand_mod_LDFLAGS): Likewise.
7852
7853 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Return
7854 GRUB_ERR_UNKNOWN_DEVICE instead of GRUB_ERR_BAD_DEVICE if no device
7855 type property. (nand device in olpc don't have this property)
7856
7857 * include/grub/disk.h (grub_disk_dev_id): New macro
7858 GRUB_DISK_DEVICE_NAND_ID.
7859
7860 * include/grub/i386/ieee1275/loader.h (grub_rescue_cmd_linux): New
7861 function prototype.
7862 (grub_rescue_cmd_initrd): Likewise.
7863
7864 * include/grub/i386/linux.h (GRUB_LINUX_OFW_SIGNATURE): New macro.
7865 (linux_kernel_params): Add new member ofw_signature, ofw_num_items,
7866 ofw_cif_handler and ofw_idt, adjust padding number.
7867
7868 * include/grub/i386/pc/memory.h (grub_upper_mem): Export it if
7869 GRUB_MACHINE_IEEE1275 is defined.
7870
7871 * include/grub/ieee1275/ieee1275.h (grub_available_iterate):
7872 Use NESTED_FUNC_ATTR attribute on the hook parameter.
7873
7874 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Use NESTED_FUNC_ATTR
7875 on nested function heap_init.
7876 (grub_upper_mem): New variable for i386-ieee1275.
7877 (grub_get_extended_memory): New function for i386-ieee1275.
7878 (grub_machine_init): Call grub_get_extended_memory for i386-ieee1275.
7879
7880 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Use
7881 NESTED_FUNC_ATTR on the hook parameter. Don't quit if no device type
7882 property.
7883
7884 * loader/i386/ieee1275/linux.c: New file.
7885
7886 * loader/i386/ieee1275/linux_normal.c: New file.
7887
7888 * disk/ieee1275/nand.c: New file.
7889
7890 2008-04-18 Thomas Schwinge <tschwinge@gnu.org>
7891
7892 * util/i386/pc/grub-mkrescue.in (grub_mkimage): Don't overwrite correct
7893 value.
7894 * util/powerpc/ieee1275/grub-mkrescue.in (grub_mkimage): Likewise.
7895
7896 2008-04-18 Robert Millan <rmh@aybabtu.com>
7897
7898 Restructures early code path on ieee1275 to unify grub_main() as
7899 the first C function that is executed in every platform.
7900
7901 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_init): New prototype.
7902 * kern/i386/ieee1275/startup.S (_start): Jump to grub_main() instead of
7903 cmain().
7904 * kern/powerpc/ieee1275/crt0.S (_start): Likewise.
7905 * kern/ieee1275/cmain.c (cmain): Rename to ...
7906 * kern/ieee1275/cmain.c (grub_ieee1275_init): ... this.
7907 * kern/ieee1275/init.c (grub_machine_init): Call grub_ieee1275_init()
7908 at the beginning.
7909
7910 2008-04-18 Robert Millan <rmh@aybabtu.com>
7911
7912 * util/update-grub.in: Fix syntax error when setting
7913 `GRUB_PRELOAD_MODULES'.
7914 Reported by Stephane Chazelas <stephane@artesyncp.com>
7915
7916 2008-04-17 Lubomir Kundrak <lkundrak@redhat.com>
7917
7918 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): take only .text
7919 section into account, newer toolchains generate unique build ids
7920 * configure.ac: remove the test for --build-id=none acceptance,
7921 we want build ids to be preserved
7922 * genmk.rb: add -R .note.gnu.build-id to objcopy, so build id
7923 far from other sections don't cause the raw binary images grow
7924 size
7925
7926 2008-04-15 Robert Millan <rmh@aybabtu.com>
7927
7928 * disk/lvm.c: Update copyright year.
7929 * kern/misc.c: Likewise.
7930
7931 2008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
7932
7933 * disk/lvm.c (grub_lvm_scan_device): Add forgotten failure path when
7934 there is no memory left for physical volume name.
7935
7936 2008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
7937
7938 * disk/lvm.c (grub_lvm_scan_device): Fix logical volume's physical
7939 volume name mapping to support bigger than 9 character names properly.
7940
7941 2008-04-13 Robert Millan <rmh@aybabtu.com>
7942
7943 * disk/i386/pc/biosdisk.c (grub_biosdisk_rw): Fix CHS limit check,
7944 as per http://www.allensmith.net/Storage/HDDlimit/Int13h.htm
7945
7946 2008-04-13 Christian Franke <franke@computer.org>
7947
7948 * util/i386/pc/grub-mkrescue.in: Add --emulation=floppy
7949 to create a floppy emulation boot CD when non emulation mode
7950 does not work.
7951 Enable Joliet CD filesystem extension.
7952
7953 2008-04-13 Robert Millan <rmh@aybabtu.com>
7954
7955 * kern/misc.c (grub_strncat): Fix off-by-one error.
7956 Reported by Zhang Huan <zhanghuan@nrchpc.ac.cn>
7957
7958 * kern/env.c (grub_env_context_close): Clear current context, not
7959 previous one.
7960 Patch from Zhang Huan <zhanghuan@nrchpc.ac.cn>
7961
7962 * kern/misc.c (grub_strcat): Minor speed optimization (same code size).
7963
7964 2008-04-13 Robert Millan <rmh@aybabtu.com>
7965
7966 Improve robustness when handling LVM.
7967
7968 * disk/lvm.c (grub_lvm_getvalue): Return 0 when `*p' is NULL
7969 (and leave `*p' unmodified).
7970 (grub_lvm_iterate): Don't assume `vg->lvs != NULL' when iterating
7971 through it.
7972 (grub_lvm_memberlist): Don't assume `lv->vg->pvs != NULL' when
7973 iterating through it.
7974 (grub_lvm_open): Don't assume `vg->lvs != NULL' when iterating
7975 through it.
7976 (grub_lvm_scan_device): Check the return value (and fail gracefully
7977 when due) on each grub_lvm_getvalue() or grub_strstr() call.
7978 Don't assume `vg->pvs != NULL' when iterating through it.
7979
7980 2008-04-13 Robert Millan <rmh@aybabtu.com>
7981
7982 * gendistlist.sh (EXTRA_DISTFILES): Add `genpartmaplist.sh'.
7983 * genmk.rb (partmap): New variable.
7984 (CLEANFILES, PARTMAPFILES): Add #{partmap}.
7985 (#{partmap}): New target rule.
7986 * genpartmaplist.sh: New file.
7987 * Makefile.in (pkglib_DATA): Add partmap.lst.
7988 (partmap.lst): New target rule.
7989 * util/i386/pc/grub-mkrescue.in: Generate grub.cfg that loads needed
7990 modules (including all partition maps), instead of preloading them.
7991
7992 2007-04-13 Fabian Greffrath <fabian.greffrath@web.de>
7993
7994 * util/grub.d/30_os-prober.in: New script. Use `os-prober' and
7995 `linux-boot-prober' (if installed) to detect other operating
7996 systems which are installed on the computer and add them to
7997 the boot menu.
7998 * conf/common.rmk: Build and install 30_os-prober.
7999
8000 2008-04-12 Robert Millan <rmh@aybabtu.com>
8001
8002 * kern/powerpc/ieee1275/init.c: Move from here ...
8003 * kern/ieee1275/init.c: ... to here. Update all users.
8004
8005 * kern/powerpc/ieee1275/cmain.c: Move from here ...
8006 * kern/ieee1275/cmain.c: ... to here. Update all users.
8007
8008 * kern/powerpc/ieee1275/openfw.c: Move from here ...
8009 * kern/ieee1275/openfw.c: ... to here. Update all users.
8010
8011 * loader/powerpc/ieee1275/multiboot2.c: Move from here ...
8012 * loader/ieee1275/multiboot2.c: ... to here. Update all users.
8013
8014 2008-04-10 Pavel Roskin <proski@gnu.org>
8015
8016 * configure.ac: Always use "_cv_" in cache variables for
8017 compatibility with Autoconf 2.62.
8018
8019 2008-04-07 Robert Millan <rmh@aybabtu.com>
8020
8021 Revert grub/machine/init.h addition by Pavel (since it breaks on
8022 i386-ieee1275 and others):
8023 * util/i386/pc/misc.c: Remove grub/machine/init.h.
8024 * util/powerpc/ieee1275/misc.c: Likewise.
8025
8026 2008-04-07 Robert Millan <rmh@aybabtu.com>
8027
8028 * util/grub-probe.c (probe): Improve error message.
8029
8030 2008-04-07 Robert Millan <rmh@aybabtu.com>
8031
8032 * util/biosdisk.c (read_device_map): Skip devices that don't exist
8033 (this prevents the presence of a bogus entry from ruining the whole
8034 thing).
8035
8036 2008-04-06 Pavel Roskin <proski@gnu.org>
8037
8038 * util/biosdisk.c: Include grub/util/biosdisk.h.
8039 * util/grub-fstest.c (execute_command): Make static.
8040 * util/grub-mkdevicemap.c (check_device): Likewise.
8041 * util/i386/pc/misc.c: Include grub/machine/init.h.
8042 * util/powerpc/ieee1275/misc.c: Likewise.
8043 * util/lvm.c: Include grub/util/lvm.h.
8044 * util/misc.c: Include grub/kernel.h, grub/misc.h and
8045 grub/cache.h.
8046 * util/raid.c: Include grub/util/raid.h.
8047 (grub_util_getdiskname): Make static.
8048
8049 * util/grub-emu.c (main): Remove calls to grub_hostfs_init() and
8050 grub_hostfs_fini(), as they are called from grub_init_all() and
8051 grub_fini_all() respectively. This fixes an infinite loop in
8052 grub-fstest due to double registration of hostfs.
8053 Reported by Christian Franke <Christian.Franke@t-online.de>
8054
8055 2008-04-05 Pavel Roskin <proski@gnu.org>
8056
8057 * bus/pci.c (grub_pci_iterate): For multifunction devices, probe
8058 all 8 functions. Otherwise, probe function 0 only.
8059
8060 2008-04-04 Pavel Roskin <proski@gnu.org>
8061
8062 * commands/lspci.c (grub_lspci_iter): Print the bus number
8063 correctly.
8064
8065 * commands/lspci.c (grub_pci_classes): Fix typos.
8066 (grub_lspci_iter): Don't print func twice. Print vendor ID
8067 before device ID, as it's normally done.
8068
8069 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
8070 Fix signedness warnings.
8071 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate):
8072 Likewise.
8073 * util/ieee1275/get_disk_name.c: Include config.h so that
8074 _GNU_SOURCE is defined and getline() is declared. Mark an
8075 unused argument as such. Fix a signedness warning.
8076
8077 2008-04-02 Pavel Roskin <proski@gnu.org>
8078
8079 * genkernsyms.sh.in: Use more robust assignments for CC and
8080 srcdir. Quote srcdir.
8081 * gensymlist.sh.in: Likewise. Assert at the compile time that
8082 the symbol table is not empty.
8083
8084 * disk/raid.c (grub_raid_memberlist): Fix a signedness warning.
8085 * fs/cpio.c (grub_cpio_read): Likewise.
8086
8087 2008-04-01 Pavel Roskin <proski@gnu.org>
8088
8089 * disk/ata.c (grub_ata_open): Don't lose precision in disk->id.
8090 * disk/host.c (grub_host_open): Likewise.
8091 * disk/loopback.c (grub_loopback_open): Likewise.
8092 * disk/memdisk.c (grub_memdisk_open): Use a string pointer for
8093 disk->id as in disk/host.c, not a multi-character constant.
8094
8095 * util/grub-fstest.c (cmd_cmp): Use fseeko(), not fseek(). The
8096 later is obsolete, potentially dangerous and sets a bad example.
8097 * util/i386/efi/grub-mkimage.c (make_header): Likewise.
8098 * util/misc.c (grub_util_get_image_size): Likewise.
8099
8100 * disk/loopback.c (options): Improve help for "--partitions".
8101
8102 * normal/arg.c (grub_arg_show_help): Fix spacing of the long
8103 options to align them with the short options, e.g. "echo -e".
8104
8105 2008-03-31 Bean <bean123ch@gmail.com>
8106
8107 * video/reader/png.c (grub_png_data): New member is_16bit and
8108 image_data.
8109 (grub_png_decode_image_header): Detect 16 bit png image.
8110 (grub_png_convert_image): New function to convert 16 bit image to 8 bit.
8111 (grub_png_decode_png): Call grub_png_convert_image for 16 bit image.
8112 (grub_video_reader_png): Release memory occupied by image_data.
8113
8114 * fs/ntfs.c (find_attr): Handle non-resident attribute list larger than
8115 4096 bytes.
8116 (grub_nfs_mount): Skip the test for sector per cluster.
8117
8118 * include/grub/ntfs.h (MAX_SPC): Removed.
8119
8120 2008-03-31 Bean <bean123ch@gmail.com>
8121
8122 * conf/common.rmk (pkgdata_MODULES): Add afs.mod.
8123 (grub_probe_SOURCES): Add fs/afs.c.
8124 (grub_fstest_SOURCES): Likewise.
8125 (afs_mod_SOURCES): New variable.
8126 (afs_mod_CFLAGS): Likewise.
8127 (afs_mod_LDFLAGS): Likewise.
8128
8129 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/afs.c.
8130 (grub_emu_SOURCES): Likewise.
8131
8132 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
8133
8134 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8135
8136 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
8137
8138 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8139
8140 * fs/afs.c: New file.
8141
8142 2008-03-30 Pavel Roskin <proski@gnu.org>
8143
8144 * disk/host.c: Include grub/misc.h to fix a warning.
8145 * util/hostfs.c: Use GRUB_MOD_INIT and GRUB_MOD_FINI to fix
8146 warnings about implicit declarations.
8147
8148 * fs/udf.c (grub_udf_mount): Fix warning about a shadowing a
8149 variable.
8150 * include/grub/i386/loader.h: Change declaration of
8151 grub_linux_boot() to match what grub_loader_set() expects.
8152 * util/getroot.c (grub_guess_root_device): Return const char* to
8153 fix a warning.
8154 * util/grub-probe.c (probe): Fix a warning about uninitialized
8155 abstraction_name variable.
8156 * util/i386/get_disk_name.c (grub_util_get_disk_name): Mark
8157 second argument as unused to fix a warning.
8158
8159 * loader/i386/pc/multiboot2.c (grub_mb2_arch_elf64_hook): Add
8160 missing grub_error() call.
8161
8162 * util/update-grub_lib.in: Define datarootdir, since Autoconf
8163 2.60 and newer uses it to define datadir.
8164
8165 * commands/sleep.c: Fix warning about implicit declaration.
8166 * disk/memdisk.c: Likewise.
8167 * loader/aout.c: Likewise.
8168 * loader/i386/bsd_normal.c: Likewise.
8169 * util/grub-probe.c: Likewise.
8170
8171 * commands/i386/cpuid.c (has_longmode): Make static.
8172 * disk/i386/pc/biosdisk.c (cd_drive): Likewise.
8173 * include/grub/i386/bsd.h (bios_memmap_t): Remove, it's unused.
8174
8175 * kern/i386/pc/startup.S (real_to_prot): Use %cs prefix to load
8176 GDT. This is more robust, as %ds can change.
8177 (grub_biosdisk_rw_int13_extensions): Don't clear %ds before
8178 calling real_to_prot().
8179 (grub_biosdisk_get_diskinfo_int13_extensions): Likewise.
8180
8181 2008-03-28 Pavel Roskin <proski@gnu.org>
8182
8183 * kern/i386/pc/startup.S: Assert that uncompressed functions
8184 don't spill beyond GRUB_KERNEL_MACHINE_RAW_SIZE.
8185 * kern/i386/pc/lzo1x.S: Remove all .align directives in the
8186 code, as they push parts of the code (error handlers) beyond
8187 GRUB_KERNEL_MACHINE_RAW_SIZE. Speed is not as important in this
8188 code as correctness and size.
8189
8190 2008-03-28 Pavel Roskin <proski@gnu.org>
8191
8192 * kern/i386/pc/startup.S
8193 (grub_biosdisk_get_diskinfo_int13_extensions): When converting
8194 data block address to the real mode, keep offset minimal. This
8195 works around a bug in AWARD BIOS on old Athlon systems, which
8196 makes CD detection hang.
8197
8198 2008-03-26 Pavel Roskin <proski@gnu.org>
8199
8200 * normal/color.c (grub_parse_color_name_pair): Make `name' a
8201 const.
8202 * include/grub/normal.h: Add grub_parse_color_name_pair()
8203 declaration.
8204
8205 2008-03-24 Bean <bean123ch@gmail.com>
8206
8207 * disk/i386/pc/biosdisk.c (cd_start): Removed.
8208 (cd_count): Removed.
8209 (cd_drive): New variable.
8210 (grub_biosdisk_get_drive): Don't check for (cdN) device.
8211 (grub_biosdisk_call_hook): Likewise.
8212 (grub_biosdisk_iterate): Change cdrom detection method.
8213 (grub_biosdisk_open): Replace cd_start with cd_drive.
8214 (GRUB_MOD_INIT): Use grub_biosdisk_get_cdinfo_int13_extension to
8215 detect cdrom device.
8216
8217 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_MACHINE_CDROM_START):
8218 Removed.
8219 (GRUB_BIOSDISK_MACHINE_CDROM_END): Removed.
8220 (GRUB_BIOSDISK_CDTYPE_NO_EMUL): New macro.
8221 (GRUB_BIOSDISK_CDTYPE_1_2_M): Likewise.
8222 (GRUB_BIOSDISK_CDTYPE_1_44_M): Likewise.
8223 (GRUB_BIOSDISK_CDTYPE_2_88_M): Likewise.
8224 (GRUB_BIOSDISK_CDTYPE_HARDDISK): Likewise.
8225 (GRUB_BIOSDISK_CDTYPE_MASK): Likewise.
8226 (grub_biosdisk_cdrp): New structure.
8227 (grub_biosdisk_get_cdinfo_int13_extensions): New function.
8228
8229 * include/grub/i386/pc/kernel.h (grub_boot_drive): Export this variable.
8230
8231 * kern/i386/pc/init.c (make_install_device): Don't use (cdN) as root
8232 device.
8233
8234 * kern/i386/pc/startup.S (grub_biosdisk_get_cdinfo_int13_extensions):
8235 New function.
8236
8237 2008-03-20 Robert Millan <rmh@aybabtu.com>
8238
8239 Remove 2 TiB limit in ata.mod.
8240 * disk/ata.c (grub_ata_device): Promote `size' to grub_uint64_t.
8241 (grub_ata_dumpinfo): Print sector count with 0x%llx.
8242 (grub_ata_identify): Interpret `&info16[100]' as a pointer to
8243 grub_uint64_t instead of grub_uint32_t.
8244
8245 2008-03-05 Bean <bean123ch@gmail.com>
8246
8247 * loader/i386/pc/multiboot.c (grub_multiboot_get_bootdev): New function.
8248 (grub_multiboot): Set boot device.
8249
8250 * boot/i386/pc/lnxboot.S (real_code_2): Set %dh to 0xFF.
8251
8252 2008-03-02 Bean <bean123ch@gmail.com>
8253
8254 * fs/reiserfs.c (grub_reiserfs_read_symlink): Add 0 at the end of
8255 symlink_buffer.
8256
8257 2008-03-01 Yoshinori K. Okuji <okuji@enbug.org>
8258
8259 * DISTLIST: Added docs/fdl.texi, docs/grub.texi, docs/mdate-sh and
8260 texinfo.tex.
8261
8262 * docs/grub.texi: New file. Copied from GRUB Legacy, and slightly
8263 modified.
8264
8265 * docs/fdl.texi: New file.
8266
8267 * docs/mdate-sh: New file. Copied from gnulib.
8268 * docs/texinfo.tex: Likewise.
8269
8270 * config.guess: Updated from gnulib.
8271 * install-sh: Likewise.
8272
8273 2008-02-28 Robert Millan <rmh@aybabtu.com>
8274
8275 * conf/i386-linuxbios.rmk (pkglib_MODULES): Add aout.mod.
8276 (aout_mod_SOURCES): New variable.
8277 (aout_mod_CFLAGS): Likewise.
8278 (aout_mod_LDFLAGS): Likewise.
8279
8280 * conf/i386-ieee1275.rmk: Likewise.
8281
8282 2008-02-28 Robert Millan <rmh@aybabtu.com>
8283
8284 * util/update-grub.in: Reorganise terminal validity check. Accept
8285 `ieee1275:console' (OLPC) and `*:gfxterm' as valid too.
8286 Based on suggestion by Franklin PIAT.
8287
8288 2008-02-28 Fabian Greffrath <greffrath@leat.rub.de>
8289
8290 * include/grub/util/getroot.h (grub_util_check_block_device): Export new
8291 function.
8292 * util/getroot.c (grub_util_check_block_device): New function that
8293 returns the given argument if it is a block device and returns NULL else.
8294 * util/grub-probe.c (argument_is_device): New variable.
8295 (probe): Promote device_name from a variable to an argument. Receive
8296 device_name from grub_util_check_block_device() if path is NULL and from
8297 grub_guess_root_device() else. Do not free() device_name anymore.
8298 (options): Introduce new parameter '-d, --device'.
8299 (main): Add description of the new parameter to the help screen.
8300 Rename path variable to argument. Set argument_is_device if the '-d'
8301 option is given. Pass argument to probe() depending on
8302 argument_is_device.
8303
8304 2008-02-24 Bean <bean123ch@gmail.com>
8305
8306 * fs/iso9660.c (GRUB_ISO9660_VOLDESC_BOOT): New macro.
8307 (GRUB_ISO9660_VOLDESC_PRIMARY): Likewise.
8308 (GRUB_ISO9660_VOLDESC_SUPP): Likewise.
8309 (GRUB_ISO9660_VOLDESC_PART): Likewise.
8310 (GRUB_ISO9660_VOLDESC_END): Likewise.
8311 (grub_iso9660_primary_voldesc): New member escape.
8312 (grub_iso9660_data): New member joliet.
8313 (grub_iso9660_convert_string): New function.
8314 (grub_iso9660_mount): Detect joliet extension.
8315 (grub_iso9660_iterate_dir): Convert filename when joliet is detected.
8316 (grub_iso9660_iso9660_label): Likewise.
8317
8318 * conf/common.rmk (pkgdata_MODULES): Add udf.mod.
8319 (grub_setup_SOURCES): Add fs/udf.c.
8320 (grub_fstest_SOURCES): Likewise.
8321 (udf_mod_SOURCES): New variable.
8322 (udf_mod_CFLAGS): Likewise.
8323 (udf_mod_LDFLAGS): Likewise.
8324
8325 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/udf.c.
8326 (grub_emu_SOURCES): Likewise.
8327
8328 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
8329
8330 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8331
8332 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
8333
8334 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8335
8336 * fs/udf.c: New file.
8337
8338 2008-02-24 Robert Millan <rmh@aybabtu.com>
8339
8340 * conf/i386-efi.rmk (normal/function.c_DEPENDENCIES)
8341 (normal/lexer.c_DEPENDENCIES): New variables.
8342 * conf/i386-ieee1275.rmk (normal/function.c_DEPENDENCIES)
8343 (normal/lexer.c_DEPENDENCIES): Likewise.
8344 * conf/i386-linuxbios.rmk (normal/function.c_DEPENDENCIES)
8345 (normal/lexer.c_DEPENDENCIES): Likewise.
8346 * conf/i386-pc.rmk (normal/function.c_DEPENDENCIES)
8347 (normal/lexer.c_DEPENDENCIES): Likewise.
8348 * conf/powerpc-ieee1275.rmk (normal/function.c_DEPENDENCIES)
8349 (normal/lexer.c_DEPENDENCIES): Likewise.
8350 * conf/sparc64-ieee1275.rmk (normal/function.c_DEPENDENCIES)
8351 (normal/lexer.c_DEPENDENCIES): Likewise.
8352
8353 2008-02-23 Robert Millan <rmh@aybabtu.com>
8354
8355 * partmap/gpt.c (grub_gpt_magic): Add `0x' qualifier to each member,
8356 since they were intended to be in hex. This didn't break previously
8357 because of a bug in gpt_partition_map_iterate() (see below).
8358
8359 (gpt_partition_map_iterate): Replace `grub_memcmp' with `! grub_memcmp'
8360 when checking the validity of GPT header.
8361 Remove `partno', since it always provides the same information as `i'.
8362
8363 2008-02-21 Yoshinori K. Okuji <okuji@enbug.org>
8364
8365 * include/grub/efi/time.h: Fix a wrong comment.
8366
8367 2008-02-19 Pavel Roskin <proski@gnu.org>
8368
8369 * kern/rescue.c (grub_enter_rescue_mode): Improve initial
8370 message.
8371
8372 2008-02-19 Bean <bean123ch@gmail.com>
8373
8374 * conf/i386-pc.rmk (pkglib_MODULES): Add aout.mod _bsd.mod and bsd.mod.
8375 (aout_mod_SOURCES): New variable.
8376 (aout_mod_CFLAGS): Likewise.
8377 (aout_mod_LDFLAGS): Likewise.
8378 (_bsd_mod_SOURCES): New variable.
8379 (_bsd_mod_CFLAGS): Likewise.
8380 (_bsd_mod_LDFLAGS): Likewise.
8381 (bsd_mod_SOURCES): New variable.
8382 (bsd_mod_CFLAGS): Likewise.
8383 (bsd_mod_LDFLAGS): Likewise.
8384
8385 * include/grub/aout.h: New file.
8386
8387 * include/grub/i386/loader.h (grub_unix_real_boot): New function.
8388
8389 * include/grub/i386/bsd.h: New file.
8390
8391 * include/grub/i386/pc/init.h (grub_get_mmap_entry): Use EXPORT_FUNC
8392 to make it public.
8393
8394 * kern/elf.c (grub_elf32_load): Get the physical address after the hook
8395 function is called, so that it's possible to change it inside the hook.
8396 (grub_elf64_load): Likewise.
8397 (grub_elf_file): Don't close the file if elf header is not found.
8398 (grub_elf_close): Close the file if grub_elf_file fails (The new
8399 grub_elf_file won't close it).
8400 (grub_elf32_size): Use NESTED_FUNC_ATTR for nested function calcsize.
8401 (grub_elf64_size): Likewise.
8402
8403 * kern/i386/loader.S (grub_unix_real_boot): New function.
8404
8405 * loader/aout.c: New file.
8406
8407 * loader/i386/bsd.c: New file.
8408
8409 * loader/i386/bsd_normal.c: New file.
8410
8411 * loader/i386/pc/multiboot.c (grub_multiboot): Handle a.out format.
8412
8413 * loader/multiboot2.c (grub_multiboot2): Reset grub_errno so that it
8414 can test other formats.
8415
8416 2008-02-19 Robert Millan <rmh@aybabtu.com>
8417
8418 * partmap/gpt.c: Include `<grub/gpt_partition.h>'.
8419 (grub_gpt_partition_type_empty): Redefine with macro from
8420 `<grub/gpt_partition.h>'.
8421 (gpt_partition_map_iterate): Adjust partition type comparison.
8422
8423 Export `entry' as partmap-specific `part.data' struct.
8424 (grub_gpt_header, grub_gpt_partentry): Move from here ...
8425
8426 * include/grub/gpt_partition.h (grub_gpt_header)
8427 (grub_gpt_partentry): ... to here (new file).
8428
8429 * util/i386/pc/grub-setup.c: Include `<grub/gpt_partition.h>'.
8430
8431 (grub_gpt_partition_type_bios_boot): New const variable, defined
8432 with macro from `<grub/gpt_partition.h>'.
8433
8434 (setup): Replace `first_start' with `embed_region', which keeps
8435 track of the embed region (and is partmap-agnostic).
8436
8437 Replace find_first_partition_start() with find_usable_region(),
8438 which finds a usable region for embedding using partmap-specific
8439 knowledge (supports PC/MSDOS and GPT).
8440
8441 Fix all assumptions that the embed region start at sector 1, using
8442 `embed_region.start' from now on. Similarly, use `embed_region.end'
8443 rather than `first_start' to calculate available size.
8444
8445 In grub_util_info() message, replace "into after the MBR" with an
8446 indication of the specific sector our embed region starts at.
8447
8448 2008-02-19 Robert Millan <rmh@aybabtu.com>
8449
8450 * DISTLIST: Replace `commands/ieee1275/halt.c' and
8451 `commands/ieee1275/reboot.c' with `commands/halt.c' and
8452 `commands/reboot.c'.
8453 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
8454 (halt_mod_SOURCES): Likewise.
8455 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
8456 (halt_mod_SOURCES): Likewise.
8457
8458 2008-02-17 Christian Franke <franke@computer.org>
8459
8460 * commands/cat.c (grub_cmd_cat): Add break on GRUB_TERM_ESC key.
8461
8462 2008-02-17 Robert Millan <rmh@aybabtu.com>
8463
8464 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
8465 set `first_start' to 0 for non-PC/MSDOS partition maps.
8466
8467 2008-02-16 Robert Millan <rmh@aybabtu.com>
8468
8469 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
8470 do not assume partition map is PC/MSDOS before performing checks that
8471 are specific to that layout.
8472
8473 2008-02-13 Robert Millan <rmh@aybabtu.com>
8474
8475 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Remove
8476 `commands/i386/pc/halt.c' and `commands/i386/pc/reboot.c'.
8477 * kern/i386/linuxbios/init.c (grub_halt, grub_reboot): Remove stubs.
8478
8479 2008-02-13 Yoshinori K. Okuji <okuji@enbug.org>
8480
8481 * configure.ac: Only a cosmetic change on the handling of
8482 -fno-stack-protector.
8483
8484 2008-02-12 Alexandre Boeglin <alex@boeglin.org>
8485
8486 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace
8487 commands/i386/pc/halt.c and reboot.c by commands/halt.c and
8488 reboot.c.
8489 (grub_install_SOURCES): Add halt.mod and reboot.mod.
8490 (halt_mod_SOURCES): New variable.
8491 (halt_mod_CFLAGS): Likewise.
8492 (halt_mod_LDFLAGS): Likewise.
8493 (reboot_mod_SOURCES): Likewise.
8494 (reboot_mod_CFLAGS): Likewise.
8495 (reboot_mod_LDFLAGS): Likewise.
8496
8497 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace
8498 commands/ieee1275/halt.c and reboot.c by commands/halt.c and
8499 reboot.c.
8500 (halt_mod_SOURCES): Likewise.
8501 (reboot_mod_SOURCES): Likewise.
8502
8503 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace
8504 commands/i386/pc/reboot.c by commands/reboot.c.
8505 (reboot_mod_SOURCES): Likewise.
8506
8507 * commands/i386/pc/reboot.c: merge this file ...
8508
8509 * commands/ieee1275/reboot.c: ... and this file ...
8510
8511 * commands/reboot.c: ... to this file.
8512 Add some precompiler directive to include the correct header for
8513 each machine.
8514
8515 * commands/ieee1275/halt.c: move this file ...
8516
8517 * commands/halt.c: ... to here.
8518 Add some precompiler directive to include the correct header for
8519 each machine.
8520
8521 * include/grub/efi/efi.h (grub_reboot): New function declaration.
8522 (grub_halt): Likewise.
8523
8524 * kern/efi/efi.c (grub_reboot): New function.
8525 (grub_halt): Likewise.
8526
8527 2008-02-12 Robert Millan <rmh@aybabtu.com>
8528
8529 * util/getroot.c (grub_guess_root_device): Inspect /dev/evms before
8530 /dev (like it is done for /dev/mapper). This doesn't provide support
8531 for EVMS, but at least it is now easy to identify the problem when it
8532 arises.
8533
8534 2008-02-11 Robert Millan <rmh@aybabtu.com>
8535
8536 * util/biosdisk.c (grub_util_biosdisk_open, linux_find_partition)
8537 (grub_util_biosdisk_get_grub_dev): Check open() exit status by
8538 comparing it with -1, not 0.
8539
8540 2008-02-10 Robert Millan <rmh@aybabtu.com>
8541
8542 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `disk/raid.c' and
8543 `disk/lvm.c'.
8544 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8545 * conf/i386-pc.rmk (grub_setup_SOURCES): Likewise.
8546
8547 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Move `disk/raid.c' and
8548 `disk/lvm.c' to the end of the list.
8549 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
8550 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
8551
8552 2008-02-10 Robert Millan <rmh@aybabtu.com>
8553
8554 * kern/main.c (grub_load_normal_mode): Do not reset `grub_errno'. Call
8555 grub_print_error() instead. This will let user know why we're entering
8556 rescue mode.
8557 Based on suggestions from Sam Morris.
8558
8559 2008-02-10 Alexandre Boeglin <alex@boeglin.org>
8560
8561 * normal/arg.c (grub_arg_parse): If one of the args is "--", call add_arg()
8562 on remaining N args, instead of "--" arg N times.
8563
8564 2008-02-09 Vesa Jaaskelainen <chaac@nic.fi>
8565
8566 * font/manager.c (unknown_glyph): Added variable for unknown glyph.
8567 (fill_with_default_glyph): Changed to use unknown_glyph for fill
8568 pattern for unknown glyphs.
8569
8570 2008-02-09 Robert Millan <rmh@aybabtu.com>
8571
8572 * configure.ac: Probe for `help2man'.
8573 * Makefile.in (builddir): New variable.
8574 (HELP2MAN): Likewise. Set to `true' when @HELP2MAN@ doesn't provide it,
8575 or otherwise add a few flags/options to it.
8576 (install-local): For every executable utility or script that is
8577 installed, invoke $(HELP2MAN) to install a manpage based on --help
8578 output.
8579
8580 * util/i386/pc/grub-install.in: Move down `update-grub_lib' sourcing, so
8581 that it doesn't prevent --help from working in build tree.
8582
8583 * util/i386/pc/grub-mkrescue.in (usage): Replace `grub-devel@gnu.org'
8584 with `bug-grub@gnu.org'.
8585 * util/powerpc/ieee1275/grub-mkrescue.in (usage): Likewise.
8586 * util/update-grub.in (usage): New function.
8587 Implement proper argument check, with support for --help and --version
8588 (as well as existing -y).
8589
8590 2008-02-09 Christian Franke <franke@computer.org>
8591
8592 * commands/cat.c (grub_cmd_cat): Print '\r' as hex to
8593 avoid overwriting previous output.
8594 * kern/rescue.c (grub_rescue_cmd_cat): Likewise.
8595
8596 2008-02-09 Robert Millan <rmh@aybabtu.com>
8597
8598 * normal/menu.c (run_menu): If timeout is set to zero, don't bother
8599 drawing the menu.
8600
8601 2008-02-09 Robert Millan <rmh@aybabtu.com>
8602
8603 * commands/sleep.c: New file.
8604 * conf/common.rmk (pkglib_MODULES): Add `commands/sleep.c'.
8605 (sleep_mod_SOURCES): New variable.
8606 (sleep_mod_CFLAGS): Likewise.
8607 (sleep_mod_LDFLAGS): Likewise.
8608
8609 2008-02-09 Robert Millan <rmh@aybabtu.com>
8610
8611 * disk/raid.c (grub_raid_scan_device): Add a pair of sanity checks for
8612 situations in which we can deduce the RAID size and the superblock
8613 doesn't match it.
8614
8615 2008-02-09 Robert Millan <rmh@aybabtu.com>
8616
8617 * disk/lvm.c [GRUB_UTIL] (grub_lvm_memberlist): New function. Construct
8618 and return a grub_diskmemberlist_t composed of LVM physical volumes.
8619 [GRUB_UTIL] (grub_lvm_dev): Add `memberlist' member.
8620
8621 * disk/raid.c [GRUB_UTIL] (grub_raid_memberlist): New function. Construct
8622 and return a grub_diskmemberlist_t composed of physical array members.
8623 [GRUB_UTIL] (grub_raid_dev): Add `memberlist' member.
8624
8625 * include/grub/disk.h [GRUB_UTIL] (grub_disk_memberlist): New struct
8626 prototype.
8627 [GRUB_UTIL] (struct grub_disk_dev): Add `memberlist' function pointer.
8628 [GRUB_UTIL] (struct grub_disk_memberlist): New struct declaration.
8629 [GRUB_UTIL] (grub_disk_memberlist_t): New typedef.
8630
8631 * util/grub-probe.c (probe): Move partmap probing code from here ...
8632 (probe_partmap): ... to here.
8633 (probe): Use probe_partmap() once for the disk we're probing, and
8634 additionally, when such disk contains a memberlist() struct member,
8635 once for each disk that is contained in the structure returned by
8636 memberlist().
8637
8638 2008-02-09 Robert Millan <rmh@aybabtu.com>
8639
8640 * util/grub-probe.c (main): When `verbosity > 1', set `debug'
8641 environment variable to 'all' in order to obtain debug output from
8642 non-util/ code.
8643 * util/i386/pc/grub-setup.c (main): Likewise.
8644
8645 2008-02-08 Robert Millan <rmh@aybabtu.com>
8646
8647 * disk/raid.c (grub_raid_scan_device): Check for
8648 `array->device[sb.this_disk.number]' rather than for
8649 `array->device[sb.this_disk.number]->name', since the latter is not
8650 guaranteed to be accessible.
8651
8652 2008-02-08 Robert Millan <rmh@aybabtu.com>
8653
8654 * disk/raid.c: Update copyright.
8655 * fs/cpio.c: Likewise.
8656 * include/grub/raid.h: Likewise.
8657 * loader/i386/pc/multiboot.c: Likewise.
8658 * util/hostfs.c: Likewise.
8659
8660 2008-02-08 Robert Millan <rmh@aybabtu.com>
8661
8662 * include/grub/raid.h (struct grub_raid_array): Change type of `device'
8663 to a grub_disk_t array.
8664 * disk/raid.c (grub_raid_read): Replace `device[x].disk' accesses with
8665 `device[x]'.
8666 (grub_raid_scan_device): Replace `device[x].name' accesses with
8667 `device[x]->name'. Simplify initialization of `array->device[x]'.
8668
8669 2008-02-08 Robert Millan <rmh@aybabtu.com>
8670
8671 * disk/raid.c (grub_raid_open, grub_raid_scan_device): Add a few
8672 grub_dprintf() calls.
8673 * kern/disk.c (grub_disk_read): Include grub_errmsg in out of range
8674 error message.
8675
8676 2008-02-07 Christian Franke <franke@computer.org>
8677
8678 * util/hostfs.c (grub_hostfs_open): Use fseeko and ftello
8679 instead of fseek and ftell to support large files.
8680 (grub_hostfs_read): Likewise.
8681
8682 2008-02-07 Robert Millan <rmh@aybabtu.com>
8683
8684 Patch from Jeroen Dekkers.
8685 * disk/raid.c (grub_raid_scan_device): Reset `grub_errno' on disk
8686 failure, since successfully reading all array members might not be
8687 required.
8688
8689 2008-02-06 Robert Millan <rmh@aybabtu.com>
8690
8691 * util/grub-probe.c (probe): Simplify partmap probing (with the
8692 assumption that the first word up to the underscore equals to
8693 the module name).
8694
8695 2008-02-06 Christian Franke <franke@computer.org>
8696
8697 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_NONE
8698 (and set *ofs = 0) instead of GRUB_ERR_FILE_NOT_FOUND on
8699 last block of a cpio or tar stream.
8700 Check for "TRAILER!!!" instead of any empty data
8701 block to detect last block of a cpio stream.
8702 (grub_cpio_dir): Fix constness of variable np.
8703 (grub_cpio_open): Return GRUB_ERR_FILE_NOT_FOUND if
8704 cpio or tar trailer is detected. This fixes a crash
8705 on open of a non existing file.
8706
8707 2008-02-05 Bean <bean123ch@gmail.com>
8708
8709 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Get physical
8710 address of entry.
8711 (grub_multiboot_load_elf64): Likewise.
8712 (grub_multiboot): Initialize mbi structure.
8713
8714 * util/grub-fstest.c: Don't include unused header file script.h.
8715
8716 * conf/common.rmk (grub-fstest.c_DEPENDENCIES): Move to the beginning
8717 of file.
8718 (grub_fstest_SOURCES): Likewise.
8719
8720 2008-02-05 Robert Millan <rmh@aybabtu.com>
8721
8722 * include/grub/term.h (GRUB_TERM_LEFT, GRUB_TERM_RIGHT)
8723 (GRUB_TERM_UP, GRUB_TERM_DOWN, GRUB_TERM_HOME, GRUB_TERM_END)
8724 (GRUB_TERM_DC, GRUB_TERM_PPAGE, GRUB_TERM_NPAGE, GRUB_TERM_ESC)
8725 (GRUB_TERM_TAB, GRUB_TERM_BACKSPACE): New macros.
8726
8727 * kern/i386/pc/startup.S: Include `<grub/term.h>'.
8728 (translation_table): Replace hardcoded values with macros
8729 provided by `<grub/term.h>'.
8730
8731 * term/i386/pc/at_keyboard.c: Include `<grub/term.h>'.
8732 (keyboard_map): Correct/add a few values, with macros provided
8733 by `<grub/term.h>'.
8734 (keyboard_map_shift): Zero values that don't differ from their
8735 `keyboard_map' equivalents.
8736 (grub_console_checkkey): Optimize KEYBOARD_STATUS_CAPS_LOCK toggling.
8737 Discard the second scan code that is always sent by Caps lock.
8738 Only use `keyboard_map_shift' when it provides a non-zero value,
8739 otherwise fallback to `keyboard_map'.
8740
8741 2008-02-04 Bean <bean123ch@gmail.com>
8742
8743 * Makefile.in (enable_grub_fstest): New variable.
8744
8745 * conf/common.rmk (grub_fstest_init.lst): New rule.
8746 (grub_fstest_init.h): Likewise.
8747 (grub_fstest_init.c): Likewise.
8748 (util/grub-fstest.c_DEPENDENCIES): New variable.
8749 (grub_fstest_SOURCES): Likewise.
8750
8751 * configure.ac (enable_grub_fstest): Check for --enable-grub-fstest.
8752
8753 * util/grub-fstest.c: New file.
8754
8755 2008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
8756
8757 Make grub-setup handle a separate root device.
8758
8759 * util/i386/pc/grub-setup.c (setup): Always open the root device,
8760 so that the root device can be compared with the destination
8761 device.
8762 When embedding the core image, if the root and destination devices
8763 are different, set ROOT_DRIVE to ROOT_DEV->DISK->ID. Otherwise, to
8764 0xFF.
8765 When not embedding, set ROOT_DRIVE to 0xFF.
8766
8767 2008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
8768
8769 Add support for having a grub directory in a different drive. This
8770 is still only the data handling part.
8771
8772 * kern/i386/pc/startup.S (multiboot_trampoline): Set %dh to 0xFF.
8773 (codestart): Save %dh in GRUB_ROOT_DRIVE.
8774 (grub_root_drive): New variable.
8775
8776 * kern/i386/pc/init.c (make_install_device): Use GRUB_ROOT_DRIVE
8777 instead of GRUB_BOOT_DRIVE to construct a device name. Set
8778 GRUB_ROOT_DRIVE to GRUB_BOOT_DRIVE if it is 0xFF, otherwise use it
8779 as it was.
8780
8781 * include/grub/i386/pc/kernel.h (grub_root_drive): New prototype.
8782
8783 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_ROOT_DRIVE): New
8784 macro.
8785 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Set to 0x4f.
8786
8787 * boot/i386/pc/pxeboot.S (_start): Set %dh to 0xFF. For now, this
8788 is bogus, because PXE booting does not specify any drive
8789 correctly.
8790
8791 * boot/i386/pc/lnxboot.S (reg_edx): Set the second byte to 0xFF. I
8792 am not sure if this is really correct.
8793
8794 * boot/i386/pc/cdboot.S: Set %dh to 0xFF, because the root drive
8795 is always identical to the boot drive when booting from a CD.
8796
8797 * boot/i386/pc/boot.S (MOV_MEM_TO_AL): Removed. Not needed any
8798 longer.
8799 (root_drive): New variable.
8800 (real_start): Unconditionally set %dh to ROOT_DRIVE.
8801 (setup_sectors): Push %dx right after popping it, because %dh will
8802 be modified later.
8803 (copy_buffer): Restore %dx.
8804
8805 2008-02-03 Robert Millan <rmh@aybabtu.com>
8806
8807 * util/i386/pc/grub-mkrescue.in: Rewrite most of image generation to
8808 use `cdboot.img' for cdrom images.
8809
8810 2008-02-03 Robert Millan <rmh@aybabtu.com>
8811
8812 * util/grub.d/00_header.in: Issue scripting commands for GRUB to
8813 only setup gfxterm when `font' command has succeeded.
8814
8815 2008-02-03 Robert Millan <rmh@aybabtu.com>
8816
8817 * loader/multiboot_loader.c [GRUB_MACHINE_LINUXBIOS]
8818 (grub_rescue_cmd_multiboot_loader)
8819 (grub_rescue_cmd_module_loader): Enable multiboot1 calls.
8820
8821 2008-02-03 Pavel Roskin <proski@gnu.org>
8822
8823 * kern/i386/pc/startup.S (grub_chainloader_real_boot): Pop
8824 %edx and %esi from stack only after grub_gate_a20() is called.
8825 grub_gate_a20() clobbers %edx.
8826
8827 2008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
8828
8829 * configure.ac (AC_INIT): Bumped to 1.96.
8830
8831 * DISTLIST: Added boot/i386/pc/cdboot.S, bus/pci.c,
8832 commands/lspci.c,disk/memdisk.c, include/grub/pci.h,
8833 include/grub/i386/pc/pci.h, video/readers/jpeg.c, and
8834 video/readers/png.c.
8835
8836 2008-02-03 Bean <bean123ch@gmail.com>
8837
8838 * conf/i386-pc.rmk (pkglib_IMAGES): Add cdboot.img.
8839 (cdboot_img_SOURCES): New variable.
8840 (cdboot_img_ASFLAGS): New variable.
8841 (cdboot_img_LDFLAGS): New variable.
8842
8843 * boot/i386/pc/cdboot.S: New file.
8844
8845 * disk/i386/pc/biosdisk.c (cd_start): New variable.
8846 (cd_count): Likewise.
8847 (grub_biosdisk_get_drive): Add support for cd device.
8848 (grub_biosdisk_call_hook): Likewise.
8849 (grub_biosdisk_iterate): Likewise.
8850 (grub_biosdisk_open): Likewise.
8851 (GRUB_BIOSDISK_CDROM_RETRY_COUNT): New macro.
8852 (grub_biosdisk_rw): Support reading from cd device.
8853 (GRUB_MOD_INIT): Iterate cd devices.
8854
8855 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_FLAG_CDROM): New macro.
8856 (GRUB_BIOSDISK_MACHINE_CDROM_START): Likewise.
8857 (GRUB_BIOSDISK_MACHINE_CDROM_END): Likewise.
8858
8859 * kern/i386/pc/init.c (make_install_device): Check for cd device.
8860
8861 2008-02-02 Robert Millan <rmh@aybabtu.com>
8862
8863 * commands/read.c: New file.
8864 * conf/common.rmk (pkglib_MODULES): Add `commands/read.c'.
8865 (read_mod_SOURCES): New variable.
8866 (read_mod_CFLAGS): Likewise.
8867 (read_mod_LDFLAGS): Likewise.
8868
8869 2008-02-02 Robert Millan <rmh@aybabtu.com>
8870
8871 * normal/main.c (grub_normal_execute): Check for `menu->size' when
8872 determining whether menu has to be displayed.
8873
8874 2008-02-02 Marco Gerards <marco@gnu.org>
8875
8876 * bus/pci.c: New file.
8877
8878 * include/grub/pci.h: Likewise.
8879
8880 * include/grub/i386/pc/pci.h: Likewise.
8881
8882 * commands/lspci.c: Likewise.
8883
8884 * conf/i386-pc.rmk (pkglib_MODULES): Add `pci.mod' and
8885 `lspci.mod'.
8886 (pci_mod_SOURCES): New variable.
8887 (pci_mod_CFLAGS): Likewise.
8888 (pci_mod_LDFLAGS): Likewise.
8889 (lspci_mod_SOURCES): Likewise.
8890 (lspci_mod_CFLAGS): Likewise.
8891 (lspci_mod_LDFLAGS): Likewise.
8892
8893 2008-02-02 Bean <bean123ch@gmail.com>
8894
8895 * fs/ufs.c (INODE_BLKSZ): Fix incorrect value.
8896 (grub_ufs_get_file_block): Fix indirect block calculation problem.
8897
8898 * fs/xfs.c (grub_xfs_sblock): New member log2_dirblk.
8899 (grub_xfs_btree_node): New structure.
8900 (grub_xfs_btree_root): New structure.
8901 (grub_xfs_inode): New members nblocks, extsize, nextents and btree.
8902 (GRUB_XFS_EXTENT_OFFSET): Use exts instead of inode->data.extents.
8903 (GRUB_XFS_EXTENT_BLOCK): Likewise.
8904 (GRUB_XFS_EXTENT_SIZE): Likewise.
8905 (grub_xfs_read_block): Support btree format type.
8906 (grub_xfs_iterate_dir): Use NESTED_FUNC_ATTR in call_hook.
8907 Use directory block as basic unit.
8908
8909 * fs/fshelp.c (grub_fshelp_read_file): Bug fix for sparse block.
8910
8911 * aclocal.m4 (grub_i386_CHECK_REGPARM_BUG): Define NESTED_FUNC_ATTR as
8912 __attribute__ ((__regparm__ (1))).
8913
8914 2008-02-01 Robert Millan <rmh@aybabtu.com>
8915
8916 Correct a mistake in previous commit.
8917
8918 * conf/i386-pc.rmk (normal/execute.c_DEPENDENCIES): Move to the
8919 top.
8920 (normal/command.c_DEPENDENCIES): New variable.
8921
8922 2008-02-01 Robert Millan <rmh@aybabtu.com>
8923
8924 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Move to the
8925 top.
8926 (normal/command.c_DEPENDENCIES): New variable.
8927 (grub-emu_DEPENDENCIES, normal_mod_DEPENDENCIES): Remove variables.
8928 * conf/i386-ieee1275.rmk: Likewise.
8929 * conf/i386-linuxbios.rmk: Likewise.
8930 * conf/i386-pc.rmk: Likewise.
8931 * conf/sparc64-ieee1275.rmk: Likewise.
8932 * conf/powerpc-ieee1275.rmk: Likewise.
8933 (grub_emu_SOURCES): Add `fs/fshelp.c'.
8934
8935 * genmk.rb: Add `$(#{src}_DEPENDENCIES)' in targets that require it.
8936
8937 2008-02-01 Robert Millan <rmh@aybabtu.com>
8938
8939 * kern/disk.c (grub_disk_read, grub_disk_write): Add grub_dprintf()
8940 call at beginning of function.
8941
8942 2008-01-31 Pavel Roskin <proski@gnu.org>
8943
8944 * util/powerpc/ieee1275/grub-mkrescue.in: New file.
8945 * conf/powerpc-ieee1275.rmk (bin_SCRIPTS): New variable.
8946 (grub_mkrescue_SOURCES): Likewise.
8947 * DISTLIST: Add util/powerpc/ieee1275/grub-mkrescue.in.
8948
8949 2008-01-30 Robert Millan <rmh@aybabtu.com>
8950
8951 * conf/i386-pc.rmk (sbin_UTILITIES): Remove `grub-probe'.
8952 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Moved from here ...
8953 * conf/common.rmk (util/grub-probe.c_DEPENDENCIES)
8954 (grub_probe_SOURCES): ... to here.
8955
8956 * conf/i386-efi.rmk (sbin_UTILITIES): Remove `grub-probe'.
8957 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Remove.
8958 * conf/i386-ieee1275.rmk: Likewise.
8959 * conf/i386-linuxbios.rmk: Likewise.
8960 * conf/powerpc-ieee1275.rmk: Likewise.
8961
8962 2008-01-30 Tristan Gingold <gingold@free.fr>
8963
8964 * kern/rescue.c: Silently accept empty lines.
8965
8966 2008-01-29 Bean <bean123ch@gmail.com>
8967
8968 * boot/i386/pc/lnxboot.S (data_start): Code cleanup.
8969 (real_code_2): Code cleanup and change comment style.
8970 (move_memory): Avoid using 32-bit address mode.
8971
8972 2008-01-29 Bean <bean123ch@gmail.com>
8973
8974 * conf/i386-pc.rmk (pkglib_MODULES): Add `png.mod'.
8975 (png_mod_SOURCES): New variable.
8976 (png_mod_CFLAGS): Likewise.
8977 (png_mod_LDFLAGS): Likewise.
8978
8979 * video/readers/png.c: New file.
8980
8981 2008-01-28 Robert Millan <rmh@aybabtu.com>
8982
8983 * include/grub/i386/linuxbios/kernel.h (GRUB_MOD_GAP): New macro.
8984 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Remove
8985 `ifndef GRUB_MOD_GAP' hack.
8986 * util/elf/grub-mkimage.c (add_segments): Likewise.
8987
8988 2008-01-27 Robert Millan <rmh@aybabtu.com>
8989
8990 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Skip
8991 `GRUB_MOD_GAP' for platforms in which it's not defined.
8992 * util/elf/grub-mkimage.c (add_segments): Likewise.
8993
8994 2008-01-27 Robert Millan <rmh@aybabtu.com>
8995
8996 Get grub-emu to build again (including parallel builds).
8997
8998 * conf/i386-pc.rmk (util/grub-emu.c_DEPENDENCIES): Remove variable.
8999 Split into ...
9000 (util/grub-emu.c_DEPENDENCIES): ... this, ...
9001 (normal/execute.c_DEPENDENCIES): ... this, ...
9002 (grub-emu_DEPENDENCIES): ... and this.
9003
9004 * conf/i386-efi.rmk: Likewise.
9005 * conf/i386-linuxbios.rmk: Likewise.
9006 * conf/i386-ieee1275.rmk: Likewise.
9007 * conf/powerpc-ieee1275.rmk: Likewise.
9008 (grub_emu_SOURCES): Remove duplicated `kern/file.c'.
9009
9010 2008-01-27 Robert Millan <rmh@aybabtu.com>
9011
9012 * NEWS: Add a few items.
9013
9014 2008-01-27 Robert Millan <rmh@aybabtu.com>
9015
9016 Fix parallel builds with grub-emu. Based on earlier commit for
9017 grub-probe and grub-setup.
9018
9019 * conf/i386-pc.rmk (grub-emu_DEPENDENCIES): Renamed to ...
9020 (util/grub-emu.c_DEPENDENCIES): ... this.
9021 * conf/i386-efi.rmk (grub-emu_DEPENDENCIES): Renamed to ...
9022 (util/grub-emu.c_DEPENDENCIES): ... this.
9023 * conf/i386-linuxbios.rmk (grub-emu_DEPENDENCIES): Renamed to ...
9024 (util/grub-emu.c_DEPENDENCIES): ... this.
9025 * conf/i386-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
9026 (util/grub-emu.c_DEPENDENCIES): ... this.
9027 * conf/powerpc-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
9028 (util/grub-emu.c_DEPENDENCIES): ... this.
9029
9030 2008-01-27 Pavel Roskin <proski@gnu.org>
9031
9032 * include/grub/powerpc/ieee1275/kernel.h: Introduce GRUB_MOD_GAP
9033 to create a gap between _end and the modules added to the image
9034 with grub-mkrescue. That fixes "CLAIM failed" on PowerMAC.
9035 * kern/powerpc/ieee1275/init.c: Use GRUB_MOD_GAP.
9036 * util/elf/grub-mkimage.c (add_segments): Likewise.
9037
9038 2008-01-26 Pavel Roskin <proski@gnu.org>
9039
9040 * kern/dl.c (grub_dl_load): Don't abort if prefix is not set,
9041 just return an error.
9042
9043 2008-01-26 Bean <bean123ch@gmail.com>
9044
9045 * fs/reiserfs.c (grub_fshelp_node): New member next_offset.
9046 (grub_reiserfs_get_item): Save offset of the next item.
9047 (grub_reiserfs_iterate_dir): Use next_offset to find next item.
9048
9049 2008-01-25 Robert Millan <rmh@aybabtu.com>
9050
9051 * conf/i386-pc.rmk (grub_setup_SOURCES, grub_emu_SOURCES): Regroup to
9052 make all filesystem sources appear together (possibly fixing omissions
9053 while at it).
9054 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
9055 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
9056 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
9057 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
9058
9059 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise. Additionally,
9060 add `kern/file.c'.
9061 * conf/i386-efi.rmk (grub_probe_SOURCES): Likewise.
9062 * conf/i386-ieee1275.rmk (grub_probe_SOURCES): Likewise.
9063 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Likewise.
9064 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Likewise.
9065
9066 * util/grub-probe.c: Include `<grub/file.h>' and `<sys/stat.h>'.
9067 (probe): Add a sanity check to make sure of our ability to read
9068 requested files when probing for filesystem type.
9069
9070 * genmk.rb: Update copyright year (2007).
9071
9072 * include/grub/fs.h (grub_fat_init, grub_fat_fini, grub_ext2_init)
9073 (grub_ext2_fini, grub_ufs_init, grub_ufs_fini, grub_minix_init)
9074 (grub_minix_fini, grub_hfs_init, grub_hfs_fini, grub_jfs_init)
9075 (grub_jfs_fini, grub_xfs_init, grub_xfs_fini, grub_affs_init)
9076 (grub_affs_fini, grub_sfs_init, grub_sfs_fini, grub_iso9660_init)
9077 : Remove function prototypes.
9078
9079 2008-01-25 Robert Millan <rmh@aybabtu.com>
9080
9081 Revert my previous commits (based on wrong assumption of how grub_errno
9082 works).
9083
9084 * kern/disk.c (grub_disk_open): Stop resetting grub_errno.
9085 * kern/file.c (grub_file_open): Likewise.
9086
9087 2008-01-24 Pavel Roskin <proski@gnu.org>
9088
9089 * include/grub/ieee1275/ieee1275.h: Introduce flag for firmwares
9090 that hang if GRUB tries to setup colors.
9091 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Don't set
9092 colors for firmwares that don't support it.
9093 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag):
9094 Recognize Open Hack'Ware, set flags to work around its
9095 limitations.
9096
9097 2008-01-24 Robert Millan <rmh@aybabtu.com>
9098
9099 * kern/file.c (grub_file_open): Do not account previous failures of
9100 unrelated functions when grub_errno is checked for.
9101 Reported by Oleg Strikov.
9102
9103 2008-01-24 Bean <bean123ch@gmail.com>
9104
9105 * fs/ufs.c (GRUB_UFS_VOLNAME_LEN): New macro.
9106 (grub_ufs_sblock): New member volume name.
9107 (grub_ufs_find_file): Fix string copy bug.
9108 (grub_ufs_label): Implement this function properly.
9109
9110 * fs/hfs.c (grub_hfs_cnid_type): New enum.
9111 (grub_hfs_iterate_records): Use the correct file number for extents
9112 and catalog file. Fix problem in next index calculation.
9113 (grub_hfs_find_node): Replace recursive function call with loop.
9114 (grub_hfs_iterate_dir): Replace recursive function call with loop.
9115
9116 2008-01-23 Robert Millan <rmh@aybabtu.com>
9117
9118 * include/grub/i386/ieee1275/loader.h: Include `<grub/types.h>',
9119 `<grub/symbol.h>' and `<grub/multiboot.h>'.
9120 (grub_multiboot2_real_boot): New function prototype.
9121
9122 * include/grub/i386/pc/memory.h: Include `<grub/machine/machine.h>'.
9123 [!GRUB_MACHINE_IEEE1275] (grub_lower_mem, grub_upper_mem): Disable.
9124
9125 * kern/i386/ieee1275/init.c (grub_os_area_addr)
9126 (grub_os_area_size, grub_lower_mem, grub_upper_mem): Remove variables.
9127
9128 2008-01-23 Robert Millan <rmh@aybabtu.com>
9129
9130 * kern/mm.c (grub_mm_init_region): Replace grub_dprintf() call with
9131 #ifdef'ed out grub_printf().
9132
9133 2008-01-23 Robert Millan <rmh@aybabtu.com>
9134
9135 * term/i386/pc/at_keyboard.c (grub_keyboard_isr): #ifdef out
9136 grub_dprintf calls, since they make "debug=all" mode unusable.
9137 (grub_console_checkkey): Likewise.
9138
9139 2008-01-23 Robert Millan <rmh@aybabtu.com>
9140
9141 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
9142 `term/i386/pc/at_keyboard.c'.
9143 (pkglib_MODULES): Add `serial.mod'.
9144 (serial_mod_SOURCES): New variable.
9145 (serial_mod_CFLAGS): Likewise.
9146 (serial_mod_LDFLAGS): Likewise.
9147
9148 * include/grub/i386/ieee1275/console.h: Add `<grub/symbol.h>'. Remove
9149 `<grub/powerpc/ieee1275/console.h>'.
9150 (grub_keyboard_controller_init): New function prototype.
9151 (grub_console_checkkey): Likewise.
9152 (grub_console_getkey): Likewise.
9153
9154 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize AT
9155 keyboard on i386.
9156
9157 * term/ieee1275/ofconsole.c (grub_ofconsole_term): On i386, use
9158 grub_ofconsole_checkkey() and grub_ofconsole_getkey() for input.
9159
9160 2008-01-23 Robert Millan <rmh@aybabtu.com>
9161
9162 * kern/i386/pc/init.c (make_install_device): When memdisk image is
9163 present, "(memdisk)/boot/grub" becomes the default prefix.
9164
9165 * util/i386/pc/grub-mkrescue.in: Switch to a minimal core.img plus
9166 a memdisk tarball with all the modules. Add --overlay=DIR option that
9167 allows users to overlay additional files into the image.
9168
9169 2008-01-23 Robert Millan <rmh@aybabtu.com>
9170
9171 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add `machine/loader.h'
9172 and `machine/memory.h'.
9173 (pkglib_MODULES): Add `multiboot.mod' and `_multiboot.mod'.
9174 (_multiboot_mod_SOURCES): New variable.
9175 (_multiboot_mod_CFLAGS): Likewise.
9176 (_multiboot_mod_LDFLAGS): Likewise.
9177 (multiboot_mod_SOURCES): Likewise.
9178 (multiboot_mod_CFLAGS): Likewise.
9179 (multiboot_mod_LDFLAGS): Likewise.
9180
9181 * include/grub/i386/ieee1275/loader.h: New file.
9182
9183 * include/grub/i386/ieee1275/machine.h: Likewise.
9184
9185 * include/grub/i386/ieee1275/memory.h: Likewise.
9186
9187 * include/grub/i386/pc/init.h (grub_os_area_addr): Remove (redundant)
9188 variable declaration.
9189 (grub_os_area_size): Likewise.
9190
9191 * kern/i386/ieee1275/init.c (grub_os_area_addr, grub_os_area_size)
9192 (grub_lower_mem, grub_upper_mem): New variables.
9193 (grub_stop_floppy): New function (just to make
9194 grub_multiboot2_real_boot() happy).
9195
9196 * kern/i386/ieee1275/startup.S: Include `<grub/machine/memory.h>',
9197 `<grub/cpu/linux.h>', `<multiboot.h>' and `<multiboot2.h>'.
9198 (grub_stop): New function.
9199 Include `"../realmode.S"' and `"../loader.S"'.
9200
9201 * loader/multiboot_loader.c: Include `<grub/machine/machine.h>'.
9202 Replace `__i386__' #ifdefs with `GRUB_MACHINE_PCBIOS'.
9203
9204 * loader/powerpc/ieee1275/multiboot2.c (grub_mb2_arch_boot): On i386,
9205 rely on grub_multiboot2_real_boot() for final boot.
9206
9207 2008-01-22 Robert Millan <rmh@aybabtu.com>
9208
9209 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): When
9210 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag is set, skip any
9211 device that doesn't look like an SD card.
9212 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
9213 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag.
9214 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag): Detect
9215 OLPC laptop, and set `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' when
9216 found.
9217
9218 2008-01-22 Robert Millan <rmh@aybabtu.com>
9219
9220 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Add sanity check to
9221 avoid claiming over our own code.
9222
9223 2008-01-22 Bean <bean123ch@gmail.com>
9224
9225 * conf/i386-pc.rmk (pkglib_MODULES): Add `jpeg.mod'.
9226 (jpeg_mod_SOURCES): New variable.
9227 (jpeg_mod_CFLAGS): Likewise.
9228 (jpeg_mod_LDFLAGS): Likewise.
9229
9230 * video/readers/jpeg.c : New file.
9231
9232 2008-01-22 Bean <bean123ch@gmail.com>
9233
9234 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_FILE_NOT_FOUND when
9235 there are no more items.
9236
9237 2008-01-21 Robert Millan <rmh@aybabtu.com>
9238
9239 * kern/mm.c (grub_mm_init_region): Improve debug message.
9240
9241 2008-01-21 Robert Millan <rmh@aybabtu.com>
9242
9243 * conf/i386-pc.rmk (GRUB_MEMORY_MACHINE_LINK_ADDR): New variable.
9244 (kernel_img_LDFLAGS): Use `GRUB_MEMORY_MACHINE_LINK_ADDR' as link
9245 address.
9246 (grub_mkimage_CFLAGS): Propagate `GRUB_MEMORY_MACHINE_LINK_ADDR' as
9247 a C macro.
9248 * include/grub/i386/pc/memory.h (GRUB_MEMORY_MACHINE_UPPER): New macro.
9249 Indicates start of upper memory.
9250 * util/i386/pc/grub-mkimage.c: Include `<grub/machine/memory.h>'.
9251 (generate_image): Abort when image size is big enough to corrupt
9252 upper memory.
9253
9254 * include/grub/i386/pc/vga.h: Include `<grub/machine/memory.h>'.
9255 (GRUB_MEMORY_MACHINE_VGA_ADDR): Alias for `GRUB_MEMORY_MACHINE_UPPER'.
9256 * term/i386/pc/vga.c (VGA_MEM): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
9257 instead of hardcoding 0xA0000.
9258 * video/i386/pc/vbe.c: Include `<grub/machine/vga.h>'.
9259 (grub_vbe_set_video_mode): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
9260 instead of hardcoding 0xA0000.
9261
9262 2008-01-21 Robert Millan <rmh@aybabtu.com>
9263
9264 * disk/memdisk.c (memdisk_size): New variable.
9265 (grub_memdisk_open): Replace grub_arch_memdisk_size() call with
9266 `memdisk_size'.
9267 (grub_memdisk_init): Initialize `memdisk_size'. Reallocate memdisk
9268 image to dynamic memory.
9269 (grub_memdisk_fini): Replace grub_arch_memdisk_size() call with
9270 `memdisk_size'. Free memdisk block.
9271
9272 2008-01-21 Robert Millan <rmh@aybabtu.com>
9273
9274 Fix detection of very small filesystems (like tar).
9275
9276 * fs/reiserfs.c (grub_reiserfs_mount): When disk is too small to
9277 contain a ReiserFS, abort with GRUB_ERR_BAD_FS rather than
9278 GRUB_ERR_OUT_OF_RANGE (which made the upper layer think there's
9279 a problem with this disk).
9280
9281 2008-01-21 Robert Millan <rmh@aybabtu.com>
9282
9283 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Add debug message
9284 on grub_biosdisk_rw_standard() error.
9285
9286 2008-01-21 Robert Millan <rmh@aybabtu.com>
9287
9288 * include/grub/ieee1275/ieee1275.h: Add 2008 to Copyright line for
9289 recent changes.
9290 * kern/elf.c: Likewise.
9291 * kern/ieee1275/ieee1275.c: Likewise.
9292 * kern/powerpc/ieee1275/openfw.c: Likewise.
9293 * term/ieee1275/ofconsole.c: Likewise.
9294
9295 2008-01-21 Robert Millan <rmh@aybabtu.com>
9296
9297 * include/grub/i386/pc/kernel.h: Include `<grub/symbol.h>'.
9298
9299 * include/grub/kernel.h (grub_arch_memdisk_addr)
9300 (grub_arch_memdisk_size): Moved from here ...
9301
9302 * include/grub/i386/pc/kernel.h (grub_arch_memdisk_addr)
9303 (grub_arch_memdisk_size): ... to here.
9304
9305 2008-01-21 Robert Millan <rmh@aybabtu.com>
9306
9307 Mostly based on bugfix from Bean.
9308
9309 * kern/elf.c (grub_elf32_phdr_iterate): Use `NESTED_FUNC_ATTR'
9310 attribute with hook() parameter.
9311 (grub_elf32_load): Use `NESTED_FUNC_ATTR' with grub_elf32_load_segment()
9312 declaration.
9313 (grub_elf64_phdr_iterate): Use `NESTED_FUNC_ATTR'
9314 attribute with hook() parameter.
9315 (grub_elf64_load): Use `NESTED_FUNC_ATTR' with grub_elf64_load_segment()
9316 declaration.
9317
9318 2008-01-21 Robert Millan <rmh@aybabtu.com>
9319
9320 * conf/i386-pc.rmk (kernel_img_HEADERS): Add `machine/kernel.h'.
9321 (pkglib_MODULES): Add `memdisk.mod'.
9322 (memdisk_mod_SOURCES): New variable.
9323 (memdisk_mod_CFLAGS): Likewise.
9324 (memdisk_mod_LDFLAGS): Likewise.
9325
9326 * disk/memdisk.c: New file.
9327
9328 * include/grub/disk.h (grub_disk_dev_id): Add
9329 `GRUB_DISK_DEVICE_MEMDISK_ID'.
9330
9331 * include/grub/i386/pc/kernel.h
9332 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): New macro.
9333 (GRUB_KERNEL_MACHINE_PREFIX): Increment by 4.
9334 (grub_kernel_image_size): New variable declaration.
9335 (grub_total_module_size): Likewise.
9336 (grub_memdisk_image_size): Likewise.
9337
9338 * include/grub/i386/pc/memory.h
9339 (GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR): New macro.
9340
9341 * include/grub/kernel.h: Include `<grub/symbol.h>'.
9342 (grub_arch_memdisk_addr): New variable declaration.
9343 (grub_arch_memdisk_size): Likewise.
9344
9345 * kern/i386/pc/init.c (grub_arch_memdisk_addr): New function.
9346 (grub_arch_memdisk_size): Likewise.
9347
9348 * kern/i386/pc/startup.S (grub_memdisk_image_size): New variable.
9349 (codestart): Replace hardcoded `0x100000' with
9350 `GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR' macro.
9351
9352 * util/i386/pc/grub-mkimage.c: Include `<grub/misc.h>'.
9353 (generate_image): Add `memdisk_path' parameter. When `memdisk_path' is
9354 not NULL, append the contents of the file it refers to, at the end of
9355 the compressed kernel image. Initialize `grub_memdisk_image_size'
9356 variable (at `GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE' offset).
9357 (options): Add "memdisk"|'m' option.
9358 (main): Parse --memdisk|-m option, and pass user-provided path as
9359 parameter to generate_image().
9360
9361 2008-01-20 Robert Millan <rmh@aybabtu.com>
9362
9363 * kern/sparc64/ieee1275/openfw.c (grub_devalias_iterate): Copy debug
9364 grub_dprintf() calls from here ...
9365 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): ... to here.
9366
9367 2008-01-20 Robert Millan <rmh@aybabtu.com>
9368
9369 Fix detection of "real mode" when /options/real-mode? doesn't exist.
9370
9371 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_mmu): New variable
9372 declaration.
9373 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_mmu): New variable.
9374 (grub_ieee1275_find_options): If `grub_ieee1275_mmu' is 0, set
9375 `GRUB_IEEE1275_FLAG_REAL_MODE'.
9376 (cmain): Initialize `grub_ieee1275_mmu' (using /chosen/mmu integer
9377 property).
9378 * kern/powerpc/ieee1275/openfw.c (grub_map): Rely on pre-initialized
9379 `grub_ieee1275_mmu' rather than obtaining a handler on every call.
9380
9381 2008-01-19 Robert Millan <rmh@aybabtu.com>
9382
9383 Get rid of confusing function (superseded by
9384 `grub_ieee1275_get_integer_property')
9385 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_decode_int_4): Remove
9386 prototype.
9387 * kern/ieee1275/ieee1275.c (grub_ieee1275_decode_int_4): Remove
9388 function.
9389 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid use of
9390 grub_ieee1275_decode_int_4(), by obtaining integer properties directly
9391 in native endianness from grub_ieee1275_get_integer_property().
9392
9393 2008-01-19 Robert Millan <rmh@aybabtu.com>
9394
9395 * kern/powerpc/ieee1275/openfw.c (grub_halt): Issue "power-off"
9396 command after "shut-down", since implementations differ on which
9397 the command for halt is.
9398
9399 2008-01-19 Robert Millan <rmh@aybabtu.com>
9400
9401 * include/grub/i386/linuxbios/console.h: Add header protection.
9402 (grub_keyboard_controller_init): New function prototype.
9403 * term/i386/pc/at_keyboard.c (KEYBOARD_COMMAND_ISREADY): New macro.
9404 (KEYBOARD_COMMAND_READ): Likewise.
9405 (KEYBOARD_COMMAND_WRITE): Likewise.
9406 (KEYBOARD_SCANCODE_SET1): Likewise.
9407 (grub_keyboard_controller_write): New function.
9408 (grub_keyboard_controller_read): Likewise.
9409 (grub_keyboard_controller_init): Likewise.
9410
9411 * term/i386/pc/console.c: Include `<grub/machine/machine.h>'.
9412 (grub_console_init): On coreboot/LinuxBIOS, call
9413 grub_keyboard_controller_init().
9414
9415 2008-01-19 Robert Millan <rmh@aybabtu.com>
9416
9417 PowerPC changes provided by Pavel Roskin.
9418
9419 * kern/powerpc/ieee1275/cmain.c (cmain): Don't take any arguments.
9420 * kern/powerpc/ieee1275/crt0.S: Store r5 in grub_ieee1275_entry_fn,
9421 don't rely on cmain() doing it.
9422 * kern/i386/ieee1275/startup.S (_start): Store %eax in
9423 grub_ieee1275_entry_fn, don't rely on cmain() doing it.
9424
9425 2008-01-16 Robert Millan <rmh@aybabtu.com>
9426
9427 * include/grub/i386/linuxbios/memory.h
9428 (GRUB_MEMORY_MACHINE_LINUXBIOS_TABLE_ADDR): Remove macro.
9429 * kern/i386/linuxbios/table.c (grub_linuxbios_table_iterate): Do not
9430 receive `table_header' as argument. Instead, probe for it in the
9431 known memory ranges where it can be present.
9432 (grub_available_iterate): Do not pass a fixed `table_header' address
9433 to grub_linuxbios_table_iterate().
9434
9435 2008-01-15 Robert Millan <rmh@aybabtu.com>
9436
9437 * configure.ac: Add `i386-ieee1275' to the list of supported targets.
9438 * conf/i386-ieee1275.rmk: New file.
9439 * include/grub/i386/ieee1275/console.h: Likewise.
9440 * include/grub/i386/ieee1275/ieee1275.h: Likewise.
9441 * include/grub/i386/ieee1275/kernel.h: Likewise.
9442 * include/grub/i386/ieee1275/time.h: Likewise.
9443 * kern/i386/ieee1275/init.c: Likewise.
9444 * kern/i386/ieee1275/startup.S: Likewise.
9445
9446 2008-01-15 Robert Millan <rmh@aybabtu.com>
9447
9448 * kern/misc.c (grub_vsprintf): Do not reset `longlongfmt' to zero
9449 when pointers are 32-bit (but still do set it to one when they are
9450 64-bit).
9451
9452 2008-01-15 Robert Millan <rmh@aybabtu.com>
9453
9454 * include/grub/ieee1275/ieee1275.h
9455 (grub_ieee1275_get_integer_property): New function prototype.
9456
9457 * kern/ieee1275/ieee1275.c: Include `<grub/types.h>'.
9458 (grub_ieee1275_get_integer_property): New function. Wraps around
9459 grub_ieee1275_get_property() to handle endianness.
9460
9461 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Replace
9462 grub_ieee1275_get_property() with grub_ieee1275_get_integer_property()
9463 where appropriate.
9464 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Likewise.
9465 (grub_map): Likewise.
9466 * kern/sparc64/ieee1275/openfw.c (grub_map): Likewise.
9467
9468 2008-01-15 Bean <bean123ch@gmail.com>
9469
9470 * normal/execute.c (grub_script_exec_argument_to_string): Check for undefined variable.
9471 (grub_script_execute_cmdline): Reset grub_errno.
9472
9473 * normal/main.c (read_config_file): Reset grub_errno.
9474
9475 * normal/parse.y (script_init): New.
9476 (script): Move function and menuentry here.
9477 (delimiter): New.
9478 (command): Add delimiter at the end of command.
9479 (commands): Adjust to match the new command.
9480 (commandblock): Remove grub_script_lexer_record_start.
9481 (menuentry): Add grub_script_lexer_record_start, use the new commands.
9482 (if): Use the new commands.
9483
9484 * conf/common.rmk (pkgdata_MODULES): Add echo.mod.
9485
9486 2008-01-15 Robert Millan <rmh@aybabtu.com>
9487
9488 * normal/menu.c (run_menu): Move timeout message from here ...
9489 (print_timeout): ... to here.
9490 (run_menu): Use print_timeout() once during initial draw to print
9491 the whole message, and again in every clock tick to update only
9492 the number of seconds.
9493
9494 2008-01-15 Robert Millan <rmh@aybabtu.com>
9495
9496 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Obtain
9497 actual size of `available' from grub_ieee1275_get_property(), and
9498 restrict parsing to that bound.
9499
9500 2008-01-15 Christian Franke <franke@computer.org>
9501
9502 * util/grub-emu.c: Replace <argp.h> by <getopt.h>.
9503 (argp_program_version): Remove variable.
9504 (argp_program_bug_address): Likewise.
9505 (options): Convert from struct argp_option to struct option.
9506 (struct arguments): Remove.
9507 (parse_opt): Remove.
9508 (usage): New function.
9509 (main): Replace struct args members by simple variables.
9510 Replace argp_parse() by getopt_long().
9511 Add switch to evaluate options.
9512 Add missing "(...)" around root_dev in prefix string.
9513
9514 2008-01-14 Robert Millan <rmh@aybabtu.com>
9515
9516 * kern/powerpc/ieee1275/init.c (grub_exit): Reimplement as a wrapper
9517 for grub_ieee1275_exit(), in order to improve portability.
9518
9519 2008-01-14 Robert Millan <rmh@aybabtu.com>
9520
9521 * util/grub.d/10_linux.in (prefix): Define.
9522 (exec_prefix): Likewise. Both definitions are later used by `libdir'.
9523
9524 2008-01-13 Pavel Roskin <proski@gnu.org>
9525
9526 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Don't use
9527 grub_errno if no errors have been detected.
9528
9529 2008-01-12 Robert Millan <rmh@aybabtu.com>
9530
9531 * include/grub/util/getroot.h (grub_dev_abstraction_types): New enum.
9532 (grub_util_get_dev_abstraction): New function prototype.
9533
9534 * util/getroot.c: Include `<grub/util/getroot.h>'
9535 (grub_util_get_grub_dev): Move detection of abstraction type to ...
9536 (grub_util_get_dev_abstraction): ... here (new function).
9537
9538 * util/grub-probe.c: Convert PRINT_* to an enum. Add
9539 `PRINT_ABSTRACTION'.
9540 (probe): Probe for abstraction type when requested.
9541 (main): Understand `--target=abstraction'.
9542
9543 * util/i386/efi/grub-install.in: Add abstraction module to core
9544 image when it is found to be necessary.
9545 * util/i386/pc/grub-install.in: Likewise.
9546 * util/powerpc/ieee1275/grub-install.in: Likewise.
9547
9548 * util/update-grub_lib.in (font_path): Return system path without
9549 converting to GRUB path.
9550 * util/update-grub.in: Convert system path returned by font_path()
9551 to a GRUB path. Use `grub-probe -t abstraction' to determine what
9552 abstraction module is needed for loading fonts (if any). Export
9553 that as `GRUB_PRELOAD_MODULES'.
9554 * util/grub.d/00_header.in: Process `GRUB_PRELOAD_MODULES' (print
9555 insmod commands).
9556
9557 2008-01-12 Yoshinori K. Okuji <okuji@enbug.org>
9558
9559 Remove some unused code from reiserfs.
9560
9561 * fs/reiserfs.c (struct grub_reiserfs_key)
9562 [GRUB_REISERFS_KEYV2_BITFIELD]: Removed offset and type.
9563 (struct grub_reiserfs_node_body): Removed.
9564 (grub_reiserfs_get_key_v2_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
9565 Likewise.
9566 (grub_reiserfs_get_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
9567 Likewise.
9568 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
9569 Likewise.
9570 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
9571 Likewise.
9572 (grub_reiserfs_set_key_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
9573 Likewise.
9574 (grub_reiserfs_iterate_dir) [GRUB_REISERFS_KEYV2_BITFIELD]:
9575 Likewise.
9576 (grub_reiserfs_open) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
9577 (grub_reiserfs_read) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
9578 (grub_reiserfs_dir) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
9579
9580 2008-01-10 Robert Millan <rmh@aybabtu.com>
9581
9582 * util/update-grub_lib.in (grub_file_is_not_garbage): New function.
9583 Determines if a file is garbage left by packaging systems, etc.
9584 * util/update-grub.in: Use grub_file_is_not_garbage() as a condition
9585 for processing /etc/grub.d scripts.
9586 * util/grub.d/10_hurd.in: Fix `GRUB_DISTRIBUTOR' comparison.
9587 * util/grub.d/10_linux.in: Likewise. Use grub_file_is_not_garbage()
9588 as a condition for processing Linux images.
9589
9590 2008-01-10 Pavel Roskin <proski@gnu.org>
9591
9592 * include/grub/powerpc/libgcc.h (__ucmpdi2): New export. Needed
9593 to compile reiserfs.c on PowerPC.
9594
9595 2008-01-10 Robert Millan <rmh@aybabtu.com>
9596
9597 * kern/device.c (grub_device_iterate): Do not abort device iteration
9598 when one of the devices cannot be opened.
9599 * kern/disk.c (grub_disk_open): Do not account previous failures of
9600 unrelated functions when grub_errno is checked for.
9601
9602 2008-01-08 Robert Millan <rmh@aybabtu.com>
9603
9604 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): For
9605 `! grub_linux_is_bzimage', change order of address comparison to make
9606 it more intuitive, and improve "too big zImage" error message.
9607
9608 2008-01-08 Robert Millan <rmh@aybabtu.com>
9609
9610 * Makefile.in (uninstall): Handle `$(update-grub_SCRIPTS)' and
9611 `$(update-grub_DATA)'.
9612 (distcheck): Fix race condition when invoking `$(MAKE)' on multiple
9613 targets.
9614
9615 2008-01-07 Robert Millan <rmh@aybabtu.com>
9616
9617 * boot/i386/pc/boot.S (boot_drive_check): Add a comment indicating
9618 which instruction is modified by grub-setup during installation
9619 (since it wasn't obvious by only looking at this file).
9620
9621 2008-01-07 Robert Millan <rmh@aybabtu.com>
9622
9623 * TODO: Rewrite. Just refer to the wiki and the BTS instead of
9624 listing actual TODO items.
9625
9626 2008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
9627
9628 * fs/reiserfs.c (grub_reiserfs_get_key_v2_type): Handle endianness
9629 correctly.
9630 (grub_reiserfs_get_key_offset): Likewise.
9631 (grub_reiserfs_set_key_offset): Likewise.
9632 (grub_reiserfs_set_key_type): Likewise.
9633 (grub_reiserfs_iterate_dir): Return 1 if found, otherwise 0.
9634
9635 (GRUB_REISERFS_KEYV2_BITFIELD): Undefined. Probably it would be
9636 better to remove the bitfield version completely.
9637
9638 2008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
9639
9640 * fs/reiserfs.c (grub_reiserfs_iterate_dir): ENTRY_ITEM must be
9641 allocated from the heap, due to the fshelp implementation.
9642 (grub_reiserfs_dir): Free NODE, due to the same reason.
9643
9644 2008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
9645
9646 Mostly from Vincent Pelletier:
9647
9648 * fs/reiserfs.c: New file.
9649
9650 * conf/common.rmk (pkglib_MODULES): Added reiserfs.mod.
9651 (reiserfs_mod_SOURCES): New variable.
9652 (reiserfs_mod_CFLAGS): Likewise.
9653 (reiserfs_mod_LDFLAGS): Likewise.
9654
9655 * DISTLIST: Added boot/i386/pc/lnxboot.S, commands/hexdump.c,
9656 disk/ata.c, fs/cpio.c, fs/ntfscomp.c, fs/reiserfs.c,
9657 include/grub/ntfs.h, include/grub/i386/pc/machine.h, and
9658 normal/color.c.
9659
9660 2008-01-06 Robert Millan <rmh@aybabtu.com>
9661
9662 * normal/color.c: Remove `<grub/env.h>'.
9663
9664 2008-01-05 Jeroen Dekkers <jeroen@dekkers.cx>
9665
9666 * include/grub/normal.h: Include <grub/env.h>.
9667
9668 2008-01-05 Robert Millan <rmh@aybabtu.com>
9669
9670 * util/i386/pc/grub-setup.c (usage): Replace obsolete `(hd0,0)' in
9671 usage example with `(hd0,1)'.
9672 Reported by Samuel Thibault.
9673
9674 2008-01-05 Robert Millan <rmh@aybabtu.com>
9675
9676 * kern/i386/loader.S (grub_linux_is_bzimage): New variable.
9677 (grub_linux_boot_zimage): Rename to ...
9678 (grub_linux_boot): ... this.
9679 (grub_linux_boot_bzimage): Merge with `grub_linux_boot_zimage'.
9680 (grub_linux_boot_zimage): Conditionalize zImage copy.
9681
9682 * include/grub/i386/loader.h (grub_linux_is_bzimage): Add prototype.
9683 (grub_linux_boot_bzimage): Remove prototype.
9684 (grub_linux_boot_zimage): Rename to ...
9685 (grub_linux_boot): ... this.
9686
9687 * loader/i386/pc/linux.c (big_linux): Replace with `grub_linux_is_bzimage'.
9688 (grub_linux_boot): Remove function.
9689
9690 2008-01-05 Robert Millan <rmh@aybabtu.com>
9691
9692 * include/grub/normal.h (grub_env_write_color_normal): New prototype.
9693 (grub_env_write_color_highlight): Likewise.
9694 (grub_wait_after_message): Likewise.
9695
9696 * normal/color.c: New file.
9697
9698 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/color.c'.
9699 (normal_mod_DEPENDENCIES): Likewise.
9700
9701 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `normal/color.c'.
9702 (normal_mod_DEPENDENCIES): Likewise.
9703
9704 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add `normal/color.c'.
9705 (normal_mod_DEPENDENCIES): Likewise.
9706
9707 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `normal/color.c'.
9708 (normal_mod_DEPENDENCIES): Likewise.
9709
9710 * normal/menu_entry.c (run): Rely on grub_wait_after_message()
9711 for waiting after a message is printed.
9712 * normal/main.c (read_config_file): Likewise.
9713 (grub_normal_init): Register grub_env_write_color_normal() and
9714 grub_env_write_color_highlight() hooks. Mark `color_normal' and
9715 `color_highlight' variables as global.
9716
9717 * normal/menu.c (grub_wait_after_message): New function.
9718 (grub_color_menu_normal): New variable. Replaces ...
9719 (GRUB_COLOR_MENU_NORMAL): ... this macro.
9720 (grub_color_menu_highlight): New variable. Replaces ...
9721 (GRUB_COLOR_MENU_HIGHLIGHT): ... this macro.
9722 (draw_border): Set color state to `GRUB_TERM_COLOR_NORMAL' instead of
9723 `GRUB_TERM_COLOR_STANDARD'.
9724 (print_message): Use `grub_setcolorstate' to reload colors. Rename
9725 `normal_code' and `highlight_code' to `old_color_normal' and
9726 `old_color_highlight', respectively.
9727 (grub_menu_init_page): Update colors when drawing the menu, based on
9728 `menu_color_normal' and `menu_color_highlight' variables.
9729 (grub_menu_run): Rely on grub_wait_after_message() for waiting after
9730 a message is printed.
9731
9732 2008-01-05 Robert Millan <rmh@aybabtu.com>
9733
9734 * kern/env.c (grub_env_context_open): Propagate hooks for global
9735 variables to new context.
9736
9737 * kern/main.c (grub_set_root_dev): Export `root' variable.
9738
9739 2008-01-05 Robert Millan <rmh@aybabtu.com>
9740
9741 * util/biosdisk.c (get_os_disk): Check for devfs-style IDE and SCSI
9742 discs unconditionally, since udev and others have options to provide
9743 them.
9744
9745 2008-01-05 Robert Millan <rmh@aybabtu.com>
9746
9747 * normal/completion.c (iterate_dir): Skip `.' and `..' directories.
9748
9749 2008-01-04 Christian Franke <franke@computer.org>
9750
9751 * kern/i386/pc/init.c (grub_machine_init): Fix evaluation
9752 of eisa_mmap.
9753
9754 2008-01-03 Pavel Roskin <proski@gnu.org>
9755
9756 * kern/i386/linuxbios/init.c: Put "void" to all function
9757 declarations with no arguments.
9758 * kern/powerpc/ieee1275/init.c: Likewise.
9759 * term/i386/pc/at_keyboard.c: Likewise.
9760 * term/i386/pc/vga_text.c: Likewise.
9761 * util/grub-mkdevicemap.c: Likewise.
9762
9763 2008-01-02 Robert Millan <rmh@aybabtu.com>
9764
9765 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Improve error
9766 message when loaded image is out of bounds.
9767 (grub_multiboot_load_elf64): Likewise.
9768
9769 2008-01-02 Pavel Roskin <proski@gnu.org>
9770
9771 * util/grub.d/10_linux.in: Try version without ".old" when
9772 looking for initrd. It's better to use initrd from the newer
9773 kernel of the same version than no initrd at all.
9774
9775 2008-01-01 Robert Millan <rmh@aybabtu.com>
9776
9777 * util/biosdisk.c (get_os_disk): Fix check for IDE or SCSI discs.
9778
9779 2008-01-01 Vesa Jaaskelainen <chaac@nic.fi>
9780
9781 * include/grub/video.h: Added grub_video_unmap_color and
9782 grub_video_get_active_render_target.
9783 (grub_video_adapter): Added unmap_color and get_active_render_target.
9784
9785 * video/video.c: Added grub_video_unmap_color and
9786 grub_video_get_active_render_target.
9787 (grub_video_get_info): Changed method to accept NULL pointer as an
9788 argument to allow detection of active video adapter.
9789
9790 * video/i386/pc/vbe.c: Renamed grub_video_vbe_unmap_color as
9791 grub_video_vbe_unmap_color_int.
9792 Added grub_video_vbe_unmap_color and
9793 grub_video_vbe_get_active_render_target.
9794 (grub_video_vbe_adapter): Added unmap_color and
9795 get_active_render_target.
9796
9797 * video/i386/pc/vbeblit.c: Replaced grub_video_vbe_unmap_color usage
9798 with grub_video_vbe_unmap_color_int.
9799
9800 * term/gfxterm.c (DEFAULT_STANDARD_COLOR): Added.
9801 (DEFAULT_NORMAL_COLOR): Likewise.
9802 (DEFAULT_HIGHLIGHT_COLOR) Likewise.
9803 (DEFAULT_FG_COLOR): Removed.
9804 (DEFAULT_BG_COLOR): Likewise.
9805 (DEFAULT_CURSOR_COLOR): Changed value.
9806 (grub_virtual_screen): Added standard_color_setting,
9807 normal_color_setting, highlight_color_setting and term_color.
9808 (grub_virtual_screen): Removed fg_color_setting and bg_color_setting.
9809 (bitmap_width): Added.
9810 (bitmap_height): Likewise.
9811 (bitmap): Likewise.
9812 (set_term_color): Likewise.
9813 (grub_virtual_screen_setup): Changed to use new terminal coloring
9814 settings.
9815 (grub_gfxterm_init): Added init for bitmap.
9816 (grub_gfxterm_fini): Added destroy for bitmap.
9817 (redraw_screen_rect): Updated to use background bitmap and new
9818 terminal coloring.
9819 (scroll_up): Added optimization for case when there is no bitmap.
9820 (grub_gfxterm_cls): Fixed to use correct background color.
9821 (grub_virtual_screen_setcolorstate): Changed to use new terminal
9822 coloring.
9823 (grub_virtual_screen_setcolor): Likewise.
9824 (grub_virtual_screen_getcolor): Added.
9825 (grub_gfxterm_background_image_cmd): Likewise.
9826 (grub_video_term): Added setcolor and getcolor.
9827 (MOD_INIT): Added registration of background_image command.
9828 (MOD_TERM): Added unregistration for background_image command.
9829
9830 2007-12-30 Pavel Roskin <proski@gnu.org>
9831
9832 * loader/multiboot_loader.c: Fix multiboot command
9833 unregistration. Fix all typos in the word "multiboot".
9834
9835 2007-12-29 Pavel Roskin <proski@gnu.org>
9836
9837 * util/grub.d/10_linux.in: Refactor search for initrd. Add
9838 support for initrd names used in Fedora.
9839
9840 2007-12-26 Bean <bean123ch@gmail.com>
9841
9842 * conf/common.rmk (pkgdata_MODULES): Add cpio.mod.
9843 (cpio_mod_SOURCES): New variable.
9844 (cpio_mod_CFLAGS): Likewise.
9845 (cpio_mod_LDFLAGS): Likewise.
9846
9847 * fs/cpio.c: New file.
9848
9849 * conf/i386-pc.rmk (grub_emu_SOURCES): Add cpio.c.
9850
9851 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
9852
9853 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
9854
9855 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
9856
9857 2007-12-25 Robert Millan <rmh@aybabtu.com>
9858
9859 * include/grub/term.h (struct grub_term): Add `getcolor' function.
9860 (grub_getcolor): New function.
9861
9862 * kern/term.c (grub_getcolor): New function.
9863 * normal/menu.c (GRUB_COLOR_MENU_NORMAL): New macro.
9864 (GRUB_COLOR_MENU_HIGHLIGHT): New macro.
9865 (print_entry): Set normal and highlight colors to
9866 `GRUB_COLOR_MENU_NORMAL' and `GRUB_COLOR_MENU_HIGHLIGHT',
9867 respectively, before printing and restore them to old
9868 values afterwards.
9869 (grub_menu_init_page): Likewise. Fill an additional colored space
9870 that would otherwise be left blank.
9871
9872 * term/efi/console.c (grub_console_getcolor): New function.
9873 (struct grub_console_term.getcolor): New variable.
9874 * term/i386/pc/console.c (grub_console_getcolor): New function.
9875 (struct grub_console_term.getcolor): New variable.
9876 * term/ieee1275/ofconsole.c (grub_ofconsole_getcolor): New function.
9877 (struct grub_console_term.getcolor): New variable.
9878
9879 * term/i386/pc/serial.c (grub_serial_setcolor): Remove function.
9880 (struct grub_console_term.setcolor): Remove variable.
9881 * term/i386/pc/vesafb.c (grub_virtual_screen_setcolor): Remove function.
9882 (struct grub_console_term.setcolor): Remove variable.
9883 * term/i386/pc/vga.c (grub_vga_setcolor): Remove function.
9884 (struct grub_console_term.setcolor): Remove variable.
9885 * term/gfxterm.c (grub_virtual_screen_setcolor): Remove function.
9886 (struct grub_console_term.setcolor): Remove variable.
9887
9888 2007-12-25 Robert Millan <rmh@aybabtu.com>
9889
9890 * configure.ac: Search for possible unifont.hex locations, and
9891 define UNIFONT_HEX if found.
9892
9893 * Makefile.in (UNIFONT_HEX): Define variable.
9894 (DATA): Rename to ...
9895 (PKGLIB): ... this. Update all users.
9896 (PKGDATA): New variable.
9897 (pkgdata_IMAGES): Rename to ...
9898 (pkglib_IMAGES): ... this. Update all users.
9899 (pkgdata_MODULES): Rename to ...
9900 (pkglib_MODULES): ... this. Update all users.
9901 (pkgdata_PROGRAMS): Rename to ...
9902 (pkglib_PROGRAMS): ... this. Update all users.
9903 (pkgdata_DATA): Rename to ...
9904 (pkglib_DATA): ... this. Update all users.
9905 (CLEANFILES): Redefine to `$(pkglib_DATA) $(pkgdata_DATA)'.
9906 (unicode.pff, ascii.pff): New rules.
9907 (all-local): Add `$(PKGDATA)' dependency.
9908 (install-local): Process `$(PKGDATA)'.
9909
9910 * util/update-grub_lib.in (font_path): Search for *.pff files in
9911 a few more locations, including `${pkgdata}'.
9912
9913 2007-12-23 Robert Millan <rmh@aybabtu.com>
9914
9915 Patch from Bean <bean123ch@gmail.com>:
9916 * disk/loopback.c (grub_loopback_read): Add missing bit shift to
9917 `size'.
9918
9919 2007-12-21 Bean <bean123ch@gmail.com>
9920
9921 * conf/common.rmk (pkgdata_MODULES): Add ntfscomp.mod.
9922 (ntfscomp_mod_SOURCES): New variable.
9923 (ntfscomp_mod_CFLAGS): Likewise.
9924 (ntfscomp_mod_LDFLAGS): Likewise.
9925
9926 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfscomp.c.
9927 (grub_probe_SOURCES): Likewise.
9928 (grub_emu_SOURCES): Likewise.
9929
9930 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
9931 (grub_emu_SOURCES): Likewise.
9932
9933 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
9934 (grub_emu_SOURCES): Likewise.
9935
9936 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
9937 (grub_emu_SOURCES): Likewise.
9938
9939 * fs/ntfs.c (grub_ntfscomp_func): New variable.
9940 (read_run_list): Renamed to grub_ntfs_read_run_list.
9941 (decomp_nextvcn): Moved to ntfscomp.c.
9942 (decomp_getch): Likewise.
9943 (decomp_get16): Likewise.
9944 (decomp_block): Likewise.
9945 (read_block): Likewise.
9946 (read_data): Partially moved to ntfscomp.c.
9947 (fixup): Change unsigned to grub_uint16_t.
9948 (read_mft): Change unsigned long to grub_uint32_t.
9949 (read_attr): Likewise.
9950 (read_data): Likewise.
9951 (read_run_data): Likewise.
9952 (read_run_list): Likewise.
9953 (read_mft): Likewise.
9954
9955 * fs/ntfscomp.c: New file.
9956
9957 * include/grub/ntfs.h: New file.
9958
9959 2007-12-16 Robert Millan <rmh@aybabtu.com>
9960
9961 * util/grub-mkdevicemap.c (make_device_map): Iterate up to 20 for
9962 IDE disk check, since Linux is known to support 20 IDE disks.
9963 Reported by Colin Watson.
9964
9965 2007-12-15 Bean <bean123ch@gmail.com>
9966
9967 * conf/i386-pc.rmk (pkgdata_IMAGES): Add lnxboot.img.
9968 (lnxboot_img_SOURCES): New variable.
9969 (lnxboot_img_ASFLAGS): Likewise.
9970 (lnxboot_img_LDFLAGS): Likewise.
9971
9972 * boot/i386/pc/lnxboot.S: New file.
9973
9974 2007-11-24 Pavel Roskin <proski@gnu.org>
9975
9976 * configure.ac: Test if '--build-id=none' is supported by the
9977 linker. If yes, add it to TARGET_LDFLAGS. Build ID causes
9978 objcopy to generate incorrect binary files (binutils
9979 2.17.50.0.18-1 as shipped by Fedora 8).
9980 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Use LDFLAGS when
9981 linking, so that build ID doesn't break the test.
9982
9983 2007-11-24 Pavel Roskin <proski@gnu.org>
9984
9985 * include/grub/i386/time.h: use "void" in the argument list
9986 of grub_cpu_idle().
9987 * include/grub/powerpc/time.h: Likewise.
9988 * include/grub/sparc64/time.h: Likewise.
9989
9990 2007-11-18 Christian Franke <franke@computer.org>
9991
9992 * util/console.c (grub_ncurses_getkey): Change curses KEY_* mapping,
9993 now return control chars instead of GRUB_CONSOLE_KEY_* constants.
9994 This fixes the problem that function keys did not work in grub-emu.
9995
9996 2007-11-18 Christian Franke <franke@computer.org>
9997
9998 * disk/host.c (grub_host_open): Remove attribute unused from
9999 name parameter. Add check for "host". This fixes the problem
10000 that grub-emu does not find partitions.
10001
10002 2007-11-18 Christian Franke <franke@computer.org>
10003
10004 * util/hostfs.c (is_dir): New function.
10005 (grub_hostfs_dir): Handle missing dirent.d_type case.
10006 (grub_hostfs_read): Add missing fseek().
10007 (grub_hostfs_label): Clear label pointer. This fixes a crash
10008 of grub-emu on "ls (host)".
10009
10010 2007-11-18 Christian Franke <franke@computer.org>
10011
10012 * include/grub/i386/pc/init.h (struct grub_machine_mmap_entry):
10013 Add attribute packed, gcc 3.4.4 on Cygwin aligns this
10014 to 64 bit boundary by default.
10015
10016 2007-11-18 Bean <bean123ch@gmail.com>
10017
10018 * conf/common.rmk (pkgdata_MODULES): Add hexdump.mod.
10019 (hexdump_mod_SOURCES): New variable.
10020 (hexdump_mod_CFLAGS): Likewise.
10021 (hexdump_mod_LDFLAGS): Likewise.
10022
10023 * conf/i386-pc.rmk (grub_emu_SOURCES): Add command/hexdump.c.
10024
10025 * conf/i386-efi.rmk (grub_emu_SOURCES): Add command/hexdump.c.
10026
10027 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add command/hexdump.c.
10028
10029 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add command/hexdump.c.
10030
10031 * include/grub/hexdump.h: New file.
10032
10033 * commands/hexdump.c: New file.
10034
10035 2007-11-10 Robert Millan <rmh@aybabtu.com>
10036
10037 * commands/i386/pc/play.c (beep_off): Switch order of arguments
10038 in grub_outb() calls.
10039 (beep_on): Likewise.
10040
10041 2007-11-10 Christian Franke <franke@computer.org>
10042
10043 * normal/menu.c (run_menu): Check for empty menu to avoid crash.
10044 (grub_menu_run): Likewise.
10045
10046 2007-11-10 Robert Millan <rmh@aybabtu.com>
10047
10048 * include/grub/i386/efi/machine.h: New file.
10049 * include/grub/i386/linuxbios/machine.h: Likewise.
10050 * include/grub/i386/pc/machine.h: Likewise.
10051 * include/grub/powerpc/ieee1275/machine.h: Likewise.
10052 * include/grub/sparc64/ieee1275/machine.h: Likewise.
10053
10054 * term/i386/pc/serial.c: Include <grub/machine/machine.h>.
10055 (serial_hw_io_addr): New variable.
10056 (serial_hw_get_port): Obtain port address from `serial_hw_io_addr'
10057 instead of `(unsigned short *) 0x400'.
10058
10059 2007-11-10 Bean <bean123ch@gmail.com>
10060
10061 * fs/ntfs.c (read_block): Fix a bug caused by adjacent blocks.
10062
10063 2007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
10064
10065 * conf/i386-pc.rmk (pkgdata_MODULES): Added vga.mod.
10066 (vga_mod_SOURCES): Added.
10067 (vga_mod_CFLAGS): Likewise.
10068 (vga_mod_LDFLAGS): Likewise.
10069
10070 * term/i386/pc/vga.c (get_map_mask): Switch order of arguments in
10071 grub_outb() calls.
10072 (set_map_mask): Likewise.
10073 (set_read_map): Likewise.
10074 (set_read_address): Likewise.
10075 (vga_font): Removed variable.
10076 (get_vga_glyph): Removed function.
10077 (invalidate_char): Likewise.
10078 (write_char): Changed to use grub_font_get_glyph() for font
10079 information.
10080 (grub_vga_putchar): Likewise.
10081 (grub_vga_getcharwidth): Likewise.
10082
10083 2007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
10084
10085 * conf/i386-pc.rmk (boot_img_LDFLAGS): Use COMMON_LDFLAGS for target
10086 flags.
10087 (pxeboot_img_LDFLAGS): Likewise.
10088 (diskboot_img_LDFLAGS): Likewise.
10089 (kernel_img_LDFLAGS): Likewise.
10090
10091 2007-11-06 Robert Millan <rmh@aybabtu.com>
10092
10093 * term/i386/pc/serial.c (serial_hw_put): Switch order of arguments
10094 in grub_outb() calls.
10095 (serial_hw_init): Likewise.
10096
10097 2007-11-05 Robert Millan <rmh@aybabtu.com>
10098
10099 * util/update-grub.in: Allow files in ${update_grub_dir} to contain
10100 spaces. Skip non-regular files.
10101
10102 2007-11-05 Robert Millan <rmh@aybabtu.com>
10103
10104 * kern/disk.c (grub_disk_firmware_fini)
10105 (grub_disk_firmware_is_tainted): New variables.
10106
10107 * include/grub/disk.h (grub_disk_firmware_fini)
10108 (grub_disk_firmware_is_tainted): Likewise.
10109
10110 * disk/i386/pc/biosdisk.c (GRUB_MOD_FINI(biosdisk)): Moved from here ...
10111 (grub_disk_biosdisk_fini): ... to here.
10112 (GRUB_MOD_FINI(biosdisk)): Implement using grub_disk_biosdisk_fini().
10113 (GRUB_MOD_INIT(biosdisk)): Abort when `grub_disk_firmware_is_tainted'
10114 is set. Register grub_disk_biosdisk_fini() in
10115 `grub_disk_firmware_fini'.
10116
10117 * disk/ata.c: Remove `<grub/machine/biosdisk.h>'.
10118 (GRUB_MOD_INIT(ata)): Remove grub_biosdisk_fini() call.
10119 Use `grub_disk_firmware_is_tainted' and `grub_disk_firmware_fini'
10120 to finish existing firmware disk interface.
10121
10122 * conf/i386-linuxbios.rmk (pkgdata_MODULES): Add `ata.mod'.
10123 (ata_mod_SOURCES): New variable.
10124 (ata_mod_CFLAGS): Likewise.
10125 (ata_mod_LDFLAGS): Likewise.
10126
10127 2007-11-05 Robert Millan <rmh@aybabtu.com>
10128
10129 * disk/ata.c: Remove `<grub/machine/time.h>'. Include `<grub/time.h>'.
10130 (grub_ata_wait): Reimplement using grub_millisleep().
10131
10132 * include/grub/misc.h (grub_div_roundup): Fix parenthesization.
10133 * include/grub/i386/time.h (grub_cpu_idle): Disable `hlt' instruction.
10134
10135 2007-11-03 Marco Gerards <marco@gnu.org>
10136
10137 * term/i386/pc/vga_text.c: Include <grub/cpu/io.h>.
10138 (CRTC_ADDR_PORT): New macro.
10139 (CRTC_DATA_PORT): Likewise.
10140 (CRTC_CURSOR): Likewise.
10141 (CRTC_CURSOR_ADDR_HIGH): Likewise.
10142 (CRTC_CURSOR_ADDR_LOW): Likewise.
10143 (update_cursor): New function.
10144 (grub_console_real_putchar): Call `update_cursor'.
10145 (grub_console_gotoxy): Likewise.
10146 (grub_console_cls): Set the default color when clearing the
10147 screen.
10148 (grub_console_setcursor): Implemented.
10149
10150 2007-11-03 Marco Gerards <marco@gnu.org>
10151
10152 * disk/ata.c (grub_ata_pio_read): Don't wait for the command to
10153 become activate.
10154 (grub_ata_pio_write): Likewise.
10155
10156 (grub_atapi_identify): Wait after issuing an ATA command.
10157 (grub_atapi_packet): Likewise.
10158 (grub_ata_identify): Likewise.
10159 (grub_ata_readwrite): Likewise.
10160
10161 2007-11-03 Marco Gerards <marco@gnu.org>
10162
10163 * disk/ata.c (grub_ata_pio_read): Detect and return the error code.
10164 (grub_ata_pio_write): Likewise.
10165 (grub_ata_readwrite): Use `grub_error', instead of
10166 returning `grub_errno'.
10167
10168 2007-11-03 Marco Gerards <marco@gnu.org>
10169
10170 * disk/ata.c (grub_ata_readwrite): Call grub_ata_pio_read and
10171 grub_ata_pio_write once for every single sector, instead of for
10172 multiple sectors.
10173
10174 2007-10-31 Robert Millan <rmh@aybabtu.com>
10175
10176 * configure.ac: Add `i386-linuxbios' to the list of supported targets.
10177
10178 * conf/i386-linuxbios.rmk: New file.
10179
10180 * kern/i386/pc/hardware.c: Likewise.
10181 * term/i386/pc/at_keyboard.c: Likewise.
10182 * term/i386/pc/vga_text.c: Likewise.
10183
10184 * include/grub/i386/linuxbios/boot.h: Likewise.
10185 * include/grub/i386/linuxbios/console.h: Likewise.
10186 * include/grub/i386/linuxbios/init.h: Likewise.
10187 * include/grub/i386/linuxbios/kernel.h: Likewise.
10188 * include/grub/i386/linuxbios/loader.h: Likewise.
10189 * include/grub/i386/linuxbios/memory.h: Likewise.
10190 * include/grub/i386/linuxbios/serial.h: Likewise.
10191 * include/grub/i386/linuxbios/time.h: Likewise.
10192
10193 * kern/i386/linuxbios/init.c: Likewise.
10194 * kern/i386/linuxbios/startup.S: Likewise.
10195 * kern/i386/linuxbios/table.c: Likewise.
10196
10197 2007-10-31 Marco Gerards <marco@gnu.org>
10198
10199 * conf/i386-pc.rmk (pkgdata_MODULES): Add `ata.mod'.
10200 (ata_mod_SOURCES): New variable.
10201 (ata_mod_CFLAGS): Likewise.
10202 (ata_mod_LDFLAGS): Likewise.
10203
10204 * disk/ata.c: New file.
10205
10206 * include/grub/disk.h (grub_disk_dev_id): Add
10207 `GRUB_DISK_DEV_ATA_ID'.
10208
10209 2007-10-31 Robert Millan <rmh@aybabtu.com>
10210
10211 * include/grub/i386/pc/init.h (grub_lower_mem): Moved from here ...
10212 * include/grub/i386/pc/memory.h (grub_lower_mem): ... to here.
10213
10214 * include/grub/i386/pc/init.h (grub_upper_mem): Moved from here ...
10215 * include/grub/i386/pc/memory.h (grub_upper_mem): ... to here.
10216
10217 * include/grub/i386/pc/memory.h: Include `<grub/symbol.h>' and
10218 `<grub/types.h>'.
10219
10220 * loader/i386/pc/multiboot.c: Include `<grub/machine/memory.h>'.
10221
10222 2007-10-27 Robert Millan <rmh@aybabtu.com>
10223
10224 * include/grub/types.h (ULONG_MAX): Define macro.
10225
10226 2007-10-22 Robert Millan <rmh@aybabtu.com>
10227
10228 * kern/i386/pc/startup.S: Remove `"kern/i386/realmode.S"'. Include
10229 `"../realmode.S"'.
10230 Remove `"kern/i386/loader.S"'. Include `"../loader.S"'.
10231
10232 2007-10-22 Robert Millan <rmh@aybabtu.com>
10233
10234 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove `disk/i386/pc/biosdisk.c'.
10235 (pkgdata_MODULES): Add `biosdisk.mod'.
10236 (biosdisk_mod_SOURCES, biosdisk_mod_CFLAGS, biosdisk_mod_LDFLAGS): New
10237 variables.
10238
10239 * disk/i386/pc/biosdisk.c: Include `<grub/dl.h>'.
10240 (grub_biosdisk_init): Replace with ...
10241 (GRUB_MOD_INIT(biosdisk)): ... this.
10242 (grub_biosdisk_fini): Replace with ...
10243 (GRUB_MOD_FINI(biosdisk)): ... this.
10244
10245 * kern/i386/pc/init.c: Remove `<grub/machine/biosdisk.h>'.
10246 (grub_machine_init): Remove call to grub_biosdisk_init().
10247 (grub_machine_fini): Remove call to grub_machine_fini().
10248
10249 * util/i386/pc/grub-install.in (modules): Add `biosdisk'.
10250
10251 2007-10-22 Robert Millan <rmh@aybabtu.com>
10252
10253 * include/grub/time.h: New file.
10254 * include/grub/i386/time.h: Likewise.
10255 * include/grub/powerpc/time.h: Likewise.
10256 * include/grub/sparc64/time.h: Likewise.
10257
10258 * include/grub/i386/pc/time.h (KERNEL_TIME_HEADER): Rename all
10259 instances to ...
10260 (KERNEL_MACHINE_TIME_HEADER): ... this.
10261 * include/grub/powerpc/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
10262 instances to ...
10263 (KERNEL_MACHINE_TIME_HEADER): ... this.
10264 * include/grub/sparc64/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
10265 instances to ...
10266 (KERNEL_MACHINE_TIME_HEADER): ... this.
10267
10268 * kern/i386/efi/init.c: Include `<grub/time.h>'.
10269 (grub_millisleep): New function.
10270 * kern/i386/pc/init.c: Include `<grub/time.h>'.
10271 (grub_millisleep): New function.
10272 * kern/powerpc/ieee1275/init.c: Include `<grub/time.h>'.
10273 Remove `grub/machine/time.h' include.
10274 (grub_millisleep): New function.
10275 * kern/sparc64/ieee1275/init.c: Include `<grub/time.h>'.
10276 Remove `grub/machine/time.h' include.
10277 (grub_millisleep): New function.
10278
10279 * include/grub/misc.h (grub_div_roundup): New function.
10280
10281 * kern/misc.c: Include `<grub/time.h>'.
10282 (grub_millisleep_generic): New function.
10283
10284 * conf/i386-efi.rmk (kernel_mod_HEADERS): Remove `i386/efi/time.h'.
10285 Add `time.h'.
10286 * conf/i386-pc.rmk (kernel_img_HEADERS): Remove `machine/time.h'.
10287 Add `time.h'.
10288 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Remove
10289 `machine/time.h'. Add `time.h'.
10290 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
10291
10292 2007-10-21 Robert Millan <rmh@aybabtu.com>
10293
10294 * include/grub/misc.h (grub_max): New function.
10295
10296 2007-10-21 Robert Millan <rmh@aybabtu.com>
10297
10298 * util/misc.c (grub_util_info): Call fflush() before returning.
10299
10300 2007-10-20 Robert Millan <rmh@aybabtu.com>
10301
10302 * genmk.rb (Image): Copy `extra_flags' from here ...
10303 (PModule): ... to here. Use it in `#{obj}: #{src}' rule.
10304
10305 * commands/i386/cpuid.c (grub_cmd_cpuid): Add __attribute__ ((unused))
10306 to `argc' and `args' arguments.
10307
10308 2007-10-17 Robert Millan <rmh@aybabtu.com>
10309
10310 * kern/i386/loader.S: New file.
10311
10312 * kern/i386/pc/startup.S (grub_linux_prot_size): Moved from here ...
10313 * kern/i386/loader.S (grub_linux_prot_size)... to here.
10314 * kern/i386/pc/startup.S (grub_linux_tmp_addr): Moved from here ...
10315 * kern/i386/loader.S (grub_linux_tmp_addr)... to here.
10316 * kern/i386/pc/startup.S (grub_linux_real_addr): Moved from here ...
10317 * kern/i386/loader.S (grub_linux_real_addr)... to here.
10318 * kern/i386/pc/startup.S (grub_linux_boot_zimage): Moved from here ...
10319 * kern/i386/loader.S (grub_linux_boot_zimage)... to here.
10320 * kern/i386/pc/startup.S (grub_linux_boot_bzimage): Moved from here ...
10321 * kern/i386/loader.S (grub_linux_boot_bzimage)... to here.
10322 * kern/i386/pc/startup.S (grub_multiboot_real_boot): Moved from here ...
10323 * kern/i386/loader.S (grub_multiboot_real_boot)... to here.
10324 * kern/i386/pc/startup.S (grub_multiboot2_real_boot): Moved from here ...
10325 * kern/i386/loader.S (grub_multiboot2_real_boot)... to here.
10326
10327 * kern/i386/realmode.S: New file.
10328
10329 * kern/i386/pc/startup.S (protstack): Moved from here ...
10330 * kern/i386/realmode.S (protstack)... to here.
10331 * kern/i386/pc/startup.S (gdt): Moved from here ...
10332 * kern/i386/realmode.S (gdt)... to here.
10333 * kern/i386/pc/startup.S (prot_to_real): Moved from here ...
10334 * kern/i386/realmode.S (prot_to_real)... to here.
10335
10336 * kern/i386/pc/startup.S: Include `kern/i386/loader.S' and
10337 `kern/i386/realmode.S'.
10338
10339 2007-10-17 Robert Millan <rmh@aybabtu.com>
10340
10341 * include/grub/i386/loader.h: New file.
10342
10343 * include/grub/i386/pc/loader.h (grub_linux_prot_size)
10344 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
10345 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
10346 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
10347 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): Moved from here ...
10348 * include/grub/i386/loader.h (grub_linux_prot_size)
10349 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
10350 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
10351 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
10352 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): ... to here.
10353
10354 * include/grub/i386/pc/loader.h: Include `grub/cpu/loader.h'.
10355
10356 2007-10-15 Robert Millan <rmh@aybabtu.com>
10357
10358 * normal/misc.c (grub_normal_print_device_info): Do not probe for
10359 filesystem when dev->disk is unset.
10360 Do probe for filesystem even when dev->disk->has_partitions is set.
10361 In case a filesystem is found, always report it.
10362 In case it isn't, if dev->disk->has_partitions is set, report that
10363 a partition table was found instead of reporting that no filesystem
10364 could be identified.
10365
10366 2007-10-12 Robert Millan <rmh@aybabtu.com>
10367
10368 * conf/powerpc-ieee1275.rmk (grub_mkimage_SOURCES): Replace reference
10369 to util/powerpc/ieee1275/grub-mkimage.c with util/elf/grub-mkimage.c.
10370
10371 * include/grub/types.h (grub_host_to_target16): New macro.
10372 (grub_host_to_target32): Likewise.
10373 (grub_host_to_target64): Likewise.
10374 (grub_target_to_host16): Likewise.
10375 (grub_target_to_host32): Likewise.
10376 (grub_target_to_host64): Likewise.
10377
10378 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
10379 Renamed from to ...
10380 (GRUB_MOD_ALIGN): ...this. Update all users.
10381
10382 * util/elf/grub-mkimage.c (load_note): Replace grub_cpu_to_be32 with
10383 grub_host_to_target32.
10384 Replace grub_be_to_cpu32 with grub_target_to_host32.
10385 (load_modules): Likewise.
10386 (add_segments): Replace grub_be_to_cpu16 with grub_target_to_host16.
10387 Replace grub_be_to_cpu32 with grub_target_to_host32.
10388 Replace grub_cpu_to_be16 with grub_host_to_target16.
10389 Replace grub_cpu_to_be32 grub_host_to_target32.
10390
10391 2007-10-12 Robert Millan <rmh@aybabtu.com>
10392
10393 * util/powerpc/ieee1275/grub-mkimage.c: Moved to ...
10394 * util/elf/grub-mkimage.c: ... here.
10395
10396 * DISTLIST: Add `util/elf/grub-mkimage.c'. Remove
10397 `util/powerpc/ieee1275/grub-mkimage.c'.
10398
10399 2007-10-07 Robert Millan <rmh@aybabtu.com>
10400
10401 * kern/powerpc/ieee1275/init.c: Rename HEAP_LIMIT to HEAP_MAX_ADDR,
10402 and make it easier to figure out.
10403 Add HEAP_MIN_SIZE and HEAP_MAX_ADDR definitions.
10404 (grub_claim_heap): Use HEAP_MAX_ADDR rather than taking a parameter.
10405 Do not avoid claiming a region above HEAP_MAX_ADDR if that would
10406 leave us with less than HEAP_MIN_SIZE total heap.
10407 Avoid our total amount of heap to surpass HEAP_MAX_SIZE.
10408
10409 2007-10-03 Robert Millan <rmh@aybabtu.com>
10410
10411 * include/grub/i386/io.h: New file.
10412 * commands/i386/pc/play.c (inb): Removed.
10413 (outb): Removed.
10414 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
10415 with grub_outb().
10416 * term/i386/pc/serial.c (inb): Removed.
10417 (outb): Removed.
10418 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
10419 with grub_outb().
10420 * term/i386/pc/vga.c (inb): Removed.
10421 (outb): Removed.
10422 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
10423 with grub_outb().
10424
10425 2007-10-02 Robert Millan <rmh@aybabtu.com>
10426
10427 * conf/i386-efi.rmk (grub_emu_SOURCES): Add util/hostfs.c.
10428 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
10429 Reported by Marcin Kurek.
10430
10431 2007-09-07 Robert Millan <rmh@aybabtu.com>
10432
10433 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_test_flag): Detect
10434 SmartFirmware version updates (as released by Sven Luther), and avoid
10435 setting GRUB_IEEE1275_FLAG_NO_PARTITION_0 or
10436 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS unless the running version is
10437 known broken.
10438
10439 2007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
10440
10441 From Hitoshi Ozeki:
10442 * kern/i386/pc/init.c (compact_mem_regions): Decrease NUM_REGIONS
10443 when merging two regions.
10444
10445 2007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
10446
10447 * kern/rescue.c (grub_enter_rescue_mode): Free ARGS.
10448 * normal/completion.c (grub_normal_do_completion): Likewise.
10449 Reported by Hitoshi Ozeki.
10450
10451 2007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
10452
10453 Do not use devices at boot in chainloading.
10454
10455 * loader/i386/pc/chainloader.c (boot_drive): New variable.
10456 (boot_part_addr): Likewise.
10457 (grub_chainloader_boot): Simply call grub_chainloader_real_boot
10458 with BOOT_DRIVE and BOOT_PART_ADDR.
10459 (grub_chainloader_cmd): Set BOOT_DRIVE and BOOT_PART_ADDR.
10460 Reported by Hitoshi Ozeki <h-ozeki@ck2.so-net.ne.jp>.
10461
10462 2007-08-29 Robert Millan <rmh@aybabtu.com>
10463
10464 Patch from Simon Peter <dn.tlp@gmx.net>:
10465 * genmk.rb (Utility): Append $(#{src}_DEPENDENCIES) to #{obj} targets.
10466 * conf/i386-pc.rmk: Replace grub-probe_DEPENDENCIES with
10467 util/grub-probe.c_DEPENDENCIES. Replace grub-setup_DEPENDENCIES with
10468 util/i386/pc/grub-setup.c_DEPENDENCIES.
10469 * conf/i386-efi.rmk: Replace grub-probe_DEPENDENCIES with
10470 util/grub-probe.c_DEPENDENCIES.
10471 * conf/powerpc-ieee1275.rmk: Likewise.
10472
10473 2007-08-28 Robert Millan <rmh@aybabtu.com>
10474
10475 * util/i386/get_disk_name.c: New. Implement grub_util_get_disk_name()
10476 to tell grub-mkdevicemap how to name devices.
10477 * util/ieee1275/get_disk_name.c: Likewise (using "ofpathname -a"
10478 feature).
10479
10480 * conf/i386-efi.rmk (grub_mkdevicemap_SOURCES): Add
10481 util/i386/get_disk_name.c.
10482 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Likewise.
10483 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Add
10484 util/ieee1275/get_disk_name.c.
10485
10486 * include/grub/util/misc.h: grub_util_get_disk_name() declaration.
10487
10488 * DISTLIST: Add util/i386/get_disk_name.c and
10489 util/ieee1275/get_disk_name.c.
10490
10491 * util/grub-mkdevicemap.c: Replace device naming logic with
10492 grub_util_get_disk_name() calls.
10493
10494 2007-08-20 Robert Millan <rmh@aybabtu.com>
10495
10496 * normal/menu.c (run_menu): Refer to seconds as "s" not "seconds"
10497 (so that it works for both plural and singular quantities).
10498
10499 2007-08-05 Robert Millan <rmh@aybabtu.com>
10500
10501 * util/grub.d/10_linux.in (test_gt): Strip out vmlinu[xz]- prefix
10502 so that [xz] isn't taken into account when determining order.
10503
10504 2007-08-02 Marco Gerards <marco@gnu.org>
10505
10506 * DISTLIST: Add `disk/host.c', `fs/ntfs.c', `include/multiboot.h',
10507 `include/multiboot2.h', `include/grub/elfload.h',
10508 `include/multiboot.h', `include/grub/multiboot.h',
10509 `include/grub/multiboot_loader.h', `include/grub/multiboot2.h',
10510 `include/grub/i386/pc/biosdisk.h', `include/grub/util/biosdisk.h',
10511 `kern/elf.c', `loader/multiboot_loader.c',
10512 `loader/multiboot_loader_normal.c', `loader/multiboot2.c',
10513 `loader/i386/pc/multiboot2.c',
10514 `loader/powerpc/ieee1275/multiboot2.c', `util/hostfs.c' and
10515 `util/i386/pc/grub-mkrescue.in'. Remove
10516 `include/grub/biosdisk.h', `include/grub/i386/pc/multiboot.h',
10517 `include/grub/i386/pc/util/biosdisk.h' and
10518 `include/grub/powerpc/ieee1275/multiboot.h'.
10519
10520 2007-08-02 Bean <bean123ch@gmail.com>
10521
10522 * conf/common.rmk (pkgdata_MODULES): Add ntfs.mod.
10523 (ntfs_mod_SOURCES): New variable.
10524 (ntfs_mod_CFLAGS): Likewise.
10525 (ntfs_mod_LDFLAGS): Likewise.
10526
10527 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfs.c.
10528 (grub_probe_SOURCES): Likewise.
10529 (grub_emu_SOURCES): Likewise.
10530
10531 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
10532 (grub_emu_SOURCES): Likewise.
10533
10534 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
10535 (grub_emu_SOURCES): Likewise.
10536
10537 * conf/misc.c (grub_utf16_to_utf8): Fix unicode conversion bug.
10538
10539 * fs/ntfs.c: New file.
10540
10541 2007-08-02 Bean <bean123ch@gmail.com>
10542
10543 * disk.h (grub_disk): Use NESTED_FUNC_ATTR.
10544
10545 * file.h (grub_file): Likewise.
10546
10547 * fshelp.h (grub_fshelp_read_file): Likewise.
10548
10549 * util/i386/pc/grub-setup.c (setup): Likewise.
10550 (save_first_sector): Likewise.
10551 (save_blocklists): Likewise.
10552
10553 * fs/affs.c (grub_affs_read_file): Likewise.
10554
10555 * fs/ext2.c (grub_ext2_read_file): Likewise.
10556
10557 * fs/fat.c (grub_fat_read_data): Likewise.
10558
10559 * fs/fshelp.c (grub_fshelp_read_file): Likewise.
10560
10561 * fs/hfs.c (grub_hfs_read_file): Likewise.
10562
10563 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
10564
10565 * fs/jfs.c (grub_jfs_read_file): Likewise.
10566
10567 * fs/minix.c (grub_minix_read_file): Likewise.
10568
10569 * fs/sfs.c (grub_sfs_read_file): Likewise.
10570
10571 * fs/ufs.c (grub_ufs_read_file): Likewise.
10572
10573 * fs/xfs.c (grub_xfs_read_file): Likewise.
10574
10575 * command/blocklist.c (read_blocklist): Likewise.
10576 (print_blocklist): Likewise.
10577
10578 2007-08-02 Marco Gerards <marco@gnu.org>
10579
10580 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/host.c' and
10581 `util/hostfs.c'.
10582
10583 * disk/host.c: New file.
10584
10585 * util/hostfs.c: Likewise.
10586
10587 * fs/hfsplus.c (grub_hfsplus_mount): When reading out of disk,
10588 return `GRUB_ERR_BAD_FS'.
10589 * fs/sfs.c (grub_sfs_mount): Likewise.
10590 * fs/xfs.c (grub_xfs_mount): Likewise.
10591
10592 * include/grub/disk.h (enum grub_disk_dev_id): Add
10593 `GRUB_DISK_DEVICE_HOST_ID'.
10594
10595 * util/grub-emu.c (main): Initialize and de-initialize hostfs.
10596
10597 2007-07-24 Jerone Young <jerone@gmail.com>
10598
10599 * conf/i386-pc.rmk: Add Multiboot loader and multiboot 2 to multiboot
10600 modules for compilation.
10601 * conf/powerpc-ieee1275.rmk: Likewise.
10602
10603 * include/multiboot.h: Move multiboot definitions to one file. Rename
10604 many definitions to not get grub specific.
10605 * include/multiboot2.h: Create header with multiboot 2 definitions.
10606 * include/grub/multiboot.h: Header for grub specific function
10607 prototypes and definitions.
10608 * include/grub/multiboot2.h: Likewise.
10609 * include/grub/multiboot_loader.h: Likewise.
10610 * include/grub/i386/pc/multiboot.h: Removed.
10611 * include/grub/powerpc/ieee1275/multiboot.h: Removed.
10612
10613 * loader/multiboot_loader.c: Created to act as a proxy for multiboot 1
10614 and 2 to allow for one multiboot and module commands.
10615 * loader/multiboot2.c: Add multiboot2 functionality.
10616 * loader/i386/pc/multiboot.c: Modify for new multiboot header location
10617 and definition names.
10618 * loader/i386/pc/multiboot2.c: Created to add i386 specific multiboot
10619 2 functions.
10620 * loader/powerpc/ieee1275/multiboot2.c: Created to add powerpc
10621 ieee1275 specific multiboot2 code.
10622
10623 * kern/i386/pc/startup.S: Change headers and definition names for
10624 multiboot. Add function grub_multiboot2_real_boot for multiboot 2.
10625
10626 2007-07-22 Robert Millan <rmh@aybabtu.com>
10627
10628 * geninitheader.sh: Process file specified in first parameter rather
10629 than hardcoding grub_modules_init.lst.
10630 * geninit.sh: Likewise. Also, construct header name dynamically rather
10631 than hardcoding grub_modules_init.h.
10632
10633 * conf/common.rmk: Rename grub_modules_init.[ch] files associated with
10634 grub-emu to grub_emu_init.[ch]. Add rules to build analogous
10635 grub_probe_init.[ch] and grub_setup_init.[ch].
10636
10637 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Replace
10638 grub_modules_init.h with grub_emu_init.h.
10639 (grub_probe_DEPENDENCIES, grub_probe_SOURCES): Add new
10640 grub_probe_init.[ch] files.
10641 * conf/i386-efi.rmk: Likewise.
10642 * conf/i386-pc.rmk: Likewise.
10643 (grub_setup_DEPENDENCIES, grub_setup_SOURCES): Add new
10644 grub_setup_init.[ch] files.
10645
10646 * util/grub-emu.c: Replace grub_modules_init.h with grub_emu_init.h.
10647 * util/grub-probe.c: Include grub_probe_init.h. Use grub_init_all()
10648 to initialize modules rather than a list of hardcoded functions.
10649 * util/i386/pc/grub-setup.c: Include grub_setup_init.h. Use
10650 grub_init_all() to initialize modules rather than a list of hardcoded
10651 functions.
10652
10653 2007-07-22 Robert Millan <rmh@aybabtu.com>
10654
10655 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set
10656 GRUB_IEEE1275_FLAG_NO_PARTITION_0 flag when running on SmartFirmware.
10657
10658 2007-07-22 Robert Millan <rmh@aybabtu.com>
10659
10660 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
10661 GRUB_IEEE1275_FLAG_BROKEN_OUTPUT flag.
10662 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set this
10663 flag when running on SmartFirmware.
10664 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid running
10665 "output-device output" command when GRUB_IEEE1275_FLAG_BROKEN_OUTPUT
10666 was set.
10667
10668 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
10669 Increase partno when GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS flag is set,
10670 rather than decreasing it.
10671
10672 * util/i386/pc/grub-setup.c (setup): When embedding is required, but
10673 there's not enough space to do it, fail in the same way as when it
10674 can't be done because there are no partitions.
10675
10676 * util/powerpc/ieee1275/grub-install.in: Improve error message shown
10677 when nvsetenv failed.
10678
10679 2007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
10680
10681 * conf/i386-pc.rmk (CLEANFILES): Removed for grub-mkrescue,
10682 because this rule is automatically generated.
10683 (grub-mkrescue): Removed for the same reason as above.
10684
10685 2007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
10686
10687 Migrate to GNU General Public License Version 3.
10688
10689 * COPYING: Replaced with the plain text version of GPLv3.
10690
10691 * config.guess: Updated from gnulib.
10692 * config.sub: Likewise.
10693
10694 * geninit.sh: Output a GPLv3 copyright notice.
10695 * geninitheader.sh: Likewise.
10696 * genmodsrc.sh: Likewise.
10697 * gensymlist.sh.in: Likewise.
10698
10699 * boot/i386/pc/boot.S: Upgraded to GPLv3.
10700 * boot/i386/pc/diskboot.S: Likewise.
10701 * boot/i386/pc/pxeboot.S: Likewise.
10702 * commands/blocklist.c: Likewise.
10703 * commands/boot.c: Likewise.
10704 * commands/cat.c: Likewise.
10705 * commands/cmp.c: Likewise.
10706 * commands/configfile.c: Likewise.
10707 * commands/echo.c: Likewise.
10708 * commands/help.c: Likewise.
10709 * commands/ls.c: Likewise.
10710 * commands/search.c: Likewise.
10711 * commands/terminal.c: Likewise.
10712 * commands/test.c: Likewise.
10713 * commands/videotest.c: Likewise.
10714 * commands/i386/cpuid.c: Likewise.
10715 * commands/i386/pc/halt.c: Likewise.
10716 * commands/i386/pc/play.c: Likewise.
10717 * commands/i386/pc/reboot.c: Likewise.
10718 * commands/i386/pc/vbeinfo.c: Likewise.
10719 * commands/i386/pc/vbetest.c: Likewise.
10720 * commands/ieee1275/halt.c: Likewise.
10721 * commands/ieee1275/reboot.c: Likewise.
10722 * commands/ieee1275/suspend.c: Likewise.
10723 * disk/loopback.c: Likewise.
10724 * disk/lvm.c: Likewise.
10725 * disk/raid.c: Likewise.
10726 * disk/efi/efidisk.c: Likewise.
10727 * disk/i386/pc/biosdisk.c: Likewise.
10728 * disk/ieee1275/ofdisk.c: Likewise.
10729 * font/manager.c: Likewise.
10730 * fs/affs.c: Likewise.
10731 * fs/ext2.c: Likewise.
10732 * fs/fat.c: Likewise.
10733 * fs/fshelp.c: Likewise.
10734 * fs/hfs.c: Likewise.
10735 * fs/hfsplus.c: Likewise.
10736 * fs/iso9660.c: Likewise.
10737 * fs/jfs.c: Likewise.
10738 * fs/minix.c: Likewise.
10739 * fs/sfs.c: Likewise.
10740 * fs/ufs.c: Likewise.
10741 * fs/xfs.c: Likewise.
10742 * hello/hello.c: Likewise.
10743 * include/grub/acorn_filecore.h: Likewise.
10744 * include/grub/arg.h: Likewise.
10745 * include/grub/bitmap.h: Likewise.
10746 * include/grub/boot.h: Likewise.
10747 * include/grub/cache.h: Likewise.
10748 * include/grub/device.h: Likewise.
10749 * include/grub/disk.h: Likewise.
10750 * include/grub/dl.h: Likewise.
10751 * include/grub/elfload.h: Likewise.
10752 * include/grub/env.h: Likewise.
10753 * include/grub/err.h: Likewise.
10754 * include/grub/file.h: Likewise.
10755 * include/grub/font.h: Likewise.
10756 * include/grub/fs.h: Likewise.
10757 * include/grub/fshelp.h: Likewise.
10758 * include/grub/gzio.h: Likewise.
10759 * include/grub/hfs.h: Likewise.
10760 * include/grub/kernel.h: Likewise.
10761 * include/grub/loader.h: Likewise.
10762 * include/grub/lvm.h: Likewise.
10763 * include/grub/misc.h: Likewise.
10764 * include/grub/mm.h: Likewise.
10765 * include/grub/net.h: Likewise.
10766 * include/grub/normal.h: Likewise.
10767 * include/grub/parser.h: Likewise.
10768 * include/grub/partition.h: Likewise.
10769 * include/grub/pc_partition.h: Likewise.
10770 * include/grub/raid.h: Likewise.
10771 * include/grub/rescue.h: Likewise.
10772 * include/grub/script.h: Likewise.
10773 * include/grub/setjmp.h: Likewise.
10774 * include/grub/symbol.h: Likewise.
10775 * include/grub/term.h: Likewise.
10776 * include/grub/terminfo.h: Likewise.
10777 * include/grub/tparm.h: Likewise.
10778 * include/grub/types.h: Likewise.
10779 * include/grub/video.h: Likewise.
10780 * include/grub/efi/api.h: Likewise.
10781 * include/grub/efi/chainloader.h: Likewise.
10782 * include/grub/efi/console.h: Likewise.
10783 * include/grub/efi/console_control.h: Likewise.
10784 * include/grub/efi/disk.h: Likewise.
10785 * include/grub/efi/efi.h: Likewise.
10786 * include/grub/efi/pe32.h: Likewise.
10787 * include/grub/efi/time.h: Likewise.
10788 * include/grub/i386/linux.h: Likewise.
10789 * include/grub/i386/setjmp.h: Likewise.
10790 * include/grub/i386/types.h: Likewise.
10791 * include/grub/i386/efi/kernel.h: Likewise.
10792 * include/grub/i386/efi/loader.h: Likewise.
10793 * include/grub/i386/efi/time.h: Likewise.
10794 * include/grub/i386/pc/biosdisk.h: Likewise.
10795 * include/grub/i386/pc/boot.h: Likewise.
10796 * include/grub/i386/pc/chainloader.h: Likewise.
10797 * include/grub/i386/pc/console.h: Likewise.
10798 * include/grub/i386/pc/init.h: Likewise.
10799 * include/grub/i386/pc/kernel.h: Likewise.
10800 * include/grub/i386/pc/loader.h: Likewise.
10801 * include/grub/i386/pc/memory.h: Likewise.
10802 * include/grub/i386/pc/multiboot.h: Likewise.
10803 * include/grub/i386/pc/serial.h: Likewise.
10804 * include/grub/i386/pc/time.h: Likewise.
10805 * include/grub/i386/pc/vbe.h: Likewise.
10806 * include/grub/i386/pc/vbeblit.h: Likewise.
10807 * include/grub/i386/pc/vbefill.h: Likewise.
10808 * include/grub/i386/pc/vbeutil.h: Likewise.
10809 * include/grub/i386/pc/vga.h: Likewise.
10810 * include/grub/ieee1275/ieee1275.h: Likewise.
10811 * include/grub/ieee1275/ofdisk.h: Likewise.
10812 * include/grub/powerpc/libgcc.h: Likewise.
10813 * include/grub/powerpc/setjmp.h: Likewise.
10814 * include/grub/powerpc/types.h: Likewise.
10815 * include/grub/powerpc/ieee1275/biosdisk.h: Likewise.
10816 * include/grub/powerpc/ieee1275/console.h: Likewise.
10817 * include/grub/powerpc/ieee1275/ieee1275.h: Likewise.
10818 * include/grub/powerpc/ieee1275/kernel.h: Likewise.
10819 * include/grub/powerpc/ieee1275/loader.h: Likewise.
10820 * include/grub/powerpc/ieee1275/multiboot.h: Likewise.
10821 * include/grub/powerpc/ieee1275/time.h: Likewise.
10822 * include/grub/powerpc/ieee1275/util/biosdisk.h: Likewise.
10823 * include/grub/sparc64/libgcc.h: Likewise.
10824 * include/grub/sparc64/setjmp.h: Likewise.
10825 * include/grub/sparc64/types.h: Likewise.
10826 * include/grub/sparc64/ieee1275/console.h: Likewise.
10827 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
10828 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
10829 * include/grub/sparc64/ieee1275/time.h: Likewise.
10830 * include/grub/util/biosdisk.h: Likewise.
10831 * include/grub/util/getroot.h: Likewise.
10832 * include/grub/util/lvm.h: Likewise.
10833 * include/grub/util/misc.h: Likewise.
10834 * include/grub/util/raid.h: Likewise.
10835 * include/grub/util/resolve.h: Likewise.
10836 * io/gzio.c: Likewise.
10837 * kern/device.c: Likewise.
10838 * kern/disk.c: Likewise.
10839 * kern/dl.c: Likewise.
10840 * kern/elf.c: Likewise.
10841 * kern/env.c: Likewise.
10842 * kern/err.c: Likewise.
10843 * kern/file.c: Likewise.
10844 * kern/fs.c: Likewise.
10845 * kern/loader.c: Likewise.
10846 * kern/main.c: Likewise.
10847 * kern/misc.c: Likewise.
10848 * kern/mm.c: Likewise.
10849 * kern/parser.c: Likewise.
10850 * kern/partition.c: Likewise.
10851 * kern/rescue.c: Likewise.
10852 * kern/term.c: Likewise.
10853 * kern/efi/efi.c: Likewise.
10854 * kern/efi/init.c: Likewise.
10855 * kern/efi/mm.c: Likewise.
10856 * kern/i386/dl.c: Likewise.
10857 * kern/i386/efi/init.c: Likewise.
10858 * kern/i386/efi/startup.S: Likewise.
10859 * kern/i386/pc/init.c: Likewise.
10860 * kern/i386/pc/lzo1x.S: Likewise.
10861 * kern/i386/pc/startup.S: Likewise.
10862 * kern/ieee1275/ieee1275.c: Likewise.
10863 * kern/powerpc/cache.S: Likewise.
10864 * kern/powerpc/dl.c: Likewise.
10865 * kern/powerpc/ieee1275/cmain.c: Likewise.
10866 * kern/powerpc/ieee1275/crt0.S: Likewise.
10867 * kern/powerpc/ieee1275/init.c: Likewise.
10868 * kern/powerpc/ieee1275/openfw.c: Likewise.
10869 * kern/sparc64/cache.S: Likewise.
10870 * kern/sparc64/dl.c: Likewise.
10871 * kern/sparc64/ieee1275/init.c: Likewise.
10872 * kern/sparc64/ieee1275/openfw.c: Likewise.
10873 * loader/efi/chainloader.c: Likewise.
10874 * loader/efi/chainloader_normal.c: Likewise.
10875 * loader/i386/efi/linux.c: Likewise.
10876 * loader/i386/efi/linux_normal.c: Likewise.
10877 * loader/i386/pc/chainloader.c: Likewise.
10878 * loader/i386/pc/chainloader_normal.c: Likewise.
10879 * loader/i386/pc/linux.c: Likewise.
10880 * loader/i386/pc/linux_normal.c: Likewise.
10881 * loader/i386/pc/multiboot.c: Likewise.
10882 * loader/i386/pc/multiboot_normal.c: Likewise.
10883 * loader/powerpc/ieee1275/linux.c: Likewise.
10884 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
10885 * normal/arg.c: Likewise.
10886 * normal/cmdline.c: Likewise.
10887 * normal/command.c: Likewise.
10888 * normal/completion.c: Likewise.
10889 * normal/execute.c: Likewise.
10890 * normal/function.c: Likewise.
10891 * normal/lexer.c: Likewise.
10892 * normal/main.c: Likewise.
10893 * normal/menu.c: Likewise.
10894 * normal/menu_entry.c: Likewise.
10895 * normal/misc.c: Likewise.
10896 * normal/parser.y: Likewise.
10897 * normal/script.c: Likewise.
10898 * normal/i386/setjmp.S: Likewise.
10899 * normal/powerpc/setjmp.S: Likewise.
10900 * normal/sparc64/setjmp.S: Likewise.
10901 * partmap/acorn.c: Likewise.
10902 * partmap/amiga.c: Likewise.
10903 * partmap/apple.c: Likewise.
10904 * partmap/gpt.c: Likewise.
10905 * partmap/pc.c: Likewise.
10906 * partmap/sun.c: Likewise.
10907 * term/gfxterm.c: Likewise.
10908 * term/terminfo.c: Likewise.
10909 * term/efi/console.c: Likewise.
10910 * term/i386/pc/console.c: Likewise.
10911 * term/i386/pc/serial.c: Likewise.
10912 * term/i386/pc/vesafb.c: Likewise.
10913 * term/i386/pc/vga.c: Likewise.
10914 * term/ieee1275/ofconsole.c: Likewise.
10915 * util/biosdisk.c: Likewise.
10916 * util/console.c: Likewise.
10917 * util/genmoddep.c: Likewise.
10918 * util/getroot.c: Likewise.
10919 * util/grub-emu.c: Likewise.
10920 * util/grub-mkdevicemap.c: Likewise.
10921 * util/grub-probe.c: Likewise.
10922 * util/lvm.c: Likewise.
10923 * util/misc.c: Likewise.
10924 * util/raid.c: Likewise.
10925 * util/resolve.c: Likewise.
10926 * util/update-grub.in: Likewise.
10927 * util/update-grub_lib.in: Likewise.
10928 * util/grub.d/00_header.in: Likewise.
10929 * util/grub.d/10_hurd.in: Likewise.
10930 * util/grub.d/10_linux.in: Likewise.
10931 * util/i386/efi/grub-install.in: Likewise.
10932 * util/i386/efi/grub-mkimage.c: Likewise.
10933 * util/i386/pc/grub-install.in: Likewise.
10934 * util/i386/pc/grub-mkimage.c: Likewise.
10935 * util/i386/pc/grub-mkrescue.in: Likewise.
10936 * util/i386/pc/grub-setup.c: Likewise.
10937 * util/i386/pc/misc.c: Likewise.
10938 * util/powerpc/ieee1275/grub-install.in: Likewise.
10939 * util/powerpc/ieee1275/grub-mkimage.c: Likewise.
10940 * util/powerpc/ieee1275/misc.c: Likewise.
10941 * video/bitmap.c: Likewise.
10942 * video/video.c: Likewise.
10943 * video/i386/pc/vbe.c: Likewise.
10944 * video/i386/pc/vbeblit.c: Likewise.
10945 * video/i386/pc/vbefill.c: Likewise.
10946 * video/i386/pc/vbeutil.c: Likewise.
10947 * video/readers/tga.c: Likewise.
10948
10949 2007-07-02 Robert Millan <rmh@aybabtu.com>
10950
10951 * conf/i386-efi.rmk: Replace obsolete reference to
10952 util/i386/pc/biosdisk.c with util/biosdisk.c, and util/i386/pc/getroot.c
10953 with util/getroot.c.
10954 * conf/powerpc-ieee1275.rmk: Likewise.
10955 * conf/sparc64-ieee1275.rmk: Likewise.
10956
10957 * util/grub-emu.c (main): Fix unchecked pointer handling.
10958
10959 2007-07-02 Robert Millan <rmh@aybabtu.com>
10960
10961 * util/i386/efi/grub-install.in: Allow `grub_probe --target=partmap'
10962 invocation to fail, in order to support partition-less media.
10963
10964 * util/i386/pc/grub-install.in: Likewise.
10965
10966 * util/powerpc/ieee1275/grub-install.in: Use grub-probe to determine
10967 which fs or partmap modules are needed (akin to its sister scripts).
10968
10969 Also use grub-probe to get rid of unportable /proc/mounts check.
10970
10971 Print the same informational message that the other scripts do, before
10972 exiting.
10973
10974 2007-06-23 Robert Millan <rmh@aybabtu.com>
10975
10976 * util/update-grub_lib.in (font_path): New function. Determine whether
10977 a font file can be found and, if so, echo the GRUB path to it.
10978
10979 * util/update-grub.in: Handle multiple terminals depending on user
10980 input, platform availability and font file presence. Propagate
10981 variables of our findings to /etc/grub.d/ children.
10982
10983 * util/grub.d/00_header.in: Handle multiple terminals, based on
10984 environment setup by update-grub.
10985
10986 2007-06-23 Robert Millan <rmh@aybabtu.com>
10987
10988 * conf/i386-pc.rmk (pkgdata_MODULES): Add serial.mod.
10989
10990 2007-06-21 Robert Millan <rmh@aybabtu.com>
10991
10992 * include/grub/i386/pc/kernel.h: Define GRUB_KERNEL_MACHINE_DATA_END to
10993 indicate end of data section in kernel image.
10994 * include/grub/i386/efi/kernel.h: Define GRUB_KERNEL_MACHINE_PREFIX and
10995 GRUB_KERNEL_MACHINE_DATA_END.
10996
10997 * kern/i386/pc/startup.S: Do not initialize grub_prefix, only reserve
10998 space for it.
10999 * kern/i386/efi/startup.S: Likewise.
11000
11001 * util/i386/pc/grub-mkimage.c: Initialize grub_prefix to /boot/grub
11002 during image generation. Implement --prefix option to override this
11003 patch.
11004 * util/i386/efi/grub-mkimage.c: Likewise.
11005
11006 * util/update-grub_lib.in (convert_system_path_to_grub_path): Split
11007 code to make path relative to its root into a separate function.
11008
11009 * util/i386/pc/grub-install.in: Use newly provided
11010 make_system_path_relative_to_its_root() to convert ${grubdir}, then
11011 pass the result to grub-install --prefix.
11012
11013 2007-06-13 Robert Millan <rmh@aybabtu.com>
11014
11015 * include/grub/util/misc.h: Define DEFAULT_DIRECTORY and
11016 DEFAULT_DEVICE_MAP.
11017 * util/grub-emu.c: Use above definitions from misc.h instead of
11018 defining them.
11019 * util/grub-mkdevicemap.c: Likewise.
11020 * util/i386/pc/grub-setup.c: Likewise.
11021 * util/grub-probe.c: Likewise.
11022 (probe): Abort with grub_util_error() when either
11023 grub_guess_root_device or grub_util_get_grub_dev fails.
11024
11025 2007-06-12 Robert Millan <rmh@aybabtu.com>
11026
11027 * normal/command.c (grub_command_execute): Use NULL rather than 0 for
11028 "pager" assignment.
11029 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Likewise for
11030 "pcdata".
11031 * util/grub-probe.c (probe): Likewise for "drive_name".
11032
11033 2007-06-11 Robert Millan <rmh@aybabtu.com>
11034
11035 * util/i386/pc/grub-mkrescue.in: Pad both floppy images with zeroes,
11036 not just the cdrom one.
11037
11038 2007-06-11 Robert Millan <rmh@aybabtu.com>
11039
11040 * util/i386/pc/grub-mkrescue.in: Add "set -e".
11041 Add --pkglibdir=DIR option to override pkglibdir.
11042 Mention --image-type=TYPE in help output.
11043 Fix --grub-mkimage (it was a no-op).
11044 Abort gracefully when no parameter is given.
11045
11046 2007-06-11 Robert Millan <rmh@aybabtu.com>
11047
11048 * util/i386/pc/grub-mkrescue.in: New file.
11049 * conf/i386-pc.rmk: Add its build declarations. Put it in bin_SCRIPTS.
11050 * Makefile.in: Handle bin_SCRIPTS.
11051
11052 2007-06-10 Vesa Jaaskelainen <chaac@nic.fi>
11053
11054 * term/gfxterm.c (grub_gfxterm_init): Added support for specifying
11055 list of video modes.
11056
11057 2007-06-06 Robert Millan <rmh@aybabtu.com>
11058
11059 * util/update-grub_lib.in (convert_system_path_to_grub_path): Abort if
11060 file doesn't exist, or if it is in a filesystem grub can't read.
11061
11062 * util/update-grub.in: Set fallback for GRUB_FS check to "unknown". Do
11063 not abort if GRUB_DRIVE could not be defined. Rearrange generated
11064 header comment to fit in 80 columns when the variables are resolved.
11065
11066 * util/grub.d/00_header.in: Only set root variable when GRUB_DRIVE
11067 could be identified by update-grub. Remove redundant check for
11068 unifont.pff existence (since convert_system_path_to_grub_path now
11069 handles that).
11070
11071 2007-06-04 Robert Millan <rmh@aybabtu.com>
11072
11073 * conf/i386-efi.rmk (grub_probe_SOURCES): Add partmap/apple.c.
11074
11075 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise.
11076
11077 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add partmap/pc.c.
11078
11079 2007-06-04 Robert Millan <rmh@aybabtu.com>
11080
11081 * conf/powerpc-ieee1275.rmk: Enable grub-mkdevicemap and grub-probe.
11082
11083 * include/grub/partition.h: Declare grub_apple_partition_map_init and
11084 grub_apple_partition_map_fini.
11085
11086 * util/biosdisk.c
11087 (grub_util_biosdisk_open): Replace BLKGETSIZE with BLKGETSIZE64 (needed
11088 to access >2 TiB disks).
11089
11090 Print disk->total_sectors with %llu instead of %lu, since this
11091 variable is always 64-bit (prevents wrong disk size from being displayed
11092 on either >2 TiB disk or big-endian CPU).
11093
11094 (grub_util_biosdisk_get_grub_dev): Convert gpt_partition_map handling
11095 into a generic case that supports all (sane) partition maps.
11096
11097 Stop using grub_cpu_to_le32() on dos_part / bsd_part since it actually
11098 breaks big-endian.
11099
11100 * util/grub-probe.c: Call grub_apple_partition_map_init() before probe()
11101 and grub_apple_partition_map_fini() after that.
11102
11103 2007-06-01 Robert Millan <rmh@aybabtu.com>
11104
11105 * util/update-grub.in: Export GRUB_CMDLINE_LINUX.
11106
11107 * util/grub.d/00_header.in: Only enable gfxterm when
11108 convert_system_path_to_grub_path() succeeds.
11109
11110 2007-05-20 Robert Millan <rmh@aybabtu.com>
11111
11112 * util/update-grub_lib.in: New file.
11113 * DISTLIST: Add update-grub_lib.in.
11114 * conf/common.rmk: Generate update-grub_lib and install it in
11115 $(lib_DATA).
11116 * Makefile.in: Add install routine for $(lib_DATA).
11117
11118 * util/grub.d/00_header.in: Use convert_system_path_to_grub_path()
11119 function provided by update-grub_lib to support arbitrary paths of
11120 unifont.pff.
11121 * util/update-grub.in: Use convert_system_path_to_grub_path() to
11122 initialize GRUB_DRIVE_BOOT and GRUB_DRIVE_BOOT_GRUB variables.
11123
11124 2007-05-19 Robert Millan <rmh@aybabtu.com>
11125
11126 * commands/i386/cpuid.c: New module.
11127 * DISTLIST: Add it.
11128 * conf/i386-efi.rmk: Enable cpuid.mod.
11129 * conf/i386-pc.rmk: Likewise.
11130
11131 2007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
11132
11133 * kern/disk.c (grub_disk_read): Check return value of
11134 grub_realloc().
11135
11136 2007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
11137
11138 * util/getroot.c (grub_util_get_grub_dev): Support partitionable
11139 arrays.
11140 * disk/raid.c (grub_raid_open): Likewise.
11141
11142 2007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
11143
11144 * util/biosdisk.c (linux_find_partition): Allocate real_dev on the
11145 stack instead of on the heap.
11146
11147 * kern/disk.c (grub_disk_read): Make sure tmp_buf is big enough
11148 before doing a read on it.
11149
11150 * configure.ac: Only use -fno-stack-protector for the target
11151 environment.
11152
11153 2007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
11154
11155 * video/i386/pc/vbe.c (grub_video_vbe_create_render_target): Add
11156 __attribute_ ((unused)) to mode_type argument.
11157
11158 * util/getroot.c (grub_guess_root_device): Fix #endif.
11159
11160 * kern/misc.c (memcmp): Fix prototype.
11161
11162 * include/grub/partition.h [GRUB_UTIL]
11163 (grub_gpt_partition_map_init): Add prototype.
11164 (grub_gpt_partition_map_fini): Likewise.
11165
11166 * fs/jfs.c (struct grub_jfs_inode): Put __attribute__ ((packed)
11167 at the right place.
11168
11169 * fs/fat.c (grub_fat_mount): Replace ~0UL with ~0U.
11170 (grub_fat_read_data): Likewise.
11171 (grub_fat_find_dir): Likewise.
11172
11173 * font/manager.c (find_glyph): Make table a const.
11174 (grub_font_get_glyph): Remove bitmap from if statement.
11175
11176 2007-05-16 Jeroen Dekkers <jeroen@dekkers.cx>
11177
11178 * util/getroot.c (grub_guess_root_device): Remove RAID and LVM
11179 code, first search for device in /dev/mapper, then in /dev.
11180 (grub_util_get_grub_dev): New function.
11181 * include/grub/util/getroot.h (grub_util_get_grub_dev): Add
11182 prototype.
11183 * util/grub-probe.c (probe): Remove check for RAID, call
11184 grub_util_get_grub_dev() instead of
11185 grub_util_biosdisk_get_grub_dev().
11186 * util/grub-emu.c (main): Call grub_util_get_grub_dev() instead of
11187 grub_util_biosdisk_get_grub_dev().
11188 * util/i386/pc/grub-setup.c (main): Likewise.
11189
11190 2007-05-16 Robert Millan <rmh@aybabtu.com>
11191
11192 * DISTLIST: Update for the latest changes.
11193 * conf/i386-pc.rmk: Use the new paths for util/getroot.c,
11194 util/grub-mkdevicemap.c, util/grub-probe.c and util/biosdisk.c.
11195 * util/grub-emu.c: Replace grub/i386/pc/util/biosdisk.h with
11196 grub/util/biosdisk.h.
11197 * util/i386/pc/grub-setup.c: Replace grub/machine/util/biosdisk.h with
11198 grub/util/biosdisk.h.
11199
11200 2007-05-16 Robert Millan <rmh@aybabtu.com>
11201
11202 * util/grub.d/00_header.in: Set default gfxmode to `640x480'.
11203
11204 2007-05-16 Robert Millan <rmh@aybabtu.com>
11205
11206 * util/i386/efi/grub-install.in: New.
11207 * conf/i386-efi.rmk: Enable grub-mkdevicemap, grub-probe and the
11208 newly added grub-install.
11209 * util/biosdisk.c: Remove unnecessary grub/machine/biosdisk.h
11210 include.
11211 * util/getroot.c: Replace grub/i386/pc/util/biosdisk.h with
11212 grub/util/biosdisk.h.
11213 * util/grub-probe.c: Replace grub/machine/util/biosdisk.h with
11214 grub/util/biosdisk.h.
11215
11216 2007-05-16 Robert Millan <rmh@aybabtu.com>
11217
11218 * include/grub/i386/pc/util/biosdisk.h: Moved to ...
11219 * include/grub/util/biosdisk.h: ... here.
11220 * util/i386/pc/biosdisk.c: Moved to ...
11221 * util/biosdisk.c: ... here.
11222 * util/i386/pc/getroot.c: Moved to ...
11223 * util/getroot.c: ... here.
11224 * util/i386/pc/grub-mkdevicemap.c: Moved to ...
11225 * util/grub-mkdevicemap.c: ... here.
11226 * util/i386/pc/grub-probe.c: Moved to ...
11227 * util/grub-probe.c: ... here.
11228
11229 2007-05-15 Robert Millan <rmh@aybabtu.com>
11230
11231 * util/update-grub.in: Remove duplicated line in grub.cfg header
11232 message.
11233
11234 2007-05-13 Robert Millan <rmh@aybabtu.com>
11235
11236 * util/update-grub.in: Fix a few assumptions about the devices holding
11237 /, /boot and /boot/grub being the same.
11238 * util/grub.d/00_header.in: Likewise.
11239 * util/grub.d/10_hurd.in: Likewise.
11240 * util/grub.d/10_linux.in: Likewise.
11241
11242 * util/grub.d/10_linux.in: Implement Linux image sorting with arbitrary
11243 patterns. Use that to define the `.old' suffix as older than `'.
11244
11245 * util/grub.d/00_header.in: Set default gfxmode to `800x600x16'.
11246
11247 * util/update-grub.in: Add a reference to ${sysconfdir}/default/grub in
11248 the grub.cfg header message.
11249
11250 2007-05-11 Robert Millan <rmh@aybabtu.com>
11251
11252 * util/update-grub.in: Create device.map if it doesn't already exist,
11253 before attempting to run grub-probe.
11254 Check for grub-probe and grub-mkdevicemap with the same code
11255 grub-install is using.
11256 Remove test mode.
11257
11258 2007-05-09 Jeroen Dekkers <jeroen@dekkers.cx>
11259
11260 * Makefile.in: Add the datarootdir autoconf variable.
11261
11262 2007-05-09 Robert Millan <rmh@aybabtu.com>
11263
11264 * util/i386/pc/grub-probe.c (probe): When detecting partition map,
11265 fail gracefully if dev->disk->partition == NULL.
11266
11267 2007-05-07 Robert Millan <rmh@aybabtu.com>
11268
11269 * util/i386/pc/grub-probe.c: Add `grub-probe -t partmap' parameter to
11270 determine partition map module.
11271 * util/i386/pc/grub-install.in: Use this feature to decide which
11272 partition module to load, instead of hardcoding pc and gpt.
11273
11274 2007-05-07 Robert Millan <rmh@aybabtu.com>
11275
11276 * Makefile.in: Fix assumption that $(srcdir) has a trailing slash when
11277 source directory differs from build directory.
11278
11279 2007-05-05 Robert Millan <rmh@aybabtu.com>
11280
11281 * util/powerpc/ieee1275/grub-install.in: Fix syntax error in pkglibdir
11282 initialisation.
11283
11284 2007-05-05 Robert Millan <rmh@aybabtu.com>
11285
11286 * util/update-grub.in: Create ${grub_prefix} if it doesn't exist.
11287
11288 2007-05-05 Robert Millan <rmh@aybabtu.com>
11289
11290 * util/grub.d/10_linux.in: Allow the administrator to insert Linux
11291 command-line arguments via ${GRUB_CMDLINE_LINUX}.
11292
11293 2007-05-05 Robert Millan <rmh@aybabtu.com>
11294
11295 * conf/i386-pc.rmk (grub_setup_SOURCES): Add partmap/gpt.c.
11296 (grub_probe_SOURCES): Likewise.
11297 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): Detect
11298 GPT and initialize dos_part and bsd_part accordingly.
11299 * util/i386/pc/grub-setup.c (setup): Ditto for install_dos_part and
11300 install_bsd_part.
11301 (main): Activate gpt module for use during partition identification,
11302 and deactivate it afterwards.
11303 * util/i386/pc/grub-install.in: Add gpt module to core.img.
11304 * util/i386/pc/grub-probe.c (main): Activate gpt module for use during
11305 partition identification, and deactivate it afterwards.
11306
11307 2007-05-05 Robert Millan <rmh@aybabtu.com>
11308
11309 * term/i386/pc/console.c (grub_console_fini): Call
11310 grub_term_set_current() before grub_term_unregister().
11311
11312 2007-05-04 Robert Millan <rmh@aybabtu.com>
11313
11314 * DISTLIST: Add util/update-grub.in, util/grub.d/00_header.in,
11315 util/grub.d/10_hurd.in, util/grub.d/10_linux.in and util/grub.d/README.
11316 * Makefile.in: Build update-grub_SCRIPTS. Install update-grub_SCRIPTS
11317 and update-grub_DATA.
11318 * conf/common.rmk: Build and install update-grub components.
11319 * conf/common.mk: Regenerate.
11320 * util/update-grub.in: New. Core of update-grub.
11321 * util/grub.d/00_header.in: New. Generates grub.cfg header.
11322 * util/grub.d/10_hurd.in: New. Generates boot entries for the Hurd.
11323 * util/grub.d/10_linux.in: New. Generates boot entries for Linux.
11324 * util/grub.d/README: New. Document grub.d directory layout.
11325
11326 2007-05-01 Robert Millan <rmh@aybabtu.com>
11327
11328 * util/grub-emu.c: Move initialization functions
11329 grub_util_biosdisk_init() and grub_init_all() before
11330 grub_util_biosdisk_get_grub_dev(), which relies on them.
11331
11332 2007-04-19 Robert Millan <rmh@aybabtu.com>
11333
11334 * util/powerpc/ieee1275/grub-install.in: Initialize ${bindir}, since
11335 it is used later.
11336
11337 2007-04-18 Jerone Young <jerone@gmail.com>
11338
11339 * kernel/elf.c: Add missing parenthesis for conditional statement
11340 stanza.
11341
11342 2007-04-10 Jerone Young <jerone@gmail.com>
11343
11344 * util/i386/pc/getroot.c: Update so that if root device is /dev/root ,
11345 continue on and look for device node with real device name.
11346
11347 2007-04-10 Jerone Young <jerone@gmail.com>
11348
11349 * configure.ac: Add argument for autoconf to use transformation
11350 ability.
11351 * Makefile.in: Add autoconf package transformation code.
11352 * util/i386/pc/grub-install.in: Likewise.
11353 * util/powerpc/ieee1275/grub-install.in: Likewise.
11354
11355 2007-03-19 Yoshinori K. Okuji <okuji@enbug.org>
11356
11357 * fs/ext2.c (EXT2_GOOD_OLD_REVISION): New macro.
11358 (EXT2_GOOD_OLD_INODE_SIZE): Likewise.
11359 (EXT2_REVISION): Likewise.
11360 (EXT2_INODE_SIZE): Likewise.
11361 (struct grub_ext2_block_group): Added a missing member
11362 "used_dirs".
11363 (grub_ext2_read_inode): Divide by the inode size in a superblock
11364 instead of 128 to obtain INODES_PER_BLOCK.
11365 Use the macro EXT2_INODE_SIZE instead of directly using
11366 SBLOCK->INODE_SIZE.
11367
11368 2007-03-18 Yoshinori K. Okuji <okuji@enbug.org>
11369
11370 * fs/ext2.c (grub_ext2_read_inode): Use the inode size in a
11371 superblock instead of the structure size to compute an
11372 offset. This fixes the problem that GRUB could not read a
11373 filesystem when inode size is different from 128-byte.
11374
11375 2007-03-05 Marco Gerards <marco@gnu.org>
11376
11377 * normal/main.c (read_config_file): When "menu" is not set, create
11378 an initial context.
11379
11380 2007-02-21 Hollis Blanchard <hollis@penguinppc.org>
11381
11382 * kern/powerpc/ieee1275/init.c (HEAP_SIZE): Removed.
11383 (HEAP_LIMIT): New macro.
11384 (grub_claim_heap): Claim memory up to `heaplimit'.
11385
11386 2007-02-21 Hollis Blanchard <hollis@penguinppc.org>
11387
11388 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Link at 64KB.
11389 * kern/powerpc/ieee1275/init.c (_end): Add declaration.
11390 (_start): Likewise.
11391 (grub_arch_modules_addr): Return address after `_end'.
11392 * util/powerpc/ieee1275/grub-mkimage.c: Include grub/misc.h.
11393 (load_modules): Use new parameter as `p_paddr' and `p_vaddr'.
11394 (add_segments): Calculate `_end' from phdr size and location.
11395 (ALIGN_UP): Moved to ...
11396 * include/grub/misc.h: here.
11397 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
11398 New macro.
11399 (GRUB_IEEE1275_MODULE_BASE): Removed.
11400
11401 2007-02-20 Hollis Blanchard <hollis@penguinppc.org>
11402
11403 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Correct
11404 loop boundary.
11405
11406 2007-02-20 Hollis Blanchard <hollis@penguinppc.org>
11407
11408 * include/grub/elfload.h (grub_elf32_load_hook_t): Return grub_err_t.
11409 All users updated.
11410 (grub_elf64_load_hook_t): Likewise.
11411 * kern/elf.c: Call `grub_error_push' before `grub_error'. Improve
11412 debug output.
11413
11414 2007-02-20 Hollis Blanchard <hollis@penguinppc.org>
11415
11416 * kern/mm.c: Update copyright.
11417 (grub_mm_debug): Correct syntax error.
11418 (grub_mm_dump_free): New function.
11419 (grub_debug_free): Call `grub_free'.
11420 * include/grub/mm.h: Update copyright.
11421 (grub_mm_dump_free): Add declaration.
11422
11423 2007-02-12 Hollis Blanchard <hollis@penguinppc.org>
11424
11425 * include/grub/ieee1275/ieee1275.h: Update copyright.
11426 * kern/powerpc/ieee1275/init.c: Likewise.
11427 * kern/powerpc/ieee1275/openfw.c: Likewise.
11428
11429 * loader/powerpc/ieee1275/linux.c: Likewise.
11430 * include/grub/elfload.h: Likewise.
11431 * kern/elf.c: Likewise.
11432 (grub_elf32_load): Pass `base' and `size' parameters. Update all
11433 callers.
11434 (grub_elf64_load): Likewise.
11435 (grub_elf32_load_segment): Move to a nested function.
11436 (grub_elf64_load_segment): Likewise.
11437
11438 2007-02-12 Hollis Blanchard <hollis@penguinppc.org>
11439
11440 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): New
11441 prototype.
11442 * kern/powerpc/ieee1275/init.c (grub_heap_start): Removed.
11443 (grub_heap_len): Likewise.
11444 (HEAP_SIZE): New macro.
11445 (grub_claim_heap): New function.
11446 (grub_machine_init): Don't claim heap directly. Call
11447 `grub_claim_heap'.
11448 * kern/powerpc/ieee1275/openfw.c: Include alloca.h.
11449 (grub_available_iterate): New function.
11450
11451 2007-02-03 Thomas Schwinge <tschwinge@gnu.org>
11452
11453 * aclocal.m4 (grub_CHECK_STACK_PROTECTOR): New definition.
11454 * configure.ac: Use it for testing the HOST and TARGET compilers.
11455
11456 2006-12-13 Thomas Schwinge <tschwinge@gnu.org>
11457
11458 * Makefile.in (enable_grub_emu): New variable.
11459 * configure.ac (--enable-grub-emu): New option.
11460 Do the checks for (n)curses only if `--enable-grub-emu' is requested.
11461 * conf/i386-efi.rmk (sbin_UTILITIES): Add `grub-emu' only if requested.
11462 * conf/i386-pc.rmk: Likewise.
11463 * conf/powerpc-ieee1275.rmk: Likewise.
11464 * conf/sparc64-ieee1275.rmk (bin_UTILITIES): Likewise.
11465
11466 2006-12-12 Marco Gerards <marco@gnu.org>
11467
11468 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_MENU'.
11469
11470 * kern/env.c (grub_env_unset): Don't free the member `value' when
11471 the type is GRUB_ENV_VAR_DATA, in this case it's a user defined
11472 pointer.
11473
11474 * normal/main.c (current_menu): Removed.
11475 (free_menu): Unset the `menu' environment variable.
11476 (grub_normal_menu_addentry): Make use of the environment variable
11477 `menu', instead of using the global `current_menu'. Allocate
11478 memory for the sourcecode of this entry.
11479 (read_config_file): New argument `nested', changed all callers.
11480 Only in the case of a new context, initialize a new menu. Set the
11481 `menu' environment variable.
11482 (grub_normal_execute): Don't set and unset the environment
11483 variable `menu' here anymore. Only free the menu when leaving the
11484 context.
11485
11486 * util/i386/pc/biosdisk.c (linux_find_partition): Fixed a memory
11487 leak.
11488
11489 2006-12-11 Marco Gerards <marco@gnu.org>
11490
11491 * normal/menu_entry.c (run): Fix off by one bug so the last line
11492 is executed. Move the loader check to outside the loop.
11493
11494 2006-12-08 Hollis Blanchard <hollis@penguinppc.org>
11495
11496 * kern/powerpc/ieee1275/cmain.c (cmain): Mark r3 and r4 as `UNUSED'.
11497
11498 2006-11-25 Yoshinori K. Okuji <okuji@enbug.org>
11499
11500 * util/i386/pc/grub-mkimage.c (generate_image): Fix the offset of
11501 the number of sectors. Reported by Andrey Shuvikov
11502 <mr_hyro@yahoo.com>.
11503
11504 2006-11-11 Jeroen Dekkers <jeroen@dekkers.cx>
11505
11506 * kern/disk.c (grub_disk_read): When there is a read error, always
11507 try to read only the necessary data.
11508
11509 * conf/i386-pc.rmk (grub_probe_SOURCES): Add disk/lvm.c and
11510 disk/raid.c.
11511 * include/grub/disk.h [GRUB_UTIL] (grub_raid_init): New
11512 prototype.
11513 [GRUB_UTIL] (grub_raid_fini): Likewise.
11514 [GRUB_UTIL] (grub_lvm_init): Likewise.
11515 [GRUB_UTIL] (grub_lvm_fini): Likewise.
11516 * util/i386/pc/grub-probe.c (probe): Check whether DEVICE_NAME is
11517 RAID device and copy DEVICE_NAME to DRIVE_NAME in that case.
11518 (main): Call grub_raid_init(), grub_lvm_init(), grub_lvm_fini()
11519 and grub_raid_fini().
11520
11521 2006-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
11522
11523 * include/grub/types.h (__unused): Rename to UNUSED.
11524 * kern/elf.c (grub_elf32_size): Use UNUSED instead of __unused.
11525 (grub_elf64_size): Likewise.
11526
11527 2006-11-03 Hollis Blanchard <hollis@penguinppc.org>
11528
11529 * kern/elf.c (grub_elf_file): Call grub_file_seek. Call
11530 grub_error_push and grub_error_pop in the error-handling path.
11531 (grub_elf32_load_segment): Only call grub_file_read with non-zero
11532 length.
11533
11534 2006-11-03 Hollis Blanchard <hollis@penguinppc.org>
11535
11536 * conf/i386-efi.rmk (grub_emu_SOURCES): Add kern/elf.c.
11537 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
11538 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11539 (kernel_elf_SOURCES): Likewise.
11540 * conf/i386-efi.rmk (kernel_mod_HEADERS): Add elfload.h and cache.h.
11541 * conf/i386-pc.rmk (kernel_mod_HEADERS): Likewise.
11542 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
11543 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
11544 * conf/common.rmk (pkgdata_MODULES): Add elf.mod.
11545 (elf_mod_SOURCES): New variable.
11546 (elf_mod_CFLAGS): Likewise.
11547 (elf_mod_LDFLAGS): Likewise.
11548 * include/grub/types.h (__unused): New macro.
11549 * include/grub/elfload.h: New file.
11550 * kern/elf.c: Likewise.
11551 * loader/powerpc/ieee1275/linux.c: Include elfload.h.
11552 (ELF32_LOADMASK): New macro.
11553 (ELF64_LOADMASK): Likewise.
11554 (vmlinux): Removed.
11555 (grub_linux_load32): New function.
11556 (grub_linux_load64): Likewise.
11557 (grub_rescue_cmd_linux): Call grub_linux_load32 or grub_linux_load64.
11558 Use grub_elf_t instead of grub_file_t.
11559
11560 2006-11-02 Hollis Blanchard <hollis@penguinppc.org>
11561
11562 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): Add
11563 `catch_result' to struct set_color_args.
11564
11565 2006-10-28 Yoshinori K. Okuji <okuji@enbug.org>
11566
11567 * normal/menu.c: Include grub/script.h.
11568 * normal/menu_entry.c: Likewise.
11569 * include/grub/normal.h: Do not include grub/script.h.
11570
11571 2006-10-27 Hollis Blanchard <hollis@penguinppc.org>
11572
11573 * kern/disk.c (grub_disk_read): Correct debug printf formatting.
11574
11575 2006-10-27 Hollis Blanchard <hollis@penguinppc.org>
11576
11577 * kern/disk.c (grub_disk_open): Print debug messages when opening a
11578 disk.
11579 (grub_disk_close): Print debug messages when closing a disk.
11580 (grub_disk_read): Print debug messages when disk read fails.
11581 * kern/fs.c (grub_fs_probe): Print debug messages when detecting
11582 filesystem type.
11583 * kern/partition.c: Include misc.h.
11584 (grub_partition_iterate): Print debug messages when detecting
11585 partition type.
11586
11587 2006-10-27 Hollis Blanchard <hollis@penguinppc.org>
11588
11589 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Return error if `status'
11590 is negative.
11591 * kern/ieee1275/ieee1275.c (IEEE1275_IHANDLE_INVALID): Change to 0.
11592
11593 2006-10-26 Hollis Blanchard <hollis@penguinppc.org>
11594
11595 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
11596 Reverse GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS test.
11597
11598 2006-10-25 Jeroen Dekkers <jeroen@dekkers.cx>
11599
11600 * disk/lvm.c (grub_lvm_scan_device): Malloc sizeof(*lv) bytes
11601 instead of sizeof(lv). Patch by Michael Guntsche.
11602
11603 2006-10-18 Jeroen Dekkers <jeroen@dekkers.cx>
11604
11605 * disk/lvm.c: Rename VGS to VG_LIST.
11606 (grub_lvm_iterate): Change VGS->LV to VG-LV.
11607 (grub_lvm_open): Likewise.
11608 Thanks to Michael Guntsche for finding this bug.
11609
11610 2006-10-15 Yoshinori K. Okuji <okuji@enbug.org>
11611
11612 * configure.ac (AC_INIT): Bumped to 1.95.
11613
11614 2006-10-14 Robert Millan <rmh@aybabtu.com>
11615
11616 * util/i386/pc/getroot.c (grub_guess_root_device): Don't compare os_dev
11617 with "/dev/.static/dev/md".
11618
11619 2006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
11620
11621 * util/i386/pc/grub-probe.c (probe): Print DEVICE_NAME instead of
11622 DRIVE_NAME when grub_util_biosdisk_get_grub_dev fails. Open
11623 DRIVE_NAME instead of DEVICE_NAME. Make sure that DEVICE_NAME and
11624 DRIVE_NAME are always freed.
11625
11626 * util/i386/pc/biosdisk.c (make_device_name): Add one into
11627 DOS_PART, as a DOS partition is counted from one instead of zero
11628 now. Reported by Robert Millan.
11629
11630 2006-10-14 Robert Millan <rmh@aybabtu.com>
11631
11632 * util/i386/pc/getroot.c (grub_guess_root_device): Stop using
11633 grub_util_biosdisk_get_grub_dev to convert system device to GRUB device.
11634 * util/grub-emu.c (main): Use grub_util_biosdisk_get_grub_dev with the
11635 string returned by grub_guess_root_device.
11636 * util/i386/pc/grub-setup.c: Likewise.
11637 * util/i386/pc/grub-probefs.c: Likewise.
11638
11639 * util/i386/pc/grub-probefs.c: Rename to ...
11640 * util/i386/pc/grub-probe.c: ... this.
11641 * DISTLIST: Remove grub-probefs, add grub-probe.
11642 * conf/i386-efi.rmk: Likewise.
11643 * conf/i386-pc.rmk: Likewise.
11644 * util/i386/pc/grub-install.in: Likewise.
11645
11646 * util/i386/pc/grub-probe.c: Add --target=(fs|device|drive) option to
11647 choose which information we want to print.
11648
11649 2006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
11650
11651 * DISTLIST: Added commands/echo.c, disk/lvm.c, disk/raid.c,
11652 include/grub/bitmap.h, include/grub/lvm.h, include/grub/raid.h,
11653 include/grub/i386/pc/vbeutil.h, include/grub/util/lvm.h,
11654 include/grub/util/raid.h, util/lvm.c, util/raid.c, video/bitmap.c,
11655 video/readers/tga.c and video/i386/pc/vbeutil.c.
11656
11657 2006-10-14 Jeroen Dekkers <jeroen@dekkers.cx>
11658
11659 Added support for RAID and LVM.
11660
11661 * disk/lvm.c: New file.
11662 * disk/raid.c: Likewise.
11663 * include/grub/lvm.h: Likewise.
11664 * include/grub/raid.h: Likewise.
11665 * include/grub/util/lvm.h: Likewise.
11666 * include/grub/util/raid.h: Likewise.
11667 * util/lvm.c: Likewise.
11668 * util/raid.c: Likewise.
11669
11670 * include/grub/disk.h (grub_disk_dev_id): Add
11671 GRUB_DISK_DEVICE_RAID_ID and GRUB_DISK_DEVICE_LVM_ID.
11672 (grub_disk_get_size): New prototype.
11673 * kern/disk.c (grub_disk_open): Check whether grub_partition_probe()
11674 returns a partition.
11675 (grub_disk_get_size): New function.
11676
11677 * kern/i386/pc/init.c (make_install_device): Copy the prefix
11678 verbatim if grub_install_dos_part is -2.
11679
11680 * util/i386/pc/getroot.c (grub_guess_root_device): Support RAID
11681 and LVM devices.
11682
11683 * util/i386/pc/grub-setup.c (setup): New argument
11684 MUST_EMBED. Force embedding of GRUB when the argument is
11685 true. Close FILE before returning.
11686 (main): Add support for RAID and LVM.
11687
11688 * conf/common.rmk: Add RAID and LVM modules.
11689 * conf/i386-pc.rmk (grub_setup_SOURCES): Add util/raid.c and
11690 util/lvm.c.
11691 (grub_emu_SOURCES): Add disk/raid.c and disk/lvm.c.
11692
11693 * kern/misc.c (grub_strstr): New function.
11694 * include/grub/misc.h (grub_strstr): New prototype.
11695
11696 2006-10-10 Tristan Gingold <tristan.gingold@bull.net>
11697
11698 * include/grub/efi/api.h (GRUB_EFI_ERROR_CODE): Long constant.
11699
11700 2006-10-05 Tristan Gingold <tristan.gingold@bull.net>
11701
11702 * kern/misc.c (grub_strtoull): Guess the base only if not
11703 specified.
11704
11705 2006-10-01 Hollis Blanchard <hollis@penguinppc.org>
11706
11707 * kern/powerpc/ieee1275/cmain.c (cmain): Remove incomplete Old World
11708 PowerMac support.
11709
11710 2006-10-01 Hollis Blanchard <hollis@penguinppc.org>
11711
11712 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Cast `size' to long.
11713
11714 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_next_property):
11715 Remove `flags' argument. All callers changed.
11716 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_ROOT): Removed.
11717 (IEEE1275_IHANDLE_INVALID): New variable.
11718 (IEEE1275_CELL_INVALID): New variable.
11719 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
11720 grub_ieee1275_get_property_length, grub_ieee1275_instance_to_package,
11721 grub_ieee1275_package_to_path, grub_ieee1275_instance_to_path,
11722 grub_ieee1275_peer, grub_ieee1275_child, grub_ieee1275_open,
11723 grub_ieee1275_claim, grub_ieee1275_set_property): Error-check return
11724 codes from Open Firmware. All callers updated.
11725 (grub_ieee1275_next_property): Directly return Open Firmware return
11726 code.
11727 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
11728 Standardize error checking from `grub_ieee1275_get_property'.
11729 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Rename
11730 `devalias' to `aliases'. Correct comments. Consolidate error paths.
11731
11732 2006-10-01 Hollis Blanchard <hollis@penguinppc.org>
11733
11734 * kern/ieee1275/ieee1275.c (grub_ieee1275_instance_to_path): Rename
11735 `instance_to_package_args' to `instance_to_path_args'.
11736
11737 * kern/powerpc/ieee1275/init.c (grub_machine_init): Use
11738 `grub_ieee1275_chosen'.
11739
11740 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Call
11741 `grub_ieee1275_interpret'.
11742
11743 2006-09-25 Hollis Blanchard <hollis@penguinppc.org>
11744
11745 * util/powerpc/ieee1275/grub-mkimage.c: Include config.h.
11746
11747 2006-09-25 Hollis Blanchard <hollis@penguinppc.org>
11748
11749 * include/grub/powerpc/libgcc.h (__floatdisf): New prototype.
11750 (__cmpdi): Likewise.
11751
11752 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Pass 0 as
11753 `flags' to `grub_ieee1275_next_property'. Change `pathlen' to type
11754 `grub_ssize_t'.
11755
11756 * kern/powerpc/ieee1275/cmain.c: Include grub/misc.h.
11757
11758 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Change `actual'
11759 to type `grub_ssize_t'.
11760 (grub_rescue_cmd_linux): Cast -1 to `grub_off_t'.
11761
11762 2006-09-22 Marco Gerards <marco@gnu.org>
11763
11764 * normal/script.c (grub_script_create_cmdmenu): Skip leading
11765 newlines.
11766
11767 2006-09-22 Marco Gerards <marco@gnu.org>
11768
11769 * commands/echo.c: New file.
11770
11771 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/echo.c'.
11772
11773 * conf/common.rmk (echo_mod_SOURCES): New variable.
11774 (echo_mod_CFLAGS): Likewise.
11775 (echo_mod_LDFLAGS): Likewise.
11776
11777 2006-09-22 Marco Gerards <marco@gnu.org>
11778
11779 * normal/main.c (get_line): Malloc memory instead of using
11780 preallocated memory. Removed the arguments `cmdline' and
11781 `max_len'. Updated all callers.
11782
11783 2006-09-22 Marco Gerards <marco@gnu.org>
11784
11785 * conf/i386-efi.rmk (grub_emu_DEPENDENCIES): New variable.
11786 (normal_mod_DEPENDENCIES): Likewise.
11787
11788 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Likewise.
11789 (normal_mod_DEPENDENCIES): Likewise.
11790
11791 * conf/sparc64-ieee1275.rmk (normal_mod_DEPENDENCIES): Likewise.
11792
11793 2006-09-22 Johan Rydberg <jrydberg@gnu.org>
11794
11795 * genmk.rb: Add DEPENDENCIES variables to modules, utilities, and
11796 programs.
11797 * conf/i386-pc.rmk (grub_emu_DEPENDENCIES): Declare.
11798 (normal_mod_DEPENDENCIES): Likewise.
11799 * conf/i386-pc.mk: Regenerate.
11800 * conf/i386-efi.mk: Likewise
11801 * conf/common.mk: Likewise.
11802 * conf/powerpc-ieee1275.mk: Likewise.
11803 * conf/sparc64-ieee1275.mk: Likewise.
11804
11805 2006-09-22 Robert Millan <rmh@aybabtu.com>
11806
11807 Sync with i386 version.
11808 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Remove grub-emu, add grub-mkimage.
11809 * conf/powerpc-ieee1275.rmk (sbin_UTILITIES): Remove grub-mkimage, add grub-emu.
11810
11811 2006-09-21 Robert Millan <rmh@aybabtu.com>
11812
11813 Import from GRUB Legacy (lib/device.c):
11814 * util/i386/pc/grub-mkdevicemap.c (get_i2o_disk_name): New function.
11815 (init_device_map) [__linux__]: Add support for I2O devices.
11816
11817 2006-09-14 Marco Gerards <marco@gnu.org>
11818
11819 * conf/i386-pc.rmk (COMMON_LDFLAGS): Use `-m32' instead of
11820 `-melf_i386'.
11821
11822 2006-09-14 Robert Millan <rmh@aybabtu.com>
11823
11824 * util/i386/pc/grub-install.in: Skip menu.lst when removing
11825 /boot/grub/*.lst.
11826
11827 * util/i386/pc/getroot.c: Don't recurse into dotdirs (e.g. ".static").
11828
11829 * util/i386/pc/grub-mkdevicemap.c: Make sure the floppy device exists
11830 before adding it to device.map.
11831
11832 2006-08-15 Johan Rydberg <jrydberg@gnu.org>
11833
11834 * genmk.rb: Let GCC generate dependencies the first time it
11835 compiles a file; using the -MD option.
11836 * conf/common.mk: Regenerate.
11837 * conf/i386-pc.mk: Likewise.
11838 * conf/i386-efi.mk: Likewise.
11839 * conf/powerpc-ieee1275.mk: Likewise.
11840 * conf/sparc64-ieee1275.mk: Likewise.
11841
11842 2006-08-04 Yoshinori K. Okuji <okuji@enbug.org>
11843
11844 Move the prototypes of grub_setjmp and grub_longjmp to
11845 cpu/setjmp.h, so that each architecture may specify different
11846 attributes.
11847
11848 * include/grub/i386/setjmp.h (grub_setjmp): New prototype.
11849 (grub_longjmp): Likewise.
11850 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise..
11851 (grub_longjmp): Likewise.
11852 * include/grub/sparc64/setjmp.h (grub_setjmp): Likewise..
11853 (grub_longjmp): Likewise.
11854
11855 * include/grub/setjmp.h [!GRUB_UTIL] (grub_setjmp): Removed.
11856 [!GRUB_UTIL] (grub_longjmp): Removed.
11857
11858 2006-08-01 Pelletier Vincent <subdino2004@yahoo.fr>
11859
11860 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): IEEE1275
11861 "color!" method does not return any value.
11862
11863 2006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
11864
11865 * include/grub/bitmap.h: New file.
11866
11867 * include/grub/i386/pc/vbeutil.h: Likewise.
11868
11869 * video/bitmap.c: Likewise.
11870
11871 * video/readers/tga.c: Likewise.
11872
11873 * video/i386/pc/vbeutil.c: Likewise.
11874
11875 * commands/videotest.c: Code cleanup and updated to reflect to new
11876 video API.
11877
11878 * term/gfxterm.c: Likewise.
11879
11880 * video/video.c: Likewise.
11881
11882 * conf/i386-pc.rmk (pkgdata_MODULES): Added tga.mod and bitmap.mod.
11883 (vbe_mod_SOURCES): Added video/i386/pc/vbeutil.c.
11884 (bitmap_mod_SOURCES): New entry.
11885 (bitmap_mod_CFLAGS): Likewise.
11886 (bitmap_mod_LDFLAGS): Likewise.
11887 (tga_mod_SOURCES): Likewise.
11888 (tga_mod_CFLAGS): Likewise.
11889 (tga_mod_LDFLAGS): Likewise.
11890
11891 * include/grub/video.h (grub_video_blit_operators): New enum type.
11892 (grub_video_render_target): Changed as forward declaration and moved
11893 actual definition to be video driver specific.
11894 (grub_video_adapter.blit_bitmap): Added blitting operator.
11895 (grub_video_adapter.blit_render_target): Likewise.
11896 (grub_video_blit_bitmap): Likewise.
11897 (grub_video_blit_render_target): Likewise.
11898
11899 * include/grub/i386/pc/vbe.h (grub_video_render_target): Added
11900 driver specific render target definition.
11901 (grub_video_vbe_map_rgba): Added driver internal helper.
11902 (grub_video_vbe_unmap_color): Updated to use
11903 grub_video_i386_vbeblit_info.
11904 (grub_video_vbe_get_video_ptr): Likewise.
11905
11906 * include/grub/i386/pc/vbeblit.h
11907 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8): Updated to use
11908 grub_video_i386_vbeblit_info.
11909 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
11910 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
11911 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
11912 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
11913 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
11914 (grub_video_i386_vbeblit_index_index): Likewise.
11915 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): New blitter function.
11916 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
11917 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
11918 (grub_video_i386_vbeblit_blend): Added generic blitter for blend
11919 operator.
11920 (grub_video_i386_vbeblit_replace): Added generic blitter for replace
11921 operator.
11922
11923 * video/i386/pc/vbeblit.c: Updated to reflect changes on
11924 include/grub/i386/pc/vbeblit.h.
11925
11926 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8):
11927 Updated to use grub_video_i386_vbeblit_info.
11928 (grub_video_i386_vbefill_R8G8B8): Likewise.
11929 (grub_video_i386_vbefill_index): Likewise.
11930 (grub_video_i386_vbefill): Added generic filler.
11931
11932 * video/i386/pc/vbefill.c: Updated to reflect changes on
11933 include/grub/i386/pc/vbefill.h.
11934
11935 * video/i386/pc/vbe.c (grub_video_vbe_get_video_ptr): Updated to use
11936 grub_video_i386_vbeblit_info.
11937 (grub_video_vbe_unmap_color): Likewise.
11938 (grub_video_vbe_blit_glyph): Likewise.
11939 (grub_video_vbe_scroll): Likewise.
11940 (grub_video_vbe_draw_pixel): Removed function.
11941 (grub_video_vbe_get_pixel): Likewise.
11942 (grub_video_vbe_fill_rect): Moved all blitters to vbefill.c and
11943 updated code to use it.
11944 (common_blitter): Added common blitter for render target and bitmap.
11945 (grub_video_vbe_blit_bitmap): Updated to use common_blitter.
11946 (grub_video_vbe_blit_render_target): Likewise.
11947
11948 2006-07-30 Johan Rydberg <jrydberg@gnu.org>
11949
11950 * kern/efi/efi.c (grub_efi_set_text_mode): Assume console already
11951 is in text mode if there is no console control protocol instance
11952 available.
11953
11954 2006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
11955
11956 * include/grub/video.h: Code cleanup.
11957
11958 * include/grub/i386/pc/vbe.h: Likewise.
11959
11960 * video/i386/pc/vbe.c: Likewise.
11961
11962 * video/i386/pc/vbeblit.c: Likewise.
11963
11964 * video/i386/pc/vbefill.c: Likewise.
11965
11966 * video/video.c: Likewise. Also added more comments.
11967
11968 2006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
11969
11970 * disk/i386/pc/biosdisk.c (struct grub_biosdisk_drp): Moved to ...
11971 (struct grub_biosdisk_dap): Likewise.
11972
11973 * include/grub/i386/pc/biosdisk.h: ... to here. Also corrected
11974 linkage settings for all functions.
11975
11976 2006-07-12 Marco Gerards <marco@gnu.org>
11977
11978 * configure.ac (--enable-mm-debug): Fix typo.
11979
11980 * genkernsyms.sh.in: Use proper quoting for `CC'.
11981
11982 2006-07-02 Jeroen Dekkers <jeroen@dekkers.cx>
11983
11984 * conf/i386-pc.rmk (COMMON_ASFLAGS): Add "-m32".
11985 (normal_mod_ASFLAGS): Remove "-m32".
11986
11987 2006-06-14 Yoshinori K. Okuji <okuji@enbug.org>
11988
11989 * util/misc.c: Include config.h.
11990 [!HAVE_MEMALIGN]: Do not include malloc.h.
11991 (grub_memalign): Use posix_memalign, if present. Then, use
11992 memalign, if present. Otherwise, emit an error.
11993
11994 * util/grub-emu.c: Do not include malloc.h.
11995
11996 * include/grub/util/misc.h: Include unistd.h. This is required for
11997 FreeBSD, because off_t is defined in unistd.h. Reported by Harley
11998 D. Eades III <hde@foobar-qux.org>.
11999
12000 * configure.ac (AC_GNU_SOURCE): Added.
12001 (AC_CHECK_FUNCS): Check posix_memalign and memalign for the host
12002 type.
12003
12004 2006-06-09 Yoshinori K. Okuji <okuji@enbug.org>
12005
12006 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Make sure that
12007 ADDR_MAX does not exceed GRUB_LINUX_INITRD_MAX_ADDRESS.
12008
12009 2006-06-07 Jeroen Dekkers <jeroen@dekkers.cx>
12010
12011 * include/grub/types.h (grub_host_addr_t): Rename to
12012 grub_target_addr_t.
12013 (grub_host_off_t): Rename to grub_target_off_t.
12014 (grub_host_size_t): Rename to grub_target_size_t.
12015 (grub_host_ssize_t): Rename to grub_target_ssize_t.
12016 Refer to GRUB_TARGET_SIZEOF_VOID_P to define those variables.
12017
12018 * include/grub/kernel.h (struct grub_module_header): Change type
12019 of OFFSET to grub_target_off_t and type of SIZE to grub_target_size_t.
12020 (grub_module_info): Likewise.
12021
12022 2006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
12023
12024 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): The conditional
12025 of checking LINUX_MEM_SIZE was reverse. Reported by Jesus
12026 Velazquez <jesus.velazquez@gmail.com>.
12027
12028 2006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
12029
12030 Count partitions from 1 instead of 0 in the string representation
12031 of partitions. Still use 0-based internally.
12032
12033 * partmap/sun.c (grub_sun_is_valid): A cosmetic change.
12034 (sun_partition_map_iterate): Use grub_partition_t instead of
12035 struct grub_partition *. Cast DESC->START_CYLINDER to
12036 grub_uint64_t after converting the endian.
12037 (sun_partition_map_probe): Subtract 1 for PARTNUM.
12038 (sun_partition_map_get_name): Add 1 to P->INDEX.
12039
12040 * partmap/pc.c (grub_partition_parse): Subtract 1 for
12041 PCDATA->DOS_PART.
12042 (pc_partition_map_get_name): Add 1 into PCDATA->DOS_PART.
12043
12044 * partmap/gpt.c (gpt_partition_map_iterate): Initialize PARTNO to
12045 zero instead of one.
12046 (gpt_partition_map_probe): Subtract 1 for PARTNUM.
12047 (gpt_partition_map_get_name): Add 1 into P->INDEX.
12048
12049 * partmap/apple.c (apple_partition_map_iterate): Change the type
12050 of POS to unsigned.
12051 (apple_partition_map_probe): Subtract 1 for PARTNUM.
12052 (apple_partition_map_get_name): Add 1 into P->INDEX.
12053
12054 * partmap/amiga.c (amiga_partition_map_iterate): Change the type
12055 of POS to unsigned.
12056 (amiga_partition_map_iterate): Cast NEXT to grub_off_t to
12057 calculate the offset of a partition.
12058 (amiga_partition_map_probe): Subtract 1 for PARTNUM.
12059 (amiga_partition_map_get_name): Add 1 into P->INDEX.
12060
12061 * partmap/acorn.c (acorn_partition_map_find): Change the type of
12062 SECTOR to grub_disk_addr_t.
12063 (acorn_partition_map_iterate): Likewise.
12064 (acorn_partition_map_probe): Subtract 1 for PARTNUM.
12065 Change the type of SECTOR to grub_disk_addr_t. Declare P on the
12066 top.
12067 (acorn_partition_map_get_name): Add 1 into P->INDEX.
12068
12069 * kern/i386/pc/init.c (make_install_device): Add 1 into
12070 GRUB_INSTALL_DOS_PART.
12071
12072 * fs/iso9660.c (grub_iso9660_mount): Fixed a reversed
12073 conditional.
12074
12075 2006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
12076
12077 Clean up the code to support 64-bit addressing in disks and
12078 files. This change is not enough for filesystems yet.
12079
12080 * util/i386/pc/grub-setup.c (struct boot_blocklist): Change the
12081 type of "start" to grub_uint64_t.
12082 (setup): Change the types of KERNEL_SECTOR and FIRST_SECTOR to
12083 grub_disk_addr_t * and grub_disk_addr_t. Fix the format string in
12084 save_first_sector and save_blocklists. Use grub_le_to_cpu64 to
12085 convert addresses.
12086
12087 * util/i386/pc/biosdisk.c (open_device): Change the type of SECTOR
12088 to grub_disk_addr_t.
12089
12090 * partmap/gpt.c (gpt_partition_map_iterate): Fix the format
12091 string.
12092
12093 * partmap/pc.c (pc_partition_map_iterate): Likewise.
12094
12095 * partmap/amiga.c (amiga_partition_map_iterate): Cast RDSK.MAGIC
12096 to char *.
12097
12098 * normal/script.c (grub_script_parse): Remove unused MEMFREE.
12099
12100 * normal/parser.y (YYLTYPE_IS_TRIVIAL): New macro.
12101
12102 * normal/lexer.c (grub_script_yyerror): Specify unused to LEX.
12103
12104 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf64): Cast -1
12105 to grub_off_t, to detect an error from grub_file_seek.
12106 (grub_multiboot_load_elf32): Likewise.
12107
12108 * kern/misc.c (grub_strtoul): Use grub_strtoull. Return the
12109 maximum unsigned long value when an overflow is detected.
12110 (grub_strtoull): New function.
12111 (grub_divmod64): Likewise.
12112 (grub_lltoa): use grub_divmod64.
12113
12114 * kern/fs.c (struct grub_fs_block): Change the type of "offset" to
12115 grub_disk_addr_t.
12116 (grub_fs_blocklist_open): Increase P if P is not NULL to advance
12117 the pointer to next character. Use grub_strtoull instead of
12118 grub_strtoul.
12119 (grub_fs_blocklist_read): Change the types of SECTOR, OFFSET and
12120 SIZE to grub_disk_addr_t, grub_off_t and grub_size_t,
12121 respectively.
12122
12123 * kern/file.c (grub_file_read): Prevent an overflow of LEN, as the
12124 return value is signed.
12125 (grub_file_seek): Change the type of OLD to grub_off_t. Do not
12126 test if OFFSET is less than zero, as OFFSET is unsigned now.
12127
12128 * kern/disk.c (struct grub_disk_cache): Change the type of
12129 "sector" to grub_disk_addr_t.
12130 (grub_disk_cache_get_index): Change the type of SECTOR to
12131 grub_disk_addr_t. Calculate the hash with SECTOR casted to
12132 unsigned after shifting.
12133 (grub_disk_cache_invalidate): Change the type of SECTOR to
12134 grub_disk_addr_t.
12135 (grub_disk_cache_unlock): Likewise.
12136 (grub_disk_cache_store): Likewise.
12137 (grub_disk_check_range): Change the types of SECTOR, OFFSET, SIZE,
12138 START and LEN to grub_disk_addr_t *, grub_off_t *, grub_size_t,
12139 grub_disk_addr_t and grub_uint64_t, respectively.
12140 (grub_disk_read): Use an unsigned variable REAL_OFFSET for the
12141 body, as the value of OFFSET is tweaked by
12142 grub_disk_check_range. Change the types of START_SECTOR, LEN and
12143 POS to grub_disk_addr_t, grub_size_t and grub_size_t,
12144 respectively.
12145 (grub_disk_write): Use an unsigned variable REAL_OFFSET for the
12146 body, as the value of OFFSET is tweaked by
12147 grub_disk_check_range. Change the types of LEN and N to
12148 grub_size_t.
12149
12150 * io/gzio.c (struct grub_gzio): Change the types of "data_offset"
12151 and "saved_offset" to grub_off_t.
12152 (test_header): Cast BUF to char *.
12153 (get_byte): Cast GZIO->DATA_OFFSET to grub_off_t. Cast GZIO->INBUF
12154 to char *.
12155 (grub_gzio_read): Change the types of OFFSET and SIZE to
12156 grub_off_t and grub_size_t, respectively.
12157
12158 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_FORCE_LBA):
12159 Removed.
12160 (GRUB_BOOT_MACHINE_BOOT_DRIVE): Changed to 0x4c.
12161 (GRUB_BOOT_MACHINE_KERNEL_ADDRESS): Changed to 0x40.
12162 (GRUB_BOOT_MACHINE_KERNEL_SEGMENT): Changed to 0x42.
12163 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Changed to 0x4e.
12164 (GRUB_BOOT_MACHINE_LIST_SIZE): Increased to 12.
12165
12166 * include/grub/types.h (grub_off_t): Unconditionally set to
12167 grub_uint64_t.
12168 (grub_disk_addr_t): Changed to grub_uint64_t.
12169
12170 * include/grub/partition.h (struct grub_partition): Change the
12171 types of "start", "len" and "offset" to grub_disk_addr_t,
12172 grub_uint64_t and grub_disk_addr_t, respectively.
12173 (grub_partition_get_start): Return grub_disk_addr_t.
12174 (grub_partition_get_len): Return grub_uint64_t.
12175
12176 * include/grub/misc.h (grub_strtoull): New prototype.
12177 (grub_divmod64): Likewise.
12178
12179 * include/grub/fshelp.h (grub_fshelp_read_file): Change the types
12180 of SECTOR, LEN and FILESIZE to grub_disk_addr_t, grub_size_t and
12181 grub_off_t, respectively.
12182 All callers and references changed.
12183
12184 * include/grub/fs.h (struct grub_fs): Change the type of LEN to
12185 grub_size_t in "read".
12186 All callers and references changed.
12187
12188 * include/grub/file.h (struct grub_file): Change the types of
12189 "offset" and "size" to grub_off_t and grub_off_t,
12190 respectively. Change the type of SECTOR to grub_disk_addr_t in
12191 "read_hook".
12192 (grub_file_read): Change the type of LEN to grub_size_t.
12193 (grub_file_seek): Return grub_off_t. Change the type of OFFSET to
12194 grub_off_t.
12195 (grub_file_size): Return grub_off_t.
12196 (grub_file_tell): Likewise.
12197 All callers and references changed.
12198
12199 * include/grub/disk.h (struct grub_disk_dev): Change the types of
12200 SECTOR and SIZE to grub_disk_addr_t and grub_size_t in "read" and
12201 "write".
12202 (struct grub_disk): Change the type of "total_sectors" to
12203 grub_uint64_t. Change the type of SECTOR to grub_disk_addr_t in
12204 "read_hook".
12205 (grub_disk_read): Change the types of SECTOR, OFFSET and SIZE to
12206 grub_disk_addr_t, grub_off_t and grub_size_t, respectively.
12207 (grub_disk_write): Likewise.
12208 All callers and references changed.
12209
12210 * fs/iso9660.c (grub_iso9660_susp_iterate): Cast parameters to
12211 char * for grub_strncmp to silence gcc.
12212 (grub_iso9660_mount): Likewise.
12213 (grub_iso9660_mount): Likewise.
12214 (grub_iso9660_read_symlink): Likewise. Also, remove the nonsense
12215 return statement.
12216 (grub_iso9660_iterate_dir): Likewise.
12217 (grub_iso9660_label): Cast DATA->VOLDESC.VOLNAME to char *.
12218
12219 * fs/hfs.c (grub_hfs_read_file): Change the types of SECTOR and
12220 LEN to grub_disk_addr_t and grub_size_t, respectively.
12221
12222 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
12223
12224 * fs/jfs.c (grub_jfs_read_file): Likewise.
12225
12226 * fs/minix.c (grub_jfs_read_file): Likewise.
12227
12228 * fs/sfs.c (grub_jfs_read_file): Likewise.
12229
12230 * fs/ufs.c (grub_jfs_read_file): Likewise.
12231
12232 * fs/xfs.c (grub_jfs_read_file): Likewise.
12233
12234 * fs/fat.c (grub_fat_read_data): Change the types of SECTOR, LEN
12235 and SIZE to grub_disk_addr_t, grub_size_t and grub_size_t,
12236 respectively.
12237
12238 * fs/ext2.c (grub_ext2_read_block): When an error happens, set
12239 BLKNR to -1 instead of returning GRUB_ERRNO.
12240 (grub_ext2_read_file): Change the types of SECTOR and
12241 LEN to grub_disk_addr_t and grub_size_t, respectively.
12242
12243 * fs/affs.c (grub_affs_read_file): Change the types of SECTOR and
12244 LEN to grub_disk_addr_t and grub_size_t, respectively.
12245
12246 * font/manager.c (grub_font_get_glyph): Cast BITMAP to char * for
12247 grub_file_read.
12248
12249 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Fix the format
12250 string. Do not cast SECTOR explicitly.
12251
12252 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): Change the type of
12253 TOTAL_SECTORS to grub_uint64_t. Do not mask DRP->TOTAL_SECTORS.
12254 (grub_biosdisk_rw): Change the types of SECTOR and SIZE to
12255 grub_disk_addr_t and grub_size_t, respectively. If the sector is
12256 over 2TB and LBA mode is not supported, raise an error.
12257 (get_safe_sectors): New function.
12258 (grub_biosdisk_read): Use get_safe_sectors.
12259 (grub_biosdisk_write): Likewise.
12260
12261 * disk/efi/efidisk.c (grub_efidisk_read): Fix the format string.
12262 (grub_efidisk_write): Likewise.
12263
12264 * disk/loopback.c (delete_loopback): Cosmetic changes.
12265 (grub_cmd_loopback): Likewise. Also, test NEWDEV->FILENAME
12266 correctly.
12267 (grub_loopback_open): Likewise.
12268 (grub_loopback_read): Likewise. Also, change the type of POS to
12269 grub_off_t, and fix the usage of grub_memset.
12270
12271 * commands/i386/pc/play.c: Include grub/machine/time.h.
12272
12273 * commands/ls.c (grub_ls_list_files): Use "llu" instead of "d" to
12274 print FILE->SIZE.
12275
12276 * commands/configfile.c: Include grub/env.h.
12277
12278 * commands/cmp.c (grub_cmd_cmp): Do not use ERR, but use
12279 GRUB_ERRNO directly instead. Change the type of POS to
12280 grub_off_t. Follow the coding standard.
12281
12282 * commands/blocklist.c: Include grub/partition.h.
12283 (grub_cmd_blocklist): Return an error if the underlying device is
12284 not a disk. Take the starting sector of a partition into account,
12285 if a partition is used.
12286
12287 * boot/i386/pc/diskboot.S (bootloop): Adapted to the new offset of
12288 a length field.
12289 (lba_mode): Support 64-bit addresses.
12290 (chs_mode): Likewise.
12291 (copy_buffer): Adapted to the new offsets of a length field and a
12292 segment field.
12293 (blocklist_default_start): Allocate 64-bit space.
12294
12295 * boot/i386/pc/boot.S (force_lba): Removed.
12296 (boot_drive): Moved to under KERNEL_SECTOR.
12297 (kernel_sector): Moved to under KERNEL_SEGMENT. Allocate 64-bit
12298 space.
12299 (real_start): Set %si earlier. Remove code for FORCE_LBA, since it
12300 is useless.
12301 (lba_mode): Refactored to support a 64-bit address. More size
12302 optimization.
12303 (setup_sectors): Likewise.
12304
12305 2006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
12306
12307 * DISTLIST: Added include/grub/i386/linux.h. Removed
12308 include/grub/i386/pc/linux.h
12309
12310 * configure.ac (AC_INIT): Bumped to 1.94.
12311
12312 * config.guess: Updated from gnulib.
12313 * config.sub: Likewise.
12314 * install-sh: Likewise.
12315 * mkinstalldirs: Likewise.
12316
12317 2006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
12318
12319 * conf/common.rmk (grub_modules_init.lst): Depended on
12320 grub_emu_SOURCES, excluding grub_emu_init.c, instead of
12321 MODSRCFILES.
12322
12323 * genmk.rb (PModule::rule): Reverted the previous change.
12324
12325 2006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
12326
12327 * conf/common.rmk (grub_modules_init.lst): Depends on
12328 $(MODSRCFILES). Grep only the files in $(MODSRCFILES). Make sure
12329 that the target does not exist before producing.
12330 (grub_modules_init.h): Remove the target before generating.
12331 (grub_emu_init.c): Likewise.
12332
12333 * genmk.rb (PModule::rule): Add source files into MODSRCFILES.
12334
12335 2006-05-31 Jeroen Dekkers <jeroen@dekkers.cx>
12336
12337 * configure.ac: Don't set host_m32 for x86_64. Also reset LIBS
12338 for the target-specific tests. Make sure that we also have the
12339 up-to-date target variables for those tests.
12340
12341 2006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
12342
12343 * genmk.rb (Image::rule): Prefix CFLAGS or ASFLAGS with TARGET_.
12344 (PModule::rule): Likewise.
12345
12346 2006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
12347
12348 * genmk.rb (Image::rule): Set FLAG to CFLAGS or ASFLAGS instead of
12349 TARGET_CFLAGS or TARGET_ASFLAGS. There is no reason why
12350 target-specific flags should be prefixed.
12351 (PModule::rule): Likewise.
12352
12353 2006-05-30 Yoshinori K. Okuji <okuji@enbug.org>
12354
12355 * configure.ac (CMP): Check if cmp is available explicitly.
12356
12357 2006-05-29 Yoshinori K. Okuji <okuji@enbug.org>
12358
12359 * util/powerpc/ieee1275/grub-install.in (host_cpu): Removed.
12360 (target_cpu): New variable.
12361 (pkglibdir): Use target_cpu instead of host_cpu.
12362
12363 * util/i386/pc/grub-install.in (host_cpu): Removed.
12364 (target_cpu): New variable.
12365 (pkglibdir): Use target_cpu instead of host_cpu.
12366
12367 * util/genmoddep.c: Removed.
12368
12369 * kern/efi/mm.c (filter_memory_map): Use GRUB_CPU_SIZEOF_VOID_P
12370 instead of GRUB_HOST_SIZEOF_VOID_P.
12371 * kern/dl.c: Likewise.
12372
12373 * include/grub/i386/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed to
12374 ...
12375 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
12376 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
12377 (GRUB_TARGET_SIZEOF_LONG): ... this.
12378 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
12379 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
12380 * include/grub/powerpc/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
12381 to ...
12382 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
12383 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
12384 (GRUB_TARGET_SIZEOF_LONG): ... this.
12385 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
12386 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
12387 * include/grub/sparc64/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
12388 to ...
12389 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
12390 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
12391 (GRUB_TARGET_SIZEOF_LONG): ... this.
12392 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
12393 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
12394
12395 * include/grub/types.h [!GRUB_UTIL] (GRUB_CPU_SIZEOF_VOID_P): Use
12396 GRUB_TARGET_SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P.
12397 [!GRUB_UTIL] (GRUB_CPU_SIZEOF_LONG): Use GRUB_TARGET_SIZEOF_LONG
12398 instead of GRUB_HOST_SIZEOF_LONG.
12399 [!GRUB_UTIL]: Refer to GRUB_TARGET_WORDS_BIGENDIAN instead of
12400 GRUB_HOST_WORDS_BIGENDIAN to define or undefine
12401 GRUB_CPU_WORDS_BIGENDIAN.
12402 Refer to SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P to
12403 define grub_host_addr_t, grub_host_off_t, grub_host_size_t and
12404 grub_host_ssize_t.
12405
12406 * conf/i386-efi.rmk (noinst_UTILITIES): Removed.
12407 (genmoddep_SOURCES): Likewise.
12408 * conf/i386-pc.rmk (noinst_UTILITIES): Likewise.
12409 (genmoddep_SOURCES): Likewise.
12410 * conf/conf/powerpc-ieee1275.rmk (noinst_UTILITIES): Likewise.
12411 (genmoddep_SOURCES): Likewise.
12412 * conf/conf/conf/sparc64-ieee1275.rmk (noinst_UTILITIES):
12413 Likewise.
12414 (genmoddep_SOURCES): Likewise.
12415
12416 * genmoddep.awk: New file.
12417
12418 * genmk.rb (Image::rule): Use TARGET_CC, TARGET_CPPFLAGS,
12419 TARGET_CFLAGS, TARGET_ASFLAGS and TARGET_LDFLAGS instead of CC,
12420 CPPFLAGS, CFLAGS, ASFLAGS and LDFLAGS, respectively.
12421 (PModule::rule): Likewise.
12422 (Program::rule): Likewise.
12423 (Utility::rule): Use CC, CPPFLAGS, CFLAGS and LDFLAGS instead of
12424 BUILD_CC, BUILD_CPPFLAGS, BUILD_CFLAGS and BUILD_LDFLAGS,
12425 respectively.
12426
12427 * configure.ac: Rewritten intensively to use host and target
12428 instead of build and host, respectively.
12429
12430 * Makefile.in (pkglibdir): Use target_cpu instead of host_cpu.
12431 (host_cpu): Removed.
12432 (target_cpu): New variable.
12433 (CPPFLAGS): Added @CPPFLAGS@ and -DGRUB_LIBDIR=\"$(pkglibdir)\".
12434 (BUILD_CC): Removed.
12435 (BUILD_CFLAGS): Likewise.
12436 (BUILD_CPPFLAGS): Likewise.
12437 (TARGET_CC): New variable.
12438 (TARGET_CFLAGS): Likewise.
12439 (TARGET_CPPFLAGS): Likewise.
12440 (TARGET_LDFLAGS): Likewise.
12441 (AWK): Likewise.
12442 (include): Use target_cpu instead of host_cpu.
12443 (moddep.lst:): Use genmoddep.awk instead of genmoddep.
12444
12445 * DISTLIST: Added genmoddep.awk. Removed util/genmoddep.c.
12446
12447 2006-05-29 Vesa Jaaskelainen <chaac@nic.fi>
12448
12449 * include/grub/script.h (grub_script_cmdif): Renamed field 'bool' to
12450 'exec_to_evaluate'. Renamed field 'true' to 'exec_on_true'. Renamed
12451 field 'false' to 'exec_on_false'.
12452 (grub_script_create_cmdif): Renamed argument names to reflect above
12453 changes.
12454
12455 * normal/execute.c (grub_script_execute_cmdif): Likewise.
12456
12457 * normal/script.c (grub_script_create_cmdif): Likewise.
12458
12459 2006-05-28 Yoshinori K. Okuji <okuji@enbug.org>
12460
12461 * fs/hfsplus.c (grub_hfsplus_btree_recoffset): Moved to near the
12462 top.
12463 (grub_hfsplus_btree_recptr): Likewise.
12464 (grub_hfsplus_find_block): Do not take RETRY any longer. Use
12465 FILEBLOCK both to pass a block number and store next block
12466 number.
12467 (grub_hfsplus_read_block): Rewritten heavily to support an extent
12468 overflow file correctly. Specify errors appropriately, because
12469 fshelp expects that GRUB_ERRNO is set when fails. Reuse
12470 grub_hfsplus_btree_recptr to get the pointer to a found key.
12471 (grub_hfsplus_btree_search): Return 1 instead of 0 when no match
12472 is found.
12473
12474 * conf/i386-efi.rmk (pkgdata_MODULES): Added _linux.mod and
12475 linux.mod.
12476 (_linux_mod_SOURCES): New variable.
12477 (_linux_mod_CFLAGS): Likewise.
12478 (_linux_mod_LDFLAGS): Likewise.
12479 (linux_mod_SOURCES): Likewise.
12480 (linux_mod_CFLAGS): Likewise.
12481 (linux_mod_LDFLAGS): Likewise.
12482
12483 * DISTLIST: Added loader/i386/efi/linux.c,
12484 loader/i386/efi/linux_normal.c and
12485 include/grub/i386/efi/loader.h.
12486
12487 * loader/i386/efi/linux.c: New file.
12488 * loader/i386/efi/linux_normal.c: Likewise.
12489 * include/grub/i386/efi/loader.h: Likewise.
12490
12491 2006-05-27 Yoshinori K. Okuji <okuji@enbug.org>
12492
12493 * commands/blocklist.c: New file.
12494
12495 * DISTLIST: Added commands/blocklist.c.
12496
12497 * term/efi/console.c (grub_console_highlight_color): Use a lighter
12498 color for the background, and a darker color for the foreground.
12499 (grub_console_checkkey): Return READ_KEY.
12500 (grub_console_cls): Set the background to
12501 GRUB_EFI_BACKGROUND_BLACK temporarily to clean out the screen.
12502
12503 * kern/efi/efi.c (grub_efi_exit_boot_services): New function.
12504
12505 * include/grub/i386/linux.h (struct linux_kernel_params): Fixed
12506 the size of "padding5", "hd0_drive_info" and "hd1_drive_info".
12507
12508 * include/grub/efi/efi.h (grub_efi_exit_boot_services): New
12509 prototype.
12510
12511 * include/grub/efi/api.h (GRUB_EFI_TEXT_ATTR): Do not shift
12512 BG. The spec is wrong again.
12513
12514 * include/grub/normal.h [GRUB_UTIL] (grub_blocklist_init): New
12515 prototype.
12516 [GRUB_UTIL] (grub_blocklist_fini): Likewise.
12517
12518 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
12519 commands/blocklist.c.
12520 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
12521
12522 * conf/common.rmk (pkgdata_MODULES): Added blocklist.mod.
12523 (blocklist_mod_SOURCES): New variable.
12524 (blocklist_mod_CFLAGS): Likewise.
12525 (blocklist_mod_LDFLAGS): Likewise.
12526
12527 2006-05-20 Yoshinori K. Okuji <okuji@enbug.org>
12528
12529 * boot/i386/pc/boot.S (real_start): Set %si earlier to eliminate
12530 duplication.
12531 (lba_mode): Use %eax more intensively to reduce the code size.
12532
12533 2006-05-20 Marco Gerards <marco@gnu.org>
12534
12535 * normal/lexer.c (grub_script_yylex): Don't filter out newlines.
12536
12537 * normal/parser.y (commandblock): Defined as <cmd>. A subroutine
12538 for `menuentry'.
12539 (script): Accept leading newlines.
12540 (newlines): New rule to describe 0 or more newlines.
12541 (commands): Accept `command' with trailing newline. Fixed the
12542 order in which arguments were passed to `grub_script_add_cmd'.
12543 Accept commands separated by newlines.
12544 (function): Changed to accept newlines.
12545 (menuentry) Rewritten.
12546
12547 * normal/script.c (grub_script_create_cmdmenu): Add new entries in
12548 front of the list, instead of to the end.
12549
12550 2006-05-19 Yoshinori K. Okuji <okuji@enbug.org>
12551
12552 * util/i386/pc/grub-install.in (bindir): New variable.
12553 (grub_mkimage): Use BINDIR instead of SBINDIR. Reported by Lee
12554 Shaver <lbgwjl@gmail.com>.
12555
12556 2006-05-14 Yoshinori K. Okuji <okuji@enbug.org>
12557
12558 * kern/i386/pc/startup.S: Include grub/cpu/linux.h instead of
12559 grub/machine/linux.h
12560 * loader/i386/pc/linux.c: Likewise.
12561
12562 * include/grub/i386/pc/linux.h: Moved to ...
12563 * include/grub/i386/linux.h: ... here.
12564
12565 * include/grub/i386/linux.h (struct linux_kernel_params): New
12566 struct.
12567
12568 2006-05-09 Vesa Jaaskelainen <chaac@nic.fi>
12569
12570 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Corrected bounds
12571 checking.
12572 (grub_video_vbe_blit_glyph): Likewise.
12573 (grub_video_vbe_blit_bitmap): Likewise.
12574 (grub_video_vbe_blit_render_target): Likewise.
12575
12576 2006-05-09 Yoshinori K. Okuji <okuji@enbug.org>
12577
12578 * configure.ac (--with-platform): Properly quote the square
12579 brackets.
12580
12581 2006-05-08 Marco Gerards <marco@gnu.org>
12582
12583 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Renamed from
12584 this...
12585 (kernel_elf_HEADERS): ...to this. Updated all users.
12586 (grubof_symlist.c): Renamed from this...
12587 (kernel_elf_symlist.c): ...to this. Updated all users.
12588 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
12589 (grubof_SOURCES): Renamed from this...
12590 (kernel_elf_SOURCES): ...to this.
12591 (grubof_HEADERS): Renamed from this...
12592 (kernel_elf_HEADERS): ...to this.
12593 (grubof_CFLAGS): Renamed from this...
12594 (kernel_elf_CFLAGS): ...to this.
12595 (grubof_ASFLAGS): Renamed from this...
12596 (kernel_elf_ASFLAGS): ...to this.
12597 (grubof_LDFLAGS): Renamed from this...
12598 (kernel_elf_LDFLAGS): ...to this.
12599
12600 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Renamed from
12601 this...
12602 (kernel_elf_HEADERS): ...to this. Updated all users.
12603 (grubof_symlist.c): Renamed from this...
12604 (kernel_elf_symlist.c): ...to this. Updated all users.
12605 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
12606 (grubof_SOURCES): Renamed from this...
12607 (kernel_elf_SOURCES): ...to this.
12608 (grubof_HEADERS): Renamed from this...
12609 (kernel_elf_HEADERS): ...to this.
12610 (grubof_CFLAGS): Renamed from this...
12611 (kernel_elf_CFLAGS): ...to this.
12612 (grubof_ASFLAGS): Renamed from this...
12613 (kernel_elf_ASFLAGS): ...to this.
12614 (grubof_LDFLAGS): Renamed from this...
12615 (kernel_elf_LDFLAGS): ...to this.
12616
12617 * util/powerpc/ieee1275/grub-mkimage.c (add_segments): Use
12618 `kernel.elf' instead of `grubof'.
12619
12620 2006-05-08 Yoshinori K. Okuji <okuji@enbug.org>
12621
12622 Add --with-platform to configure. Use pkglibdir instead of
12623 pkgdatadir. This is reported by Roger Leigh.
12624
12625 * util/powerpc/ieee1275/grub-install.in (datadir): Removed.
12626 (host_vendor): Likewise.
12627 (host_os): Likewise.
12628 (pkgdatadir): Likewise.
12629 (platform): New variable.
12630 (pkglibdir): Likewise.
12631 Use PKGLIBDIR instead of PKGDATADIR.
12632
12633 * util/i386/pc/grub-install.in (datadir): Removed.
12634 (host_vendor): Likewise.
12635 (host_os): Likewise.
12636 (pkgdatadir): Likewise.
12637 (platform): New variable.
12638 (pkglibdir): Likewise.
12639 Use PKGLIBDIR instead of PKGDATADIR.
12640
12641 * util/powerpc/ieee1275/grub-mkimage.c (usage): Use GRUB_LIBDIR
12642 instead of GRUB_DATADIR.
12643 (main): Likewise.
12644 * util/i386/pc/grub-mkimage.c (usage): Likewise.
12645 (main): Likewise.
12646 * util/i386/efi/grub-mkimage.c (usage): Likewise.
12647 (main): Likewise.
12648
12649 * configure.ac (--with-platform): New option.
12650 Use PLATFORM instead of HOST_VENDOR to specify a platform.
12651
12652 * Makefile.in: Include a makefile based on PLATFORM instead of
12653 HOST_VENDOR.
12654 (pkgdatadir): Not appended by the machine type.
12655 (pkglibdir): Appended by the machine type.
12656 (host_vendor): Removed.
12657 (platform): New variable.
12658 (BUILD_CPPFLAGS): Specify GRUB_LIBDIR instead of GRUB_DATADIR.
12659 (install-local): Use PKGLIBDIR instead of PKGDATADIR.
12660 (uninstall): Likewise.
12661
12662 2006-05-07 Yoshinori K. Okuji <okuji@enbug.org>
12663
12664 Use the environment context in the menu. Remove the commands
12665 "default" and "timeout", and use variables instead.
12666
12667 * normal/menu.c: Include grub/env.h.
12668 (print_entry): Cast TITLE to silence gcc.
12669 (get_timeout): New function.
12670 (set_timeout): Likewise.
12671 (get_entry_number): Likewise.
12672 (run_menu): Use a default entry, a fallback entry and a timeout
12673 in the environment variables "default", "fallback" and
12674 "timeout". Also, tweak the default entry if it is not within the
12675 current menu entries.
12676 (grub_menu_run): Use a fallback entry in the environment variable
12677 "fallback".
12678
12679 * normal/main.c (read_config_file): Do not initialize
12680 NEWMENU->DEFAULT_ENTRY, NEWMENU->FALLBACK_ENTRY or
12681 NEWMENU->TIMEOUT.
12682 (grub_normal_execute): Use a data slot to store the menu.
12683
12684 * include/grub/normal.h (struct grub_menu): Removed default_entry,
12685 fallback_entry and timeout.
12686 (struct grub_menu_list): Removed.
12687 (grub_menu_list_t): Likewise.
12688 (struct grub_context): Likewise.
12689 (grub_context_t): Likewise.
12690 (grub_context_get): Likewise.
12691 (grub_context_get_current_menu): Likewise.
12692 (grub_context_push_menu): Likewise.
12693 (grub_context_pop_menu): Likewise.
12694 (grub_default_init): Likewise.
12695 (grub_default_fini): Likewise.
12696 (grub_timeout_init): Likewise.
12697 (grub_timeout_fini): Likewise.
12698
12699 * conf/sparc64-ieee1275.rmk (pkgdata_MODULES): Removed default.mod
12700 and timeout.mod.
12701 (normal_mod_SOURCES): Removed normal/context.c.
12702
12703 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Removed
12704 commands/default.c, commands/timeout.c and normal/context.c.
12705 (normal_mod_SOURCES): Removed normal/context.c.
12706
12707 * conf/i386-pc.rmk (grub_emu_SOURCES): Removed commands/default.c,
12708 commands/timeout.c and normal/context.c.
12709 (normal_mod_SOURCES): Removed normal/context.c.
12710
12711 * conf/i386-efi.rmk (grub_emu_SOURCES): Removed
12712 commands/default.c, commands/timeout.c and normal/context.c.
12713 (normal_mod_SOURCES): Removed normal/context.c.
12714
12715 * conf/common.rmk (pkgdata_MODULES): Removed default.mod and
12716 timeout.mod.
12717 (default_mod_SOURCES): Removed.
12718 (default_mod_CFLAGS): Likewise.
12719 (default_mod_LDFLAGS): Likewise.
12720 (timeout_mod_SOURCES): Removed.
12721 (timeout_mod_CFLAGS): Likewise.
12722 (timeout_mod_LDFLAGS): Likewise.
12723
12724 * DISTLIST: Removed commands/default.c, commands/timeout.c and
12725 normal/context.c.
12726
12727 * commands/default.c: Removed.
12728 * commands/timeout.c: Likewise.
12729 * normal/context.c: Likewise.
12730
12731 2006-05-07 Vesa Jaaskelainen <chaac@nic.fi>
12732
12733 * kern/i386/pc/startup.S (grub_exit): Added missing .code32 tag.
12734
12735 2006-05-02 Yoshinori K. Okuji <okuji@enbug.org>
12736
12737 * kern/env.c (struct grub_env_context): Removed "sorted". Renamed
12738 "next" to "prev" for readability.
12739 (struct grub_env_sorted_var): New struct.
12740 (grub_env_context): Renamed to ...
12741 (initial_context): ... this.
12742 (grub_env_var_context): Renamed to ...
12743 (current_context): ... this.
12744 (grub_env_find): Look only at CURRENT_CONTEXT.
12745 (grub_env_context_open): Rewritten to copy exported variables from
12746 previous context.
12747 (grub_env_context_close): Rewritten according to the new
12748 scheme. Also, add an assertion to prevent the initial context from
12749 removed.
12750 (grub_env_insert): Removed the code for the sorted list.
12751 (grub_env_remove): Likewise.
12752 (grub_env_export): Simply mark the variable with
12753 GRUB_ENV_VAR_GLOBAL.
12754 (grub_env_set): A cosmetic change for naming consistency.
12755 (grub_env_get): Likewise.
12756 (grub_env_unset): Likewise.
12757 (grub_env_iterate): Rewritten to sort variables within this
12758 function.
12759 (grub_register_variable_hook): Fixed for naming consistency. Call
12760 grub_env_find again, only if NAME is not found at the first time.
12761 (mangle_data_slot_name): New function.
12762 (grub_env_set_data_slot): Likewise.
12763 (grub_env_get_data_slot): Likewise.
12764 (grub_env_unset_data_slot): Likewise.
12765
12766 * include/grub/env.h (grub_env_var_type): New enum.
12767 (GRUB_ENV_VAR_LOCAL): New constant.
12768 (GRUB_ENV_VAR_GLOBAL): Likewise.
12769 (GRUB_ENV_VAR_DATA): Likewise.
12770 (struct grub_env_var): Removed "sort_next" and "sort_prevp". Added
12771 "type".
12772 (grub_env_set): Replace VAR with NAME for consistency.
12773 (grub_register_variable_hook): Likewise.
12774 (grub_env_export): Specify the name of the argument.
12775 (grub_env_set_data_slot): New prototype.
12776 (grub_env_get_data_slot): Likewise.
12777 (grub_env_unset_data_slot): Likewise.
12778
12779 2006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
12780
12781 Extend the loader so that GRUB can accept a loader which comes
12782 back to GRUB when a loaded image exits. Also, this change adds
12783 support for a chainloader on EFI.
12784
12785 * term/efi/console.c: Include grub/misc.h.
12786 (grub_console_checkkey): Display a scan code on the top for
12787 debugging. This will be removed once the EFI port gets stable.
12788 Correct the scan code mapping.
12789
12790 * kern/efi/mm.c (sort_memory_map): Sort in a descending order to
12791 allocate memory from larger regions, in order to reduce the number
12792 of allocated regions. Otherwise, the MacOSX loader panics.
12793 (filter_memory_map): Avoid less than 1MB for compatibility with
12794 other loaders.
12795 (add_memory_regions): Allocate from the tail of a region, if
12796 possible, to avoid allocating a region near to 1MB, for the MacOSX
12797 loader.
12798
12799 * kern/efi/init.c (grub_efi_set_prefix): Specify
12800 GRUB_EFI_IMAGE_HANDLE to grub_efi_get_loaded_image.
12801
12802 * kern/efi/efi.c (grub_efi_get_loaded_image): Accept a new
12803 argument IMAGE_HANDLE and specify it to get a loaded image.
12804 (grub_arch_modules_addr): Specify GRUB_EFI_IMAGE_HANDLE to
12805 grub_efi_get_loaded_image.
12806 (grub_efi_get_filename): Divide the length by the size of
12807 grub_efi_char16_t.
12808 (grub_efi_get_device_path): New function.
12809 (grub_efi_print_device_path): Print End Device Path nodes. Divide
12810 the length by the size of grub_efi_char16_t for a file path device
12811 path node.
12812
12813 * kern/loader.c (grub_loader_noreturn): New variable.
12814 (grub_loader_set): Accept a new argument NORETURN. Set
12815 GRUB_LOADER_NORETURN to NORETURN.
12816 All callers changed.
12817 (grub_loader_boot): If GRUB_LOADER_NORETURN is false, do not call
12818 grub_machine_fini.
12819
12820 * include/grub/efi/efi.h (grub_efi_get_device_path): New
12821 prototype.
12822 (grub_efi_get_loaded_image): Take an argument to specify an image
12823 handle.
12824
12825 * include/grub/loader.h (grub_loader_set): Added one more argument
12826 NORETURN.
12827
12828 * disk/efi/efidisk.c (make_devices): Use grub_efi_get_device_path
12829 instead of grub_efi_open_protocol.
12830 (grub_efidisk_get_device_name): Likewise.
12831 (grub_efidisk_close): Print a newline.
12832 (grub_efidisk_get_device_handle): Fixed to use
12833 GRUB_EFI_DEVICE_PATH_SUBTYPE instead of
12834 GRUB_EFI_DEVICE_PATH_TYPE.
12835
12836 * disk/efi/efidisk.c (device_path_guid): Moved to ...
12837 * kern/efi/efi.c (device_path_guid): ... here.
12838
12839 * conf/i386-efi.rmk (pkgdata_MODULES): Added _chain.mod and
12840 chain.mod.
12841 (kernel_mod_HEADERS): Added efi/disk.h.
12842 (_chain_mod_SOURCES): New variable.
12843 (_chain_mod_CFLAGS): Likewise.
12844 (_chain_mod_LDFLAGS): Likewise.
12845 (chain_mod_SOURCES): Likewise.
12846 (chain_mod_CFLAGS): Likewise.
12847 (chain_mod_LDFLAGS): Likewise.
12848
12849 * DISTLIST: Added include/grub/efi/chainloader.h,
12850 loader/efi/chainloader.c and loader/efi/chainloader_normal.c.
12851
12852 * include/grub/efi/chainloader.h: New file.
12853 * loader/efi/chainloader.c: Likewise.
12854 * loader/efi/chainloader_normal.c: Likewise.
12855
12856 2006-04-30 Marco Gerards <marco@gnu.org>
12857
12858 * commands/configfile.c (grub_cmd_source): New function.
12859 (GRUB_MOD_INIT): Register the commands `source' and `.'.
12860 (GRUB_MOD_FINI): De-register the commands `source' and `.'.
12861
12862 2006-04-30 Marco Gerards <marco@gnu.org>
12863
12864 * normal/execute.c (grub_script_execute_cmd): Change the return
12865 type to `grub_err_t'. Correctly return the error.
12866 (grub_script_execute_cmdline): In case a command line is not a
12867 command or a function, try to interpret it as an assignment.
12868
12869 2006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
12870
12871 * fs/hfsplus.c (grub_hfsplus_read_block): Fixed a memory leak.
12872 (grub_hfsplus_iterate_dir): Reordered to skip unknown nodes. Also,
12873 skip a node whose name is obviously invalid as UTF-16,
12874 i.e. contains a NUL character. Stop the iteration when the last
12875 directory entry is found. Instead of using the return value of
12876 grub_hfsplus_btree_iterate_node, store the value in RET and use
12877 it, because the iterator can be stopped by the last directory
12878 entry.
12879
12880 2006-04-30 Marco Gerards <marco@gnu.org>
12881
12882 * include/grub/env.h (grub_env_export): New prototype. Reported
12883 by Jan C. Kleinsorge <jan.kleinsorge@udo.edu>.
12884
12885 2006-04-30 Marco Gerards <marco@gnu.org>
12886
12887 * fs/hfsplus.c (grub_hfsplus_iterate_dir): Correctly calculate the
12888 size of the extents in a catalog file record.
12889
12890 2006-04-29 Marco Gerards <marco@gnu.org>
12891
12892 * commands/configfile.c (grub_cmd_configfile): Execute the
12893 configfile within its own context.
12894
12895 * include/grub/env.h (grub_env_context_open): New prototype.
12896 (grub_env_context_close): Likewise.
12897
12898 * kern/env.c (grub_env): Removed.
12899 (grub_env_sorted): Likewise.
12900 (grub_env_context): New variable.
12901 (grub_env_var_context): Likewise.
12902 (grub_env_find): Search both the active context and the global
12903 context.
12904 (grub_env_context_open): New function.
12905 (grub_env_context_close): Likewise.
12906 (grub_env_insert): Likewise.
12907 (grub_env_remove): Likewise.
12908 (grub_env_export): Likewise.
12909 (grub_env_set): Changed to use helper functions to avoid code
12910 duplication.
12911 (grub_env_iterate): Rewritten so both the current context and the
12912 global context are being used.
12913
12914 * normal/command.c (export_command): New function.
12915 (grub_command_init): Register the `export' function.
12916
12917 2006-04-26 Yoshinori K. Okuji <okuji@enbug.org>
12918
12919 * util/i386/pc/grub-mkimage.c (compress_kernel): Cast arguments
12920 explicitly to suppress gcc's warnings.
12921 * fs/fat.c (grub_fat_find_dir): Likewise.
12922 (grub_fat_label): Likewise.
12923 * fs/xfs.c (grub_xfs_read_inode): Likewise.
12924 (grub_xfs_mount): Likewise.
12925 (grub_xfs_label): Likewise.
12926 * fs/affs.c (grub_affs_mount): Likewise.
12927 (grub_affs_label): Likewise.
12928 (grub_affs_iterate_dir): Likewise.
12929 * fs/sfs.c (grub_sfs_mount): Likewise.
12930 (grub_sfs_iterate_dir): Likewise.
12931 * fs/ufs.c (grub_ufs_lookup_symlink): Likewise.
12932 * fs/hfs.c (grub_hfs_mount): Likewise.
12933 (grub_hfs_cmp_catkeys): Likewise.
12934 (grub_hfs_find_dir): Likewise.
12935 (grub_hfs_dir): Likewise.
12936 (grub_hfs_label): Likewise.
12937 * fs/jfs.c (grub_jfs_mount): Likewise.
12938 (grub_jfs_opendir): Likewise.
12939 (grub_jfs_getent): Likewise.
12940 (grub_jfs_lookup_symlink): Likewise.
12941 (grub_jfs_label): Likewise.
12942 * fs/hfsplus.c (grub_hfsplus_cmp_catkey): Likewise.
12943 (grub_hfsplus_iterate_dir): Likewise.
12944 (grub_hfsplus_btree_iterate_node): Made static.
12945
12946 * util/grub-emu.c (prefix): New variable.
12947 (grub_machine_set_prefix): New function.
12948 (main): Do not set the environment variable "prefix" here. Only
12949 set PREFIX, which is used later by grub_machine_set_prefix.
12950
12951 * include/grub/video.h: Do not include grub/symbol.h.
12952 (grub_video_register): Not exported. This symbol is not defined in
12953 the kernel.
12954 (grub_video_unregister): Likewise.
12955 (grub_video_iterate): Likewise.
12956 (grub_video_setup): Likewise.
12957 (grub_video_restore): Likewise.
12958 (grub_video_get_info): Likewise.
12959 (grub_video_get_blit_format): Likewise.
12960 (grub_video_set_palette): Likewise.
12961 (grub_video_get_palette): Likewise.
12962 (grub_video_set_viewport): Likewise.
12963 (grub_video_get_viewport): Likewise.
12964 (grub_video_map_color): Likewise.
12965 (grub_video_map_rgb): Likewise.
12966 (grub_video_map_rgba): Likewise.
12967 (grub_video_fill_rect): Likewise.
12968 (grub_video_blit_glyph): Likewise.
12969 (grub_video_blit_bitmap): Likewise.
12970 (grub_video_blit_render_target): Likewise.
12971 (grub_video_scroll): Likewise.
12972 (grub_video_swap_buffers): Likewise.
12973 (grub_video_create_render_target): Likewise.
12974 (grub_video_delete_render_target): Likewise.
12975 (grub_video_set_active_render_target): Likewise.
12976
12977 * include/grub/symbol.h [GRUB_SYMBOL_GENERATOR] (EXPORT_FUNC):
12978 Undefined.
12979 [GRUB_SYMBOL_GENERATOR] (EXPORT_VAR): Likewise.
12980
12981 * conf/sparc64-ieee1275.rmk (grubof_symlist.c): Depended on
12982 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
12983 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
12984 instead of $(srcdir)/genkernsyms.sh.
12985
12986 * conf/powerpc-ieee1275.rmk (grubof_symlist.c): Depended on
12987 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
12988 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
12989 instead of $(srcdir)/genkernsyms.sh.
12990
12991 * conf/i386-pc.rmk (symlist.c): Depended on config.h. Use
12992 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
12993 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
12994 instead of $(srcdir)/genkernsyms.sh.
12995
12996 * conf/i386-efi.rmk (symlist.c): Depended on config.h. Use
12997 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
12998 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
12999 instead of $(srcdir)/genkernsyms.sh.
13000
13001 * configure.ac (AC_CONFIG_FILES): Added gensymlist.sh and
13002 genkernsyms.sh.
13003
13004 * Makefile.in (DISTCLEANFILES): Added gensymlist.sh and
13005 genkernsyms.sh.
13006 (gensymlist.sh): New target.
13007 (genkernsyms.sh): Likewise.
13008
13009 * DISTLIST: Removed genkernsyms.sh and gensymlist.sh. Added
13010 genkernsyms.sh.in and gensymlist.sh.in.
13011
13012 * genkernsyms.sh: Removed.
13013 * gensymlist.sh: Likewise.
13014
13015 * genkernsyms.sh.in: New file.
13016 * gensymlist.sh.in: Likewise.
13017
13018 2006-04-25 Hollis Blanchard <hollis@penguinppc.org>
13019
13020 * kern/powerpc/ieee1275/init.c (grub_machine_set_prefix): Do not
13021 clobber "prefix", since we may have already set it manually.
13022
13023 2006-04-25 Hollis Blanchard <hollis@penguinppc.org>
13024
13025 * kern/misc.c (abort): New alias for grub_abort.
13026
13027 2006-04-25 Yoshinori K. Okuji <okuji@enbug.org>
13028
13029 A new machine-specific function "grub_machine_set_prefix" is
13030 defined. This is called after loading modules, so that a prefix
13031 initialization can use modules. Also, this change adds an
13032 intensive debugging feature for the memory manager via the
13033 configure option "--enable-mm-debug".
13034
13035 * partmap/gpt.c (gpt_partition_map_iterate): Add one more into
13036 PART.LEN.
13037
13038 * kern/sparc64/ieee1275/init.c (abort): Removed.
13039 (grub_stop): Likewise.
13040 (grub_exit): New function.
13041 (grub_set_prefix): Renamed to ...
13042 (grub_machine_set_prefix): ... this.
13043 (grub_machine_init): Do not call grub_set_prefix.
13044
13045 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Renamed to ...
13046 (grub_machine_set_prefix): ... this.
13047 (grub_machine_init): Do not call grub_set_prefix.
13048
13049 * kern/i386/pc/init.c (grub_machine_set_prefix): New function.
13050 (grub_machine_init): Do not set the prefix here.
13051
13052 * kern/i386/efi/init.c (grub_machine_set_prefix): New function.
13053
13054 * kern/efi/init.c: Include grub/mm.h.
13055 (grub_efi_set_prefix): New function.
13056
13057 * kern/efi/efi.c (grub_exit): Call grub_efi_fini.
13058 (grub_efi_get_filename): New function.
13059 (grub_print_device_path): Renamed to ...
13060 (grub_efi_print_device_path): ... this.
13061
13062 * kern/mm.c [MM_DEBUG] (grub_malloc): Undefined.
13063 [MM_DEBUG] (grub_realloc): Likewise.
13064 [MM_DEBUG] (grub_free): Likewise.
13065 [MM_DEBUG] (grub_memalign): Likewise.
13066 [MM_DEBUG] (grub_mm_debug): New variable.
13067 [MM_DEBUG] (grub_debug_malloc): New function.
13068 [MM_DEBUG] (grub_debug_free): New function.
13069 [MM_DEBUG] (grub_debug_realloc): New function.
13070 [MM_DEBUG] (grub_debug_memalign): New function.
13071
13072 * kern/misc.c (grub_abort): Print a newline to distinguish
13073 the message.
13074
13075 * kern/main.c (grub_main): Call grub_machine_set_prefix and
13076 grub_set_root_dev after loading modules. This is necessary when
13077 setting a prefix depends on modules.
13078
13079 * include/grub/efi/efi.h (grub_print_device_path): Renamed to ...
13080 (grub_efi_print_device_path): ... this.
13081 (grub_efi_get_filename): New prototype.
13082 (grub_efi_set_prefix): Likewise.
13083
13084 * include/grub/efi/disk.h: Include grub/efi/api.h, grub/symbol.h
13085 and grub/disk.h.
13086 (grub_efidisk_get_device_handle): New prototype.
13087 (grub_efidisk_get_device_name): Likewise.
13088
13089 * include/grub/mm.h: Include config.h.
13090 (MM_DEBUG): Removed.
13091 [MM_DEBUG && !GRUB_UTIL] (grub_mm_debug): New prototype.
13092 [MM_DEBUG && !GRUB_UTIL] (grub_malloc): New macro.
13093 [MM_DEBUG && !GRUB_UTIL] (grub_realloc): Likewise.
13094 [MM_DEBUG && !GRUB_UTIL] (grub_memalign): Likewise.
13095 [MM_DEBUG && !GRUB_UTIL] (grub_free): Likewise.
13096 [MM_DEBUG && !GRUB_UTIL] (grub_debug_malloc): New prototype.
13097 [MM_DEBUG && !GRUB_UTIL] (grub_debug_realloc): New prototype.
13098 [MM_DEBUG && !GRUB_UTIL] (grub_debug_memalign): New prototype.
13099 [MM_DEBUG && !GRUB_UTIL] (grub_debug_free): New prototype.
13100
13101 * include/grub/kernel.h (grub_machine_set_prefix): New prototype.
13102
13103 * disk/efi/efidisk.c: Include grub/partition.h.
13104 (iterate_child_devices): New function.
13105 (add_device): First, compare only last device path nodes, so that
13106 devices are sorted by the types.
13107 (grub_efidisk_get_device_handle): New function.
13108 (grub_efidisk_get_device_name): Likewise.
13109
13110 * configure.ac (--enable-mm-debug): New option to enable the
13111 memory manager debugging feature. This makes the binary much
13112 bigger, so is disabled by default.
13113
13114 2006-04-23 Yoshinori K. Okuji <okuji@enbug.org>
13115
13116 Use grub_abort instead of grub_stop, and grub_exit must be
13117 define in each architecture now. Also, this change adds support
13118 for EFI disks.
13119
13120 * util/i386/pc/grub-probefs.c: Include grub/term.h.
13121 (grub_getkey): New function.
13122 (grub_term_get_current): Likewise.
13123
13124 * util/i386/pc/grub-setup.c: Include grub/term.h.
13125 (grub_getkey): New function.
13126 (grub_term_get_current): Likewise.
13127
13128 * util/misc.c (grub_stop): Renamed to ...
13129 (grub_exit): ... this.
13130
13131 * kern/powerpc/ieee1275/init.c (abort): Renamed to ...
13132 (grub_exit): ... this.
13133 (grub_machine_init): Use grub_abort instead of abort.
13134 (grub_stop): Removed.
13135
13136 * kern/powerpc/ieee1275/cmain.c (cmain): Use grub_abort instead of
13137 abort.
13138
13139 * kern/i386/pc/startup.S (grub_exit): New function.
13140 (cold_reboot): New label.
13141
13142 * kern/efi/init.c: Include grub/efi/disk.h and grub/env.h.
13143 (grub_efi_init): Call grub_efidisk_init.
13144 (grub_efi_fini): Call grub_efidisk_fini.
13145
13146 * kern/efi/efi.c: Include grub/mm.h.
13147 (grub_efi_console_control_guid): Renamed to ...
13148 (console_control_guid): ... this.
13149 (grub_efi_loaded_image_guid): Renamed to ...
13150 (loaded_image_guid): ... this.
13151 (grub_efi_locate_handle): New function.
13152 (grub_efi_open_protocol): Likewise.
13153 (grub_efi_set_text_mode): Use CONSOLE_CONTROL_GUID instead of
13154 GRUB_EFI_CONSOLE_CONTROL_GUID.
13155 (grub_efi_exit): Removed.
13156 (grub_stop): Likewise.
13157 (grub_efi_get_loaded_image): Use grub_efi_open_protocol.
13158 (grub_exit): New function.
13159 (grub_print_device_path): Likewise.
13160
13161 * kern/rescue.c (grub_rescue_cmd_exit): New function.
13162 (grub_enter_rescue_mode): Register "exit".
13163
13164 * kern/misc.c (grub_real_dprintf): A cosmetic change.
13165 (grub_abort): New function.
13166
13167 * kern/err.c (grub_fatal): Use grub_abort instead of grub_stop.
13168
13169 * include/grub/sparc64/ieee1275/kernel.h (abort): Removed.
13170
13171 * include/grub/powerpc/ieee1275/kernel.h (abort): Removed.
13172
13173 * include/grub/efi/efi.h (grub_efi_exit): Removed.
13174 (grub_print_device_path): New prototype.
13175 (grub_efi_locate_handle): Likewise.
13176 (grub_efi_open_protocol): Likewise.
13177
13178 * include/grub/efi/disk.h (grub_efidisk_fini): New file.
13179 * disk/efi/efidisk.c: Likewise.
13180
13181 * DISTLIST: Added disk/efi/efidisk.c and include/grub/efi/disk.h.
13182
13183 * include/grub/efi/console_control.h
13184 (GRUB_EFI_CONSOLE_CONTROL_GUID): Use an array for the last 8 bytes.
13185
13186 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): Specify the
13187 last 8 bytes as an array.
13188 (GRUB_EFI_DISK_IO_GUID): New macro.
13189 (GRUB_EFI_BLOCK_IO_GUID): Likewise.
13190 (GRUB_EFI_DEVICE_PATH_GUID): Likewise.
13191 (grub_efi_ipv6_address_t): Change the type to grub_uint16_t from
13192 grub_uint8_t.
13193 (struct grub_efi_guid): Use an array to specify the last 8 bytes.
13194 (struct grub_efi_device_path): Rename the member "sub_type" to
13195 "subtype".
13196 (GRUB_EFI_DEVICE_PATH_TYPE): New macro.
13197 (GRUB_EFI_DEVICE_PATH_SUBTYPE): Likewise.
13198 (GRUB_EFI_DEVICE_PATH_LENGTH): Likewise.
13199 (GRUB_EFI_END_DEVICE_PATH_TYPE): Likewise.
13200 (GRUB_EFI_END_ENTIRE_DEVICE_PATH_SUBTYPE): Likewise.
13201 (GRUB_EFI_END_THIS_DEVICE_PATH_SUBTYPE): Likewise.
13202 (GRUB_EFI_END_ENTIRE_DEVICE_PATH): Likewise.
13203 (GRUB_EFI_NEXT_DEVICE_PATH): Likewise.
13204 (GRUB_EFI_HARDWARE_DEVICE_PATH_TYPE): Likewise.
13205 (GRUB_EFI_PCI_DEVICE_PATH_SUBTYPE): Likewise.
13206 (struct grub_efi_pci_device_path): New structure.
13207 (grub_efi_pci_device_path_t): New type.
13208 (GRUB_EFI_PCCARD_DEVICE_PATH_SUBTYPE): New macro.
13209 (struct grub_efi_pccard_device_path): New structure.
13210 (grub_efi_pccard_device_path_t): New type.
13211 (GRUB_EFI_MEMORY_MAPPED_DEVICE_PATH_SUBTYPE): New macro.
13212 (struct grub_efi_memory_mapped_device_path): New structure.
13213 (grub_efi_memory_mapped_device_path_t): New type.
13214 (GRUB_EFI_VENDOR_DEVICE_PATH_SUBTYPE): New macro.
13215 (struct grub_efi_vendor_device_path): New structure.
13216 (grub_efi_vendor_device_path_t): New type.
13217 (GRUB_EFI_CONTROLLER_DEVICE_PATH_SUBTYPE): New macro.
13218 (struct grub_efi_controller_device_path): New structure.
13219 (grub_efi_controller_device_path_t): New type.
13220 (GRUB_EFI_ACPI_DEVICE_PATH_TYPE): New macro.
13221 (GRUB_EFI_ACPI_DEVICE_PATH_SUBTYPE): Likewise.
13222 (struct grub_efi_acpi_device_path): New structure.
13223 (grub_efi_acpi_device_path_t): New type.
13224 (GRUB_EFI_EXPANDED_ACPI_DEVICE_PATH_SUBTYPE): New macro.
13225 (struct grub_efi_expanded_acpi_device_path): New structure.
13226 (grub_efi_expanded_acpi_device_path_t): New type.
13227 (GRUB_EFI_EXPANDED_ACPI_HIDSTR): New macro.
13228 (GRUB_EFI_EXPANDED_ACPI_UIDSTR): Likewise.
13229 (GRUB_EFI_EXPANDED_ACPI_CIDSTR): Likewise.
13230 (GRUB_EFI_MESSAGING_DEVICE_PATH_TYPE): Likewise.
13231 (GRUB_EFI_ATAPI_DEVICE_PATH_SUBTYPE): Likewise.
13232 (struct grub_efi_atapi_device_path): New structure.
13233 (grub_efi_atapi_device_path_t): New type.
13234 (GRUB_EFI_FIBRE_CHANNEL_DEVICE_PATH_SUBTYPE): New macro.
13235 (struct grub_efi_fibre_channel_device_path): New structure.
13236 (grub_efi_fibre_channel_device_path_t): New type.
13237 (GRUB_EFI_1394_DEVICE_PATH_SUBTYPE): New macro.
13238 (struct grub_efi_1394_device_path): New structure.
13239 (grub_efi_1394_device_path_t): New type.
13240 (GRUB_EFI_USB_DEVICE_PATH_SUBTYPE): New macro.
13241 (struct grub_efi_usb_device_path): New structure.
13242 (grub_efi_usb_device_path_t): New type.
13243 (GRUB_EFI_USB_CLASS_DEVICE_PATH_SUBTYPE): New macro.
13244 (struct grub_efi_usb_class_device_path): New structure.
13245 (grub_efi_usb_class_device_path_t): New type.
13246 (GRUB_EFI_I2O_DEVICE_PATH_SUBTYPE): New macro.
13247 (struct grub_efi_i2o_device_path): New structure.
13248 (grub_efi_i2o_device_path_t): New type.
13249 (GRUB_EFI_MAC_ADDRESS_DEVICE_PATH_SUBTYPE): New macro.
13250 (struct grub_efi_mac_address_device_path): New structure.
13251 (grub_efi_mac_address_device_path_t): New type.
13252 (GRUB_EFI_IPV4_DEVICE_PATH_SUBTYPE): New macro.
13253 (struct grub_efi_ipv4_device_path): New structure.
13254 (grub_efi_ipv4_device_path_t): New type.
13255 (GRUB_EFI_IPV6_DEVICE_PATH_SUBTYPE): New macro.
13256 (struct grub_efi_ipv6_device_path): New structure.
13257 (grub_efi_ipv6_device_path_t): New type.
13258 (GRUB_EFI_INFINIBAND_DEVICE_PATH_SUBTYPE): New macro.
13259 (struct grub_efi_infiniband_device_path): New structure.
13260 (grub_efi_infiniband_device_path_t): New type.
13261 (GRUB_EFI_UART_DEVICE_PATH_SUBTYPE): New macro.
13262 (struct grub_efi_uart_device_path): New structure.
13263 (grub_efi_uart_device_path_t): New type.
13264 (GRUB_EFI_VENDOR_MESSAGING_DEVICE_PATH_SUBTYPE): New macro.
13265 (struct grub_efi_vendor_messaging_device_path): New structure.
13266 (grub_efi_vendor_messaging_device_path_t): New type.
13267 (GRUB_EFI_MEDIA_DEVICE_PATH_TYPE): New macro.
13268 (GRUB_EFI_HARD_DRIVE_DEVICE_PATH_SUBTYPE): Likewise.
13269 (struct grub_efi_hard_drive_device_path): New structure.
13270 (grub_efi_hard_drive_device_path_t): New type.
13271 (GRUB_EFI_CDROM_DEVICE_PATH_SUBTYPE): New macro.
13272 (struct grub_efi_cdrom_device_path): New structure.
13273 (grub_efi_cdrom_device_path_t): New type.
13274 (GRUB_EFI_VENDOR_MEDIA_DEVICE_PATH_SUBTYPE): New macro.
13275 (struct grub_efi_vendor_media_device_path): New structure.
13276 (grub_efi_vendor_media_device_path_t): New type.
13277 (GRUB_EFI_FILE_PATH_DEVICE_PATH_SUBTYPE): New macro.
13278 (struct grub_efi_file_path_device_path): New structure.
13279 (grub_efi_file_path_device_path_t): New type.
13280 (GRUB_EFI_PROTOCOL_DEVICE_PATH_SUBTYPE): New macro.
13281 (struct grub_efi_protocol_device_path): New structure.
13282 (grub_efi_protocol_device_path_t): New type.
13283 (GRUB_EFI_BIOS_DEVICE_PATH_TYPE): New macro.
13284 (GRUB_EFI_BIOS_DEVICE_PATH_SUBTYPE): Likewise.
13285 (struct grub_efi_bios_device_path): New structure.
13286 (grub_efi_bios_device_path_t): New type.
13287 (struct grub_efi_disk_io): New structure.
13288 (grub_efi_disk_io_t): New type.
13289 (struct grub_efi_block_io_media): New structure.
13290 (grub_efi_block_io_media_t): New type.
13291 (struct grub_efi_block_io): New structure.
13292 (grub_efi_block_io_t): New type.
13293
13294 * include/grub/misc.h (grub_stop): Removed.
13295 (grub_exit): New prototype.
13296 (grub_abort): Likewise.
13297
13298 * include/grub/disk.h (enum grub_disk_dev_id): Added
13299 GRUB_DISK_DEVICE_EFIDISK_ID.
13300
13301 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added
13302 disk/efi/efidisk.c.
13303 (kernel_syms.lst): Remove the target if an error occurs.
13304
13305 2006-04-22 Yoshinori K. Okuji <okuji@enbug.org>
13306
13307 * kern/misc.c (grub_lltoa): Rewritten the decimal conversion part,
13308 as it was simply too buggy.
13309
13310 2006-04-21 Yoshinori K. Okuji <okuji@enbug.org>
13311
13312 * kern/misc.c (grub_lltoa): New function.
13313 (grub_vsprintf): Added support for the long long suffix,
13314 i.e. "ll".
13315
13316 2006-04-20 Hollis Blanchard <hollis@penguinppc.org>
13317
13318 * Makefile.in (LDFLAGS): Add variable.
13319 (LD): Remove variable.
13320 * configure.ac: Add -m32 to LDFLAGS.
13321 * genmk.rb (PModule#rule): Use $(CC) instead of $(LD).
13322 * conf/powerpc-ieee1275.rmk (COMMON_LDFLAGS): Add variable.
13323 (grubof_LDFLAGS): Use $(COMMON_LDFLAGS).
13324 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS, normal_mod_LDFLAGS,
13325 suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS): New
13326 variables.
13327 * conf/sparc64-ieee1275.rmk (COMMON_LDFLAGS): Add -nostdlib.
13328 * conf/i386-pc.rmk (COMMON_LDFLAGS): Add -nostdlib.
13329 * conf/i386-efi.rmk (COMMON_LDFLAGS): Add -nostdlib.
13330
13331 2006-04-20 Vesa Jaaskelainen <chaac@nic.fi>
13332
13333 * term/gfxterm.c (grub_gfxterm_getcharwidth): Fixed character
13334 length for unknown glyph.
13335
13336 2006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
13337
13338 Add support for pre-loaded modules into the EFI port.
13339
13340 * util/i386/efi/grub-mkimage.c (make_mods_section): Rewritten
13341 completely. Accept one more argument DIR. The caller has changed.
13342
13343 * kern/i386/efi/init.c (grub_arch_modules_addr): Removed.
13344
13345 * kern/efi/efi.c: Include grub/efi/pe32.h and grub/kernel.h.
13346 (grub_efi_loaded_image_guid): New variable.
13347 (grub_efi_get_loaded_image): New function.
13348 (grub_arch_modules_addr): Likewise.
13349
13350 * include/grub/efi/efi.h (grub_efi_get_loaded_image): New
13351 prototype.
13352
13353 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): New macro.
13354 (struct grub_efi_loaded_image): New structure.
13355 (grub_efi_loaded_image_t): New type.
13356
13357 2006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
13358
13359 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Compare the file
13360 size with GRUB_OS_AREA_SIZE as grub_size_t instead of
13361 grub_ssize_t. Reported by Jeff Chua <jeff84@silk.corp.fedex.com>.
13362
13363 2006-04-19 Roger Leigh <rleigh@whinlatter.ukfsn.org>
13364
13365 * DISTLIST: Added `util/powerpc/ieee1275/grub-install.in'.
13366
13367 2006-04-19 Yoshinori K. Okuji <okuji@enbug.org>
13368
13369 * DISTLIST: Added include/grub/efi/console.h,
13370 include/grub/efi/time.h, include/grub/i386/efi/kernel.h,
13371 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
13372
13373 * include/grub/efi/console.h: New file.
13374 * include/grub/efi/time.h: Likewise.
13375 * include/grub/i386/efi/kernel.h: Likewise.
13376 * kern/efi/init.c: Likewise.
13377 * kern/efi/mm.c: Likewise.
13378 * term/efi/console.c: Likewise.
13379
13380 * kern/i386/efi/init.c: Do not include grub/machine/time.h.
13381 (grub_stop): Removed.
13382 (grub_get_rtc): Likewise.
13383 (grub_machine_init): Simply call grub_efi_init.
13384 (grub_machine_fini): Call grub_efi_fini.
13385
13386 * kern/efi/efi.c: Include grub/machine/time.h and grub/term.h.
13387 (grub_efi_output_string): Removed.
13388 (grub_efi_stall): New function.
13389 (grub_stop): Likewise.
13390 (grub_get_rtc): Likewise.
13391
13392 * include/grub/efi/efi.h (grub_efi_output_string): Removed.
13393 (grub_efi_stall): New prototype.
13394 (grub_efi_allocate_pages): Likewise.
13395 (grub_efi_free_pages): Likewise.
13396 (grub_efi_get_memory_map): Likewise.
13397 (grub_efi_mm_init): Likewise.
13398 (grub_efi_mm_fini): Likewise.
13399 (grub_efi_init): Likewise.
13400 (grub_efi_fini): Likewise.
13401
13402 * include/grub/i386/efi/time.h: Do not include
13403 grub/symbol.h. Include grub/efi/time.h.
13404 (GRUB_TICKS_PER_SECOND): Removed.
13405 (grub_get_rtc): Likewise.
13406
13407 * include/grub/efi/api.h (struct grub_efi_memory_descriptor):
13408 Added padding. The EFI spec is buggy.
13409 (GRUB_EFI_BLACK): New macro.
13410 (GRUB_EFI_BLUE): Likewise.
13411 (GRUB_EFI_GREEN): Likewise.
13412 (GRUB_EFI_CYAN): Likewise.
13413 (GRUB_EFI_RED): Likewise.
13414 (GRUB_EFI_MAGENTA): Likewise.
13415 (GRUB_EFI_BROWN): Likewise.
13416 (GRUB_EFI_LIGHTGRAY): Likewise.
13417 (GRUB_EFI_BRIGHT): Likewise.
13418 (GRUB_EFI_DARKGRAY): Likewise.
13419 (GRUB_EFI_LIGHTBLUE): Likewise.
13420 (GRUB_EFI_LIGHTGREEN): Likewise.
13421 (GRUB_EFI_LIGHTCYAN): Likewise.
13422 (GRUB_EFI_LIGHTRED): Likewise.
13423 (GRUB_EFI_LIGHTMAGENTA): Likewise.
13424 (GRUB_EFI_YELLOW): Likewise.
13425 (GRUB_EFI_WHITE): Likewise.
13426 (GRUB_EFI_BACKGROUND_BLACK): Likewise.
13427 (GRUB_EFI_BACKGROUND_BLUE): Likewise.
13428 (GRUB_EFI_BACKGROUND_GREEN): Likewise.
13429 (GRUB_EFI_BACKGROUND_CYAN): Likewise.
13430 (GRUB_EFI_BACKGROUND_RED): Likewise.
13431 (GRUB_EFI_BACKGROUND_MAGENTA): Likewise.
13432 (GRUB_EFI_BACKGROUND_BROWN): Likewise.
13433 (GRUB_EFI_BACKGROUND_LIGHTGRAY): Likewise.
13434 (GRUB_EFI_TEXT_ATTR): Likewise.
13435
13436 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added kern/efi/efi.c,
13437 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
13438 (kernel_mod_HEADERS): Added efi/time.h.
13439
13440 2006-04-18 Yoshinori K. Okuji <okuji@enbug.org>
13441
13442 * DISTLIST: Added conf/i386-efi.mk, conf/i386-efi.rmk,
13443 include/grub/efi/api.h, include/grub/efi/console_control.h,
13444 include/grub/efi/efi.h, include/grub/efi/pe32.h,
13445 include/grub/i386/efi/time.h, kern/efi/efi.c,
13446 kern/i386/efi/init.c, kern/i386/efi/startup.S,
13447 and util/i386/efi/grub-mkimage.c.
13448
13449 * Makefile.in (RMKFILES): Added i386-efi.rmk.
13450
13451 * genmk.rb (PModule#rule): Do not export symbols if
13452 #{prefix}_EXPORTS is set to "no".
13453
13454 * conf/i386-efi.mk: New file.
13455 * conf/i386-efi.rmk: Likewise.
13456 * include/grub/efi/api.h: Likewise.
13457 * include/grub/efi/console_control.h: Likewise.
13458 * include/grub/efi/efi.h: Likewise.
13459 * include/grub/efi/pe32.h: Likewise.
13460 * include/grub/i386/efi/time.h: Likewise.
13461 * kern/efi/efi.c: Likewise.
13462 * kern/i386/efi/init.c: Likewise.
13463 * kern/i386/efi/startup.S: Likewise.
13464 * util/i386/efi/grub-mkimage.c: Likewise.
13465
13466 2006-04-17 Marco Gerards <marco@gnu.org>
13467
13468 * include/grub/script.h: Include <grub/parser.h> and
13469 "grub_script.tab.h".
13470 (struct grub_lexer_param): New struct.
13471 (struct grub_parser_param): Likewise.
13472 (grub_script_create_arglist): Pass the state in an argument.
13473 (grub_script_add_arglist): Likewise.
13474 (grub_script_create_cmdline): Likewise.
13475 (grub_script_create_cmdblock): Likewise.
13476 (grub_script_create_cmdif): Likewise.
13477 (grub_script_create_cmdmenu): Likewise.
13478 (grub_script_add_cmd): Likewise.
13479 (grub_script_arg_add): Likewise.
13480 (grub_script_lexer_ref): Likewise.
13481 (grub_script_lexer_deref): Likewise.
13482 (grub_script_lexer_record_start): Likewise.
13483 (grub_script_lexer_record_stop): Likewise.
13484 (grub_script_mem_record): Likewise.
13485 (grub_script_mem_record_stop): Likewise.
13486 (grub_script_malloc): Likewise.
13487 (grub_script_yylex): Likewise.
13488 (grub_script_yyparse): Likewise.
13489 (grub_script_yyerror): Likewise.
13490 (grub_script_yylex): Likewise.
13491 (grub_script_lexer_init): Return the state.
13492
13493 * normal/lexer.c (grub_script_lexer_state): Removed variable.
13494 (grub_script_lexer_done): Likewise.
13495 (grub_script_lexer_getline): Likewise.
13496 (grub_script_lexer_refs): Likewise.
13497 (script): Likewise.
13498 (newscript): Likewise.
13499 (record): Likewise.
13500 (recording): Likewise.
13501 (recordpos): Likewise.
13502 (recordlen): Likewise.
13503 (grub_script_lexer_init): Return the state instead of setting
13504 global variables.
13505 (grub_script_lexer_ref): Use the newly added argument for state
13506 instead of globals.
13507 (grub_script_lexer_deref): Likewise.
13508 (grub_script_lexer_record_start): Likewise.
13509 (grub_script_lexer_record_stop): Likewise.
13510 (recordchar): Likewise.
13511 (nextchar): Likewise.
13512 (grub_script_yylex2): Likewise.
13513 (grub_script_yylex): Likewise.
13514 (grub_script_yyerror): Likewise.
13515
13516 * normal/parser.y (func_mem): Removed variable.
13517 (menu_entry): Likewise.
13518 (err): Likewise.
13519 (%lex-param): New parser option.
13520 (%parse-param): Likewise.
13521 (script): Always return the AST.
13522 (argument): Pass the state around.
13523 (arguments): Likewise.
13524 (grubcmd): Likewise.
13525 (commands): Likewise.
13526 (function): Likewise.
13527 (menuentry): Likewise.
13528 (if_statement): Likewise.
13529 (if): Likewise.
13530
13531 * normal/script.c (grub_script_memused): Removed variable.
13532 (grub_script_parsed): Likewise.
13533 (grub_script_malloc): Added a state argument. Use that instead of
13534 global variables.
13535 (grub_script_mem_record): Likewise.
13536 (grub_script_mem_record_stop): Likewise.
13537 (grub_script_arg_add): Likewise.
13538 (grub_script_add_arglist): Likewise.
13539 (grub_script_create_cmdline): Likewise.
13540 (grub_script_create_cmdif): Likewise.
13541 (grub_script_create_cmdmenu): Likewise.
13542 (grub_script_add_cmd): Likewise.
13543 (grub_script_parse): Setup the state before calling the parser.
13544
13545 2006-04-16 Marco Gerards <marco@gnu.org>
13546
13547 * normal/command.c (grub_command_init): Remove the title command.
13548
13549 * normal/lexer.c (grub_script_yylex): Renamed from this...
13550 (grub_script_yylex2): ... to this.
13551 (grub_script_yylex): New function. Temporary
13552 introduced to filter some tokens.
13553 (grub_script_yyerror): Print a newline.
13554
13555 * normal/main.c (read_config_file): Output information about the
13556 lines that contain errors. Wait for a key after all lines have
13557 been processed. Don't return an empty menu.
13558
13559 * normal/parser.y (func_mem): Don't initialize.
13560 (menu_entry): Likewise.
13561 (err): New variable.
13562 (script): Don't return anything when an error was encountered.
13563 (ws, returns): Removed rules.
13564 (argument): Disabled concatenated variable support.
13565 (arguments): Remove explicit separators.
13566 (grubcmd): Likewise.
13567 (function): Likewise.
13568 (menuentry): Likewise.
13569 (if): Likewise.
13570 (commands): Likewise. Add error handling.
13571
13572 * normal/script.c (grub_script_create_cmdline): If
13573 `grub_script_parsed' is 0, assume the parser encountered an error.
13574
13575 2006-04-02 Yoshinori K. Okuji <okuji@enbug.org>
13576
13577 * configure.ac: Add support for EFI. Fix the typo
13578 BUILD_LDDFLAGS. Restore the LDFLAGS after testing.
13579
13580 2006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
13581
13582 * util/unifont2pff.rb: Removed unnecessary byte ordering. Now
13583 foreign multibyte characters should be shown correctly.
13584
13585 2006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
13586
13587 * normal/main.c (grub_normal_menu_addentry): Fixed menu size
13588 calculation.
13589 (read_config_file): Made it to close file before returning.
13590
13591 2006-03-31 Vesa Jaaskelainen <chaac@nic.fi>
13592
13593 * DISTLIST: Added include/grub/i386/pc/vbeblit.h,
13594 include/grub/i386/pc/vbefill.h, video/i386/pc/vbeblit.c,
13595 video/i386/pc/vbefill.c.
13596
13597 * conf/i386-pc.rmk (vbe_mod_SOURCES): Added video/i386/pc/vbeblit.c,
13598 video/i386/pc/vbefill.c.
13599
13600 * include/grub/video.h (grub_video_blit_format): New enum.
13601 (grub_video_mode_info): Added new member blit_format.
13602 (grub_video_get_blit_format): New function prototype.
13603
13604 * include/grub/i386/pc/vbe.h (grub_video_vbe_get_video_ptr): New
13605 function prototype.
13606 (grub_video_vbe_map_rgb): Likewise.
13607 (grub_video_vbe_unmap_color): Likewise.
13608
13609 * include/grub/i386/pc/vbeblit.h: New file.
13610
13611 * include/grub/i386/pc/vbefill.h: New file.
13612
13613 * video/video.c (grub_video_get_blit_format): New function.
13614 (grub_video_vbe_get_video_ptr): Re-declared as non-static.
13615 (grub_video_vbe_map_rgb): Likewise.
13616 (grub_video_vbe_unmap_color): Likewise.
13617
13618 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Changed to use more
13619 optimized fills.
13620 (grub_video_vbe_blit_render_target): Changed to use more optimized
13621 blits.
13622 (grub_video_vbe_setup): Added detection for optimized settings.
13623 (grub_video_vbe_create_render_target): Likewise.
13624
13625 * video/i386/pc/vbeblit.c: New file.
13626
13627 * video/i386/pc/vbefill.c: New file.
13628
13629 2006-03-30 Vesa Jaaskelainen <chaac@nic.fi>
13630
13631 * font/manager.c (grub_font_get_glyph): Removed font fixup from
13632 here...
13633
13634 * util/unifont2pff.rb: ... and moved it to here. Improved argument
13635 parsing to support both hex and dec ranges. If filename was missing
13636 show usage information.
13637
13638 2006-03-14 Vesa Jaaskelainen <chaac@nic.fi>
13639
13640 * DISTLIST: Added include/grub/video.h, term/gfxterm.c,
13641 video/video.c, commands/videotest.c. Removed term/i386/pc/vesafb.c.
13642
13643 * conf/i386-pc.rmk (pkgdata_MODULES): Added video.mod,
13644 gfxterm.mod, videotest.mod. Removed vga.mod, vesafb.mod.
13645 (video_mod_SOURCES): Added.
13646 (video_mod_CFLAGS): Likewise.
13647 (video_mod_LDFLAGS): Likewise.
13648 (gfxterm_mod_SOURCES): Likewise.
13649 (gfxterm_mod_CFLAGS): Likewise.
13650 (gfxterm_mod_LDFLAGS): Likewise.
13651 (videotest_mod_SOURCES): Likewise.
13652 (videotest_mod_CFLAGS): Likewise.
13653 (videotest_mod_LDFLAGS): Likewise.
13654 (vesafb_mod_SOURCES): Removed.
13655 (vesafb_mod_CFLAGS): Likewise.
13656 (vesafb_mod_LDFLAGS): Likewise.
13657 (vga_mod_SOURCES): Likewise.
13658 (vga_mod_CFLAGS): Likewise.
13659 (vga_mod_LDFLAGS): Likewise.
13660
13661 * commands/videotest.c: New file.
13662
13663 * font/manager.c (fill_with_default_glyph): Modified to use
13664 grub_font_glyph.
13665 (grub_font_get_glyph): Likewise.
13666 (fontmanager): Renamed from this...
13667 (font_manager): ... to this.
13668
13669 * include/grub/font.h (grub_font_glyph): Added new structure.
13670 (grub_font_get_glyph): Modified to use grub_font_glyph.
13671
13672 * include/grub/misc.h (grub_abs): Added as inline function.
13673
13674 * include/grub/video.h: New file.
13675
13676 * include/grub/i386/pc/vbe.h (GRUB_VBE_STATUS_OK): New macro.
13677 (GRUB_VBE_MEMORY_MODEL_PACKED_PIXEL): Likewise.
13678 (GRUB_VBE_MEMORY_MODEL_DIRECT_COLOR): Likewise.
13679 (grub_vbe_get_controller_info): Renamed from this...
13680 (grub_vbe_bios_get_controller_info): ... to this.
13681 (grub_vbe_get_mode_info): Renamed from this...
13682 (grub_vbe_bios_get_mode_info): ... to this.
13683 (grub_vbe_set_mode): Renamed from this...
13684 (grub_vbe_bios_set_mode): ... to this.
13685 (grub_vbe_get_mode): Renamed from this...
13686 (grub_vbe_bios_get_mode): ... to this.
13687 (grub_vbe_set_memory_window): Renamed from this...
13688 (grub_vbe_bios_set_memory_window): ... to this.
13689 (grub_vbe_get_memory_window): Renamed from this...
13690 (grub_vbe_bios_get_memory_window): ... to this.
13691 (grub_vbe_set_scanline_length): Renamed from this...
13692 (grub_vbe_set_scanline_length): ... to this.
13693 (grub_vbe_get_scanline_length): Renamed from this...
13694 (grub_vbe_bios_get_scanline_length): ... to this.
13695 (grub_vbe_set_display_start): Renamed from this...
13696 (grub_vbe_bios_set_display_start): ... to this.
13697 (grub_vbe_get_display_start): Renamed from this...
13698 (grub_vbe_bios_get_display_start): ... to this.
13699 (grub_vbe_set_palette_data): Renamed from this...
13700 (grub_vbe_bios_set_palette_data): ... to this.
13701 (grub_vbe_set_pixel_rgb): Removed.
13702 (grub_vbe_set_pixel_index): Likewise.
13703
13704 * kern/i386/pc/startup.S (grub_vbe_get_controller_info): Renamed
13705 from this...
13706 (grub_vbe_bios_get_controller_info): ... to this.
13707 (grub_vbe_get_mode_info): Renamed from this...
13708 (grub_vbe_bios_get_mode_info): ... to this.
13709 (grub_vbe_set_mode): Renamed from this...
13710 (grub_vbe_bios_set_mode): ... to this.
13711 (grub_vbe_get_mode): Renamed from this...
13712 (grub_vbe_bios_get_mode): ... to this.
13713 (grub_vbe_set_memory_window): Renamed from this...
13714 (grub_vbe_bios_set_memory_window): ... to this.
13715 (grub_vbe_get_memory_window): Renamed from this...
13716 (grub_vbe_bios_get_memory_window): ... to this.
13717 (grub_vbe_set_scanline_length): Renamed from this...
13718 (grub_vbe_set_scanline_length): ... to this.
13719 (grub_vbe_get_scanline_length): Renamed from this...
13720 (grub_vbe_bios_get_scanline_length): ... to this.
13721 (grub_vbe_set_display_start): Renamed from this...
13722 (grub_vbe_bios_set_display_start): ... to this.
13723 (grub_vbe_get_display_start): Renamed from this...
13724 (grub_vbe_bios_get_display_start): ... to this.
13725 (grub_vbe_set_palette_data): Renamed from this...
13726 (grub_vbe_bios_set_palette_data): ... to this.
13727 (grub_vbe_bios_get_controller_info): Fixed problem with registers
13728 getting corrupted after calling it. Added more pushes and pops.
13729 (grub_vbe_bios_set_mode): Likewise.
13730 (grub_vbe_bios_get_mode): Likewise.
13731 (grub_vbe_bios_get_memory_window): Likewise.
13732 (grub_vbe_bios_set_scanline_length): Likewise.
13733 (grub_vbe_bios_get_scanline_length): Likewise.
13734 (grub_vbe_bios_get_display_start): Likewise.
13735 (grub_vbe_bios_set_palette_data): Likewise.
13736
13737 * normal/cmdline.c (cl_set_pos): Refresh the screen.
13738 (cl_insert): Likewise.
13739 (cl_delete): Likewise.
13740
13741 * term/gfxterm.c: New file.
13742
13743 * term/i386/pc/vesafb.c: Removed file.
13744
13745 * video/video.c: New file.
13746
13747 * video/i386/pc/vbe.c (real2pm): Added new function.
13748 (grub_video_vbe_draw_pixel): Likewise.
13749 (grub_video_vbe_get_video_ptr): Likewise.
13750 (grub_video_vbe_get_pixel): Likewise
13751 (grub_video_vbe_init): Likewise.
13752 (grub_video_vbe_fini): Likewise.
13753 (grub_video_vbe_setup): Likewise.
13754 (grub_video_vbe_get_info): Likewise.
13755 (grub_video_vbe_set_palette): Likewise.
13756 (grub_video_vbe_get_palette): Likewise.
13757 (grub_video_vbe_set_viewport): Likewise.
13758 (grub_video_vbe_get_viewport): Likewise.
13759 (grub_video_vbe_map_color): Likewise.
13760 (grub_video_vbe_map_rgb): Likewise.
13761 (grub_video_vbe_map_rgba): Likewise.
13762 (grub_video_vbe_unmap_color): Likewise.
13763 (grub_video_vbe_fill_rect): Likewise.
13764 (grub_video_vbe_blit_glyph): Likewise.
13765 (grub_video_vbe_blit_bitmap): Likewise.
13766 (grub_video_vbe_blit_render_target): Likewise.
13767 (grub_video_vbe_scroll): Likewise.
13768 (grub_video_vbe_swap_buffers): Likewise.
13769 (grub_video_vbe_create_render_target): Likewise.
13770 (grub_video_vbe_delete_render_target): Likewise.
13771 (grub_video_vbe_set_active_render_target): Likewise.
13772 (grub_vbe_set_pixel_rgb): Remove function.
13773 (grub_vbe_set_pixel_index): Likewise.
13774 (index_color_mode): Remove static variable.
13775 (active_mode): Likewise.
13776 (framebuffer): Likewise.
13777 (bytes_per_scan_line): Likewise.
13778 (grub_video_vbe_adapter): Added new static variable.
13779 (framebuffer): Likewise.
13780 (render_target): Likewise.
13781 (initial_mode): Likewise.
13782 (mode_in_use): Likewise.
13783 (mode_list): Likewise.
13784
13785 2006-03-10 Marco Gerards <marco@gnu.org>
13786
13787 * configure.ac (AC_INIT): Bumped to 1.93.
13788
13789 * DISTLIST: Added `include/grub/hfs.h'.
13790
13791 2006-02-01 Yoshinori K. Okuji <okuji@enbug.org>
13792
13793 * boot/i386/pc/boot.S (general_error): Before looping, try INT
13794 18H, which might help the BIOS falling back to next boot media.
13795
13796 2006-01-25 Yoshinori K. Okuji <okuji@enbug.org>
13797
13798 * util/i386/pc/grub-install.in: Escape a backslash. Reported by
13799 Poe Chen <poe.poechen@gmail.com>.
13800
13801 2006-01-17 Marco Gerards <marco@gnu.org>
13802
13803 * include/grub/normal.h: Include <grub/script.h>.
13804 (grub_command_list): Removed struct.
13805 (grub_command_list_t): Removed type.
13806 (grub_menu_entry): Remove members `num' and `command_list'. Add
13807 members `commands' and `sourcecode'.
13808 * include/grub/script.h: Add inclusion guards.
13809 (grub_script_cmd_menuentry): New struct.
13810 (grub_script_execute_menuentry): New prototype.
13811 (grub_script_lexer_record_start): Likewise.
13812 (grub_script_lexer_record_stop): Likewise.
13813 * normal/execute.c (grub_script_execute_menuentry): New function.
13814 * normal/lexer.c (record, recording, recordpos, recordlen): New
13815 variables.
13816 (grub_script_lexer_record_start): New function.
13817 (grub_script_lexer_record_stop): Likewise.
13818 (recordchar): Likewise.
13819 (nextchar): Likewise.
13820 (grub_script_yylex): Use `nextchar' to fetch new characters. Use
13821 2048 as the buffer size. Add the tokens `menuentry' and `@'.
13822 * normal/main.c: Include <grub/parser.h> and <grub/script.h>
13823 (current_menu): New variable.
13824 (free_menu): Mainly rewritten.
13825 (grub_normal_menu_addentry): New function.
13826 (read_config_file): Rewritten.
13827 * normal/menu.c (run_menu_entry): Mainly rewritten.
13828 * normal/menu_entry.c (make_screen): Rewritten the code to insert
13829 the menu entry.
13830 (run): Mainly rewritten.
13831 * normal/parser.y (menu_entry): New variable.
13832 (GRUB_PARSER_TOKEN_MENUENTRY): New token.
13833 (menuentry): New rule.
13834 (command): Add `menuentry'.
13835 (if_statement): Allow additional returns before `fi'.
13836 * normal/script.c (grub_script_create_cmdmenu): New function.
13837
13838 2006-01-03 Marco Gerards <marco@gnu.org>
13839
13840 * INSTALL: GNU Bison is required.
13841 * configure.ac: Rewritten the test to detect Bison.
13842 * Makefile.in (YACC): New variable. Reported by Xun Sun
13843 <xun.sun.cn@gmail.com>.
13844
13845 2006-01-03 Marco Gerards <marco@gnu.org>
13846
13847 * fs/hfsplus.c (grub_hfsplus_read_block): Convert the offset of
13848 the HFS+ filesystem to filesystem blocks.
13849 (grub_hfsplus_iterate_dir): Cast the `fileinfo' assignment so a
13850 GCC warning is silenced.
13851
13852 2006-01-03 Marco Gerards <marco@gnu.org>
13853
13854 * partmap/apple.c (apple_partition_map_iterate): Convert the data
13855 read from disk from big endian to host byte order.
13856
13857 2006-01-03 Hollis Blanchard <hollis@penguinppc.org>
13858
13859 * fs/hfs.c: Include <grub/hfs.h>. Added reference to the official
13860 documentation.
13861 (GRUB_HFS_EMBED_HFSPLUS_SIG): New macro.
13862 (grub_hfs_mount): Grammar fix in error. Make sure this is not an
13863 embedded HFS+ filesystem.
13864 (GRUB_HFS_MAGIC, grub_hfs_extent, grub_hfs_datarecord_t)
13865 (grub_hfs_sblock): Move from here...
13866 * include/grub/hfs.h: To here... New file.
13867 * fs/hfsplus.c: Include <grub/hfs.h>. Added reference to the official
13868 documentation.
13869 (GRUB_HFSPLUS_MAGIC, GRUB_HFSPLUSX_MAGIC, GRUB_HFSPLUS_SBLOCK):
13870 New macros.
13871 (grub_hfsplus_volheader): Change type of member `magic' to
13872 `grub_uint16_t'.
13873 (grub_hfsplus_data): Add new member `embedded_offset'.
13874 (grub_hfsplus_read_block): Add the HFS+ wrapper offset to the
13875 returned block.
13876 (grub_hfsplus_mount): Read the HFS+ wrapper if it exists.
13877 Calculate the offset.
13878
13879 2005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
13880
13881 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRP_ADDR):
13882 Removed.
13883 (GRUB_BOOT_MACHINE_DRP_SIZE): Likewise.
13884
13885 2005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
13886
13887 * kern/env.c (grub_env_set): Check if ENV->VALUE instead of
13888 ENV->NAME is NULL after allocating ENV->VALUE.
13889
13890 2005-12-25 Marco Gerards <marco@gnu.org>
13891
13892 * kern/env.c (grub_env_set): Rewritten the error handling code.
13893
13894 2005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
13895
13896 * geninit.sh: Made more robust, and more portable.
13897
13898 2005-12-25 Marco Gerards <marco@gnu.org>
13899
13900 Add support for Apple HFS+ filesystems.
13901
13902 * fs/hfsplus.c: New file.
13903
13904 * DISTLIST: Added `fs/hfsplus.c'.
13905
13906 * conf/common.rmk (pkgdata_MODULES): Add `hfsplus.mod'.
13907 (hfsplus_mod_SOURCES): New variable.
13908 (hfsplus_mod_CFLAGS): Likewise.
13909 (hfsplus_mod_LDFLAGS): Likewise.
13910 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/hfsplus.c'.
13911 (grub_setup_SOURCES): Likewise.
13912 (grub_mkdevicemap_SOURCES): Likewise.
13913 (grub_emu_SOURCES): Likewise.
13914 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
13915
13916 * fs/fshelp.c (grub_fshelp_log2blksize): New function.
13917
13918 * include/grub/fshelp.h (grub_fshelp_log2blksize): new prototype.
13919
13920 2005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
13921
13922 * DISTLIST: Added geninitheader.sh, geninit.sh, commands/test.c,
13923 commands/i386/pc/play.c, conf/common.mk, conf/common.rmk,
13924 include/grub/parser.h, include/grub/script.h, kern/parser.c,
13925 kern/sparc64/cache.S, normal/execute.c, normal/function.c,
13926 normal/lexer.c, normal/parser.y, normal/script.c, and
13927 partmap/gpt.c.
13928 Removed kern/sparc64/cache.c.
13929
13930 * conf/common.rmk (DISTCLEANFILES): Added grub_script.tab.c,
13931 grub_script.tab.h, grub_modules_init.lst, grub_modules_init.h,
13932 grub_emu_init.c.
13933
13934 * configure.ac (AC_INIT): Bumped to 1.92.
13935
13936 2005-12-24 Vesa Jaaskelainen <chaac@nic.fi>
13937
13938 * kern/err.c (grub_error_push): Added new function to support error
13939 stacks.
13940 (grub_error_pop): Likewise.
13941 (grub_error_stack_items): New local variable to support error stacks.
13942 (grub_error_stack_pos): Likewise.
13943 (grub_error_stack_assert): Likewise.
13944 (GRUB_ERROR_STACK_SIZE): Added new define to configure maximum error
13945 stack depth.
13946 (grub_print_error): Added support to print errors from error stack.
13947
13948 * include/grub/err.h (grub_error_push): Added function prototype.
13949 (grub_error_pop): Likewise.
13950
13951 2005-12-09 Hollis Blanchard <hollis@penguinppc.org>
13952
13953 * configure.ac: Accept `powerpc64' as host_cpu.
13954 (amd64): Rename to `biarch32'.
13955
13956 * kern/powerpc/cache.S (grub_arch_sync_caches): Handle
13957 non-cacheline-aligned addresses.
13958
13959 * kern/dl.c (grub_dl_load_core): Add grub_dprintf messages.
13960 (grub_dl_flush_cache): Likewise. Only call `grub_arch_sync_caches'
13961 if `size' is non-zero.
13962
13963 2005-12-03 Marco Gerards <mgerards@xs4all.nl>
13964
13965 * conf/common.rmk (grub_modules_init.lst): Use `-printf "%P\n"'
13966 and `cd' to make sure the filename is not prefixed with a
13967 directory name.
13968 (pkgdata_MODULES): Add `gpt.mod'.
13969 (gpt_mod_SOURCES): New variable.
13970 (gpt_mod_CFLAGS): Likewise.
13971 (gpt_mod_LDFLAGS): Likewise.
13972
13973 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/gpt.c'.
13974
13975 * include/grub/pc_partition.h (GRUB_PC_PARTITION_TYPE_GPT_DISK):
13976 New macro.
13977
13978 * partmap/gpt.c: New file.
13979
13980 * partmap/pc.c (pc_partition_map_iterate): Don't continue when a
13981 GPT partition map is detected.
13982
13983 2005-12-03 Vincent Pelletier <subdino2004@yahoo.fr>
13984
13985 * commands/i386/pc/play.c: New file.
13986 * conf/i386-pc.rmk (pkgdata_MODULES): Added play.mod.
13987 (play_mod_SOURCES, play_mod_CFLAGS, play_mod_LDFLAGS): New
13988 macros.
13989
13990 2005-11-27 Marco Gerards <mgerards@xs4all.nl>
13991
13992 * include/grub/dl.h (GRUB_MOD_INIT): Use `__attribute__
13993 ((unused))' to silence gcc warning.
13994
13995 2005-11-26 Hollis Blanchard <hollis@penguinppc.org>
13996
13997 * configure.ac: Correct `AC_PROG_YACC' test.
13998
13999 2005-11-22 Hollis Blanchard <hollis@penguinppc.org>
14000
14001 * util/powerpc/ieee1275/grub-install.in: Run the mount point
14002 check before installing files.
14003
14004 2005-11-22 Mike Small <smallm@panix.com>
14005
14006 * util/powerpc/ieee1275/grub-install.in (grubdir): Fixed partition
14007 number regex so multidigit numbers are recognized correctly.
14008
14009 2005-11-22 Mike Small <smallm@panix.com>
14010
14011 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Add a
14012 debugging message before attempting to claim memory.
14013 (grub_rescue_cmd_initrd): Add a claim debugging message and try
14014 multiple addresses in case of failure.
14015
14016 2005-11-22 Hollis Blanchard <hollis@penguinppc.org>
14017
14018 * term/tparm.c (get_space): Remove empty `if' statement.
14019
14020 * fs/ufs.c (grub_ufs_find_file): Remove `grub_le_to_cpu32'.
14021
14022 * kern/parser.c (check_varstate): Rename `state' to 's'.
14023
14024 2005-11-22 Hollis Blanchard <hollis@penguinppc.org>
14025
14026 * partmap/acorn.c: Change `unsigned' to `unsigned int'. Move all
14027 variable definitions to the beginning of each function. Sort stack
14028 variables by size.
14029 (find): Rename to `acorn_partition_map_find'. Cast `grub_disk_read'
14030 `buf' argument to `char *'.
14031
14032 2005-11-22 Hollis Blanchard <hollis@penguinppc.org>
14033
14034 * conf/powerpc-ieee1275.rmk: Include conf/common.mk.
14035 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
14036 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
14037 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
14038 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
14039 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
14040 configfile.mod, search.mod, gzio.mod and test.mod.
14041 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
14042 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
14043 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
14044 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
14045 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
14046 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
14047 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
14048 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
14049 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
14050 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
14051 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
14052 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
14053 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
14054 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
14055 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
14056 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
14057 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
14058 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
14059 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
14060 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
14061 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
14062 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
14063 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Removed.
14064
14065 * conf/common.mk (grub_modules_init.lst): Use `find' instead of
14066 `grep --include'.
14067 (pkgdata_MODULES): Add test.mod.
14068
14069 2005-11-18 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
14070
14071 * genmk.rb: Fixed list rules moved to Makefile.in. Recognise
14072 appending to variables with "+=".
14073 (PModule): Use full pathname to generate *.lst filenames.
14074
14075 * Makefile.in: Fixed list rules moved from genmk.rb.
14076 (.DELETE_ON_ERROR): New special target.
14077 (RMKFILES): Add common.rmk and sparc64-ieee1275.rmk.
14078
14079 * conf/i386-pc.rmk: Include conf/common.mk.
14080 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
14081 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
14082 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
14083 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
14084 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
14085 configfile.mod, search.mod, gzio.mod and test.mod.
14086 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
14087 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
14088 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
14089 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
14090 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
14091 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
14092 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
14093 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
14094 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
14095 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
14096 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
14097 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
14098 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
14099 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
14100 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
14101 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
14102 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
14103 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
14104 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
14105 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
14106 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
14107 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
14108 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Move from
14109 here...
14110 * conf/common.rmk: ... to here. New file.
14111
14112 * conf/common.mk: New file.
14113
14114 2005-11-18 Yoshinori K. Okuji <okuji@enbug.org>
14115
14116 * conf/powerpc-ieee1275.rmk (grub_script.tab.h): Unified to ...
14117 (grub_script.tab.c): ... here.
14118
14119 * conf/sparc64-ieee1275.rmk (grub_script.tab.h): Unified to ...
14120 (grub_script.tab.c): ... here.
14121
14122 * conf/i386-pc.rmk (grub_script.tab.h): Unified to ...
14123 (grub_script.tab.c): ... here.
14124
14125 * normal/command.c (grub_command_find): Fixed a memory leak of
14126 MODULE_NAME. Reported by Mike Small <smallm@panix.com>.
14127
14128 2005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
14129
14130 * include/grub/symbol.h: (FUNCTION): Use double quotes instead of
14131 "@" which marks the start of a comment on ARM.
14132 (VARIABLE): Likewise.
14133
14134 2005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
14135
14136 Add support for Linux/ADFS partition tables.
14137
14138 * partmap/acorn.c: New file.
14139
14140 * include/grub/acorn_filecore.h: Likewise.
14141
14142 * DISTLIST: Added `partmap/acorn.c' and
14143 `include/grub/acorn_filecore.h'.
14144
14145 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
14146 `partmap/acorn.c'.
14147 (pkgdata_MODULES): Add `acorn.mod'.
14148 (acorn_mod_SOURCES): New variable.
14149 (acorn_mod_CFLAGS): Likewise.
14150
14151 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
14152 `partmap/acorn.c'.
14153 (pkgdata_MODULES): Add `acorn.mod'.
14154 (acorn_mod_SOURCES): New variable.
14155 (acorn_mod_CFLAGS): Likewise.
14156
14157 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/acorn.c'.
14158 (pkgdata_MODULES): Add `acorn.mod'.
14159 (acorn_mod_SOURCES): New variable.
14160 (acorn_mod_CFLAGS): Likewise.
14161 (acorn_mod_LDFLAGS): Likewise.
14162
14163 * include/types.h (grub_disk_addr_t): New typedef.
14164
14165 2005-11-13 Marco Gerards <mgerards@xs4all.nl>
14166
14167 * geninit.sh: New file.
14168
14169 * geninitheader.sh: Likewise.
14170
14171 * commands/boot.c (grub_boot_init, grub_boot_fini): Removed.
14172 * commands/cat.c (grub_cat_init, grub_cat_fini): Likewise.
14173 * commands/cmp.c (grub_cmp_init, grub_cmp_fini): Likewise.
14174 * commands/configfile.c (grub_configfile_init)
14175 (grub_configfile_fini): Likewise.
14176 * commands/default.c (grub_default_init, grub_default_fini):
14177 Likewise.
14178 * commands/help.c (grub_help_init, grub_help_fini): Likewise.
14179 * commands/ls.c (grub_ls_init, grub_ls_fini): Likewise.
14180 * commands/search.c (grub_search_init, grub_search_fini): Likewise.
14181 * commands/terminal.c (grub_terminal_init, grub_terminal_fini):
14182 Likewise.
14183 * commands/test.c (grub_test_init, grub_test_fini): Likewise.
14184 * commands/timeout.c (grub_timeout_init, grub_timeout_fini):
14185 Likewise.
14186 * commands/i386/pc/halt.c (grub_halt_init, grub_halt_fini): Likewise.
14187 * commands/ieee1275/halt.c (grub_halt_init, grub_halt_fini):
14188 Likewise.
14189 * commands/i386/pc/reboot.c (grub_reboot_init, grub_reboot_fini):
14190 Likewise.
14191 * commands/ieee1275/reboot.c (grub_reboot_init, grub_reboot_fini):
14192 Likewise.
14193 * disk/loopback.c (grub_loop_init, grub_loop_fini): Likewise.
14194 * fs/affs.c (grub_affs_init, grub_affs_fini): Likewise.
14195 * fs/ext2.c (grub_ext2_init, grub_ext2_fini): Likewise.
14196 * fs/fat.c (grub_fat_init, grub_fat_fini): Likewise.
14197 * fs/hfs.c (grub_hfs_init, grub_hfs_fini): Likewise.
14198 * fs/iso9660.c (grub_iso9660_init, grub_iso9660_fini): Likewise.
14199 * fs/jfs.c (grub_jfs_init, grub_jfs_fini): Likewise.
14200 * fs/minix.c (grub_minix_init, grub_minix_fini): Likewise.
14201 * fs/sfs.c (grub_sfs_init, grub_sfs_fini): Likewise.
14202 * fs/ufs.c (grub_ufs_init, grub_ufs_fini): Likewise.
14203 * fs/xfs.c (grub_xfs_init, grub_xfs_fini): Likewise.
14204 * normal/main.c (grub_normal_init, grub_normal_fini): Likewise.
14205 * partmap/amiga.c (grub_amiga_partition_map_init)
14206 (grub_amiga_partition_map_fini): Likewise.
14207 * partmap/apple.c (grub_apple_partition_map_init)
14208 (grub_apple_partition_map_fini): Likewise.
14209 * partmap/pc.c (grub_pc_partition_map_init)
14210 (grub_pc_partition_map_fini): Likewise.
14211 * partmap/sun.c (grub_sun_partition_map_init,
14212 grub_sun_partition_map_fini): Likewise.
14213 * term/terminfo.c (grub_terminal_init, grub_terminal_fini):
14214 Likewise.
14215
14216 * util/grub-emu.c: Include <grub_modules_init.h>.
14217 (main): Don't initialize and de-initialize any modules directly,
14218 use `grub_init_all' and `grub_fini_all' instead.
14219
14220 * term/i386/pc/vesafb.c (grub_vesafb_init): Renamed to
14221 `grub_vesafb_mod_init'.
14222 (grub_vesafb_fini): Renamed to `grub_vesafb_mod_fini'. Updated
14223 all users.
14224 * term/i386/pc/vga.c (grub_vga_init): Renamed to
14225 `grub_vga_mod_init'. Updated all users.
14226 (grub_vga_fini): Renamed to `grub_vga_mod_fini'.
14227
14228 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `grub_emu_init.c'.
14229 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c): New
14230 rules.
14231
14232 * include/grub/dl.h (GRUB_MOD_INIT): Add argument `name'.
14233 Generate a function to initialize the module in utilities.
14234 Updated all callers.
14235 (GRUB_MOD_FINI): Add argument `name'. Generate a function to
14236 initialize the module in utilities. Updated all callers.
14237
14238 2005-11-09 Hollis Blanchard <hollis@penguinppc.org>
14239
14240 * term/ieee1275/ofconsole.c (grub_ofconsole_cls): Use both the ANSI
14241 escape sequence and a literal ^L to clear the screen.
14242
14243 * commands/ieee1275/suspend.c (grub_cmd_suspend): Clear the screen
14244 when returning from Open Firmware.
14245
14246 2005-11-09 Hollis Blanchard <hollis@penguinppc.org>
14247
14248 * term/ieee1275/ofconsole.c (grub_ofconsole_width): New variable.
14249 (grub_ofconsole_height): Likewise.
14250 (grub_ofconsole_putchar): If `grub_curr_x' exceeds console width,
14251 manually insert a '\n'.
14252 (grub_ofconsole_getwh): Set and return `grub_ofconsole_width' and
14253 `grub_ofconsole_height'. Return early if these are already set.
14254
14255 2005-11-07 Vincent Pelletier <subdino2004@yahoo.fr>
14256
14257 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
14258 `commands/test.c', `fs/affs.c', `fs/sfs.c', `fs/xfs.c',
14259 `normal/execute.c', `normal/lexer.c', `io/gzio.c',
14260 `kern/parser.c', `grub_script.tab.c', `normal/function.c'
14261 and `normal/script.c'.
14262 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
14263 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
14264 (test_mod_SOURCES): New variable.
14265 (test_mod_CFLAGS): Likewise.
14266 (test_mod_LDFLAGS): Likewise.
14267 (pkgdata_MODULES): Add `test.mod'.
14268 (grub_script.tab.c): New rule.
14269 (grub_script.tab.h): Likewise.
14270
14271 2005-11-07 Marco Gerards <mgerards@xs4all.nl>
14272
14273 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
14274 `commands/test.c', `normal/execute.c', `normal/lexer.c',
14275 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
14276 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
14277 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
14278 (test_mod_SOURCES): New variable.
14279 (test_mod_CFLAGS): Likewise.
14280 (pkgdata_MODULES): Add `test.mod'.
14281 (grub_script.tab.c): New rule.
14282 (grub_script.tab.h): Likewise.
14283
14284 2005-11-06 Marco Gerards <mgerards@xs4all.nl>
14285
14286 Add initial scripting support.
14287
14288 * commands/test.c: New file.
14289 * include/grub/script.h: Likewise.
14290 * normal/execute.c: Likewise.
14291 * normal/function.c: Likewise.
14292 * normal/lexer.c: Likewise.
14293 * normal/parser.y: Likewise.
14294 * normal/script.c: Likewise.
14295
14296 * configure.ac: Add `AC_PROG_YACC' test.
14297
14298 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/test.c',
14299 `normal/execute.c', `normal/lexer.c', `grub_script.tab.c',
14300 `normal/function.c' and `normal/script.c'.
14301 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
14302 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
14303 (test_mod_SOURCES, test_mod_CFLAGS, test_mod_LDFLAGS): New
14304 variables.
14305 (pkgdata_MODULES): Add `test.mod'.
14306 (grub_script.tab.c): New rule.
14307 (grub_script.tab.h): Likewise.
14308
14309 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TEST_FAILURE'.
14310
14311 * include/grub/normal.h (grub_test_init): New prototype.
14312 (grub_test_fini): Likewise.
14313
14314 * normal/command.c: Include <grub/script.h>.
14315 (grub_command_execute): Rewritten.
14316
14317 * util/grub-emu.c (main): Call `grub_test_init' and
14318 `grub_test_fini'.
14319
14320 2005-11-03 Hollis Blanchard <hollis@penguinppc.org>
14321
14322 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Initialize `msecs'
14323 to 0.
14324 * term/ieee1275/ofconsole.c (grub_ofconsole_checkkey): Return -1 if
14325 there are no pending characters.
14326
14327 2005-11-03 Hollis Blanchard <hollis@penguinppc.org>
14328
14329 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_get_devname): Use
14330 `grub_strndup' to drop device arguments. Replace unnecessary
14331 `grub_strndup' with `grub_strdup'.
14332
14333 2005-11-03 Hollis Blanchard <hollis@penguinppc.org>
14334
14335 * kern/term.c (grub_cls): Do not call grub_cur_term->cls() if the
14336 `debug' environment variable has been set.
14337
14338 2005-11-02 Hollis Blanchard <hollis@penguinppc.org>
14339
14340 * Makefile.in (install-local): Use $(DATA).
14341 (uninstall): Likewise.
14342 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Move grub-mkimage...
14343 (sbin_UTILITIES): ... to here.
14344 (sbin_SCRIPTS): New variable.
14345 (grub_install_SOURCES): New variable.
14346 * util/powerpc/ieee1275/grub-install.in: New file.
14347 * util/powerpc/ieee1275/grub-mkimage.c (kernel_path): Remove
14348 variable.
14349 (add_segments): Call `grub_util_get_path'.
14350
14351 2005-10-28 Yoshinori K. Okuji <okuji@enbug.org>
14352
14353 From Timothy Baldwin:
14354 * commands/ls.c (grub_ls_list_files): Close FILE with
14355 grub_file_close.
14356 * kern/misc.c (grub_vsprintf): Terminate the string S with NUL.
14357
14358 2005-10-24 Marco Gerards <mgerards@xs4all.nl>
14359
14360 * include/grub/parser.h: New file.
14361
14362 * kern/parser.c: Likewise.
14363
14364 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/parser.c'.
14365 (grub_setup_SOURCES): Likewise.
14366 (grub_probefs_SOURCES): Likewise.
14367 (grub_emu_SOURCES): Likewise.
14368 (kernel_img_HEADERS): Add `parser.h'.
14369
14370 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
14371 (grub_emu_SOURCES): Add `kern/parser.c'.
14372 (grubof_SOURCES): Likewise.
14373
14374 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
14375 (grubof_SOURCES): Add `kern/parser.c'.
14376
14377 * include/grub/misc.h (grub_split_cmdline): Removed prototype.
14378
14379 * kern/misc.c (grub_split_cmdline): Removed function.
14380
14381 * kern/rescue.c: Include <grub/parser.h>.
14382 (grub_enter_rescue_mode): Use `grub_parser_split_cmdline' instead
14383 of `grub_split_cmdline'.
14384
14385 * normal/command.c: Include <grub/parser.h>.
14386 (grub_command_execute): Use `grub_parser_split_cmdline' instead
14387 of `grub_split_cmdline'.
14388
14389 * normal/completion.c: Include <grub/parser.h>.
14390 (cmdline_state): New variable.
14391 (iterate_dir): End the filename with a quote depending on the
14392 command line state.
14393 (get_state): new function.
14394 (grub_normal_do_completion): Use `grub_parser_split_cmdline' to
14395 split the arguments and determine the current argument. When the
14396 argument string is not quoted, escape all spaces.
14397
14398 2005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
14399
14400 * normal/sparc64/setjmp.S: New file.
14401
14402 2005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
14403
14404 * include/grub/sparc64/libgcc.h: New file.
14405 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Remove -Av9.
14406 (normal_mod_SOURCES): Use normal/sparc64/setjmp.S instead of
14407 normal/sparc64/setjmp.c.
14408
14409 2005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
14410
14411 * kern/sparc64/dl.c: Rewritten for SPARCV9 ELF.
14412 * kern/sparc64/cache.S: New file.
14413 * kern/sparc64/cache.c: Removed.
14414 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Add -Av9.
14415 (COMMON_CFLAGS): Add -mno-app-regs. Remove -mcpu=v9 and
14416 -mtune=ultrasparc.
14417 (COMMON_LDFLAGS): Add -melf64_sparc.
14418 (grubof_HEADERS): Add sparc64/libgcc.h and machine/kernel.h.
14419 (grubof_SOURCES): Use cache.S instead of cache.c.
14420 (grubof_LDFLAGS): Add -mno-app-regs. Replace "-Xlinker
14421 --oformat -Xlinker elf64-sparc" by "-Bstatic,-melf64_sparc".
14422 (pkgdata_MODULES): Uncomment. Leave linux.mod and _linux.mod
14423 commented though.
14424 (normal_mod_SOURCES): Add normal/completion.c and normal/misc.c.
14425 (_linux_mod_SOURCES, _linux_mod_CFLAGS, linux_mod_SOURCES)
14426 (linux_mod_CFLAGS): Commented out.
14427 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS): New macro, commented
14428 out because module isn't built.
14429 (fshelp_mod_LDFLAGS, fat_mod_LDFLAGS, ext2_mod_LDFLAGS)
14430 (ufs_mod_LDFLAGS, minix_mod_LDFLAGS, hfs_mod_LDFLAGS)
14431 (jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS, normal_mod_LDFLAGS)
14432 (hello_mod_LDFLAGS, boot_mod_LDFLAGS, terminal_mod_LDFLAGS)
14433 (ls_mod_LDFLAGS, cmp_mod_LDFLAGS, cat_mod_LDFLAGS)
14434 (font_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
14435 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
14436 (suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS)
14437 (help_mod_LDFLAGS, default_mod_LDFLAGS, timeout_mod_LDFLAGS)
14438 (configfile_mod_LDFLAGS, search_mod_LDFLAGS, xfs_mod_SOURCES)
14439 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
14440 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
14441 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, gzio_mod_SOURCES)
14442 (gzio_mod_CFLAGS, gzio_mod_LDFLAGS): New macro.
14443
14444 2005-10-20 Yoshinori K. Okuji <okuji@enbug.org>
14445
14446 * util/i386/pc/grub-probefs.c (main): Call grub_xfs_init and
14447 grub_xfs_fini. Do not call grub_hfs_init or grub_hfs_fini any
14448 longer, because HFS should not be used on PC.
14449
14450 2005-10-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
14451
14452 * io/gzio.c (grub_gzio_read): Use OFFSET instead of FILE->OFFSET
14453 consistently within the loop.
14454
14455 2005-10-15 Marco Gerards <mgerards@xs4all.nl>
14456
14457 * fs/xfs.c (grub_xfs_iterate_dir): Detect an error if part of a
14458 directory can not be read.
14459
14460 2005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
14461
14462 * configure.ac (AC_INIT): Increase the version number to 1.91.
14463
14464 * DISTLIST: Added include/grub/terminfo.h, include/grub/tparm.h,
14465 include/grub/i386/pc/serial.h, term/terminfo.c, term/tparm.c and
14466 term/i386/pc/serial.c.
14467
14468 2005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
14469
14470 * kern/file.c (grub_file_seek): Seeking to an offset equal to a
14471 file size must be permitted.
14472
14473 * kern/i386/pc/startup.S (multiboot_trampoline): Fix a mistake
14474 between %ah and %al.
14475
14476 2005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
14477
14478 * fs/xfs.c (grub_xfs_iterate_dir): Change the type of BLK to
14479 grub_uint64_t.
14480 Call the hook with a NUL-terminated filename.
14481 (grub_xfs_mount): Use grub_be_to_cpu32 instead of
14482 grub_cpu_to_be32.
14483
14484 * kern/term.c (cursor_state): New variable.
14485 (grub_term_set_current): Reset the cursor state on a new
14486 terminal.
14487 (grub_setcursor): Rewritten to use CURSOR_STATE.
14488 (grub_getcursor): New function.
14489
14490 * include/grub/term.h (grub_getcursor): New prototype.
14491
14492 * io/gzio.c (test_header): Align BUF for accessing it as 32-bit
14493 integers on ARM. Reported by Timothy Baldwin
14494 <T.E.Baldwin99@members.leeds.ac.uk>.
14495
14496 2005-10-11 Marco Gerards <mgerards@xs4all.nl>
14497
14498 * fs/sfs.c (grub_sfs_open): Don't free `data->label' if it is not
14499 allocated.
14500 (grub_sfs_dir): Likewise.
14501
14502 2005-10-09 Marco Gerards <mgerards@xs4all.nl>
14503
14504 Add support for the SFS filesystem.
14505
14506 * fs/sfs.c: New file.
14507
14508 * DISTLIST: Added `fs/sfs.c'.
14509
14510 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/sfs.c'.
14511 (grub_probefs_SOURCES): Likewise.
14512 (grub_emu_SOURCES): Likewise.
14513 (pkgdata_MODULES): Add `sfs.mod'.
14514 (sfs_mod_SOURCES): New variable.
14515 (sfs_mod_CFLAGS): Likewise.
14516 (sfs_mod_LDFLAGS): Likewise.
14517
14518 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/sfs.c'.
14519 (pkgdata_MODULES): Add `sfs.mod'.
14520 (sfs_mod_SOURCES): New variable.
14521 (sfs_mod_CFLAGS): Likewise.
14522
14523 * util/grub-emu.c (main): Call `grub_sfs_init' and
14524 `grub_sfs_fini'.
14525
14526 * include/grub/fs.h (grub_sfs_init): New prototype.
14527 (grub_sfs_fini): Likewise.
14528
14529 2005-10-07 Marco Gerards <mgerards@xs4all.nl>
14530
14531 Add support for the AFFS filesystem.
14532
14533 * fs/affs.c: New file.
14534
14535 * DISTLIST: Added `fs/affs.c'.
14536
14537 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/affs.c'.
14538 (grub_probefs_SOURCES): Likewise.
14539 (grub_emu_SOURCES): Likewise.
14540 (pkgdata_MODULES): Add `affs.mod'.
14541 (affs_mod_SOURCES): New variable.
14542 (affs_mod_CFLAGS): Likewise.
14543 (affs_mod_LDFLAGS): Likewise.
14544
14545 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/affs.c'.
14546 (pkgdata_MODULES): Add `affs.mod'.
14547 (affs_mod_SOURCES): New variable.
14548 (affs_mod_CFLAGS): Likewise.
14549
14550 * util/grub-emu.c (main): Call `grub_affs_init' and
14551 `grub_affs_fini'.
14552
14553 * include/grub/fs.h (grub_affs_init): New prototype.
14554 (grub_affs_fini): Likewise.
14555
14556 2005-10-01 Marco Gerards <mgerards@xs4all.nl>
14557
14558 * fs/xfs.c (grub_xfs_iterate_dir): Add parentheses.
14559
14560 2005-10-01 Marco Gerards <mgerards@xs4all.nl>
14561
14562 * configure.ac: Accept `x86_64' as host_cpu. In that case add
14563 `-m32' to CFLAGS.
14564
14565 * genmk.rb (class PModule): Always use `$(#{prefix}_LDFLAGS)' when
14566 linking.
14567
14568 * conf/i386-pc.rmk (COMMON_CFLAGS): Add `-m32'.
14569 (COMMON_LDFLAGS): New variable.
14570 (kernel_img_LDFLAGS): Include `COMMON_FLAGS'.
14571 (_chain_mod_LDFLAGS, fshelp_mod_LDFLAGS, fat_mod_LDFLAGS)
14572 (ext2_mod_LDFLAGS, ufs_mod_LDFLAGS, minix_mod_LDFLAGS)
14573 (hfs_mod_LDFLAGS, jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS)
14574 (xfs_mod_LDFLAGS, _linux_mod_LDFLAGS, linux_mod_LDFLAGS)
14575 (normal_mod_LDFLAGS, hello_mod_LDFLAGS, boot_mod_LDFLAGS)
14576 (terminal_mod_LDFLAGS, ls_mod_LDFLAGS, cmp_mod_LDFLAGS)
14577 (cat_mod_LDFLAGS, help_mod_LDFLAGS, reboot_mod_LDFLAGS)
14578 (halt_mod_LDFLAGS, vga_mod_LDFLAGS, font_mod_LDFLAGS)
14579 (terminfo_mod_LDFLAGS, serial_mod_LDFLAGS, _multiboot_mod_LDFLAGS)
14580 (multiboot_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
14581 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
14582 (default_mod_LDFLAGS, timeout_mod_LDFLAGS, configfile_mod_LDFLAGS)
14583 (vbe_mod_LDFLAGS, vesafb_mod_LDFLAGS, vbeinfo_mod_LDFLAGS)
14584 (vbetest_mod_LDFLAGS, search_mod_LDFLAGS, gzio_mod_LDFLAGS): New
14585 variables.
14586 (normal_mod_ASFLAGS): Add `-m32'.
14587
14588 * include/grub/types.h (grub_host_addr_t, grub_host_off_t)
14589 (grub_host_size_t, grub_host_ssize_t): New types.
14590 (grub_addr_t, grub_off_t, grub_size_t, grub_ssize_t): Make type
14591 dependent of `GRUB_CPU_SIZEOF_VOID_P' instead on
14592 `GRUB_HOST_SIZEOF_VOID_P'.
14593
14594 * include/grub/kernel.h (struct grub_module_header): Type of
14595 member offset changed to `grub_host_off_t'. Type of member size
14596 changed to `grub_host_size_t'.
14597 (struct grub_module_info): Type of member offset changed to
14598 `grub_host_off_t'. Type of member size changed to
14599 `grub_host_size_t'.
14600
14601 2005-09-29 Yoshinori K. Okuji <okuji@enbug.org>
14602
14603 Make GRUB's kernel compliant to Multiboot Specification.
14604
14605 * kern/i386/pc/startup.S (multiboot_header): New label.
14606 (multiboot_entry): Likewise.
14607 (multiboot_trampoline): Likewise.
14608
14609 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
14610 Increased to 0x4A0.
14611
14612 * fs/xfs.c (grub_xfs_iterate_dir): Fix a syntax error. You may not
14613 put parentheses after a question mark.
14614 [!GRUB_UTIL] (my_mod): New variable.
14615
14616 * util/grub-emu.c (main): Call grub_xfs_init and grub_xfs_fini.
14617
14618 2005-09-28 Marco Gerards <mgerards@xs4all.nl>
14619
14620 Adds support for the XFS filesystem. Btrees are not supported
14621 yet.
14622
14623 * fs/xfs.c: New file.
14624
14625 * DISTLIST: Added `fs/xfs.c'.
14626
14627 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/xfs.c'.
14628 (grub_probefs_SOURCES): Likewise.
14629 (grub_emu_SOURCES): Likewise.
14630 (pkgdata_MODULES): Add `xfs.mod'.
14631 (xfs_mod_SOURCES): New variable.
14632 (xfs_mod_CFLAGS): Likewise.
14633
14634 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/xfs.c'.
14635 (pkgdata_MODULES): Add `xfs.mod'.
14636 (xfs_mod_SOURCES): New variable.
14637 (xfs_mod_CFLAGS): Likewise.
14638
14639 * util/grub-emu.c (main): Call `grub_xfs_init' and
14640 `grub_xfs_fini'.
14641
14642 * include/grub/fs.h (grub_xfs_init): New prototype.
14643 (grub_xfs_fini): Likewise.
14644
14645
14646 2005-09-18 Vesa Jaaskelainen <chaac@nic.fi>
14647
14648 * video/i386/pc/vbe.c (grub_vbe_set_video_mode): In indexed
14649 color modes, allow greater than 16 colors to be configured as
14650 a default palette.
14651
14652 2005-09-03 Yoshinori K. Okuji <okuji@enbug.org>
14653
14654 * normal/completion.c (complete_arguments): Add the qualifier
14655 const into OPTIONS.
14656
14657 From Omniflux <omniflux+lists@omniflux.com>:
14658 * include/grub/terminfo.h: New file.
14659 * include/grub/tparm.h: Likewise.
14660 * include/grub/i386/pc/serial.h: Likewise.
14661 * term/terminfo.c: Likewise.
14662 * term/tparm.c: Likewise.
14663 * term/i386/pc/serial.c: Likewise.
14664 * conf/i386-pc.rmk (pkgdata_MODULES): Added terminfo.mod and
14665 serial.mod.
14666 (terminfo_mod_SOURCES): New variable.
14667 (terminfo_mod_CFLAGS): Likewise.
14668 (serial_mod_SOURCES): Likewise.
14669 (serial_mod_CFLAGS): Likewise.
14670
14671 2005-08-31 Yoshinori K. Okuji <okuji@enbug.org>
14672
14673 * DISTLIST: Replaced boot/powerpc/ieee1275/crt0.S and
14674 boot/powerpc/ieee1275/cmain.c with kern/powerpc/ieee1275/crt0.S
14675 and kern/powerpc/ieee1275/cmain.c, respectively.
14676
14677 * boot/powerpc/ieee1275/crt0.S: Moved to ...
14678 * kern/powerpc/ieee1275/crt0.S: ... here.
14679
14680 * boot/powerpc/ieee1275/cmain.c: Moved to ...
14681 * kern/powerpc/ieee1275/cmain.c: ... here.
14682
14683 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Use
14684 kern/powerpc/ieee1275/crt0.S and kern/powerpc/ieee1275/cmain.c
14685 instead of boot/powerpc/ieee1275/crt0.S and
14686 boot/powerpc/ieee1275/cmain.c, respectively.
14687
14688 * boot/i386/pc/boot.S (lba_mode): Do not store the total number of
14689 sectors. It was not used anyway.
14690
14691 2005-08-30 Hollis Blanchard <hollis@penguinppc.org>
14692
14693 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): Fix
14694 `unused parameter' warning.
14695
14696 2005-08-30 Hollis Blanchard <hollis@penguinppc.org>
14697
14698 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): New
14699 function.
14700 (grub_ofconsole_term): Specify grub_ofconsole_getcharwidth as
14701 getcharwidth.
14702
14703 2005-08-28 Marco Gerards <metgerards@student.han.nl>
14704
14705 * include/grub/normal.h (enum grub_completion_type): Added
14706 `GRUB_COMPLETION_TYPE_ARGUMENT'.
14707
14708 * normal/cmdline.c (print_completion): Handle
14709 the `GRUB_COMPLETION_TYPE_ARGUMENT' type.
14710 * normal/menu_entry.c (store_completion): Likewise.
14711
14712 * normal/completion.c (complete_arguments): New function.
14713 (grub_normal_do_completion): Call `complete_arguments' when the
14714 current words start with a dash.
14715
14716 2005-08-27 Marco Gerards <metgerards@student.han.nl>
14717
14718 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Fix typo (use
14719 `gzio.mod' instead of `io.mod').
14720
14721 2005-08-22 Yoshinori K. Okuji <okuji@enbug.org>
14722
14723 * gendistlist.sh (EXTRA_DISTFILES): Added genfslist.sh.
14724 (DISTDIRS): Added io and video.
14725 Rewrite the search routine to make an output consistently.
14726
14727 * DISTLIST: Added conf/sparc64-ieee1275.mk,
14728 conf/sparc64-ieee1275.rmk, include/grub/gzio.h,
14729 include/grub/ieee1275/ieee1275.h, include/grub/ieee1275/ofdisk.h,
14730 io/gzio.c, kern/sparc64/cache.c, kern/sparc64/dl.c,
14731 kern/sparc64/ieee1275/init.c, kern/sparc64/ieee1275/openfw.c and
14732 util/powerpc/ieee1275/misc.c.
14733
14734 * include/grub/gzio.h: New file.
14735 * io/gzio.c: Likewise.
14736
14737 * kern/file.c (grub_file_close): Call grub_device_close only if
14738 FILE->DEVICE is not NULL.
14739
14740 * include/grub/mm.h [!NULL] (NULL): New macro.
14741
14742 * include/grub/err.h (GRUB_ERR_BAD_GZIP_DATA): New constant.
14743
14744 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added io/gzip.c.
14745 (pkgdata_MODULES): Added gzio.mod.
14746 (gzio_mod_SOURCES): New variable.
14747 (gzio_mod_CFLAGS): Likewise.
14748
14749 * conf/i386-pc.rmk (grub_emu_SOURCES): Added io/gzip.c.
14750 (pkgdata_MODULES): Added gzio.mod.
14751 (gzio_mod_SOURCES): New variable.
14752 (gzio_mod_CFLAGS): Likewise.
14753
14754 * commands/cat.c: Include grub/gzio.h.
14755 (grub_cmd_cat): Use grub_gzfile_open instead of
14756 grub_file_open.
14757
14758 * commands/cmp.c: Include grub/gzio.h.
14759 (grub_cmd_cmp): Use grub_gzfile_open instead of
14760 grub_file_open.
14761
14762 * loader/i386/pc/multiboot.c: Include grub/gzio.h.
14763 (grub_rescue_cmd_multiboot): Use grub_gzfile_open instead of
14764 grub_file_open.
14765 (grub_rescue_cmd_module): Likewise.
14766
14767 2005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
14768
14769 * conf/sparc64-ieee1275.rmk (grubof_SOURCES): The first file must be
14770 kern/sparc64/ieee1275/init.c because it contains _start.
14771 * conf/sparc64-ieee1275.mk: Generated from conf/sparc64-ieee1275.rmk.
14772
14773 2005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
14774
14775 * configure.ac: Add support for sparc64 host with ieee1275
14776 firmware.
14777 * configure: Generated from configure.ac.
14778 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Use grub_ssize_t
14779 instead of int.
14780 (grub_ofdisk_read): Likewise.
14781 (grub_ofdisk_open): Use %p to print pointer values, and cast the
14782 pointers as (void *) to remove a warning.
14783 (grub_ofdisk_close): Likewise.
14784 (grub_ofdisk_read): Likewise.
14785 * kern/ieee1275/ieee1275.c (grub_ieee1275_exit): This never
14786 returns, so make it return void to remove a warning.
14787 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_exit):
14788 Corresponding prototype change.
14789 * kern/mm.c (grub_mm_init_region): Use %p to print pointer
14790 values, and cast the pointers as (void *) to remove a warning.
14791 (grub_mm_dump): Likewise.
14792 * conf/sparc64-ieee1275.mk: New file.
14793 * conf/sparc64-ieee1275.rmk: Likewise.
14794 * include/grub/sparc64/setjmp.h: Likewise.
14795 * include/grub/sparc64/types.h: Likewise.
14796 * include/grub/sparc64/ieee1275/console.h: Likewise.
14797 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
14798 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
14799 * include/grub/sparc64/ieee1275/time.h: Likewise.
14800 * kern/sparc64/cache.c: Likewise.
14801 * kern/sparc64/dl.c: Likewise.
14802 * kern/sparc64/ieee1275/init.c: Likewise.
14803 * kern/sparc64/ieee1275/openfw.c: Likewise.
14804
14805 2005-08-21 Yoshinori K. Okuji <okuji@enbug.org>
14806
14807 * util/console.c (grub_ncurses_putchar): If C is greater than
14808 0x7f, set C to a question mark.
14809 (grub_ncurses_getcharwidth): New function.
14810 (grub_ncurses_term): Specify grub_ncurses_getcharwidth as
14811 getcharwidth.
14812
14813 * normal/menu.c (print_entry): Made aware of Unicode. First,
14814 convert TITLE to UCS-4, and predict the cursor position by
14815 grub_getcharwidth.
14816
14817 * include/grub/misc.h (grub_utf8_to_ucs4): Specify the qualifier
14818 const to SRC.
14819 * kern/misc.c (grub_utf16_to_utf8): Likewise.
14820
14821 2005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
14822
14823 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Specify
14824 the boot file by the option BOOT_IMAGE. Use grub_stpcpy instead of
14825 grub_strcat.
14826
14827 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Specify the boot
14828 file by the option BOOT_IMAGE. Use grub_stpcpy instead of
14829 grub_strcpy and grub_strlen. Take it into account that a space
14830 character is inserted as a delimiter.
14831
14832 2005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
14833
14834 * partmap/pc.c (pc_partition_map_iterate): Include the value of an
14835 invalid magic in the error.
14836
14837 * commands/search.c: New file.
14838
14839 * util/grub-emu.c (main): Call grub_search_init and
14840 grub_search_fini.
14841
14842 * kern/rescue.c (grub_rescue_print_disks): Removed.
14843 (grub_rescue_print_devices): New function.
14844 (grub_rescue_cmd_ls): Use grub_device_iterate with
14845 grub_rescue_print_devices instead of grub_disk_dev_iterate with
14846 grub_rescue_print_disks.
14847
14848 * kern/partition.c (grub_partition_iterate): Return the result of
14849 PARTMAP->ITERATE instead of GRUB_ERRNO.
14850
14851 * kern/device.c: Include grub/partition.h.
14852 (grub_device_iterate): New function.
14853
14854 * include/grub/partition.h (grub_partition_iterate): Return int
14855 instead of grub_err_t.
14856
14857 * include/grub/normal.h [GRUB_UTIL] (grub_search_init): New
14858 prototype.
14859 [GRUB_UTIL] (grub_search_fini): Likewise.
14860
14861 * include/grub/device.h (grub_device_iterate): New prototype.
14862
14863 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
14864 commands/search.c.
14865 (pkgdata_MODULES): Added search.mod.
14866 (search_mod_SOURCES): New variable.
14867 (search_mod_CFLAGS): Likewise.
14868
14869 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/search.c.
14870 (pkgdata_MODULES): Added search.mod.
14871 (search_mod_SOURCES): New variable.
14872 (search_mod_CFLAGS): Likewise.
14873
14874 * commands/ls.c (grub_ls_list_disks): Renamed to ...
14875 (grub_ls_list_devices): ... this, and use grub_device_iterate.
14876 All callers changed.
14877
14878 * DISTLIST: Added commands/search.c.
14879
14880 2005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
14881
14882 * kern/term.c (grub_putchar): Use grub_utf8_to_ucs4 for the
14883 conversion.
14884 (grub_getcharwidth): New function.
14885
14886 * kern/misc.c (grub_utf8_to_ucs4): New function.
14887
14888 * include/grub/term.h (struct grub_term): Added a new member
14889 "getcharwidth".
14890 (grub_getcharwidth): New prototype.
14891
14892 * include/grub/misc.h (grub_utf8_to_ucs4): New prototype.
14893
14894 * term/i386/pc/console.c (map_char): New function. Segregated from
14895 grub_console_putchar.
14896 (grub_console_putchar): Use map_char.
14897 (grub_console_getcharwidth): New function.
14898 (grub_console_term): Specified grub_console_getcharwidth as
14899 getcharwidth.
14900
14901 * term/i386/pc/vga.c (grub_vga_getcharwidth): New function.
14902 (grub_vga_term): Specified grub_vga_getcharwidth as getcharwidth.
14903
14904 * term/i386/pc/vesafb.c (grub_virtual_screen_setup): Return
14905 GRUB_ERRNO.
14906 (grub_vesafb_init): Do not use RC. Instead, use GRUB_ERRNO. Rely
14907 on grub_strtoul completely.
14908 (write_char): Declare local variables in the beginning of the
14909 function.
14910 (grub_vesafb_getcharwidth): New function.
14911 (grub_vesafb_term): Specified grub_vesafb_getcharwidth as
14912 getcharwidth.
14913
14914 2005-08-19 Yoshinori K. Okuji <okuji@enbug.org>
14915
14916 * DISTLIST: Replace commands/i386/pc/vbe_list_modes.c and
14917 commands/i386/pc/vbe_test.c with commands/i386/pc/vbeinfo.c and
14918 commands/i386/pc/vbetest.c.
14919
14920 * video/i386/pc/vbe.c (grub_vbe_probe): If INFOBLOCK is not NULL,
14921 call grub_vbe_get_controller_info again, because the returned
14922 information is volatile.
14923 (grub_vbe_set_video_mode): Mostly rewritten.
14924 (grub_vbe_get_video_mode): Use grub_vbe_probe and use
14925 grub_vbe_status_t correctly.
14926 (grub_vbe_get_video_mode_info): Likewise.
14927 (grub_vbe_set_pixel_rgb): Use a switch statement rather than
14928 several if statements.
14929
14930 * commands/i386/pc/vbe_list_modes.c: Renamed to ...
14931 * commands/i386/pc/vbeinfo.c: ... this.
14932
14933 * commands/i386/pc/vbe_test.c: Renamed to ...
14934 * commands/i386/pc/vbetest.c: ... this.
14935
14936 * commands/i386/pc/vbeinfo.c (grub_cmd_vbe_list_modes): Renamed to
14937 ...
14938 (grub_cmd_vbeinfo): ... this. Save video modes before
14939 iterating. Skip a video mode, if it is not available, not enough
14940 information is given or it is monochrome. Show the memory
14941 model. Leave the interpretation of MODEVAR to grub_strtoul
14942 completely.
14943 (GRUB_MOD_INIT): Rename vbe_list_modes to vbeinfo.
14944 (GRUB_MOD_FINI): Likewise.
14945
14946 * commands/i386/pc/vbetest.c (grub_cmd_vbe_test): Renamed to ...
14947 (grub_cmd_vbetest): ... this. Don't print unnecessarily. Use
14948 grub_err_t instead of grub_uint32_t. Don't use SPTR. Remove a
14949 duplicated grub_env_get. Leave the interpretation of MODEVAR to
14950 grub_strtoul completely.
14951 (real2pm): Removed.
14952 (GRUB_MOD_INIT): Rename vbe_test to vbetest.
14953 (GRUB_MOD_FINI): Likewise.
14954
14955 * normal/misc.c: Include grub/mm.h.
14956
14957 * conf/i386-pc.rmk (pkgdata_MODULES): Replaced vbe_test.mod and
14958 vbe_list_modes with vbetest.mod and vbeinfo.mod.
14959 (vbe_list_modes_mod_SOURCES): Removed.
14960 (vbe_list_modes_mod_CFLAGS): Likewise.
14961 (vbe_test_mod_SOURCES): Likewise.
14962 (vbe_test_mod_CFLAGS): Likewise.
14963 (vbeinfo_mod_SOURCES): New variable.
14964 (vbeinfo_mod_CFLAGS): Likewise.
14965 (vbetest_mod_SOURCES): Likewise.
14966 (vbetest_mod_CFLAGS): Likewise.
14967
14968 2005-08-18 Yoshinori K. Okuji <okuji@enbug.org>
14969
14970 * normal/misc.c: New file.
14971
14972 * DISTLIST: Added normal/misc.c.
14973
14974 * partmap/amiga.c (amiga_partition_map_iterate): Add an argument
14975 DISK to HOOK. Call HOOK with DISK.
14976 * partmap/apple.c (apple_partition_map_iterate): Likewise.
14977 * partmap/pc.c (pc_partition_map_iterate): Likewise.
14978 * partmap/sun.c (sun_partition_map_iterate): Likewise.
14979
14980 * normal/menu_entry.c (struct screen): Added a new member
14981 "completion_shown".
14982 (completion_buffer): New global variable.
14983 (make_screen): Set SCREEN->COMPLETION_SHOWN to zero.
14984 (store_completion): New function.
14985 (complete): Likewise.
14986 (clear_completions): Likewise.
14987 (grub_menu_entry_run): If SCREEN->COMPLETION_SHOWN is non-zero,
14988 call clear_completions and reset SCREEN->COMPLETION_SHOWN. If C is
14989 a tab, call complete.
14990
14991 * normal/completion.c (disk_dev): Removed.
14992 (print_simple_completion): Likewise.
14993 (print_partition_completion): Likewise.
14994 (print_func): New global variable.
14995 (add_completion): Do not take the arguments WHAT or PRINT any
14996 longer. Added a new argument TYPE. Instead of printing directly,
14997 call PRINT_FUNC if not NULL.
14998 All callers changed.
14999 (complete_device): Use a local variable DEV instead of
15000 DISK_DEV. Do not move CURRENT_WORD to the end of a device name.
15001 (grub_normal_do_completion): Take a new argument HOOK. Do not
15002 initialize DISK_DEV. Initialize PRINT_FUNC to HOOK. If RET is an
15003 empty string, return NULL instead.
15004 All callers changed.
15005
15006 * normal/cmdline.c (print_completion): New function.
15007
15008 * kern/partition.c (grub_partition_iterate): Add an argument DISK
15009 to HOOK.
15010 All callers changed.
15011
15012 * kern/disk.c (grub_print_partinfo): Removed.
15013
15014 * include/grub/partition.h (struct grub_partition_map): Add a new
15015 argument DISK into HOOK of ITERATE.
15016 (grub_partition_iterate): Add a new argument DISK to HOOK.
15017
15018 * include/grub/normal.h (enum grub_completion_type): New enum.
15019 (grub_completion_type_t): New type.
15020 (GRUB_COMPLETION_TYPE_COMMAND): New constant.
15021 (GRUB_COMPLETION_TYPE_DEVICE): Likewise.
15022 (GRUB_COMPLETION_TYPE_PARTITION): Likewise.
15023 (GRUB_COMPLETION_TYPE_FILE): Likewise.
15024 (grub_normal_do_completion): Added a new argument HOOK.
15025 (grub_normal_print_device_info): New prototype.
15026
15027 * include/grub/disk.h (grub_print_partinfo): Removed.
15028
15029 * conf/i386-pc.rmk (grub_emu_SOURCES): Added normal/misc.c.
15030 (normal_mod_SOURCES): Likewise.
15031 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
15032 (normal_mod_SOURCES): Likewise.
15033
15034 * commands/ls.c (grub_ls_list_disks): Use
15035 grub_normal_print_device_info instead of grub_print_partinfo. Free
15036 PNAME.
15037 (grub_ls_list_files): Use grub_normal_print_device_info instead of
15038 duplicating the code.
15039
15040 2005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
15041
15042 * commands/i386/pc/vbe_list_modes.c: Update source formatting to
15043 follow GCS more precisely.
15044 * commands/i386/pc/vbe_test.c: Likewise.
15045 * include/grub/i386/pc/vbe.h: Likewise.
15046 * term/i386/pc/vesafb.c: Likewise.
15047 * video/i386/pc/vbe.c: Likewise.
15048
15049 2005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
15050
15051 * DISTLIST: Added term/i386/pc/vesafb.c
15052 DISTLIST: Added video/i386/pc/vbe.c
15053 DISTLIST: Added commands/i386/pc/vbe_list_modes.c.
15054 DISTLIST: Added commands/i386/pc/vbe_test.c.
15055 * commands/i386/pc/vbe_list_modes.c: New file.
15056 * commands/i386/pc/vbe_test.c: Likewise.
15057 * term/i386/pc/vesafb.c: Likewise.
15058 * video/i386/pc/vbe.c: Likewise.
15059 * include/grub/i386/pc/vbe.h (GRUB_VBE_DEFAULT_VIDEO_MODE): Added define.
15060 (grub_vbe_probe) Added prototype.
15061 (grub_vbe_set_video_mode) Likewise.
15062 (grub_vbe_get_video_mode) Likewise.
15063 (grub_vbe_get_video_mode_info) Likewise.
15064 (grub_vbe_set_pixel_rgb) Likewise.
15065 (grub_vbe_set_pixel_index) Likewise.
15066 * conf/i386-pc.rmk (pkgdata_MODULES): Added vbe.mod.
15067 (pkgdata_MODULES): Added vesafb.mod.
15068 (pkgdata_MODULES): Added vbe_list_modes.mod.
15069 (pkgdata_MODULES): Added vbe_test.mod.
15070 (vbe_mod_SOURCES): Added.
15071 (vbe_mod_CFLAGS): Likewise.
15072 (vesafb_mod_SOURCES): Likewise.
15073 (vesafb_mod_CFLAGS): Likewise.
15074 (vbe_list_modes_mod_SOURCES): Likewise.
15075 (vbe_list_modes_mod_CFLAGS): Likewise.
15076 (vbe_test_mod_SOURCES): Likewise.
15077 (vbe_test_mod_CFLAGS): Likewise.
15078
15079 2005-08-14 Yoshinori K. Okuji <okuji@enbug.org>
15080
15081 * normal/command.c (grub_command_execute): If INTERACTIVE is
15082 false and GRUB_COMMAND_FLAG_NO_ECHO is not specified, print
15083 CMDLINE. Disable the pager if INTERACTIVE is true.
15084 All callers are changed.
15085
15086 * normal/main.c (grub_normal_execute): Read command.lst and fs.lst
15087 before reading a config file.
15088 * normal/main.c (read_config_file): Even if a command is not
15089 found, register it if it is within an entry.
15090
15091 * util/grub-emu.c: Include sys/types.h and unistd.h.
15092 (options): Added --hold.
15093 (struct arguments): Added a new member "hold".
15094 (parse_opt): If KEY is 'H', set ARGS->HOLD to ARG or -1 if ARG is
15095 missing.
15096 (main): Initialize ARGS.HOLD to zero. Wait until ARGS.HOLD is
15097 cleared by a debugger, if it is not zero.
15098
15099 * include/grub/normal.h (grub_command_execute): Add an argument
15100 INTERACTIVE.
15101
15102 2005-08-14 Vesa Jaaskelainen <chaac@nic.fi>
15103
15104 * DISTLIST: Added include/grub/i386/pc/vbe.h.
15105
15106 2005-08-13 Yoshinori K. Okuji <okuji@enbug.org>
15107
15108 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Replace the test
15109 program with another one, because the old one didn't detect a bug
15110 in gcc-3.4. Always use regparm 2, because the new test is still
15111 not enough for gcc-4.0. Someone must investigate a simple test
15112 case which detects a bug in gcc-4.0.
15113
15114 2005-08-12 Yoshinori K. Okuji <okuji@enbug.org>
15115
15116 * DISTLIST: Added normal/completion.c.
15117
15118 * normal/completion.c: New file.
15119
15120 * term/i386/pc/console.c (grub_console_getwh): New function.
15121 (grub_console_term): Assign grub_console_getwh to getwh.
15122
15123 * normal/cmdline.c (grub_tab_complete): Removed. Now the same
15124 function is defined in normal/completion.c as
15125 grub_normal_do_completion.
15126 (grub_cmdline_get): Use grub_normal_do_completion instead of
15127 grub_tab_complete.
15128
15129 * kern/partition.c (grub_partition_map_iterate): Return 1 if HOOK
15130 returns non-zero, otherwise return 0.
15131 (grub_partition_iterate): First, probe the partition map. Then,
15132 call ITERATE only for this partition map.
15133
15134 * kern/misc.c (grub_strncmp): Rewritten.
15135
15136 * kern/disk.c (grub_disk_dev_iterate): Return 1 if P->ITERATE
15137 returns non-zero. Otherwise return 0.
15138
15139 * include/grub/partition.h (grub_partition_map_iterate): Return
15140 int instead of void.
15141
15142 * include/grub/normal.h (grub_normal_do_completion): New prototype.
15143
15144 * include/grub/misc.h (grub_strncmp): Change the type of N to
15145 grub_size_t.
15146
15147 * include/grub/disk.h (grub_disk_dev_iterate): Return int instead
15148 of void.
15149
15150 * normal/menu.c (draw_border): Cast GRUB_TERM_BORDER_WIDTH to
15151 unsigned explicitly before comparing it with I.
15152
15153 * kern/main.c (grub_env_write_root): Add the attribute unused into
15154 VAR.
15155
15156 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
15157 normal/completion.c.
15158 (normal_mod_SOURCES): Likewise.
15159 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
15160 (normal_mod_SOURCES): Likewise.
15161
15162 * normal/command.c (grub_iterate_commands): If ITERATE returns
15163 non-zero, return one immediately.
15164
15165 2005-08-09 Vesa Jaaskelainen <chaac@nic.fi>
15166
15167 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vbe.h.
15168 * kern/i386/pc/startup.S: Updated Global Descriptor table's
15169 descriptions.
15170 (grub_vbe_get_controller_info): New function.
15171 (grub_vbe_get_mode_info): Likewise.
15172 (grub_vbe_set_mode): Likewise.
15173 (grub_vbe_get_mode): Likewise.
15174 (grub_vbe_set_memory_window): Likewise.
15175 (grub_vbe_get_memory_window): Likewise.
15176 (grub_vbe_set_scanline_length): Likewise.
15177 (grub_vbe_get_scanline_length): Likewise.
15178 (grub_vbe_set_display_start): Likewise.
15179 (grub_vbe_get_display_start): Likewise.
15180 (grub_vbe_set_palette_data): Likewise.
15181 * include/grub/i386/pc/vbe.h: New file.
15182
15183 2005-08-08 Hollis Blanchard <hollis@penguinppc.org>
15184
15185 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
15186 kern/ieee1275/of.c with kern/ieee1275/ieee1275.c.
15187 * DISTLIST: Likewise.
15188 * kern/ieee1275/of.c: Moved to ...
15189 * kern/ieee1275/ieee1275.c: ... here.
15190
15191 2005-08-08 Hollis Blanchard <hollis@penguinppc.org>
15192
15193 * term/ieee1275/ofconsole.c: Include <grub/mm.h>.
15194 (grub_ofconsole_getwh): Cast -1 to type grub_ieee1275_ihandle_t.
15195 Pass 0 as `end' parameter to grub_strtoul().
15196
15197 2005-08-08 Hollis Blanchard <hollis@penguinppc.org>
15198
15199 * include/grub/powerpc/ieee1275/console.h: Do not include
15200 <grub/types.h>. Do not include <grub/symbol.h>. Remove ASM_FILE
15201 ifdef.
15202 (grub_console_cur_color): Remove i386-specific prototype.
15203 (grub_console_real_putchar): Likewise.
15204 (grub_console_checkkey): Likewise.
15205 (grub_console_getkey): Likewise.
15206 (grub_console_getxy): Likewise.
15207 (grub_console_gotoxy): Likewise.
15208 (grub_console_cls): Likewise.
15209 (grub_console_setcursor): Likewise.
15210 * kern/powerpc/ieee1275/init.c: Don't include <grub/console.h>.
15211 Include <grub/machine/console.h>.
15212 * term/ieee1275/ofconsole.c: Likewise.
15213
15214 2005-08-08 Yoshinori K. Okuji <okuji@enbug.org>
15215
15216 * Makefile.in (LIBLZO): New variable.
15217
15218 * configure.ac: Check for LZO version 2.
15219
15220 * util/i386/pc/grub-mkimage.c [HAVE_LZO_LZO1X_H]: Include
15221 lzo/lzo1x.h instead of lzo1x.h.
15222
15223 * conf/i386-pc.rmk (grub_mkimage_LDFLAGS): Use $(LIBLZO) instead
15224 of -llzo.
15225
15226 * util/i386/pc/grub-setup.c (main): Do not free PREFIX
15227 twice. Reported by Vladimir Serbinenko <phcoder@gmail.com>.
15228
15229 * partmap/pc.c (pc_partition_map_probe): Restore P->DATA after
15230 copying the data from PARTITION to P.
15231
15232 2005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
15233
15234 * kern/rescue.c (grub_rescue_cmd_rmmod): If the reference count is
15235 negative, unload the module.
15236
15237 * util/i386/pc/grub-setup.c (setup): The name of the PC partition
15238 map is "pc_partition_map" but not "pc".
15239 (usage): Fix the description. The options are --boot-image and
15240 --core-image but not --boot-file or --core-file.
15241 (main): If not specified explicitly, make BOOT_FILE and CORE_FILE
15242 based on DEFAULT_BOOT_FILE and DEFAULT_CORE_FILE with DIR or
15243 DEFAULT_DIRECTORY.
15244
15245 * util/i386/pc/grub-install.in: Do not specify --boot-file or
15246 --core-file. Specify INSTALL_DEVICE as an argument.
15247
15248 * util/console.c: Include config.h.
15249 [HAVE_NCURSeS_CURSES_H]: Include ncurses/curses.h.
15250 [HAVE_NCURSES_H]: Include ncurses.h.
15251 [HAVE_CURSES_H]: Include curses.h.
15252 [!A_NORMAL] (A_NORMAL): Defined as zero.
15253 [!A_STANDOUT] (A_STANDOUT): Likewise.
15254
15255 * conf/i386-pc.rmk (grub_emu_LDFLAGS): Use $(LIBCURSES) instead of
15256 -lncurses.
15257 * conf/powerpc-ieee1275.rmk (grub_emu_LDFLAGS): Likewise.
15258
15259 * configure.ac: Check for curses libraries and headers.
15260
15261 * Makefile.in (LIBCURSES): New variable.
15262
15263 * genmk.rb (Script::rule): Set the executable bits.
15264
15265 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): The
15266 name of the PC partition map is "pc_partition_map" but not "pc".
15267
15268 2005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
15269
15270 * util/i386/pc/grub-install.in (grub_probefs): New variable.
15271 (modules): Likewise.
15272 (usage): Added descriptions for --modules and --grub-probefs.
15273 Handle --modules and --grub-probefs. Save the arguments in MODULES
15274 and GRUB_PROBEFS, respectively.
15275 Auto-detect a filesystem module against GRUBDIR. If the result is
15276 empty and modules are not specified explicitly, abort the
15277 installation. Add the result to MODULES.
15278
15279 * DISTLIST: Removed boot/powerpc/ieee1275/ieee1275.c,
15280 disk/powerpc/ieee1275/ofdisk.c,
15281 include/grub/powerpc/ieee1275/init.h and
15282 term/powerpc/ieee1275/ofconsole.c.
15283 Added disk/ieee1275/ofdisk.c, kern/ieee1275/of.c and
15284 term/ieee1275/ofconsole.c.
15285
15286 * include/grub/powerpc/ieee1275/console.h: Resurrected.
15287
15288 * COPYING: Upgraded to the latest version. Only the address of the
15289 FSF office has changed.
15290
15291 2005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
15292
15293 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
15294 kern/ieee1275.c with kern/ieee1275/of.c.
15295
15296 * kern/ieee1275.c: Moved to ...
15297 * kern/ieee1275/of.c: ... here.
15298
15299 2005-08-06 Yoshinori K. Okuji <okuji@enbug.org>
15300
15301 * conf/i386-pc.rmk (kernel_img_HEADERS): Reordered for
15302 readability.
15303
15304 * config.guess: Updated to the latest version from gnulib.
15305 * config.sub: Likewise.
15306 * install.sh: Likewise.
15307 * mkinstalldirs: Likewise.
15308
15309 * include/grub/console.h: Removed. This file is arch-specific. Do
15310 not put this in include/grub.
15311
15312 * include/grub/i386/pc/console.h: Resurrected.
15313
15314 * util/console.c: Include grub/machine/console.h instead of
15315 grub/console.h.
15316 * util/grub-emu.c: Likewise.
15317
15318 2005-08-04 Marco Gerards <metgerards@student.han.nl>
15319
15320 * kern/term.c (grub_putcode): Use `grub_getwh' instead of
15321 hardcoded value.
15322
15323 From Vincent Pelletier <subdino2004@yahoo.fr>
15324 * include/grub/term.h (GRUB_TERM_WIDTH, GRUB_TERM_HEIGHT):
15325 Redefined to use grub_getwh.
15326 (grub_term): New member named getwh.
15327 (grub_getwh): New prototype.
15328 * kern/term.c (grub_getwh): New function.
15329 * term/i386/pc/console.c (grub_console_getwh): New function.
15330 (grub_console_term): New member `getwh'.
15331 * term/i386/pc/vga.c (grub_vga_getwh): New function.
15332 (grub_vga_term): New member `getwh'.
15333 * term/ieee1275/ofconsole.c (grub_ofconsole_readkey): Use
15334 grub_ssize_t.
15335 (grub_ofconsole_getw): New function.
15336 (grub_ofconsole_init): Use grub_ssize_t and unsigned char.
15337 (grub_ofconsole_term): New field named getwh and new initial
15338 value.
15339
15340 2005-08-03 Hollis Blanchard <hollis@penguinppc.org>
15341
15342 * include/grub/powerpc/ieee1275/ieee1275.h: Move ...
15343 * include/grub/ieee1275/ieee1275.h: ... to here. All users updated.
15344 Move `abort', `grub_reboot', and `grub_halt' prototypes ...
15345 * include/grub/powerpc/ieee1275/kernel.h: ... to here.
15346 * commands/ieee1275/halt.c: Include <grub/machine/kernel.h> instead
15347 of <grub/machine/ieee1275.h>.
15348 * commands/ieee1275/reboot.c: Likewise.
15349 * boot/powerpc/ieee1275/ieee1275.c: Move ...
15350 * kern/ieee1275.c: ... to here. All users updated. Change all
15351 parameter structs to use new type `grub_ieee1275_cell_t'.
15352 * term/powerpc/ieee1275/ofconsole.c: Move ...
15353 * term/ieee1275/ofconsole.c: ... to here. All users updated.
15354 * disk/powerpc/ieee1275/ofdisk.c: Move ...
15355 * disk/ieee1275/ofdisk.c: ... to here. All users updated.
15356 * boot/powerpc/ieee1275/cmain.c: Change `grub_ieee1275_entry_fn' type
15357 to return int.
15358 * include/grub/i386/pc/console.h: Move to include/grub/console.h.
15359 Remove unused prototypes. All users updated.
15360 * include/grub/powerpc/ieee1275/console.h: Removed.
15361 * include/grub/powerpc/ieee1275/ieee1275.h: Define
15362 `grub_ieee1275_cell_t'.
15363 * kern/powerpc/ieee1275/openfw.c: Include <grub/machine/kernel.h>.
15364 Cast comparisons with -1 to the correct type.
15365 * loader/powerpc/ieee1275/linux.c (kernel_entry_t): Change parameter
15366 type to match `grub_ieee1275_entry_fn'.
15367
15368 2005-08-01 Yoshinori K. Okuji <okuji@enbug.org>
15369
15370 * DISTLIST: Added util/i386/pc/grub-probefs.c.
15371
15372 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-probefs.
15373 (grub_setup_SOURCES): Removed partmap/amiga.c, partmap/apple.c and
15374 partmap/sun.c.
15375 (grub_probefs_SOURCES): New variable.
15376
15377 * util/i386/pc/grub-probefs.c: New file.
15378
15379 * util/i386/pc/grub-setup.c (main): Call
15380 grub_pc_partition_map_init, grub_ufs_init, grub_minix_init,
15381 grub_hfs_init and grub_jfs_init to initialize the system. Call
15382 grub_ufs_fini, grub_minix_fini, grub_hfs_fini, grub_jfs_init and
15383 grub_pc_partition_map_fini to finish the system.
15384
15385 2005-07-31 Yoshinori K. Okuji <okuji@enbug.org>
15386
15387 * loader/i386/pc/multiboot.c (grub_multiboot_is_elf32): New
15388 function.
15389 (grub_multiboot_load_elf32): Likewise.
15390 (grub_multiboot_is_elf64): Likewise.
15391 (grub_multiboot_load_elf64): Likewise.
15392 (grub_multiboot_load_elf): Likewise.
15393 (grub_rescue_cmd_multiboot): Call grub_multiboot_load_elf to load
15394 an ELF32 or ELF64 file.
15395 This is based on a patch from Ruslan Nikolaev <nruslan@mail.com>.
15396
15397 From Serbinenko Vladimir <serbinenko.vova@list.ru>:
15398 * kern/disk.c (grub_print_partinfo): Check if FS->LABEL is not
15399 NULL before calling FS->LABEL.
15400 * fs/fat.c (grub_fat_dir): Initialize DIRNAME to NULL.
15401 * commands/ls.c (grub_ls_list_files): Show labels, if possible.
15402 (grub_ls_list_disks): Check if FS and FS->LABEL are not NULL
15403 before calling FS->LABEL.
15404
15405 2005-07-26 Yoshinori K. Okuji <okuji@enbug.org>
15406
15407 * util/i386/pc/grub-install.in (datadir): New variable.
15408 (libdir): Removed.
15409 (pkgdatadir): New variable.
15410 (pkglibdir): Removed.
15411
15412 2005-07-24 Yoshinori K. Okuji <okuji@enbug.org>
15413
15414 * DISTLIST: Added util/i386/pc/grub-install.in.
15415
15416 * util/i386/pc/grub-install.in: New file.
15417
15418 * conf/i386-pc.rmk (sbin_SCRIPTS): New variable.
15419 (grub_install_SOURCES): Likewise.
15420
15421 * genmk.rb: Added support for scripts.
15422 (Script): New class.
15423 (scripts): New variable.
15424
15425 * Makefile.in (install-local): Install sbin_SCRIPTS by
15426 INSTALL_SCRIPT.
15427 (uninstall): Remove sbin_SCRIPTS.
15428
15429 * util/i386/pc/grub-setup.c (main): If the argument is not a GRUB
15430 device, try to get a GRUB device by
15431 grub_util_biosdisk_get_grub_dev.
15432 Free DEST_DEV.
15433
15434 * util/i386/pc/grub-mkdevicemap.c (usage): Remove a duplicated
15435 description for --device-map.
15436
15437 2005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
15438
15439 Change the semantics of variable hooks. They now return strings
15440 instead of error values.
15441
15442 * util/i386/pc/grub-setup.c: Include grub/env.h.
15443 (setup): Use grub_device_set_root instead of grub_env_set.
15444
15445 * kern/rescue.c (grub_rescue_cmd_root): Use grub_env_set and
15446 grub_env_get instead of grub_device_set_root and
15447 grub_device_get_root, respectively.
15448
15449 * kern/main.c (grub_env_write_root): New function.
15450 (grub_set_root_dev): Register grub_env_write_hook for "root". Use
15451 grub_env_set instead of grub_device_set_root.
15452
15453 * kern/env.c (HASHSZ): Reduced to 13, because GRUB does not need
15454 many variables.
15455 (grub_env_set): Set ENV->VALUE to the result of ENV->WRITE_HOOK
15456 rather than calling ENV->WRITE_HOOK afterwards.
15457 (grub_env_get): Return the result of ENV->READ_HOOK rather than
15458 passing a pointer of a pointer.
15459 (grub_register_variable_hook): Change the types of "read_hook" and
15460 "write_hook" to grub_env_read_hook_t and grub_env_write_hook_t,
15461 respectively.
15462 Allocate the default empty string on the heap, because this string
15463 may be freed later.
15464
15465 * kern/device.c: Include grub/env.h.
15466 (grub_device_set_root): Removed.
15467 (grub_device_get_root): Likewise.
15468 (grub_device_open): Use grub_env_get instead of
15469 grub_device_get_root.
15470
15471 * include/grub/env.h (grub_env_read_hook_t): New type.
15472 (grub_env_write_hook_t): Likewise.
15473 (grub_env_var): Change the types of "read_hook" and "write_hook"
15474 to grub_env_read_hook_t and grub_env_write_hook_t, respectively.
15475 (grub_register_variable_hook): Likewise.
15476
15477 * include/grub/device.h (grub_device_set_root): Removed.
15478 (grub_device_set_root): Likewise.
15479
15480 * fs/fat.c (grub_fat_dir): Make a copy of PATH in DIRNAME, and
15481 make sure that DIRNAME terminates with '/', so that
15482 grub_fat_find_dir will fail if PATH is not a directory.
15483
15484 * commands/ls.c (grub_ls_list_files): Remove the qualifier const
15485 from DIRNAME.
15486 Use the qualifier auto for print_files and print_files_long.
15487 If FS->DIR sets GRUB_ERRNO to GRUB_ERR_BAD_FILE_TYPE, try DIRNAME
15488 as a regular file.
15489 Put a newline only if there is no error.
15490 (grub_cmd_ls): Remove grub_ls_print_files, because this is not
15491 used.
15492
15493 2005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
15494
15495 * kern/partition.c (grub_partition_probe): Initialize PART to
15496 NULL. Otherwise, when no partition map is registered, this returns
15497 a garbage.
15498
15499 2005-07-19 Yoshinori K. Okuji <okuji@enbug.org>
15500
15501 * partmap/apple.c (apple_partition_map_iterate): Check if POS
15502 equals GRUB_DISK_SECTOR_SIZE to see if the partition table is
15503 valid.
15504
15505 2005-07-18 Yoshinori K. Okuji <okuji@enbug.org>
15506
15507 * commands/ls.c (grub_ls_list_disks): Print the filesystem
15508 information on each device, if it does not have partitions. Print
15509 "Device" instead of "Disk", because this function is not specific
15510 to disk devices.
15511
15512 * normal/main.c (grub_rescue_cmd_normal): Make the variable CONFIG
15513 static to ensure that it is put on the memory rather than a
15514 register.
15515
15516 2005-07-17 Yoshinori Okuji <okuji@enbug.org>
15517
15518 * commands/cat.c (GRUB_MOD_INIT): Use better documentation.
15519 (grub_cat_init): Likewise.
15520 * loader/i386/pc/chainloader_normal.c (GRUB_MOD_INIT): Likewise.
15521 (options): Likewise.
15522 * commands/configfile.c (GRUB_MOD_INIT): Likewise.
15523 (grub_configfile_init): Likewise.
15524 * font/manager.c (GRUB_MOD_INIT): Likewise.
15525 * commands/help.c (GRUB_MOD_INIT): Likewise.
15526 (grub_help_init): Likewise.
15527 * normal/command.c (grub_command_init): Likewise.
15528 * loader/i386/pc/linux_normal.c (GRUB_MOD_INIT): Likewise.
15529 * disk/loopback.c (grub_loop_init): Likewise.
15530 (GRUB_MOD_INIT): Likewise.
15531 * commands/ls.c (grub_ls_init): Likewise.
15532 (GRUB_MOD_INIT): Likewise.
15533 (options): Likewise.
15534 * commands/boot.c (grub_boot_init): Likewise.
15535 (GRUB_MOD_INIT): Likewise.
15536 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Likewise.
15537 * commands/i386/pc/reboot.c (grub_reboot_init): Likewise.
15538 (GRUB_MOD_INIT): Likewise.
15539 * commands/cmp.c (grub_cmp_init): Likewise.
15540 (GRUB_MOD_INIT): Likewise.
15541
15542 * normal/arg.c: Use <> instead of "" to include header files.
15543 (SHORT_ARG_HELP): New macro.
15544 (SHORT_ARG_USAGE): Likewise.
15545 (help_options): Specify SHORT_ARG_HELP and SHORT_ARG_USAGE instead
15546 of 'h' and 'u' for help and usage, respectively. Use more GNU-like
15547 descriptions.
15548 (find_short): Check if C is 'h' or 'u' explicitly.
15549 (grub_arg_show_help): Use space characters instead of tabs. Treat
15550 SHORT_ARG_HELP and SHORT_ARG_USAGE exceptionally so that -h and -u
15551 are shown with --help and --usage only if they are not used for
15552 the command itself.
15553 (parse_option): Use SHORT_ARG_HELP and SHORT_ARG_USAGE instead of
15554 'h' and 'u'.
15555
15556 * include/grub/arg.h (struct grub_arg_option): Add the qualifier
15557 const into "longarg". Change the type of "shortarg" to int.
15558
15559 2005-07-17 Yoshinori Okuji <okuji@enbug.org>
15560
15561 * boot/i386/pc/boot.S (boot_drive_check): New label.
15562
15563 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRIVE_CHECK): New
15564 macro.
15565
15566 * util/i386/pc/grub-setup.c (setup): Added a workaround for BIOSes
15567 which do not pass a boot drive correctly. Copied from GRUB Legacy.
15568
15569 2005-07-17 Yoshinori Okuji <okuji@enbug.org>
15570
15571 * kern/i386/pc/startup.S (gate_a20_try_system_control_port_a):
15572 When turning off Gate A20, skip the check and return immediately,
15573 because this is not fatal usually.
15574
15575 2005-07-17 Yoshinori Okuji <okuji@enbug.org>
15576
15577 * conf/i386-pc.rmk (pxeboot_img_LDFLAGS): The text address should
15578 be 0x7C00 instead of 0x8000.
15579
15580 * boot/i386/pc/pxeboot.S: Rewritten.
15581
15582 * kern/i386/pc/startup.S (gate_a20_try_bios): No need to specify
15583 EXT_C.
15584 (gate_a20_check_state): Read a byte from 0x108000. Invert the
15585 result.
15586
15587 2005-07-16 Yoshinori K. Okuji <okuji@enbug.org>
15588
15589 * kern/i386/pc/startup.S (grub_gate_a20): Rewritten for
15590 robustness. This routine now supports a BIOS call and System
15591 Control Port A to modify the gate A20.
15592
15593 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
15594 Increased to 0x440.
15595
15596 2005-07-12 Hollis Blanchard <hollis@penguinppc.org>
15597
15598 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): dprintf the
15599 device path and resulting ihandle.
15600 (grub_ofdisk_close): dprintf the ihandle being closed.
15601 (grub_ofdisk_read): dprintf function parameters.
15602 * kern/mm.c (grub_mm_init_region): Likewise.
15603 * loader/powerpc/ieee1275/linux.c: Remove extra whitespace.
15604 (grub_linux_boot): dprintf the Linux entry point, initrd address and
15605 size, and boot arguments.
15606 (grub_rescue_cmd_linux): dprintf each ELF segment's address and size
15607 before loading into memory.
15608 (grub_rescue_cmd_initrd): dprintf the initrd's address and size
15609 before loading into memory.
15610
15611 2005-07-12 Yoshinori K. Okuji <okuji@enbug.org>
15612
15613 * kern/mm.c: Added much documentation.
15614 (GRUB_MM_ALIGN_LOG2): When GRUB_CPU_SIZEOF_VOID_P is
15615 8, set to 5 instead of 8.
15616
15617 2005-07-10 Yoshinori Okuji <okuji@enbug.org>
15618
15619 * DISTLIST: Added util/i386/pc/grub-mkimage.c.
15620
15621 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-mkdevicemap.
15622 (grub_mkdevicemap_SOURCES): New variable.
15623
15624 * util/i386/pc/grub-mkdevicemap.c: New file. Mostly copied from
15625 lib/device.c of GRUB Legacy.
15626
15627 2005-07-10 Yoshinori Okuji <okuji@enbug.org>
15628
15629 * commands/ls.c (grub_ls_list_files): Check if *PATH is NUL
15630 instead of PATH is NULL.
15631
15632 2005-07-09 Vincent Pelletier <subdino2004@yahoo.fr>
15633
15634 * commands/cmp.c (BUFFER_SIZE): New macro.
15635 (grub_cmd_cmp): Close the right file at the right time. Compare
15636 only data just read. Don't report files of different size as
15637 identical. Dynamically allocate buffers. Move variable
15638 declarations at the beginning of function.
15639
15640 2005-07-09 Yoshinori Okuji <okuji@enbug.org>
15641
15642 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): The return value was
15643 reverse.
15644
15645 2004-07-04 Vincent Pelletier <subdino2004@yahoo.fr>
15646
15647 * normal/cmdline.c (grub_cmdline_get): Don't fallback on ctrl-d
15648 when backspace is pressed at beginning of line.
15649
15650 2005-07-03 Yoshinori Okuji <okuji@enbug.org>
15651
15652 * DISTLIST: Added genfslist.sh.
15653
15654 * normal/main.c (fs_module_list): New variable.
15655 (autoload_fs_module): New function.
15656 (read_fs_list): Likewise.
15657 (grub_normal_execute): Call read_fs_list.
15658
15659 * kern/fs.c (grub_fs_autoload_hook): New variable.
15660 (grub_fs_probe): Added support for auto-loading.
15661
15662 * include/grub/normal.h (struct grub_fs_module_list): New struct.
15663 (grub_fs_module_list_t): New type.
15664
15665 * include/grub/fs.h (grub_fs_autoload_hook_t): New type.
15666 (grub_fs_autoload_hook): New prototype.
15667
15668 * genfslist.sh: New file.
15669
15670 * genmk.rb: Added a rule to generate a filesystem list.
15671
15672 2005-06-30 Marco Gerards <metgerards@student.han.nl>
15673
15674 * configure.ac: Fix the test for cross-compiling.
15675
15676 * genmk.rb (Program): Use `$(CC)' instead of `$(BUILD_CC)'. Don't
15677 define GRUB_UTIL anymore.
15678
15679 * util/powerpc/ieee1275/grub-mkimage.c (load_note): Endian fixes
15680 so this function works on other systems than just big endian.
15681 (load_modules): Likewise.
15682 (add_segments): Likewise.
15683
15684 2005-06-23 Hollis Blanchard <hollis@penguinppc.org>
15685
15686 * kern/misc.c (grub_vsprintf): Add `longfmt'. If format string
15687 contains `l' modifier, get a long from va_arg().
15688
15689 2005-06-23 Yoshinori K. Okuji <okuji@enbug.org>
15690
15691 * kern/mm.c (grub_free): If the next free block which is being
15692 merged is the first free block, set the first block to the block
15693 being freed.
15694 Reported by Vincent Guffens <guffens@inma.ucl.ac.be>.
15695
15696 2005-05-08 Hollis Blanchard <hollis@penguinppc.org>
15697
15698 * boot/powerpc/ieee1275/cmain.c (cmain): Initialize
15699 `grub_ieee1275_chosen'.
15700
15701 2005-05-08 Hollis Blanchard <hollis@penguinppc.org>
15702
15703 * boot/powerpc/ieee1275/cmain.c (module_info): Remove definition.
15704 (grub_ieee1275_chosen): New variable.
15705 (cmain): Initialize and use `grub_ieee1275_chosen' instead of
15706 `chosen'.
15707 * boot/powerpc/ieee1275/crt0.S (init_stack): Remove stack space.
15708 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
15709 Rename first argument to `phandle' for consistency.
15710 (grub_ieee1275_get_property_length): Likewise.
15711 (grub_ieee1275_next_property): Likewise. Change type of first argument
15712 to grub_ieee1275_phandle_t.
15713 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_entry_fn):
15714 Move export next to declaration.
15715 (grub_ieee1275_chosen): New variable.
15716 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MODULE_BASE):
15717 Correct cosmetic typo.
15718 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Use
15719 `grub_ieee1275_chosen'.
15720 * kern/powerpc/ieee1275/openfw.c (grub_map): Likewise.
15721 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Likewise.
15722 (grub_rescue_cmd_linux): Set `initrd_addr' to 0.
15723 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_refresh): Use
15724 `grub_ieee1275_chosen'.
15725
15726 2005-05-10 Hollis Blanchard <hollis@penguinppc.org>
15727
15728 * boot/powerpc/ieee1275/cmain.c (cmain): Remove code to parse
15729 /chosen/bootargs.
15730 * kern/powerpc/ieee1275/init.c (grub_machine_init): Parse
15731 /chosen/bootargs as "variable=value" pairs.
15732
15733 2005-05-08 Vincent Pelletier <subdino2004@yahoo.fr>
15734
15735 * include/grub/misc.h (grub_dprintf): New macro.
15736 (grub_real_dprintf): New prototype.
15737 (grub_strword): Likewise.
15738 (grub_iswordseparator): Likewise.
15739 * kern/misc.c (grub_real_dprintf): New function.
15740 (grub_strword): Likewise.
15741 (grub_iswordseparator): Likewise.
15742
15743 2005-04-30 Hollis Blanchard <hollis@penguinppc.org>
15744
15745 * boot/powerpc/ieee1275/cmain.c: Don't include grub/machine/init.h.
15746 (roundup): Remove macro.
15747 (grub_ieee1275_flags): Make static.
15748 (grub_ieee1275_realmode): Remove.
15749 (grub_ieee1275_test_flag): New function.
15750 (grub_ieee1275_set_flag): Likewise.
15751 (find_options): Rename to `grub_ieee1275_find_options'; update
15752 callers. Set GRUB_IEEE1275_FLAG_REAL_MODE and
15753 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS.
15754 (cmain): New prototype.
15755 (cmain): Use `grub_ieee1275_set_flag' instead of accessing
15756 `grub_ieee1275_flags' directly.
15757 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Remove
15758 machine/biosdisk.h.
15759 * disk/powerpc/ieee1275/ofdisk.c: Include grub/machine/ofdisk.h.
15760 Don't include grub/machine/init.h.
15761 (grub_ofdisk_open): Call `grub_ieee1275_test_flag'.
15762 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
15763 Remove prototype.
15764 (grub_ieee1275_realmode): Likewise.
15765 (grub_ieee1275_flag): New enum.
15766 (grub_ieee1275_test_flag): New prototype.
15767 (grub_ieee1275_set_flag): New prototype.
15768 * include/grub/powerpc/ieee1275/init.h: Remove file.
15769 * include/grub/powerpc/ieee1275/ofdisk.h: New file.
15770 * kern/powerpc/ieee1275/init.c: Don't include grub/machine/init.h.
15771 Include grub/machine/console.h. Include grub/machine/ofdisk.h.
15772 (grub_machine_fini): Don't call `grub_ieee1275_release'. Remove
15773 comment.
15774 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Call
15775 `grub_ieee1275_test_flag'.
15776 (grub_ieee1275_encode_devname): Likewise.
15777
15778 2005-04-21 Hollis Blanchard <hollis@penguinppc.org>
15779
15780 * include/grub/powerpc/ieee1275/ieee1275.h
15781 (grub_ieee1275_encode_devname): New prototype.
15782 (grub_ieee1275_get_filename): Likewise.
15783 * kern/powerpc/ieee1275/init.c (grub_translate_ieee175_path): New
15784 function.
15785 (grub_set_prefix): Likewise.
15786 (grub_machine_init): Call grub_set_prefix.
15787 * kern/powerpc/ieee1275/openfw.c: Fix typos.
15788 (grub_parse_type): New enum.
15789 (grub_ieee1275_get_devargs): New function.
15790 (grub_ieee1275_get_devname): Likewise.
15791 (grub_ieee1275_parse_args): Likewise.
15792 (grub_ieee1275_get_filename): Likewise.
15793 (grub_ieee1275_encode_devname): Likewise.
15794
15795 2005-03-30 Marco Gerards <metgerards@student.han.nl>
15796
15797 * kern/powerpc/ieee1275/init.c (grub_machine_fini): Don't call
15798 `grub_loader_unset'.
15799
15800 2005-03-26 Hollis Blanchard <hollis@penguinppc.org>
15801
15802 * commands/ieee1275/halt.c (grub_cmd_halt): Call grub_halt
15803 instead of grub_ieee1275_interpret.
15804 (grub_halt_init): New function.
15805 (grub_halt_fini): Likewise.
15806 (GRUB_MOD_INIT): Correct message grammar.
15807 * commands/ieee1275/reboot.c (grub_cmd_reboot): Call grub_reboot
15808 instead of grub_ieee1275_interpret.
15809 (grub_reboot_init): New function.
15810 (grub_reboot_fini): Likewise.
15811 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace
15812 commands/i386/pc/halt.c, commands/i386/pc/reboot.c, and
15813 util/i386/pc/misc.c with commands/ieee1275/halt.c,
15814 commands/ieee1275/reboot.c, and util/powerpc/ieee1275/misc.c.
15815 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_fini): New
15816 function.
15817 * include/grub/powerpc/ieee1275/console.h (grub_console_fini):
15818 Add prototype.
15819 * include/grub/powerpc/ieee1275/ieee1275.h (grub_reboot): Add
15820 prototype.
15821 (grub_halt): Likewise.
15822 * include/grub/powerpc/ieee1275/init.h: Remove inaccurate comment.
15823 (cmain): Remove __attribute__((unused)).
15824 * kern/powerpc/ieee1275/init.c (grub_heap_start): New variable.
15825 (grub_heap_len): Likewise.
15826 (grub_machine_fini): New function.
15827 * kern/powerpc/ieee1275/openfw.c (grub_reboot): New function.
15828 (grub_halt): Likewise.
15829 * term/powerpc/ieee1275/ofconsole.c (grub_console_fini): New
15830 function.
15831 * util/powerpc/ieee1275/misc.c: New file.
15832
15833 2005-03-19 Yoshinori K. Okuji <okuji@enbug.org>
15834
15835 * DISTLIST: New file.
15836 * gendistlist.sh: Likewise.
15837
15838 * Makefile.in (COMMON_DISTFILES): Removed.
15839 (BOOT_DISTFILES): Likewise.
15840 (CONF_DISTFILES): Likewise.
15841 (DISK_DISTFILES): Likewise.
15842 (FS_DISTFILES): Likewise.
15843 (INCLUDE_DISTFILES): Likewise.
15844 (KERN_DISTFILES): Likewise.
15845 (LOADER_DISTFILES): Likewise.
15846 (TERM_DISTFILES): Likewise.
15847 (UTIL_DISTFILES): Likewise.
15848 (DISTFILES): Likewise.
15849 (uninstall): Uninstall files in $(pkgdata_DATA).
15850 (DISTLIST): New target.
15851 (distdir): Use the contents of the file DISTLIST to get a list of
15852 distributed files.
15853
15854 2005-03-18 Yoshinori K. Okuji <okuji@enbug.org>
15855
15856 * fs/fat.c (grub_fat_mount): Ignore the 3rd bit of a media
15857 descriptor. This is ported from GRUB Legacy.
15858
15859 * gencmdlist.sh: Added an extra semicolon to make it work with
15860 old sed versions. Reported by Robert Bihlmeyer
15861 <robbe@orcus.priv.at>.
15862
15863 2005-03-08 Yoshinori Okuji <okuji@enbug.org>
15864
15865 Automatic loading of commands is supported.
15866
15867 * normal/main.c (read_command_list): New function.
15868 (grub_normal_execute): Call read_command_list.
15869
15870 * normal/command.c (grub_register_command): Return zero or CMD.
15871 Allocate CMD->NAME from the heap.
15872 Initialize CMD->MODULE_NAME to zero.
15873 Find the same name as well. If the same command is found and it is
15874 a dummy command, overwrite members. If it is not a dummy command,
15875 return zero.
15876 (grub_unregister_command): Free Q->NAME and Q->MODULE_NAME.
15877 (grub_command_find): If a dummy command is found, load a module
15878 and retry to find a command only once.
15879
15880 * normal/cmdline.c (grub_tab_complete): Call grub_command_find to
15881 make sure that each command is loaded.
15882
15883 * include/grub/normal.h (GRUB_COMMAND_FLAG_NOT_LOADED): New
15884 macro.
15885 (struct grub_command): Remove const from the member `name'.
15886 Add a new member `module_name'.
15887 (grub_register_command): Return grub_command_t.
15888
15889 * commands/help.c (grub_cmd_help): Call grub_command_find to make
15890 sure that each command is loaded.
15891
15892 * genmk.rb (PModule::rule): Specify a module name without the
15893 suffix ".mod" to gencmdlist.sh.
15894
15895 2005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
15896
15897 * gencmdlist.sh: New file.
15898
15899 * genmk.rb (PModule::rule): Generate a rule for a command list.
15900 Clean command.lst.
15901 Generate command.lst from $(COMMANDFILES).
15902
15903 * Makefile.in (COMMON_DISTFILES): Added gencmdlist.sh.
15904 (DATA): Added $(pkgdata_DATA).
15905 (install-local): Install files in $(pkgdata_DATA).
15906
15907 2005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
15908
15909 * term/i386/pc/vga.c (debug_command): Removed.
15910 (GRUB_MOD_INIT): Do not register the command "debug".
15911
15912 From Hollis Blanchard:
15913 * commands/configfile.c: New file.
15914 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
15915 commands/configfile.c.
15916 (pkgdata_MODULES): Added configfile.mod.
15917 (configfile_mod_SOURCES): New variable.
15918 (configfile_mod_CFLAGS): Likewise.
15919 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
15920 commands/configfile.c.
15921 (pkgdata_MODULES): Added configfile.mod.
15922 (configfile_mod_SOURCES): New variable.
15923 (configfile_mod_CFLAGS): Likewise.
15924 * util/grub-emu.c (main): Call grub_configfile_init and
15925 grub_configfile_fini.
15926 * include/grub/normal.h [GRUB_UTIL] (grub_configfile_init): New
15927 prototype.
15928 [GRUB_UTIL] (grub_configfile_fini): Likewise.
15929
15930 2005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
15931
15932 * normal/arg.c (grub_arg_show_help): Do not show the bug report
15933 address.
15934
15935 * commands/help.c (grub_cmd_help): Do not print newlines after
15936 the last command in print_command_help.
15937
15938 2005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
15939
15940 * commands/default.h: New file.
15941 * commands/timeout.h: Likewise.
15942 * normal/context.c: Likewise.
15943
15944 * util/misc.c: Do not include sys/times.h.
15945 Include sys/time.h and grub/machine/time.h.
15946 (grub_get_rtc): Rewritten with gettimeofday.
15947
15948 * util/grub-emu.c (main): Call grub_default_init and
15949 grub_timeout_init before grub_normal_init, and call
15950 grub_timeout_fini and grub_default_fini after grub_main.
15951
15952 * util/console.c (grub_ncurses_checkkey): Return the read
15953 character or -1.
15954
15955 * normal/menu.c (run_menu): Set MENU->TIMEOUT to -1 once it
15956 timeouts.
15957
15958 * normal/main.c (read_config_file): Push MENU. If this fails,
15959 print an error and wait for a user input.
15960 Print an error only if GRUB_ERRNO is not GRUB_ERR_NONE.
15961 If a menu is empty or an error occurs, pop MENU.
15962 (grub_normal_execute): Pop and free MENU after grub_menu_run
15963 returns.
15964
15965 * kern/loader.c (grub_loader_boot): Call grub_machine_fini.
15966
15967 * include/grub/powerpc/ieee1275/time.h [GRUB_UTIL]: Do not
15968 include time.h.
15969 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
15970 without GRUB_UTIL.
15971 * include/grub/i386/pc/time.h [GRUB_UTIL]: Do not include
15972 time.h.
15973 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
15974 without GRUB_UTIL.
15975
15976 * include/grub/normal.h (struct grub_menu_list): New struct.
15977 (grub_menu_list_t): New type.
15978 (struct grub_context): New struct.
15979 (grub_context_t): New type.
15980 (grub_register_command): Got rid of EXPORT_FUNC.
15981 (grub_unregister_command): Likewise.
15982 (grub_context_get): New prototype.
15983 (grub_context_get_current_menu): Likewise.
15984 (grub_context_push_menu): Likewise.
15985 (grub_context_pop_menu): Likewise.
15986 [GRUB_UTIL] (grub_default_init): Likewise.
15987 [GRUB_UTIL] (grub_default_fini): Likewise.
15988 [GRUB_UTIL] (grub_timeout_init): Likewise.
15989 [GRUB_UTIL] (grub_timeout_fini): Likewise.
15990
15991 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/default.c,
15992 commands/timeout.c and normal/context.c.
15993 (pkgdata_MODULES): Added default.mod and timeout.mod.
15994 (normal_mod_SOURCES): Added normal/context.c.
15995 (default_mod_SOURCES): New variable.
15996 (default_mod_CFLAGS): Likewise.
15997 (timeout_mod_SOURCES): Likewise.
15998 (timeout_mod_CFLAGS): Likewise.
15999 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Copied from
16000 conf/i386-pc.rmk.
16001 (pkgdata_MODULES): Added default.mod and timeout.mod.
16002 (normal_mod_SOURCES): Added normal/context.c.
16003 (default_mod_SOURCES): New variable.
16004 (default_mod_CFLAGS): Likewise.
16005 (timeout_mod_SOURCES): Likewise.
16006 (timeout_mod_CFLAGS): Likewise.
16007
16008 * Makefile.in (all-local): Added $(MKFILES).
16009
16010 2005-02-21 Vincent Pelletier <subdino2004@yahoo.fr>
16011
16012 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `partmap/sun.c'.
16013 (grub_emu_SOURCES): Likewise.
16014 (pkgdata_MODULES): Add `sun.mod'.
16015 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
16016 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
16017 `partmap/sun.c'.
16018 (pkgdata_MODULES): Add `sun.mod'.
16019 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
16020 * include/grub/partition.h (grub_sun_partition_map_init): New
16021 prototype.
16022 (grub_sun_partition_map_fini): Likewise.
16023 * partmap/sun.c: New file.
16024 * util/grub-emu.c (main): Initialize and de-initialize the sun
16025 partitionmap support.
16026
16027 2005-02-19 Yoshinori K. Okuji <okuji@enbug.org>
16028
16029 This implements an Emacs-like menu entry editor.
16030
16031 * normal/menu_entry.c: New file.
16032
16033 * util/console.c (grub_ncurses_putchar): Translate some Unicode
16034 characters to ASCII.
16035 (saved_char): New variable.
16036 (grub_ncurses_checkkey): Rewritten completely.
16037 (grub_ncurses_getkey): Likewise.
16038 (grub_ncurses_init): Call raw instead of cbreak.
16039
16040 * normal/menu.c (print_entry): Do not put a space.
16041 (init_page): Renamed to ...
16042 (grub_menu_init_page): ... this. All callers changed.
16043 (edit_menu_entry): Removed.
16044 (run_menu): Call grub_menu_entry_run instead of edit_menu_entry.
16045
16046 * normal/cmdline.c (grub_cmdline_run): Call grub_setcursor.
16047
16048 * kern/misc.c (grub_vprintf): Call grub_refresh.
16049
16050 * normal/menu.c (DISP_LEFT): Renamed to ...
16051 * include/grub/term.h (GRUB_TERM_DISP_LEFT): ... this.
16052 * normal/menu.c (DISP_UP): Renamed to ...
16053 * include/grub/term.h (GRUB_TERM_DISP_UP): ... this.
16054 * normal/menu.c (DISP_RIGHT): Renamed to ...
16055 * include/grub/term.h (GRUB_TERM_DISP_RIGHT): ... this.
16056 * normal/menu.c (DISP_DOWN): Renamed to ...
16057 * include/grub/term.h (GRUB_TERM_DISP_DOWN): ... this.
16058 * normal/menu.c (DISP_HLINE): Renamed to ...
16059 * include/grub/term.h (GRUB_TERM_DISP_HLINE): ... this.
16060 * normal/menu.c (DISP_VLINE): Renamed to ...
16061 * include/grub/term.h (GRUB_TERM_DISP_VLINE): ... this.
16062 * normal/menu.c (DISP_UL): Renamed to ...
16063 * include/grub/term.h (GRUB_TERM_DISP_UL): ... this.
16064 * normal/menu.c (DISP_UR): Renamed to ...
16065 * include/grub/term.h (GRUB_TERM_DISP_UR): ... this.
16066 * normal/menu.c (DISP_LL): Renamed to ...
16067 * include/grub/term.h (GRUB_TERM_DISP_LL): ... this.
16068 * normal/menu.c (DISP_LR): Renamed to ...
16069 * include/grub/term.h (GRUB_TERM_DISP_LR): ... this.
16070 * normal/menu.c (TERM_WIDTH): Renamed to ...
16071 * include/grub/term.h (GRUB_TERM_WIDTH): ... this.
16072 * normal/menu.c (TERM_HEIGHT): Renamed to ...
16073 * include/grub/term.h (GRUB_TERM_HEIGHT): ... this.
16074 * normal/menu.c (TERM_INFO_HEIGHT): Renamed to ...
16075 * include/grub/term.h (GRUB_TERM_INFO_HEIGHT): ... this.
16076 * normal/menu.c (TERM_MARGIN): Renamed to ...
16077 * include/grub/term.h (GRUB_TERM_MARGIN): ... this.
16078 * normal/menu.c (TERM_SCROLL_WIDTH): Renamed to ...
16079 * include/grub/term.h (GRUB_TERM_SCROLL_WIDTH): ... this.
16080 * normal/menu.c (TERM_TOP_BORDER_Y): Renamed to ...
16081 * include/grub/term.h (GRUB_TERM_TOP_BORDER_Y): ... this.
16082 * normal/menu.c (TERM_LEFT_BORDER_X): Renamed to ...
16083 * include/grub/term.h (GRUB_TERM_LEFT_BORDER_X): ... this.
16084 * normal/menu.c (TERM_BORDER_WIDTH): Renamed to ...
16085 * include/grub/term.h (GRUB_TERM_BORDER_WIDTH): ... this.
16086 * normal/menu.c (TERM_MESSAGE_HEIGHT): Renamed to ...
16087 * include/grub/term.h (GRUB_TERM_MESSAGE_HEIGHT): ... this.
16088 * normal/menu.c (TERM_BORDER_HEIGHT): Renamed to ...
16089 * include/grub/term.h (GRUB_TERM_BORDER_HEIGHT): ... this.
16090 * normal/menu.c (TERM_NUM_ENTRIES): Renamed to ...
16091 * include/grub/term.h (GRUB_TERM_NUM_ENTRIES): ... this.
16092 * normal/menu.c (TERM_FIRST_ENTRY_Y): Renamed to ...
16093 * include/grub/term.h (GRUB_TERM_FIRST_ENTRY_Y): ... this.
16094 * normal/menu.c (TERM_ENTRY_WIDTH): Renamed to ...
16095 * include/grub/term.h (GRUB_TERM_ENTRY_WIDTH): ... this.
16096 * normal/menu.c (TERM_CURSOR_X): Renamed to ...
16097 * include/grub/term.h (GRUB_TERM_CURSOR_X): ... this.
16098 All callers changed.
16099
16100 * include/grub/normal.h: New prototype.
16101
16102 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
16103 normal/menu_entry.c.
16104 (normal_mod_SOURCES): Likewise.
16105 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
16106 (normal_mod_SOURCES): Likewise.
16107
16108 2005-02-15 Yoshinori K. Okuji <okuji@enbug.org>
16109
16110 * include/grub/normal.h (grub_halt_init): New prototype.
16111 (grub_halt_fini): Likewise.
16112 (grub_reboot_init): Likewise.
16113 (grub_reboot_fini): Likewise.
16114
16115 * util/grub-emu.c: Include signal.h.
16116 (main_env): New global variable.
16117 (grub_machine_init): Ignore SIGINT. Otherwise grub-emu cannot
16118 catch C-c.
16119 (grub_machine_fini): New function.
16120 (main): Call grub_halt_init and grub_reboot_init before
16121 grub_main, and grub_reboot_fini and grub_halt_fini after it.
16122 Call setjmp with MAIN_ENV to go back afterwards.
16123 Call grub_machine_fini right before return.
16124
16125 * include/grub/util/misc.h: Include setjmp.h.
16126 (main_env): New prototype.
16127
16128 * include/grub/kernel.h (grub_machine_fini): New prototype.
16129 * include/grub/i386/pc/biosdisk.h (grub_biosdisk_fini): Likewise.
16130 * include/grub/i386/pc/console.h (grub_console_fini): Likewise.
16131
16132 * disk/i386/pc/biosdisk.c (grub_biosdisk_fini): New function.
16133 * kern/i386/pc/init.c (grub_machine_fini): Likewise.
16134 * term/i386/pc/console.c (grub_console_fini): Likewise.
16135
16136 * util/i386/pc/misc.c: New file.
16137
16138 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
16139 util/i386/pc/misc.c, commands/i386/pc/halt.c and
16140 commands/i386/pc/reboot.c.
16141
16142 2005-02-14 Guillem Jover <guillem@hadrons.org>
16143
16144 * include/grub/dl.h (grub_dl_check_header): New prototype.
16145 (grub_arch_dl_check_header): Change return type to grub_err_t,
16146 remove size parameter and export function. Update all callers.
16147 * kern/dl.c (grub_dl_check_header): New function.
16148 (grub_dl_load_core): Use `grub_dl_check_header' instead of
16149 `grub_arch_dl_check_header'. Check ELF type. Check if sections
16150 are inside the core.
16151 * kern/i386/dl.c (grub_arch_dl_check_header): Remove arch
16152 independent ELF header checks.
16153 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
16154 * loader/i386/pc/multiboot.c (grub_rescue_cmd_multiboot): Use
16155 `grub_dl_check_header' instead of explicit checks. Check for the
16156 ELF type.
16157 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Use
16158 `grub_dl_check_header' instead of explicit checks. Remove arch
16159 specific ELF header checks.
16160
16161 * util/grub-emu.c (grub_arch_dl_check_header): Remove the
16162 argument SIZE.
16163
16164 2005-02-13 Hollis Blanchard <hollis@penguinppc.org>
16165
16166 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add ls.mod.
16167 * include/grub/powerpc/libgcc.h (__mulsf3): New prototype.
16168
16169 2005-02-12 Hollis Blanchard <hollis@penguinppc.org>
16170
16171 * kern/partition.c (grub_partition_probe): Clear `grub_errno' and
16172 return 0 if `grub_errno' is GRUB_ERR_BAD_PART_TABLE.
16173 (part_map_iterate): Clear `grub_errno' and return 0 if
16174 `partmap->iterate' returns GRUB_ERR_BAD_PART_TABLE.
16175 * partmap/amiga.c (amiga_partition_map_iterate): Return
16176 GRUB_ERR_BAD_PART_TABLE if no partition map magic is found.
16177 * partmap/apple.c (apple_partition_map_iterate): Likewise.
16178
16179 2005-02-01 Guillem Jover <guillem@hadrons.org>
16180
16181 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Fix module
16182 help info.
16183
16184 2005-01-31 Marco Gerards <metgerards@student.han.nl>
16185
16186 * include/grub/powerpc/ieee1275/loader.h (grub_load_linux):
16187 Removed prototype.
16188 (grub_rescue_cmd_linux): New prototype.
16189 (grub_rescue_cmd_initrd): Likewise.
16190 * powerpc/ieee1275/linux.c (grub_linux_boot): Remove struct
16191 `bi_rec'.
16192 (grub_linux_release_mem): Release the memory for the initrd.
16193 (grub_load_linux): Renamed from this...
16194 (grub_rescue_cmd_linux): ...To this. Changed all callers.
16195 Changed `entry' not to be static. Loop over memory regions to
16196 find another one when the default fails.
16197 (grub_rescue_cmd_initrd): New function.
16198 (grub_linux_init): Remove function.
16199 (grub_linux_fini): Likewise.
16200 (GRUB_MOD_INIT): Register `initrd'.
16201 (GRUB_MOD_FINI): Unregister `initrd'.
16202 * powerpc/ieee1275/linux_normal.c (grub_linux_normal_init):
16203 Function removed.
16204 (grub_linux_normal_fini): Likewise.
16205 (GRUB_MOD_INIT): Register `initrd'.
16206 (GRUB_MOD_FINI): Unregister `initrd'.
16207
16208 2005-01-31 Marco Gerards <metgerards@student.han.nl>
16209
16210 * commands/help.c: New file.
16211 * normal/arg.c (show_help): Renamed to...
16212 (grub_arg_show_help): ... this.
16213 * commands/i386/pc/halt.c: New file.
16214 * commands/i386/pc/reboot.c: Likewise.
16215 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/help.c'.
16216 (pkgdata_MODULES): Add `reboot.mod', `halt.mod' and `help.mod'.
16217 (help_mod_SOURCES, help_mod_CFLAGS, reboot_mod_SOURCES)
16218 (reboot_mod_CFLAGS, halt_mod_SOURCES, halt_mod_CFLAGS): New
16219 variables.
16220 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
16221 `commands/help.c'.
16222 (pkgdata_MODULES): Add `help.mod'.
16223 (help_mod_SOURCES, help_mod_CFLAGS): New variables.
16224 * grub/i386/pc/init.h (grub_reboot): New prototype.
16225 (grub_halt): Likewise.
16226 * include/grub/normal.h (grub_arg_show_help): New prototype.
16227 (grub_help_init): Likewise.
16228 (grub_help_fini): Likewise.
16229 * util/grub-emu.c (main): Initialize and deinitialize the help
16230 command.
16231
16232 * normal/cmdline.c (grub_cmdline_get): Doc fix.
16233
16234 * normal/command.c (grub_command_init): Fixed the description of
16235 the `set' and `unset' commands.
16236
16237 2005-01-31 Marco Gerards <metgerards@student.han.nl>
16238
16239 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_interpret): New
16240 function.
16241 * commands/ieee1275/halt.c: New file.
16242 * commands/ieee1275/reboot.c: Likewise.
16243 * commands/ieee1275/suspend.c (grub_cmd_suspend): Use
16244 `__attribute__ ((unused))'. Some GCS related fixed.
16245 (grub_suspend_init) [GRUB_UTIL]: Function removed.
16246 (grub_suspend_fini): Likewise.
16247 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add `reboot.mod'
16248 and `halt.mod'.
16249 (reboot_mod_SOURCES, reboot_mod_CFLAGS, halt_mod_SOURCES)
16250 (halt_mod_CFLAGS): New variables.
16251 * include/grub/powerpc/ieee1275/ieee1275.h
16252 (grub_ieee1275_interpret): New prototype.
16253
16254 2005-01-29 Yoshinori K. Okuji <okuji@enbug.org>
16255
16256 * include/grub/misc.h (memmove): New prototype.
16257 (memcpy): Likewise.
16258
16259 2005-01-22 Hollis Blanchard <hollis@penguinppc.org>
16260
16261 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Don't initialize
16262 `devpath' to 0. Use `name' instead of `devpath' with `grub_strndup'.
16263
16264 2005-01-22 Marco Gerards <metgerards@student.han.nl>
16265
16266 * kern/misc.c (grub_strndup): Function rewritten.
16267
16268 2005-01-22 Vincent Pelletier <subdino2004@yahoo.fr>
16269
16270 * normal/menu.c (TERM_WIDTH): Macro redefined.
16271 (TERM_TOP_BORDER_Y): Likewise.
16272 (draw_border): Replaced while-loop by a for-loop. Make the number
16273 of lines consistent with the number of lines displayed in
16274 print_entries. Added a margin below the rectangle.
16275 (print_entry): Make the entry fit in the rectangle.
16276 (print_entries): Display the scroll arrows next to the right
16277 border.
16278
16279 2005-01-21 Marco Gerards <metgerards@student.han.nl>
16280
16281 * fs/minix.c (grub_minix_find_file): Reserve more space for
16282 `fpath' so the \0 can be stored. Use `grub_strcpy' instead of
16283 `grub_strncpy' to copy `path' into it.
16284
16285 2005-01-21 Marco Gerards <metgerards@student.han.nl>
16286
16287 Add the loopback device, a device via which files can be accessed
16288 as devices.
16289
16290 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/loopback.c'.
16291 (pkgdata_MODULES): Add loopback.mod.
16292 (loopback_mod_SOURCES): New variable.
16293 (loopback_mod_CFLAGS): Likewise.
16294 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
16295 `disk/loopback.c'.
16296 (pkgdata_MODULES): Add loopback.mod.
16297 (loopback_mod_SOURCES): New variable.
16298 (loopback_mod_CFLAGS): Likewise.
16299 * disk/loopback.c: new file.
16300 * include/grub/normal.h (grub_loop_init): New prototype.
16301 (grub_loop_fini): New prototype.
16302 * util/grub-emu.c (main): Initialize and de-initialize loopback
16303 support.
16304 * include/grub/disk.h (grub_disk_dev_id): Add
16305 `GRUB_DISK_DEVICE_LOOPBACK_ID'.
16306
16307 2005-01-20 Hollis Blanchard <hollis@penguinppc.org>
16308
16309 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_enter): New
16310 function.
16311 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add suspend.mod.
16312 (suspend_mod_SOURCES): New variable.
16313 (suspend_mod_CFLAGS): Likewise.
16314 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_enter):
16315 New prototype.
16316 * commands/ieee1275/suspend.c: New file.
16317
16318 2005-01-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
16319
16320 * include/grub/dl.h (GRUB_MOD_INIT): Changed `__attribute__
16321 ((unused))' to `__attribute__ ((used))'.
16322 (GRUB_MOD_FINI): Likewise.
16323 * kern/dl.c (grub_dl_load_file): Fix null pointer dereference.
16324 * genmk.rb (PModule): Assign space to common symbols when linking
16325 modules.
16326
16327 2005-01-20 Marco Gerards <metgerards@student.han.nl>
16328
16329 * include/grub/mm.h (grub_mm_init_region): Change the type of the
16330 `unsigned' arguments to `grub_size_t'.
16331 (grub_malloc): Likewise.
16332 (grub_realloc): Likewise.
16333 (grub_memalign): Likewise.
16334 * kern/i386/dl.c (grub_arch_dl_check_header): Likewise.
16335 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
16336 * util/misc.c (grub_malloc): Likewise.
16337 (grub_realloc): Likewise.
16338 * kern/mm.c (get_header_from_pointer): Change the casts to
16339 `unsigned' into a cast to `grub_size_t'.
16340
16341 * fs/fshelp.c (grub_fshelp_find_file): The `oldnode' should always
16342 point to `currnode' when `currnode' is changed.
16343
16344 * util/grub-emu.c (main): Initialize `progname'. Reported by Nico
16345 Schottelius <nico-linux@schottelius.org>.
16346
16347 2005-01-09 Hollis Blanchard <hollis@penguinppc.org>
16348
16349 * util/powerpc/ieee1275/grub-mkimage.c: Include <string.h>.
16350 (note_path): Remove variable.
16351 (GRUB_IEEE1275_NOTE_NAME): New macro.
16352 (GRUB_IEEE1275_NOTE_TYPE): Likewise.
16353 (grub_ieee1275_note_hdr): New structure.
16354 (grub_ieee1275_note_desc): Likewise.
16355 (grub_ieee1275_note): Likewise.
16356 (load_note): Remove `dir' argument. All callers updated. Remove
16357 `note_img' and `path'. Do not load a file from `note_path'.
16358 Initialize a struct grub_ieee1275_note and write that to `out'.
16359 Use GRUB_IEEE1275_MODULE_BASE instead of MODULE_BASE.
16360
16361 2005-01-05 Marco Gerards <metgerards@student.han.nl>
16362
16363 * util/misc.c (grub_util_read_image): Revert last change. It
16364 called `grub_util_read_at', which seeks from the beginning of the
16365 file.
16366
16367 2005-01-04 Hollis Blanchard <hollis@penguinppc.org>
16368
16369 * TODO: Add note about endianness in grub-mkimage.
16370 * boot/powerpc/ieee1275/crt0.S (note): Remove unused .note
16371 section.
16372 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Add grub-mkimage.
16373 (grub_mkimage_SOURCES): New target.
16374 * include/grub/kernel.h (grub_start_addr): Remove variable.
16375 (grub_end_addr): Likewise.
16376 (grub_total_module_size): Likewise.
16377 (grub_kernel_image_size): Likewise.
16378 (GRUB_MODULE_MAGIC): New constant.
16379 (grub_module_info): New structure.
16380 (grub_arch_modules_addr): New prototype.
16381 (grub_get_end_addr): Remove prototype.
16382 * include/grub/i386/pc/kernel.h (grub_end_addr): New prototype.
16383 * include/grub/powerpc/ieee1275/kernel.h: New file.
16384 * include/grub/util/misc.h (grub_util_get_fp_size): New
16385 prototype.
16386 (grub_util_read_at): Likewise.
16387 (grub_util_write_image_at): Likewise.
16388 * kern/main.c (grub_get_end_addr): Remove function.
16389 (grub_load_modules): Call grub_arch_modules_addr instead of using
16390 grub_end_addr. Look for a grub_module_info struct in memory. Use
16391 the grub_module_info fields instead of calling grub_get_end_addr
16392 as loop conditions. Move grub_add_unused_region code here.
16393 (grub_add_unused_region): Remove function.
16394 * kern/i386/pc/init.c: Include grub/cache.h.
16395 (grub_machine_init): Remove call to grub_get_end_addr. Remove
16396 one call to add_mem_region.
16397 (grub_arch_modules_addr): New function.
16398 * kern/powerpc/ieee1275/init.c (grub_end_addr): Remove variable.
16399 (grub_total_module_size): Likewise.
16400 Include grub/machine/kernel.h.
16401 (grub_arch_modules_addr): New function.
16402 * util/grub-emu.c (grub_end_addr): Remove variable.
16403 (grub_total_module_size): Likewise.
16404 (grub_arch_modules_addr): New function.
16405 * util/misc.c: Include unistd.h.
16406 (grub_util_get_fp_size): New function.
16407 (grub_util_read_at): Likewise.
16408 (grub_util_write_image_at): Likewise.
16409 (grub_util_read_image): Call grub_util_read_at.
16410 (grub_util_write_image): Call grub_util_write_image_at.
16411 * util/i386/pc/grub-mkimage.c (generate_image): Allocate
16412 additional memory in kernel_img for a struct grub_module_info.
16413 Fill in that grub_module_info.
16414 * util/powerpc/ieee1275/grub-mkimage.c: New file.
16415
16416 2005-01-03 Hollis Blanchard <hollis@penguinppc.org>
16417
16418 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_milliseconds):
16419 New function.
16420 * include/grub/powerpc/ieee1275/ieee1275.h
16421 (grub_ieee1275_milliseconds): New prototype.
16422 * include/grub/powerpc/ieee1275/time.h (GRUB_TICKS_PER_SECOND):
16423 Change to 1000.
16424 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Call
16425 grub_ieee1275_milliseconds.
16426
16427 2005-01-03 Hollis Blanchard <hollis@penguinppc.org>
16428
16429 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_realmode): New
16430 variable.
16431 (find_options): New function.
16432 (cmain): Call find_options.
16433 * include/grub/powerpc/ieee1275/ieee1275.h
16434 (grub_ieee1275_realmode): New extern variable.
16435 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Only call
16436 grub_map if grub_ieee1275_realmode is false.
16437
16438 2004-12-29 Marco Gerards <metgerards@student.han.nl>
16439
16440 * normal/cmdline.c (grub_cmdline_get): Redone logic so no empty
16441 lines are inserted and make it work like readline. Reported by
16442 Vincent Pelletier <subdino2004@yahoo.fr>.
16443
16444 2004-12-28 Marco Gerards <metgerards@student.han.nl>
16445
16446 * boot/powerpc/ieee1275/crt0.S (_start): Don't set up the stack.
16447
16448 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCE): Remove
16449 `kern/powerpc/cache.S'.
16450
16451 2004-12-27 Marco Gerards <metgerards@student.han.nl>
16452
16453 * genmk.rb: Handle the `Program' class in the main loop. Written
16454 by Johan Rydberg <jrydberg@gnu.org>.
16455 (Program): New class.
16456 (programs): New variable.
16457 * boot/powerpc/ieee1275/cmain.c: Include <grub/machine/ieee1275.h>
16458 instead of "grub/machine/ieee1275.h". Include <grub/kernel.h>
16459 instead of "grub/kernel.h". Include <grub/machine/init.h>.
16460 (help_arch): Function removed.
16461 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add
16462 `powerpc/libgcc.h' and `loader.h'.
16463 (pkgdata_PROGRAMS): New variable.
16464 (sbin_UTILITIES): Variable removed.
16465 (grub_emu_SOURCES): Added kern/powerpc/cache.S.
16466 (grubof_SOURCES): Variable re-defined so it only includes the
16467 core functionality.
16468 (grubof_CFLAGS): Remove `-DGRUBOF'.
16469 (pkgdata_MODULES, fshelp_mod_SOURCES, fshelp_mod_CFLAGS,
16470 (fat_mod_SOURCES, fat_mod_CFLAGS, ext2_mod_SOURCES)
16471 (ext2_mod_CFLAGS, ufs_mod_SOURCES, ufs_mod_CFLAGS)
16472 (minix_mod_SOURCES, minix_mod_CFLAGS, hfs_mod_SOURCES)
16473 (hfs_mod_CFLAGS, jfs_mod_SOURCES, jfs_mod_CFLAGS)
16474 (iso9660_mod_SOURCES, iso9660_mod_CFLAGS, _linux_mod_SOURCES)
16475 (_linux_mod_CFLAGS, linux_mod_SOURCES, linux_mod_CFLAGS)
16476 (normal_mod_SOURCES, normal_mod_CFLAGS, normal_mod_ASFLAGS)
16477 (hello_mod_SOURCES, hello_mod_CFLAGS, boot_mod_SOURCES)
16478 (boot_mod_CFLAGS, terminal_mod_SOURCES, terminal_mod_CFLAGS)
16479 (ls_mod_SOURCES, ls_mod_CFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
16480 (cat_mod_SOURCES, cat_mod_CFLAGS, font_mod_SOURCES)
16481 (font_mod_CFLAGS, amiga_mod_SOURCES, amiga_mod_CFLAGS)
16482 (apple_mod_SOURCES, apple_mod_CFLAGS, pc_mod_SOURCES)
16483 (pc_mod_CFLAGS): New variables.
16484 * disk/powerpc/ieee1275/ofdisk.c: Include <grub/machine/init.h>.
16485 (grub_ofdisk_iterate): Add a prototype for `dev_iterate'.
16486 * include/grub/dl.h (grub_arch_dl_sync_caches): New prototype.
16487 * include/grub/loader.h (grub_os_area_addr, grub_os_area_size):
16488 Moved from here...
16489 * include/grub/i386/pc/init.h (grub_os_area_addr)
16490 (rub_os_area_size): ... to here.
16491 * include/grub/powerpc/ieee1275/ieee1275.h
16492 (grub_ieee1275_entry_fn): Export symbol.
16493 * include/grub/powerpc/ieee1275/init.h: New file.
16494 * include/grub/powerpc/libgcc.h: Likewise.
16495 * include/grub/cache.h: Likewise.
16496 * kern/powerpc/cache.S: Likewise. Written by Hollis Blanchard
16497 <hollis@penguinppc.org>.
16498 * kern/dl.c: Include <grub/cache.h>.
16499 (grub_dl_flush_cache): New function.
16500 (grub_dl_load_core): Call `grub_dl_flush_cache' to flush the cache
16501 for this module.
16502 * kern/powerpc/ieee1275/init.c (grub_ofdisk_init)
16503 (grub_console_init): Removed prototypes.
16504 (grub_machine_init): Don't initialize the modules anymore.
16505 * kern/powerpc/ieee1275/openfw.c (grub_map): Make the function
16506 static.
16507 * include/grub/powerpc/types.h (GRUB_HOST_WORDS_LITTLEENDIAN):
16508 Macro undef removed.
16509 (GRUB_HOST_WORDS_BIGENDIAN): New macro.
16510 * kern/powerpc/dl.c (grub_arch_dl_relocate_symbols): Add
16511 relocation `R_PPC_REL32'. Return an error when the relocation is
16512 unknown.
16513 * Makefile.in (DATA): Add `$(pkgdata_PROGRAMS)'.
16514 * kern/i386/pc/init.c (grub_arch_sync_caches): New function.
16515 * util/misc.c (grub_arch_sync_caches): Likewise.
16516
16517 2004-12-19 Marco Gerards <metgerards@student.han.nl>
16518
16519 * conf/powerpc-ieee1275.rmk (MOSTLYCLEANFILES): Remove
16520 `symlist.c', add `grubof_symlist.c'.
16521 (symlist.c): Variable removed.
16522 (grubof_HEADERS): Variable added.
16523 (grubof_symlist.c): New target.
16524 (kernel_syms.lst): Use `grubof_HEADERS' instead of
16525 `kernel_img_HEADERS'.
16526 (grubof_SOURCES): Add `kern/powerpc/dl.c' and `grubof_symlist.c'.
16527 * kern/powerpc/dl.c: New file.
16528 * kern/powerpc/ieee1275/init.c (grub_arch_dl_check_header):
16529 Function removed.
16530 (grub_arch_dl_relocate_symbols): Likewise.
16531 (grub_register_exported_symbols): Likewise.
16532
16533 2004-12-13 Marco Gerards <metgerards@student.han.nl>
16534
16535 * fs/ext2.c (grub_ext2_open): Don't use data after freeing it.
16536 (grub_ext2_dir): Likewise. Don't return in case of an error, jump
16537 to fail instead. Reported by Vincent Pelletier
16538 <subdino2004@yahoo.fr>.
16539
16540 * fs/fshelp.c (grub_fshelp_find_file): Don't free `oldnode' when
16541 it is not allocated. Reported by Vincent Pelletier
16542 <subdino2004@yahoo.fr>.
16543
16544 * normal/cmdline.c (grub_tab_complete): Add a blank line to the
16545 output so the output looks better.
16546
16547 2004-12-04 Marco Gerards <metgerards@student.han.nl>
16548
16549 Modulize the partition map support and add support for the amiga
16550 partition map.
16551
16552 * commands/ls.c: Include <grub/partition.h> instead of
16553 <grub/machine/partition.h>.
16554 * kern/disk.c: Likewise.
16555 * kern/rescue.c: Likewise.
16556 * loader/i386/pc/chainloader.c: Likewise.
16557 * normal/cmdline.c: Likewise.
16558 * kern/powerpc/ieee1275/init.c: Likewise.
16559 (grub_machine_init): Call `grub_pc_partition_map_init',
16560 `grub_amiga_partition_map_init' and
16561 `grub_apple_partition_map_init'.
16562 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove
16563 `disk/i386/pc/partition.c'. Add `kern/partition.c'.
16564 (kernel_img_HEADERS): Remove `machine/partition.h'. Add
16565 `partition.h' and `pc_partition.h'.
16566 (grub_setup_SOURCES): Remove
16567 `disk/i386/pc/partition.c'. Add `kern/partition.c',
16568 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
16569 (grub_emu_SOURCES): Likewise.
16570 (pkgdata_MODULES): Add `amiga.mod', `apple.mod' and `pc.mod'.
16571 (amiga_mod_SOURCES, amiga_mod_CFLAGS, apple_mod_SOURCES)
16572 (apple_mod_CFLAGS, pc_mod_SOURCES, pc_mod_CFLAGS): New variables.
16573 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
16574 `disk/powerpc/ieee1275/partition.c'. Add `kern/partition.c',
16575 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
16576 (grubof_SOURCES): Likewise.
16577 * disk/i386/pc/partition.c: File removed.
16578 * disk/powerpc/ieee1275/partition.c: Likewise.
16579 * include/grub/powerpc/ieee1275/partition.h: Likewise.
16580 * include/grub/i386/pc/partition.h: Likewise.
16581 * kern/partition.c: New file.
16582 * partmap/amiga.c: Likewise.
16583 * partmap/apple.c: Likewise.
16584 * partmap/pc.c: Likewise.
16585 * include/grub/partition.h: Likewise..
16586 * include/grub/pc_partition.h: Likewise.
16587 * util/grub-emu.c: Include <grub/partition.h> instead of
16588 <grub/machine/partition.h>.
16589 (main): Call `grub_pc_partition_map_init',
16590 `grub_amiga_partition_map_init' and
16591 `grub_apple_partition_map_init' and deinitialize afterwards.
16592 * util/i386/pc/biosdisk.c: Include `#include
16593 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
16594 `<grub/machine/partition.h>'.
16595 * util/i386/pc/grub-setup.c: Likewise.
16596 * util/i386/pc/biosdisk.c: Likewise.
16597 (grub_util_biosdisk_get_grub_dev): Only access the PC specific
16598 partition information in case of a PC partition.
16599 * util/i386/pc/grub-setup.c: Include `#include
16600 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
16601 `<grub/machine/partition.h>'.
16602 (setup): Only access the PC specific partition information in case
16603 of a PC partition.
16604
16605 2004-11-17 Hollis Blanchard <hollis@penguinppc.org>
16606
16607 * kern/powerpc/ieee1275/init.c (grub_setjmp): Remove function.
16608 (grub_longjmp): Likewise.
16609 * include/grub/powerpc/setjmp.h (grub_jmp_buf): Set array size to
16610 20.
16611 * normal/powerpc/setjmp.S: New file.
16612 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
16613 `normal/powerpc/setjmp.S'.
16614 (grubof_CFLAGS): Add `-DGRUBOF'.
16615 * include/grub/setjmp.h [GRUB_UTIL]: Changed condition to
16616 [GRUB_UTIL && !GRUBOF].
16617
16618 2004-11-16 Marco Gerards <metgerards@student.han.nl>
16619
16620 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Skip any
16621 property named `name'. Correctly handle the error returned by
16622 `grub_ieee1275_finddevice' if a device can not be opened.
16623
16624 2004-11-02 Hollis Blanchard <hollis@penguinppc.org>
16625
16626 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_readkey): Test
16627 `actual' for negativity.
16628 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
16629 kern/fshelp.c.
16630
16631 2004-11-01 Marco Gerards <metgerards@student.han.nl>
16632
16633 * term/i386/pc/vga.c (VGA_HEIGHT): Changed to 350.
16634 (PAGE_OFFSET): New macro.
16635 (CRTC_ADDR_PORT): Likewise.
16636 (CRTC_DATA_PORT): Likewise.
16637 (START_ADDR_HIGH_REGISTER): Likewise.
16638 (START_ADDR_LOW_REGISTER): Likewise.
16639 (GRAPHICS_ADDR_PORT): Likewise.
16640 (GRAPHICS_DATA_PORT): Likewise.
16641 (READ_MAP_REGISTER): Likewise.
16642 (INPUT_STATUS1_REGISTER): Likewise.
16643 (INPUT_STATUS1_VERTR_BIT): Likewise.
16644 (page): New variable.
16645 (wait_vretrace): New function.
16646 (set_read_map): Likewise.
16647 (set_start_address): Likewise.
16648 (grub_vga_init): Use mode 0x10 instead of mode 0x12. Switch to
16649 the right page.
16650 (check_vga_mem): Take the page into account.
16651 (write_char): Likewise.
16652 (write_cursor): Likewise.
16653 (scroll_up): Likewise. Copy the page to the page that is not
16654 shown and switch between both pages.
16655 (grub_vga_putchar): Fix off by one error.
16656 (grub_vga_cls): Wait for the vertical retrace. Take the page into
16657 account.
16658
16659 2004-11-01 Marco Gerards <metgerards@student.han.nl>
16660
16661 Add support for iso9660 (including rockridge).
16662
16663 * conf/i386-pc.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
16664 (iso9660_mod_SOURCES): New variable.
16665 (iso9660_mod_CFLAGS): Likewise.
16666 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
16667 * include/grub/fs.h (grub_iso9660_init): New prototype.
16668 * util/grub-emu.c (main): Call `grub_iso9660_init'.
16669 * fs/iso9660.c: New file.
16670
16671 * include/grub/misc.h (grub_strncat): New prototype.
16672 * kern/misc.c (grub_strncat): New function.
16673
16674 * fs/hfs.c (grub_hfs_mount): Translate the error
16675 `GRUB_ERR_OUT_OF_RANGE' to `GRUB_ERR_BAD_FS'.
16676 * fs/jfs.c (grub_jfs_mount): Likewise.
16677 * fs/ufs.c (grub_ufs_mount): Likewise.
16678
16679 2004-10-28 Hollis Blanchard <hollis@penguinppc.org>
16680
16681 * boot/powerpc/ieee1275/cmain.c (cmain): Remove asm statements
16682 which initialized BAT registers.
16683 * boot/powerpc/ieee1275/ieee1275.c (IEEE1275_CALL_ENTRY_FN,
16684 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
16685 Move from here...
16686 * include/grub/powerpc/ieee1275/ieee1275.h (IEEE1275_CALL_ENTRY_FN,
16687 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
16688 ... to here.
16689 * kern/powerpc/ieee1275/openfw.c (grub_map): New function.
16690 (grub_mapclaim): Likewise.
16691 * loader/powerpc/ieee1275/linux.c (grub_load_linux): Use
16692 grub_mapclaim instead of grub_ieee1275_claim. Assign linux_addr by
16693 hand.
16694
16695 2004-10-19 Hollis Blanchard <hollis@penguinppc.org>
16696
16697 * conf/powerpc-ieee1275.rmk (COMMON_ASFLAGS): Remove -fno-builtin.
16698 (COMMON_CFLAGS): Remove -fno-builtin and -D__ASSEMBLY__. Add
16699 -ffreestanding and -msoft-float.
16700
16701 2004-10-15 Hollis Blanchard <hollis@penguinppc.org>
16702
16703 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Do not
16704 append ":0" to devpath if the GRUB_IEEE1275_NO_PARTITION_0 flag is
16705 set in grub_ieee1275_flags.
16706
16707 2004-10-14 Hollis Blanchard <hollis@penguinppc.org>
16708
16709 * include/grub/powerpc/ieee1275/ieee1275.h (abort): Add function
16710 prototype.
16711 * kern/powerpc/ieee1275/init.c (grub_machine_init): Call
16712 grub_console_init first.
16713 Change the memory range used for grub_ieee1275_claim and
16714 grub_mm_init_region.
16715 Print an error message if the claim fails.
16716 Include <grub/misc.h>.
16717
16718 2004-10-13 Hollis Blanchard <hollis@penguinppc.org>
16719
16720 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_iterate):
16721 Call grub_children_iterate for device nodes of type `scsi',
16722 `ide', or `ata'.
16723 (grub_ofdisk_open): Remove manual device alias resolution.
16724 Fix memory leak when device cannot be opened.
16725 * include/grub/powerpc/ieee1275/ieee1275.h
16726 (grub_children_iterate): New prototype.
16727 * kern/powerpc/ieee1275/openfw.c (grub_children_iterate):
16728 New function.
16729 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
16730 Return -1 if args.size was -1.
16731
16732 2004-10-11 Hollis Blanchard <hollis@penguinppc.org>
16733
16734 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_flags): New global.
16735 (cmain): Accept 3 parameters. Test for 0xdeadbeef, indicating Old
16736 World Macintosh. If Old Wold, set flag in grub_ieee1275_flags; claim
16737 Open Firmware's memory for it; claim memory from _start to _end.
16738 * boot/powerpc/ieee1275/crt0.S (__bss_start): New extern.
16739 (_end): New extern.
16740 (_start): Zero BSS from __bss_start to _end.
16741 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
16742 New extern.
16743 (GRUB_IEEE1275_NO_PARTITION_0): New #define.
16744
16745 2004-10-11 Hollis Blanchard <hollis@penguinppc.org>
16746
16747 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): Return
16748 -1 if args.base was -1.
16749
16750 2004-10-08 Hollis Blanchard <hollis@penguinppc.org>
16751
16752 * term/powerpc/ieee1275/ieee1275.c (grub_ofconsole_cls): Use an ANSI
16753 escape sequence instead of a literal ^L. Also call
16754 grub_ofconsole_gotoxy.
16755
16756 2004-10-03 Hollis Blanchard <hollis@penguinppc.org>
16757
16758 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): change
16759 void * arguments to grub_addr_t. All callers updated. Also make
16760 the `result' argument optional.
16761 (grub_ieee1275_release): change void * arguments to grub_addr_t.
16762 All callers updated.
16763
16764 2004-09-22 Hollis Blanchard <hollis@penguinppc.org>
16765
16766 * commands/ls.c (grub_ls_list_files): Use the string following the
16767 initial ')', if present, as the filesystem path.
16768 * kern/rescue.c (grub_rescue_cmd_ls): Likewise.
16769
16770 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): List crt0.S first.
16771
16772 2004-09-18 Yoshinori K. Okuji <okuji@enbug.org>
16773
16774 Make the source code of the menu interface more readable.
16775
16776 * normal/menu.c: Include grub/mm.h.
16777 (TERM_WIDTH): New macro.
16778 (TERM_HEIGHT): Likewise.
16779 (TERM_INFO_HEIGHT): Likewise.
16780 (TERM_MARGIN): Likewise.
16781 (TERM_SCROLL_WIDTH): Likewise.
16782 (TERM_TOP_BORDER_Y): Likewise.
16783 (TERM_LEFT_BORDER_X): Likewise.
16784 (TERM_BORDER_WIDTH): Likewise.
16785 (TERM_MESSAGE_HEIGHT): Likewise.
16786 (TERM_BORDER_HEIGHT): Likewise.
16787 (TERM_NUM_ENTRIES): Likewise.
16788 (TERM_FIRST_ENTRY_Y): Likewise.
16789 (TERM_ENTRY_WIDTH): Likewise.
16790 (TERM_CURSOR_X): Likewise.
16791 (draw_border): Use macros instead of magic numbers.
16792 (print_entry): Likewise.
16793 (print_entries): Likewise.
16794 (run_menu): Likewise. Also, handle the key 'e'.
16795 (run_menu_entry): Ignore empty command lines.
16796 (print_message): Added a new argument EDIT. If EDIT is true,
16797 print a different message.
16798 (init_page): Likewise.
16799 (edit_menu_entry): New function. Not implemented yet.
16800
16801 2004-09-17 Marco Gerards <metgerards@student.han.nl>
16802
16803 Add `linux.mod' and `multiboot.mod' so linux and multiboot kernels
16804 can be loaded from normal mode.
16805
16806 * conf/i386-pc.rmk (pkgdata_MODULES): Add `linux.mod' and
16807 `multiboot.mod'.
16808 (linux_mod_SOURCES, linux_mod_CFLAGS, multiboot_mod_SOURCES)
16809 (multiboot_mod_CFLAGS): New variables.
16810 * loader/i386/pc/linux_normal.c: New file.
16811 * loader/i386/pc/multiboot_normal.c: Likewise.
16812
16813 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Don't use the
16814 attribute `unused'.
16815
16816 * fs/ext2.c (grub_ext2_iterate_dir): Fix typos in inode type. Use
16817 `fdiro' to read the mode information from instead of `diro'.
16818
16819 * fs/fshelp.c (grub_fshelp_find_file): Set type to foundtype after
16820 looking up a symlink.
16821
16822 * include/grub/normal.h (GRUB_COMMAND_FLAG_NO_ARG_PARSE): New
16823 macro.
16824 * normal/command.c (grub_command_execute): Don't parse the
16825 arguments when `GRUB_COMMAND_FLAG_NO_ARG_PARSE' is set in the
16826 flags of the command.
16827
16828 * normal/menu.c (grub_menu_run): Fix typo.
16829
16830 2004-09-14 Hollis Blanchard <hollis@penguinppc.org>
16831
16832 * kern/powerpc/ieee1275/init.c (abort): Trap into Open Firmware.
16833
16834 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_gotoxy): Use
16835 `y + 1' instead of `y - 1'.
16836
16837 * conf/powerpc-ieee1275.rmk (grubof_LDFLAGS): Add `-N' and `-S'.
16838
16839 2004-09-14 Yoshinori K. Okuji <okuji@enbug.org>
16840
16841 From Hollis Blanchard <hollis@penguinppc.org>:
16842 * kern/misc.c (memmove): New alias for grub_memmove.
16843 (memcmp): New alias for grub_memcmp.
16844 (memset): New alias for grub_memset.
16845 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
16846 Change "int handle" to "grub_ieee1275_phandle_t handle".
16847 * include/grub/powerpc/ieee1275/ieee1275.h
16848 (grub_ieee1275_get_property): Likewise.
16849
16850 2004-09-12 Tomas Ebenlendr <ebik@ucw.cz>
16851
16852 Added normal mode command `chainloader' as module chain.mod, which
16853 depends on normal.mod and _chain.mod.
16854
16855 * conf/i386-pc.rmk (pkgdata_MODULES): Add `chain.mod'.
16856 (chain_mod_SOURCES, chain_mod_CFLAGS): Variables added.
16857 * include/grub/i386/pc/loader.h (grub_rescue_cmd_chainloader):
16858 Deleted prototype.
16859 * loader/i386/pc/chainloader.c (grub_rescue_cmd_chainloader): All
16860 but arguments parsing moved to ...
16861 (grub_chainloader_cmd): ... here. New function.
16862 * include/grub/i386/pc/chainloader.h: New file.
16863 * loader/i386/pc/chainloader_normal.c: Likewise.
16864
16865 2004-09-11 Marco Gerards <metgerards@student.han.nl>
16866
16867 * conf/i386-pc.rmk (kernel_img_SOURCES): Added kern/fshelp.c.
16868 (grub_mkimage_LDFLAGS): Likewise.
16869 (grub_emu_SOURCES): Likewise.
16870 (kernel_img_HEADERS): Added fshelp.h.
16871 * fs/ext2.c: Include <grub/fshelp.h>.
16872 (FILETYPE_REG): New macro.
16873 (FILETYPE_INO_REG): Likewise.
16874 (grub_ext_sblock): Renamed to `grub_ext2_sblock'.
16875 Changed all users.
16876 (ext2_block_group): Renamed to `grub_ext2_block_group'. Changed
16877 all users.
16878 (grub_fshelp_node): New struct.
16879 (grub_ext2_data): Added member `diropen'. Changed member `inode'
16880 to a pointer.
16881 (grub_ext2_get_file_block): Removed function.
16882 (grub_ext2_read_block): New function.
16883 (grub_ext2_read_file): Replaced parameter `data' by `node'.
16884 This function was written.
16885 (grub_ext2_mount): Read the root inode. Create a diropen struct.
16886 (grub_ext2_find_file): Removed function.
16887 (grub_ext2_read_symlink): New function.
16888 (grub_ext2_iterate_dir): Likewise.
16889 (grub_ext2_open): Rewritten.
16890 (grub_ext2_dir): Rewritten.
16891 * include/grub/fshelp.h: New file.
16892 * fs/fshelp.c: Likewise.
16893
16894 2004-09-10 Yoshinori K. Okuji <okuji@enbug.org>
16895
16896 * normal/menu.c: Include grub/loader.h and grub/machine/time.h.
16897 (print_message): Add a missing newline.
16898 (run_menu): Added timeout support.
16899 (run_menu_entry): New local function.
16900 (grub_menu_run): Added support for booting.
16901
16902 * kern/loader.c (grub_loader_is_loaded): New function.
16903
16904 * include/grub/powerpc/ieee1275/time.h: Include grub/symbol.h.
16905 (grub_get_rtc): Exported.
16906
16907 * include/grub/i386/pc/time.h: Include grub/symbol.h.
16908 (grub_get_rtc): Exported.
16909
16910 * include/grub/normal.h (struct grub_command_list): Remove
16911 constant from the member `command'.
16912
16913 * include/grub/loader.h (grub_loader_is_loaded): Declared.
16914
16915 * include/grub/err.h (GRUB_ERR_INVALID_COMMAND): New constant.
16916
16917 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/time.h.
16918
16919 2004-08-28 Marco Gerards <metgerards@student.han.nl>
16920
16921 Add support for the JFS filesystem.
16922
16923 * fs/jfs.c: New file.
16924 * include/grub/fs.h (grub_jfs_init): New prototype.
16925 (grub_jfs_fini): New prototype.
16926 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/jfs.c.
16927 (grub_emu_SOURCES): Likewise.
16928 (pkgdata_MODULES): Add jfs.mod.
16929 (jfs_mod_SOURCES): New variable.
16930 (jfs_mod_CFLAGS): Likewise.
16931 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs.jfs.c.
16932 (grubof_SOURCES): Likewise.
16933 * util/grub-emu.c (main): Initialize and deinitialize JFS support.
16934
16935 * fs/fat.c (grub_fat_find_dir): Convert the filename little
16936 endian to the host endian.
16937 (grub_fat_utf16_to_utf8): Move function from there...
16938 * kern/misc.c (grub_utf16_to_utf8): ...to here. Do not convert
16939 the endianness of the source string anymore.
16940 * include/grub/misc.h (grub_utf16_to_utf8): New prototype.
16941
16942 2004-08-24 Marco Gerards <metgerards@student.han.nl>
16943
16944 * commands/boot.c (grub_boot_init) [GRUB_UTIL]: Make conditional.
16945 (grub_boot_fini) [GRUB_UTIL]: Likewise.
16946 (GRUB_MOD_INIT) [!GRUB_UTIL]: Likewise.
16947 (GRUB_MOD_FINI) [!GRUB_UTIL]: Likewise.
16948
16949 * fs/hfs.c (grub_hfs_find_node): Add a prototype for `node_found'.
16950 (grub_hfs_iterate_dir): Make the function static. Add prototypes
16951 for `node_found' and `it_dir'.
16952 (grub_hfs_dir): Add prototype for `dir_hook'.
16953
16954 * fs/minix.c (grub_minix_get_file_block): Add prototype for
16955 `grub_get_indir'. Rename `indir' in two blocks to `indir16'
16956 and `indir32' to silence a gcc warning.
16957
16958 * include/grub/fs.h (grub_hfs_init): New prototype.
16959 (grub_hfs_fini): Likewise.
16960
16961
16962 2004-08-21 Yoshinori K. Okuji <okuji@enbug.org>
16963
16964 Each disk device has its own id now. This is useful to make use
16965 of multiple disk devices.
16966
16967 * include/grub/disk.h (grub_disk_dev_id): New enum.
16968 (GRUB_DISK_DEVICE_BIOSDISK_ID): New constant.
16969 (GRUB_DISK_DEVICE_OFDISK_ID): Likewise.
16970
16971 * disk/i386/pc/biosdisk.c (grub_biosdisk_dev): Specify
16972 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
16973
16974 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_dev): Specify
16975 GRUB_DISK_DEVICE_OFDISK_ID as an id.
16976
16977 * util/i386/pc/biosdisk.c (grub_util_biosdisk_dev): Specify
16978 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
16979
16980 * include/grub/disk.h (struct grub_disk_dev): Added a new member
16981 "id" which is used by the cache manager.
16982
16983 * normal/main.c (grub_normal_init_page): Use "GNU GRUB" instead
16984 of just "GRUB".
16985
16986 2004-08-18 Marco Gerards <metgerards@student.han.nl>
16987
16988 * fs/hfs.c: New file.
16989 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/hfs.c.
16990 (grub_emu_SOURCES): Likewise.
16991 (pkgdata_MODULES): Add hfs.mod.
16992 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/hfs.c.
16993 (grubof_SOURCES): Likewise.
16994 * util/grub-emu.c (main): Initialize and deinitialize HFS support.
16995
16996 * include/grub/misc.h (grub_strncasecmp): Add prototype.
16997 * kern/misc.c (grub_strncasecmp): Add function.
16998
16999 2004-08-14 Marco Gerards <metgerards@student.han.nl>
17000
17001 * include/grub/arg.h (GRUB_ARG_OPTION_OPTIONAL): Surround macro
17002 with parentheses.
17003
17004 * fs/ext2.c (FILETYPE_UNKNOWN): New macro.
17005 (grub_ext2_dir): In case the directory entry type is unknown, read
17006 it from the inode.
17007
17008 2004-08-02 Peter Bruin <pjbruin@dds.nl>
17009
17010 * loader/powerpc/ieee1275/linux.c (grub_linux_init): Pass
17011 grub_load_linux instead of grub_rescue_cmd_linux as second
17012 argument of grub_rescue_register_command.
17013
17014 * Makefile.in (RMKFILES): Add conf/powerpc-ieee1275.rmk.
17015
17016 2004-07-27 Marco Gerards <metgerards@student.han.nl>
17017
17018 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_release): New
17019 function.
17020 * commands/boot.c: Remove the check for `GRUB_UTIL'.
17021 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
17022 `loader/powerpc/ieee1275/linux.c',
17023 `loader/powerpc/ieee1275/linux_normal.c' and `commands/boot.c'.
17024 * include/grub/powerpc/ieee1275/ieee1275.h
17025 (grub_ieee1275_release): New prototype.
17026 * include/grub/powerpc/ieee1275/loader.h: Rewritten.
17027 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize
17028 normal, boot, linux and linux_normal.
17029 * loader/powerpc/ieee1275/linux.c: New file.
17030 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
17031
17032 2004-07-12 Marco Gerards <metgerards@student.han.nl>
17033
17034 * normal/arg.c (grub_arg_parse): Correct error handling after
17035 reallocating the argumentlist (check if `argl' is not null instead
17036 of checking if `args' is not null).
17037 * kern/mm.c (grub_realloc): Return the same pointer when using the
17038 same region, instead of returning the header address.
17039
17040 2004-07-11 Marco Gerards <metgerards@student.han.nl>
17041
17042 * disk/powerpc/ieee1275/partition.c (grub_partition_iterate): Skip
17043 one block instead of two when looking for the initial partition.
17044 (grub_partition_probe): Initialize the local variable `p' with 0.
17045 Use base 10 for the grub_strtoul call.
17046 * kern/misc.c (grub_strncpy): Fix off by one bug. Eliminated the
17047 need for one local variable.
17048 (grub_strtoul): Don't add the new value to `num', instead of that
17049 just assign it.
17050
17051 2004-07-11 Marco Gerards <metgerards@student.han.nl>
17052
17053 * conf/i386-pc.rmk (pkgdata_IMAGE): Add pxeboot.img.
17054 (pxeboot_img_SOURCES): New variable.
17055 (pxeboot_img_ASFLAGS): Likewise.
17056 (pxeboot_img_LDFLAGS): Likewise.
17057 * boot/i386/pc/pxeboot.S: New file. Based on pxeloader.S from
17058 GRUB Legacy and boot.S. Adopted for GRUB 2 by lode leroy
17059 <lode_leroy@hotmail.com>.
17060
17061 2004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
17062
17063 * kern/rescue.c (grub_enter_rescue_mode): Don't continue when
17064 there was no input.
17065
17066 2004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
17067
17068 * normal/cmdline.c (grub_set_history): Fix off by one bug. Fixed
17069 the history buffer logic.
17070
17071 2004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
17072
17073 * fs/ext2.c (FILETYPE_INO_MASK, FILETYPE_INO_DIRECTORY)
17074 (FILETYPE_INO_SYMLINK): New macros.
17075 (grub_ext2_find_file): Check if the node is a directory using the
17076 inode stat information instead of using the filetype in the
17077 dirent. Exclude the first character of an absolute symlink.
17078 (grub_ext2_dir): Mask out the filetype part of the mode member of
17079 the inode.
17080
17081 2004-05-24 Marco Gerards <metgerards@student.han.nl>
17082
17083 Add support for UFS version 1 and 2. Add support for the minix
17084 filesystem version 1 and 2, both the variants with 14 and 30 long
17085 filenames.
17086
17087 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ufs.c and
17088 fs/minix.c.
17089 (grub_emu_SOURCES): Likewise.
17090 (pkgdata_MODULES): Add ufs.mod and minix.mod.
17091 (ufs_mod_SOURCES): New variable.
17092 (ufs_mod_CFLAGS): Likewise.
17093 (minix_mod_SOURCES): Likewise.
17094 (minix_mod_CFLAGS): Likewise.
17095 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/ufs.c and
17096 fs/minix.c.
17097 (grubof_SOURCES): Likewise.
17098 * fs/ufs.c: New file.
17099 * fs/minix.c: New file.
17100 * include/grub/fs.h (grub_ufs_init): New prototype.
17101 (grub_ufs_fini): Likewise.
17102 (grub_minix_init): Likewise.
17103 (grub_minix_fini): Likewise.
17104 * util/grub-emu.c (main): Initialize and deinitialize UFS and
17105 minix fs.
17106
17107 2004-04-30 Jeroen Dekkers <jeroen@dekkers.cx>
17108
17109 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add normal/arg.c,
17110 commands/ls.c, commands/terminal.c, commands/boot.c,
17111 commands/cmp.c and commands/cat.c.
17112 (grubof_LDFLAGS): Add -nostdlib -static-libgcc -lgcc.
17113
17114 * kern/powerpc/ieee1275/init.c: Include "grub/env.h" instead of
17115 "env.h"
17116
17117 2004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
17118
17119 All symbols prefixed with PUPA_ and pupa_ are renamed to GRUB_
17120 and grub_, respectively. Because the conversion is trivial and
17121 mechanical, I omit the details here. Please refer to the CVS
17122 if you need more information.
17123
17124 2004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
17125
17126 * include/pupa: Renamed to ...
17127 * include/grub: ... this.
17128 * util/i386/pc/pupa-mkimage.c: Renamed to ...
17129 * util/i386/pc/grub-mkimage.c: ... this.
17130 * util/i386/pc/pupa-setup.c: Renamed to ...
17131 * util/i386/pc/grub-setup.c: ... this.
17132 * util/pupa-emu.c: Renamed to ...
17133 * util/grub-emu.c: ... this.
17134
17135 2004-03-29 Marco Gerards <metgerards@student.han.nl>
17136
17137 Add support for the newworld apple macintosh (PPC). This has been
17138 tested on the powerbook 2000 only. It only adds support for
17139 generic ieee1275 functions, console and disk support. This should
17140 be easy to port to other architectures with support for Open
17141 Firmware.
17142
17143 * configure.ac: Accept the powerpc as host_cpu. In the case of
17144 the powerpc cpu set the host_vendor to ieee1275. Make sure the i386
17145 specific tests are only executed while building for the i386.
17146 Inverse test for crosscompile.
17147 * genmk.rb (Utility): Allow assembler files.
17148 * normal/cmdline.c (pupa_tab_complete): Reset pupa_errno.
17149 * conf/powerpc-ieee1275.rmk: New file.
17150 * disk/powerpc/ieee1275/ofdisk.c: Likewise.
17151 * disk/powerpc/ieee1275/partition.c: Likewise.
17152 * include/pupa/powerpc/ieee1275/biosdisk.h: Likewise.
17153 * include/pupa/powerpc/ieee1275/console.h: Likewise.
17154 * include/pupa/powerpc/ieee1275/partition.h: Likewise.
17155 * include/pupa/powerpc/ieee1275/time.h: Likewise.
17156 * include/pupa/powerpc/ieee1275/util/biosdisk.h: Likewise.
17157 * include/pupa/powerpc/ieee1275/multiboot.h: Likewise.
17158 * include/pupa/powerpc/ieee1275/loader.h
17159 * include/pupa/powerpc/setjmp.h: Likewise.
17160 * include/pupa/powerpc/types.h: Likewise.
17161 * kern/powerpc/ieee1275/init.c: Likewise.
17162 * kern/powerpc/ieee1275/openfw.c: Likewise.
17163 * term/powerpc/ieee1275/ofconsole.c: Likewise.
17164
17165 These files were written by Johan Rydberg
17166 (jrydberg@night.trouble.net) and I only modified them slightly.
17167
17168 * boot/powerpc/ieee1275/cmain.c: New file.
17169 * boot/powerpc/ieee1275/crt0.S: Likewise.
17170 * boot/powerpc/ieee1275/ieee1275.c: Likewise.
17171 * include/pupa/powerpc/ieee1275/ieee1275.h: Likewise.
17172
17173 2004-03-14 Jeroen Dekkers <jeroen@dekkers.cx>
17174
17175 * Makefile.in: Update copyright.
17176 * genmodsrc.sh: Likewise.
17177 * gensymlist.sh: Likewise.
17178 * term/i386/pc/vga.c: Indent correctly.
17179
17180 * util/i386/pc/pupa-mkimage.c (usage): Use PACKAGE_BUGREPORT as
17181 bugreporting address.
17182 * util/i386/pc/pupa-setup.c (usage): Likewise,
17183 (main): Call pupa_ext2_init and pupa_ext2_fini.
17184
17185 * fs/fat.c (log2): Renamed to ...
17186 (fat_log2): ... this.
17187 All callers changed.
17188 * kern/misc.c (memcpy): Alias to pupa_memmove.
17189 * loader/i386/pc/multiboot.c (pupa_rescue_cmd_multiboot): Fix
17190 lvalue cast.
17191 * util/console.c (pupa_ncurses_fini): Return 0.
17192
17193 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open)[__linux__]:
17194 Move fail label here.
17195 [__GNU__]: Don't warn when using stat.
17196 (open_device)[!__linux__]: Check if FD < 0 instead of !FD.
17197 (pupa_util_biosdisk_get_pupa_dev)[__GNU__]: Change type of N to
17198 long int. Use strtol instead of strtoul.
17199
17200 2004-03-14 Marco Gerards <metgerards@student.han.nl>
17201
17202 * commands/boot.c: New file.
17203 * commands/cat.c: Likewise.
17204 * commands/cmp.c: Likewise.
17205 * commands/ls.c: Likewise.
17206 * commands/terminal.c: Likewise.
17207 * normal/command.c: Include <pupa/env.h> and <pupa/dl.h>.
17208 (pupa_register_command): Changed interface to match the new
17209 argument parser.
17210 (pupa_command_execute): Changed (almost rewritten) so it uses
17211 pupa_split_command. Added support for setting variables using the
17212 syntax `foo=bar'.
17213 (rescue_command): Changed to work with the new argument parser.
17214 (terminal_command): Moved from here to commands/terminal.c.
17215 (set_command): New function.
17216 (unset_command): New function.
17217 (insmod_command): New function.
17218 (rmmod_command): New function.
17219 (lsmod_command): New function.
17220 (pupa_command_init): Don't initialize the command terminal
17221 anymore. Initialize the commands set, unset, insmod, rmmod and
17222 lsmod.
17223 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/env.c.
17224 (kernel_img_HEADERS): Add arg.h and env.h.
17225 (pupa_mkimage_LDFLAGS): Add kern/env.c.
17226 (pupa_emu_SOURCES): Add kern/env.c, commands/ls.c,
17227 commands/terminal.c commands/boot.c commands/cmp.c commands/cat.c,
17228 normal/arg.c.
17229 (pkgdata_MODULES): Add ls.mod, boot.mod, cmp.mod, cat.mod and
17230 terminal.mod.
17231 (normal_mod_SOURCES): Add normal/arg.c and normal/arg.c.
17232 (boot_mod_SOURCES): New variable.
17233 (terminal_mod_SOURCES): Likewise.
17234 (ls_mod_SOURCES): Likewise.
17235 (cmp_mod_SOURCES): Likewise.
17236 (cat_mod_SOURCES): Likewise.
17237
17238 * normal/arg.c: New file.
17239 * kern/env.c: Likewise.
17240 * include/pupa/arg.h: Likewise.
17241 * include/pupa/env.h: Likewise.
17242 * font/manager.c (font_command): Changed to match argument parsing
17243 interface changes.
17244 (PUPA_MOD_INIT): Likewise.
17245 * hello/hello.c (pupa_cmd_hello): Likewise.
17246 (PUPA_MOD_INIT): Likewise.
17247 * include/pupa/disk.h: Include <pupa/device.h>.
17248 (pupa_print_partinfo): New prototype.
17249 * include/pupa/dl.h (pupa_dl_set_prefix): Prototype removed.
17250 (pupa_dl_get_prefix): Likewise.
17251 * include/pupa/misc.h: Include <pupa/err.h>.
17252 (pupa_isgraph): New prototype.
17253 (pupa_isdigit): Likewise.
17254 (pupa_split_cmdline): Likewise.
17255 * include/pupa/normal.h: Include <pupa/arg.h>.
17256 (pupa_command): Changed the prototype of the member `func' to
17257 match the argument parsing interface. Added member `options'.
17258 (pupa_register_command): Updated to match function.
17259 (pupa_arg_parse): New prototype.
17260 (pupa_hello_init) [PUPA_UTIL]: New prototype.
17261 (pupa_hello_fini) [PUPA_UTIL]: Likewise.
17262 (pupa_ls_init) [PUPA_UTIL]: Likewise.
17263 (pupa_ls_fini) [PUPA_UTIL]: Likewise.
17264 (pupa_cat_init) [PUPA_UTIL]: Likewise.
17265 (pupa_cat_fini) [PUPA_UTIL]: Likewise.
17266 (pupa_boot_init) [PUPA_UTIL]: Likewise.
17267 (pupa_boot_fini) [PUPA_UTIL]: Likewise.
17268 (pupa_cmp_init) [PUPA_UTIL]: Likewise.
17269 (pupa_cmp_fini) [PUPA_UTIL]: Likewise.
17270 (pupa_terminal_init) [PUPA_UTIL]: Likewise.
17271 (pupa_terminal_fini) [PUPA_UTIL]: Likewise.
17272 * kern/disk.c: Include <pupa/file.h>.
17273 (pupa_print_partinfo): New function.
17274 * kern/dl.c: Include <pupa/env.h>.
17275 (pupa_dl_dir): Variable removed.
17276 (pupa_dl_load): Use the environment variable `prefix' instead of
17277 the variable pupa_dl_dir.
17278 (pupa_dl_set_prefix): Function removed.
17279 (pupa_dl_get_prefix): Likewise.
17280 * kern/i386/pc/init.c: Include <pupa/env.h>.
17281 (pupa_machine_init): Use the environment variable `prefix' instead of
17282 using pupa_dl_set_prefix to set the prefix.
17283 * kern/main.c: Include <pupa/env.h>.
17284 (pupa_set_root_dev): Use the environment variable `prefix' instead of
17285 using pupa_dl_get_prefix to get the prefix.
17286 * kern/misc.c: Include <pupa/env.h>.
17287 (pupa_isdigit): New function.
17288 (pupa_isgraph): Likewise.
17289 (pupa_ftoa): Likewise.
17290 (pupa_vsprintf): Added support for printing values of the type
17291 `double'. Make it possible to format variable output when using
17292 formatting like `%1.2%f'.
17293 (pupa_split_cmdline): New function.
17294 * kern/rescue.c: Include <pupa/env.h>.
17295 (next_word): Removed function.
17296 (pupa_rescue_cmd_prefix): Likewise.
17297 (pupa_rescue_cmd_set): New function.
17298 (pupa_rescue_cmd_unset): New function.
17299 (pupa_enter_rescue_mode): Use the `pupa_split_cmdline' function to
17300 split the command line instead of splitting it here. Added
17301 support for setting variables using the syntax `foo=bar'. Don't
17302 initialize the prefix command anymore. Initialized the set and
17303 unset commands.
17304 * normal/cmdline.c: Include <pupa/env.h>.
17305 (pupa_tab_complete): Added prototypes for print_simple_completion,
17306 print_partition_completion, add_completion, iterate_commands,
17307 iterate_dev, iterate_part and iterate_dir. Moved code to print
17308 partition information from here to kern/disk.c.
17309 (pupa_cmdline_run): Don't check if the function exists anymore.
17310 * normal/main.c: Include <pupa/env.h>.
17311 (pupa_rescue_cmd_normal): Use the environment variable `prefix'
17312 instead of using pupa_dl_get_prefix to get the prefix.
17313 * term/i386/pc/vga.c: Include <pupa/arg.h>.
17314 (check_vga_mem): Cast pointers to `void *' to silence a gcc
17315 warning.
17316 (pupa_vga_putchar) [! DEBUG_VGA]: Removed for this case.
17317 (pupa_vga_setcolor): Declare unused variables with `__attribute__
17318 ((unused))' to silence a gcc warning.
17319 (pupa_vga_setcolor): Likewise.
17320 (debug_command): Changed to match argument parsing
17321 interface changes.
17322 * util/pupa-emu.c: Include <pupa/env.h>.
17323 (options): Added 0's for unused fields to silence a gcc warning.
17324 (argp): Likewise.
17325 (main): Use the environment variable `prefix' instead of using
17326 pupa_dl_set_prefix to set the prefix. Initialize the commands ls,
17327 boot, cmp, cat and terminal. Finish the commands boot, cmp, cat
17328 and terminal.
17329
17330 * util/i386/pc/getroot.c: Include <pupa/i386/pc/util/biosdisk.h>.
17331 * util/misc.c: Include <malloc.h>.
17332 (pupa_malloc): Rewritten so errors are correctly reported.
17333 (pupa_realloc): Likewise.
17334 (pupa_memalign): Likewise.
17335 (pupa_mm_init_region): Declare unused variables with
17336 `__attribute__ ((unused))' to silence a gcc warning.
17337 * normal/i386/setjmp.S: Remove tab at the end of the file to
17338 silence a gcc warning.
17339 * loader/i386/pc/linux.c (pupa_rescue_cmd_initrd): Declare unused
17340 variables with `__attribute__ ((unused))' to silence a gcc
17341 warning.
17342 * loader/i386/pc/multiboot.c (pupa_multiboot_unload): Make the
17343 local variable i unsigned to silence a gcc warning.
17344
17345 * kern/term.c: Include <pupa/misc.h>.
17346 (pupa_more_lines): New variable.
17347 (pupa_more): Likewise.
17348 (pupa_putcode): When the pager is active pause at the end of every
17349 screen.
17350 (pupa_set_more): New function.
17351 * include/pupa/term.h (pupa_set_more): New prototype.
17352
17353
17354 2004-03-07 Yoshinori K. Okuji <okuji@enbug.org>
17355
17356 Now this project is GRUB 2 rather than PUPA. The location of
17357 the CVS repository was moved to GRUB's.
17358
17359 * configure.ac: Use bug-grub as the reporting address.
17360 Use GRUB instead of PUPA.
17361 Change the version number to 1.90.
17362
17363 2004-02-24 Yoshinori K. Okuji <okuji@enbug.org>
17364
17365 * genkernsyms.sh: Updated copyright information.
17366 * genmk.rb: Likewise.
17367 * genmodsrc.sh: Likewise.
17368 * gensymlist.sh: Likewise.
17369 * boot/i386/pc/boot.S: Likewise.
17370 * boot/i386/pc/diskboot.S: Likewise.
17371 * disk/i386/pc/biosdisk.c: Likewise.
17372 * disk/i386/pc/partition.c: Likewise.
17373 * font/manager.c: Likewise.
17374 * fs/ext2.c: Likewise.
17375 * fs/fat.c: Likewise.
17376 * include/pupa/boot.h: Likewise.
17377 * include/pupa/device.h: Likewise.
17378 * include/pupa/disk.h: Likewise.
17379 * include/pupa/dl.h: Likewise.
17380 * include/pupa/elf.h: Likewise.
17381 * include/pupa/err.h: Likewise.
17382 * include/pupa/file.h: Likewise.
17383 * include/pupa/font.h: Likewise.
17384 * include/pupa/fs.h: Likewise.
17385 * include/pupa/kernel.h: Likewise.
17386 * include/pupa/loader.h: Likewise.
17387 * include/pupa/misc.h: Likewise.
17388 * include/pupa/mm.h: Likewise.
17389 * include/pupa/net.h: Likewise.
17390 * include/pupa/normal.h: Likewise.
17391 * include/pupa/rescue.h: Likewise.
17392 * include/pupa/setjmp.h: Likewise.
17393 * include/pupa/symbol.h: Likewise.
17394 * include/pupa/term.h: Likewise.
17395 * include/pupa/types.h: Likewise.
17396 * include/pupa/i386/setjmp.h: Likewise.
17397 * include/pupa/i386/types.h: Likewise.
17398 * include/pupa/i386/pc/biosdisk.h: Likewise.
17399 * include/pupa/i386/pc/boot.h: Likewise.
17400 * include/pupa/i386/pc/console.h: Likewise.
17401 * include/pupa/i386/pc/init.h: Likewise.
17402 * include/pupa/i386/pc/kernel.h: Likewise.
17403 * include/pupa/i386/pc/linux.h: Likewise.
17404 * include/pupa/i386/pc/loader.h: Likewise.
17405 * include/pupa/i386/pc/memory.h: Likewise.
17406 * include/pupa/i386/pc/multiboot.h: Likewise.
17407 * include/pupa/i386/pc/partition.h: Likewise.
17408 * include/pupa/i386/pc/time.h: Likewise.
17409 * include/pupa/i386/pc/vga.h: Likewise.
17410 * include/pupa/i386/pc/util/biosdisk.h: Likewise.
17411 * include/pupa/util/getroot.h: Likewise.
17412 * include/pupa/util/misc.h: Likewise.
17413 * include/pupa/util/resolve.h: Likewise.
17414 * kern/device.c: Likewise.
17415 * kern/disk.c: Likewise.
17416 * kern/dl.c: Likewise.
17417 * kern/err.c: Likewise.
17418 * kern/file.c: Likewise.
17419 * kern/fs.c: Likewise.
17420 * kern/loader.c: Likewise.
17421 * kern/main.c: Likewise.
17422 * kern/misc.c: Likewise.
17423 * kern/mm.c: Likewise.
17424 * kern/rescue.c: Likewise.
17425 * kern/term.c: Likewise.
17426 * kern/i386/dl.c: Likewise.
17427 * kern/i386/pc/init.c: Likewise.
17428 * kern/i386/pc/lzo1x.S: Likewise.
17429 * kern/i386/pc/startup.S: Likewise.
17430 * loader/i386/pc/chainloader.c: Likewise.
17431 * loader/i386/pc/linux.c: Likewise.
17432 * loader/i386/pc/multiboot.c: Likewise.
17433 * normal/cmdline.c: Likewise.
17434 * normal/command.c: Likewise.
17435 * normal/main.c: Likewise.
17436 * normal/menu.c: Likewise.
17437 * normal/i386/setjmp.S: Likewise.
17438 * term/i386/pc/console.c: Likewise.
17439 * term/i386/pc/vga.c: Likewise.
17440 * util/console.c: Likewise.
17441 * util/genmoddep.c: Likewise.
17442 * util/misc.c: Likewise.
17443 * util/pupa-emu.c: Likewise.
17444 * util/resolve.c: Likewise.
17445 * util/unifont2pff.rb: Likewise.
17446 * util/i386/pc/biosdisk.c: Likewise.
17447 * util/i386/pc/getroot.c: Likewise.
17448 * util/i386/pc/pupa-mkimage.c: Likewise.
17449 * util/i386/pc/pupa-setup.c: Likewise.
17450
17451 2004-02-15 Jeroen Dekkers <jeroen@dekkers.cx>
17452
17453 * fs/ext2.c (pupa_ext2_read_file): Correct the value of BLOCKEND
17454 when it is EXT2_BLOCK_SIZE (data). New argument READ_HOOK, all
17455 callers changed. Set DATA->DISK->READ_HOOK to READ_HOOK before
17456 reading and reset it after reading.
17457 (pupa_ext2_close): Return PUPA_ERR_NONE.
17458
17459 * include/pupa/i386/pc/linux.h (PUPA_LINUX_INITRD_MAX_ADDRESS):
17460 Correct value.
17461 (struct linux_kernel_header): Add kernel_version and
17462 initrd_addr_max.
17463 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Check whether
17464 pupa_file_read succeeds.
17465 (pupa_rescue_cmd_initrd): Implement.
17466
17467 2003-12-03 Marco Gerards <metgerards@student.han.nl>
17468
17469 * fs/ext2.c (pupa_ext2_label): New function.
17470 (pupa_ext2_fs): Added label.
17471 * fs/fat.c (pupa_fat_label): New function.
17472 (pupa_fat_fs): Added label.
17473 * include/pupa/fs.h (struct pupa_fs): Added prototype label.
17474
17475 * kern/misc.c (pupa_strndup): New function.
17476 * include/pupa/misc.h (pupa_strndup): New prototype.
17477
17478 * include/pupa/normal.h: Include <pupa/err.h>.
17479 (pupa_set_history): New prototype.
17480 (pupa_iterate_commands): New prototype.
17481 * normal/cmdline.c: Include <pupa/machine/partition.h>,
17482 <pupa/disk.h>, <pupa/file.h>.
17483 (hist_size): New variable.
17484 (hist_lines): Likewise.
17485 (hist_end): Likewise.
17486 (hist_used): Likewise.
17487 (pupa_set_history): New function.
17488 (pupa_history_get): Likewise.
17489 (pupa_history_add): Likewise.
17490 (pupa_history_replace): Likewise.
17491 (pupa_tab_complete): Likewise.
17492 (pupa_cmdline_run): Added tab completion and history buffer. Tab
17493 completion shows partitionnames while completing partitions, this
17494 feature was suggested by Jeff Bailey.
17495 * normal/command.c (pupa_iterate_commands): New function.
17496 * normal/main.c (PUPA_DEFAULT_HISTORY_SIZE): New macro.
17497 (pupa_normal_init): Initialize history buffer.
17498 (PUPA_MOD_INIT): Likewise.
17499 (pupa_normal_fini): Free the history buffer.
17500 (PUPA_MOD_FINI): Likewise.
17501
17502 * util/console.c (pupa_ncurses_getkey): Accept 127 as backspace
17503 key.
17504
17505 * aclocal.m4 (pupa_I386_CHECK_REGPARM_BUG): New DEFUN.
17506 * configure.ac [i386]: Check for regparam bug.
17507 (NESTED_FUNC_ATTR) [! i386]: Defined.
17508
17509 2003-11-17 Marco Gerards <metgerards@student.han.nl>
17510
17511 * conf/i386-pc.rmk (sbin_UTILITIES): Added pupa-emu.
17512 (pupa_setup_SOURCES): Added util/i386/pc/getroot.c.
17513 (pupa_emu_SOURCES): New variable.
17514 (pupa_emu_LDFLAGS): Likewise.
17515 * include/pupa/fs.h (pupa_ext2_init) [PUPA_UTIL]: New prototype.
17516 (pupa_ext2_fini) [PUPA_UTIL]: Likewise.
17517 * include/pupa/normal.h (pupa_normal_init) [PUPA_UTIL]: Likewise.
17518 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
17519 * include/pupa/setjmp.h [PUPA_UTIL]: Include <setjmp.h>.
17520 (pupa_jmp_buf): New typedef.
17521 (pupa_setjmp) [PUPA_UTIL]: New macro.
17522 (pupa_longjmp) [PUPA_UTIL]: Likewise.
17523 * include/pupa/term.h (struct pupa_term): New member `refresh'.
17524 (pupa_refresh): New prototype.
17525 * include/pupa/util/getroot.h: New file.
17526 * kern/misc.c (pupa_vsprintf): Refresh the screen after updating
17527 it.
17528 * kern/rescue.c (pupa_rescue_get_command_line): Likewise.
17529 (pupa_rescue_cmd_cat): Likewise.
17530 (pupa_rescue_cmd_ls): Likewise.
17531 (pupa_rescue_cmd_testload): Likewise.
17532 (pupa_rescue_cmd_lsmod): Likewise.
17533 * normal/cmdline.c (pupa_cmdline_get): Likewise.
17534 * normal/menu.c (run_menu): Likewise.
17535 * kern/term.c (pupa_cls): Likewise.
17536 (pupa_refresh): New function.
17537 * normal/normal.c (pupa_normal_init) [PUPA_UTIL]: New function.
17538 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
17539 * util/console.c: New file.
17540
17541 * util/i386/pc/getroot.c: New file.
17542 * util/i386/pc/pupa-setup.c: Include <pupa/util/getroot.h>.
17543 (pupa_putchar): New function.
17544 (pupa_refresh): Likewise.
17545 (xgetcwd): Function moved to ...
17546 (strip_extra_slashes): Likewise.
17547 (get_prefix): Likewise.
17548 * util/i386/pc/getroot.c: ... here.
17549 (find_root_device): Function moved and renamed to...
17550 * util/i386/pc/getroot.c (pupa_find_root_device): ... here.
17551 Changed all callers.
17552 * util/i386/pc/pupa-setup.c (guess_root_device): Function moved
17553 and renamed to...
17554 * util/i386/pc/getroot.c (pupa_guess_root_device): ... here.
17555 Changed all callers.
17556 * util/misc.c (pupa_memalign): New function.
17557 (pupa_mm_init_region): Likewise.
17558 (pupa_register_exported_symbols): Likewise.
17559 (pupa_putchar): Function removed.
17560 * util/pupa-emu.c: New file.
17561
17562 2003-11-16 Jeroen Dekkers <jeroen@dekkers.cx>
17563
17564 * conf/i386-pc.rmk (pkgdata_MODULES): Add _multiboot.mod.
17565 (_multiboot_mod_SOURCES): New variable.
17566 (_multiboot_mod_CFLAGS): Likewise.
17567 * loader/i386/pc/multiboot.c: New file.
17568 * include/pupa/i386/pc/multiboot.h: Likewise.
17569 * kern/i386/pc/startup.S: Include pupa/machine/multiboot.h.
17570 (pupa_multiboot_real_boot): New function.
17571 * include/pupa/i386/pc/loader.h: Include pupa/machine/multiboot.h.
17572 (pupa_multiboot_real_boot): New prototype.
17573 (pupa_rescue_cmd_multiboot): Likewise
17574 (pupa_rescue_cmd_module): Likewise.
17575
17576 * kern/loader.c (pupa_loader_set): Continue when
17577 pupa_loader_unload_func() fails.
17578 (pupa_loader_unset): New function.
17579 * include/pupa/loader.h (pupa_loader_unset): New prototype.
17580
17581 * kern/misc.c (pupa_stpcpy): New function.
17582 * include/pupa/misc.h (pupa_stpcpy): New prototype.
17583
17584 2003-11-12 Marco Gerards <metgerards@student.han.nl>
17585
17586 * disk/i386/pc/biosdisk.c (pupa_biosdisk_open): Correctly check
17587 for available extensions.
17588
17589 * include/pupa/i386/pc/time.h: New file.
17590 * kern/disk.c: Include <pupa/machine/time.h>.
17591 (PUPA_CACHE_TIMEOUT): New macro.
17592 (pupa_last_time): New variable.
17593 (pupa_disk_open): Flush the cache when there was a timeout.
17594 (pupa_disk_close): Reset the timer.
17595 * kern/i386/pc/startup.S (pupa_get_rtc): Renamed from
17596 pupa_currticks.
17597 * util/misc.c: Include <sys/times.h>
17598 (pupa_get_rtc): New function.
17599
17600 2003-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
17601
17602 * fs/ext2.c (struct pupa_ext2_inode): Declare struct datablocks
17603 as blocks.
17604 (pupa_ext2_get_file_block): Use blocks member.
17605
17606 * fs/ext2.c (pupa_ext2_read_file): Only set skipfirst for the
17607 first block. Return -1 instead of pupa_errno on error.
17608
17609 2003-10-27 Marco Gerards <metgerards@student.han.nl>
17610
17611 * README: In the pupa-mkimage example use _chain instead of chain
17612 and ext2 instead of fat.
17613 * TODO: Replace ext2fs with jfs as an example. Add an item for
17614 adding journal playback for ext2fs.
17615 * conf/i386-pc.rmk (pupa_setup_SOURCES): Added fs/ext2.c.
17616 (pkgdata_MODULES): Added ext2.mod.
17617 (ext2_mod_SOURCES): New variable.
17618 (ext2_mod_CFLAGS): Likewise.
17619 * include/pupa/err.h (pupa_err_t): Added PUPA_ERR_SYMLINK_LOOP.
17620 * include/pupa/misc.h (pupa_strncpy): New prototype.
17621 (pupa_strcat): Likewise.
17622 (pupa_strncmp): Likewise.
17623 * kern/misc.c (pupa_strcat): Enable function.
17624 (pupa_strncpy): New function.
17625 (pupa_strncmp): Likewise.
17626 * fs/ext2.c: New file.
17627
17628 * kern/disk.c (pupa_disk_read): Set pupa_errno to PUPA_ERR_NONE
17629 when the read failed before retrying.
17630 * util/i386/pc/biosdisk.c (_LARGEFILE_SOURCE): Removed.
17631 (_FILE_OFFSET_BITS): Likewise.
17632 * configure.ac: Added AC_SYS_LARGEFILE.
17633
17634 2003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
17635
17636 * genmk.rb (PModule#rule): Make sure to get only symbol names
17637 from the output of nm.
17638 Reported by Robert Millan <zeratul2@wanadoo.es>.
17639
17640 2003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
17641
17642 I forgot to check in these changes for a long time. This adds
17643 incomplete support for VGA console, and this is still very
17644 buggy. Also, a lot of consideration is required for I18N,
17645 UNICODE, and VGA font issues. Therefore, assume that this is
17646 such that "better than nothing".
17647
17648 * font/manager.c: New file.
17649 * include/pupa/font.h: Likewise.
17650 * include/pupa/i386/pc/vga.h: Likewise.
17651 * term/i386/pc/vga.c: Likewise.
17652 * util/unifont2pff.rb: Likewise.
17653
17654 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vga.h.
17655 (pkgdata_MODULES): Added vga.mod and font.mod.
17656 (vga_mod_SOURCES): New variables.
17657 (vga_mod_CFLAGS): Likewise.
17658 (font_mod_SOURCES): Likewise.
17659 (font_mod_CFLAGS): Likewise.
17660
17661 * include/pupa/err.h (PUPA_ERR_BAD_FONT): New constant.
17662
17663 * include/pupa/term.h: Include pupa/err.h.
17664 (struct pupa_term): Added init and fini.
17665 Changed the argument of putchar to pupa_uint32_t.
17666
17667 * include/pupa/i386/pc/console.h: Include pupa/symbol.h.
17668 (pupa_console_real_putchar): New prototype.
17669 (pupa_console_putchar): Removed.
17670 (pupa_console_checkkey): Exported.
17671 (pupa_console_getkey): Likewise.
17672
17673 * kern/misc.c (pupa_vsprintf): Add support for UNICODE
17674 characters.
17675
17676 * kern/term.c (pupa_term_set_current): Rewritten.
17677 (pupa_putchar): Likewise.
17678 (pupa_putcode): New function.
17679
17680 * kern/i386/pc/startup.S (pupa_console_putchar): Renamed to ...
17681 (pupa_console_real_putchar): ... this.
17682 (pupa_vga_set_mode): New function.
17683 (pupa_vga_get_font): Likewise.
17684
17685 * normal/command.c: Include pupa/term.h.
17686 (terminal_command): New function.
17687 (pupa_command_init): Register the command "terminal".
17688
17689 * normal/menu.c (DISP_LEFT): Changed to a UNICODE value.
17690 (DISP_UP): Likewise.
17691 (DISP_RIGHT): Likewise.
17692 (DISP_DOWN): Likewise.
17693 (DISP_HLINE): Likewise.
17694 (DISP_VLINE): Likewise.
17695 (DISP_UL): Likewise.
17696 (DISP_UR): Likewise.
17697 (DISP_LL): Likewise.
17698 (DISP_LR): Likewise.
17699
17700 * term/i386/pc/console.c (pupa_console_putchar): New function.
17701
17702 2003-02-08 NIIBE Yutaka <gniibe@m17n.org>
17703
17704 * util/resolve.c (pupa_util_resolve_dependencies): BUG
17705 FIX. Reverse the path_list.
17706
17707 * include/pupa/normal.h: Export pupa_register_command and
17708 pupa_unregister_command.
17709
17710 * hello/hello.c (pupa_cmd_hello): New module.
17711 * conf/i386-pc.rmk: Added hello.mod.
17712
17713 2003-01-31 Yoshinori K. Okuji <okuji@enbug.org>
17714
17715 * kern/i386/pc/lzo1x.S: New file.
17716
17717 * util/i386/pc/pupa-mkimage.c: Include lzo1x.h.
17718 (compress_kernel): New variable.
17719 (generate_image): Heavily modified to support compressing a
17720 large part of the core image.
17721
17722 * util/misc.c (pupa_util_read_image): Fix a file descriptor
17723 leak.
17724 (pupa_util_load_image): New function.
17725
17726 * kern/i386/pc/startup.S: Include pupa/machine/kernel.h.
17727 (pupa_compressed_size): New variable.
17728 (codestart): Enable Gate A20 here.
17729 Decompress the compressed part of the core image.
17730 Rearrange the code to put functions and variables which are
17731 required for initialization in the non-compressed part.
17732 Include lzo1x.S.
17733
17734 * kern/i386/pc/init.c (pupa_machine_init): Don't enable Gate A20
17735 here.
17736
17737 * include/pupa/util/misc.h (pupa_util_write_image): Declared.
17738
17739 * include/pupa/i386/pc/kernel.h
17740 (PUPA_KERNEL_MACHINE_COMPRESSED_SIZE): New macro.
17741 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): Increased by 4.
17742 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
17743 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
17744 (PUPA_KERNEL_MACHINE_RAW_SIZE): New macro.
17745
17746 * conf/i386-pc.rmk (pupa_mkimage_LDFLAGS): New variable.
17747
17748 * genmk.rb (Image#rule): Put LDFLAGS at the end of a line.
17749 (Utility#rule): Likewise.
17750
17751 * configure.ac: Check if LZO is available.
17752
17753 2003-01-20 Yoshinori K. Okuji <okuji@enbug.org>
17754
17755 * include/pupa/normal.h: New file.
17756 * include/pupa/setjmp.h: Likewise.
17757 * include/pupa/i386/setjmp.h: Likewise.
17758 * normal/cmdline.c: Likewise.
17759 * normal/command.c: Likewise.
17760 * normal/main.c: Likewise.
17761 * normal/menu.c: Likewise.
17762 * normal/i386/setjmp.S: Likewise.
17763
17764 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Made global.
17765 (pupa_rescue_cmd_initrd): Likewise.
17766
17767 * loader/i386/pc/chainloader.c (pupa_rescue_cmd_chainloader):
17768 Likewise.
17769
17770 * kern/i386/pc/startup.S (translation_table): New variable.
17771 (translate_keycode): New function.
17772 (pupa_console_getkey): Call translate_keycode.
17773
17774 * kern/rescue.c (attempt_normal_mode): New function.
17775 (pupa_enter_rescue_mode): Attempt to execute the normal mode. If
17776 it failed, print a message.
17777
17778 * kern/mm.c (pupa_real_malloc): Print more information when a
17779 free magic is broken.
17780 (pupa_free): If the first free header is not free actually, set
17781 it to P.
17782
17783 * kern/main.c (pupa_load_normal_mode): Just load the module
17784 "normal".
17785 (pupa_main): Don't print the message
17786 "Entering into rescue mode..." here.
17787
17788 * include/pupa/i386/pc/loader.h (pupa_rescue_cmd_initrd):
17789 Declared.
17790 (pupa_rescue_cmd_initrd): Likewise.
17791 (pupa_rescue_cmd_initrd): Likewise.
17792
17793 * include/pupa/symbol.h (FUNCTION): Specify the type.
17794 (VARIABLE): Likewise.
17795
17796 * include/pupa/err.h (pupa_err_t): Added
17797 PUPA_ERR_UNKNOWN_COMMAND.
17798
17799 * include/pupa/dl.h (pupa_dl_set_prefix): Exported.
17800 (pupa_dl_get_prefix): Likewise.
17801
17802 * conf/i386-pc.rmk (pkgdata_MODULES): Added normal.mod.
17803 Added _chain.mod and _linux.mod instead of chain.mod and
17804 linux.mod.
17805 (chain_mod_SOURCES): Renamed to ...
17806 (_chain_mod_SOURCES): ... this.
17807 (chain_mod_CFLAGS): Renamed to ...
17808 (_chain_mod_CFLAGS): ... this.
17809 (linux_mod_SOURCES): Renamed to ...
17810 (_linux_mod_SOURCES): ... this.
17811 (linux_mod_CFLAGS): Renamed to ...
17812 (_linux_mod_CFLAGS): ... this.
17813 (normal_mod_SOURCES): New variable.
17814 (normal_mod_CFLAGS): Likewise.
17815 (normal_mod_ASFLAGS): Likewise.
17816
17817 2003-01-18 Yoshinori K. Okuji <okuji@enbug.org>
17818
17819 * kern/rescue.c (pupa_rescue_cmd_rmmod): Call pupa_dl_unload, if
17820 possible.
17821
17822 * kern/dl.c (pupa_dl_ref): Refer depending modules
17823 recursively.
17824 (pupa_dl_unref): Unrefer depending modules recursively.
17825 Don't call pupa_dl_unload implicitly, because PUPA can crash if
17826 a module is unloaded before one depending on that module is
17827 unloaded.
17828 (pupa_dl_unload): Unload depending modules explicitly,
17829 if possible.
17830
17831 2003-01-17 Yoshinori K. Okuji <okuji@enbug.org>
17832
17833 * include/pupa/i386/pc/linux.h: New file.
17834 * loader/i386/pc/linux.c: Likewise.
17835
17836 * loader/i386/pc/chainloader.c (pupa_chainloader_boot_sector):
17837 Removed.
17838 (pupa_chainloader_unload): Return PUPA_ERR_NONE.
17839 (pupa_rescue_cmd_chainloader): Read the image to 0x7C00 instead
17840 of PUPA_CHAINLOADER_BOOT_SECTOR.
17841
17842 * kern/i386/pc/startup.S: Include pupa/machine/linux.h.
17843 (pupa_linux_prot_size): New variable.
17844 (pupa_linux_tmp_addr): Likewise.
17845 (pupa_linux_real_addr): Likewise.
17846 (pupa_linux_boot_zimage): New function.
17847 (pupa_linux_boot_bzimage): Likewise.
17848
17849 * kern/i386/pc/init.c (struct mem_region): New structure.
17850 (MAX_REGIONS): New macro.
17851 (mem_regions): New variable.
17852 (num_regions): Likewise.
17853 (pupa_os_area_addr): Likewise.
17854 (pupa_os_area_size): Likewise.
17855 (pupa_lower_mem): Likewise.
17856 (pupa_upper_mem): Likewise.
17857 (add_mem_region): New function.
17858 (compact_mem_regions): Likewise.
17859 (pupa_machine_init): Set PUPA_LOWER_MEM and PUPA_UPPER_MEM to
17860 the size of the conventional memory and that of so-called upper
17861 memory (before the first memory hole).
17862 Instead of adding each found region to free memory, use
17863 add_mem_region and add them after removing overlaps.
17864 Also, add only 1/4 of the upper memory to free memory. The rest
17865 is used for loading OS images. Maybe this is ad hoc, but this
17866 makes it much easier to relocate OS images when booting.
17867
17868 * kern/rescue.c (pupa_rescue_cmd_module): Removed.
17869 (pupa_enter_rescue_mode): Don't register initrd and module.
17870
17871 * kern/mm.c: Include pupa/dl.h.
17872
17873 * kern/main.c: Include pupa/file.h and pupa/device.h.
17874
17875 * kern/loader.c (pupa_loader_load_module_func): Removed.
17876 (pupa_loader_load_module): Likewise.
17877
17878 * kern/dl.c (pupa_dl_load): Use the suffix ``.mod'' instead of
17879 ``.o''.
17880
17881 * include/pupa/i386/pc/loader.h (pupa_linux_prot_size): Declared.
17882 (pupa_linux_tmp_addr): Likewise.
17883 (pupa_linux_real_addr): Likewise.
17884 (pupa_linux_boot_zimage): Likewise.
17885 (pupa_linux_boot_bzimage): Likewise.
17886
17887 * include/pupa/i386/pc/init.h (pupa_lower_mem): Declared.
17888 (pupa_upper_mem): Likewise.
17889 (pupa_gate_a20): Don't export, because turning off Gate A20 in a
17890 module is too dangerous.
17891
17892 * include/pupa/loader.h (pupa_os_area_addr): Declared.
17893 (pupa_os_area_size): Likewise.
17894 (pupa_loader_set): Remove the first argument. Loader doesn't
17895 manage modules or initrd any longer.
17896 (pupa_loader_load_module): Removed.
17897
17898 * conf/i386-pc.rmk (pkgdata_MODULES): Added linux.mod.
17899 (linux_mod_SOURCES): New variable.
17900 (linux_mod_CFLAGS): Likewise.
17901
17902 2003-01-07 Yoshinori K. Okuji <okuji@enbug.org>
17903
17904 * util/i386/pc/pupa-setup.c (setup): Convert the endianness of
17905 the length of a blocklist correctly.
17906
17907 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open) [__linux__]:
17908 Use ioctl only if the OS file is a block device.
17909 (pupa_util_biosdisk_open): Don't use ST.ST_BLOCKS, because it is
17910 not very useful for normal files.
17911
17912 * kern/main.c (pupa_set_root_dev): New function.
17913 (pupa_load_normal_mode): Likewise.
17914 (pupa_main): Call those above.
17915
17916 * include/pupa/types.h (pupa_swap_bytes16): Cast the result to
17917 pupa_uint16_t.
17918
17919 * include/pupa/kernel.h (pupa_enter_normal_mode): Removed.
17920
17921 2003-01-06 Yoshinori K. Okuji <okuji@enbug.org>
17922
17923 * util/i386/pc/pupa-setup.c: Include pupa/machine/kernel.h.
17924 (setup): Configure the installed partition information and the
17925 dl prefix.
17926
17927 * loader/i386/pc/chainloader.c (my_mod): New variable.
17928 (pupa_chainloader_unload): New function.
17929 (pupa_rescue_cmd_chainloader): Refer itself.
17930 (PUPA_MOD_INIT): Save its own module in MY_MOD.
17931
17932 * kern/i386/pc/startup.S (install_partition): Removed.
17933 (version_string): Likewise.
17934 (config_file): Likewise.
17935 (pupa_install_dos_part): New variable.
17936 (pupa_install_bsd_part): Likewise.
17937 (pupa_prefix): Likewise.
17938 (pupa_chainloader_real_boot): Call pupa_dl_unload_all.
17939
17940 * kern/i386/pc/init.c: Include pupa/machine/kernel.h, pupa/dl.h
17941 and pupa/misc.h.
17942 (make_install_device): New function.
17943 (pupa_machine_init): Set the dl prefix.
17944
17945 * kern/rescue.c: Include pupa/rescue.h and pupa/dl.h.
17946 (buf): Renamed to ...
17947 (linebuf): ... this.
17948 (pupa_rescue_cmd_prefix): New function.
17949 (pupa_rescue_cmd_insmod): Likewise.
17950 (pupa_rescue_cmd_rmmod): Likewise.
17951 (pupa_rescue_cmd_lsmod): Likewise.
17952 (pupa_enter_rescue_mode): Register new commands: prefix, insmod,
17953 rmmod and lsmod.
17954
17955 * kern/mm.c (pupa_memalign): If failed even after invalidating
17956 disk caches, unload unneeded modules and retry.
17957
17958 * kern/misc.c (pupa_memmove): New function.
17959 (pupa_memcpy): Removed.
17960 (pupa_strcpy): New function.
17961 (pupa_itoa): Made static.
17962
17963 * kern/dl.c (pupa_dl_iterate): New function.
17964 (pupa_dl_ref): Likewise.
17965 (pupa_dl_unref): Likewise.
17966 (pupa_dl_unload): Return if succeeded or not.
17967 (pupa_dl_unload_unneeded): New function.
17968 (pupa_dl_unload_all): Likewise.
17969 (pupa_dl_init): Renamed to ...
17970 (pupa_dl_set_prefix): ... this.
17971 (pupa_dl_get_prefix): New function.
17972
17973 * include/pupa/i386/pc/kernel.h: Include pupa/types.h.
17974 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): New macro.
17975 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
17976 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
17977 (pupa_install_dos_part): Declared.
17978 (pupa_install_bsd_part): Likewise.
17979 (pupa_prefix): Likewise.
17980 (pupa_boot_drive): Likewise.
17981
17982 * include/pupa/types.h: Fix a typo.
17983
17984 * include/pupa/misc.h (pupa_memcpy): New macro. Just an alias to
17985 pupa_memmove.
17986 (pupa_memmove): Declared.
17987 (pupa_strcpy): Likewise.
17988
17989 * include/pupa/dl.h (PUPA_MOD_INIT): Change the prototype. Now
17990 pupa_mod_init takes one argument, its own module.
17991 (pupa_dl_unload_unneeded): Declared.
17992 (pupa_dl_unload_all): Likewise.
17993 (pupa_dl_ref): Likewise.
17994 (pupa_dl_unref): Likewise.
17995 (pupa_dl_iterate): Likewise.
17996 (pupa_dl_init): Renamed to ...
17997 (pupa_dl_set_prefix): ... this.
17998 (pupa_dl_get_prefix): Declared.
17999
18000 * fs/fat.c [!PUPA_UTIL] (my_mod): New variable.
18001 (pupa_fat_dir) [!PUPA_UTIL]: Prevent the fat module from being
18002 unloaded.
18003 (pupa_fat_open) [!PUPA_UTIL]: Refer itself if succeeded.
18004 (pupa_fat_close) [!PUPA_UTIL]: Unrefer itself.
18005
18006 * configure.ac (tmp_CFLAGS): Added -Wshadow, -Wpointer-arith,
18007 -Wmissing-prototypes, -Wundef and -Wstrict-prototypes.
18008
18009 2003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
18010
18011 * util/i386/pc/pupa-setup.c (setup): Define the internal
18012 function find_first_partition_start at the top level, because GCC
18013 3.0.x cannot compile internal functions in deeper scopes
18014 correctly.
18015 (find_root_device): Use lstat instead of stat.
18016 Don't follow symbolic links.
18017 Fix the path-constructing code.
18018
18019 * util/i386/pc/biosdisk.c [__linux__] (BLKFLSBUF): New macro.
18020 (pupa_util_biosdisk_open) [__linux__]: Get the size of a device
18021 by a BLKGETSIZE ioctl first, because block devices don't fill
18022 the member st_mode of the structure stat on Linux.
18023 [__linux__] (linux_find_partition): Use a temporary buffer
18024 REAL_DEV for the working space. Copy it to DEV before returning.
18025 (open_device) [__linux__]: Call ioctl with BLKFLSBUF to make the
18026 buffer cache consistent.
18027 (get_os_disk) [__linux__]: Use the length 5 instead of 4 for
18028 strncmp. The previous value was merely wrong.
18029 (pupa_util_biosdisk_get_pupa_dev): Use stat instead of lstat.
18030
18031 * fs/fat.c (pupa_fat_read_data): Shift 4 instead of 12 when the
18032 FAT size is 12. The previous value was merely wrong.
18033
18034 * kern/main.c (pupa_main): Don't split the starting message from
18035 newlines.
18036
18037 * kern/term.c (pupa_putchar): Put CR after LF instead of before
18038 LF, because BIOS goes crazy about character attributes in this
18039 case.
18040
18041 2003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
18042
18043 * include/i386/pc/util/biosdisk.h: New file.
18044 * util/i386/pc/biosdisk.c: Likewise.
18045 * util/i386/pc/pupa-setup.c: Likewise.
18046
18047 * Makefile.in (INCLUDE_DISTFILES): Added
18048 include/pupa/i386/pc/util/biosdisk.h.
18049 (UTIL_DISTFILES): Added biosdisk.c and pupa-setup.c under the
18050 directory util/i386/pc.
18051 (install-local): Added a rule for sbin_UTILITIES.
18052 (uninstall): Likewise.
18053
18054 * util/i386/pc/pupa-mkimage.c (usage): Fix a typo in the doc.
18055
18056 * util/misc.c (xrealloc): New function.
18057 (pupa_malloc): Likewise.
18058 (pupa_free): Likewise.
18059 (pupa_realloc): Likewise.
18060 (pupa_stop): Likewise.
18061 (pupa_putchar): Likewise.
18062
18063 * kern/disk.c (pupa_disk_read): Prevent L from underflowing.
18064
18065 * include/pupa/util/misc.h (xrealloc): Declared.
18066
18067 * include/pupa/i386/pc/boot.h (PUPA_BOOT_MACHINE_BPB_START): New
18068 macro.
18069 (PUPA_BOOT_MACHINE_BPBEND): Renamed to ...
18070 (PUPA_BOOT_MACHINE_BPB_END): ... this.
18071
18072 * include/pupa/fs.h [PUPA_UTIL] (pupa_fat_init): Declared.
18073 [PUPA_UTIL] (pupa_fat_fini): Likewise.
18074
18075 * fs/fat.c [PUPA_UTIL] (pupa_fat_init): Defined. Maybe a better
18076 way should be implemented.
18077 [PUPA_UTIL] (pupa_fat_fini): Likewise.
18078
18079 * disk/i386/pc/biosdisk.c (pupa_biosdisk_call_hook): Increase
18080 the size of NAME for safety.
18081 (pupa_biosdisk_iterate): Search hard disks to 0x90 instead of
18082 0x88.
18083
18084 * conf/i386-pc.rmk (sbin_UTILITIES): New variable.
18085 (pupa_setup_SOURCES): Likewise.
18086
18087 * genmk.rb (Utility#rule): Add $(BUILD_CFLAGS) into the rules.
18088
18089 2002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
18090
18091 * kern/i386/pc/startup.S (push_get_mmap_entry): Revert to a
18092 bunch of pushl's from pusha, because this destroys the return
18093 value.
18094
18095 2002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
18096
18097 Use -mrtd and -mregparm=3 to reduce the generated code sizes.
18098 This means that any missing prototypes could be fatal. Also, you
18099 must take care when writing assembly code. See the comments at
18100 the beginning of startup.S, for more details.
18101
18102 * kern/i386/pc/startup.S (pupa_halt): Modified for the new
18103 compilation mechanism.
18104 (pupa_chainloader_real_boot): Likewise.
18105 (pupa_biosdisk_rw_int13_extensions): Likewise.
18106 (pupa_biosdisk_rw_standard): Likewise.
18107 (pupa_biosdisk_check_int13_extensions): Likewise.
18108 (pupa_biosdisk_get_diskinfo_int13_extensions): Likewise.
18109 (pupa_biosdisk_get_diskinfo_standard): Likewise.
18110 (pupa_get_memsize): Likewise.
18111 (pupa_get_mmap_entry): Likewise.
18112 (pupa_console_putchar): Likewise.
18113 (pupa_console_setcursor): Likewise.
18114 (pupa_getrtsecs): Use pushl instead of push.
18115
18116 * kern/i386/pc/init.c (pupa_machine_init): Use the scratch
18117 memory instead of the stack for a mmap entry, because some
18118 BIOSes may ignore the maximum size and overflow.
18119
18120 * conf/i386-pc.rmk (COMMON_CFLAGS): Added -mrtd and -mregparm=3.
18121
18122 * genmk.rb (PModule#rule): Compile automatically generated
18123 sources with module-specific CFLAGS as well as other sources.
18124
18125 2002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
18126
18127 * configure.ac: Check ld.
18128 Replace CFLAGS and CPPFLAGS with BUILD_CFLAGS and BUILD_CPPFLAGS
18129 respectively, before checking endianness and sizes.
18130
18131 * Makefile.in (LD): New variable.
18132
18133 2002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
18134
18135 * Makefile.in (BUILD_CC): CC -> BUILD_CC.
18136
18137 2002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
18138
18139 * Changelog: New file.
18140