]> git.proxmox.com Git - grub2.git/blob - ChangeLog
2009-04-11 Andrey Shuvikov <mr_hyro@yahoo.com>
[grub2.git] / ChangeLog
1 2009-04-11 Andrey Shuvikov <mr_hyro@yahoo.com>
2
3 * util/hostdisk.c [__FreeBSD__]: Include sys/disk.h.
4 (grub_util_biosdisk_open) [__FreeBSD__]: Add support for
5 FreeBSD. Check if a device is a character device. Use
6 DIOCGMEDIASIZE to get the size.
7 (convert_system_partition_to_system_disk) [__FreeBSD__]: Add
8 support for FreeBSD.
9 (grub_util_biosdisk_get_grub_dev) [__FreeBSD__]: Check if OS_DEV
10 is a character device instead of a block device. Add support for
11 FreeBSD device names.
12
13 * util/getroot.c (find_root_device) [__FreeBSD__]: Check if ENT is
14 a character device instead of a block device.
15 (grub_util_check_char_device): New function.
16
17 * util/grub-probe.c (probe) [__FreeBSD__]: Check if DEVICE_NAME is
18 a character device instead of a block device.
19
20 * include/grub/util/getroot.h (grub_util_check_char_device): New
21 prototype.
22
23 2009-04-11 David S. Miller <davem@davemloft.net>
24
25 * conf/sparc64-ieee1275.rmk (kernel_img_LDFLAGS): Link with
26 static libgcc.
27 * configure.ac: Check for __bswapsi2 and __bswapdi2 presence.
28 * include/grub/sparc64/libgcc.h (__bswapsi2): Export libgcc
29 function, if present.
30 (__bswapdi2): Likewise.
31
32 * include/grub/sparc64/ieee1275/boot.h: New file.
33 * boot/sparc64/ieee1275/boot.S: Likewise.
34 * boot/sparc64/ieee1275/diskboot.S: Likewise.
35
36 2009-04-10 David S. Miller <davem@davemloft.net>
37
38 * disk/ieee1275/nand.c (grub_nand_open): All ieee1275 call arg
39 slots are of type grub_ieee1275_cell_t.
40 (grub_nand_read): Likewise.
41 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_INVALID,
42 IEEE1275_IHANDLE_INVALID): Use grub_ieee1275_cell_t since these
43 macros are used to compare values in arg/ret block of the call.
44 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
45 grub_ieee1275_next_property, grub_ieee1275_get_property_length,
46 grub_ieee1275_instance_to_package, grub_ieee1275_package_to_path,
47 grub_ieee1275_instance_to_path, grub_ieee1275_write,
48 grub_ieee1275_read, grub_ieee1275_seek, grub_ieee1275_peer,
49 grub_ieee1275_child, grub_ieee1275_parent, grub_ieee1275_open,
50 grub_ieee1275_close, grub_ieee1275_set_property,
51 grub_ieee1275_set_color): All ieee1275 call arg slots are of type
52 grub_ieee1275_cell_t.
53 * kern/ieee1275/openfw.c (grub_map): Likewise.
54 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_ihandle_t,
55 grub_ieee1275_phandle_t): Define as grub_unit32_t type.
56
57 * kern/ieee1275/init.c (grub_machine_init): Make 'actual' grub_ssize_t.
58 * kern/ieee1275/openfw.c (grub_children_iterate): Likewise.
59 (grub_devalias_iterate): Likewise.
60
61 2009-04-10 Vladimir Serbinenko <phcoder@gmail.com>
62
63 UFS improvements
64
65 * fs/ufs.c (INODE_NBLOCKS): new definition
66 (struct grub_ufs_dirent): added fields for non-BSD dirents
67 (grub_ufs_get_file_block): fixed double indirect handling
68 (grub_ufs_lookup_symlink): use more robust way to determine whether
69 symlink is inline
70 (grub_ufs_find_file): support for non-BSD dirents
71 (grub_ufs_dir): support for non-BSD dirents
72
73 2009-04-10 Bean <bean123ch@gnail.com>
74
75 * include/grub/efi/api.h (grub_efi_configuration_table): Add packed
76 attribute, otherwise the size would be wrong for i386 platform.
77
78 * include/grub/pci.h (grub_pci_read_word): New inline function.
79 (grub_pci_read_byte): Likewise.
80 (grub_pci_write): Likewise.
81 (grub_pci_write_word): Likewise.
82 (grub_pci_write_byte): Likewise.
83
84 * include/grub/pci.h (grub_pci_iteratefunc_t): Add NESTED_FUNC_ATTR.
85
86 * loader/i386/efi/linux.c (fake_bios_data): Moved to loadbios module.
87 (find_framebuf): Scan pci to locate the frame buffer address.
88
89 * commands/efi/fixvideo.c: New file.
90
91 * commands/efi/loadbios.c: Likewise.
92
93 * commands/memrw.c: Likewise.
94
95 * util/grub-dumpbios.in: Likewise.
96
97 * conf/common.rmk (grub-dumpbios): New utility.
98 (pkglib_MODULES): New module memrw.mod.
99 (memrw_mod_SOURCE): New macro.
100 (memrw_mod_CFLAGS): Likewise.
101 (memrw_mod_LDFLAGS): Likewise.
102
103 * conf/i386-efi.rmk (pkglig_MODULES): New module loadbios.mod and
104 fixvideo.mod.
105 (loadbios_mod_SOURCE): New macro.
106 (loadbios_mod_CFLAGS): Likewise.
107 (loadbios_mod_LDFLAGS): Likewise.
108 (fixvideo_mod_SOURCE): Likewise.
109 (fixvideo_mod_CFLAGS): Likewise.
110 (fixvideo_mod_LDFLAGS): Likewise.
111
112 * conf/x86_64.rmk (pkglig_MODULES): New module loadbios.mod and
113 fixvideo.mod.
114 (loadbios_mod_SOURCE): New macro.
115 (loadbios_mod_CFLAGS): Likewise.
116 (loadbios_mod_LDFLAGS): Likewise.
117 (fixvideo_mod_SOURCE): Likewise.
118 (fixvideo_mod_CFLAGS): Likewise.
119 (fixvideo_mod_LDFLAGS): Likewise.
120
121 2009-04-08 Felix Zielcke <fzielcke@z-51.de>
122
123 * disk/lvm.c (grub_lvm_scan_device): Add a missing NULL check.
124
125 2009-04-07 David S. Miller <davem@davemloft.net>
126
127 * kern/sparc64/dl.c (grub_arch_dl_relocate_symbols): Add
128 support for R_SPARC_OLO10 relocations. Fix compile warning for
129 R_SPARC_WDISP30 case.
130 * kern/sparc64/cache.S: Fix grub_arch_sync_caches implementation.
131
132 2009-04-06 Pavel Roskin <proski@gnu.org>
133
134 * include/grub/misc.h (ARRAY_SIZE): New macro.
135 * include/grub/i386/linux.h (GRUB_LINUX_VID_MODE_VESA_START):
136 New macro.
137 * loader/i386/linux.c (allocate_pages): Use free_pages().
138 (grub_linux_unload): Don't use free_pages().
139 (grub_linux_boot): Prevent accessing linux_vesafb_modes with a
140 wrong index. Treat all other modes as text modes.
141 (grub_cmd_linux): Initialize vid_mode unconditionally to
142 GRUB_LINUX_VID_MODE_NORMAL. Recognize and support "vga=ask".
143
144 * commands/help.c (print_command_help): Use cmd->prio, not
145 cmd->flags to check for GRUB_PRIO_LIST_FLAG_ACTIVE.
146
147 2009-04-06 Vladimir Serbinenko <phcoder@gmail.com>
148
149 Parttool
150
151 * parttool/pcpart.c: new file
152 * commands/parttool.c: likewise
153 * conf/common.rmk (pkglib_MODULES): Added parttool.mod and pcpart.mod
154 (parttool_mod_SOURCES): new variable
155 (parttool_mod_CFLAGS): likewise
156 (parttool_mod_LDFLAGS): likewise
157 (pcpart_mod_SOURCES): likewise
158 (pcpart_mod_CFLAGS): likewise
159 (pcpart_mod_LDFLAGS): likewise
160 * conf/i386-coreboot.rmk (grub_emu_SOURCES): added commands/parttool.c
161 and parttool/pcpart.c
162 * conf/i386-efi.rmk: likewise
163 * conf/i386-ieee1275.rmk: likewise
164 * conf/i386-pc.rmk: likewise
165 * conf/powerpc-ieee1275.rmk: likewise
166 * conf/sparc64-ieee1275.rmk: likewise
167 * conf/x86_64-ieee1275.rmk: likewise
168
169 2009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
170
171 Support for mtime and further expandability of dir command
172
173 * include/grub/lib/datetime.h: moved to ...
174 * include/grub/datetime.h: ... moved here and added
175 declaration of grub_unixtime2datetime. All users updated
176 * include/grub/fs.h: new syntax for dir and mtime functionin
177 struct grub_fs
178 * include/grub/fshelp.h: new declarations of GRUB_FSHELP_TYPE_MASK
179 and GRUB_FSHELP_FLAGS_MASK
180 * commands/ls.c (grub_ls_list_files): Write mtime in long format
181 * fs/ext2.c (grub_ext2_dir): use new dir syntax and supply mtime
182 (grub_ext2_mtime): new function
183 * fs/hfsplus.c (grub_hfsplus_dir): use new dir syntax and supply mtime
184 (grub_hfsplus_mtime): new function
185 * fs/ufs.c (GRUB_UFS_ATTR_TYPE): new definition
186 (GRUB_UFS_ATTR_FILE): likewise
187 (GRUB_UFS_ATTR_LNK): likewise
188 (struct grub_ufs_sblock): new fields mtime
189 (grub_ufs_read_inode): new parameter to read inode to a separate buffer
190 all users updated
191 (grub_ufs_dir): mtime support
192 (grub_ufs_mtime): new function
193 * fs/affs.c (grub_affs_dir): use new dir syntax
194 * fs/afs.c (grub_afs_dir): likewise
195 * fs/cpio.c (grub_cpio_dir): likewise
196 * fs/fat.c (grub_fat_find_dir): likewise
197 * fs/hfs.c (grub_hfs_dir): likewise
198 * fs/iso9660.c (grub_iso9660_dir): likewise
199 * fs/jfs.c (grub_jfs_dir): likewise
200 * fs/minix.c (grub_minix_dir): likewise
201 * fs/ntfs.c (grub_ntfs_dir): likewise
202 * fs/reiserfs.c (grub_reiserfs_dir): likewise
203 * fs/sfs.c (grub_sfs_dir): likewise
204 * fs/xfs.c (grub_xfs_dir): likewise
205 * util/hostfs.c (grub_hostfs_dir): likewise
206 * lib/datetime.c: moved to ...
207 * normal/datetime.c: ... moved here
208 (grub_unixtime2datetime): new function
209 * kern/rescue.c (grub_rescue_print_files): use new dir syntax
210 * normal/completition.c (iterate_dir): use new dir syntax
211 * normal/misc.c (grub_normal_print_device_info): tell the
212 last modification time of a volume
213 * kern/fs.c (grub_fs_probe): updated dummy function to use new syntax
214 * conf/common.rmk: added lib/datetime.c to ls.mod
215 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add normal/datetime.c
216 (normal_mod_SOURCES): likewise
217 (datetime_mod_SOURCES): Removed lib/datetime.c
218 * conf/i386-efi.rmk: likewise
219 * conf/i386-ieee1275.rmk: likewise
220 * conf/i386-pc.rmk: likewise
221 * conf/powerpc-ieee1275.rmk: likewise
222 * conf/sparc64-ieee1275.rmk: likewise
223 * conf/x86_64-efi.rmk: likewise
224
225 2009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
226
227 Trim trailing spaces in FAT label and support mtools-like labels
228
229 * fs/fat.c (grub_fat_iterate_dir): New function based
230 on grub_fat_find_dir
231 (grub_fat_find_dir): use grub_fat_iterate_dir
232 (grub_fat_label): likewise
233
234 2009-04-04 Vladimir Serbinenko <phcoder@gmail.com>
235
236 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): add list.h
237 and command.h
238 remove extraneous kernel_elf_HEADERS
239
240 2009-04-04 Bean <bean123ch@gnail.com>
241
242 * include/grub/util/misc.h: Add dummy function fsync for mingw.
243
244 * util/misc.c: Likewise.
245
246 2009-04-04 Yoshinori K. Okuji <okuji@enbug.org>
247
248 * loader/i386/efi/linux.c (fake_bios_data): Use grub_dprintf
249 instead of grub_printf.
250
251 2009-04-03 Robert Millan <rmh@aybabtu.com>
252
253 * loader/i386/linux.c (grub_linux_setup_video): Fill
254 `params->{red,green,blue,reserved}_{mask_size,field_pos}' with
255 values from `mode info' structure instead of hardcoded
256 values.
257
258 2009-04-01 Pavel Roskin <proski@gnu.org>
259
260 * Makefile.in: Remove all references to MODULE_LDFLAGS, it's
261 unused now.
262 * genmk.rb: Likewise.
263 * configure.ac: Likewise.
264
265 2009-04-01 Manoel Abranches <mrabran@linux.vnet.ibm.com>
266
267 * aclocal.m4: Move --build-id=none from MODULE_LDFLAGS to
268 TARGET_LDFLAGS. This corrects a problem with grub-mkelfimage.
269
270 2009-04-01 David S. Miller <davem@davemloft.net>
271
272 * normal/sparc64/setjmp.S: Fix setjmp implementation.
273 * include/grub/sparc64/setjmp.h (grub_jmp_buf): Update.
274 (grub_setjmp): Mark with 'returns_twice' attribute.
275 * include/grub/i386/setjmp.h (grub_setjmp): Likewise
276 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise.
277 * include/grub/x86_64/setjmp.h (grub_setjmp): Likewise.
278
279 2009-04-01 Robert Millan <rmh@aybabtu.com>
280
281 Reapply fix from 2008-07-28 which was accidentally reverted; also
282 perform the same fix to a similar check in same function.
283
284 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
285 with the same number are found, just use issue a warning with
286 grub_dprintf(), as this error has been reported to be non-fatal.
287
288 2009-03-31 Pavel Roskin <proski@gnu.org>
289
290 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Provide safe default
291 for cross-compilation.
292
293 2009-03-30 Robert Millan <rmh@aybabtu.com>
294
295 Fix i386-ieee1275 build.
296
297 * include/grub/i386/ieee1275/loader.h (grub_multiboot2_real_boot):
298 Remove declaration.
299
300 2009-03-30 Pavel Roskin <proski@gnu.org>
301
302 * fs/hfs.c (grub_hfs_strncasecmp): Integrate into ...
303 (grub_hfs_cmp_catkeys): ... this. Don't assume strings to be
304 zero-terminated, rely only on the strlen value. Fix comparison
305 of strings differing in length.
306
307 2009-03-30 Robert Millan <rmh@aybabtu.com>
308
309 * loader/i386/linux.c (grub_cmd_linux): Check for zImage before
310 checking for abi version. Improve error messages on BIOS to notify
311 user about `linux16' command.
312
313 2009-03-29 Vladimir Serbinenko <phcoder@gmail.com>
314
315 Leak fixes
316
317 * kern/disk.c (grub_disk_cache_store): Invalidate previous cache
318 in case of collision
319 * disk/scsi.c (grub_scsi_open): free scsi in case of error
320
321 2009-03-29 Robert Millan <rmh@aybabtu.com>
322
323 * loader/i386/linux.c (grub_cmd_linux): Parse "vga=" parameter and
324 set `vid_mode' accordingly.
325 (grub_linux_boot): Process `vid_mode' and set video mode.
326
327 2009-03-29 Robert Millan <rmh@aybabtu.com>
328
329 * util/grub.d/10_linux.in (linux_entry): New function.
330 Factorize generation of Linux boot entries.
331
332 2009-03-29 Yoshinori K. Okuji <okuji@enbug.org>
333
334 Make the format of Environment Block plain text. The boot loader
335 part is not tested well yet.
336
337 * util/grub-editenv.c (DEFAULT_ENVBLK_SIZE): New macro.
338 (buffer): Removed.
339 (envblk): Likewise.
340 (usage): Remove "info" and "clear". Add "unset". Update the
341 description of "set", as this does not delete variables any
342 longer.
343 (create_envblk_file): Complete rewrite.
344 (open_envblk_file): Likewise.
345 (cmd_info): Removed.
346 (cmd_list): Likewise.
347 (cmd_set): Likewise.
348 (cmd_clear): Likewise.
349 (list_variables): New function.
350 (write_envblk): Likewise.
351 (set_variables): Likewise.
352 (unset_variables): Likewise.
353 (main): Complete rewrite.
354
355 * commands/loadenv.c (buffer): Removed.
356 (envblk): Likewise.
357 (open_envblk_file): New function.
358 (read_envblk_file): Complete rewrite.
359 (grub_cmd_load_env): Likewise.
360 (grub_cmd_list_env): Likewise.
361 (struct blocklist): New struct.
362 (free_blocklists): New function.
363 (check_blocklists): Likewise.
364 (write_blocklists): Likewise.
365 (grub_cmd_save_env): Complete rewrite.
366
367 * include/grub/lib/envblk.h (GRUB_ENVBLK_SIGNATURE): Replaced with
368 a plain text signature.
369 (GRUB_ENVBLK_MAXLEN): Removed.
370 (struct grub_envblk): Complete rewrite.
371 (grub_envblk_find): Removed.
372 (grub_envblk_insert): Likewise.
373 (grub_envblk_open): New prototype.
374 (grub_envblk_set): Likewise.
375 (grub_envblk_delete): Put const to VALUE.
376 (grub_envblk_iterate): Put const to NAME and VALUE.
377 (grub_envblk_close): New prototype.
378 (grub_envblk_buffer): New inline function.
379 (grub_envblk_size): Likewise.
380
381 * lib/envblk.c: Include grub/mm.h.
382 (grub_env_find): Removed.
383 (grub_envblk_open): New function.
384 (grub_envblk_close): Likewise.
385 (escaped_value_len): Likewise.
386 (find_next_line): Likewise.
387 (grub_envblk_insert): Removed.
388 (grub_envblk_set): New function.
389 (grub_envblk_delete): Complete rewrite.
390 (grub_envblk_iterate): Likewise.
391
392 2009-03-28 Robert Millan <rmh@aybabtu.com>
393
394 * conf/i386-pc.rmk (pkglib_MODULES): Add `linux16.mod'.
395 (linux16_mod_SOURCES, linux16_mod_CFLAGS, linux16_mod_LDFLAGS): New
396 variables. Use 16-bit loader.
397 (linux_mod_SOURCES, linux_mod_CFLAGS, linux_mod_LDFLAGS): Use 32-bit
398 loader.
399 * kern/i386/loader.S (grub_linux_boot): Rename to ...
400 (grub_linux16_boot): ... this. Update all users.
401 * loader/i386/linux.c (grub_linux32_boot): Rename to ...
402 (grub_linux_boot): ... this. Update all users.
403
404 * loader/i386/pc/linux.c (GRUB_MOD_INIT(linux)): Rename to ...
405 (GRUB_MOD_INIT(linux16)): ... this. Rename `linux' and `initrd'
406 commands to `linux16' and `initrd16'.
407 (GRUB_MOD_FINI(linux)): Rename to ...
408 (GRUB_MOD_FINI(linux16)): ... this.
409
410 2009-03-24 Pavel Roskin <proski@gnu.org>
411
412 * genmk.rb: Define ASM_FILE for *.S files for *.lst generation,
413 not just for compilation.
414
415 2009-03-22 Vladimir Serbinenko <phcoder@gmail.com>
416
417 Move multiboot helper out of kernel
418
419 * conf/i386-pc.rmk (multiboot_mod_SOURCES): Add
420 `loader/i386/multiboot_helper.S'.
421 * conf/i386-coreboot.rmk: Likewise
422 * conf/i386-ieee1275.rmk: Likewise
423
424 * kern/i386/loader.S: Move multiboot helpers from here...
425 * loader/i386/multiboot_helper.S: ...moved here
426 * include/grub/i386/loader.h: Move declarations of multiboot
427 helpers from here...
428 * include/grub/i386/multiboot.h: ...moved here
429 * loader/i386/multiboot.c: Added include of grub/cpu/multiboot.h
430
431 2009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
432
433 * kern/env.c (grub_env_context_open): Added an argument to specify
434 whether a new context inherits exported variables from current
435 one. This is useful when making a sandbox to interpret a config
436 file.
437 All callers updated.
438
439 * include/grub/env.h (grub_env_context_open): Updated the prototype.
440
441 2009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
442
443 * kern/env.c (grub_env_context_close): Fix memory leaks.
444
445 2009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
446
447 * normal/main.c (grub_normal_execute): Added an argument
448 BATCH to specify if an interactive interface should be provided
449 after reading a config file.
450 All callers updated.
451 (read_command_list): Prevent being executed twice.
452 (read_fs_list): Likewise.
453
454 * include/grub/normal.h (grub_normal_execute): Updated the
455 prototype.
456
457 2009-03-22 Pavel Roskin <proski@gno.org>
458
459 * kern/powerpc/ieee1275/startup.S: Replace EXT_C(start) with
460 _start.
461 * kern/i386/pc/startup.S: Likewise.
462 * kern/i386/efi/startup.S: Likewise.
463 * kern/i386/ieee1275/startup.S: Likewise.
464 * kern/i386/coreboot/startup.S: Likewise.
465 * kern/x86_64/efi/startup.S: Likewise.
466
467 * aclocal.m4 (grub_CHECK_START_SYMBOL): Remove.
468 * configure.ac: Don't call grub_CHECK_START_SYMBOL.
469 * kern/i386/pc/startup.S: Use _start instead of START_SYMBOL.
470
471 2009-03-21 Vladimir Serbinenko <phcoder@gmail.com>
472
473 Bugfixes in multiboot for bugs uncovered by solaris kernel.
474
475 * loader/i386/multiboot_elfxx.c (grub_multiboot_load_elf): Corrected
476 limit detection.
477 Use vaddr of correct segment for entry_point.
478
479 2009-03-21 Bean <bean123ch@gmail.com>
480
481 * commands/blocklist.c: Add include file <grub/command.h>, remove
482 <grub/normal.h> and <grub/arg.h>.
483 (grub_cmd_blocklist): Use the new command interface.
484 (GRUB_MOD_INIT): Likewise.
485 (GRUB_MOD_FINI): Likewise.
486 * commands/boot.c: Likewise.
487 * commands/cat.c: Likewise.
488 * commands/cmp.c: Likewise.
489 * commands/configfile.c: Likewise.
490 * commands/crc.c: Likewise.
491 * commands/echo.c: Likewise.
492 * commands/halt.c: Likewise.
493 * commands/handler.c: Likewise.
494 * commands/hdparm.c: Likewise.
495 * commands/help.c: Likewise.
496 * commands/hexdump.c: Likewise.
497 * commands/loadenv.c: Likewise.
498 * commands/ls.c: Likewise.
499 * commands/lsmmap.c: Likewise.
500 * commands/lspci.c: Likewise.
501 * commands/loadenv.c: Likewise.
502 * commands/read.c: Likewise.
503 * commands/reboot.c: Likewise.
504 * commands/search.c: Likewise.
505 * commands/sleep.c: Likewise.
506 * commands/test.c: Likewise.
507 * commands/usbtest.c: Likewise.
508 * commands/videotest.c: Likewise.
509 * commands/i386/cpuid.c: Likewise.
510 * commands/i386/pc/halt.c: Likewise.
511 * commands/i386/pc/play.c: Likewise.
512 * commands/i386/pc/pxecmd.c: Likewise.
513 * commands/i386/pc/vbeinfo.c: Likewise.
514 * commands/i386/pc/vbetest.c: Likewise.
515 * commands/ieee1275/suspend.c: Likewise.
516 * disk/loopback.c: Likewise.
517 * font/font_cmd.c: Likewise.
518 * hello/hello.c: Likewise.
519 * loader/efi/appleloader.c: Likewise.
520 * loader/efi/chainloader.c: Likewise.
521 * loader/i386/bsd.c: Likewise.
522 * loader/i386/efi/linux.c: Likewise.
523 * loader/i386/ieee1275/linux.c: Likewise.
524 * loader/i386/linux.c: Likewise.
525 * loader/i386/pc/chainloader.c: Likewise.
526 * loader/i386/pc/linux.c: Likewise.
527 * loader/powerpc/ieee1275/linux.c: Likewise.
528 * loader/multiboot_loader.c: Likewise.
529 * term/gfxterm.c: Likewise.
530 * term/i386/pc/serial.c: Likewise.
531 * term/terminfo.c: Likewise.
532
533 * term/i386/pc/vesafb.c: Removed <grub/arg.h>.
534 * term/i386/pc/vga.c: Likewise.
535 * video/readers/jpeg.c: Likewise.
536 * video/readers/png.c: Likewise.
537 * video/readers/tga.c: Likewise.
538
539 * util/grub-fstest (cmd_loopback): Removed.
540 (cmd_blocklist): Likewise.
541 (cmd_ls): Likewise.
542 (grub_register_command): Likewise.
543 (grub_unregister_command): Likewise.
544 (execute_command): Use grub_command_find to locate command and execute
545 it.
546
547 * include/grub/efi/chainloader.h: Removed.
548 * loader/efi/chainloader_normal.c: Likewise.
549 * loader/i386/bsd_normal.c: Likewise.
550 * loader/i386/pc/chainloader_normal.c: Likewise.
551 * loader/i386/pc/multiboot_normal.c: Likewise.
552 * loader/linux_normal.c: Likewise.
553 * loader/multiboot_loader_normal.c: Likewise.
554 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
555
556 * gencmdlist.sh: Scan new registration command grub_register_extcmd
557 and grub_register_command_p1.
558
559 * conf/common.rmk (grub_fstest_SOURCES): Add kern/list.c,
560 kern/command.c, lib/arg.c and commands/extcmd.c.
561 (pkglib_MODULES): Remove boot.mod, and minicmd.mod and extcmd.mod.
562 (minicmd_mod_SOURCES): New variable.
563 (minicmd_mod_CFLAGS): Likewise.
564 (minicmd_mod_LDFLAGS): Likewise.
565 (extcmd_mod_SOURCES): Likewise.
566 (extcmd_mod_CFLAGS): Likewise.
567 (extcmd_mod_LDFLAGS): Likewise.
568 (boot_mod_SOURCES): Removed.
569 (boot_mod_CFLAGS): Likewise.
570 (boot_mod_LDFLAGS): Likewise.
571
572 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/command.c and
573 kern/corecmd.c.
574 (kernel_img_HEADERS): Add command.h.
575 (grub_emu_SOURCES): Remove commands/boot.c and normal/arg.c, add
576 commands/minicmd.c, kern/command.c, kern/corecmd.c, commands/extcmd.c
577 and lib/arg.c.
578 (pkglib_MODULES): Change _linux.mod, _chain.mod, _bsd.mod and
579 _multiboot.mod as linux.mod, chain.mod, bsd.mod and multiboot.mod,
580 remove the corresponding normal mode command.
581 (normal_mod_SOURCES): Remove normal/arg.c.
582 * conf/i386-coreboot.rmk: Likewise.
583 * conf/i386-efi.rmk: Likewise.
584 * conf/i386-ieee1275.rmk: Likewise.
585 * conf/powerpc-ieee1275.rmk: Likewise.
586 * conf/x86_64-efi.rmk: Likewise.
587
588 * include/grub/arg.h: Move from here ...
589 * include/grub/lib/arg.h: ... to here.
590
591 * normal/arg.c: Move from here ...
592 * lib/arg.c: ... to here.
593
594 * commands/extcmd.c: New file.
595 * commands/minicmd.c: Likewise.
596 * include/grub/command.h: Likewise.
597 * include/grub/extcmd.h: Likewise.
598 * kern/command.c: Likewise.
599 * kern/corecmd.c: Likewise.
600
601 * kern/list.c (grub_list_iterate): Return int instead of void.
602 (grub_list_insert): New function.
603 (grub_prio_list_insert): Likewise.
604
605 * kern/rescue.c (grub_rescue_command): Removed.
606 (grub_rescue_command_list): Likewise.
607 (grub_rescue_register_command): Likewise.
608 (grub_rescue_unregister_command): Likewise.
609 (grub_rescue_cmd_boot): Move to minicmd.c
610 (grub_rescue_cmd_help): Likewise.
611 (grub_rescue_cmd_info): Likewise.
612 (grub_rescue_cmd_boot): Likewise.
613 (grub_rescue_cmd_testload): Likewise.
614 (grub_rescue_cmd_dump): Likewise.
615 (grub_rescue_cmd_rmmod): Likewise.
616 (grub_rescue_cmd_lsmod): Likewise.
617 (grub_rescue_cmd_exit): Likewise.
618 (grub_rescue_print_devices): Moved to corecmd.c.
619 (grub_rescue_print_files): Likewise.
620 (grub_rescue_cmd_ls): Likewise.
621 (grub_rescue_cmd_insmod): Likewise.
622 (grub_rescue_cmd_set): Likewise.
623 (grub_rescue_cmd_unset): Likewise.
624 (attempt_normal_mode): Use grub_command_find to get normal module.
625 (grub_enter_rescue_mode): Use grub_register_core_commands to register
626 commands, remove grub_rescue_register_command calls.
627
628 * normal/command.c (grub_register_command): Removed.
629 (grub_unregister_command): Likewise.
630 (grub_command_find): Likewise.
631 (grub_iterate_commands): Likewise.
632 (rescue_command): Likewise.
633 (export_command): Moved to corecmd.c.
634 (set_command): Removed.
635 (unset_command): Likewise.
636 (insmod_command): Likewise.
637 (rmmod_command): Likewise.
638 (lsmod_command): Likewise.
639 (grub_command_init): Likewise.
640
641 * normal/completion.c (iterate_command): Use cmd->prio to check for
642 active command.
643 (complete_arguments): Use grub_extcmd_t structure to find options.
644 (grub_normal_do_completion): Change function grub_iterate_commands to
645 grub_command_iterate.
646
647 * normal/execute.c (grub_script_execute_cmd): No need to parse
648 argument here.
649
650 * normal/main.c (grub_dyncmd_dispatcher): New function.
651 (read_command_list): Register unload commands as dyncmd.
652 (grub_cmd_normal): Use new command interface, register rescue,
653 unregister normal at entry, register normal, unregister rescue at exit.
654
655 * include/grub/list.h (grub_list_test_t): New type.
656 (grub_list_iterate): Return int instead of void.
657 (grub_list_insert): New function.
658 (GRUB_AS_NAMED_LIST_P): New macro.
659 (GRUB_AS_PRIO_LIST): Likewise.
660 (GRUB_AS_PRIO_LIST_P): Likewise.
661 (GRUB_PRIO_LIST_PRIO_MASK): New constant.
662 (GRUB_PRIO_LIST_FLAG_ACTIVE): Likewise.
663 (grub_prio_list): New structure.
664 (grub_prio_list_insert): New function.
665 (grub_prio_list_remove): New inline function.
666
667 * include/grub/normal.h: Remove <grub/arg.h>, add <grub/command.h>.
668 (GRUB_COMMAND_FLAG_CMDLINE): Moved to command.h.
669 (GRUB_COMMAND_FLAG_MENU): Likewise.
670 (GRUB_COMMAND_FLAG_BOTH): Likewise.
671 (GRUB_COMMAND_FLAG_TITLE): Likewise.
672 (GRUB_COMMAND_FLAG_NO_ECHO): Likewise.
673 (GRUB_COMMAND_FLAG_NO_ARG_PARSE): Removed.
674 (GRUB_COMMAND_FLAG_NOT_LOADED): Likewise.
675 (grub_command): Likewise.
676 (grub_register_command): Likewise.
677 (grub_command_find): Likewise.
678 (grub_iterate_commands): Likewise.
679 (grub_command_init): Likewise.
680 (grub_arg_parse): Likewise.
681 (grub_arg_show_help): Likewise.
682
683 * include/grub/rescue.h (grub_rescue_register_command): Removed.
684 (grub_rescue_unregister_command): Likewise.
685
686 * include/grub/i386/bsd.h: Remove grub_rescue_cmd_freebsd,
687 grub_rescue_cmd_openbsd, grub_rescue_cmd_netbsd,
688 grub_rescue_cmd_freebsd_loadenv and grub_rescue_cmd_freebsd_module.
689
690 * include/grub/i386/efi/loader.h: Remove grub_rescue_cmd_linux and
691 grub_rescue_cmd_initrd.
692 * include/grub/i386/loader.h: Likewise.
693 * include/grub/x86_64/loader.h: Likewise.
694
695 * include/grub/i386/pc/chainloader.h: Remove grub_chainloader_cmd.
696
697 2009-03-21 Bean <bean123ch@gmail.com>
698
699 * util/hostdisk.c (read_device_map): Use grub_util_get_disk_size
700 instead of stat in mingw environment.
701
702 * util/misc.c (grub_millisleep): Use Sleep in mingw environment.
703
704 * aclocal.m4 (grub_CHECK_LINK_DIR): New function.
705
706 * configure.ac: Use grub_CHECK_LINK_DIR to determine whether to use
707 AC_CONFIG_LINKS.
708
709 2009-03-21 Bean <bean123ch@gmail.com>
710
711 * fs/ext2.c (grub_ext2_mount): Change errno to GRUB_ERR_BAD_FS for
712 out of range error.
713
714 2009-03-18 Michel Dänzer <michel@daenzer.net>
715
716 * fs/ext2.c (grub_ext2_read_block): Take endianness into account when
717 checking inode flags for EXT4_EXTENTS_FLAG.
718
719 2009-03-18 Robert Millan <rmh@aybabtu.com>
720
721 * loader/i386/linux.c: Include `<grub/video.h>' and
722 `<grub/i386/pc/vbe.h>'..
723 (grub_linux_setup_video): New function. Loosely based on the EFI one.
724 (grub_linux32_boot): Attempt to configure video settings with
725 grub_linux_setup_video().
726 (grub_rescue_cmd_linux): Set noreturn=0 in grub_loader_set, in order
727 to avoid grub_console_fini() which would step out of graphical mode
728 unconditionally.
729
730 2009-03-14 Robert Millan <rmh@aybabtu.com>
731
732 Fix build on powerpc.
733 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Add `handler.h'.
734
735 2009-03-12 Vladimir Serbinenko <phcoder@gmail.com>
736
737 * term/gfxterm.c (GRUB_MOD_FINI(term_gfxterm)): Correct name of
738 background image command.
739
740 2009-03-12 Colin D Bennett <colin@gibibit.com>
741
742 * term/gfxterm.c (draw_cursor): Ensure character is redrawn.
743 (grub_gfxterm_putchar): Extract pairs of identical calls to
744 draw_cursor out of conditional blocks.
745
746 2009-03-11 Pavel Roskin <proski@gnu.org>
747
748 * fs/hfs.c (grub_hfs_strncasecmp): New function.
749 (grub_hfs_cmp_catkeys): Use HFS specific string comparison.
750
751 2009-03-11 Robert Millan <rmh@aybabtu.com>
752
753 * loader/i386/multiboot_elfxx.c
754 (CONCAT(grub_multiboot_load_elf, XX)): Do not reject ET_DYN files.
755
756 2009-03-11 Felix Zielcke <fzielcke@z-51.de>
757
758 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add `kern/list.c' and
759 `kern/handler.c'.
760
761 2009-03-11 Robert Millan <rmh@aybabtu.com>
762
763 * loader/i386/multiboot.c (code_size): New variable.
764 (grub_multiboot): Define offsets by adding to `code_size' rather
765 than subtracting from `grub_multiboot_payload_size'. Provide
766 4-byte alignment to MBI and others by increasing
767 `boot_loader_name_length' appropriately.
768
769 * loader/i386/multiboot_elfxx.c
770 (CONCAT(grub_multiboot_load_elf, XX)): Initialize `code_size'.
771
772 2009-03-09 Felix Zielcke <fzielcke@z-51.de>
773
774 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove duplicated
775 `fs/ext2.c'.
776
777 2009-03-08 Robert Millan <rmh@aybabtu.com>
778
779 Make loader/i386/linux.c usable on i386-pc again.
780
781 * kern/i386/pc/init.c (grub_machine_init): Disable addition of low
782 memory to heap.
783 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS] (allocate_pages): Remove
784 `#error' stanza.
785
786 2009-03-07 Bean <bean123ch@gmail.com>
787
788 * loader/i386/efi/linux.c (grub_rescue_cmd_initrd): Fix a bug in initrd
789 allocation.
790
791 2009-03-06 Robert Millan <rmh@aybabtu.com>
792
793 Fix display issue on terminals with screen size other than 80x25
794 (e.g. gfxterm with resolution higher than 640x480).
795
796 * normal/main.c (grub_normal_init_page): Display title text in a
797 position relative to the center of the terminal instead of relying
798 on a hardcoded offset.
799
800 2009-03-04 Robert Millan <rmh@aybabtu.com>
801
802 Filter /etc/grub.d/10_* so that only add-ons for native kernels are
803 installed.
804
805 * Makefile.in (host_kernel): New variable.
806 * conf/common.rmk (grub-mkconfig_SCRIPTS): Conditionalize all 10_*.in
807 scripts instead of just the windows one.
808 * configure.ac: Initialize and AC_SUBST `host_kernel'.
809
810 2009-03-04 Felix Zielcke <fzielcke@z-51.de>
811
812 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `kern/list.c' and
813 `kern/handler.c'.
814 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
815 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
816 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
817 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
818 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
819 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
820
821 2009-03-04 Felix Zielcke <fzielcke@z-51.de>
822
823 * partmap/pc.c (pc_partition_map_iterate): Skip over invalid BSD partitions
824 or if there's no space for the disk label and print the partition number on a
825 invalid magic.
826
827 2009-03-04 Felix Zielcke <fzielcke@z-51.de>
828
829 * util/misc.c: Include <time.h>.
830 (grub_millisleep): New function.
831
832 2009-03-04 Bean <bean123ch@gmail.com>
833
834 * configure.ac: Only test -mcmodel=large option in x86_64-efi, also add
835 another option -mno-red-zone.
836
837 * commands/handler.c: Change module description.
838
839 * kern/handler.c: Add missing space at the end of description line.
840
841 * kern/list.c: Likewise.
842
843 2009-03-03 Robert Millan <rmh@aybabtu.com>
844
845 Move more components to the relocation area, and fix mbi pointer
846 handling to use the destination rather than the origin (thanks to
847 Vladimir Serbinenko for spotting).
848
849 * loader/i386/multiboot.c (mbi_dest): New variable.
850 (grub_multiboot_boot): Use `mbi_dest' instead of `mbi'.
851 (grub_multiboot): Put cmdline, boot_loader_name and mbi in the
852 relocation area.
853
854 2009-03-01 Bean <bean123ch@gmail.com>
855
856 * include/grub/efi/api.h (GRUB_EFI_MPS_TABLE_GUID): New constant.
857 (GRUB_EFI_ACPI_TABLE_GUID): Likewise.
858 (GRUB_EFI_ACPI_20_TABLE_GUID): Likewise.
859 (GRUB_EFI_SMBIOS_TABLE_GUID): Likewise.
860
861 * loader/i386/efi/linux.c (acpi_guid): New variable.
862 (acpi_guid): Likewise.
863 (EBDA_SEG_ADDR): New constant.
864 (LOW_MEM_ADDR): Likewise.
865 (FAKE_EBDA_SEG): Likewise.
866 (fake_bios_data): New function.
867 (grub_linux_boot): Call fake_bios_data.
868
869 2009-03-01 Bean <bean123ch@gmail.com>
870
871 * commands/terminal.c: Removed.
872
873 * commands/handler.c: New file.
874
875 * include/grub/list.h: Likewise.
876
877 * include/grub/handler.h: Likewise.
878
879 * kern/list.c: Likewise.
880
881 * kern/handler.c: Likewise.
882
883 * kern/term.h: Include header file <grub/handler.h>.
884 (grub_term_input): Move next field to the beginning.
885 (grub_term_output): Likewise.
886 (grub_term_input_class): New variable.
887 (grub_term_output_class): Likewise.
888 (grub_term_register_input): Changed to inline function.
889 (grub_term_register_output): Likewise.
890 (grub_term_unregister_input): Likewise.
891 (grub_term_unregister_output): Likewise.
892 (grub_term_set_current_input): Likewise.
893 (grub_term_set_current_output): Likewise.
894 (grub_term_get_current_input): Likewise.
895 (grub_term_get_current_output): Likewise.
896 (grub_term_iterate_input): Removed.
897 (grub_term_iterate_output): Likewise.
898
899 * kern/term.c (grub_term_list_input): Removed.
900 (grub_term_list_output): Likewise.
901 (grub_term_input_class): New variable.
902 (grub_term_output_class): Likewise.
903 (grub_cur_term_input): Change variable as macro.
904 (grub_cur_term_output): Likewise.
905 (grub_term_register_input): Removed.
906 (grub_term_register_output): Likewise.
907 (grub_term_unregister_input): Likewise.
908 (grub_term_unregister_output): Likewise.
909 (grub_term_set_current_input): Likewise.
910 (grub_term_set_current_output): Likewise.
911 (grub_term_iterate_input): Likewise.
912 (grub_term_iterate_output): Likewise.
913 (grub_term_get_current_input): Likewise.
914 (grub_term_get_current_output): Likewise.
915
916 * util/grub-editenv.c: Include header file <grub/handler.h>.
917 (grub_term_get_current_input): Removed.
918 (grub_term_get_current_output): Likewise.
919 (grub_term_input_class): New variable.
920 (grub_term_output_class): Likewise.
921
922 * util/grub-fstest.c (grub_term_get_current_input): Removed.
923 (grub_term_get_current_output): Likewise.
924 (grub_term_input_class): New variable.
925 (grub_term_output_class): Likewise.
926
927 * util/grub-probe.c (grub_term_get_current_input): Removed.
928 (grub_term_get_current_output): Likewise.
929 (grub_term_input_class): New variable.
930 (grub_term_output_class): Likewise.
931
932 * util/i386/pc/grub-setup.c (grub_term_get_current_input): Removed.
933 (grub_term_get_current_output): Likewise.
934 (grub_term_input_class): New variable.
935 (grub_term_output_class): Likewise.
936
937 * conf/common.rmk (pkglib_MODULES): Replace terminal with handler.
938 (terminal_mod_SOURCES): Likewise.
939 (terminal_mod_CFLAGS): Likewise.
940 (terminal_mod_LDFLAGS): Likewise.
941
942 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace terminal.c with
943 handler.c.
944 (kernel_img_SOURCES): Add list.c and handler.c.
945 (kernel_img_HEADERS): Add list.h and handler.h.
946
947 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
948 handler.c.
949 (kernel_mod_SOURCES): Add list.c and handler.c.
950 (kernel_mod_HEADERS): Add list.h and handler.h.
951
952 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Replace terminal.c with
953 handler.c.
954 (kernel_elf_SOURCES): Add list.c and handler.c.
955 (kernel_elf_HEADERS): Add list.h and handler.h.
956
957 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
958 handler.c.
959 (kernel_elf_SOURCES): Add list.c and handler.c.
960 (kernel_elf_HEADERS): Add list.h and handler.h.
961
962 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
963 handler.c.
964 (kernel_mod_SOURCES): Add list.c and handler.c.
965 (kernel_mod_HEADERS): Add list.h and handler.h.
966
967 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
968 handler.c.
969 (kernel_elf_SOURCES): Add list.c and handler.c.
970 (kernel_elf_HEADERS): Add list.h and handler.h.
971
972 2009-02-27 Robert Millan <rmh@aybabtu.com>
973
974 Factorize elf32 / elf64 code in Multiboot loader. This will
975 prevent it from getting out of sync again.
976
977 * loader/i386/multiboot.c (grub_multiboot_is_elf32,
978 grub_multiboot_load_elf32, grub_multiboot_is_elf64,
979 grub_multiboot_load_elf64): Move from here ...
980 * loader/i386/multiboot_elfxx.c (grub_multiboot_is_elf,
981 grub_multiboot_load_elf): ... to here (new file).
982
983 2009-02-27 Robert Millan <rmh@aybabtu.com>
984
985 * util/grub.d/10_linux.in: Rename "single-user mode" to
986 "recovery mode".
987
988 2009-02-27 Vladimir Serbinenko <phcoder@gmail.com>
989
990 Don't leak in SCSI code.
991 * disk/scsi.c (grub_scsi_close): free `scsi'.
992
993 2009-02-27 Robert Millan <rmh@aybabtu.com>
994
995 * loader/i386/pc/multiboot.c: Move from here ...
996 * loader/i386/multiboot.c: ... to here. Update all users.
997
998 2009-02-27 Robert Millan <rmh@aybabtu.com>
999
1000 Patch from Alexandre Bique <bique.alexandre@gmail.com>
1001 * util/i386/pc/grub-setup.c (setup): Fix directory path.
1002
1003 2009-02-27 Krzysztof Smiechowicz <deadwood@wp.pl>
1004
1005 * fs/sfs.c (grub_sfs_read_extent): Correction to traversing extent
1006 b-tree.
1007
1008 2009-02-27 Robert Millan <rmh@aybabtu.com>
1009
1010 * kern/misc.c (grub_strtoull): Fix bug (it mistakenly parsed the
1011 `0x' qualifier as 0 when base is specified as parameter).
1012
1013 2009-02-24 Bean <bean123ch@gmail.com>
1014
1015 * configure.ac: Check for -mcmodel=large in x86_64 target.
1016
1017 * include/grub/efi/api.h (efi_call_10): New macro.
1018 (efi_wrap_10): New function.
1019
1020 * include/grub/efi/pe32.h (GRUB_PE32_REL_BASE_HIGH): New macro.
1021 (GRUB_PE32_REL_BASED_HIGH): Likewise.
1022 (GRUB_PE32_REL_BASED_LOW): Likewise.
1023 (GRUB_PE32_REL_BASED_HIGHLOW): Likewise.
1024 (GRUB_PE32_REL_BASED_HIGHADJ): Likewise.
1025 (GRUB_PE32_REL_BASED_MIPS_JMPADDR): Likewise.
1026 (GRUB_PE32_REL_BASED_SECTION): Likewise.
1027 (GRUB_PE32_REL_BASED_REL): Likewise.
1028 (GRUB_PE32_REL_BASED_IA64_IMM64): Likewise.
1029 (GRUB_PE32_REL_BASED_DIR64): Likewise.
1030 (GRUB_PE32_REL_BASED_HIGH3ADJ): Likewise.
1031
1032 * kern/x86_64/dl.c (grub_arch_dl_relocate_symbols): Fixed relocation
1033 issue.
1034
1035 * kern/x86_64/efi/callwrap.S (efi_wrap_6): Bug fix.
1036 (efi_wrap_10): New function.
1037
1038 * kern/x86_64/efi/startup.S (codestart): Use relative addressing.
1039
1040 * loader/efi/appleloader.c (devpath_5): Add support for late 2008
1041 MB/MBP model (NV chipset).
1042 (devdata_devs): Add devpath_5 to the list.
1043
1044 * load/i386/efi/linux.c (video_base): Remove variable.
1045 (RGB_MASK): New macro.
1046 (RGB_MAGIC): Likewise.
1047 (LINE_MIN): Likewise.
1048 (LINE_MAX): Likewise.
1049 (FBTEST_STEP): Likewise.
1050 (FBTEST_COUNT): Likewise.
1051 (fb_list): New variable.
1052 (grub_find_video_card): Remove function.
1053 (find_framebuf): New function.
1054 (grub_linux_setup_video): Use find_framebuf to get frame buffer and
1055 line length.
1056
1057 * util/i386/efi/grub-mkimage.c (grub_reloc_section): Fix relocation
1058 problem for x86_64.
1059
1060 2009-02-22 Vesa Jääskeläinen <chaac@nic.fi>
1061
1062 Patch #25624 by Kevin Lacquement <kevin@lacqui>.
1063
1064 * util/grub-mkconfig.in: Use ${grub_mkdevicemap} instead of hard
1065 coding tool name.
1066
1067 2009-02-22 Robert Millan <rmh@aybabtu.com>
1068
1069 * include/multiboot.h (MULTIBOOT_INFO_ALIGN): New macro.
1070 * loader/i386/pc/multiboot.c (grub_multiboot): Include the MBI
1071 in our relocation, instead of using it directly from heap. Also
1072 use `MULTIBOOT_INFO_ALIGN' to ensure it is aligned.
1073
1074 2009-02-21 Robert Millan <rmh@aybabtu.com>
1075
1076 Implement USB keyboard support (based on patch by Marco Gerards)
1077
1078 * conf/i386-pc.rmk (pkglib_MODULES): Add `usb_keyboard.mod'.
1079 (usb_keyboard_mod_SOURCES, usb_keyboard_mod_CFLAGS)
1080 (usb_keyboard_mod_LDFLAGS): New variables.
1081
1082 * term/usb_keyboard.c: New file.
1083
1084 2009-02-14 Vladimir Serbinenko <phcoder@gmail.com>
1085
1086 Corrected wrong declaration
1087
1088 * kern/disk.c: corrected declaration of grub_disk_ata_pass_through.
1089
1090 2009-02-14 Christian Franke <franke@computer.org>
1091
1092 * commands/lspci.c (grub_pci_classes): Add `SATA Controller'.
1093 (grub_lspci_iter): Print class code and programming interface byte.
1094
1095 2009-02-14 Christian Franke <franke@computer.org>
1096
1097 * gendistlist.sh: Ignore `.svn' directories.
1098
1099 2009-02-14 Felix Zielcke <fzielcke@z-51.de>
1100
1101 * fs/fat.c: Add 2009 to Copyright line.
1102
1103 2009-02-14 Christian Franke <franke@computer.org>
1104
1105 * commands/hdparm.c: New file. Provides `hdparm' command
1106 which sends ATA commands via grub_disk_ata_pass_through ().
1107
1108 * conf/i386-pc.rmk: Add ata_pthru.mod and hdparm.mod.
1109
1110 * disk/ata.c: Include <grub/ata.h>. Move <grub/misc.h>
1111 and <grub/cpu/io.h> to include/grub/ata.h.
1112 (enum grub_ata_addressing_t): Move to include/grub/ata.h.
1113 (GRUB_CDROM_SECTOR_SIZE): Remove.
1114 (GRUB_ATA_*): Move to include/grub/ata.h.
1115 (GRUB_ATAPI_*): Likewise.
1116 (enum grub_ata_commands): Likewise.
1117 (enum grub_ata_timeout_milliseconds): Likewise.
1118 (struct grub_ata_device): Likewise.
1119 (grub_ata_regset): Likewise.
1120 (grub_ata_regget): Likewise.
1121 (grub_ata_regset2): Likewise.
1122 (grub_ata_regget2): Likewise.
1123 (grub_ata_check_ready): Likewise.
1124 (grub_ata_wait_not_busy): Remove static, exported in
1125 include/grub/ata.h.
1126 (grub_ata_wait_drq): Likewise.
1127 (grub_ata_pio_read): Likewise.
1128
1129 * disk/ata_pthru.c: New file. Provides grub_ata_pass_through ()
1130 function for hdparm.mod.
1131
1132 * include/grub/ata.h: New file, contains declarations from
1133 disk/ata.c.
1134 (enum grub_ata_commands): Add new commands for commands/hdparm.c.
1135
1136 * include/grub/disk.h (grub_disk_ata_pass_through_parms): New struct.
1137 (grub_disk_ata_pass_through): New exported variable.
1138
1139 * kern/disk.c (grub_disk_ata_pass_through): New variable.
1140
1141 2009-02-13 Colin D Bennett <colin@gibibit.com>
1142
1143 Support multiple fallback entries, and provide an API to support
1144 executing default+fallback menu entries. Renamed the `terminal' menu
1145 viewer to `text'.
1146
1147 * include/grub/normal.h (grub_normal_text_menu_viewer): New global
1148 variable declaration.
1149 (grub_menu_execute_callback): New structure declaration.
1150 (grub_menu_execute_callback_t): New typedef.
1151 (grub_menu_execute_with_fallback): New function declaration.
1152 (grub_menu_get_entry): Likewise.
1153 (grub_menu_get_timeout): Likewise.
1154 (grub_menu_set_timeout): Likewise.
1155
1156 * normal/main.c (GRUB_MOD_INIT(normal)): Refer to new variable name.
1157
1158 * normal/menu.c (grub_wait_after_message): Moved to
1159 `normal/menu_text.c'.
1160 (draw_border): Likewise.
1161 (print_message): Likewise.
1162 (print_entry): Likewise.
1163 (print_entries): Likewise.
1164 (grub_menu_init_page): Likewise.
1165 (get_entry_number): Likewise.
1166 (print_timeout): Likewise.
1167 (run_menu): Likewise.
1168 (grub_menu_execute_entry): Likewise.
1169 (show_text_menu): Likewise.
1170 (get_and_remove_first_entry_number): New function.
1171 (grub_menu_execute_with_fallback): Likewise.
1172 (get_entry): Renamed to ...
1173 (grub_menu_get_entry): .. this and made it global.
1174 (get_timeout): Renamed to ...
1175 (grub_menu_get_timeout): ... this and made it global.
1176 (set_timeout): Renamed to ...
1177 (grub_menu_set_timeout): ... this and made it global.
1178 (grub_normal_terminal_menu_viewer): Renamed to ...
1179 (grub_normal_text_menu_viewer): ... this.
1180
1181 * normal/menu_text.c: New file. Extracted text-menu-specific code
1182 from normal/menu.c.
1183
1184 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add `normal/menu_text.c'.
1185 (normal_mod_SOURCES): Likewise.
1186
1187 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
1188 (normal_mod_SOURCES): Likewise.
1189
1190 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1191 (normal_mod_SOURCES): Likewise.
1192
1193 * conf/i386-pc.rmk, (grub_emu_SOURCES): Likewise.
1194 (normal_mod_SOURCES): Likewise.
1195
1196 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1197 (normal_mod_SOURCES): Likewise.
1198
1199 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1200 (normal_mod_SOURCES): Likewise.
1201
1202 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
1203 (normal_mod_SOURCES): Likewise.
1204
1205 2009-02-11 Robert Millan <rmh@aybabtu.com>
1206
1207 * util/grub.d/00_header.in: Update old reference to `font' command.
1208
1209 2009-02-10 Felix Zielcke <fzielcke@z-51.de>
1210
1211 * fs/fat.c (grub_fat_mount): Fix wrong comparison.
1212
1213 Based on patch from Javier Martín.
1214
1215 2009-02-09 Felix Zielcke <fzielcke@z-51.de>
1216
1217 * conf/common.rmk (grub_probe_SOURCES): Move fs/ext2.c before fs/fat.c
1218 to avoid false positives with FAT.
1219 (grub_fstest_SOURCES): Likewise.
1220 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
1221 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
1222 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1223 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
1224 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1225 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1226
1227 2009-02-09 Felix Zielcke <fzielcke@z-51.de>
1228
1229 * fs/fat.c (grub_fat_mount): Try to avoid false positives by checking
1230 bpb.version_specific.fat12_or_fat16.fstype and
1231 bpb.version_specific.fat32.fstype.
1232
1233 2009-02-08 Robert Millan <rmh@aybabtu.com>
1234
1235 * fs/tar.c: Replace "fs/cpio.c" with "cpio.c".
1236
1237 2009-02-08 Robert Millan <rmh@aybabtu.com>
1238
1239 * Makefile.in (host_os, host_cpu): New variables.
1240 (target_os): Remove. Update all users.
1241
1242 2009-02-08 Marco Gerards <marco@gnu.org>
1243
1244 * Makefile.in (enable_grub_emu_usb): New variable.
1245 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/scsi.c'.
1246 (grub_emu_SOURCES) [grub_emu_SOURCES]: Add `disk/usbms.c',
1247 `util/usb.c', `bus/usb/usb.c' and `commands/usbtest.c'.
1248 (grub_emu_LDFLAGS): Add `$(LIBUSB)'.
1249 (pkglib_MODULES): Add `usb.mod', `uhci.mod', `ohci.mod',
1250 `usbtest.mod' and `usbms.mod'.
1251 (usb_mod_SOURCES, usb_mod_CFLAGS, usb_mod_LDFLAGS)
1252 (usbtest_mod_SOURCES, usbtest_mod_CFLAGS, usbtest_mod_LDFLAGS)
1253 (uhci_mod_SOURCES, uhci_mod_CFLAGS, uhci_mod_LDFLAGS,
1254 (ohci_mod_SOURCES, ohci_mod_CFLAGS, ohci_mod_LDFLAGS)
1255 (usbms_mod_SOURCES, usbms_mod_CFLAGS, usbms_mod_LDFLAGS): New
1256 variables.
1257
1258 * disk/usbms.c: New file.
1259
1260 * include/grub/usb.h: Likewise.
1261
1262 * include/grub/usbtrans.h: Likewise.
1263
1264 * include/grub/usbdesc.h: Likewise.
1265
1266 * bus/usb/usbtrans.c: Likewise.
1267
1268 * bus/usb/ohci.c: Likewise.
1269
1270 * bus/usb/uhci.c: Likewise.
1271
1272 * bus/usb/usbhub.c: Likewise.
1273
1274 * bus/usb/usb.c: Likewise.
1275
1276 * commands/usbtest.c: Likewise.
1277
1278 * util/usb.c: Likewise.
1279
1280 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_IO'.
1281
1282 * configure.ac: Test for libusb presence.
1283
1284 * util/grub-emu.c (main) [HAVE_LIBUSB_H]: Call `grub_libusb_init'.
1285
1286 2009-02-08 Vesa Jääskeläinen <chaac@nic.fi>
1287
1288 * kern/mm.c: Add more comments.
1289
1290 2009-02-08 Robert Millan <rmh@aybabtu.com>
1291
1292 Patch from Javier Martín.
1293 * fs/ext2.c (EXT2_DRIVER_SUPPORTED_INCOMPAT): Add
1294 `EXT4_FEATURE_INCOMPAT_FLEX_BG'.
1295
1296 2009-02-08 Robert Millan <rmh@aybabtu.com>
1297
1298 * fs/cpio.c: Split tar functionality to ...
1299 * fs/tar.c: ... here (new file). Update all users.
1300
1301 2009-02-07 Robert Millan <rmh@aybabtu.com>
1302
1303 * fs/ext2.c (grub_ext2_mount): Avoid mounting filesystems with
1304 backward-incompatible features.
1305
1306 Based on patch from Javier Martín, with some adjustments.
1307
1308 2009-02-07 Michael Scherer <misc@mandriva.org>
1309
1310 * fs/hfs.c (grub_hfsplus_iterate_dir): Treat hfs+ as case insensitive.
1311
1312 2009-02-07 Robert Millan <rmh@aybabtu.com>
1313
1314 * conf/common.rmk (grub_probe_SOURCES, grub_fstest_SOURCES): Move
1315 position of `disk/lvm.c' to ensure grub_init_all() always picks it
1316 after the RAID stuff.
1317
1318 2009-02-05 Vesa Jääskeläinen <chaac@nic.fi>
1319
1320 Fixes problem when running vbetest command as reported by
1321 Vladimir Serbinenko <phcoder@gmail.com>.
1322
1323 * (grub_vbe_set_video_mode): Fixed problem with text modes.
1324
1325 2009-02-04 Felix Zielcke <fzielcke@z-51.de>
1326
1327 util/getroot.c (grub_util_get_grub_dev): Add support for /dev/mdNpN and
1328 /dev/md/NpN style mdraid devices.
1329
1330 2009-02-03 Felix Zielcke <fzielcke@z-51.de>
1331
1332 * util/unifont2pff.rb: Remove.
1333
1334 2009-02-03 Felix Zielcke <fzielcke@z-51.de>
1335
1336 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add a missing trailing
1337 `#'.
1338
1339 2009-02-03 Felix Zielcke <fzielcke@z-51.de>
1340
1341 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/menu_viewer.c'.
1342 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
1343 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
1344 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
1345 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1346 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1347 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1348
1349 2009-02-02 Christian Franke <franke@computer.org>
1350
1351 * lib/hexdump.c (hexdump): Print at most 3 lines if data is identical.
1352
1353 2009-02-01 Felix Zielcke <fzielcke@z-51.de>
1354
1355 * INSTALL: Note that we now require at least autoconf 2.59 and
1356 that LZO is optional.
1357
1358 2009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
1359
1360 Base on patch on bug #24154 created by Tomas Tintera
1361 <trosos@seznam.cz>.
1362
1363 * video/i386/pc/vbe.c (grub_video_vbe_scroll): Fix downward scrolling.
1364
1365 2009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
1366
1367 Based on patch on bug #25318 created by Bernhard Rosenkraenzer
1368 <bero@arklinux.org>.
1369
1370 * normal/parser.y (script_init): Add missing semicolon.
1371
1372 2009-01-31 Colin D Bennett <colin@gibibit.com>
1373
1374 * normal/main.c: Add include to grub/menu_viewer.h.
1375 (free_menu_entry_classes): Added.
1376 (grub_normal_menu_addentry): Added class property handling.
1377 (grub_normal_execute): Changed to use new menu viewer for menu viewing.
1378 (GRUB_MOD_INIT(normal)): Added register for text based menu viewer.
1379
1380 * normal/menu_viewer.c: New file.
1381
1382 * normal/menu.c (run_menu_entry): Renamed to ...
1383 (grub_menu_execute_entry): ... this and made it as global.
1384 (grub_menu_run): Renamed to ...
1385 (show_text_menu): ... this and made it local.
1386 (show_text_menu): Adapt to new function names.
1387 (grub_normal_terminal_menu_viewer): New global variable.
1388
1389 * include/grub/menu.h: New file.
1390
1391 * include/grub/menu_viewer.h: New file.
1392
1393 * include/grub/normal.h: Added include to grub/menu.h.
1394 (grub_menu_entry): Moved to include/grub/menu.h.
1395 (grub_menu_entry_t): Likewise.
1396 (grub_menu): Likewise.
1397 (grub_menu_t): Likewise.
1398 (grub_normal_terminal_menu_viewer): Added.
1399 (grub_menu_execute_entry): Likewise.
1400 (grub_menu_run): Removed.
1401
1402 * DISTLIST: Added include/grub/menu.h.
1403 Added include/grub/menu_viewer.h.
1404 Added normal/menu_viewer.c.
1405
1406 2009-01-31 Vesa Jääskeläinen <chaac@nic.fi>
1407
1408 * normal/execute.c (grub_script_execute_menuentry): Changed to use
1409 arglist for menutitle arguments.
1410
1411 * normal/main.c (grub_normal_menu_addentry): Likewise.
1412
1413 * normal/parser.y (menuentry): Likewise.
1414
1415 * normal/script.c (grub_script_create_cmdmenu): Likewise.
1416
1417 * include/grub/script.h (grub_script_cmd_menuentry): Likewise.
1418 (grub_script_create_cmdmenu): Likewise.
1419
1420 * include/grub/normal.h (grub_normal_menu_addentry): Likewise.
1421
1422 * conf/i386-pc.rmk (normal_mod_SOURCES): Adapt Colin D Bennett's
1423 changes.
1424
1425 * conf/x86_64-efi.rmk (normal_mod_SOURCES): Likewise.
1426
1427 * conf/i386-coreboot.rmk (normal_mod_SOURCES): Likewise.
1428
1429 * conf/i386-efi.rmk (normal_mod_SOURCES): Likewise.
1430
1431 * conf/i386-ieee1275.rmk (normal_mod_SOURCES): Likewise.
1432
1433 * conf/powerpc-ieee1275.rmk (normal_mod_SOURCES): Likewise.
1434
1435 * conf/sparc64-ieee1275.rmk (normal_mod_SOURCES): Likewise.
1436
1437 2009-01-30 Christian Franke <franke@computer.org>
1438
1439 * normal/arg.c (grub_arg_show_help): Add indentation if '\n' appears
1440 in option help text.
1441
1442 2009-01-27 Pavel Roskin <proski@gnu.org>
1443
1444 * disk/fs_uuid.c (search_fs_uuid): Ignore case of the UUID.
1445
1446 2009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
1447
1448 * commands/lsmmap.c: Add include to grub/machine/memory.h.
1449
1450 * fs/i386/pc/pxe.c (grub_pxefs_open): Fix sign problem.
1451
1452 * term/i386/pc/at_keyboard.c (GRUB_MOD_FINI(at_keyboard)): Use proper
1453 unregister function.
1454
1455 2009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
1456
1457 * disk/scsi.c (grub_scsi_read): Fix sign problem.
1458
1459 * term/i386/pc/vga_text.c (grub_vga_text_init_fini). Fix declaration.
1460
1461 * util/grub-mkfont.c (usage): Fix typo.
1462
1463 * util/elf/grub-mkimage.c (load_modules): Fix warning.
1464
1465 2009-01-26 Daniel Mierswa <impulze@impulze.org>
1466
1467 * fs/fat.c (grub_fat_uuid): Fix shift of the first two bytes.
1468
1469 * commands/search.c (search_fs_uuid): Ignore case of the UUID.
1470
1471 * kern/misc.c (grub_strcasecmp): New function.
1472 (grub_strcasecmp): Use grub_size_t instead of int for length.
1473 Fix return value.
1474 * include/grub/misc.h: Update function prototypes.
1475
1476 2009-01-26 Robert Millan <rmh@aybabtu.com>
1477
1478 * configure.ac: Fix cross-compilation check.
1479
1480 2009-01-22 Christian Franke <franke@computer.org>
1481
1482 * kern/misc.c (grub_vsprintf): Fix size and termination of `format2'
1483 (precision) digit string. Allow `.format2' without `format1' (width).
1484 Limit input chars for `%s' output to `format2' if specified. This is
1485 compatible with standard printf ().
1486
1487 2009-01-22 Christian Franke <franke@computer.org>
1488
1489 * disk/ata.c (grub_ata_wait_status): Replace by ...
1490 (grub_ata_wait_not_busy): ... this function. Checks only BSY bit,
1491 other status bits may be invalid while BSY is asserted.
1492 (grub_ata_check_ready): New function.
1493 (grub_ata_cmd): Removed.
1494 (grub_ata_wait_drq): New function.
1495 (grub_ata_strncpy): Remove inline.
1496 (grub_ata_pio_read): Reduce to actual block transfer. BSY wait
1497 and error check now done by grub_ata_wait_drq ().
1498 (grub_ata_pio_write): Likewise.
1499 (grub_atapi_identify): Set DEV before check for !BSY. Use
1500 grub_ata_wait_drq () to wait for data.
1501 (grub_ata_device_initialize): Add status register check to
1502 detect missing SATA slave devices. Add debug messages.
1503 (grub_atapi_wait_drq): Use grub_ata_wait_not_busy ().
1504 (grub_atapi_packet): Set DEV before check for !BSY. Replace
1505 transfer loop by grub_ata_pio_write ().
1506 (grub_ata_identify): Set DEV before check for !BSY. Use
1507 grub_ata_wait_drq () to wait for data.
1508 (grub_ata_setaddress): Set DEV before check for !BSY.
1509 (grub_ata_readwrite): Remove duplicate code, handle batch/rest and
1510 read/write in one loop. Fix invalid command on write. Fix incomplete
1511 command on (size % batch) == 0. Add missing error check after write of
1512 last block. Add debug messages.
1513 (grub_atapi_read): Replace transfer loop by grub_ata_pio_read ().
1514
1515 2009-01-19 Christian Franke <franke@computer.org>
1516
1517 * disk/ata.c (GRUB_ATAPI_REG_*): New defines.
1518 (GRUB_ATAPI_IREASON_*): Likewise.
1519 (grub_ata_pio_write): Fix timeout error return.
1520 (grub_atapi_identify): Add grub_ata_wait () after cmd.
1521 (grub_atapi_wait_drq): New function.
1522 (grub_atapi_packet): New parameter `size'.
1523 Use grub_atapi_wait_drq () and direct write instead of
1524 grub_ata_pio_write ().
1525 (grub_atapi_read): Replace grub_ata_pio_read () by a loop which
1526 reads the number of bytes requested by the device for each DRQ
1527 assertion.
1528 (grub_atapi_write): Remove old implementation, return not
1529 implemented instead.
1530
1531 2009-01-19 Christian Franke <franke@computer.org>
1532
1533 * disk/scsi.c (grub_scsi_read10): Use scsi->blocksize instead
1534 of 512 to calculate data size.
1535 (grub_scsi_read12): Likewise.
1536 (grub_scsi_write10): Likewise.
1537 (grub_scsi_write12): Likewise.
1538 (grub_scsi_read): Adjust size according to blocksize.
1539 Add checks for invalid blocksize and unaligned transfer.
1540
1541 2009-01-19 Vesa Jääskeläinen <chaac@nic.fi>
1542
1543 * font/font.c (grub_font_loader_init): Re-position unknown glyph.
1544
1545 * term/gfxterm.c (write_char): Fix background rendering for wide
1546 width glyphs.
1547
1548 2009-01-19 Robert Millan <rmh@aybabtu.com>
1549
1550 * config.guess: Update to latest version from config git.
1551 * config.sub: Likewise.
1552
1553 2009-01-17 Felix Zielcke <fzielcke@z-51.de>
1554
1555 * Makefile.in: Change font compilation to use new grub-mkfont instead
1556 of java version.
1557
1558 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: Remove.
1559 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
1560 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
1561 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
1562 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
1563 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
1564 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
1565 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
1566 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
1567
1568 2009-01-16 Christian Franke <franke@computer.org>
1569
1570 * disk/ata.c (enum grub_ata_commands): Remove EXEC_DEV_DIAGNOSTICS.
1571 (enum grub_ata_timeout_milliseconds): New enum.
1572 (grub_ata_wait_status): Add parameter milliseconds.
1573 (grub_ata_cmd): Remove variable `err'. Remove wait for !DRQ to allow
1574 recovery from timed-out commands.
1575 (grub_ata_pio_read): Add parameter milliseconds. Fix error return,
1576 return grub_errno instead of REG_ERROR.
1577 (grub_ata_pio_write): Add parameter milliseconds.
1578 (grub_atapi_identify): Fix size of ATAPI IDENTIFY sector.
1579 Pass milliseconds to grub_ata_wait_status () and
1580 grub_ata_pio_read ().
1581 (grub_atapi_packet): Pass milliseconds to grub_ata_pio_write ().
1582 (grub_ata_identify): Remove variable `ataerr'. Pass milliseconds to
1583 grub_ata_wait_status (). Fix IDENTIFY timeout check.
1584 (grub_ata_device_initialize): Remove EXECUTE DEVICE DIAGNOSTICS.
1585 It is not suitable for device detection, because DEV bit is ignored,
1586 the command may run too long, and not all devices set the signature
1587 properly.
1588 (grub_ata_pciinit): Clear grub_errno before grub_ata_device_initialize ().
1589 (grub_ata_setaddress): Pass milliseconds to grub_ata_wait_status ().
1590 Fix device selection, DEV bit must be set first to address the registers
1591 of the correct device.
1592 (grub_ata_readwrite): Pass milliseconds to grub_ata_wait_status () and
1593 grub_ata_pio_read/write ().
1594 (grub_atapi_read): Pass milliseconds to grub_ata_pio_read ().
1595 (grub_atapi_write): Pass milliseconds to grub_ata_pio_write ().
1596
1597 2009-01-13 Carles Pina i Estany <carles@pina.cat>
1598
1599 * util/grub-editenv.c (main): Use fseeko(), not fseek().
1600
1601 2009-01-13 Bean <bean123ch@gmail.com>
1602
1603 * util/grub-mkfont.c (write_font): forget to remove some debug code.
1604
1605 2009-01-13 Bean <bean123ch@gmail.com>
1606
1607 * Makefile.in: (enable_grub_mkfont): New variable.
1608 (freetype_cflags): Likewise.
1609 (freetype_libs): Likewise.
1610
1611 * common.rmk (bin_UTILITIES): Add `grub-mkfont' if requested.
1612 (grub_mkfont_SOURCES): New variable.
1613 (grub_mkfont_CFLAGS): Likewise.
1614 (grub_mkfont_LDFLAGS): Likewise.
1615
1616 * configure.ac (--enable-grub-mkfont): New option. Check for freetype2
1617 library if `--enable-grub-mkfont' is requested.
1618 (enable_grub_mkfont): New variable.
1619 (freetype_cflags): Likewise.
1620 (freetype_libs): Likewise.
1621
1622 * util/grub-mkfont.c: New file.
1623
1624 2009-01-12 Christian Franke <franke@computer.org>
1625
1626 * disk/ata.c (grub_ata_pciinit): Fix bit numbers of compatibility
1627 mode check. Fix setting of compat_use[].
1628
1629 2009-01-10 Robert Millan <rmh@aybabtu.com>
1630
1631 Update a few copyright years which we forgot to do in 2008 (only for
1632 files whose changes made in 2008 were copyright-significant)
1633
1634 * Makefile.in: Add 2008 to Copyright line.
1635 * disk/ieee1275/ofdisk.c: Likewise.
1636 * disk/efi/efidisk.c: Likewise.
1637 * kern/dl.c: Likewise.
1638 * kern/sparc64/ieee1275/init.c: Likewise.
1639 * kern/mm.c: Likewise.
1640 * kern/efi/mm.c: Likewise.
1641 * boot/i386/pc/boot.S: Likewise.
1642 * genfslist.sh: Likewise.
1643 * fs/iso9660.c: Likewise.
1644 * fs/hfs.c: Likewise.
1645 * fs/jfs.c: Likewise.
1646 * fs/minix.c: Likewise.
1647 * fs/ufs.c: Likewise.
1648 * gensymlist.sh.in: Likewise.
1649 * genkernsyms.sh.in: Likewise.
1650 * include/grub/misc.h: Likewise.
1651 * include/grub/types.h: Likewise.
1652 * include/grub/symbol.h: Likewise.
1653 * include/grub/elf.h: Likewise.
1654 * include/grub/kernel.h: Likewise.
1655 * include/grub/disk.h: Likewise.
1656 * include/grub/dl.h: Likewise.
1657 * include/grub/i386/linux.h: Likewise.
1658 * include/grub/i386/pc/biosdisk.h: Likewise.
1659 * include/grub/efi/api.h: Likewise.
1660 * include/grub/efi/pe32.h: Likewise.
1661 * include/grub/util/misc.h: Likewise.
1662 * normal/execute.c: Likewise.
1663 * normal/arg.c: Likewise.
1664 * normal/completion.c: Likewise.
1665 * normal/lexer.c: Likewise.
1666 * normal/parser.y: Likewise.
1667 * normal/misc.c: Likewise.
1668 * commands/i386/pc/vbeinfo.c: Likewise.
1669 * commands/hexdump.c: Likewise.
1670 * commands/terminal.c: Likewise.
1671 * commands/ls.c: Likewise.
1672 * commands/help.c: Likewise.
1673 * partmap/pc.c: Likewise.
1674 * loader/efi/chainloader.c: Likewise.
1675 * loader/multiboot_loader.c: Likewise.
1676 * loader/i386/pc/multiboot2.c: Likewise.
1677 * term/efi/console.c: Likewise.
1678 * term/i386/pc/serial.c: Likewise.
1679 * util/lvm.c: Likewise.
1680 * util/console.c: Likewise.
1681 * util/i386/efi/grub-mkimage.c: Likewise.
1682 * util/raid.c: Likewise.
1683
1684 2009-01-06 Vesa Jääskeläinen <chaac@nic.fi>
1685
1686 * commands/videotest.c: Removed include to grub/machine/memory.h.
1687
1688 * conf/i386-pc.rmk (pkglib_MODULES): Removed video.mod, gfxterm.mod,
1689 videotest.mod, bitmap.mod, tga.mod, jpeg.mod, png.mod.
1690 (video_mod_SOURCES): Removed.
1691 (video_mod_CFLAGS): Likewise.
1692 (video_mod_LDFLAGS): Likewise.
1693 (gfxterm_mod_SOURCES): Likewise.
1694 (gfxterm_mod_CFLAGS): Likewise.
1695 (gfxterm_mod_LDFLAGS): Likewise.
1696 (videotest_mod_SOURCES): Likewise.
1697 (videotest_mod_CFLAGS): Likewise.
1698 (videotest_mod_LDFLAGS): Likewise.
1699 (bitmap_mod_SOURCES): Likewise.
1700 (bitmap_mod_CFLAGS): Likewise.
1701 (bitmap_mod_LDFLAGS): Likewise.
1702 (tga_mod_SOURCES): Likewise.
1703 (tga_mod_CFLAGS): Likewise.
1704 (tga_mod_LDFLAGS): Likewise.
1705 (jpeg_mod_SOURCES): Likewise.
1706 (jpeg_mod_CFLAGS): Likewise.
1707 (jpeg_mod_LDFLAGS): Likewise.
1708 (png_mod_SOURCES): Likewise.
1709 (png_mod_CFLAGS): Likewise.
1710 (png_mod_LDFLAGS): Likewise.
1711
1712 * conf/common.rmk (pkglib_MODULES): Added video.mod, videotest.mod,
1713 bitmap.mod, tga.mod, jpeg.mod, png.mod, font.mod, gfxterm.mod
1714 (video_mod_SOURCES): Added.
1715 (video_mod_CFLAGS): Likewise.
1716 (video_mod_LDFLAGS): Likewise.
1717 (videotest_mod_SOURCES): Likewise.
1718 (videotest_mod_CFLAGS): Likewise.
1719 (videotest_mod_LDFLAGS): Likewise.
1720 (bitmap_mod_SOURCES): Likewise.
1721 (bitmap_mod_CFLAGS): Likewise.
1722 (bitmap_mod_LDFLAGS): Likewise.
1723 (tga_mod_SOURCES): Likewise.
1724 (tga_mod_CFLAGS): Likewise.
1725 (tga_mod_LDFLAGS): Likewise.
1726 (jpeg_mod_SOURCES): Likewise.
1727 (jpeg_mod_CFLAGS): Likewise.
1728 (jpeg_mod_LDFLAGS): Likewise.
1729 (png_mod_SOURCES): Likewise.
1730 (png_mod_CFLAGS): Likewise.
1731 (png_mod_LDFLAGS): Likewise.
1732 (gfxterm_mod_SOURCES): Likewise.
1733 (gfxterm_mod_CFLAGS): Likewise.
1734 (gfxterm_mod_LDFLAGS): Likewise.
1735
1736 * term/gfxterm.c: Removed include to grub/machine/memory.h,
1737 grub/machine/console.h.
1738
1739 2009-01-04 Jerone Young <jerone@gmail.com>
1740
1741 Make on screen instructions clearer
1742
1743 Based on patch created by Jidanni <jidanni@jidanni.org>
1744
1745 * normal/menu.c: print clearer instructions on the screen
1746
1747 2009-01-02 Colin D Bennett <colin@gibibit.com>
1748
1749 New font engine.
1750
1751 Additional changes by Vesa Jääskeläinen <chaac@nic.fi> to adapt to
1752 build system and fixed gfxterm.c to work with different sized fonts.
1753
1754 * configure.ac: Changed UNIFONT_HEX to UNIFONT_BDF.
1755
1756 * configure: Re-generated.
1757
1758 * DISTLIST: Removed font/manager.c.
1759 Added font/font.c.
1760 Added font/font_cmd.c.
1761
1762 * Makefile.in: Changed UNIFONT_HEX to UNIFONT_BDF. Added Font tool
1763 compilation.
1764
1765 * include/grub/misc.h (grub_utf8_to_ucs4): Changed prototype. Changed users.
1766
1767 * kern/misc.c (grub_utf8_to_ucs4): Changed prototype.
1768
1769 * kern/term.c: Changed users of grub_utf8_to_ucs4.
1770
1771 * normal/menu.c: Likewise.
1772
1773 * conf/common.rmk (font_mod_SOURCES): Removed font/manager.c.
1774 (font_mod_SOURCES): Added font/font_cmd.c, font/font.c.
1775
1776 * include/grub/font.h: Replaced with new file.
1777
1778 * include/grub/video.h (GRUB_VIDEO_MODE_TYPE_ALPHA): Changed value.
1779 (GRUB_VIDEO_MODE_TYPE_DOUBLE_BUFFERED): Likewise.
1780 (GRUB_VIDEO_MODE_TYPE_COLOR_MASK): Likewise.
1781 (GRUB_VIDEO_MODE_TYPE_1BIT_BITMAP): Added.
1782 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_1BIT_PACKED.
1783 (grub_video_mode_info): Added bg_red, bg_green, bg_blue, bg_alpha,
1784 fg_red, fg_green, fg_blue, fg_alpha.
1785 (grub_video_adapter): Removed blit_glyph.
1786 (grub_video_blit_glyph): Removed.
1787
1788 * font/manager.c: Removed file.
1789
1790 * font/font.c: New file.
1791
1792 * font/font_cmd.c: Likewise.
1793
1794 * video/video.c (grub_video_blit_glyph): Removed.
1795
1796 * video/i386/pc/vbe.c (grub_video_vbe_map_rgb): Added 1-bit support.
1797 (grub_video_vbe_map_rgba): Likewise.
1798 (grub_video_vbe_unmap_color_int): Likewise.
1799 (grub_video_vbe_blit_glyph): Removed.
1800 (grub_video_vbe_adapter): Removed blit_glyph.
1801
1802 * video/i386/pc/vbeutil.c (get_data_ptr): Added 1-bit support.
1803 (get_pixel): Likewise.
1804 (set_pixel): Likewise.
1805
1806 * commands/videotest.c (grub_cmd_videotest): Added more tests for fonts.
1807
1808 * term/gfxterm.c: Adapted to new font engine.
1809
1810 * term/i386/pc/vesafb.c: Marked as deprecated. Made it compile.
1811
1812 * term/i386/pc/vga.c: Likewise.
1813
1814 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: New file.
1815
1816 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
1817
1818 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
1819
1820 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
1821
1822 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
1823
1824 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
1825
1826 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
1827
1828 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
1829
1830 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
1831
1832 * util/grub.d/00_header.in: Changed to use new loadfont command.
1833
1834 * util/grub-mkconfig_lib.in: Changed font extension.
1835
1836 2008-12-28 Felix Zielcke <fzielcke@z-51.de>
1837
1838 * util/getroot.c (grub_util_get_grub_dev): Add support for
1839 /dev/md/dNNpNN style partitionable mdraid devices.
1840
1841 2008-12-12 Alex Smith <alex@alex-smith.me.uk>
1842
1843 * fs/i386/pc/pxe.c (grub_pxefs_open): Handle the one open connection
1844 at a time limit of the PXE TFTP API correctly.
1845 (grub_pxefs_close): Likewise.
1846
1847 2008-11-29 Robert Millan <rmh@aybabtu.com>
1848
1849 * disk/ata.c (grub_ata_pciinit): Handle errors raised by
1850 grub_ata_device_initialize() calls.
1851
1852 2008-11-28 Krzysztof Smiechowicz <deadwood@wp.pl>
1853
1854 * fs/affs.c (grub_affs_iterate_dir): Return failure when directory
1855 iteration failed.
1856 * fs/sfs.c (grub_sfs_iterate_dir): Likewise.
1857
1858 2008-11-28 Robert Millan <rmh@aybabtu.com>
1859
1860 Fix build on powerpc-ieee1275. Based on patch created by
1861 Manoel Abranches <mrabran@linux.vnet.ibm.com>.
1862 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
1863 `kern/ieee1275/mmap.c'.
1864 * include/grub/powerpc/ieee1275/memory.h: New file.
1865
1866 Provide grub-install on coreboot.
1867 * conf/i386-coreboot.rmk (sbin_SCRIPTS): Add `grub-install'.
1868 (grub_install_SOURCES): New variable.
1869 * util/i386/pc/grub-install.in: Add a few condition checks to make it
1870 usable on coreboot.
1871
1872 2008-11-25 Felix Zielcke <fzielcke@z-51.de>
1873
1874 * util/grub-fstest.c (grub_term_get_current_input): Change return type
1875 to `grub_term_input_t'.
1876 (grub_term_get_current_output): Change return type to
1877 `grub_term_output_t'.
1878
1879 2008-11-22 Robert Millan <rmh@aybabtu.com>
1880
1881 Fix breakage on coreboot due to declaration mismatch.
1882 * term/i386/pc/vga_text.c (grub_vga_text_init_fini): New function.
1883 (grub_vga_text_term): Use grub_vga_text_init_fini() instead of
1884 grub_vga_text_cls().
1885
1886 * kern/i386/loader.S (grub_multiboot_backward_relocator): Improve
1887 comments. Avoid copying one more byte than necessary (just in case).
1888
1889 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Change link address
1890 to 0x200000 (avoids trouble with some OFW implementations, and matches
1891 with the one in Yaboot).
1892 Reported by Manoel Abranches
1893
1894 2008-11-20 Robert Millan <rmh@aybabtu.com>
1895
1896 * kern/i386/coreboot/init.c (grub_time_tics): Remove variable.
1897 (grub_get_rtc, grub_exit): Abort with grub_fatal() if called.
1898
1899 * util/grub-mkconfig_lib.in (grub_warn): New function.
1900 (convert_system_path_to_grub_path): Use grub_warn() when issuing
1901 warnings, to obtain consistent formatting.
1902 * util/grub.d/00_header.in: Likewise.
1903 * util/update-grub_lib.in: Likewise.
1904
1905 * loader/i386/linux.c (allocate_pages): Fix a warning.
1906 Move comment text to `#error' stanza.
1907
1908 Harmonize ieee1275's grub_available_iterate() with the generic
1909 grub_machine_mmap_iterate() interface (fixes a recently-introduced
1910 build problem on i386-ieee1275):
1911 * kern/ieee1275/openfw.c (grub_available_iterate): Moved from here ...
1912 * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): ... here. Add third
1913 parameter `type'. Update all users of this function.
1914 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
1915 `kern/ieee1275/mmap.c'.
1916 * kern/ieee1275/init.c
1917 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): Replace
1918 with ...
1919 (grub_machine_mmap_iterate): ... this.
1920 * include/grub/i386/pc/memory.h (grub_machine_mmap_iterate): Change
1921 return type to `grub_err_t'. Update all implementations of this
1922 function prototype.
1923 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_iterate):
1924 Likewise.
1925
1926 Add `lsmmap' command (lists firmware-provided memory map):
1927 * commands/lsmmap.c: New file.
1928 * conf/i386-pc.rmk (pkglib_MODULES): Add `lsmmap.mod'.
1929 (lsmmap_mod_SOURCES, lsmmap_mod_CFLAGS, lsmmap_mod_LDFLAGS): New
1930 variables.
1931 * conf/powerpc-ieee1275.rmk: Likewise.
1932 * conf/i386-coreboot.rmk: Likewise.
1933 * conf/i386-ieee1275.rmk: Likewise.
1934
1935 2008-11-19 Robert Millan <rmh@aybabtu.com>
1936
1937 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Fix a typo.
1938 * loader/i386/linux.c (grub_rescue_cmd_initrd): Implement a few needed
1939 constraints to initrd allocation (based on code from
1940 loader/i386/pc/linux.c). Without them, initrd was allocated too high
1941 for Linux to find it.
1942
1943 2008-11-14 Robert Millan <rmh@aybabtu.com>
1944
1945 * fs/cpio.c (grub_cpio_open): Compare `name' and `fn' by hand in
1946 order to cope with duplicate slashes.
1947
1948 2008-11-14 Robert Millan <rmh@aybabtu.com>
1949
1950 * include/grub/i386/coreboot/memory.h (GRUB_MEMORY_MACHINE_LOWER_SIZE):
1951 Redefine to match with GRUB_MEMORY_MACHINE_UPPER_START (0x100000). We
1952 don't want to mess with lower memory, because it is used in the Linux
1953 loader.
1954
1955 * loader/i386/linux.c (allocate_pages): Allocate `real_mode_mem' in
1956 an appropriate place in lower memory, between 0x10000 and 0x90000,
1957 like loader/i386/efi/linux.c does. Linux often panics if real_mode_mem
1958 is in our heap (probably as a result of it being corrupted during
1959 decompression). Add #error instance with comment to explain why this
1960 loader isn't currently usable on PC/BIOS.
1961
1962 2008-11-14 Robert Millan <rmh@aybabtu.com>
1963
1964 * term/i386/pc/serial.c [! GRUB_MACHINE_PCBIOS]
1965 (GRUB_SERIAL_PORT_NUM): Fix miscalculation.
1966
1967 2008-11-12 Robert Millan <rmh@aybabtu.com>
1968
1969 Make loader/i386/linux.c buildable on i386-pc (although disabled).
1970
1971 * include/grub/i386/pc/init.h: Include `<grub/machine/memory.h>'.
1972 (struct grub_machine_mmap_entry, grub_machine_mmap_iterate): Move
1973 from here ...
1974 * include/grub/i386/pc/memory.h: ... to here.
1975
1976 2008-11-12 Robert Millan <rmh@aybabtu.com>
1977
1978 Fix build problems on i386-ieee1275 and *-efi (introduced by vga_text
1979 split).
1980
1981 * include/grub/i386/pc/console.h: Include `<grub/i386/vga_common.h>'.
1982 (grub_console_cur_color, grub_console_real_putchar)
1983 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
1984 (grub_console_setcolorstate, grub_console_setcolor)
1985 (grub_console_getcolor): Move from here ...
1986 * include/grub/i386/vga_common.h: ... to here (new file).
1987
1988 * term/i386/pc/vga_text.c: Replace `<grub/machine/console.h>' with
1989 `<grub/i386/vga_common.h>' and `<grub/cpu/io.h>' with
1990 `<grub/i386/io.h>'.
1991 * term/i386/vga_common.c: Replace `<grub/machine/console.h>' with
1992 `<grub/i386/vga_common.h>'.
1993
1994 2008-11-12 Robert Millan <rmh@aybabtu.com>
1995
1996 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `term/i386/vga_common.c'.
1997 * conf/i386.rmk (pkglib_MODULES): Add `vga_text.mod'.
1998 (vga_text_mod_SOURCES, vga_text_mod_CFLAGS, vga_text_mod_LDFLAGS): New
1999 variables.
2000 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
2001 `term/i386/pc/console.c' with `term/i386/vga_common.c'.
2002
2003 * kern/i386/coreboot/init.c (grub_machine_init): Replace call to
2004 grub_console_init() with call to grub_vga_text_init().
2005 (grub_machine_fini): Replace call to
2006 grub_console_fini() with call to grub_vga_text_fini() and
2007 grub_at_keyboard_fini().
2008
2009 * include/grub/i386/pc/console.h: Include `<grub/term.h>'.
2010 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
2011 (grub_console_setcolorstate, grub_console_setcolor)
2012 (grub_console_getcolor): New function prototypes.
2013
2014 * term/i386/pc/vga_text.c: Include `<grub/dl.h>'.
2015 (grub_vga_text_getxy, grub_vga_text_gotoxy, grub_vga_text_cls)
2016 (grub_vga_text_setcursor): Static-ize.
2017 (grub_vga_text_term): New structure.
2018 (GRUB_MOD_INIT(vga_text), GRUB_MOD_FINI(vga_text)): New functions.
2019
2020 * term/i386/pc/console.c: Remove `<grub/machine/machine.h>'.
2021 (grub_console_cur_color, grub_console_standard_color)
2022 (grub_console_normal_color, grub_console_highlight_color)
2023 (map_char, grub_console_putchar, grub_console_getcharwidth)
2024 (grub_console_getwh, grub_console_setcolorstate, grub_console_setcolor)
2025 (grub_console_getcolor): Move from here ...
2026 * term/i386/vga_common.c: ... to here (same function names).
2027
2028 2008-11-12 Robert Millan <rmh@aybabtu.com>
2029
2030 Use newly-added Multiboot support in coreboot.
2031
2032 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
2033 `kern/i386/coreboot/mmap.c' with `kern/i386/multiboot_mmap.c'.
2034
2035 * kern/i386/coreboot/startup.S: Enable Multiboot header, fix its
2036 alignment, set `MULTIBOOT_MEMORY_INFO' flag.
2037 (codestart): Store the MBI in `startup_multiboot_info' when we're
2038 being loaded using Multiboot.
2039
2040 * kern/i386/coreboot/init.c (grub_machine_init): Move
2041 grub_at_keyboard_init() call to beginning of function (useful for
2042 debugging). Call grub_machine_mmap_init() before attempting to use
2043 grub_machine_mmap_iterate().
2044 (grub_lower_mem, grub_upper_mem): Move from here ...
2045 * kern/i386/multiboot_mmap.c (grub_lower_mem, grub_upper_mem): ... to
2046 here (new file).
2047
2048 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_init): New
2049 function prototype.
2050
2051 2008-11-12 Robert Millan <rmh@aybabtu.com>
2052
2053 Fix a regression introduced by the at_keyboard.mod split. Because
2054 some terminals are default on some platforms and non-default on
2055 others, the first terminal being registered determines which is
2056 going to be default.
2057
2058 * kern/term.c (grub_term_register_input): If this is the first
2059 terminal being registered, set it as the current one.
2060 (grub_term_register_output): Likewise.
2061
2062 * term/efi/console.c (grub_console_init): Do not call
2063 grub_term_set_current_output() or grub_term_set_current_input().
2064 * term/ieee1275/ofconsole.c (grub_console_init): Likewise.
2065 * term/i386/pc/console.c (grub_console_init): Likewise.
2066 (grub_console_fini): Do not call grub_term_set_current_input()
2067 (but leave grub_term_set_current_output() to restore text mode).
2068
2069 2008-11-10 Robert Millan <rmh@aybabtu.com>
2070
2071 * util/grub.d/00_header.in: Add backward compatibility check for
2072 versions of terminal.mod that don't understand `terminal_input' or
2073 `terminal_output'.
2074
2075 2008-11-09 Robert Millan <rmh@aybabtu.com>
2076
2077 * commands/terminal.c (GRUB_MOD_FINI(terminal)): Unregister
2078 `terminal_input' / `terminal_output', not `terminal'.
2079
2080 2008-11-08 Robert Millan <rmh@aybabtu.com>
2081
2082 * Makefile.in (include_DATA): Fix srcdir=. assumption.
2083 (DISTCLEANFILES): Add `build_env.mk'.
2084
2085 2008-11-08 Robert Millan <rmh@aybabtu.com>
2086
2087 * term/i386/pc/vesafb.c (grub_vesafb_term): Change type to
2088 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
2089 members. Update all users.
2090 * util/console.c (grub_ncurses_term): Split in ...
2091 (grub_ncurses_term_input): ... this, and ...
2092 (grub_ncurses_term_output): ... this. Update all users.
2093 * term/ieee1275/ofconsole.c: Remove stale `#endif'.
2094
2095 2008-11-08 Robert Millan <rmh@aybabtu.com>
2096
2097 * Makefile.in (PKGLIB): Add $(pkglib_BUILDDIR).
2098 (PKGDATA): Add $(pkgdata_SRCDIR).
2099 (pkglib_BUILDDIR): New variable.
2100 (pkgdata_SRCDIR): New variable.
2101 (build_env.mk): New target.
2102 (include_DATA): New variable.
2103 (install-local): Install $(include_DATA) files in $(includedir).
2104
2105 2008-11-07 Pavel Roskin <proski@gnu.org>
2106
2107 * gendistlist.sh: Use C locale for sorting to ensure consistent
2108 output on all systems.
2109
2110 * util/grub.d/00_header.in: Remove incorrect space before
2111 "serial".
2112
2113 2008-11-07 Robert Millan <rmh@aybabtu.com>
2114
2115 * include/multiboot2.h (struct multiboot_header): Add `flags' member as
2116 per specification.
2117 * loader/multiboot2.c (grub_multiboot2): Fix Multiboot2 header check.
2118 * loader/multiboot_loader.c (find_multi_boot2_header): New function
2119 (based on find_multi_boot1_header).
2120 (grub_rescue_cmd_multiboot_loader): Check for Multiboot2 header,
2121 using find_multi_boot2_header(), and abort if neither Multiboot or
2122 Multiboot headers were found.
2123
2124 2008-11-07 Robert Millan <rmh@aybabtu.com>
2125
2126 Modularize at_keyboard.mod:
2127
2128 * conf/i386.rmk (pkglib_MODULES): Add `at_keyboard.mod'.
2129 (at_keyboard_mod_SOURCES, at_keyboard_mod_CFLAGS)
2130 (at_keyboard_mod_LDFLAGS): New variables.
2131
2132 Actual terminal split:
2133
2134 * include/grub/term.h (struct grub_term): Split in ...
2135 (struct grub_term_input): ... this, and ...
2136 (struct grub_term_output): ... this. Update all users.
2137 (grub_term_set_current): Split in ...
2138 (grub_term_set_current_input): ... this, and ...
2139 (grub_term_set_current_output): ... this.
2140 (grub_term_get_current): Split in ...
2141 (grub_term_get_current_input): ... this, and ...
2142 (grub_term_get_current_output): ... this.
2143 (grub_term_register): Split in ...
2144 (grub_term_register_input): ... this, and ...
2145 (grub_term_register_output): ... this.
2146 (grub_term_unregister): Split in ...
2147 (grub_term_unregister_input): ... this, and ...
2148 (grub_term_unregister_output): ... this.
2149 (grub_term_iterate): Split in ...
2150 (grub_term_iterate_input): ... this, and ...
2151 (grub_term_iterate_output): ... this.
2152
2153 * kern/term.c (grub_term_list): Split in ...
2154 (grub_term_list_input): ... this, and ...
2155 (grub_term_list_output): ... this. Update all users.
2156 (grub_cur_term): Split in ...
2157 (grub_cur_term_input): ... this, and ...
2158 (grub_cur_term_output): ... this. Update all users.
2159 (grub_term_set_current): Split in ...
2160 (grub_term_set_current_input): ... this, and ...
2161 (grub_term_set_current_output): ... this.
2162 (grub_term_get_current): Split in ...
2163 (grub_term_get_current_input): ... this, and ...
2164 (grub_term_get_current_output): ... this.
2165 (grub_term_register): Split in ...
2166 (grub_term_register_input): ... this, and ...
2167 (grub_term_register_output): ... this.
2168 (grub_term_unregister): Split in ...
2169 (grub_term_unregister_input): ... this, and ...
2170 (grub_term_unregister_output): ... this.
2171 (grub_term_iterate): Split in ...
2172 (grub_term_iterate_input): ... this, and ...
2173 (grub_term_iterate_output): ... this.
2174
2175 * kern/misc.c (grub_abort): Split use of grub_term_get_current() into
2176 a check for input and one for output (and only attempt to get keys
2177 from user when input works).
2178
2179 * util/grub-probe.c (grub_term_get_current): Split in ...
2180 (grub_term_get_current_input): ... this, and ...
2181 (grub_term_get_current_output): ... this.
2182 * util/grub-fstest.c: Likewise.
2183 * util/i386/pc/grub-setup.c: Likewise.
2184 * util/grub-editenv.c: Likewise.
2185
2186 Portability adjustments:
2187
2188 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Remove
2189 `term/i386/pc/at_keyboard.c'.
2190 * kern/ieee1275/init.c [__i386__] (grub_machine_init): Remove call to
2191 grub_keyboard_controller_init() (now handled by terminal .init).
2192 * kern/i386/coreboot/init.c (grub_machine_init): Add call to
2193 grub_at_keyboard_init().
2194 * include/grub/i386/ieee1275/console.h (grub_keyboard_controller_init)
2195 (grub_console_checkkey, grub_console_getkey): Remove (now provided by
2196 at_keyboard.mod via input terminal interface).
2197 * include/grub/i386/coreboot/console.h: Convert into a stub for
2198 `<grub/i386/pc/console.h>'.
2199
2200 Migrate full terminals to new API:
2201
2202 * term/efi/console.c (grub_console_term): Split into ...
2203 (grub_console_term_input): ... this, and ...
2204 (grub_console_term_output): ... this. Update all users.
2205 * term/ieee1275/ofconsole.c: Remove __i386__ hack.
2206 (grub_ofconsole_init): Split into ...
2207 (grub_ofconsole_init_input): ... this, and ...
2208 (grub_ofconsole_init_output): ... this.
2209 (grub_ofconsole_term): Split into ...
2210 (grub_ofconsole_term_input): ... this, and ...
2211 (grub_ofconsole_term_output): ... this. Update all users.
2212 * term/i386/pc/serial.c (grub_serial_term): Split into ...
2213 (grub_serial_term_input): ... this, and ...
2214 (grub_serial_term_output): ... this. Update all users.
2215 * term/i386/pc/console.c (grub_console_term): Split into ...
2216 (grub_console_term_input): ... this, and ...
2217 (grub_console_term_output): ... this. Update all users.
2218 (grub_console_term_input): Only enable it on PC/BIOS platform.
2219 (grub_console_init): Remove grub_keyboard_controller_init() call.
2220
2221 Migrate input terminals to new API:
2222
2223 * term/i386/pc/at_keyboard.c: Replace `cpu' and `machine' with
2224 `i386' and `i386/pc' to enable build on x86_64 (this driver is
2225 i386-specific anyway).
2226 (grub_console_checkkey): Rename to ...
2227 (grub_at_keyboard_checkkey): ... this. Static-ize. Update all
2228 users.
2229 (grub_keyboard_controller_orig): New variable.
2230 (grub_console_getkey): Rename to ...
2231 (grub_at_keyboard_getkey): ... this. Static-ize. Update all
2232 users.
2233 (grub_keyboard_controller_init): Static-ize. Save original
2234 controller value so that it can be restored ...
2235 (grub_keyboard_controller_fini): ... here (new function).
2236 (grub_at_keyboard_term): New structure.
2237 (GRUB_MOD_INIT(at_keyboard), GRUB_MOD_FINI(at_keyboard)): New
2238 functions.
2239
2240 Migrate output terminals to new API:
2241
2242 * term/i386/pc/vga.c (grub_vga_term): Change type to
2243 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
2244 members. Update all users.
2245 * term/gfxterm.c (grub_video_term): Change type to
2246 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
2247 members. Update all users.
2248 * include/grub/i386/pc/console.h (grub_console_checkkey)
2249 (grub_console_getkey): Do not export (no longer needed by gfxterm,
2250 etc).
2251
2252 Migrate `terminal' command and userland tools to new API:
2253
2254 * commands/terminal.c (grub_cmd_terminal): Split into ...
2255 (grub_cmd_terminal_input): ... this, and ...
2256 (grub_cmd_terminal_output): ... this.
2257 (GRUB_MOD_INIT(terminal)): Split `terminal' command in two commands:
2258 `terminal_input' and `terminal_output'.
2259 * util/grub.d/00_header.in: Adjust `terminal' calls to new
2260 `terminal_input' / `terminal_output' API.
2261 * util/grub-mkconfig.in: Export ${GRUB_TERMINAL_INPUT} and
2262 ${GRUB_TERMINAL_OUTPUT} instead of ${GRUB_TERMINAL} (and if user
2263 provided ${GRUB_TERMINAL}, convert it).
2264
2265 2008-11-04 Robert Millan <rmh@aybabtu.com>
2266
2267 * util/grub.d/10_freebsd.in: New file. Generate grub configuration
2268 for FreeBSD.
2269 * conf/common.rmk (grub-mkconfig_SCRIPTS): Add 10_freebsd.
2270
2271 2008-11-03 Bean <bean123ch@gmail.com>
2272
2273 * kern/elf.c (grub_elf32_load): Revert to previous code.
2274 (grub_elf64_load): Likewise.
2275
2276 * loader/i386/bsd.c (grub_bsd_elf32_hook): Change return address.
2277
2278 2008-11-01 Robert Millan <rmh@aybabtu.com>
2279
2280 * Makefile.in (CPPFLAGS): Fix builddir=. assumption.
2281 (TARGET_CPPFLAGS): Likewise.
2282 * genmk.rb (mod_src): Fix builddir=. and srcdir=. assumptions.
2283
2284 2008-11-01 Carles Pina i Estany <carles@pina.cat>
2285
2286 * normal/menu.c (run_menu): Add Previous and Next Page keys in menu.
2287
2288 2008-10-29 Guillem Jover <guillem.jover@nokia.com>
2289
2290 * disk/lvm.c (grub_lvm_scan_device): Fix error recovery by delaying the
2291 addition of objects until the code is not going to be able to fail.
2292
2293 2008-10-29 Guillem Jover <guillem.jover@nokia.com>
2294
2295 * disk/lvm.c (grub_lvm_scan_device): Fix possible NULL value handling
2296 (add a missing NULL check, and correct them by moving the pointer
2297 operations after the actual check).
2298
2299 2008-10-29 Robert Millan <rmh@aybabtu.com>
2300
2301 * util/i386/pc/grub-install.in: Handle empty string as output from
2302 make_system_path_relative_to_its_root().
2303
2304 2008-10-05 Hans Lambermont <hans@lambermont.dyndns.org>
2305
2306 * disk/lvm.c (grub_lvm_scan_device): Allocate buffer space for the
2307 circular metadata worst case scenario. If the metadata is circular
2308 then copy the wrap in place.
2309 * include/grub/lvm.h: Add GRUB_LVM_MDA_HEADER_SIZE, from the LVM2
2310 project lib/format_text/layout.h
2311 Circular metadata bug found and patch debugged by Jan Derk Gerlings.
2312
2313 2008-10-03 Felix Zielcke <fzielcke@z-51.de>
2314
2315 * util/i386/pc/grub-install.in: Source grub-mkconfig_lib instead of update-grub_lib.
2316
2317 2008-10-03 Felix Zielcke <fzielcke@z-51.de>
2318
2319 * util/update-grub_lib.in: Mention filename in warning message.
2320
2321 2008-09-29 Felix Zielcke <fzielcke@z-51.de>
2322
2323 * NEWS: Update for rename of update-grub to grub-mkconfig.
2324
2325 2008-09-29 Felix Zielcke <fzielcke@z-51.de>
2326
2327 * util/update-grub_lib.in: Copy to ...
2328 * util/grub-mkconfig_lib.in: ... this. Update all users.
2329 * util/update-grub_lib.in: Make it a stub to `grub-mkconfig_lib.in'.
2330 * util/update-grub.in: Rename to ...
2331 * util/grub-mkconfig.in: ... this. Update all users. Remove `-y'
2332 option. Add `--output' option to allow users to specify the generated
2333 configuration file. Default to stdout.
2334 (update_grub_dir): Rename to ...
2335 (grub_mkconfig_dir): ... this.
2336 (grub_cfg): Default to an empty string.
2337 * conf/common.rmk (update-grub): Rename to ...
2338 (grub-mkconfig): ... this.
2339 (update-grub_lib): Copy to ...
2340 (grub-mkconfig_lib): ... this.
2341 (update-grub_SCRIPTS): Copy to ...
2342 (grub-mkconfig_SCRIPTS): ... this. Update all users.
2343 (update-grub_DATA): Rename to ...
2344 (grub-mkconfig_DATA): ... this.
2345
2346 2008-09-28 Robert Millan <rmh@aybabtu.com>
2347
2348 * fs/iso9660.c (struct grub_iso9660_primary_voldesc): Rename `created'
2349 to `modified'. Add the real `created' field.
2350 (grub_iso9660_uuid): Use `modified' rather than `created' for
2351 constructing the UUID.
2352
2353 2008-09-28 Felix Zielcke <fzielcke@z-51.de>
2354
2355 fs/jfs.c (grub_jfs_find_file): Treat multiple slashes like one.
2356 Based on code from Tomas Ebenlendr <ebik@ucw.cz>.
2357
2358 2008-09-28 Bean <bean123ch@gmail.com>
2359
2360 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a bug in the previous patch.
2361 Thanks to Christian Franke for finding this bug.
2362
2363 2008-09-25 Robert Millan <rmh@aybabtu.com>
2364
2365 * util/grub-mkdevicemap.c (make_device_map): Actually replace all
2366 instances of grub_util_get_disk_name() (see previous commit).
2367
2368 2008-09-25 Robert Millan <rmh@aybabtu.com>
2369
2370 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Remove
2371 `util/i386/get_disk_name.c'.
2372 * conf/i386-efi.rmk: Likewise.
2373 * conf/x86_64-efi.rmk: Likewise.
2374 * conf/i386-coreboot.rmk: Likewise.
2375 * conf/i386-ieee1275.rmk: Likewise.
2376 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Remove
2377 `util/ieee1275/get_disk_name.c'.
2378 * include/grub/util/misc.h (grub_util_get_disk_name): Remove.
2379 * util/ieee1275/get_disk_name.c: Remove file.
2380 * util/i386/get_disk_name.c: Remove file.
2381 * util/grub-mkdevicemap.c (make_device_map): Back to hardcoding
2382 "hd%d" for device.map entries, rather than using
2383 grub_util_get_disk_name().
2384
2385 2008-09-24 Carles Pina i Estany <carles@pina.cat>
2386
2387 * disk/dmraid_nvidia.c (grub_dmraid_nv_detect): Fix `unused parameter'
2388 warning.
2389 * commands/i386/pc/pxecmd.c (dmraid_nvidia): Likewise.
2390
2391 2008-09-24 Carles Pina i Estany <carles@pina.cat>
2392
2393 * include/grub/i386/pc/console.h (GRUB_TERM_NPAGE):
2394 Changed to 0x5100.
2395 (GRUB_TERM_PPAGE): Changed to 0x4900.
2396
2397 2008-09-24 Robert Millan <rmh@aybabtu.com>
2398
2399 * include/grub/powerpc/ieee1275/console.h (GRUB_CONSOLE_KEY_*): Remove
2400 macros (they were i386-pc specific).
2401 * include/grub/sparc64/ieee1275/console.h: Likewise.
2402 * include/grub/efi/console.h: Likewise.
2403
2404 2008-09-22 Bean <bean123ch@gmail.com>
2405
2406 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a rare case where $BITMAP is
2407 resident and in attribute list.
2408
2409 * include/grub/ntfs.h (BMP_LEN): Removed.
2410
2411 2008-09-22 Bean <bean123ch@gmail.com>
2412
2413 * disk/ata.c (grub_atapi_open): Initialize devfnd, no need to set
2414 scsi->name and scsi->luns, as they will be set in grub_scsi_open.
2415
2416 * disk/scsi.c (grub_scsi_open): Don't call p->close (scsi) here when
2417 error occurs, as grub_disk_open will call grub_disk_close, which will
2418 call p->close (scsi).
2419
2420 2008-09-21 Felix Zielcke <fzielcke@z-51.de>
2421
2422 * configure.ac (AC_INIT): Quote `GRUB' string and version number.
2423 (AC_PREREQ): Bumped to 2.59.
2424 (AC_TRY_COMPILE): Replace obsolete macro with ...
2425 (AC_COMPILE_IFELSE): ... this.
2426 * aclocal.m4 (AC_TRY_LINK): Replace obsolete macro with ...
2427 (AC_LINK_IFELSE): ... this.
2428
2429 2008-09-21 Felix Zielcke <fzielcke@z-51.de>
2430
2431 * autogen.sh: Add a call to `gendistlist.sh'.
2432
2433 2008-09-19 Christian Franke <franke@computer.org>
2434
2435 * aclocal.m4 (grub_CHECK_ENABLE_EXECUTE_STACK): New function.
2436 * configure.ac: Call grub_CHECK_ENABLE_EXECUTE_STACK.
2437 * include/grub/misc.h [NEED_ENABLE_EXECUTE_STACK]:
2438 Export __enable_execute_stack() to modules.
2439 * kern/misc.c [NEED_ENABLE_EXECUTE_STACK] (__enable_execute_stack):
2440 New function.
2441
2442 2008-09-09 Felix Zielcke <fzielcke@z-51.de>
2443
2444 * Makefile.in (RMKFILES): Add `i386.rmk' and `x86_64-efi.rmk'.
2445 Sort the list.
2446
2447 2008-09-09 Felix Zielcke <fzielcke@z-51.de>
2448
2449 * util/hostdisk.c: Replace #include <grub/util/biosdisk.h> with
2450 #include <grub/util/hostdisk.h>.
2451
2452 2008-09-08 Robert Millan <rmh@aybabtu.com>
2453
2454 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Skip
2455 segments when their filesz is zero (grub_file_read() interprets
2456 zero-size as "read until EOF", which results in memory corruption).
2457 Use `lowest_segment' rather than 0 for calculating the current
2458 segment load address.
2459
2460 2008-09-08 Robert Millan <rmh@aybabtu.com>
2461
2462 * util/hostdisk.c (open_device): Replace a grub_util_info() call
2463 with grub_dprintf("hostdisk", ...), as it was so verbose that it
2464 clobbered useful information.
2465
2466 2008-09-08 Robert Millan <rmh@aybabtu.com>
2467
2468 * include/grub/util/biosdisk.h: Move to ...
2469 * include/grub/util/hostdisk.h: ... here. Update all users.
2470 * util/biosdisk.c: Move to ...
2471 * util/hostdisk.c: ... here. Update all users.
2472
2473 2008-09-07 Robert Millan <rmh@aybabtu.com>
2474
2475 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): Remove
2476 variables.
2477 (grub_multiboot): Move `mbi' allocation upwards, so that mmap address
2478 and length can be stored directly in the `mbi->mmap_addr' and
2479 `mbi->mmap_length' struct fields.
2480
2481 2008-09-07 Robert Millan <rmh@aybabtu.com>
2482
2483 * conf/i386.rmk: New file. Provides declaration for building
2484 `cpuid.mod'.
2485 * conf/i386-pc.rmk (pkglib_MODULES): Remove `cpuid.mod'.
2486 (cpuid_mod_SOURCES, cpuid_mod_CFLAGS, cpuid_mod_LDFLAGS): Remove
2487 variables.
2488 Include `conf/i386.mk'.
2489 * conf/i386-efi.rmk: Likewise.
2490 * conf/x86_64-efi.rmk: Likewise.
2491 * conf/i386-coreboot.rmk: Likewise.
2492 * conf/i386-ieee1275.rmk: Likewise.
2493
2494 2008-09-07 Vesa Jääskeläinen <chaac@nic.fi>
2495
2496 Based on patch created by Colin D Bennett <colin@gibibit.com>.
2497 Adds optimization support for BGR based modes.
2498
2499 * include/grub/i386/pc/vbeblit.h (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8) Removed.
2500 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
2501 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
2502 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
2503 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
2504 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
2505 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
2506 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
2507 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
2508 (grub_video_i386_vbeblit_index_index): Likewise.
2509 (grub_video_i386_vbeblit_replace_directN): Added.
2510 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
2511 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
2512 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
2513 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
2514 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
2515 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
2516 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
2517 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
2518 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
2519 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
2520 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
2521 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
2522 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
2523
2524 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8) Removed.
2525 (grub_video_i386_vbefill_R8G8B8): Likewise.
2526 (grub_video_i386_vbefill_index): Likewise.
2527 (grub_video_i386_vbefill_direct32): Added.
2528 (grub_video_i386_vbefill_direct24): Likewise.
2529 (grub_video_i386_vbefill_direct16): Likewise.
2530 (grub_video_i386_vbefill_direct8): Likewise.
2531
2532 * include/grub/video.h (grub_video_blit_format): Removed
2533 GRUB_VIDEO_BLIT_FORMAT_R8G8B8A8, GRUB_VIDEO_BLIT_FORMAT_R8G8B8.
2534 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_RGBA_8888,
2535 GRUB_VIDEO_BLIT_FORMAT_BGRA_8888, GRUB_VIDEO_BLIT_FORMAT_RGB_888,
2536 GRUB_VIDEO_BLIT_FORMAT_BGR_888, GRUB_VIDEO_BLIT_FORMAT_RGB_565,
2537 GRUB_VIDEO_BLIT_FORMAT_BGR_565.
2538
2539 * video/video.c (grub_video_get_blit_format): Updated to use new
2540 blit formats. Added handling for 16 bit color modes.
2541
2542 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Updated to use new
2543 fillers.
2544 (common_blitter): Updated to use new blitters.
2545
2546 * video/i386/pc/vbeblit.c (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8):
2547 Removed.
2548 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
2549 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
2550 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
2551 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
2552 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
2553 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
2554 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
2555 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
2556 (grub_video_i386_vbeblit_index_index): Likewise.
2557 (grub_video_i386_vbeblit_replace_directN): Added.
2558 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
2559 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
2560 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
2561 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
2562 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
2563 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
2564 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
2565 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
2566 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
2567 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
2568 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
2569 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
2570 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
2571
2572 * video/i386/pc/vbefill.c (grub_video_i386_vbefill_R8G8B8A8): Removed.
2573 (grub_video_i386_vbefill_R8G8B8): Likewise.
2574 (grub_video_i386_vbefill_index): Likewise.
2575 (grub_video_i386_vbefill_direct32): Added.
2576 (grub_video_i386_vbefill_direct24): Likewise.
2577 (grub_video_i386_vbefill_direct16): Likewise.
2578 (grub_video_i386_vbefill_direct8): Likewise.
2579
2580 * video/readers/jpeg.c (grub_jpeg_decode_sos): Adapt to new blitter
2581 types.
2582
2583 * video/readers/tga.c (grub_video_reader_tga): Adapt to new blitter
2584 types.
2585
2586 * video/readers/png.c (grub_png_decode_image_header): Adapt to new
2587 blitter types.
2588
2589 * video/bitmap.c (grub_video_bitmap_create): Adapt to new blitter
2590 types.
2591
2592 2008-09-06 Felix Zielcke <fzielcke@z-51.de>
2593
2594 * disk/raid.c (insert_array): Set `array->chunk_size' to 64 for
2595 RAID level 1.
2596
2597 2008-09-06 Felix Zielcke <fzielcke@z-51.de>
2598
2599 * fs/iso9660.c (grub_iso9660_date): New structure.
2600 (grub_iso9660_primary_voldesc): Add `grub_iso9660_date' member.
2601 (grub_iso9660_uuid): New function.
2602
2603 2008-09-05 Bean <bean123ch@gmail.com>
2604
2605 * fs/fshelp.c (grub_fshelp_find_file): Handle case insensitive names.
2606
2607 * fs/ntfs.c (list_file): Ignore names in DOS namespace, set the case
2608 insensitive bit for names in Win32 and Win32 & DOS namespace.
2609
2610 * include/grub/fshelp.h (GRUB_FSHELP_CASE_INSENSITIVE): New macro.
2611
2612 * include/grub/types.h (LONG_MAX): Likewise.
2613
2614 2008-09-04 Felix Zielcke <fzielcke@z-51.de>
2615
2616 * util/getroot.c: Include <config.h>.
2617 (grub_util_get_grub_dev): Rewrite to use asprintf for mdraid devices,
2618 add support for /dev/md/N devices and handle LVM double dash escaping.
2619
2620 2008-09-04 Felix Zielcke <fzielcke@z-51.de>
2621
2622 * config.guess: Update to latest version from config git.
2623 * config.sub: Likewise.
2624
2625 2008-09-03 Robert Millan <rmh@aybabtu.com>
2626
2627 * disk/scsi.c (grub_scsi_open): Remove size limit when printing
2628 `disk->total_sectors'.
2629
2630 2008-09-01 Colin D Bennett <colin@gibibit.com>
2631
2632 * include/grub/normal.h: Fixed incorrect comment for
2633 GRUB_COMMAND_FLAG_NO_ARG_PARSE.
2634
2635 2008-09-01 Colin D Bennett <colin@gibibit.com>
2636
2637 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Replaced constant
2638 values with defines.
2639
2640 * include/grub/i386/pc/vbe.h (GRUB_VBE_MODEATTR_SUPPORTED): Added.
2641 (GRUB_VBE_MODEATTR_RESERVED_1): Likewise.
2642 (GRUB_VBE_MODEATTR_BIOS_TTY_OUTPUT_SUPPORT): Likewise.
2643 (GRUB_VBE_MODEATTR_COLOR): Likewise.
2644 (GRUB_VBE_MODEATTR_GRAPHICS): Likewise.
2645 (GRUB_VBE_MODEATTR_VGA_COMPATIBLE): Likewise.
2646 (GRUB_VBE_MODEATTR_VGA_WINDOWED_AVAIL): Likewise.
2647 (GRUB_VBE_MODEATTR_LFB_AVAIL): Likewise.
2648 (GRUB_VBE_MODEATTR_DOUBLE_SCAN_AVAIL): Likewise.
2649 (GRUB_VBE_MODEATTR_INTERLACED_AVAIL): Likewise.
2650 (GRUB_VBE_MODEATTR_TRIPLE_BUF_AVAIL): Likewise.
2651 (GRUB_VBE_MODEATTR_STEREO_AVAIL): Likewise.
2652 (GRUB_VBE_MODEATTR_DUAL_DISPLAY_START): Likewise.
2653 (GRUB_VBE_MEMORY_MODEL_TEXT): Likewise.
2654 (GRUB_VBE_MEMORY_MODEL_CGA): Likewise.
2655 (GRUB_VBE_MEMORY_MODEL_HERCULES): Likewise.
2656 (GRUB_VBE_MEMORY_MODEL_PLANAR): Likewise.
2657 (GRUB_VBE_MEMORY_MODEL_NONCHAIN4_256): Likewise.
2658 (GRUB_VBE_MEMORY_MODEL_YUV): Likewise.
2659
2660 2008-08-31 Robert Millan <rmh@aybabtu.com>
2661
2662 * loader/i386/pc/multiboot.c (grub_get_multiboot_mmap_len): Fix
2663 declaration.
2664 (grub_multiboot): Fix a few warnings.
2665
2666 2008-08-31 Robert Millan <rmh@aybabtu.com>
2667
2668 * loader/i386/pc/multiboot.c: Update comment not to say that
2669 boot_device support is unimplemented.
2670
2671 2008-08-31 Robert Millan <rmh@aybabtu.com>
2672
2673 * loader/i386/pc/multiboot.c: Update comment not to say that a.out
2674 or memory map support are unimplemented.
2675
2676 2008-08-31 Colin D Bennett <colin@gibibit.com>
2677
2678 * util/i386/pc/grub-mkrescue.in: Support multiple overlay directories.
2679
2680 2008-08-31 Colin D Bennett <colin@gibibit.com>
2681
2682 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Show VBE version and
2683 total video memory in 'vbeinfo' output; show color format details for
2684 each video mode.
2685
2686 2008-08-30 Pavel Roskin <proski@gnu.org>
2687
2688 * util/genmoddep.c: Remove for real this time.
2689 * DISTLIST: Remove util/genmoddep.c.
2690
2691 2008-08-30 Robert Millan <rmh@aybabtu.com>
2692
2693 * kern/i386/pc/startup.S (multiboot_header): Force 4-byte alignment
2694 as required by Multiboot spec (it was already 4-byte aligned, but
2695 only by chance).
2696
2697 2008-08-29 Pavel Roskin <proski@gnu.org>
2698
2699 * kern/powerpc/ieee1275/crt0.S: Rename to ...
2700 * kern/powerpc/ieee1275/startup.S: ... this.
2701 * conf/powerpc-ieee1275.rmk: Adjust for the above.
2702 * DISTLIST: Likewise.
2703
2704 * kern/powerpc/ieee1275/crt0.S: Include grub/symbol.h and
2705 grub/cpu/kernel.h. Add start label for consistency with other
2706 platforms. Add grub_prefix immediately after start. Add jump
2707 to the code after grub_prefix.
2708 * include/grub/powerpc/kernel.h: Provide valid values for
2709 GRUB_KERNEL_CPU_PREFIX and GRUB_KERNEL_CPU_DATA_END.
2710
2711 2008-08-29 Bean <bean123ch@gmail.com>
2712
2713 * configure.ac: Change host_os to cygwin for mingw.
2714 (asprintf): New check for function.
2715
2716 * include/grub/symbol.h: Replace #ifndef __CYGWIN__ with
2717 #if ! defined (__CYGWIN__) && ! defined (__MINGW32__).
2718
2719 * include/grub/util/misc.h: #include <config.h> and <grub/types.h>,
2720 declare asprintf if HAVE_ASPRINTF is not set, declare fseeko, ftello,
2721 sync, sleep and grub_util_get_disk_size for mingw.
2722
2723 * util/biosdisk.c (grub_util_biosdisk_open): Use grub_util_get_disk_size
2724 to get size in mingw.
2725 (open_device): Use flag O_BINARY if it's defined.
2726 (find_root_device): Add dummy code for mingw.
2727
2728 * util/grub-mkdevicemap.c (get_floppy_disk_name): Return 0 for mingw.
2729 (get_ide_disk_name): Return //./PHYSICALDRIVE%d for mingw.
2730 (get_scsi_disk_name): Return 0 for mingw.
2731
2732 * util/hostfs.c: #include <grub/util/misc.h>.
2733 (grub_hostfs_open): Use "rb" flag to open file, use
2734 grub_util_get_disk_size to get disk size for mingw.
2735
2736 * util/misc.c: #include <windows.h> and <winioctl.h> in mingw.
2737 (asprintf): New function if HAVE_ASPRINTF is not set.
2738 (sync): New function for mingw.
2739 (sleep): Likewise.
2740 (grub_util_get_disk_size): Likewise.
2741
2742 2008-08-28 Pavel Roskin <proski@gnu.org>
2743
2744 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
2745 kern/time.c.
2746
2747 2008-08-28 Robert Millan <rmh@aybabtu.com>
2748
2749 * util/biosdisk.c (find_grub_drive): Declare missing `i' variable.
2750
2751 2008-08-28 Robert Millan <rmh@aybabtu.com>
2752
2753 Change find_grub_drive() syntax so it doesn't prevent it from
2754 detecting NULL names as errors.
2755
2756 * util/biosdisk.c (find_grub_drive): Move free slot search code
2757 from here ...
2758 (find_free_slot): ... to here.
2759 (read_device_map): Use find_free_slot() to search for free slots.
2760
2761 2008-08-27 Marco Gerards <marco@gnu.org>
2762
2763 * conf/common.rmk (pkglib_MODULES): Add scsi.mod.
2764 (scsi_mod_SOURCES): New variable.
2765 (scsi_mod_CFLAGS): Likewise
2766 (scsi_mod_LDFLAGS): Likewise.
2767
2768 * disk/scsi.c: New file.
2769
2770 * include/grub/scsi.h: Likewise.
2771
2772 * include/grub/scsicmd.h: Likewise.
2773
2774 * disk/ata.c: Include <grub/scsi.h>.
2775 (grub_atapi_packet): Do not use grub_ata_cmd, use registers
2776 instead.
2777 (grub_ata_iterate): Skip ATAPI devices.
2778 (grub_ata_open): Only handle ATAPI devices.
2779 (struct grub_atapi_read): Removed.
2780 (grub_atapi_readsector): Likewise.
2781 (grub_ata_read): No longer handle ATAPI devices.
2782 (grub_ata_write): Likewise.
2783 (grub_atapi_iterate): New function.
2784 (grub_atapi_read): Likewise.
2785 (grub_atapi_write): Likewise.
2786 (grub_atapi_open): Likewise.
2787 (grub_atapi_close): Likewise.
2788 (grub_atapi_dev): New variable.
2789 (GRUB_MOD_INIT(ata)): Register ATAPI as SCSI device.
2790 (GRUB_MOD_FINI(ata)): Unregister ATAPI.
2791
2792 * include/grub/disk.h (enum grub_disk_dev_id): Add
2793 `GRUB_DISK_DEVICE_SCSI_ID'.
2794
2795 2008-08-26 Robert Millan <rmh@aybabtu.com>
2796
2797 * util/biosdisk.c (grub_util_biosdisk_open, open_device)
2798 (grub_util_biosdisk_get_grub_dev): Make error messages a bit more
2799 descriptive.
2800
2801 2008-08-23 Bean <bean123ch@gmail.com>
2802
2803 * conf/common.rmk (grub_probe_SOURCES): Add disk/mdraid_linux.c.
2804 (grub_fstest_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
2805 disk/mdraid_linux.c and disk/dmraid_nvidia.c and lib/crc.c.
2806 (pkglib_MODULES): Add raid5rec.mod, raid6rec.mod, mdraid.mod and
2807 dm_nv.mod.
2808 (raid5rec_mod_SOURCES): New macro.
2809 (raid5rec_mod_CFLAGS): Likewise.
2810 (raid5rec_mod_LDFLAGS): Likewise.
2811 (raid6rec_mod_SOURCES): Likewise.
2812 (raid6rec_mod_CFLAGS): Likewise.
2813 (raid6rec_mod_LDFLAGS): Likewise.
2814 (mdraid_mod_SOURCES): Likewise.
2815 (mdraid_mod_CFLAGS): Likewise.
2816 (mdraid_mod_LDFLAGS): Likewise.
2817 (dm_nv_mod_SOURCES): Likewise.
2818 (dm_nv_mod_CFLAGS): Likewise.
2819 (dm_nv_mod_LDFLAGS): Likewise.
2820
2821 * conf/i386-pc.rmk (grub_setup_SOURCES): Add disk/mdraid_linux.c.
2822 (grub_emu_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
2823 disk/mdraid_linux.c and disk/dmraid_nvidia.c.
2824
2825 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add disk/raid5_recover.c,
2826 disk/raid6_recover.c, disk/mdraid_linux.c and disk/dmraid_nvidia.c.
2827
2828 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
2829
2830 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
2831
2832 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2833
2834 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2835
2836 * disk/raid5_recover.c: New file.
2837
2838 * disk/raid6_recover.c: Likewise.
2839
2840 * disk/mdraid_linux.c: Likewise.
2841
2842 * disk/dmraid_nvidia.c: Likewise.
2843
2844 * disk/i386/pc/biosdisk.c: Set total_sectors of cdrom device to
2845 ULONG_MAX.
2846
2847 * disk/raid.c (grub_raid_open): Use the size of the smallest disk to
2848 calculate the size of raid device.
2849 (grub_raid_read): Simplify raid0 code. Support raid4, raid6 and four
2850 different layout of raid5.
2851 (grub_raid_scan_device): Remove code specific to mdraid.
2852 (grub_raid_list): New variable.
2853 (free_array): New function.
2854 (grub_raid_register): Likewise.
2855 (grub_raid_unregister): Likewise.
2856 (grub_raid_rescan): Likewise.
2857 (GRUB_MOD_INIT): Don't iterate device here.
2858 (GRUB_MOD_FINI): Use free_array to release resource.
2859
2860 * include/grub/raid.h: Remove macro and structure specific to mdraid.
2861 (grub_raid5_recover_func_t): New function variable type.
2862 (grub_raid6_recover_func_t): Likewise.
2863 (grub_raid5_recover_func): New variable.
2864 (grub_raid6_recover_func): Likewise.
2865 (grub_raid_register): New function.
2866 (grub_raid_unregister): Likewise.
2867 (grub_raid_rescan): Likewise.
2868 (grub_raid_block_xor): Likewise.
2869
2870 * util/grub-fstest.c: Add #include <grub/raid.h> and <grub/lib/crc.h>.
2871 (CMD_CRC): New macro.
2872 (part): Removed.
2873 (read_file): Handle device as well as file.
2874 (cmd_crc): New function.
2875 (fstest): Handle multiple disks.
2876 (options): Remove part, raw and long, add root and diskcount.
2877 (usage): Add crc, remove -p, -r, -l, add -r and -c.
2878 (main): Find the first non option entry and ignore subsequent options,
2879 add handling for the new options, support multiple disks.
2880
2881 * util/grub-probe.c (probe): Add mdraid to abstraction_name.
2882
2883 2008-08-23 Bean <bean123ch@gmail.com>
2884
2885 * normal/x86_64/setjmp.S (grub_longjmp): Return 1 when val = 0.
2886
2887 * genfslist.sh: Ignore kernel.mod.
2888
2889 * genpartmaplist.sh: Likewise.
2890
2891 2008-08-23 Robert Millan <rmh@aybabtu.com>
2892
2893 * util/getroot.c (find_root_device): Skip anything that starts with
2894 a dot, not just directories. This avoids things like /dev/.tmp.md0.
2895
2896 2008-08-22 Felix Zielcke <fzielcke@z-51.de>
2897
2898 * util/update-grub.in (GRUB_GFXMODE): Export variable.
2899 * util/grub.d/00_header.in: Allow the administrator to change default
2900 gfxmode via ${GRUB_GFXMODE}.
2901
2902 2008-08-21 Felix Zielcke <fzielcke@z-51.de>
2903
2904 * fs/ntfs.c (grub_ntfs_mount): Fix a memory leak.
2905
2906 2008-08-21 Robert Millan <rmh@aybabtu.com>
2907
2908 * loader/i386/linux.c: New file. Implements generic 32-bit Linux
2909 loader.
2910 * conf/i386-coreboot.rmk (_linux_mod_SOURCES): Replace
2911 `loader/i386/pc/linux.c' with `loader/i386/linux.c'.
2912
2913 2008-08-20 Carles Pina i Estany <carles@pina.cat>
2914
2915 * menu/normal.c (run_menu): Replace hardcoded numbers with macros
2916 (16 for GRUB_TERM_UP and 14 for GRUB_TERM_DOWN)
2917
2918 2008-08-19 Robert Millan <rmh@aybabtu.com>
2919
2920 * term/gfxterm.c (DEFAULT_CURSOR_COLOR): Remove.
2921 (struct grub_virtual_screen): Remove `cursor_color'.
2922 (grub_virtual_screen_setup): Remove `virtual_screen.cursor_color'
2923 initialization.
2924 (write_cursor): Use `virtual_screen.fg_color' to draw cursor.
2925
2926 2008-08-18 Robert Millan <rmh@aybabtu.com>
2927
2928 Unify (identical) linux_normal.c files.
2929 * loader/i386/efi/linux_normal.c: Move from here ...
2930 * loader/linux_normal.c: ... to here. Update all users.
2931 * loader/i386/pc/linux_normal.c: Delete. Update all users.
2932 * loader/i386/ieee1275/linux_normal.c: Likewise.
2933
2934 2008-08-18 Robert Millan <rmh@aybabtu.com>
2935
2936 * include/grub/i386/linux.h (LINUX_LOADER_ID_LILO)
2937 (LINUX_LOADER_ID_LOADLIN, LINUX_LOADER_ID_BOOTSECT)
2938 (LINUX_LOADER_ID_SYSLINUX, LINUX_LOADER_ID_ETHERBOOT)
2939 (LINUX_LOADER_ID_ELILO, LINUX_LOADER_ID_GRUB, LINUX_LOADER_ID_UBOOT)
2940 (LINUX_LOADER_ID_XEN, LINUX_LOADER_ID_GUJIN, LINUX_LOADER_ID_QEMU):
2941 New macros.
2942 (GRUB_LINUX_CL_OFFSET, GRUB_LINUX_CL_END_OFFSET): Move from here ...
2943 * loader/i386/pc/linux.c (GRUB_LINUX_CL_OFFSET)
2944 (GRUB_LINUX_CL_END_OFFSET): ... to here.
2945 * loader/i386/efi/linux.c (GRUB_EFI_CL_OFFSET): Rename to ...
2946 (GRUB_LINUX_CL_OFFSET): ... this. Update all users.
2947 (GRUB_EFI_CL_END_OFFSET): Rename to ...
2948 (GRUB_LINUX_CL_END_OFFSET): ... this. Update all users.
2949 (grub_rescue_cmd_linux): Macroify `type_of_loader' initialization.
2950 Initialize `params->video_cursor_x' and `params->video_cursor_y'
2951 portably using grub_getxy().
2952 Replace `-EFI' with `-bzImage' in boot message.
2953
2954 2008-08-17 Robert Millan <rmh@aybabtu.com>
2955
2956 * include/grub/x86_64/kernel.h: New file (<grub/i386/kernel.h> stub).
2957
2958 2008-08-17 Robert Millan <rmh@aybabtu.com>
2959
2960 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pc/mmap.c'.
2961
2962 * include/grub/i386/pc/init.h (GRUB_MACHINE_MEMORY_AVAILABLE)
2963 (GRUB_MACHINE_MEMORY_RESERVED): New macros.
2964 (grub_machine_mmap_iterate): New function declaration.
2965 * include/grub/multiboot.h (struct grub_multiboot_mmap_entry): New
2966 structure.
2967 (GRUB_MMAP_MEMORY_AVAILABLE, GRUB_MMAP_MEMORY_RESERVED): New
2968 macros.
2969
2970 * kern/i386/pc/init.c (grub_machine_init): Replace hardcoded region
2971 type check value with `GRUB_MACHINE_MEMORY_AVAILABLE'.
2972 Move e820 parsing from here ...
2973 * kern/i386/pc/mmap.c: New file.
2974 (grub_machine_mmap_iterate): ... to here.
2975
2976 * include/grub/i386/coreboot/memory.h: Remove `<grub/err.h>'.
2977 (GRUB_LINUXBIOS_MEMORY_AVAILABLE): Rename (for consistency) to ...
2978 (GRUB_MACHINE_MEMORY_AVAILABLE): ... this. Update all users.
2979 (grub_available_iterate): Redeclare to return `void', and redeclare
2980 its hook to use grub_uint64_t as addr and size parameters, and rename
2981 to ...
2982 (grub_machine_mmap_iterate): ... this. Update all users.
2983
2984 * kern/i386/coreboot/mmap.c (grub_mmap_iterate): Simplify parser loop
2985 to make it more readable. Rename to ...
2986 (grub_machine_mmap_iterate): ... this.
2987
2988 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): New variables.
2989 (grub_get_multiboot_mmap_len, grub_fill_multiboot_mmap): New functions.
2990 (grub_multiboot): Allocate an extra region after the payload, and fill
2991 it with a Multiboot memory map. Adjust a.out loader to calculate size
2992 with the extra space.
2993 (grub_multiboot_load_elf32): Adjust elf32 loader to calculate size
2994 with the extra space.
2995
2996 2008-08-17 Carles Pina i Estany <carles@pina.cat>
2997
2998 * menu/normal.c (run_menu): Add Home and End keys in grub-menu.
2999
3000 2008-08-17 Felix Zielcke <fzielcke@z-51.de>
3001
3002 * gendistlist.sh: Add *.y, *.tex, *.texi, grub.cfg, README, *.sc,
3003 mdate-sh to the list `find' searches for.
3004 * DISTLIST: Regenerated.
3005
3006 2008-08-16 Felix Zielcke <fzielcke@z-51.de>
3007
3008 * gendistlist.sh (EXTRA_DISTFILES): Remove gensymlist.sh,
3009 genkernsyms.sh. Add geninit.sh, geninitheader.sh, genkernsyms.sh.in,
3010 genmoddep.awk, gensymlist.sh.in.
3011 (DISTDIRS): Add bus, docs, hook, lib.
3012 * DISTLIST: Regenerated.
3013 * NEWS: Add cygwin support and change the `os-prober' entry a bit.
3014
3015 2008-08-16 Robert Millan <rmh@aybabtu.com>
3016
3017 * disk/raid.c (grub_raid_init): Handle/report errors set by
3018 grub_device_iterate().
3019 * disk/lvm.c (grub_lvm_init): Likewise.
3020
3021 2008-08-15 Bean <bean123ch@gmail.com>
3022
3023 * conf/i386-pc.rmk (pkglib_MODULES): Add datetime.mod, date.mod
3024 and datehook.mod.
3025 (datetime_mod_SOURCES): New macro.
3026 (datetime_mod_CFLAGS): Likewise.
3027 (datetime_mod_LDFLAGS): Likewise.
3028 (date_mod_SOURCES): Likewise.
3029 (date_mod_CFLAGS): Likewise.
3030 (date_mod_LDFLAGS): Likewise.
3031 (datehook_mod_SOURCES): Likewise.
3032 (datehook_mod_CFLAGS): Likewise.
3033 (datehook_mod_LDFLAGS): Likewise.
3034
3035 * conf/i386-coreboot.rmk (pkglib_MODULES): Add datetime.mod, date.mod
3036 and datehook.mod.
3037 (datetime_mod_SOURCES): New macro.
3038 (datetime_mod_CFLAGS): Likewise.
3039 (datetime_mod_LDFLAGS): Likewise.
3040 (date_mod_SOURCES): Likewise.
3041 (date_mod_CFLAGS): Likewise.
3042 (date_mod_LDFLAGS): Likewise.
3043 (datehook_mod_SOURCES): Likewise.
3044 (datehook_mod_CFLAGS): Likewise.
3045 (datehook_mod_LDFLAGS): Likewise.
3046
3047 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add datetime.mod, date.mod
3048 and datehook.mod.
3049 (datetime_mod_SOURCES): New macro.
3050 (datetime_mod_CFLAGS): Likewise.
3051 (datetime_mod_LDFLAGS): Likewise.
3052 (date_mod_SOURCES): Likewise.
3053 (date_mod_CFLAGS): Likewise.
3054 (date_mod_LDFLAGS): Likewise.
3055 (datehook_mod_SOURCES): Likewise.
3056 (datehook_mod_CFLAGS): Likewise.
3057 (datehook_mod_LDFLAGS): Likewise.
3058
3059 * conf/i386-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
3060 and datehook.mod.
3061 (datetime_mod_SOURCES): New macro.
3062 (datetime_mod_CFLAGS): Likewise.
3063 (datetime_mod_LDFLAGS): Likewise.
3064 (date_mod_SOURCES): Likewise.
3065 (date_mod_CFLAGS): Likewise.
3066 (date_mod_LDFLAGS): Likewise.
3067 (datehook_mod_SOURCES): Likewise.
3068 (datehook_mod_CFLAGS): Likewise.
3069 (datehook_mod_LDFLAGS): Likewise.
3070
3071 * conf/x86_64-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
3072 and datehook.mod.
3073 (datetime_mod_SOURCES): New macro.
3074 (datetime_mod_CFLAGS): Likewise.
3075 (datetime_mod_LDFLAGS): Likewise.
3076 (date_mod_SOURCES): Likewise.
3077 (date_mod_CFLAGS): Likewise.
3078 (date_mod_LDFLAGS): Likewise.
3079 (datehook_mod_SOURCES): Likewise.
3080 (datehook_mod_CFLAGS): Likewise.
3081 (datehook_mod_LDFLAGS): Likewise.
3082
3083 * kern/env.c (grub_env_insert): Fix a bug in prevp pointer.
3084
3085 * commands/date.c: New file.
3086
3087 * hook/datehook.c: Likewise.
3088
3089 * include/grub/lib/datetime.h: Likewise.
3090
3091 * include/grub/i386/cmos.h: Likewise.
3092
3093 * lib/datetime.c: Likewise.
3094
3095 * lib/i386/datetime.c: Likewise.
3096
3097 * lib/efi/datetime.c: Likewise.
3098
3099 2008-08-14 Robert Millan <rmh@aybabtu.com>
3100
3101 * conf/common.rmk (bin_UTILITIES): Add `grub-mkelfimage'.
3102 (grub_mkelfimage_SOURCES): New variable.
3103 (util/elf/grub-mkimage.c_DEPENDENCIES): Likewise.
3104
3105 * conf/i386-coreboot.rmk (bin_UTILITIES, grub_mkimage_SOURCES)
3106 (grub_mkimage_LDFLAGS, util/elf/grub-mkimage.c_DEPENDENCIES): Remove.
3107 * conf/powerpc-ieee1275.rmk: Likewise.
3108 * conf/i386-ieee1275.rmk: Likewise.
3109
3110 * kern/ieee1275/init.c: Include `<grub/cpu/kernel.h>'.
3111 * kern/i386/coreboot/init.c: Likewise.
3112
3113 * kern/i386/ieee1275/startup.S: Replace `<grub/machine/kernel.h>'
3114 with `<grub/cpu/kernel.h>'.
3115 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Renamed
3116 to ...
3117 (GRUB_KERNEL_CPU_PREFIX, GRUB_KERNEL_CPU_DATA_END): ... this.
3118 * kern/i386/coreboot/startup.S: Likewise.
3119
3120 * include/grub/powerpc/ieee1275/kernel.h (GRUB_MOD_ALIGN)
3121 (GRUB_MOD_GAP): Remove.
3122 * include/grub/powerpc/kernel.h: New file.
3123 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX)
3124 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
3125 * include/grub/i386/kernel.h: New file.
3126 * include/grub/i386/coreboot/kernel.h (GRUB_MOD_ALIGN)
3127 (GRUB_MOD_GAP, GRUB_KERNEL_MACHINE_PREFIX)
3128 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
3129
3130 * util/ieee1275/grub-install.in (grub_mkimage): Initialize to use
3131 `grub-mkelfimage'.
3132 Use --directory when invoking grub_mkimage.
3133
3134 * util/elf/grub-mkimage.c: Include `<grub/cpu/kernel.h>'.
3135 (add_segments): Replace GRUB_KERNEL_MACHINE_DATA_END and
3136 GRUB_KERNEL_MACHINE_PREFIX with GRUB_KERNEL_CPU_DATA_END
3137 and GRUB_KERNEL_CPU_PREFIX.
3138
3139 2008-08-14 Felix Zielcke <fzielcke@z-51.de>
3140
3141 * include/grub/err.h (grub_err_printf): New function prototype.
3142 * util/misc.c (grub_err_printf): New function.
3143 * kern/misc.c [! GRUB_UTIL] (grub_err_printf): New alias for
3144 grub_printf.
3145 * kern/err.c (grub_print_error): Use grub_err_printf.
3146
3147 2008-08-13 Robert Millan <rmh@aybabtu.com>
3148
3149 * docs/grub.cfg: Remove `/dev/' prefix in GNU/Hurd boot entry.
3150
3151 2008-08-13 Robert Millan <rmh@aybabtu.com>
3152
3153 * docs/grub.cfg: Use the native device name for the example GNU/Hurd
3154 boot entry.
3155
3156 2008-08-12 Robert Millan <rmh@aybabtu.com>
3157
3158 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Move part
3159 of the relocation code from here ...
3160 (grub_multiboot): ... to here.
3161 (forward_relocator, backward_relocator): Move from here ...
3162 * kern/i386/loader.S (grub_multiboot_forward_relocator)
3163 (grub_multiboot_backward_relocator): ... to here.
3164 (grub_multiboot_real_boot): Use %edx for entry offset. Put Multiboot
3165 magic in %eax. Use %ebp for jumping (so %edx is not trashed).
3166 * include/grub/i386/loader.h (grub_multiboot_forward_relocator)
3167 (grub_multiboot_forward_relocator_end)
3168 (grub_multiboot_backward_relocator)
3169 (grub_multiboot_backward_relocator_end): New variables.
3170
3171 2008-08-12 Bean <bean123ch@gmail.com>
3172
3173 * disk/raid.c (grub_raid_read): Fix a bug in raid0 code.
3174
3175 2008-08-11 Robert Millan <rmh@aybabtu.com>
3176
3177 * kern/i386/linuxbios/startup.S: Move from here ...
3178 * kern/i386/coreboot/startup.S: ... to here.
3179
3180 * kern/i386/linuxbios/init.c: Move from here ...
3181 * kern/i386/coreboot/init.c: ... to here.
3182
3183 * kern/i386/linuxbios/table.c: Move from here ...
3184 * kern/i386/coreboot/mmap.c: ... to here.
3185
3186 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Update moved files.
3187
3188 2008-08-11 Robert Millan <rmh@aybabtu.com>
3189
3190 * kern/device.c (grub_device_open): Do not handle grub_disk_open()
3191 errors. Leave it to the upper layer to handle them.
3192
3193 2008-08-09 Christian Franke <franke@computer.org>
3194
3195 * Makefile.in: Add `target_os' and `enable_grub_pe2elf'.
3196 * conf/common.rmk: Install `grub-pe2elf' only if requested.
3197 Install `grub.d/10_windows' only on Cygwin.
3198 * configure.ac: Add subst of `target_os'.
3199 Check `target_os' also before setting TARGET_OBJ2ELF.
3200 Add `--enable-grub-pe2elf'.
3201
3202 2008-08-08 Robert Millan <rmh@aybabtu.com>
3203
3204 * kern/disk.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
3205 (grub_last_time): Change type to grub_uint64_t.
3206 (grub_disk_open): Migrate code from to using grub_get_time_ms().
3207 (grub_disk_close): Likewise.
3208
3209 * normal/menu.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
3210 (run_menu): Migrate code from to using grub_get_time_ms().
3211
3212 * util/misc.c (grub_get_time_ms): New function.
3213
3214 2008-08-08 Marco Gerards <marco@gnu.org>
3215
3216 * disk/ata.c (grub_ata_regget): Change return type to
3217 `grub_uint8_t'.
3218 (grub_ata_regget2): Likewise.
3219 (grub_ata_wait_status): New function.
3220 (grub_ata_wait_busy): Removed function, updated all users to use
3221 `grub_ata_wait_status'.
3222 (grub_ata_wait_drq): Likewise.
3223 (grub_ata_cmd): New function.
3224 (grub_ata_pio_read): Change return type to `grub_uint8_t'. Add
3225 error handling.
3226 (grub_ata_pio_write): Add error handling.
3227 (grub_atapi_identify): Likewise.
3228 (grub_atapi_packet): Use `grub_ata_cmd' and improve error
3229 handling.
3230 (grub_ata_identify): Use `grub_ata_cmd' and improve error
3231 handling. Actually use the detected registers. Reorder the
3232 detection logic such that it is easier to read.
3233 (grub_ata_pciinit): Do not assign the same ID to each controller.
3234 (grub_ata_setaddress): Use `grub_ata_cmd' and improve error
3235 handling.
3236 (grub_atapi_readsector): Check the result of `grub_ata_pio_read'.
3237
3238 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TIMEOUT'.
3239
3240 2008-08-08 Marco Gerards <marco@gnu.org>
3241
3242 * NEWS: Update.
3243
3244 2008-08-07 Bean <bean123ch@gmail.com>
3245
3246 * include/grub/x86_64/pci.h: New file.
3247
3248 2008-08-07 Christian Franke <franke@computer.org>
3249
3250 * kern/i386/pit.c (TIMER2_SPEAKER): New define.
3251 (TIMER2_GATE): Likewise.
3252 (grub_pit_wait): Add enable/disable of the timer2 gate
3253 bit of port 0x61. This fixes a possible infinite loop.
3254
3255 2008-08-07 Bean <bean123ch@gmail.com>
3256
3257 * conf/x86_64-efi.rmk (kernel_mod_SOURCES): Add kern/time.c,
3258 kern/i386/tsc.c and kern/i386/pit.c.
3259
3260 * include/grub/i386/tsc.h (grub_cpu_is_cpuid_supported): Handle
3261 x86_64 platform.
3262
3263 * kern/i386/efi/init.c: Replace <grub/cpu/tsc.h> with
3264 <grub/i386/tsc.h>.
3265
3266 * kern/i386/pit.c: Replace <grub/cpu/io.h> with <grub/i386/io.h>.
3267
3268 2008-08-07 Bean <bean123ch@gmail.com>
3269
3270 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add kern/time.c.
3271
3272 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add kern/time.c,
3273
3274 * include/grub/i386/pit.h: Use macro KERNEL_CPU_PIT_HEADER to avoid
3275 multiple inclusion. Add #include <grub/types.h>.
3276
3277 2008-08-06 Christian Franke <franke@computer.org>
3278
3279 * conf/common.rmk: Build and install `10_windows'.
3280 * util/grub.d/10_windows.in: New script.
3281
3282 2008-08-06 Pavel Roskin <proski@gnu.org>
3283
3284 * kern/i386/pit.c: Include `<grub/i386/pit.h>'.
3285
3286 2008-08-06 Robert Millan <rmh@aybabtu.com>
3287
3288 * conf/i386-coreboot.rmk (kernel_elf_ASFLAGS): New variable.
3289 * kern/i386/tsc.c: Include `<grub/i386/pit.h>'.
3290
3291 2008-08-06 Bean <bean123ch@gmail.com>
3292
3293 * fs/i386/pc/pxe.c (grub_pxe_data): New member block_size.
3294 (grub_pxefs_fs_int): Remove dummy definition.
3295 (grub_pxefs_open): Use data->block_size to store the current block
3296 size setting.
3297 (grub_pxefs_read): Use block size stored in data->block_size. As the
3298 value of grub_pxe_blksize can be changed after the file is opened.
3299
3300 2008-08-06 Bean <bean123ch@gmail.com>
3301
3302 * fs/i386/pc/pxe.c (curr_file): new variable.
3303 (grub_pxefs_open): Simply the handling of pxe file system. Don't
3304 require the dummy internal file system anymore.
3305 (grub_pxefs_read): Removed.
3306 (grub_pxefs_close): Likewise.
3307 (grub_pxefs_fs_int): Likewise.
3308 (grub_pxefs_read_int): Renamed to grub_pxefs_read. Reinitialize tftp
3309 connection when we switch file.
3310 (grub_pxefs_close_int): Renamed to grub_pxefs_close.
3311
3312 2008-08-06 Robert Millan <rmh@aybabtu.com>
3313
3314 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `reboot.mod' and
3315 `halt.mod'.
3316 (reboot_mod_SOURCES, reboot_mod_CFLAGS, reboot_mod_LDFLAGS)
3317 (halt_mod_SOURCES, halt_mod_CFLAGS, halt_mod_LDFLAGS): New variables.
3318
3319 * kern/i386/halt.c: New file.
3320 * kern/i386/reboot.c: Likewise.
3321 * include/grub/i386/reboot.h: Likewise.
3322 * include/grub/i386/halt.h: Likewise.
3323
3324 * commands/halt.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]:
3325 Include `<grub/cpu/halt.h>'.
3326 * commands/reboot.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]
3327 [! GRUB_MACHINE_PCBIOS]: Include `<grub/cpu/reboot.h>'.
3328
3329 * term/i386/pc/at_keyboard.c: Include `<grub/cpu/at_keyboard.h>'.
3330 (SHIFT_L, SHIFT_R, CTRL, ALT, CAPS_LOCK, KEYBOARD_REG_DATA)
3331 (KEYBOARD_REG_STATUS, KEYBOARD_COMMAND_ISREADY, KEYBOARD_COMMAND_READ)
3332 (KEYBOARD_COMMAND_WRITE, KEYBOARD_COMMAND_REBOOT)
3333 (KEYBOARD_SCANCODE_SET1, KEYBOARD_ISMAKE, KEYBOARD_ISREADY)
3334 (KEYBOARD_SCANCODE, OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): Move
3335 from here ...
3336 * include/grub/i386/at_keyboard.h: ... to here.
3337
3338 2008-08-05 Robert Millan <rmh@aybabtu.com>
3339
3340 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pit.c'.
3341 * conf/i386-efi.rmk (kernel_mod_SOURCES): Likewise.
3342 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Likewise. Also add
3343 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
3344 `kern/generic/millisleep.c'.
3345
3346 * kern/i386/tsc.c (calibrate_tsc): Rewrite using grub_pit_wait()
3347 instead of grub_get_rtc().
3348 (grub_tsc_init): Initialize `tsc_boot_time'.
3349
3350 * kern/i386/linuxbios/init.c (grub_millisleep): Remove stub.
3351 (grub_machine_init): Use grub_tsc_init() rather than
3352 installing an RTC-based handler via grub_install_get_time_ms().
3353
3354 * kern/i386/pit.c: New file.
3355 * include/grub/i386/pit.h: Likewise.
3356
3357 2008-08-05 Bean <bean123ch@gmail.com>
3358
3359 * boot/i386/pc/pxeboot.S (_start): Use drive number 0x7F for pxe.
3360
3361 * conf/i386-pc.rmk (kernel_img_HEADERS): Add machine/pxe.h.
3362 (pkglib_MODULES): Add pxe.mod and pxecmd.mod.
3363 (pxe_mod_SOURCES): New macro.
3364 (pxe_mod_CFLAGS): Likewise.
3365 (pxe_mod_LDFLAGS): Likewise.
3366 (pxecmd_mod_SOURCES): Likewise.
3367 (pxecmd_mod_CFLAGS): Likewise.
3368 (pxecmd_mod_LDFLAGS): Likewise.
3369
3370 * kern/i386/pc/startup.S (grub_pxe_scan): New function.
3371 (grub_pxe_call): Likewise.
3372
3373 * include/grub/disk.h (grub_disk_dev_id): Add GRUB_DISK_DEVICE_PXE_ID.
3374
3375 * commands/i386/pc/pxecmd.c: New file.
3376
3377 * fs/i386/pc/pxe.c: Likewise.
3378
3379 * include/grub/i386/pc/pxe.h: Likewise.
3380
3381 2008-08-05 Bean <bean123ch@gmail.com>
3382
3383 * util/console.c (grub_console_cur_color): New variable.
3384 (grub_console_standard_color): Likewise.
3385 (grub_console_normal_color): Likewise.
3386 (grub_console_highlight_color): Likewise.
3387 (color_map): Likewise.
3388 (use_color): Likewise.
3389 (NUM_COLORS): New macro.
3390 (grub_ncurses_setcolorstate): Handle color properly.
3391 (grub_ncurses_setcolor): Don't change color here, just remember the
3392 settings, color will be set in grub_ncurses_setcolorstate.
3393 (grub_ncurses_getcolor): New function.
3394 (grub_ncurses_init): Initialize color pairs.
3395 (grub_ncurses_term): New member grub_ncurses_getcolor.
3396
3397 2008-08-05 Colin D Bennett <colin@gibibit.com>
3398
3399 High resolution timer support. Implemented for x86 CPUs using TSC.
3400 Extracted generic grub_millisleep() so it's linked in only as needed.
3401 This requires a Pentium compatible CPU; if the RDTSC instruction is
3402 not supported, then it falls back on the generic grub_get_time_ms()
3403 implementation that uses the machine's RTC.
3404
3405 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/time.c',
3406 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
3407 `kern/generic/millisleep.c'.
3408
3409 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add `kern/i386/tsc.c',
3410 `kern/generic/rtc_get_time_ms.c' and `kern/generic/millisleep.c'.
3411
3412 * conf/x86_64-efi.rml (kernel_mod_SOURCES): Add
3413 `kern/generic/millisleep.c' and `kern/generic/rtc_get_time_ms.c'.
3414
3415 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
3416
3417 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
3418 `kern/generic/millisleep.c'.
3419
3420 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
3421
3422 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Add `kern/time.c'.
3423
3424 * kern/generic/rtc_get_time_ms.c: New file.
3425
3426 * kern/generic/millisleep.c: New file.
3427
3428 * kern/misc.c: Don't include
3429 <kern/time.h> anymore.
3430 (grub_millisleep_generic): Removed.
3431
3432 * commands/sleep.c (grub_interruptible_millisleep): Uses
3433 grub_get_time_ms() instead of grub_get_rtc().
3434
3435 * include/grub/i386/tsc.h (grub_get_tsc): New file. New inline
3436 function.
3437 (grub_cpu_is_cpuid_supported): New inline function.
3438 (grub_cpu_is_tsc_supported): New inline function.
3439 (grub_tsc_init): New function prototype.
3440 (grub_tsc_get_time_ms): New function prototype.
3441
3442 * kern/i386/tsc.c (grub_get_time_ms): New file.
3443
3444 * include/grub/time.h: Include <grub/types.h.
3445 (grub_millisleep_generic): Removed.
3446 (grub_get_time_ms): New prototype.
3447 (grub_install_get_time_ms): New prototype.
3448 (grub_rtc_get_time_ms): New prototype.
3449
3450 * kern/time.c (grub_get_time_ms): New function.
3451 (grub_install_get_time_ms): New function.
3452
3453 * kern/i386/efi/init.c: Include <grub/cpu/tsc.h>. Don't include
3454 <grub/time.h> anymore.
3455 (grub_millisleep): Removed.
3456 (grub_machine_init): Call grub_tsc_init.
3457
3458 * kern/i386/linuxbios/init.c (grub_machine_init): Install the RTC
3459 get_time_ms() implementation.
3460
3461 * kern/sparc64/ieee1275/init.c (grub_millisleep): Removed.
3462 (ieee1275_get_time_ms): New function.
3463 (grub_machine_init): Install get_time_ms() implementation.
3464
3465 * kern/i386/pc/init.c: Include <grub/cpu/tsc.h>.
3466 (grub_machine_init): Call grub_tsc_init().
3467 (grub_millisleep): Removed.
3468
3469 * kern/ieee1275/init.c (grub_millisleep): Removed.
3470 (grub_machine_init): Install ieee1275_get_time_ms()
3471 implementation.
3472 (ieee1275_get_time_ms): New function.
3473 (grub_get_rtc): Now calls ieee1275_get_time_ms(), which does the
3474 real work.
3475
3476 2008-08-05 Marco Gerards <marco@gnu.org>
3477
3478 * disk/ata.c: Include <grub/pci.h>.
3479 (enum grub_ata_commands): Add `GRUB_ATA_CMD_EXEC_DEV_DIAGNOSTICS'.
3480 (grub_ata_initialize): Rewritten.
3481 (grub_ata_device_initialize): New function.
3482
3483 2008-08-04 Pavel Roskin <proski@gnu.org>
3484
3485 * kern/main.c: Include grub/mm.h.
3486
3487 2008-08-04 Robert Millan <rmh@aybabtu.com>
3488
3489 * conf/i386-coreboot.rmk (COMMON_ASFLAGS, COMMON_CFLAGS)
3490 (COMMON_LDFLAGS): Harmonize with i386-pc version (fixes a code
3491 corruption problem).
3492
3493 2008-08-04 Robert Millan <rmh@aybabtu.com>
3494
3495 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Fix misc
3496 warnings introduced in my last commit.
3497
3498 2008-08-03 Robert Millan <rmh@aybabtu.com>
3499
3500 Make PCI available on all i386 architectures.
3501
3502 * include/grub/i386/pc/pci.h: Move from here ...
3503 * include/grub/i386/pci.h: ... to here.
3504
3505 * include/grub/i386/pc/pci.h: Remove.
3506 * include/grub/i386/efi/pci.h: Remove.
3507 * include/grub/x86_64/efi/pci.h: Remove.
3508
3509 * include/grub/pci.h: Replace `<grub/machine/pci.h>' with
3510 `<grub/cpu/pci.h>'.
3511
3512 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `pci' and `lspci'.
3513 (pci_mod_SOURCES, pci_mod_CFLAGS, pci_mod_LDFLAGS, lspci_mod_SOURCES)
3514 (lspci_mod_CFLAGS, lspci_mod_LDFLAGS): New variables.
3515
3516 * conf/i386-ieee1275.rmk: Likewise.
3517
3518 2008-08-03 Robert Millan <rmh@aybabtu.com>
3519
3520 * term/i386/pc/vga_text.c (CRTC_CURSOR_DISABLE): New macro.
3521 (grub_console_setcursor): Make it possible to set cursor off.
3522
3523 2008-08-03 Robert Millan <rmh@aybabtu.com>
3524
3525 * util/grub.d/00_header.in: Be platform-agnostic. Probe for existence
3526 of modules instead of assuming which platform provides what.
3527 * util/update-grub.in: Likewise.
3528
3529 2008-08-03 Robert Millan <rmh@aybabtu.com>
3530
3531 * kern/i386/pc/init.c (make_install_device): Check for `grub_prefix'
3532 instead of `grub_install_dos_part' to determine whether a drive needs
3533 to be prepended to prefix (`grub_install_dos_part' is not reliable,
3534 because it can be overridden when loading GRUB via Multiboot).
3535
3536 2008-08-02 Robert Millan <rmh@aybabtu.com>
3537
3538 * util/i386/pc/grub-install.in: Remove trailing slash from prefix.
3539
3540 2008-08-02 Robert Millan <rmh@aybabtu.com>
3541
3542 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Add a pair
3543 of informational grub_dprintf() calls.
3544
3545 2008-08-02 Robert Millan <rmh@aybabtu.com>
3546
3547 * disk/memdisk.c (memdisk_size): Don't initialize.
3548 (GRUB_MOD_INIT(memdisk)): Find memdisk using grub_module_iterate().
3549
3550 * include/grub/i386/pc/kernel.h
3551 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): Remove macro.
3552 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Shift.
3553 (grub_memdisk_image_size, grub_arch_memdisk_addr)
3554 (grub_arch_memdisk_size): Remove.
3555
3556 * include/grub/kernel.h (struct grub_module_header): Remove `offset'
3557 field (was only used to transfer a constant). Add `type' field to
3558 support multiple module types.
3559 (grub_module_iterate): New function.
3560
3561 * kern/device.c (grub_device_open): Do not hide error messages
3562 when grub_disk_open() fails. Use grub_print_error() instead.
3563
3564 * kern/i386/pc/init.c (grub_arch_modules_addr)
3565 (grub_arch_memdisk_size): Remove functions.
3566 (grub_arch_modules_addr): Return the module address in high memory
3567 (now that it isn't copied anymore).
3568
3569 * kern/i386/pc/startup.S (grub_memdisk_image_size): Remove variable.
3570 (codestart): Don't add grub_memdisk_image_size to %ecx in LZMA
3571 decompression routine (grub_total_module_size already includes that
3572 now). Don't copy modules back to low memory.
3573
3574 * kern/main.c: Include `<grub/mm.h>'.
3575 (grub_load_modules): Split out (and use) ...
3576 (grub_module_iterate): ... this function, which iterates through
3577 module objects and runs a hook.
3578 Comment out grub_mm_init_region() call, as it would cause non-ELF
3579 modules to be overwritten.
3580
3581 * util/i386/pc/grub-mkimage.c (generate_image): Instead of appending
3582 the memdisk image in its own region, make it part of the module list.
3583 * util/elf/grub-mkimage.c (options): Add "memdisk"|'m' option.
3584 (main): Parse --memdisk|-m option, and pass user-provided path as
3585 parameter to generate_image().
3586 (add_segments): Pass `memdisk_path' down to load_modules().
3587 (load_modules): Embed memdisk image in module section when requested.
3588 * util/i386/efi/grub-mkimage.c (make_mods_section): Initialize
3589 `header.type' instead of `header.offset'.
3590
3591 * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add `memdisk.mod'.
3592 (memdisk_mod_SOURCES, memdisk_mod_CFLAGS)
3593 (memdisk_mod_LDFLAGS): New variables.
3594 * conf/i386-coreboot.rmk: Likewise.
3595 * conf/i386-ieee1275.rmk: Likewise.
3596
3597 2008-08-02 Robert Millan <rmh@aybabtu.com>
3598
3599 * loader/i386/pc/multiboot.c (playground, forward_relocator)
3600 (backward_relocator): New variables. Used to allocate and relocate
3601 the payload, respectively.
3602 (grub_multiboot_load_elf32): Load into heap instead of requested
3603 address, install the appropriate relocator code in each bound of
3604 the payload, and set the entry point such that
3605 grub_multiboot_real_boot() will jump to one of them.
3606
3607 * kern/i386/loader.S (grub_multiboot_payload_size)
3608 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
3609 (grub_multiboot_payload_entry_offset): New variables.
3610 (grub_multiboot_real_boot): Set cpu context to what the relocator
3611 expects, and jump to the relocator instead of the payload.
3612
3613 * include/grub/i386/loader.h (grub_multiboot_payload_size)
3614 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
3615 (grub_multiboot_payload_entry_offset): Export.
3616
3617 2008-08-01 Bean <bean123ch@gmail.com>
3618
3619 * normal/menu_entry.c (editor_getline): Don't return the original
3620 string as result, as it will be released by lexer once it has done
3621 using it.
3622
3623 2008-08-01 Robert Millan <rmh@aybabtu.com>
3624
3625 * util/grub.d/10_linux.in: Use prepare_grub_to_access_device() from
3626 within menuentries, not before them.
3627 util/grub.d/10_hurd.in: Likewise.
3628
3629 2008-08-01 Bean <bean123ch@gmail.com>
3630
3631 * conf/common.rmk (pkglib_MODULES): Add bufio.mod.
3632 (bufio_mod_SOURCES): New macro.
3633 (bufio_mod_CFLAGS): Likewise.
3634 (bufio_mod_LDFLAGS): Likewise.
3635
3636 * include/grub/bufio.h: New file.
3637
3638 * io/bufio.c: Likewise.
3639
3640 * video/png.c: Replace <grub/file.h> with <grub/bufio.h>.
3641 (grub_video_reader_png): Use grub_buffile_open to open file.
3642
3643 * video/jpeg.c: Replace <grub/file.h> with <grub/bufio.h>.
3644 (grub_video_reader_jpeg): Use grub_buffile_open to open file.
3645
3646 * video/tga.c: Replace <grub/file.h> with <grub/bufio.h>.
3647 (grub_video_reader_tga): Use grub_buffile_open to open file.
3648
3649 * font/manager.c: Include <grub/bufio.h>.
3650 (add_font): Use grub_buffile_open to open file.
3651
3652 2008-07-31 Robert Millan <rmh@aybabtu.com>
3653
3654 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): When loading
3655 ELF segments, use a macro for arbitrarily accessing any of them instead
3656 of preparing a pointer that allows access to one at a time.
3657 (grub_multiboot_load_elf64): Likewise.
3658
3659 2008-07-31 Bean <bean123ch@gmail.com>
3660
3661 * boot/i386/pc/lnxboot.S (real_code_2): Replace 0x50 with
3662 GRUB_KERNEL_MACHINE_DATA_END.
3663
3664 2008-07-30 Robert Millan <rmh@aybabtu.com>
3665
3666 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_DATA_END):
3667 Increase from 0x50 to 0x60.
3668 * util/i386/pc/grub-install.in: Detect cross-disk installs, and
3669 use UUIDs to identify the root drive for them. If that's not
3670 possible, abort.
3671 * util/i386/pc/grub-setup.c (setup): Do not special-case, or even
3672 check, for cross-disk installs.
3673
3674 2008-07-30 Robert Millan <rmh@aybabtu.com>
3675
3676 * kern/ieee1275/init.c (grub_machine_set_prefix): If `grub_prefix'
3677 is non-empty, use it to set the `prefix' environment variable instead
3678 of the usual approach.
3679 * kern/i386/linuxbios/init.c (make_install_device): Remove function.
3680 (grub_machine_set_prefix): Use `grub_prefix' to set the `prefix'
3681 environment variable instead of dummy make_install_device().
3682
3683 * kern/i386/ieee1275/startup.S: Include `<grub/machine/kernel.h>'.
3684 (start): Insert a data section, with `grub_prefix' variable.
3685 * kern/i386/linuxbios/startup.S: Likewise.
3686
3687 * include/grub/powerpc/ieee1275/kernel.h [!ASM_FILE] (grub_prefix):
3688 New variable reference.
3689 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX):
3690 New macro. Defines offset of `grub_prefix' within startup.S (relative
3691 to `start').
3692 (GRUB_KERNEL_MACHINE_DATA_END): New macro. Defines the end of data
3693 section within startup.S (relative to `start').
3694 * include/grub/i386/coreboot/kernel.h: Likewise.
3695
3696 * util/elf/grub-mkimage.c (add_segments): Receive `prefix' parameter.
3697 Overwrite grub_prefix with its contents, at the beginning of the
3698 first segment.
3699 (main): Understand -p|--prefix.
3700
3701 2008-07-30 Robert Millan <rmh@aybabtu.com>
3702
3703 * util/grub.d/10_hurd.in: Source ${libdir}/grub/update-grub_lib.
3704
3705 2008-07-30 Robert Millan <rmh@aybabtu.com>
3706
3707 * term/i386/pc/vga_text.c (grub_console_cls): Use
3708 grub_console_gotoxy() to go back to beginning of the screen.
3709 Found by Patrick Georgi <patrick.georgi@coresystems.de>
3710
3711 2008-07-29 Christian Franke <franke@computer.org>
3712
3713 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
3714 Add conversion of emulated mount points on Cygwin.
3715
3716 2008-07-29 Christian Franke <franke@computer.org>
3717
3718 * util/update-grub.in: Add a check for admin
3719 group on Cygwin.
3720 Remove old `grub.cfg.new' before creation.
3721 Add `-f' to `mv' to handle the different filesystem
3722 semantics of Windows.
3723
3724 2008-07-29 Bean <bean123ch@gmail.com>
3725
3726 * normal/main.c (get_line): Fix buffer overflow bug.
3727
3728 2008-07-28 Robert Millan <rmh@aybabtu.com>
3729
3730 * partmap/apple.c (GRUB_APPLE_HEADER_MAGIC): New macro.
3731 (struct grub_apple_header): New struct. Describes the layout of
3732 the partmap header.
3733 (apple_partition_map_iterate): Check the header magic as well as the
3734 partition magic (which was already being checked).
3735
3736 2008-07-28 Pavel Roskin <proski@gnu.org>
3737
3738 * genmk.rb: Add a warning to the beginning of the output that
3739 it's a generated file and should not be edited.
3740
3741 2008-07-28 Robert Millan <rmh@aybabtu.com>
3742
3743 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
3744 with the same number are found, just use issue a warning with
3745 grub_dprintf(), as this error has been reported to be non-fatal.
3746
3747 2008-07-27 Robert Millan <rmh@aybabtu.com>
3748
3749 * disk/ata.c (grub_ata_dumpinfo): Use grub_dprintf() for debugging
3750 information.
3751
3752 2008-07-27 Bean <bean123ch@gmail.com>
3753
3754 * fs/fat.c (GRUB_FAT_MAXFILE): New constant.
3755 (grub_fat_find_dir): Ignore case when comparing filename.
3756
3757 2008-07-27 Bean <bean123ch@gmail.com>
3758
3759 * fs/xfs.c (grub_xfs_dir_header): Change field i8count back to
3760 smallino, as it's more descriptive, and i8count can be confused with
3761 the other field count.
3762 (grub_xfs_iterate_dir): Adjust grub_xfs_dir_entry pointer for small
3763 inode type.
3764
3765 2008-07-27 Bean <bean123ch@gmail.com>
3766
3767 * commands/crc.c: New file.
3768
3769 * lib/crc.c: Likewise.
3770
3771 * include/grub/lib/crc.h: Likewise.
3772
3773 * util/grub-fstest.c: grub/hexdump.h => grub/lib/hexdump.h.
3774
3775 * commands/hexdump.c: grub/hexdump.h => grub/lib/hexdump.h.
3776 (hexdump): Move this function to ...
3777
3778 * lib/hexdump.c: ... here.
3779
3780 * include/grub/hexdump.h: Renamed to ...
3781
3782 * include/grub/lib/hexdump.h: ... this.
3783
3784 * commands/loadenv.c: grub/envblk.h => grub/lib/envblk.h
3785
3786 * util/grub-editenv.c: Likewise.
3787
3788 * include/envblk.h: Renamed to ...
3789
3790 * include/lib/envblk.h: ... this.
3791
3792 * util/envblk.c: Renamed to ...
3793
3794 * lib/envblk.c: ... this.
3795
3796 * conf/common.rmk (grub_fstest_SOURCES): commands/hexdump.c =>
3797 lib/hexdump.c.
3798 (grub_editenv_SOURCES): util/envblk.c => lib/envblk.c
3799 (pkglib_MODULES): Add crc.mod.
3800 (hexdump_mod_SOURCES): Add lib/hexdump.c.
3801 (loadenv_mod_SOURCES): util/envblk.c => lib/envblk.c.
3802 (crc_mod_SOURCES): New macro.
3803 (crc_mod_CFLAGS): Likewise.
3804 (crc_mod_LDFLAGS): Likewise.
3805
3806 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add lib/hexdump.c.
3807
3808 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
3809
3810 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
3811
3812 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3813
3814 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
3815
3816 2008-07-27 Felix Zielcke <fzielcke@z-51.de>
3817
3818 * commands/help.c: Include <grub/term.h>.
3819 (TERM_WIDTH): Removed. Updated all users.
3820
3821 2008-07-27 Pavel Roskin <proski@gnu.org>
3822
3823 * util/getroot.c (find_root_device): Rephrase a comment to avoid
3824 spurious warnings about a comment within a comment.
3825
3826 2008-07-25 Robert Millan <rmh@aybabtu.com>
3827
3828 * util/getroot.c (find_root_device): Skip devices that match
3829 /dev/dm-[0-9]. This lets the real device be found for any type of
3830 abstraction (LVM, EVMS, RAID..).
3831 (grub_guess_root_device): Do not traverse /dev/mapper (for LVM)
3832 and /dev/evms (for EVMS) before traversing /dev. If a /dev/dm-[0-9]
3833 device is found first, find_root_device() will now skip it.
3834
3835 2008-07-24 Pavel Roskin <proski@gnu.org>
3836
3837 * include/grub/types.h: Use __builtin_bswap32() and
3838 __builtin_bswap64() with gcc 4.3 and newer.
3839
3840 2008-07-24 Christian Franke <franke@computer.org>
3841
3842 * util/i386/pc/grub-install.in: If `--debug' is specified,
3843 pass `--verbose' to grub-setup.
3844 Abort script if make_system_path_relative_to_its_root() fails.
3845
3846 2008-07-24 Bean <bean123ch@gmail.com>
3847
3848 * configure.ac: Fixed a bug caused by the previous cygwin patch,
3849 variable `target_platform' should be `platform'.
3850
3851 2008-07-24 Bean <bean123ch@gmail.com>
3852
3853 * video/reader/png.c (DEFLATE_HLIT_MAX): Change value.
3854 (grub_png_init_fixed_block): New function.
3855 (grub_png_decode_image_data): Handle fixed huffman code compression.
3856
3857 2008-07-24 Bean <bean123ch@gmail.com>
3858
3859 * common.rmk (bin_UTILITIES): Add grub-pe2elf.
3860 (grub_pe2elf_SOURCES): New macro.
3861 (CLEANFILES): Add grub-pe2elf.
3862
3863 * include/grub/efi/pe32.h (GRUB_PE32_SCN_ALIGN_1BYTES): New constant.
3864 (GRUB_PE32_SCN_ALIGN_2BYTES): Likewise.
3865 (GRUB_PE32_SCN_ALIGN_4BYTES): Likewise.
3866 (GRUB_PE32_SCN_ALIGN_8BYTES): Likewise.
3867 (GRUB_PE32_SCN_ALIGN_16BYTES): Likewise.
3868 (GRUB_PE32_SCN_ALIGN_32BYTES): Likewise.
3869 (GRUB_PE32_SCN_ALIGN_64BYTES): Likewise.
3870 (GRUB_PE32_SCN_ALIGN_SHIFT): Likewise.
3871 (GRUB_PE32_SCN_ALIGN_MASK): Likewise.
3872 (GRUB_PE32_SYM_CLASS_EXTERNAL): Likewise.
3873 (GRUB_PE32_SYM_CLASS_STATIC): Likewise.
3874 (GRUB_PE32_SYM_CLASS_FILE): Likewise.
3875 (GRUB_PE32_DT_FUNCTION): Likewise.
3876 (GRUB_PE32_REL_I386_DIR32): Likewise.
3877 (GRUB_PE32_REL_I386_REL32): Likewise.
3878 (grub_pe32_symbol): New structure.
3879 (grub_pe32_reloc): Likewise.
3880
3881 * util/grub-pe2elf.c: New file.
3882
3883 * configure.ac: Set TARGET_OBJ2ELF if host os is cygwin. Don't test for
3884 start symbol in non pc platform.
3885
3886 * genmk.rb: Use TARGET_OBJ2ELF to convert native object format to elf.
3887
3888 The following patches are from Christian Franke.
3889
3890 * include/grub/dl.h: Remove .previous, gas supports this only
3891 for ELF format.
3892
3893 * include/grub/symbol.h [__CYGWIN__] (#define FUNCTION/VARIABLE):
3894 Remove .type, gas supports this only for ELF format.
3895
3896 * kern/dl.c (grub_dl_resolve_dependencies): Add check for trailing
3897 nullbytes in symbol table. This fixes an infinite loop if table is
3898 zero filled.
3899
3900 * Makefile.in: Add autoconf replacements TARGET_IMG_LDSCRIPT,
3901 TARGET_IMG_LDFLAGS and EXEEXT.
3902
3903 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Replace -Wl,-N by
3904 TARGET_IMG_LDFLAGS_AC.
3905 (grub_CHECK_STACK_ARG_PROBE): New function.
3906
3907 * conf/i386-pc.rmk: Replace -Wl,-N by TARGET_IMG_LDFLAGS.
3908
3909 * conf/i386-pc-cygwin-ld-img.sc: New linker script.
3910
3911 * configure.ac: Add check for linker script "conf/${target}-img-ld.c"
3912 to set TARGET_IMG_LD* accordingly.
3913 Add check for Cygwin to set TARGET_MOD_OBJCOPY accordingly.
3914 Add call to grub_CHECK_STACK_ARG_PROBE.
3915 Use TARGET_IMG_LDFLAGS to check start, bss_start, end symbols.
3916
3917 * genkernsyms.sh.in: Handle HAVE_ASM_USCORE case.
3918
3919 * genmk.rb: Add EXEEXT to CLEANFILES.
3920
3921 2008-07-23 Robert Millan <rmh@aybabtu.com>
3922
3923 * Makefile.in (UNICODE_ARROWS, UNICODE_LINES): New variables (they
3924 define the codes for arrows and lines used for the menu).
3925 (ascii.pff): Generate fonts for $(UNICODE_ARROWS) and $(UNICODE_LINES)
3926 as well.
3927
3928 * util/update-grub_lib.in (font_path): Prefer ascii.pff over complete
3929 fonts, because the latter are too slow.
3930
3931 2008-07-21 Bean <bean123ch@gmail.com>
3932
3933 * kern/i386/pc/startup.S (gate_a20_try_bios): Change test order for
3934 a20. Run keyboard test last, as it will cause macbook to halt.
3935
3936 2008-07-18 Pavel Roskin <proski@gnu.org>
3937
3938 * kern/dl.c: Go back to using GRUB_CPU_SIZEOF_VOID_P. We cannot
3939 load foreign architecture modules correctly anyway. Keep
3940 support for loading host architecture modules, whether we
3941 compile them or not.
3942
3943 2008-07-17 Pavel Roskin <proski@gnu.org>
3944
3945 * configure.ac: Use -m32 or -m64 regardless of whether we had to
3946 change target_cpu. The compiler default can mismatch target_cpu
3947 in any case.
3948
3949 * disk/efi/efidisk.c: Fix format warnings on x86_64.
3950 * kern/efi/efi.c: Likewise.
3951
3952 * aclocal.m4 (grub_PROG_TARGET_CC): New macro. Check if the
3953 target compiler is functional.
3954 * configure.ac: Call grub_PROG_TARGET_CC once all target flags
3955 are set up.
3956
3957 * configure.ac: Default to efi platform for x86_64-apple. Allow
3958 powerpc64 CPU, default to ieee1275 platform for it. Split CPU
3959 adjustments from the rest, only do them if target is not
3960 explicitly given. Merge other adjustments with the final sanity
3961 check. Remove an extraneous check for supported CPU. Be
3962 specific which CPU and which platform is not supported.
3963
3964 * configure.ac: Default to pc platform for x86_64.
3965
3966 2008-07-17 Robert Millan <rmh@aybabtu.com>
3967
3968 Partial LinuxBIOS -> Coreboot rename.
3969
3970 * conf/i386-linuxbios.rmk: Renamed to ...
3971 * conf/i386-coreboot.rmk: ... this.
3972 * Makefile.in (RMKFILES): s/i386-linuxbios.rmk/i386-coreboot.rmk/g.
3973 * configure.ac: Accept "coreboot" as input platform (but maintain
3974 compatibility with "linuxbios").
3975 * include/grub/i386/linuxbios: Renamed to ...
3976 * include/grub/i386/coreboot: ... this.
3977
3978 2008-07-17 Bean <bean123ch@gmail.com>
3979
3980 * conf/i386/efi.rmk (pkglib_MODULES): add pci.mod and lspci.mod.
3981 (appleldr_mod_SOURCE): New variable.
3982 (appleldr_mod_CFLAGS): Likewise.
3983 (appleldr_mod_LDFLAGS): Likewise.
3984 (pci_mod_SOURCES): Likewise.
3985 (pci_mod_CFLAGS): Likewise.
3986 (pci_mod_LDFLAGS): Likewise.
3987 (lspci_mod_SOURCES): Likewise.
3988 (lspci_mod_CFLAGS): Likewise.
3989 (lspci_mod_LDFLAGS): Likewise.
3990
3991 * conf/x86_64-efi.rmk: New file.
3992
3993 * disk/efi/efidisk.c (grub_efidisk_read): Wrap efi calls with efi_call_N
3994 macro.
3995 (grub_efidisk_write): Likewise.
3996
3997 * include/efi/api.h (efi_call_0): New macro.
3998 (efi_call_1): Likewise.
3999 (efi_call_2): Likewise.
4000 (efi_call_3): Likewise.
4001 (efi_call_4): Likewise.
4002 (efi_call_5): Likewise.
4003 (efi_call_6): Likewise.
4004
4005 * include/grub/efi/chainloader.h (grub_chainloader_cmd): Rename to
4006 grub_rescue_cmd_chainloader.
4007
4008 * include/grub/efi/pe32.h (GRUB_PE32_MACHINE_X86_64): New macro.
4009 (grub_pe32_optional_header): Change some fields based on i386 or
4010 x86_64 platform.
4011 (GRUB_PE32_PE32_MAGIC): Likewise.
4012
4013 * include/grub/efi/uga_draw.h: New file.
4014
4015 * include/grub/elf.h (STN_ABS): New constant.
4016 (R_X86_64_NONE): Relocation constant for x86_64.
4017 (R_X86_64_64): Likewise.
4018 (R_X86_64_PC32): Likewise.
4019 (R_X86_64_GOT32): Likewise.
4020 (R_X86_64_PLT32): Likewise.
4021 (R_X86_64_COPY): Likewise.
4022 (R_X86_64_GLOB_DAT): Likewise.
4023 (R_X86_64_JUMP_SLOT): Likewise.
4024 (R_X86_64_RELATIVE): Likewise.
4025 (R_X86_64_GOTPCREL): Likewise.
4026 (R_X86_64_32): Likewise.
4027 (R_X86_64_32S): Likewise.
4028 (R_X86_64_16): Likewise.
4029 (R_X86_64_PC16): Likewise.
4030 (R_X86_64_8): Likewise.
4031 (R_X86_64_PC8): Likewise.
4032
4033 * include/grub/i386/efi/pci.h: New file.
4034
4035 * include/grub/i386/linux.h (GRUB_LINUX_EFI_SIGNATURE):
4036 Change it value based on platform.
4037 (GRUB_LINUX_EFI_SIGNATURE_0204): New constant.
4038 (GRUB_E820_RAM): Likewise.
4039 (GRUB_E820_RESERVED): Likewise.
4040 (GRUB_E820_ACPI): Likewise.
4041 (GRUB_E820_NVS): Likewise.
4042 (GRUB_E820_EXEC_CODE): Likewise.
4043 (GRUB_E820_MAX_ENTRY): Likewise.
4044 (grub_e820_mmap): New structure.
4045 (linux_kernel_header): Change the efi field according to different
4046 kernel version, also field from linux_kernel_header.
4047
4048 * include/grub/kernel.h (grub_module_info): Add padding for x86_64.
4049
4050 * include/grub/pci.h (GRUB_PCI_ADDR_SPACE_MASK): New constant.
4051 (GRUB_PCI_ADDR_SPACE_MEMORY): Likewise.
4052 (GRUB_PCI_ADDR_SPACE_IO): Likewise.
4053 (GRUB_PCI_ADDR_MEM_TYPE_MASK): Likewise.
4054 (GRUB_PCI_ADDR_MEM_TYPE_32): Likewise.
4055 (GRUB_PCI_ADDR_MEM_TYPE_1M): Likewise.
4056 (GRUB_PCI_ADDR_MEM_TYPE_64): Likewise.
4057 (GRUB_PCI_ADDR_MEM_PREFETCH): Likewise.
4058 (GRUB_PCI_ADDR_MEM_MASK): Likewise.
4059 (GRUB_PCI_ADDR_IO_MASK): Likewise.
4060
4061 * include/grub/x86_64/efi/kernel.h: New file.
4062
4063 * include/grub/x86_64/efi/loader.h: Likewise.
4064
4065 * include/grub/x86_64/efi/machine.h: Likewise.
4066
4067 * include/grub/x86_64/efi/pci.h: Likewise.
4068
4069 * include/grub/x86_64/efi/time.h: Likewise.
4070
4071 * include/grub/x86_64/linux.h: Likewise.
4072
4073 * include/grub/x86_64/setjmp.h: Likewise.
4074
4075 * include/grub/x86_64/time.h: Likewise.
4076
4077 * include/grub/x86_64/types.h: Likewise.
4078
4079 * kern/dl.c (GRUB_CPU_SIZEOF_VOID_P): Changed to
4080 GRUB_TARGET_SIZEOF_VOID_P.
4081
4082 * kern/efi/efi.c (grub_efi_locate_protocol): Wrap efi calls.
4083 (grub_efi_locate_handle): Likewise.
4084 (grub_efi_open_protocol): Likewise.
4085 (grub_efi_set_text_mode): Likewise.
4086 (grub_efi_stall): Likewise.
4087 (grub_exit): Likewise.
4088 (grub_reboot): Likewise.
4089 (grub_halt): Likewise.
4090 (grub_efi_exit_boot_services): Likewise.
4091 (grub_get_rtc): Likewise.
4092
4093 * kern/efi/mm.c (MEMORY_MAP_SIZE): Change to 0x3000 for new models.
4094 (GRUB_CPU_SIZEOF_VOID_P): Changed to GRUB_TARGET_SIZEOF_VOID_P.
4095 (grub_efi_allocate_pages): Wrap efi calls.
4096 (grub_efi_free_pages): Wrap efi calls.
4097 (grub_efi_get_memory_map): Wrap efi calls.
4098
4099 * kern/x86_64/dl.c: New file.
4100
4101 * kern/x86_64/efi/callwrap.S: Likewise.
4102
4103 * kern/x86_64/efi/startup.S: Likewise.
4104
4105 * loader/efi/appleloader.c: Likewise.
4106
4107 * loader/efi/chainloader.c (cmdline): New variable.
4108 (grub_chainloader_unload): Wrap efi calls.
4109 (grub_chainloader_boot): Likewise.
4110 (grub_rescue_cmd_chainloader): Wrap efi calls, handle
4111 command line.
4112
4113 * loader/efi/chainloader_normal.c (chainloader_command):
4114 Change grub_chainloader_cmd to grub_rescue_cmd_chainloader, pass
4115 command line.
4116
4117 * loader/i386/efi/linux.c (allocate_pages): Change allocation
4118 method.
4119 (grub_e820_add_region): New function.
4120 (grub_linux_boot): Construct e820 map from efi map, handle x86_64
4121 booting.
4122 (grub_find_video_card): New function.
4123 (grub_linux_setup_video): New function.
4124 (grub_rescue_cmd_linux): Probe for video information.
4125
4126 * normal/x86_64/setjmp.S: New file.
4127
4128 * term/efi/console.c (map_char): New function.
4129 (grub_console_putchar): Map unicode char.
4130 (grub_console_checkkey): Wrap efi calls.
4131 (grub_console_getkey): Likewise.
4132 (grub_console_getwh): Likewise.
4133 (grub_console_gotoxy): Likewise.
4134 (grub_console_cls): Likewise.
4135 (grub_console_setcolorstate): Likewise.
4136 (grub_console_setcursor): Likewise.
4137
4138 * util/i386/efi/grub-mkimage.c: Add support for x86_64.
4139
4140 2008-07-16 Pavel Roskin <proski@gnu.org>
4141
4142 * loader/i386/efi/linux.c (allocate_pages): Fix warnings in
4143 format strings.
4144
4145 * util/i386/efi/grub-mkimage.c (get_target_address): Return a
4146 pointer, not an integer. This fixes a warning and prevents
4147 precision loss on 64-bit systems.
4148 (relocate_addresses): Remove unneeded cast.
4149
4150 2008-07-15 Pavel Roskin <proski@gnu.org>
4151
4152 * kern/i386/ieee1275/init.c: Include grub/cache.h.
4153
4154 * term/ieee1275/ofconsole.c: Disable code unused on i386.
4155
4156 * kern/ieee1275/ieee1275.c (grub_ieee1275_get_integer_property):
4157 Fix comparison between signed and unsigned.
4158
4159 * include/grub/i386/ieee1275/console.h: Declare
4160 grub_console_init() and grub_console_fini().
4161
4162 * loader/i386/ieee1275/linux.c (grub_set_bootpath): Remove.
4163 It's empty and unused.
4164
4165 * fs/ext2.c (grub_ext2_read_block): Initialize blknr in the
4166 beginning to avoid warnings with some compilers.
4167
4168 * loader/ieee1275/multiboot2.c: Include grub/machine/loader.h.
4169 [__i386__] (grub_mb2_arch_boot): Avoid unnecessary cast.
4170
4171 2008-07-14 Pavel Roskin <proski@gnu.org>
4172
4173 * kern/env.c (grub_register_variable_hook): Don't copy empty
4174 string, it leaks memory. Pass "" to grub_env_set(), it should
4175 handle constant strings.
4176
4177 * commands/blocklist.c (grub_cmd_blocklist): Fix format warning.
4178 * commands/cmp.c (grub_cmd_cmp): Likewise.
4179 * kern/dl.c (grub_dl_flush_cache): Likewise.
4180 (grub_dl_load_core): Likewise.
4181 * kern/elf.c (grub_elf32_load_phdrs): Likewise.
4182 (grub_elf64_load_phdrs): Likewise.
4183
4184 2008-07-13 Pavel Roskin <proski@gnu.org>
4185
4186 * lib/LzmaEnc.c (LzmaEnc_SetProps): Fix warning about comparison
4187 between signed and unsigned.
4188 (LzmaEnc_Finish): Fix warning about an unused parameter.
4189
4190 2008-07-13 Bean <bean123ch@gmail.com>
4191
4192 * Makefile.in (enable_lzo): New rule.
4193
4194 * conf/i386-pc.rmk (grub_mkimage_SOURCES): New test with enable_lzo.
4195
4196 * configure.ac (ENABLE_LZO): New option --enable-lzo.
4197
4198 * boot/i386/pc/lnxboot.S: #include <config.h>.
4199
4200 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE): Change
4201 its value according to the compression algorithm used, lzo or lzma.
4202
4203 * util/i386/pc/grub-mkimage.c (compress_kernel): Use different
4204 compression algorithm according to configure macro.
4205
4206 * kern/i386/pc/startup.S (codestart): Likewise.
4207
4208 * kern/i386/pc/lzma_decode.S: New file.
4209
4210 * include/grub/lib/LzFind.h: Likewise.
4211
4212 * include/grub/lib/LzHash.h: Likewise.
4213
4214 * include/grub/lib/LzmaDec.h: Likewise.
4215
4216 * include/grub/lib/LzmaEnc.h: Likewise.
4217
4218 * include/grub/lib/LzmaTypes.h: Likewise.
4219
4220 * lib/LzFind.c: Likewise.
4221
4222 * lib/LzmaDec.c: Likewise.
4223
4224 * lib/LzmaEnc.c: Likewise.
4225
4226 2008-07-13 Bean <bean123ch@gmail.com>
4227
4228 * fs/ext2.c (EXT4_EXTENTS_FLAG): New macro.
4229 (grub_ext4_extent_header): New structure.
4230 (grub_ext4_extent): Likewise.
4231 (grub_ext4_extent_idx): Likewise.
4232 (grub_ext4_find_leaf): New function.
4233 (grub_ext2_read_block): Handle extents.
4234
4235 2008-07-12 Robert Millan <rmh@aybabtu.com>
4236
4237 * util/i386/pc/grub-mkrescue.in: s/grub-install/grub-mkrescue/g.
4238
4239 2008-07-11 Robert Millan <rmh@aybabtu.com>
4240
4241 * util/grub.d/40_custom.in: New file. Example on how to add custom
4242 entries to /etc/grub.d.
4243 * conf/common.rmk (%, update-grub_SCRIPTS, CLEANFILES): Install
4244 40_custom (implicitly, by merging all the grub.d rules).
4245
4246 2008-07-11 Pavel Roskin <proski@gnu.org>
4247
4248 * commands/read.c (grub_getline): Fix invalid memory access.
4249 Don't add newline to the variable value.
4250
4251 * term/i386/pc/serial.c (GRUB_SERIAL_PORT_NUM): New constant.
4252 [!GRUB_MACHINE_PCBIOS] (serial_hw_io_addr): Add COM2 and COM3.
4253 (serial_hw_get_port): Check validity of the port number.
4254 (grub_cmd_serial): Check return value of serial_hw_get_port().
4255
4256 2008-07-07 Pavel Roskin <proski@gnu.org>
4257
4258 * boot/i386/pc/diskboot.S (notification_string): Replace
4259 "Loading kernel" with just "loading". This is shorter, less
4260 confusing and saves a few bytes for possible future changes.
4261
4262 2008-07-05 Pavel Roskin <proski@gnu.org>
4263
4264 * disk/ata.c (grub_ata_dumpinfo): Don't output addressing and
4265 size for ATAPI devices, they are undefined. Output sector
4266 number in decimal form.
4267
4268 * disk/ata.c: Use named constants for status bits.
4269
4270 2008-07-04 Pavel Roskin <proski@gnu.org>
4271
4272 * kern/i386/linuxbios/init.c (grub_machine_init): Cast addr to
4273 grub_addr_t before casting it to the void pointer to fix a
4274 warning. Non-addressable regions are discarded earlier.
4275 (grub_arch_modules_addr): Cast _end to grub_addr_t.
4276 * kern/i386/linuxbios/table.c: Include grub/misc.h.
4277 (check_signature): Don't shadow table_header.
4278 (grub_linuxbios_table_iterate): Cast numeric constants to
4279 grub_linuxbios_table_header_t.
4280 * include/grub/i386/linuxbios/init.h: Add noreturn attribute to
4281 grub_stop().
4282
4283 * kern/ieee1275/init.c: Cast _start and _end to grub_addr_t to
4284 prevent warnings.
4285
4286 * include/grub/misc.h (ALIGN_UP): Avoid unnecessary cast to a
4287 pointer, which can cause warnings. Support 64-bit addresses.
4288
4289 * util/elf/grub-mkimage.c: Use GRUB_TARGET_SIZEOF_LONG instead
4290 of sizeof(long). This fixes PowerPC image generation on x86_64.
4291
4292 2008-07-04 Robert Millan <rmh@aybabtu.com>
4293
4294 This fixes a performance issue when pc & gpt partmap iterators
4295 didn't abort iteration even after our hook found what it was
4296 looking for (often causing expensive probes of non-existent drives).
4297
4298 Some callers relied on previous buggy behaviour, since they would
4299 raise an error when their own hooks caused early abortion of its
4300 iteration.
4301
4302 * kern/device.c (grub_device_open): Improve error message.
4303 * disk/lvm.c (grub_lvm_open): Likewise.
4304 * disk/raid.c (grub_raid_open): Likewise.
4305
4306 * partmap/pc.c (pc_partition_map_iterate): Abort parent iteration
4307 when hook requests it, independently of grub_errno.
4308 (pc_partition_map_probe): Do not fail when find_func() caused
4309 early abortion of pc_partition_map_iterate().
4310
4311 * partmap/gpt.c (gpt_partition_map_iterate): Abort parent iteration
4312 when hook requests it, independently of grub_errno.
4313 (gpt_partition_map_probe): Do not fail when find_func() caused
4314 early abortion of gpt_partition_map_iterate().
4315
4316 * kern/partition.c (grub_partition_iterate): Abort parent iteration
4317 when hook requests it, independently of grub_errno. Do not fail when
4318 part_map_iterate_hook() caused early abortion of p->iterate().
4319
4320 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Do not fail
4321 when grub_partition_iterate() returned with non-zero.
4322
4323 2008-07-03 Pavel Roskin <proski@gnu.org>
4324
4325 * disk/ata.c (grub_ata_pio_write): Check status before writing,
4326 like we do in grub_ata_pio_read().
4327 (grub_ata_readwrite): Always write individual sectors. Fix the
4328 sector count for the remainder.
4329 (grub_ata_write): Enable writing to ATA devices. Correctly
4330 report error for ATAPI devices.
4331
4332 2008-07-02 Pavel Roskin <proski@gnu.org>
4333
4334 * boot/i386/pc/cdboot.S: Add _start entry to fix a linker
4335 warning.
4336
4337 * disk/ata.c (grub_ata_readwrite): Don't increment sector number
4338 for every read sector, we already increment it for the whole
4339 batch. This fixes reading more than 256 sectors at once.
4340
4341 * util/grub-editenv.c (cmd_info): Cast argument to long
4342 explicitly. ptrdiff_t reduces to int on i386.
4343
4344 * util/grub-editenv.c (main): Be specific which parameter is
4345 missing.
4346
4347 * disk/memdisk.c (memdisk_addr): Make a pointer to fix warnings.
4348 (memdisk): Make memdisk_orig_addr a pointer.
4349
4350 * fs/reiserfs.c (grub_reiserfs_read): Fix misuse of grub_size_t
4351 for file offsets, use grub_off_t instead. Fix printf format
4352 warnings.
4353
4354 * fs/reiserfs.c: Remove #warning, TODO list items don't belong
4355 there. Real unexpected warnings should not drown in the noise
4356 about known problems.
4357
4358 * commands/hexdump.c (grub_cmd_hexdump): Fix misuse of
4359 grub_disk_addr_t for memory addresses.
4360
4361 * loader/aout.c (grub_aout_load): Cast load_addr to pointer
4362 explicitly to fix a warning.
4363
4364 * util/grub-editenv.c (cmd_info): Fix warning in printf format.
4365
4366 * Makefile.in (MODULE_LDFLAGS): New variable.
4367 * aclocal.m4 (grub_PROG_LD_BUILD_ID_NONE): New macro. Check if
4368 the linker accepts --build-id=none.
4369 * configure.ac: Call grub_PROG_LD_BUILD_ID_NONE. Substitute
4370 MODULE_LDFLAGS.
4371 * genmk.rb: Use MODULE_LDFLAGS when linking modules.
4372
4373 * fs/xfs.c (struct grub_xfs_dir_header): Use names similar to
4374 those in Linux XFS code. Provide a way to access 64-bit parent
4375 inode.
4376 (grub_xfs_iterate_dir): Use the new names. Avoid reading past
4377 the end of struct grub_xfs_dir_header.
4378
4379 2008-07-02 Bean <bean123ch@gmail.com>
4380
4381 * include/grub/ieee1275.h (grub_ieee1275_flag): New constant
4382 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
4383 and GRUB_IEEE1275_FLAG_NO_ANSI.
4384
4385 * kern/ieee1275/cmain.c (grub_ieee1275_find_options): Set flag
4386 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
4387 and GRUB_IEEE1275_FLAG_NO_ANSI for Open Hackware.
4388
4389 * kern/ieee1275/ieee1275.c (grub_ieee1275_interpret): Return
4390 immediately if GRUB_IEEE1275_FLAG_CANNOT_INTERPRET is set.
4391
4392 * kern/ieee1275/init.c (grub_claim_heap): Claim memory directly if
4393 GRUB_IEEE1275_FLAG_FORCE_CLAIM is set.
4394
4395 * term/ieee1275/ofconsole.c (grub_ofconsole_writeesc): Don't output
4396 esc sequence on non ANSI terminal.
4397 (grub_ofconsole_gotoxy): Emulate backspace key on non ANSI terminal.
4398
4399 * util/elf/grub-mkimage.c (add_segments): Move ELF header to the
4400 beginning of file.
4401
4402 2008-07-02 Bean <bean123ch@gmail.com>
4403
4404 * conf/common.rmk (bin_UTILITIES): Add grub-editenv.
4405 (grub_editenv_SOURCES): New variable.
4406 (pkglib_MODULES): Add loadenv.mod.
4407 (loadenv_mod_SOURCES): New variable.
4408 (loadenv_mod_CFLAGS): Likewise.
4409 (loadenv_mod_LDFLAGS): Likewise.
4410
4411 * include/grub/envblk.h: New file.
4412
4413 * util/envblk.c: New file.
4414
4415 * util/grub-editenv.c: New file.
4416
4417 * commands/loadenv.c: New file.
4418
4419 2008-07-01 Pavel Roskin <proski@gnu.org>
4420
4421 * include/multiboot2.h (struct multiboot_tag_module): Use char,
4422 not unsigned char. This fixes warnings and is consistent with
4423 other tags.
4424
4425 * disk/fs_uuid.c (search_fs_uuid): Correctly increment count.
4426
4427 * normal/parser.y: Define YYENABLE_NLS as 0 to fix warnings.
4428
4429 * term/tparm.c (analyze): Always set *popcount.
4430
4431 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Remove useless
4432 cast to fix a warning.
4433
4434 * loader/i386/pc/multiboot2.c (grub_mb2_arch_module_alloc): Use
4435 cast to suppress a warning.
4436
4437 * fs/afs.c (grub_afs_read_block): Return grub_disk_addr_t, as
4438 grub_fshelp_read_file() expects.
4439
4440 * fs/fat.c: Fix UUID calculation on big-endian systems. We
4441 write uuid as a 32-bit value in CPU byte order, so declare and
4442 use it as such.
4443
4444 * disk/raid.c: Cast grub_dprintf() arguments to unsigned long
4445 long if the format specifier expects it.
4446 * partmap/gpt.c (gpt_partition_map_iterate): Likewise.
4447 * partmap/pc.c (pc_partition_map_iterate): Likewise.
4448 * fs/ntfs.c (grub_ntfs_uuid): Cast data->uuid to unsigned long
4449 long to fix a warning.
4450 * fs/reiserfs.c (grub_reiserfs_read): Change casts in
4451 grub_dprintf() arguments to fix warnings.
4452
4453 2008-06-30 Pavel Roskin <proski@gnu.org>
4454
4455 * util/i386/pc/grub-setup.c (setup): Write install_dos_part and
4456 install_bsd_part immediately before core.img is embedded or
4457 modified on disk. This fixes core.img verification if core.img
4458 cannot be embedded.
4459
4460 * util/i386/pc/grub-setup.c (setup): Use core_path_dev, not
4461 core_path to calculate the blocklist.
4462 Patch from Javier Martín <lordhabbit@gmail.com>
4463
4464 2008-06-29 Robert Millan <rmh@aybabtu.com>
4465
4466 * fs/xfs.c (GRUB_XFS_FSB_TO_BLOCK): New macro. Maps filesystem
4467 block to disk block.
4468 (grub_xfs_read_block): Use GRUB_XFS_FSB_TO_BLOCK() on result.
4469 Patch from Niels Böhm <bitbucket@arcor.de>
4470
4471 2008-06-29 Robert Millan <rmh@aybabtu.com>
4472
4473 * util/update-grub_lib.in (font_path): Search for fonts in
4474 /boot/grub first, which is more likely to be readable (we aren't
4475 deciding where fonts live, just looking for them).
4476
4477 2008-06-26 Pavel Roskin <proski@gnu.org>
4478
4479 * util/biosdisk.c (read_device_map): Don't leave dead map
4480 entries for devices failing stat() check.
4481
4482 * util/i386/pc/grub-setup.c (setup): Don't reuse core_path, use
4483 core_path_dev for the core.img path on the target device.
4484
4485 2008-06-26 Robert Millan <rmh@aybabtu.com>
4486
4487 * disk/fs_uuid.c: New file.
4488 * conf/common.rmk (pkglib_MODULES): Add `fs_uuid.mod'.
4489 (fs_uuid_mod_SOURCES, fs_uuid_mod_CFLAGS)
4490 (fs_uuid_mod_LDFLAGS): New variables.
4491 * include/grub/disk.h (grub_disk_dev_id): Add
4492 `GRUB_DISK_DEVICE_UUID_ID'.
4493 * kern/disk.c (grub_disk_dev_iterate): Allow disk devices not to
4494 implement iterate().
4495
4496 2008-06-26 Robert Millan <rmh@aybabtu.com>
4497
4498 * util/grub.d/10_linux.in: Avoid passing UUIDs to Linux when either
4499 "/dev/disk/by-uuid/${GRUB_DEVICE_UUID}" does not exist, or when a
4500 Linux image includes no initrd.
4501
4502 2008-06-21 Javier Martín <lordhabbit@gmail.com>
4503
4504 * util/i386/pc/grub-setup.c (setup): Remove literal "core.img" in a
4505 call to resolve the core image location that effectively appended the
4506 name twice.
4507
4508 2008-06-21 Robert Millan <rmh@aybabtu.com>
4509
4510 * util/grub.d/00_header.in: Move last prepare_grub_to_access_device()
4511 call from here ...
4512
4513 * util/grub.d/10_hurd.in: ... to here ...
4514 * util/grub.d/10_linux.in: ... and here.
4515
4516 2008-06-19 Robert Millan <rmh@aybabtu.com>
4517
4518 * kern/main.c (grub_main): Export `prefix' variable immediately
4519 after it has been set by grub_machine_set_prefix().
4520
4521 2008-06-19 Robert Millan <rmh@aybabtu.com>
4522
4523 * commands/search.c (search_label, search_fs_uuid, search_file): Print
4524 search result when not saving to variable, not the other way around.
4525 When saving to variable, abort iteration as soon as a match is found.
4526
4527 2008-06-19 Robert Millan <rmh@aybabtu.com>
4528
4529 * util/update-grub_lib.in (prepare_grub_to_access_device): Remove
4530 check for partition that provides /boot/grub. Its logic is flawed,
4531 as it prevents prepare_grub_to_access_device() from being called
4532 multiple times.
4533
4534 2008-06-19 Robert Millan <rmh@aybabtu.com>
4535
4536 * util/update-grub_lib.in (prepare_grub_to_access_device): Issue
4537 "insmod" command directly when abstraction modules are needed,
4538 instead of relying on GRUB_PRELOAD_MODULES (which had no effect
4539 since it had already been processed).
4540
4541 2008-06-19 Pavel Roskin <proski@gnu.org>
4542
4543 * conf/i386-efi.rmk: Recompile grub-mkimage.c if Makefile has
4544 changed. This is needed in case GRUB_LIBDIR changes.
4545 * conf/i386-ieee1275.rmk: Likewise.
4546 * conf/i386-linuxbios.rmk: Likewise.
4547 * conf/i386-pc.rmk: Likewise.
4548 * conf/powerpc-ieee1275.rmk: Likewise.
4549
4550 2008-06-18 Pavel Roskin <proski@gnu.org>
4551
4552 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Rename
4553 kernel_elf_symlist.c to symlist.c for consistency with other
4554 architectures. Update all users.
4555 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
4556
4557 2008-06-18 Robert Millan <rmh@aybabtu.com>
4558
4559 * util/i386/pc/grub-install.in: If the drive is LVM or RAID, prepend
4560 it in prefix.
4561
4562 * util/i386/pc/grub-setup.c (main): Don't handle prefix at all. Set
4563 `must_embed' to 1 when root_dev is a RAID device. When dest_dev is
4564 a RAID device, run setup() for all members independently on whether
4565 LVM abstraction is being used.
4566 (setup): Don't handle prefix at all; let grub-mkimage take care of it.
4567 If grub-mkimage has set `*install_dos_part == -2', don't override this
4568 value.
4569 Perform *install_dos_part adjustments independently on whether
4570 we're embedding or not.
4571 Clarify error message when image is too big for embedding.
4572 Remove duplicate *install_dos_part stanza.
4573
4574 2008-06-17 Robert Millan <rmh@aybabtu.com>
4575
4576 * term/ieee1275/ofconsole.c (fgcolor, bgcolor): Remove variables.
4577 (grub_ofconsole_normal_color, grub_ofconsole_highlight_color): New
4578 variables.
4579 (grub_ofconsole_setcolor, grub_ofconsole_getcolor): Load/store
4580 values in grub_ofconsole_normal_color and
4581 grub_ofconsole_highlight_color (they're not directly related to
4582 background and foreground).
4583 (grub_ofconsole_setcolorstate): Extract background and foreground
4584 from grub_ofconsole_normal_color and grub_ofconsole_highlight_color.
4585
4586 2008-06-17 Robert Millan <rmh@aybabtu.com>
4587
4588 * util/update-grub_lib.in (prepare_grub_to_access_device): Use
4589 /boot/grub for the check in last commit, not /boot (they could be
4590 different partitions).
4591
4592 2008-06-16 Robert Millan <rmh@aybabtu.com>
4593
4594 * util/update-grub_lib.in (prepare_grub_to_access_device): If we were
4595 asked to setup access for the same partition that provides /boot,
4596 don't bother using UUIDs since our root already has the value we
4597 want.
4598
4599 2008-06-16 Robert Millan <rmh@aybabtu.com>
4600
4601 * util/biosdisk.c (convert_system_partition_to_system_disk): Detect
4602 I2O devices.
4603 Patch from Sven Mueller <sven@debian.org>.
4604
4605 2008-06-16 Robert Millan <rmh@aybabtu.com>
4606
4607 * util/update-grub.in: Check for $EUID instead of $UID.
4608 Reported by Vincent Zweije.
4609
4610 2008-06-16 Bean <bean123ch@gmail.com>
4611
4612 * fs/ext2.c (grub_ext2_blockgroup): Revert to pre-journal state.
4613 (grub_ext2_read_block): Likewise.
4614 (grub_ext2_read_inode): Likewise.
4615 (grub_ext2_mount): Likewise.
4616 (grub_ext2_close): Likewise.
4617 (grub_ext3_get_journal): Removed.
4618
4619 * fs/reiserfs.c (grub_reiserfs_get_item): Revert to pre-journal state.
4620 (grub_reiserfs_read_symlink): Likewise.
4621 (grub_reiserfs_mount): Likewise.
4622 (grub_reiserfs_open): Likewise.
4623 (grub_reiserfs_read): Likewise.
4624 (grub_reiserfs_close): Likewise.
4625 (grub_reiserfs_get_journal): Removed.
4626
4627 * fs/fshelp.c (grub_fshelp_read): Removed.
4628 (grub_fshelp_map_block): Likewise.
4629
4630 * include/grub/fshelp.h (grub_fshelp_journal_type): Removed.
4631 (grub_fshelp_journal): Likewise.
4632 (grub_fshelp_read): Likewise.
4633 (grub_fshelp_map_block): Likewise.
4634
4635 2008-06-16 Pavel Roskin <proski@gnu.org>
4636
4637 * conf/powerpc-ieee1275.rmk: Remove -msoft-float, we don't use
4638 floating point anymore.
4639 * include/grub/powerpc/libgcc.h: Leave only necessary exports.
4640
4641 2008-06-15 Pavel Roskin <proski@gnu.org>
4642
4643 * commands/ls.c (grub_ls_list_files): Use integer calculations
4644 for human readable format, avoid floating point use.
4645 * kern/misc.c (grub_ftoa): Remove.
4646 (grub_vsprintf): Remove floating point support.
4647
4648 2008-06-15 Robert Millan <rmh@aybabtu.com>
4649
4650 * util/grub.d/10_linux.in: Use the underlying device for loop-AES
4651 devices.
4652 Reported by Max Vozeler.
4653
4654 2008-06-15 Robert Millan <rmh@aybabtu.com>
4655
4656 * util/i386/pc/grub-mkimage.c (generate_image): If we included a drive
4657 in our prefix, set install_{dos,bsd}_part = -2 to indicate this can be
4658 skipped later.
4659 (main): If a memdisk was requested, add "(memdisk)" drive explicitly to
4660 the beginning of the prefix.
4661
4662 * kern/i386/pc/init.c (make_install_device): Remove memdisk check.
4663 It is assumed that if we have a memdisk, grub-mkimage has set
4664 grub_prefix to include the "(memdisk)" drive in it.
4665
4666 2008-06-15 Robert Millan <rmh@aybabtu.com>
4667
4668 * term/i386/pc/console.c [GRUB_MACHINE_LINUXBIOS] (grub_console_init):
4669 Initialize keyboard controller after registering the terminal, so that
4670 grub_printf() can be called from grub_keyboard_controller_init().
4671
4672 2008-06-15 Robert Millan <rmh@aybabtu.com>
4673
4674 * fs/sfs.c (grub_sfs_read_extent): Fix the count of nodes in
4675 extent-btree which is written as big endian on disk.
4676 Reported by Alain Greppin <al@chilibi.org>.
4677
4678 2008-06-14 Robert Millan <rmh@aybabtu.com>
4679
4680 * util/i386/efi/grub-install.in (modules): Remove `_chain'.
4681 * util/i386/pc/grub-install.in (modules): Likewise.
4682
4683 2008-06-13 Pavel Roskin <proski@gnu.org>
4684
4685 * commands/ls.c (grub_ls_list_files): Fix format warnings.
4686
4687 2008-06-13 Bean <bean123ch@gmail.com>
4688
4689 * commands/hexdump.c (grub_cmd_hexdump): Adjust offset for partition.
4690
4691 * fs/ext2.c (grub_ext3_get_journal): Fix revoke block handling.
4692
4693 * fs/fshelp.c (grub_fshelp_map_block): Don't map block 0 as it's used
4694 to indicate sparse block.
4695
4696 2008-06-12 Pavel Roskin <proski@gnu.org>
4697
4698 * fs/ext2.c (grub_ext2_read_inode): Don't normalize block
4699 number, grub_fshelp_read() does it for us.
4700
4701 * fs/fshelp.c (grub_fshelp_read): New function. Implement
4702 linear disk read with journal translation.
4703 * fs/ext2.c: Use grub_fshelp_read() instead of grub_disk_read().
4704 * include/grub/fshelp.h: Declare grub_fshelp_read().
4705
4706 2008-06-09 Pavel Roskin <proski@gnu.org>
4707
4708 * fs/minix.c (grub_minix_mount): Handle error reading
4709 superblock.
4710
4711 2008-06-08 Robert Millan <rmh@aybabtu.com>
4712
4713 * util/i386/pc/grub-setup.c (main): If install drive is an LVM,
4714 don't append the RAID prefix afterwards.
4715 Reported by Clint Adams.
4716
4717 2008-06-08 Robert Millan <rmh@aybabtu.com>
4718
4719 Based on description from Pavel:
4720 * kern/disk.c (grub_disk_check_range): Rename to ...
4721 (grub_disk_adjust_range): ... this. Add a comment explaining the
4722 tasks performed by this function.
4723
4724 2008-06-08 Robert Millan <rmh@aybabtu.com>
4725
4726 * include/grub/ntfs.h (struct grub_ntfs_bpb): Rename `serial_number' to
4727 `num_serial' (for consistency with other variables).
4728 (struct grub_ntfs_data): Add `uuid' member.
4729 * fs/ntfs.c (grub_ntfs_mount): Initialize `data->uuid'.
4730 (grub_ntfs_uuid): New function.
4731 (grub_ntfs_fs): Reference grub_ntfs_uuid() in `uuid' struct member.
4732
4733 2008-06-07 Pavel Roskin <proski@gnu.org>
4734
4735 * util/biosdisk.c (open_device): Revert last change to the
4736 function, it broke installation. The sector needs to be
4737 different dependent on which device is opened.
4738
4739 2008-06-06 Robert Millan <rmh@aybabtu.com>
4740
4741 Ensure GRUB_KERNEL_MACHINE_DATA_END is always consistent with the
4742 rest of GRUB, and breakage doesn't happen if its value were modified.
4743
4744 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
4745 Redefine as an offset from `GRUB_KERNEL_MACHINE_DATA_END' instead of
4746 a constant (same value).
4747 * kern/i386/pc/startup.S: Replace hardcoded `0x50' with
4748 `GRUB_KERNEL_MACHINE_DATA_END' (same value).
4749
4750 2008-06-06 Robert Millan <rmh@aybabtu.com>
4751
4752 * util/biosdisk.c (open_device): Do not modify sector offset when
4753 accessing a partition. kern/disk.c already handles this for us.
4754
4755 2008-06-06 Robert Millan <rmh@aybabtu.com>
4756
4757 * util/grub-emu.c (grub_machine_init): Move code in this function from
4758 here ...
4759 (main): ... to here (before grub_util_biosdisk_init() call, to prevent
4760 segfault in case grub_printf() is called).
4761
4762 * util/i386/pc/grub-install.in: Append `--device-map=${device_map}' to
4763 grub_probe. Update all users not to explicitly add it again.
4764 (grub_device): New variable; contains corresponding device for grubdir.
4765 (fs_module, partmap_module, devabstraction_module): Pass
4766 `--device ${grub_device}' to grub_probe to avoid traversing /dev
4767 every time.
4768
4769 2008-06-05 Robert Millan <rmh@aybabtu.com>
4770
4771 * normal/misc.c (grub_normal_print_device_info): When a filesystem UUID
4772 is found, print it (same layout as with labels).
4773
4774 2008-06-04 Robert Millan <rmh@aybabtu.com>
4775
4776 * util/biosdisk.c (get_drive): Rename to ...
4777 (find_grub_drive): ... this. Update all users.
4778
4779 (get_os_disk): Rename to ...
4780 (convert_system_partition_to_system_disk): ... this. Update all users.
4781
4782 (find_drive): Rename to ...
4783 (find_system_device): ... this. Update all users.
4784
4785 2008-06-04 Robert Millan <rmh@aybabtu.com>
4786
4787 * util/biosdisk.c (get_os_disk): Handle IDA devices.
4788 * util/grub-mkdevicemap.c (get_mmc_disk_name)
4789 (make_device_map): Likewise.
4790
4791 2008-06-01 Robert Millan <rmh@aybabtu.com>
4792
4793 * util/biosdisk.c (get_drive): Verify that `map[i].drive' is non-NULL
4794 before dereferencing it.
4795
4796 * fs/fat.c (struct grub_fat_bpb): Move fat32-specific fields into a
4797 union with fat12/fat16-specific ones. Add some new fields, including
4798 `num_serial' for both versions.
4799 (struct grub_fat_data): Add `uuid' member.
4800 (grub_fat_mount): Refer to fat32-specific fields in `bpb' by their new
4801 names. Initialize `data->uuid' using `num_serial'.
4802 (grub_fat_uuid): New function.
4803 (grub_fat_fs): Reference grub_fat_uuid() in `uuid' struct member.
4804
4805 * fs/reiserfs.c (grub_reiserfs_superblock): Add `uuid' field.
4806 (grub_reiserfs_uuid): New function.
4807 (grub_reiserfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct
4808 member.
4809
4810 * fs/xfs.c (grub_xfs_sblock): Add `uuid' field.
4811 (grub_xfs_uuid): New function.
4812 (grub_xfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct member.
4813
4814 2008-06-01 Robert Millan <rmh@aybabtu.com>
4815
4816 * util/update-grub_lib.in (prepare_grub_to_access_device): Generate
4817 code that is backward compatible with pre-uuid search command.
4818
4819 2008-05-31 Robert Millan <rmh@aybabtu.com>
4820
4821 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Iterate through
4822 floppies after everything else, to ensure floppy drive isn't accessed
4823 unnecessarily (patch from Bean).
4824
4825 2008-05-31 Robert Millan <rmh@aybabtu.com>
4826
4827 * commands/search.c (search_label, search_fs_uuid, search_file): Do
4828 not print device names when we were asked to set a variable.
4829
4830 2008-05-31 Robert Millan <rmh@aybabtu.com>
4831
4832 * term/ieee1275/ofconsole.c (grub_ofconsole_setcursor): Implement
4833 using "cursor-on" and "cursor-off" commands (understood at least by
4834 the Open Firmware flavour on OLPC).
4835
4836 2008-05-31 Michael Gorven <michael@gorven.za.net>
4837
4838 * term/terminfo.c (grub_terminfo_set_current): Correct vt100 cursor
4839 on and off sequences.
4840
4841 2008-05-31 Robert Millan <rmh@aybabtu.com>
4842
4843 * util/update-grub_lib.in: Replace `grub-probe' with `${grub_probe}'.
4844 * util/update-grub.in: Likewise.
4845
4846 2008-05-30 Pavel Roskin <proski@gnu.org>
4847
4848 * util/biosdisk.c (linux_find_partition): Simplify logic and
4849 make the code more universal. Keep special processing for
4850 devfs, but use a simple rule for all other devices. If the
4851 device ends with a number, append 'p' and the partition number.
4852 Otherwise, append only the partition number.
4853
4854 2008-05-30 Robert Millan <rmh@aybabtu.com>
4855
4856 * util/update-grub.in (GRUB_DISABLE_LINUX_UUID): Export variable.
4857 * util/grub.d/10_linux.in: If GRUB_DEVICE_UUID is set, and
4858 GRUB_DISABLE_LINUX_UUID isn't true, use the filesystem UUIDs as
4859 the `root' parameter to Linux.
4860
4861 2008-05-30 Robert Millan <rmh@aybabtu.com>
4862
4863 * commands/search.c (options): Rename --fs_uuid to --fs-uuid.
4864 * util/update-grub_lib.in (prepare_grub_to_access_device): Replace
4865 --fs_uuid with --fs-uuid.
4866 * util/update-grub.in: Allow filesystem UUID probes to fail (since not
4867 all filesystems support them).
4868
4869 2008-05-30 Robert Millan <rmh@aybabtu.com>
4870
4871 * fs/ext2.c (grub_ext2_uuid): Use `04x' instead of '02x' as
4872 grub_printf() flags, since we're printing in units of 2 bytes.
4873
4874 2008-05-30 Robert Millan <rmh@aybabtu.com>
4875
4876 * util/grub.d/00_header.in: Remove obsolete comment referencing
4877 convert_system_path_to_grub_path().
4878 * util/update-grub.in: Likewise.
4879 * util/update-grub_lib.in (is_path_readable_by_grub): New function.
4880 (convert_system_path_to_grub_path): Add a warning message explaining
4881 that this function is deprecated. Rely on is_path_readable_by_grub()
4882 for the readability checks.
4883 (font_path): Use is_path_readable_by_grub() for the readability
4884 check rather than convert_system_path_to_grub_path().
4885
4886 2008-05-30 Robert Millan <rmh@aybabtu.com>
4887
4888 * util/update-grub_lib.in (prepare_grub_to_access_device): New function.
4889 * util/update-grub.in: Set `GRUB_FONT_PATH' to the system path, without
4890 converting it first.
4891 * util/grub.d/00_header.in: Use prepare_grub_to_access_device() to setup
4892 grub.cfg for access to font file, and afterwards call it again to set
4893 the root device.
4894
4895 2008-05-30 Robert Millan <rmh@aybabtu.com>
4896
4897 * commands/search.c (options): Add --fs_uuid option.
4898 (search_fs_uuid): New function.
4899 (grub_cmd_search): Fix --set argument passing.
4900 Use search_fs_uuid() when requested via --fs_uuid.
4901 (grub_search_init): Update help message.
4902 * fs/ext2.c (struct grub_ext2_sblock): Rename `unique_id' to `uuid'
4903 and redeclare it as an array of 16-bit words.
4904 (grub_ext2_uuid): New function.
4905 (grub_ext2_fs): Reference grub_ext2_uuid() in `uuid' struct member.
4906 * include/grub/fs.h (struct grub_fs): Add `uuid' struct member.
4907 * util/update-grub.in (GRUB_DEVICE_UUID, GRUB_DEVICE_BOOT)
4908 (GRUB_DEVICE_BOOT_UUID): New variables.
4909 (GRUB_DRIVE. GRUB_DRIVE_BOOT. GRUB_DRIVE_BOOT_GRUB): Remove.
4910 * util/grub.d/00_header.in: Set root using `search --fs_uuid' command
4911 whenever possible.
4912 * util/grub.d/10_hurd.in: Avoid explicit use of root drive. Instead,
4913 just assume `root' variable has the right value.
4914 * util/grub.d/10_linux.in: Likewise.
4915 * util/grub-probe.c (probe): Probe for filesystem UUID when requested
4916 via PRINT_FS_UUID.
4917 (main): Recognise `-t fs_uuid' argument.
4918
4919 2008-05-30 Robert Millan <rmh@aybabtu.com>
4920
4921 * util/biosdisk.c (map): Redefine structure to hold information
4922 about GRUB drive name.
4923 (get_drive): Reimplement without assuming (and verifying) BIOS-like
4924 drive names.
4925 (call_hook): Remove.
4926 (grub_util_biosdisk_iterate): Access drive names via `.drive' struct
4927 member. Assume drive has partitions.
4928 (grub_util_biosdisk_open): Access device names via `.device' struct
4929 member.
4930 (open_device): Likewise.
4931 (find_drive): Likewise.
4932 (read_device_map): Adjust map[] usage to match the new struct
4933 definition. Don't check for duplicates (still possible, but not cheap
4934 anymore).
4935 (grub_util_biosdisk_fini): Free malloced buffers referenced by map[].
4936 (make_device_name): Remove assumption of BIOS-like drive names.
4937
4938 2008-05-30 Pavel Roskin <proski@gnu.org>
4939
4940 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Remove, as
4941 compiling execute.c doesn't need grub_script.tab.h anymore.
4942 (normal/command.c_DEPENDENCIES): Likewise.
4943 (normal/function.c_DEPENDENCIES): Likewise.
4944 * conf/i386-ieee1275.rmk: Likewise.
4945 * conf/i386-linuxbios.rmk: Likewise.
4946 * conf/i386-pc.rmk: Likewise.
4947 * conf/powerpc-ieee1275.rmk: Likewise.
4948 * conf/sparc64-ieee1275.rmk: Likewise.
4949
4950 2008-05-29 Pavel Roskin <proski@gnu.org>
4951
4952 * disk/lvm.c (grub_lvm_scan_device): Check for the buffer end
4953 when scanning metadata for volume group name.
4954
4955 * include/grub/script.h: Don't include grub_script.tab.h. It's
4956 a generated file, which may only be included from the files with
4957 DEPENDENCIES rules in the makefile. Don't use typedef YYSTYPE,
4958 use union YYSTYPE, as the later allows forward declaration.
4959 * normal/lexer.c: Don't use typedef YYSTYPE, use union YYSTYPE.
4960
4961 2008-05-29 Robert Millan <rmh@aybabtu.com>
4962
4963 * term/i386/pc/at_keyboard.c: Include `grub/machine/machine.h'.
4964 (OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): New macros.
4965 [GRUB_MACHINE_IEEE1275] (keyboard_map): Add OLPC scan codes
4966 (grub_console_checkkey): Add grub_dprintf() call to report unknown
4967 scan codes.
4968
4969 2008-05-29 Robert Millan <rmh@aybabtu.com>
4970
4971 * term/i386/pc/at_keyboard.c (grub_console_checkkey): Add support for
4972 control key combinations.
4973
4974 2008-05-29 Robert Millan <rmh@aybabtu.com>
4975
4976 * util/powerpc/ieee1275/grub-install.in: Move from here ...
4977 * util/ieee1275/grub-install.in: ... to here.
4978 * powerpc-ieee1275.rmk (grub_install_SOURCES): Update location.
4979 * i386-ieee1275.rmk (sbin_SCRIPTS): New variable.
4980 (grub_install_SOURCES): Likewise.
4981
4982 2008-05-29 Robert Millan <rmh@aybabtu.com>
4983
4984 * fs/affs.c: Update copyright year.
4985 * fs/ext2.c: Likewise.
4986 * fs/fshelp.c: Likewise.
4987 * fs/hfsplus.c: Likewise.
4988 * fs/ntfs.c: Likewise.
4989 * fs/xfs.c: Likewise.
4990 * include/grub/fshelp.h: Likewise.
4991 * util/grub-mkdevicemap.c: Likewise.
4992
4993 2008-05-28 Robert Millan <rmh@aybabtu.com>
4994
4995 * util/update-grub.in: Allow chmod call to fail, since /boot/grub/
4996 might need to be fatfs to support some firmware implementations
4997 (e.g. OFW or EFI).
4998
4999 2008-05-28 Robert Millan <rmh@aybabtu.com>
5000
5001 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle MMC
5002 devices.
5003 * util/grub-mkdevicemap.c (get_mmc_disk_name)
5004 (make_device_map): Likewise.
5005
5006 2008-05-20 Bean <bean123ch@gmail.com>
5007
5008 * fs/fshelp.c (grub_fshelp_map_block): New function.
5009 (grub_fshelp_find_file): Use 64-bit type for pos and block address.
5010 Use `>>' and `&' operator to avoid 64-bit divide and modulo.
5011
5012 * include/grub/fshelp.h (grub_fshelp_journal_type): New enum.
5013 (GRUB_FSHELP_JOURNAL_UNUSED_MAPPING): New macro.
5014 (grub_fshelp_journal): New structure.
5015 (grub_fshelp_map_block): New function prototype.
5016 (grub_fshelp_read_file): Use grub_disk_addr_t as block type.
5017 (grub_fshelp_map_block): Likewise.
5018
5019 * fs/ext2.c (EXT3_FEATURE_COMPAT_HAS_JOURNAL): New macro.
5020 (EXT3_JOURNAL_MAGIC_NUMBER): Likewise.
5021 (EXT3_JOURNAL_DESCRIPTOR_BLOCK): Likewise.
5022 (EXT3_JOURNAL_COMMIT_BLOCK): Likewise.
5023 (EXT3_JOURNAL_SUPERBLOCK_V1): Likewise.
5024 (EXT3_JOURNAL_SUPERBLOCK_V2): Likewise.
5025 (EXT3_JOURNAL_REVOKE_BLOCK): Likewise.
5026 (EXT3_JOURNAL_FLAG_ESCAPE): Likewise.
5027 (EXT3_JOURNAL_FLAG_SAME_UUID): Likewise.
5028 (EXT3_JOURNAL_FLAG_DELETED): Likewise.
5029 (EXT3_JOURNAL_FLAG_LAST_TAG): Likewise.
5030 (grub_ext2_sblock): New members for journal support.
5031 (grub_ext3_journal_header): New structure.
5032 (grub_ext3_journal_revoke_header): Likewise.
5033 (grub_ext3_journal_block_tag): Likewise.
5034 (grub_ext3_journal_sblock): Likewise.
5035 (grub_fshelp_node): New members logfile and journal.
5036 (grub_ext2_read_block): Change block type to grub_disk_addr_t. Use
5037 grub_fshelp_map_block to get real block number.
5038 (grub_ext2_blockgroup): Use grub_fshelp_map_block to get real block
5039 number.
5040 (grub_ext2_read_inode): Likewise.
5041 (grub_ext3_get_journal): New function.
5042 (grub_read_inode): Initialize journal using grub_ext3_get_journal.
5043 (grub_ext2_close): Release memory used by journal.
5044
5045 * fs/reiserfs.c (REISERFS_MAGIC_STRING): Changed to "ReIsEr".
5046 (REISERFS_MAGIC_DESC_BLOCK): New macro.
5047 (grub_reiserfs_transaction_header): Renamed to
5048 grub_reiserfs_description_block, replace field data with real_blocks.
5049 (grub_reiserfs_commit_block): New structure.
5050 (grub_reiserfs_data): New member journal.
5051 (grub_reiserfs_get_item): Use grub_fshelp_map_block to get real block
5052 number.
5053 (grub_reiserfs_read_symlink): Likewise.
5054 (grub_reiserfs_iterate_dir): Likewise.
5055 (grub_reiserfs_open): Likewise.
5056 (grub_reiserfs_read): Likewise.
5057 (grub_reiserfs_get_journal): New function.
5058 (grub_reiserfs_mount): Use "ReIsEr" as super block magic, as there are
5059 three varieties ReIsErFs, ReIsEr2Fs and ReIsEr3Fs. Initialize journal
5060 using grub_reiserfs_get_journal.
5061 (grub_reiserfs_close): Release memory used by journal.
5062
5063 * fs/affs.c (grub_affs_read_block): Change block type to
5064 grub_disk_addr_t. Use grub_divmod64 to do 64-bit division.
5065
5066 * fs/afs.c (grub_afs_read_block): Change block type to grub_disk_addr_t.
5067
5068 * fs/hfsplus.c (grub_hfsplus_read_block): Likewise.
5069
5070 * fs/ntfs.c (grub_ntfs_read_block): Likewise.
5071
5072 * fs/udf.c (grub_udf_read_block): Change block type to
5073 grub_disk_addr_t. Use type cast to avoid warning.
5074
5075 * fs/xfs.c (grub_xfs_read_block): Likewise.
5076
5077 2008-05-16 Christian Franke <franke@computer.org>
5078
5079 * commands/cat.c (grub_cmd_cat): Remove non-ESC keys from keyboard queue
5080 to ensure that break with ESC will always work.
5081 * commands/sleep.c (grub_interruptible_millisleep): Likewise.
5082 Remove ESC from keyboard queue.
5083
5084 2008-05-16 Christian Franke <franke@computer.org>
5085
5086 * util/biosdisk.c: [__CYGWIN__] Add includes.
5087 (grub_util_biosdisk_open): Use Linux code also for Cygwin.
5088 (get_os_disk): Move variable declarations to OS specific
5089 parts to avoid warning.
5090 [__GNU__] (get_os_disk): Fix /dev/sdXsN case.
5091 [__CYGWIN__] (get_os_disk): Add Cygwin /dev/sdXN device names.
5092 (grub_util_biosdisk_get_grub_dev): Use Linux code also for
5093 Cygwin.
5094 * util/getroot.c: [__CYGWIN__] Add includes.
5095 (strip_extra_slashes): Fix "/" case.
5096 [__CYGWIN__] (get_win32_path): New function.
5097 [__CYGWIN__] (grub_get_prefix): Add conversion to win32 path.
5098 [__CYGWIN__] (find_root_device): Disable.
5099 [__CYGWIN__] (get_bootsec_serial): New function.
5100 [__CYGWIN__] (find_cygwin_root_device): Likewise.
5101 [__linux__] (grub_guess_root_device): Add early returns to simplify
5102 structure.
5103 [__CYGWIN__] (grub_guess_root_device): Call find_cygwin_root_device.
5104 [__linux__] (grub_util_get_dev_abstraction): Enable LVM and RAID
5105 check for Linux only.
5106
5107 2008-05-15 Bean <bean123ch@gmail.com>
5108
5109 * kern/i386/pc/startup.S (grub_console_getkey): Workaround for the
5110 keyboard hang problem in apple's intel mac.
5111
5112 2008-05-09 Robert Millan <rmh@aybabtu.com>
5113
5114 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle Virtio
5115 devices.
5116 * util/grub-mkdevicemap.c (get_virtio_disk_name)
5117 (make_device_map): Likewise.
5118 Reported by Aurelien Jarno <aurel32@debian.org>
5119
5120 2008-05-07 Ian Campbell <ijc@hellion.org.uk>
5121
5122 * util/biosdisk.c (get_os_disk): Recognise xvd type disks.
5123 * util/grub-mkdevicemap.c (get_xvd_disk_name): New function.
5124 (make_device_map): Output entries for xvd type disks.
5125
5126 2008-05-07 Robert Millan <rmh@aybabtu.com>
5127
5128 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle CCISS
5129 devices.
5130 * util/grub-mkdevicemap.c (get_cciss_disk_name)
5131 (make_device_map): Likewise.
5132 Reported by Roland Dreier <rdreier@cisco.com>
5133
5134 2008-05-07 Robert Millan <rmh@aybabtu.com>
5135
5136 * disk/lvm.c (grub_lvm_scan_device): Detect errors in an additional
5137 grub_strstr() call. Correct a few mistakes in failure path handling.
5138
5139 2008-05-06 Robert Millan <rmh@aybabtu.com>
5140
5141 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
5142 Do not print a trailing slash (therefore, the root directory is an
5143 empty string).
5144 (convert_system_path_to_grub_path): Do not remove trailing slash
5145 from make_system_path_relative_to_its_root() output.
5146
5147 * util/i386/pc/grub-install.in: Add trailing slash to output from
5148 make_system_path_relative_to_its_root().
5149
5150 2008-05-06 Robert Millan <rmh@aybabtu.com>
5151
5152 * util/grub-fstest.c (grub_refresh): Call `fflush (stdout)'. This
5153 ensures that output lines aren't intermangled with those sent to
5154 stderr (via grub_util_info()).
5155 * util/grub-probe.c (grub_refresh): Likewise.
5156 * util/i386/pc/grub-setup.c (grub_refresh): Likewise.
5157
5158 2008-05-05 Christian Franke <franke@computer.org>
5159
5160 * util/grub-mkdevicemap.c (get_floppy_disk_name) [__CYGWIN__]:
5161 Add Cygwin device names.
5162 (get_ide_disk_name) [__CYGWIN__]: Likewise.
5163 (get_scsi_disk_name) [__CYGWIN__]: Likewise.
5164 (check_device): Return error instead of success on empty name.
5165 (make_device_map): Move label inside linux specific code to
5166 prevent compiler warning.
5167
5168 2008-04-30 Robert Millan <rmh@aybabtu.com>
5169
5170 Based on patch from Fabian Greffrath <greffrath@leat.rub.de>
5171 * util/grub.d/10_linux.in: Add ${GRUB_CMDLINE_LINUX_DEFAULT} to the
5172 first boot option.
5173 * util/update-grub.in: Export GRUB_CMDLINE_LINUX_DEFAULT.
5174
5175 2008-04-29 Robert Millan <rmh@aybabtu.com>
5176
5177 * docs/grub.cfg: New file (example GRUB configuration).
5178
5179 2008-04-26 Robert Millan <rmh@aybabtu.com>
5180
5181 * DISTLIST: Sort (sort -u < DISTLIST | sponge DISTLIST). Add
5182 `loader/i386/ieee1275/linux.c', `loader/i386/ieee1275/linux_normal.c'
5183 and `disk/ieee1275/nand.c'.
5184
5185 2008-04-25 Bean <bean123ch@gmail.com>
5186
5187 * Makefile.in (RMKFILES): Add missing arch i386-ieee1275 and
5188 i386-linuxbios.
5189
5190 * commands/hexdump.c (grub_cmd_hexdump): Support dumping of device,
5191 change the buffer size to 4096 for cdrom device.
5192
5193 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add _linux.mod, linux.mod
5194 and nand.mod.
5195 (_linux_mod_SOURCES): New variable.
5196 (_linux_mod_CFLAGS): Likewise.
5197 (_linux_mod_LDFLAGS): Likewise.
5198 (linux_mod_SOURCES): Likewise.
5199 (linux_mod_CFLAGS): Likewise.
5200 (linux_mod_LDFLAGS): Likewise.
5201 (nand_mod_SOURCES): Likewise.
5202 (nand_mod_CFLAGS): Likewise.
5203 (nand_mod_LDFLAGS): Likewise.
5204
5205 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Return
5206 GRUB_ERR_UNKNOWN_DEVICE instead of GRUB_ERR_BAD_DEVICE if no device
5207 type property. (nand device in olpc don't have this property)
5208
5209 * include/grub/disk.h (grub_disk_dev_id): New macro
5210 GRUB_DISK_DEVICE_NAND_ID.
5211
5212 * include/grub/i386/ieee1275/loader.h (grub_rescue_cmd_linux): New
5213 function prototype.
5214 (grub_rescue_cmd_initrd): Likewise.
5215
5216 * include/grub/i386/linux.h (GRUB_LINUX_OFW_SIGNATURE): New macro.
5217 (linux_kernel_params): Add new member ofw_signature, ofw_num_items,
5218 ofw_cif_handler and ofw_idt, adjust padding number.
5219
5220 * include/grub/i386/pc/memory.h (grub_upper_mem): Export it if
5221 GRUB_MACHINE_IEEE1275 is defined.
5222
5223 * include/grub/ieee1275/ieee1275.h (grub_available_iterate):
5224 Use NESTED_FUNC_ATTR attribute on the hook parameter.
5225
5226 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Use NESTED_FUNC_ATTR
5227 on nested function heap_init.
5228 (grub_upper_mem): New variable for i386-ieee1275.
5229 (grub_get_extended_memory): New function for i386-ieee1275.
5230 (grub_machine_init): Call grub_get_extended_memory for i386-ieee1275.
5231
5232 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Use
5233 NESTED_FUNC_ATTR on the hook parameter. Don't quit if no device type
5234 property.
5235
5236 * loader/i386/ieee1275/linux.c: New file.
5237
5238 * loader/i386/ieee1275/linux_normal.c: New file.
5239
5240 * disk/ieee1275/nand.c: New file.
5241
5242 2008-04-18 Thomas Schwinge <tschwinge@gnu.org>
5243
5244 * util/i386/pc/grub-mkrescue.in (grub_mkimage): Don't overwrite correct
5245 value.
5246 * util/powerpc/ieee1275/grub-mkrescue.in (grub_mkimage): Likewise.
5247
5248 2008-04-18 Robert Millan <rmh@aybabtu.com>
5249
5250 Restructures early code path on ieee1275 to unify grub_main() as
5251 the first C function that is executed in every platform.
5252
5253 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_init): New prototype.
5254 * kern/i386/ieee1275/startup.S (_start): Jump to grub_main() instead of
5255 cmain().
5256 * kern/powerpc/ieee1275/crt0.S (_start): Likewise.
5257 * kern/ieee1275/cmain.c (cmain): Rename to ...
5258 * kern/ieee1275/cmain.c (grub_ieee1275_init): ... this.
5259 * kern/ieee1275/init.c (grub_machine_init): Call grub_ieee1275_init()
5260 at the beginning.
5261
5262 2008-04-18 Robert Millan <rmh@aybabtu.com>
5263
5264 * util/update-grub.in: Fix syntax error when setting
5265 `GRUB_PRELOAD_MODULES'.
5266 Reported by Stephane Chazelas <stephane@artesyncp.com>
5267
5268 2008-04-17 Lubomir Kundrak <lkundrak@redhat.com>
5269
5270 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): take only .text
5271 section into account, newer toolchains generate unique build ids
5272 * configure.ac: remove the test for --build-id=none acceptance,
5273 we want build ids to be preserved
5274 * genmk.rb: add -R .note.gnu.build-id to objcopy, so build id
5275 far from other sections don't cause the raw binary images grow
5276 size
5277
5278 2008-04-15 Robert Millan <rmh@aybabtu.com>
5279
5280 * disk/lvm.c: Update copyright year.
5281 * kern/misc.c: Likewise.
5282
5283 2008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
5284
5285 * disk/lvm.c (grub_lvm_scan_device): Add forgotten failure path when
5286 there is no memory left for physical volume name.
5287
5288 2008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
5289
5290 * disk/lvm.c (grub_lvm_scan_device): Fix logical volume's physical
5291 volume name mapping to support bigger than 9 character names properly.
5292
5293 2008-04-13 Robert Millan <rmh@aybabtu.com>
5294
5295 * disk/i386/pc/biosdisk.c (grub_biosdisk_rw): Fix CHS limit check,
5296 as per http://www.allensmith.net/Storage/HDDlimit/Int13h.htm
5297
5298 2008-04-13 Christian Franke <franke@computer.org>
5299
5300 * util/i386/pc/grub-mkrescue.in: Add --emulation=floppy
5301 to create a floppy emulation boot CD when non emulation mode
5302 does not work.
5303 Enable Joliet CD filesystem extension.
5304
5305 2008-04-13 Robert Millan <rmh@aybabtu.com>
5306
5307 * kern/misc.c (grub_strncat): Fix off-by-one error.
5308 Reported by Zhang Huan <zhanghuan@nrchpc.ac.cn>
5309
5310 * kern/env.c (grub_env_context_close): Clear current context, not
5311 previous one.
5312 Patch from Zhang Huan <zhanghuan@nrchpc.ac.cn>
5313
5314 * kern/misc.c (grub_strcat): Minor speed optimization (same code size).
5315
5316 2008-04-13 Robert Millan <rmh@aybabtu.com>
5317
5318 Improve robustness when handling LVM.
5319
5320 * disk/lvm.c (grub_lvm_getvalue): Return 0 when `*p' is NULL
5321 (and leave `*p' unmodified).
5322 (grub_lvm_iterate): Don't assume `vg->lvs != NULL' when iterating
5323 through it.
5324 (grub_lvm_memberlist): Don't assume `lv->vg->pvs != NULL' when
5325 iterating through it.
5326 (grub_lvm_open): Don't assume `vg->lvs != NULL' when iterating
5327 through it.
5328 (grub_lvm_scan_device): Check the return value (and fail gracefully
5329 when due) on each grub_lvm_getvalue() or grub_strstr() call.
5330 Don't assume `vg->pvs != NULL' when iterating through it.
5331
5332 2008-04-13 Robert Millan <rmh@aybabtu.com>
5333
5334 * gendistlist.sh (EXTRA_DISTFILES): Add `genpartmaplist.sh'.
5335 * genmk.rb (partmap): New variable.
5336 (CLEANFILES, PARTMAPFILES): Add #{partmap}.
5337 (#{partmap}): New target rule.
5338 * genpartmaplist.sh: New file.
5339 * Makefile.in (pkglib_DATA): Add partmap.lst.
5340 (partmap.lst): New target rule.
5341 * util/i386/pc/grub-mkrescue.in: Generate grub.cfg that loads needed
5342 modules (including all partition maps), instead of preloading them.
5343
5344 2007-04-13 Fabian Greffrath <fabian.greffrath@web.de>
5345
5346 * util/grub.d/30_os-prober.in: New script. Use `os-prober' and
5347 `linux-boot-prober' (if installed) to detect other operating
5348 systems which are installed on the computer and add them to
5349 the boot menu.
5350 * conf/common.rmk: Build and install 30_os-prober.
5351
5352 2008-04-12 Robert Millan <rmh@aybabtu.com>
5353
5354 * kern/powerpc/ieee1275/init.c: Move from here ...
5355 * kern/ieee1275/init.c: ... to here. Update all users.
5356
5357 * kern/powerpc/ieee1275/cmain.c: Move from here ...
5358 * kern/ieee1275/cmain.c: ... to here. Update all users.
5359
5360 * kern/powerpc/ieee1275/openfw.c: Move from here ...
5361 * kern/ieee1275/openfw.c: ... to here. Update all users.
5362
5363 * loader/powerpc/ieee1275/multiboot2.c: Move from here ...
5364 * loader/ieee1275/multiboot2.c: ... to here. Update all users.
5365
5366 2008-04-10 Pavel Roskin <proski@gnu.org>
5367
5368 * configure.ac: Always use "_cv_" in cache variables for
5369 compatibility with Autoconf 2.62.
5370
5371 2008-04-07 Robert Millan <rmh@aybabtu.com>
5372
5373 Revert grub/machine/init.h addition by Pavel (since it breaks on
5374 i386-ieee1275 and others):
5375 * util/i386/pc/misc.c: Remove grub/machine/init.h.
5376 * util/powerpc/ieee1275/misc.c: Likewise.
5377
5378 2008-04-07 Robert Millan <rmh@aybabtu.com>
5379
5380 * util/grub-probe.c (probe): Improve error message.
5381
5382 2008-04-07 Robert Millan <rmh@aybabtu.com>
5383
5384 * util/biosdisk.c (read_device_map): Skip devices that don't exist
5385 (this prevents the presence of a bogus entry from ruining the whole
5386 thing).
5387
5388 2008-04-06 Pavel Roskin <proski@gnu.org>
5389
5390 * util/biosdisk.c: Include grub/util/biosdisk.h.
5391 * util/grub-fstest.c (execute_command): Make static.
5392 * util/grub-mkdevicemap.c (check_device): Likewise.
5393 * util/i386/pc/misc.c: Include grub/machine/init.h.
5394 * util/powerpc/ieee1275/misc.c: Likewise.
5395 * util/lvm.c: Include grub/util/lvm.h.
5396 * util/misc.c: Include grub/kernel.h, grub/misc.h and
5397 grub/cache.h.
5398 * util/raid.c: Include grub/util/raid.h.
5399 (grub_util_getdiskname): Make static.
5400
5401 * util/grub-emu.c (main): Remove calls to grub_hostfs_init() and
5402 grub_hostfs_fini(), as they are called from grub_init_all() and
5403 grub_fini_all() respectively. This fixes an infinite loop in
5404 grub-fstest due to double registration of hostfs.
5405 Reported by Christian Franke <Christian.Franke@t-online.de>
5406
5407 2008-04-05 Pavel Roskin <proski@gnu.org>
5408
5409 * bus/pci.c (grub_pci_iterate): For multifunction devices, probe
5410 all 8 functions. Otherwise, probe function 0 only.
5411
5412 2008-04-04 Pavel Roskin <proski@gnu.org>
5413
5414 * commands/lspci.c (grub_lspci_iter): Print the bus number
5415 correctly.
5416
5417 * commands/lspci.c (grub_pci_classes): Fix typos.
5418 (grub_lspci_iter): Don't print func twice. Print vendor ID
5419 before device ID, as it's normally done.
5420
5421 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
5422 Fix signedness warnings.
5423 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate):
5424 Likewise.
5425 * util/ieee1275/get_disk_name.c: Include config.h so that
5426 _GNU_SOURCE is defined and getline() is declared. Mark an
5427 unused argument as such. Fix a signedness warning.
5428
5429 2008-04-02 Pavel Roskin <proski@gnu.org>
5430
5431 * genkernsyms.sh.in: Use more robust assignments for CC and
5432 srcdir. Quote srcdir.
5433 * gensymlist.sh.in: Likewise. Assert at the compile time that
5434 the symbol table is not empty.
5435
5436 * disk/raid.c (grub_raid_memberlist): Fix a signedness warning.
5437 * fs/cpio.c (grub_cpio_read): Likewise.
5438
5439 2008-04-01 Pavel Roskin <proski@gnu.org>
5440
5441 * disk/ata.c (grub_ata_open): Don't lose precision in disk->id.
5442 * disk/host.c (grub_host_open): Likewise.
5443 * disk/loopback.c (grub_loopback_open): Likewise.
5444 * disk/memdisk.c (grub_memdisk_open): Use a string pointer for
5445 disk->id as in disk/host.c, not a multi-character constant.
5446
5447 * util/grub-fstest.c (cmd_cmp): Use fseeko(), not fseek(). The
5448 later is obsolete, potentially dangerous and sets a bad example.
5449 * util/i386/efi/grub-mkimage.c (make_header): Likewise.
5450 * util/misc.c (grub_util_get_image_size): Likewise.
5451
5452 * disk/loopback.c (options): Improve help for "--partitions".
5453
5454 * normal/arg.c (grub_arg_show_help): Fix spacing of the long
5455 options to align them with the short options, e.g. "echo -e".
5456
5457 2008-03-31 Bean <bean123ch@gmail.com>
5458
5459 * video/reader/png.c (grub_png_data): New member is_16bit and
5460 image_data.
5461 (grub_png_decode_image_header): Detect 16 bit png image.
5462 (grub_png_convert_image): New function to convert 16 bit image to 8 bit.
5463 (grub_png_decode_png): Call grub_png_convert_image for 16 bit image.
5464 (grub_video_reader_png): Release memory occupied by image_data.
5465
5466 * fs/ntfs.c (find_attr): Handle non-resident attribute list larger than
5467 4096 bytes.
5468 (grub_nfs_mount): Skip the test for sector per cluster.
5469
5470 * include/grub/ntfs.h (MAX_SPC): Removed.
5471
5472 2008-03-31 Bean <bean123ch@gmail.com>
5473
5474 * conf/common.rmk (pkgdata_MODULES): Add afs.mod.
5475 (grub_probe_SOURCES): Add fs/afs.c.
5476 (grub_fstest_SOURCES): Likewise.
5477 (afs_mod_SOURCES): New variable.
5478 (afs_mod_CFLAGS): Likewise.
5479 (afs_mod_LDFLAGS): Likewise.
5480
5481 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/afs.c.
5482 (grub_emu_SOURCES): Likewise.
5483
5484 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
5485
5486 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5487
5488 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
5489
5490 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5491
5492 * fs/afs.c: New file.
5493
5494 2008-03-30 Pavel Roskin <proski@gnu.org>
5495
5496 * disk/host.c: Include grub/misc.h to fix a warning.
5497 * util/hostfs.c: Use GRUB_MOD_INIT and GRUB_MOD_FINI to fix
5498 warnings about implicit declarations.
5499
5500 * fs/udf.c (grub_udf_mount): Fix warning about a shadowing a
5501 variable.
5502 * include/grub/i386/loader.h: Change declaration of
5503 grub_linux_boot() to match what grub_loader_set() expects.
5504 * util/getroot.c (grub_guess_root_device): Return const char* to
5505 fix a warning.
5506 * util/grub-probe.c (probe): Fix a warning about uninitialized
5507 abstraction_name variable.
5508 * util/i386/get_disk_name.c (grub_util_get_disk_name): Mark
5509 second argument as unused to fix a warning.
5510
5511 * loader/i386/pc/multiboot2.c (grub_mb2_arch_elf64_hook): Add
5512 missing grub_error() call.
5513
5514 * util/update-grub_lib.in: Define datarootdir, since Autoconf
5515 2.60 and newer uses it to define datadir.
5516
5517 * commands/sleep.c: Fix warning about implicit declaration.
5518 * disk/memdisk.c: Likewise.
5519 * loader/aout.c: Likewise.
5520 * loader/i386/bsd_normal.c: Likewise.
5521 * util/grub-probe.c: Likewise.
5522
5523 * commands/i386/cpuid.c (has_longmode): Make static.
5524 * disk/i386/pc/biosdisk.c (cd_drive): Likewise.
5525 * include/grub/i386/bsd.h (bios_memmap_t): Remove, it's unused.
5526
5527 * kern/i386/pc/startup.S (real_to_prot): Use %cs prefix to load
5528 GDT. This is more robust, as %ds can change.
5529 (grub_biosdisk_rw_int13_extensions): Don't clear %ds before
5530 calling real_to_prot().
5531 (grub_biosdisk_get_diskinfo_int13_extensions): Likewise.
5532
5533 2008-03-28 Pavel Roskin <proski@gnu.org>
5534
5535 * kern/i386/pc/startup.S: Assert that uncompressed functions
5536 don't spill beyond GRUB_KERNEL_MACHINE_RAW_SIZE.
5537 * kern/i386/pc/lzo1x.S: Remove all .align directives in the
5538 code, as they push parts of the code (error handlers) beyond
5539 GRUB_KERNEL_MACHINE_RAW_SIZE. Speed is not as important in this
5540 code as correctness and size.
5541
5542 2008-03-28 Pavel Roskin <proski@gnu.org>
5543
5544 * kern/i386/pc/startup.S
5545 (grub_biosdisk_get_diskinfo_int13_extensions): When converting
5546 data block address to the real mode, keep offset minimal. This
5547 works around a bug in AWARD BIOS on old Athlon systems, which
5548 makes CD detection hang.
5549
5550 2008-03-26 Pavel Roskin <proski@gnu.org>
5551
5552 * normal/color.c (grub_parse_color_name_pair): Make `name' a
5553 const.
5554 * include/grub/normal.h: Add grub_parse_color_name_pair()
5555 declaration.
5556
5557 2008-03-24 Bean <bean123ch@gmail.com>
5558
5559 * disk/i386/pc/biosdisk.c (cd_start): Removed.
5560 (cd_count): Removed.
5561 (cd_drive): New variable.
5562 (grub_biosdisk_get_drive): Don't check for (cdN) device.
5563 (grub_biosdisk_call_hook): Likewise.
5564 (grub_biosdisk_iterate): Change cdrom detection method.
5565 (grub_biosdisk_open): Replace cd_start with cd_drive.
5566 (GRUB_MOD_INIT): Use grub_biosdisk_get_cdinfo_int13_extension to
5567 detect cdrom device.
5568
5569 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_MACHINE_CDROM_START):
5570 Removed.
5571 (GRUB_BIOSDISK_MACHINE_CDROM_END): Removed.
5572 (GRUB_BIOSDISK_CDTYPE_NO_EMUL): New macro.
5573 (GRUB_BIOSDISK_CDTYPE_1_2_M): Likewise.
5574 (GRUB_BIOSDISK_CDTYPE_1_44_M): Likewise.
5575 (GRUB_BIOSDISK_CDTYPE_2_88_M): Likewise.
5576 (GRUB_BIOSDISK_CDTYPE_HARDDISK): Likewise.
5577 (GRUB_BIOSDISK_CDTYPE_MASK): Likewise.
5578 (grub_biosdisk_cdrp): New structure.
5579 (grub_biosdisk_get_cdinfo_int13_extensions): New function.
5580
5581 * include/grub/i386/pc/kernel.h (grub_boot_drive): Export this variable.
5582
5583 * kern/i386/pc/init.c (make_install_device): Don't use (cdN) as root
5584 device.
5585
5586 * kern/i386/pc/startup.S (grub_biosdisk_get_cdinfo_int13_extensions):
5587 New function.
5588
5589 2008-03-20 Robert Millan <rmh@aybabtu.com>
5590
5591 Remove 2 TiB limit in ata.mod.
5592 * disk/ata.c (grub_ata_device): Promote `size' to grub_uint64_t.
5593 (grub_ata_dumpinfo): Print sector count with 0x%llx.
5594 (grub_ata_identify): Interpret `&info16[100]' as a pointer to
5595 grub_uint64_t instead of grub_uint32_t.
5596
5597 2008-03-05 Bean <bean123ch@gmail.com>
5598
5599 * loader/i386/pc/multiboot.c (grub_multiboot_get_bootdev): New function.
5600 (grub_multiboot): Set boot device.
5601
5602 * boot/i386/pc/lnxboot.S (real_code_2): Set %dh to 0xFF.
5603
5604 2008-03-02 Bean <bean123ch@gmail.com>
5605
5606 * fs/reiserfs.c (grub_reiserfs_read_symlink): Add 0 at the end of
5607 symlink_buffer.
5608
5609 2008-03-01 Yoshinori K. Okuji <okuji@enbug.org>
5610
5611 * DISTLIST: Added docs/fdl.texi, docs/grub.texi, docs/mdate-sh and
5612 texinfo.tex.
5613
5614 * docs/grub.texi: New file. Copied from GRUB Legacy, and slightly
5615 modified.
5616
5617 * docs/fdl.texi: New file.
5618
5619 * docs/mdate-sh: New file. Copied from gnulib.
5620 * docs/texinfo.tex: Likewise.
5621
5622 * config.guess: Updated from gnulib.
5623 * install-sh: Likewise.
5624
5625 2008-02-28 Robert Millan <rmh@aybabtu.com>
5626
5627 * conf/i386-linuxbios.rmk (pkglib_MODULES): Add aout.mod.
5628 (aout_mod_SOURCES): New variable.
5629 (aout_mod_CFLAGS): Likewise.
5630 (aout_mod_LDFLAGS): Likewise.
5631
5632 * conf/i386-ieee1275.rmk: Likewise.
5633
5634 2008-02-28 Robert Millan <rmh@aybabtu.com>
5635
5636 * util/update-grub.in: Reorganise terminal validity check. Accept
5637 `ieee1275:console' (OLPC) and `*:gfxterm' as valid too.
5638 Based on suggestion by Franklin PIAT.
5639
5640 2008-02-28 Fabian Greffrath <greffrath@leat.rub.de>
5641
5642 * include/grub/util/getroot.h (grub_util_check_block_device): Export new
5643 function.
5644 * util/getroot.c (grub_util_check_block_device): New function that
5645 returns the given argument if it is a block device and returns NULL else.
5646 * util/grub-probe.c (argument_is_device): New variable.
5647 (probe): Promote device_name from a variable to an argument. Receive
5648 device_name from grub_util_check_block_device() if path is NULL and from
5649 grub_guess_root_device() else. Do not free() device_name anymore.
5650 (options): Introduce new parameter '-d, --device'.
5651 (main): Add description of the new parameter to the help screen.
5652 Rename path variable to argument. Set argument_is_device if the '-d'
5653 option is given. Pass argument to probe() depending on
5654 argument_is_device.
5655
5656 2008-02-24 Bean <bean123ch@gmail.com>
5657
5658 * fs/iso9660.c (GRUB_ISO9660_VOLDESC_BOOT): New macro.
5659 (GRUB_ISO9660_VOLDESC_PRIMARY): Likewise.
5660 (GRUB_ISO9660_VOLDESC_SUPP): Likewise.
5661 (GRUB_ISO9660_VOLDESC_PART): Likewise.
5662 (GRUB_ISO9660_VOLDESC_END): Likewise.
5663 (grub_iso9660_primary_voldesc): New member escape.
5664 (grub_iso9660_data): New member joliet.
5665 (grub_iso9660_convert_string): New function.
5666 (grub_iso9660_mount): Detect joliet extension.
5667 (grub_iso9660_iterate_dir): Convert filename when joliet is detected.
5668 (grub_iso9660_iso9660_label): Likewise.
5669
5670 * conf/common.rmk (pkgdata_MODULES): Add udf.mod.
5671 (grub_setup_SOURCES): Add fs/udf.c.
5672 (grub_fstest_SOURCES): Likewise.
5673 (udf_mod_SOURCES): New variable.
5674 (udf_mod_CFLAGS): Likewise.
5675 (udf_mod_LDFLAGS): Likewise.
5676
5677 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/udf.c.
5678 (grub_emu_SOURCES): Likewise.
5679
5680 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
5681
5682 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5683
5684 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
5685
5686 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5687
5688 * fs/udf.c: New file.
5689
5690 2008-02-24 Robert Millan <rmh@aybabtu.com>
5691
5692 * conf/i386-efi.rmk (normal/function.c_DEPENDENCIES)
5693 (normal/lexer.c_DEPENDENCIES): New variables.
5694 * conf/i386-ieee1275.rmk (normal/function.c_DEPENDENCIES)
5695 (normal/lexer.c_DEPENDENCIES): Likewise.
5696 * conf/i386-linuxbios.rmk (normal/function.c_DEPENDENCIES)
5697 (normal/lexer.c_DEPENDENCIES): Likewise.
5698 * conf/i386-pc.rmk (normal/function.c_DEPENDENCIES)
5699 (normal/lexer.c_DEPENDENCIES): Likewise.
5700 * conf/powerpc-ieee1275.rmk (normal/function.c_DEPENDENCIES)
5701 (normal/lexer.c_DEPENDENCIES): Likewise.
5702 * conf/sparc64-ieee1275.rmk (normal/function.c_DEPENDENCIES)
5703 (normal/lexer.c_DEPENDENCIES): Likewise.
5704
5705 2008-02-23 Robert Millan <rmh@aybabtu.com>
5706
5707 * partmap/gpt.c (grub_gpt_magic): Add `0x' qualifier to each member,
5708 since they were intended to be in hex. This didn't break previously
5709 because of a bug in gpt_partition_map_iterate() (see below).
5710
5711 (gpt_partition_map_iterate): Replace `grub_memcmp' with `! grub_memcmp'
5712 when checking the validity of GPT header.
5713 Remove `partno', since it always provides the same information as `i'.
5714
5715 2008-02-21 Yoshinori K. Okuji <okuji@enbug.org>
5716
5717 * include/grub/efi/time.h: Fix a wrong comment.
5718
5719 2008-02-19 Pavel Roskin <proski@gnu.org>
5720
5721 * kern/rescue.c (grub_enter_rescue_mode): Improve initial
5722 message.
5723
5724 2008-02-19 Bean <bean123ch@gmail.com>
5725
5726 * conf/i386-pc.rmk (pkglib_MODULES): Add aout.mod _bsd.mod and bsd.mod.
5727 (aout_mod_SOURCES): New variable.
5728 (aout_mod_CFLAGS): Likewise.
5729 (aout_mod_LDFLAGS): Likewise.
5730 (_bsd_mod_SOURCES): New variable.
5731 (_bsd_mod_CFLAGS): Likewise.
5732 (_bsd_mod_LDFLAGS): Likewise.
5733 (bsd_mod_SOURCES): New variable.
5734 (bsd_mod_CFLAGS): Likewise.
5735 (bsd_mod_LDFLAGS): Likewise.
5736
5737 * include/grub/aout.h: New file.
5738
5739 * include/grub/i386/loader.h (grub_unix_real_boot): New function.
5740
5741 * include/grub/i386/bsd.h: New file.
5742
5743 * include/grub/i386/pc/init.h (grub_get_mmap_entry): Use EXPORT_FUNC
5744 to make it public.
5745
5746 * kern/elf.c (grub_elf32_load): Get the physical address after the hook
5747 function is called, so that it's possible to change it inside the hook.
5748 (grub_elf64_load): Likewise.
5749 (grub_elf_file): Don't close the file if elf header is not found.
5750 (grub_elf_close): Close the file if grub_elf_file fails (The new
5751 grub_elf_file won't close it).
5752 (grub_elf32_size): Use NESTED_FUNC_ATTR for nested function calcsize.
5753 (grub_elf64_size): Likewise.
5754
5755 * kern/i386/loader.S (grub_unix_real_boot): New function.
5756
5757 * loader/aout.c: New file.
5758
5759 * loader/i386/bsd.c: New file.
5760
5761 * loader/i386/bsd_normal.c: New file.
5762
5763 * loader/i386/pc/multiboot.c (grub_multiboot): Handle a.out format.
5764
5765 * loader/multiboot2.c (grub_multiboot2): Reset grub_errno so that it
5766 can test other formats.
5767
5768 2008-02-19 Robert Millan <rmh@aybabtu.com>
5769
5770 * partmap/gpt.c: Include `<grub/gpt_partition.h>'.
5771 (grub_gpt_partition_type_empty): Redefine with macro from
5772 `<grub/gpt_partition.h>'.
5773 (gpt_partition_map_iterate): Adjust partition type comparison.
5774
5775 Export `entry' as partmap-specific `part.data' struct.
5776 (grub_gpt_header, grub_gpt_partentry): Move from here ...
5777
5778 * include/grub/gpt_partition.h (grub_gpt_header)
5779 (grub_gpt_partentry): ... to here (new file).
5780
5781 * util/i386/pc/grub-setup.c: Include `<grub/gpt_partition.h>'.
5782
5783 (grub_gpt_partition_type_bios_boot): New const variable, defined
5784 with macro from `<grub/gpt_partition.h>'.
5785
5786 (setup): Replace `first_start' with `embed_region', which keeps
5787 track of the embed region (and is partmap-agnostic).
5788
5789 Replace find_first_partition_start() with find_usable_region(),
5790 which finds a usable region for embedding using partmap-specific
5791 knowledge (supports PC/MSDOS and GPT).
5792
5793 Fix all assumptions that the embed region start at sector 1, using
5794 `embed_region.start' from now on. Similarly, use `embed_region.end'
5795 rather than `first_start' to calculate available size.
5796
5797 In grub_util_info() message, replace "into after the MBR" with an
5798 indication of the specific sector our embed region starts at.
5799
5800 2008-02-19 Robert Millan <rmh@aybabtu.com>
5801
5802 * DISTLIST: Replace `commands/ieee1275/halt.c' and
5803 `commands/ieee1275/reboot.c' with `commands/halt.c' and
5804 `commands/reboot.c'.
5805 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
5806 (halt_mod_SOURCES): Likewise.
5807 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
5808 (halt_mod_SOURCES): Likewise.
5809
5810 2008-02-17 Christian Franke <franke@computer.org>
5811
5812 * commands/cat.c (grub_cmd_cat): Add break on GRUB_TERM_ESC key.
5813
5814 2008-02-17 Robert Millan <rmh@aybabtu.com>
5815
5816 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
5817 set `first_start' to 0 for non-PC/MSDOS partition maps.
5818
5819 2008-02-16 Robert Millan <rmh@aybabtu.com>
5820
5821 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
5822 do not assume partition map is PC/MSDOS before performing checks that
5823 are specific to that layout.
5824
5825 2008-02-13 Robert Millan <rmh@aybabtu.com>
5826
5827 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Remove
5828 `commands/i386/pc/halt.c' and `commands/i386/pc/reboot.c'.
5829 * kern/i386/linuxbios/init.c (grub_halt, grub_reboot): Remove stubs.
5830
5831 2008-02-13 Yoshinori K. Okuji <okuji@enbug.org>
5832
5833 * configure.ac: Only a cosmetic change on the handling of
5834 -fno-stack-protector.
5835
5836 2008-02-12 Alexandre Boeglin <alex@boeglin.org>
5837
5838 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace
5839 commands/i386/pc/halt.c and reboot.c by commands/halt.c and
5840 reboot.c.
5841 (grub_install_SOURCES): Add halt.mod and reboot.mod.
5842 (halt_mod_SOURCES): New variable.
5843 (halt_mod_CFLAGS): Likewise.
5844 (halt_mod_LDFLAGS): Likewise.
5845 (reboot_mod_SOURCES): Likewise.
5846 (reboot_mod_CFLAGS): Likewise.
5847 (reboot_mod_LDFLAGS): Likewise.
5848
5849 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace
5850 commands/ieee1275/halt.c and reboot.c by commands/halt.c and
5851 reboot.c.
5852 (halt_mod_SOURCES): Likewise.
5853 (reboot_mod_SOURCES): Likewise.
5854
5855 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace
5856 commands/i386/pc/reboot.c by commands/reboot.c.
5857 (reboot_mod_SOURCES): Likewise.
5858
5859 * commands/i386/pc/reboot.c: merge this file ...
5860
5861 * commands/ieee1275/reboot.c: ... and this file ...
5862
5863 * commands/reboot.c: ... to this file.
5864 Add some precompiler directive to include the correct header for
5865 each machine.
5866
5867 * commands/ieee1275/halt.c: move this file ...
5868
5869 * commands/halt.c: ... to here.
5870 Add some precompiler directive to include the correct header for
5871 each machine.
5872
5873 * include/grub/efi/efi.h (grub_reboot): New function declaration.
5874 (grub_halt): Likewise.
5875
5876 * kern/efi/efi.c (grub_reboot): New function.
5877 (grub_halt): Likewise.
5878
5879 2008-02-12 Robert Millan <rmh@aybabtu.com>
5880
5881 * util/getroot.c (grub_guess_root_device): Inspect /dev/evms before
5882 /dev (like it is done for /dev/mapper). This doesn't provide support
5883 for EVMS, but at least it is now easy to identify the problem when it
5884 arises.
5885
5886 2008-02-11 Robert Millan <rmh@aybabtu.com>
5887
5888 * util/biosdisk.c (grub_util_biosdisk_open, linux_find_partition)
5889 (grub_util_biosdisk_get_grub_dev): Check open() exit status by
5890 comparing it with -1, not 0.
5891
5892 2008-02-10 Robert Millan <rmh@aybabtu.com>
5893
5894 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `disk/raid.c' and
5895 `disk/lvm.c'.
5896 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5897 * conf/i386-pc.rmk (grub_setup_SOURCES): Likewise.
5898
5899 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Move `disk/raid.c' and
5900 `disk/lvm.c' to the end of the list.
5901 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
5902 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
5903
5904 2008-02-10 Robert Millan <rmh@aybabtu.com>
5905
5906 * kern/main.c (grub_load_normal_mode): Do not reset `grub_errno'. Call
5907 grub_print_error() instead. This will let user know why we're entering
5908 rescue mode.
5909 Based on suggestions from Sam Morris.
5910
5911 2008-02-10 Alexandre Boeglin <alex@boeglin.org>
5912
5913 * normal/arg.c (grub_arg_parse): If one of the args is "--", call add_arg()
5914 on remaining N args, instead of "--" arg N times.
5915
5916 2008-02-09 Vesa Jaaskelainen <chaac@nic.fi>
5917
5918 * font/manager.c (unknown_glyph): Added variable for unknown glyph.
5919 (fill_with_default_glyph): Changed to use unknown_glyph for fill
5920 pattern for unknown glyphs.
5921
5922 2008-02-09 Robert Millan <rmh@aybabtu.com>
5923
5924 * configure.ac: Probe for `help2man'.
5925 * Makefile.in (builddir): New variable.
5926 (HELP2MAN): Likewise. Set to `true' when @HELP2MAN@ doesn't provide it,
5927 or otherwise add a few flags/options to it.
5928 (install-local): For every executable utility or script that is
5929 installed, invoke $(HELP2MAN) to install a manpage based on --help
5930 output.
5931
5932 * util/i386/pc/grub-install.in: Move down `update-grub_lib' sourcing, so
5933 that it doesn't prevent --help from working in build tree.
5934
5935 * util/i386/pc/grub-mkrescue.in (usage): Replace `grub-devel@gnu.org'
5936 with `bug-grub@gnu.org'.
5937 * util/powerpc/ieee1275/grub-mkrescue.in (usage): Likewise.
5938 * util/update-grub.in (usage): New function.
5939 Implement proper argument check, with support for --help and --version
5940 (as well as existing -y).
5941
5942 2008-02-09 Christian Franke <franke@computer.org>
5943
5944 * commands/cat.c (grub_cmd_cat): Print '\r' as hex to
5945 avoid overwriting previous output.
5946 * kern/rescue.c (grub_rescue_cmd_cat): Likewise.
5947
5948 2008-02-09 Robert Millan <rmh@aybabtu.com>
5949
5950 * normal/menu.c (run_menu): If timeout is set to zero, don't bother
5951 drawing the menu.
5952
5953 2008-02-09 Robert Millan <rmh@aybabtu.com>
5954
5955 * commands/sleep.c: New file.
5956 * conf/common.rmk (pkglib_MODULES): Add `commands/sleep.c'.
5957 (sleep_mod_SOURCES): New variable.
5958 (sleep_mod_CFLAGS): Likewise.
5959 (sleep_mod_LDFLAGS): Likewise.
5960
5961 2008-02-09 Robert Millan <rmh@aybabtu.com>
5962
5963 * disk/raid.c (grub_raid_scan_device): Add a pair of sanity checks for
5964 situations in which we can deduce the RAID size and the superblock
5965 doesn't match it.
5966
5967 2008-02-09 Robert Millan <rmh@aybabtu.com>
5968
5969 * disk/lvm.c [GRUB_UTIL] (grub_lvm_memberlist): New function. Construct
5970 and return a grub_diskmemberlist_t composed of LVM physical volumes.
5971 [GRUB_UTIL] (grub_lvm_dev): Add `memberlist' member.
5972
5973 * disk/raid.c [GRUB_UTIL] (grub_raid_memberlist): New function. Construct
5974 and return a grub_diskmemberlist_t composed of physical array members.
5975 [GRUB_UTIL] (grub_raid_dev): Add `memberlist' member.
5976
5977 * include/grub/disk.h [GRUB_UTIL] (grub_disk_memberlist): New struct
5978 prototype.
5979 [GRUB_UTIL] (struct grub_disk_dev): Add `memberlist' function pointer.
5980 [GRUB_UTIL] (struct grub_disk_memberlist): New struct declaration.
5981 [GRUB_UTIL] (grub_disk_memberlist_t): New typedef.
5982
5983 * util/grub-probe.c (probe): Move partmap probing code from here ...
5984 (probe_partmap): ... to here.
5985 (probe): Use probe_partmap() once for the disk we're probing, and
5986 additionally, when such disk contains a memberlist() struct member,
5987 once for each disk that is contained in the structure returned by
5988 memberlist().
5989
5990 2008-02-09 Robert Millan <rmh@aybabtu.com>
5991
5992 * util/grub-probe.c (main): When `verbosity > 1', set `debug'
5993 environment variable to 'all' in order to obtain debug output from
5994 non-util/ code.
5995 * util/i386/pc/grub-setup.c (main): Likewise.
5996
5997 2008-02-08 Robert Millan <rmh@aybabtu.com>
5998
5999 * disk/raid.c (grub_raid_scan_device): Check for
6000 `array->device[sb.this_disk.number]' rather than for
6001 `array->device[sb.this_disk.number]->name', since the latter is not
6002 guaranteed to be accessible.
6003
6004 2008-02-08 Robert Millan <rmh@aybabtu.com>
6005
6006 * disk/raid.c: Update copyright.
6007 * fs/cpio.c: Likewise.
6008 * include/grub/raid.h: Likewise.
6009 * loader/i386/pc/multiboot.c: Likewise.
6010 * util/hostfs.c: Likewise.
6011
6012 2008-02-08 Robert Millan <rmh@aybabtu.com>
6013
6014 * include/grub/raid.h (struct grub_raid_array): Change type of `device'
6015 to a grub_disk_t array.
6016 * disk/raid.c (grub_raid_read): Replace `device[x].disk' accesses with
6017 `device[x]'.
6018 (grub_raid_scan_device): Replace `device[x].name' accesses with
6019 `device[x]->name'. Simplify initialization of `array->device[x]'.
6020
6021 2008-02-08 Robert Millan <rmh@aybabtu.com>
6022
6023 * disk/raid.c (grub_raid_open, grub_raid_scan_device): Add a few
6024 grub_dprintf() calls.
6025 * kern/disk.c (grub_disk_read): Include grub_errmsg in out of range
6026 error message.
6027
6028 2008-02-07 Christian Franke <franke@computer.org>
6029
6030 * util/hostfs.c (grub_hostfs_open): Use fseeko and ftello
6031 instead of fseek and ftell to support large files.
6032 (grub_hostfs_read): Likewise.
6033
6034 2008-02-07 Robert Millan <rmh@aybabtu.com>
6035
6036 Patch from Jeroen Dekkers.
6037 * disk/raid.c (grub_raid_scan_device): Reset `grub_errno' on disk
6038 failure, since successfully reading all array members might not be
6039 required.
6040
6041 2008-02-06 Robert Millan <rmh@aybabtu.com>
6042
6043 * util/grub-probe.c (probe): Simplify partmap probing (with the
6044 assumption that the first word up to the underscore equals to
6045 the module name).
6046
6047 2008-02-06 Christian Franke <franke@computer.org>
6048
6049 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_NONE
6050 (and set *ofs = 0) instead of GRUB_ERR_FILE_NOT_FOUND on
6051 last block of a cpio or tar stream.
6052 Check for "TRAILER!!!" instead of any empty data
6053 block to detect last block of a cpio stream.
6054 (grub_cpio_dir): Fix constness of variable np.
6055 (grub_cpio_open): Return GRUB_ERR_FILE_NOT_FOUND if
6056 cpio or tar trailer is detected. This fixes a crash
6057 on open of a non existing file.
6058
6059 2008-02-05 Bean <bean123ch@gmail.com>
6060
6061 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Get physical
6062 address of entry.
6063 (grub_multiboot_load_elf64): Likewise.
6064 (grub_multiboot): Initialize mbi structure.
6065
6066 * util/grub-fstest.c: Don't include unused header file script.h.
6067
6068 * conf/common.rmk (grub-fstest.c_DEPENDENCIES): Move to the beginning
6069 of file.
6070 (grub_fstest_SOURCES): Likewise.
6071
6072 2008-02-05 Robert Millan <rmh@aybabtu.com>
6073
6074 * include/grub/term.h (GRUB_TERM_LEFT, GRUB_TERM_RIGHT)
6075 (GRUB_TERM_UP, GRUB_TERM_DOWN, GRUB_TERM_HOME, GRUB_TERM_END)
6076 (GRUB_TERM_DC, GRUB_TERM_PPAGE, GRUB_TERM_NPAGE, GRUB_TERM_ESC)
6077 (GRUB_TERM_TAB, GRUB_TERM_BACKSPACE): New macros.
6078
6079 * kern/i386/pc/startup.S: Include `<grub/term.h>'.
6080 (translation_table): Replace hardcoded values with macros
6081 provided by `<grub/term.h>'.
6082
6083 * term/i386/pc/at_keyboard.c: Include `<grub/term.h>'.
6084 (keyboard_map): Correct/add a few values, with macros provided
6085 by `<grub/term.h>'.
6086 (keyboard_map_shift): Zero values that don't differ from their
6087 `keyboard_map' equivalents.
6088 (grub_console_checkkey): Optimize KEYBOARD_STATUS_CAPS_LOCK toggling.
6089 Discard the second scan code that is always sent by Caps lock.
6090 Only use `keyboard_map_shift' when it provides a non-zero value,
6091 otherwise fallback to `keyboard_map'.
6092
6093 2008-02-04 Bean <bean123ch@gmail.com>
6094
6095 * Makefile.in (enable_grub_fstest): New variable.
6096
6097 * conf/common.rmk (grub_fstest_init.lst): New rule.
6098 (grub_fstest_init.h): Likewise.
6099 (grub_fstest_init.c): Likewise.
6100 (util/grub-fstest.c_DEPENDENCIES): New variable.
6101 (grub_fstest_SOURCES): Likewise.
6102
6103 * configure.ac (enable_grub_fstest): Check for --enable-grub-fstest.
6104
6105 * util/grub-fstest.c: New file.
6106
6107 2008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
6108
6109 Make grub-setup handle a separate root device.
6110
6111 * util/i386/pc/grub-setup.c (setup): Always open the root device,
6112 so that the root device can be compared with the destination
6113 device.
6114 When embedding the core image, if the root and destination devices
6115 are different, set ROOT_DRIVE to ROOT_DEV->DISK->ID. Otherwise, to
6116 0xFF.
6117 When not embedding, set ROOT_DRIVE to 0xFF.
6118
6119 2008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
6120
6121 Add support for having a grub directory in a different drive. This
6122 is still only the data handling part.
6123
6124 * kern/i386/pc/startup.S (multiboot_trampoline): Set %dh to 0xFF.
6125 (codestart): Save %dh in GRUB_ROOT_DRIVE.
6126 (grub_root_drive): New variable.
6127
6128 * kern/i386/pc/init.c (make_install_device): Use GRUB_ROOT_DRIVE
6129 instead of GRUB_BOOT_DRIVE to construct a device name. Set
6130 GRUB_ROOT_DRIVE to GRUB_BOOT_DRIVE if it is 0xFF, otherwise use it
6131 as it was.
6132
6133 * include/grub/i386/pc/kernel.h (grub_root_drive): New prototype.
6134
6135 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_ROOT_DRIVE): New
6136 macro.
6137 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Set to 0x4f.
6138
6139 * boot/i386/pc/pxeboot.S (_start): Set %dh to 0xFF. For now, this
6140 is bogus, because PXE booting does not specify any drive
6141 correctly.
6142
6143 * boot/i386/pc/lnxboot.S (reg_edx): Set the second byte to 0xFF. I
6144 am not sure if this is really correct.
6145
6146 * boot/i386/pc/cdboot.S: Set %dh to 0xFF, because the root drive
6147 is always identical to the boot drive when booting from a CD.
6148
6149 * boot/i386/pc/boot.S (MOV_MEM_TO_AL): Removed. Not needed any
6150 longer.
6151 (root_drive): New variable.
6152 (real_start): Unconditionally set %dh to ROOT_DRIVE.
6153 (setup_sectors): Push %dx right after popping it, because %dh will
6154 be modified later.
6155 (copy_buffer): Restore %dx.
6156
6157 2008-02-03 Robert Millan <rmh@aybabtu.com>
6158
6159 * util/i386/pc/grub-mkrescue.in: Rewrite most of image generation to
6160 use `cdboot.img' for cdrom images.
6161
6162 2008-02-03 Robert Millan <rmh@aybabtu.com>
6163
6164 * util/grub.d/00_header.in: Issue scripting commands for GRUB to
6165 only setup gfxterm when `font' command has succeeded.
6166
6167 2008-02-03 Robert Millan <rmh@aybabtu.com>
6168
6169 * loader/multiboot_loader.c [GRUB_MACHINE_LINUXBIOS]
6170 (grub_rescue_cmd_multiboot_loader)
6171 (grub_rescue_cmd_module_loader): Enable multiboot1 calls.
6172
6173 2008-02-03 Pavel Roskin <proski@gnu.org>
6174
6175 * kern/i386/pc/startup.S (grub_chainloader_real_boot): Pop
6176 %edx and %esi from stack only after grub_gate_a20() is called.
6177 grub_gate_a20() clobbers %edx.
6178
6179 2008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
6180
6181 * configure.ac (AC_INIT): Bumped to 1.96.
6182
6183 * DISTLIST: Added boot/i386/pc/cdboot.S, bus/pci.c,
6184 commands/lspci.c,disk/memdisk.c, include/grub/pci.h,
6185 include/grub/i386/pc/pci.h, video/readers/jpeg.c, and
6186 video/readers/png.c.
6187
6188 2008-02-03 Bean <bean123ch@gmail.com>
6189
6190 * conf/i386-pc.rmk (pkglib_IMAGES): Add cdboot.img.
6191 (cdboot_img_SOURCES): New variable.
6192 (cdboot_img_ASFLAGS): New variable.
6193 (cdboot_img_LDFLAGS): New variable.
6194
6195 * boot/i386/pc/cdboot.S: New file.
6196
6197 * disk/i386/pc/biosdisk.c (cd_start): New variable.
6198 (cd_count): Likewise.
6199 (grub_biosdisk_get_drive): Add support for cd device.
6200 (grub_biosdisk_call_hook): Likewise.
6201 (grub_biosdisk_iterate): Likewise.
6202 (grub_biosdisk_open): Likewise.
6203 (GRUB_BIOSDISK_CDROM_RETRY_COUNT): New macro.
6204 (grub_biosdisk_rw): Support reading from cd device.
6205 (GRUB_MOD_INIT): Iterate cd devices.
6206
6207 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_FLAG_CDROM): New macro.
6208 (GRUB_BIOSDISK_MACHINE_CDROM_START): Likewise.
6209 (GRUB_BIOSDISK_MACHINE_CDROM_END): Likewise.
6210
6211 * kern/i386/pc/init.c (make_install_device): Check for cd device.
6212
6213 2008-02-02 Robert Millan <rmh@aybabtu.com>
6214
6215 * commands/read.c: New file.
6216 * conf/common.rmk (pkglib_MODULES): Add `commands/read.c'.
6217 (read_mod_SOURCES): New variable.
6218 (read_mod_CFLAGS): Likewise.
6219 (read_mod_LDFLAGS): Likewise.
6220
6221 2008-02-02 Robert Millan <rmh@aybabtu.com>
6222
6223 * normal/main.c (grub_normal_execute): Check for `menu->size' when
6224 determining whether menu has to be displayed.
6225
6226 2008-02-02 Marco Gerards <marco@gnu.org>
6227
6228 * bus/pci.c: New file.
6229
6230 * include/grub/pci.h: Likewise.
6231
6232 * include/grub/i386/pc/pci.h: Likewise.
6233
6234 * commands/lspci.c: Likewise.
6235
6236 * conf/i386-pc.rmk (pkglib_MODULES): Add `pci.mod' and
6237 `lspci.mod'.
6238 (pci_mod_SOURCES): New variable.
6239 (pci_mod_CFLAGS): Likewise.
6240 (pci_mod_LDFLAGS): Likewise.
6241 (lspci_mod_SOURCES): Likewise.
6242 (lspci_mod_CFLAGS): Likewise.
6243 (lspci_mod_LDFLAGS): Likewise.
6244
6245 2008-02-02 Bean <bean123ch@gmail.com>
6246
6247 * fs/ufs.c (INODE_BLKSZ): Fix incorrect value.
6248 (grub_ufs_get_file_block): Fix indirect block calculation problem.
6249
6250 * fs/xfs.c (grub_xfs_sblock): New member log2_dirblk.
6251 (grub_xfs_btree_node): New structure.
6252 (grub_xfs_btree_root): New structure.
6253 (grub_xfs_inode): New members nblocks, extsize, nextents and btree.
6254 (GRUB_XFS_EXTENT_OFFSET): Use exts instead of inode->data.extents.
6255 (GRUB_XFS_EXTENT_BLOCK): Likewise.
6256 (GRUB_XFS_EXTENT_SIZE): Likewise.
6257 (grub_xfs_read_block): Support btree format type.
6258 (grub_xfs_iterate_dir): Use NESTED_FUNC_ATTR in call_hook.
6259 Use directory block as basic unit.
6260
6261 * fs/fshelp.c (grub_fshelp_read_file): Bug fix for sparse block.
6262
6263 * aclocal.m4 (grub_i386_CHECK_REGPARM_BUG): Define NESTED_FUNC_ATTR as
6264 __attribute__ ((__regparm__ (1))).
6265
6266 2008-02-01 Robert Millan <rmh@aybabtu.com>
6267
6268 Correct a mistake in previous commit.
6269
6270 * conf/i386-pc.rmk (normal/execute.c_DEPENDENCIES): Move to the
6271 top.
6272 (normal/command.c_DEPENDENCIES): New variable.
6273
6274 2008-02-01 Robert Millan <rmh@aybabtu.com>
6275
6276 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Move to the
6277 top.
6278 (normal/command.c_DEPENDENCIES): New variable.
6279 (grub-emu_DEPENDENCIES, normal_mod_DEPENDENCIES): Remove variables.
6280 * conf/i386-ieee1275.rmk: Likewise.
6281 * conf/i386-linuxbios.rmk: Likewise.
6282 * conf/i386-pc.rmk: Likewise.
6283 * conf/sparc64-ieee1275.rmk: Likewise.
6284 * conf/powerpc-ieee1275.rmk: Likewise.
6285 (grub_emu_SOURCES): Add `fs/fshelp.c'.
6286
6287 * genmk.rb: Add `$(#{src}_DEPENDENCIES)' in targets that require it.
6288
6289 2008-02-01 Robert Millan <rmh@aybabtu.com>
6290
6291 * kern/disk.c (grub_disk_read, grub_disk_write): Add grub_dprintf()
6292 call at beginning of function.
6293
6294 2008-01-31 Pavel Roskin <proski@gnu.org>
6295
6296 * util/powerpc/ieee1275/grub-mkrescue.in: New file.
6297 * conf/powerpc-ieee1275.rmk (bin_SCRIPTS): New variable.
6298 (grub_mkrescue_SOURCES): Likewise.
6299 * DISTLIST: Add util/powerpc/ieee1275/grub-mkrescue.in.
6300
6301 2008-01-30 Robert Millan <rmh@aybabtu.com>
6302
6303 * conf/i386-pc.rmk (sbin_UTILITIES): Remove `grub-probe'.
6304 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Moved from here ...
6305 * conf/common.rmk (util/grub-probe.c_DEPENDENCIES)
6306 (grub_probe_SOURCES): ... to here.
6307
6308 * conf/i386-efi.rmk (sbin_UTILITIES): Remove `grub-probe'.
6309 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Remove.
6310 * conf/i386-ieee1275.rmk: Likewise.
6311 * conf/i386-linuxbios.rmk: Likewise.
6312 * conf/powerpc-ieee1275.rmk: Likewise.
6313
6314 2008-01-30 Tristan Gingold <gingold@free.fr>
6315
6316 * kern/rescue.c: Silently accept empty lines.
6317
6318 2008-01-29 Bean <bean123ch@gmail.com>
6319
6320 * boot/i386/pc/lnxboot.S (data_start): Code cleanup.
6321 (real_code_2): Code cleanup and change comment style.
6322 (move_memory): Avoid using 32-bit address mode.
6323
6324 2008-01-29 Bean <bean123ch@gmail.com>
6325
6326 * conf/i386-pc.rmk (pkglib_MODULES): Add `png.mod'.
6327 (png_mod_SOURCES): New variable.
6328 (png_mod_CFLAGS): Likewise.
6329 (png_mod_LDFLAGS): Likewise.
6330
6331 * video/readers/png.c: New file.
6332
6333 2008-01-28 Robert Millan <rmh@aybabtu.com>
6334
6335 * include/grub/i386/linuxbios/kernel.h (GRUB_MOD_GAP): New macro.
6336 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Remove
6337 `ifndef GRUB_MOD_GAP' hack.
6338 * util/elf/grub-mkimage.c (add_segments): Likewise.
6339
6340 2008-01-27 Robert Millan <rmh@aybabtu.com>
6341
6342 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Skip
6343 `GRUB_MOD_GAP' for platforms in which it's not defined.
6344 * util/elf/grub-mkimage.c (add_segments): Likewise.
6345
6346 2008-01-27 Robert Millan <rmh@aybabtu.com>
6347
6348 Get grub-emu to build again (including parallel builds).
6349
6350 * conf/i386-pc.rmk (util/grub-emu.c_DEPENDENCIES): Remove variable.
6351 Split into ...
6352 (util/grub-emu.c_DEPENDENCIES): ... this, ...
6353 (normal/execute.c_DEPENDENCIES): ... this, ...
6354 (grub-emu_DEPENDENCIES): ... and this.
6355
6356 * conf/i386-efi.rmk: Likewise.
6357 * conf/i386-linuxbios.rmk: Likewise.
6358 * conf/i386-ieee1275.rmk: Likewise.
6359 * conf/powerpc-ieee1275.rmk: Likewise.
6360 (grub_emu_SOURCES): Remove duplicated `kern/file.c'.
6361
6362 2008-01-27 Robert Millan <rmh@aybabtu.com>
6363
6364 * NEWS: Add a few items.
6365
6366 2008-01-27 Robert Millan <rmh@aybabtu.com>
6367
6368 Fix parallel builds with grub-emu. Based on earlier commit for
6369 grub-probe and grub-setup.
6370
6371 * conf/i386-pc.rmk (grub-emu_DEPENDENCIES): Renamed to ...
6372 (util/grub-emu.c_DEPENDENCIES): ... this.
6373 * conf/i386-efi.rmk (grub-emu_DEPENDENCIES): Renamed to ...
6374 (util/grub-emu.c_DEPENDENCIES): ... this.
6375 * conf/i386-linuxbios.rmk (grub-emu_DEPENDENCIES): Renamed to ...
6376 (util/grub-emu.c_DEPENDENCIES): ... this.
6377 * conf/i386-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
6378 (util/grub-emu.c_DEPENDENCIES): ... this.
6379 * conf/powerpc-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
6380 (util/grub-emu.c_DEPENDENCIES): ... this.
6381
6382 2008-01-27 Pavel Roskin <proski@gnu.org>
6383
6384 * include/grub/powerpc/ieee1275/kernel.h: Introduce GRUB_MOD_GAP
6385 to create a gap between _end and the modules added to the image
6386 with grub-mkrescue. That fixes "CLAIM failed" on PowerMAC.
6387 * kern/powerpc/ieee1275/init.c: Use GRUB_MOD_GAP.
6388 * util/elf/grub-mkimage.c (add_segments): Likewise.
6389
6390 2008-01-26 Pavel Roskin <proski@gnu.org>
6391
6392 * kern/dl.c (grub_dl_load): Don't abort if prefix is not set,
6393 just return an error.
6394
6395 2008-01-26 Bean <bean123ch@gmail.com>
6396
6397 * fs/reiserfs.c (grub_fshelp_node): New member next_offset.
6398 (grub_reiserfs_get_item): Save offset of the next item.
6399 (grub_reiserfs_iterate_dir): Use next_offset to find next item.
6400
6401 2008-01-25 Robert Millan <rmh@aybabtu.com>
6402
6403 * conf/i386-pc.rmk (grub_setup_SOURCES, grub_emu_SOURCES): Regroup to
6404 make all filesystem sources appear together (possibly fixing omissions
6405 while at it).
6406 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
6407 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6408 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
6409 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6410
6411 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise. Additionally,
6412 add `kern/file.c'.
6413 * conf/i386-efi.rmk (grub_probe_SOURCES): Likewise.
6414 * conf/i386-ieee1275.rmk (grub_probe_SOURCES): Likewise.
6415 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Likewise.
6416 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Likewise.
6417
6418 * util/grub-probe.c: Include `<grub/file.h>' and `<sys/stat.h>'.
6419 (probe): Add a sanity check to make sure of our ability to read
6420 requested files when probing for filesystem type.
6421
6422 * genmk.rb: Update copyright year (2007).
6423
6424 * include/grub/fs.h (grub_fat_init, grub_fat_fini, grub_ext2_init)
6425 (grub_ext2_fini, grub_ufs_init, grub_ufs_fini, grub_minix_init)
6426 (grub_minix_fini, grub_hfs_init, grub_hfs_fini, grub_jfs_init)
6427 (grub_jfs_fini, grub_xfs_init, grub_xfs_fini, grub_affs_init)
6428 (grub_affs_fini, grub_sfs_init, grub_sfs_fini, grub_iso9660_init)
6429 : Remove function prototypes.
6430
6431 2008-01-25 Robert Millan <rmh@aybabtu.com>
6432
6433 Revert my previous commits (based on wrong assumption of how grub_errno
6434 works).
6435
6436 * kern/disk.c (grub_disk_open): Stop resetting grub_errno.
6437 * kern/file.c (grub_file_open): Likewise.
6438
6439 2008-01-24 Pavel Roskin <proski@gnu.org>
6440
6441 * include/grub/ieee1275/ieee1275.h: Introduce flag for firmwares
6442 that hang if GRUB tries to setup colors.
6443 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Don't set
6444 colors for firmwares that don't support it.
6445 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag):
6446 Recognize Open Hack'Ware, set flags to work around its
6447 limitations.
6448
6449 2008-01-24 Robert Millan <rmh@aybabtu.com>
6450
6451 * kern/file.c (grub_file_open): Do not account previous failures of
6452 unrelated functions when grub_errno is checked for.
6453 Reported by Oleg Strikov.
6454
6455 2008-01-24 Bean <bean123ch@gmail.com>
6456
6457 * fs/ufs.c (GRUB_UFS_VOLNAME_LEN): New macro.
6458 (grub_ufs_sblock): New member volume name.
6459 (grub_ufs_find_file): Fix string copy bug.
6460 (grub_ufs_label): Implement this function properly.
6461
6462 * fs/hfs.c (grub_hfs_cnid_type): New enum.
6463 (grub_hfs_iterate_records): Use the correct file number for extents
6464 and catalog file. Fix problem in next index calculation.
6465 (grub_hfs_find_node): Replace recursive function call with loop.
6466 (grub_hfs_iterate_dir): Replace recursive function call with loop.
6467
6468 2008-01-23 Robert Millan <rmh@aybabtu.com>
6469
6470 * include/grub/i386/ieee1275/loader.h: Include `<grub/types.h>',
6471 `<grub/symbol.h>' and `<grub/multiboot.h>'.
6472 (grub_multiboot2_real_boot): New function prototype.
6473
6474 * include/grub/i386/pc/memory.h: Include `<grub/machine/machine.h>'.
6475 [!GRUB_MACHINE_IEEE1275] (grub_lower_mem, grub_upper_mem): Disable.
6476
6477 * kern/i386/ieee1275/init.c (grub_os_area_addr)
6478 (grub_os_area_size, grub_lower_mem, grub_upper_mem): Remove variables.
6479
6480 2008-01-23 Robert Millan <rmh@aybabtu.com>
6481
6482 * kern/mm.c (grub_mm_init_region): Replace grub_dprintf() call with
6483 #ifdef'ed out grub_printf().
6484
6485 2008-01-23 Robert Millan <rmh@aybabtu.com>
6486
6487 * term/i386/pc/at_keyboard.c (grub_keyboard_isr): #ifdef out
6488 grub_dprintf calls, since they make "debug=all" mode unusable.
6489 (grub_console_checkkey): Likewise.
6490
6491 2008-01-23 Robert Millan <rmh@aybabtu.com>
6492
6493 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
6494 `term/i386/pc/at_keyboard.c'.
6495 (pkglib_MODULES): Add `serial.mod'.
6496 (serial_mod_SOURCES): New variable.
6497 (serial_mod_CFLAGS): Likewise.
6498 (serial_mod_LDFLAGS): Likewise.
6499
6500 * include/grub/i386/ieee1275/console.h: Add `<grub/symbol.h>'. Remove
6501 `<grub/powerpc/ieee1275/console.h>'.
6502 (grub_keyboard_controller_init): New function prototype.
6503 (grub_console_checkkey): Likewise.
6504 (grub_console_getkey): Likewise.
6505
6506 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize AT
6507 keyboard on i386.
6508
6509 * term/ieee1275/ofconsole.c (grub_ofconsole_term): On i386, use
6510 grub_ofconsole_checkkey() and grub_ofconsole_getkey() for input.
6511
6512 2008-01-23 Robert Millan <rmh@aybabtu.com>
6513
6514 * kern/i386/pc/init.c (make_install_device): When memdisk image is
6515 present, "(memdisk)/boot/grub" becomes the default prefix.
6516
6517 * util/i386/pc/grub-mkrescue.in: Switch to a minimal core.img plus
6518 a memdisk tarball with all the modules. Add --overlay=DIR option that
6519 allows users to overlay additional files into the image.
6520
6521 2008-01-23 Robert Millan <rmh@aybabtu.com>
6522
6523 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add `machine/loader.h'
6524 and `machine/memory.h'.
6525 (pkglib_MODULES): Add `multiboot.mod' and `_multiboot.mod'.
6526 (_multiboot_mod_SOURCES): New variable.
6527 (_multiboot_mod_CFLAGS): Likewise.
6528 (_multiboot_mod_LDFLAGS): Likewise.
6529 (multiboot_mod_SOURCES): Likewise.
6530 (multiboot_mod_CFLAGS): Likewise.
6531 (multiboot_mod_LDFLAGS): Likewise.
6532
6533 * include/grub/i386/ieee1275/loader.h: New file.
6534
6535 * include/grub/i386/ieee1275/machine.h: Likewise.
6536
6537 * include/grub/i386/ieee1275/memory.h: Likewise.
6538
6539 * include/grub/i386/pc/init.h (grub_os_area_addr): Remove (redundant)
6540 variable declaration.
6541 (grub_os_area_size): Likewise.
6542
6543 * kern/i386/ieee1275/init.c (grub_os_area_addr, grub_os_area_size)
6544 (grub_lower_mem, grub_upper_mem): New variables.
6545 (grub_stop_floppy): New function (just to make
6546 grub_multiboot2_real_boot() happy).
6547
6548 * kern/i386/ieee1275/startup.S: Include `<grub/machine/memory.h>',
6549 `<grub/cpu/linux.h>', `<multiboot.h>' and `<multiboot2.h>'.
6550 (grub_stop): New function.
6551 Include `"../realmode.S"' and `"../loader.S"'.
6552
6553 * loader/multiboot_loader.c: Include `<grub/machine/machine.h>'.
6554 Replace `__i386__' #ifdefs with `GRUB_MACHINE_PCBIOS'.
6555
6556 * loader/powerpc/ieee1275/multiboot2.c (grub_mb2_arch_boot): On i386,
6557 rely on grub_multiboot2_real_boot() for final boot.
6558
6559 2008-01-22 Robert Millan <rmh@aybabtu.com>
6560
6561 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): When
6562 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag is set, skip any
6563 device that doesn't look like an SD card.
6564 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
6565 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag.
6566 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag): Detect
6567 OLPC laptop, and set `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' when
6568 found.
6569
6570 2008-01-22 Robert Millan <rmh@aybabtu.com>
6571
6572 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Add sanity check to
6573 avoid claiming over our own code.
6574
6575 2008-01-22 Bean <bean123ch@gmail.com>
6576
6577 * conf/i386-pc.rmk (pkglib_MODULES): Add `jpeg.mod'.
6578 (jpeg_mod_SOURCES): New variable.
6579 (jpeg_mod_CFLAGS): Likewise.
6580 (jpeg_mod_LDFLAGS): Likewise.
6581
6582 * video/readers/jpeg.c : New file.
6583
6584 2008-01-22 Bean <bean123ch@gmail.com>
6585
6586 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_FILE_NOT_FOUND when
6587 there are no more items.
6588
6589 2008-01-21 Robert Millan <rmh@aybabtu.com>
6590
6591 * kern/mm.c (grub_mm_init_region): Improve debug message.
6592
6593 2008-01-21 Robert Millan <rmh@aybabtu.com>
6594
6595 * conf/i386-pc.rmk (GRUB_MEMORY_MACHINE_LINK_ADDR): New variable.
6596 (kernel_img_LDFLAGS): Use `GRUB_MEMORY_MACHINE_LINK_ADDR' as link
6597 address.
6598 (grub_mkimage_CFLAGS): Propagate `GRUB_MEMORY_MACHINE_LINK_ADDR' as
6599 a C macro.
6600 * include/grub/i386/pc/memory.h (GRUB_MEMORY_MACHINE_UPPER): New macro.
6601 Indicates start of upper memory.
6602 * util/i386/pc/grub-mkimage.c: Include `<grub/machine/memory.h>'.
6603 (generate_image): Abort when image size is big enough to corrupt
6604 upper memory.
6605
6606 * include/grub/i386/pc/vga.h: Include `<grub/machine/memory.h>'.
6607 (GRUB_MEMORY_MACHINE_VGA_ADDR): Alias for `GRUB_MEMORY_MACHINE_UPPER'.
6608 * term/i386/pc/vga.c (VGA_MEM): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
6609 instead of hardcoding 0xA0000.
6610 * video/i386/pc/vbe.c: Include `<grub/machine/vga.h>'.
6611 (grub_vbe_set_video_mode): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
6612 instead of hardcoding 0xA0000.
6613
6614 2008-01-21 Robert Millan <rmh@aybabtu.com>
6615
6616 * disk/memdisk.c (memdisk_size): New variable.
6617 (grub_memdisk_open): Replace grub_arch_memdisk_size() call with
6618 `memdisk_size'.
6619 (grub_memdisk_init): Initialize `memdisk_size'. Reallocate memdisk
6620 image to dynamic memory.
6621 (grub_memdisk_fini): Replace grub_arch_memdisk_size() call with
6622 `memdisk_size'. Free memdisk block.
6623
6624 2008-01-21 Robert Millan <rmh@aybabtu.com>
6625
6626 Fix detection of very small filesystems (like tar).
6627
6628 * fs/reiserfs.c (grub_reiserfs_mount): When disk is too small to
6629 contain a ReiserFS, abort with GRUB_ERR_BAD_FS rather than
6630 GRUB_ERR_OUT_OF_RANGE (which made the upper layer think there's
6631 a problem with this disk).
6632
6633 2008-01-21 Robert Millan <rmh@aybabtu.com>
6634
6635 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Add debug message
6636 on grub_biosdisk_rw_standard() error.
6637
6638 2008-01-21 Robert Millan <rmh@aybabtu.com>
6639
6640 * include/grub/ieee1275/ieee1275.h: Add 2008 to Copyright line for
6641 recent changes.
6642 * kern/elf.c: Likewise.
6643 * kern/ieee1275/ieee1275.c: Likewise.
6644 * kern/powerpc/ieee1275/openfw.c: Likewise.
6645 * term/ieee1275/ofconsole.c: Likewise.
6646
6647 2008-01-21 Robert Millan <rmh@aybabtu.com>
6648
6649 * include/grub/i386/pc/kernel.h: Include `<grub/symbol.h>'.
6650
6651 * include/grub/kernel.h (grub_arch_memdisk_addr)
6652 (grub_arch_memdisk_size): Moved from here ...
6653
6654 * include/grub/i386/pc/kernel.h (grub_arch_memdisk_addr)
6655 (grub_arch_memdisk_size): ... to here.
6656
6657 2008-01-21 Robert Millan <rmh@aybabtu.com>
6658
6659 Mostly based on bugfix from Bean.
6660
6661 * kern/elf.c (grub_elf32_phdr_iterate): Use `NESTED_FUNC_ATTR'
6662 attribute with hook() parameter.
6663 (grub_elf32_load): Use `NESTED_FUNC_ATTR' with grub_elf32_load_segment()
6664 declaration.
6665 (grub_elf64_phdr_iterate): Use `NESTED_FUNC_ATTR'
6666 attribute with hook() parameter.
6667 (grub_elf64_load): Use `NESTED_FUNC_ATTR' with grub_elf64_load_segment()
6668 declaration.
6669
6670 2008-01-21 Robert Millan <rmh@aybabtu.com>
6671
6672 * conf/i386-pc.rmk (kernel_img_HEADERS): Add `machine/kernel.h'.
6673 (pkglib_MODULES): Add `memdisk.mod'.
6674 (memdisk_mod_SOURCES): New variable.
6675 (memdisk_mod_CFLAGS): Likewise.
6676 (memdisk_mod_LDFLAGS): Likewise.
6677
6678 * disk/memdisk.c: New file.
6679
6680 * include/grub/disk.h (grub_disk_dev_id): Add
6681 `GRUB_DISK_DEVICE_MEMDISK_ID'.
6682
6683 * include/grub/i386/pc/kernel.h
6684 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): New macro.
6685 (GRUB_KERNEL_MACHINE_PREFIX): Increment by 4.
6686 (grub_kernel_image_size): New variable declaration.
6687 (grub_total_module_size): Likewise.
6688 (grub_memdisk_image_size): Likewise.
6689
6690 * include/grub/i386/pc/memory.h
6691 (GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR): New macro.
6692
6693 * include/grub/kernel.h: Include `<grub/symbol.h>'.
6694 (grub_arch_memdisk_addr): New variable declaration.
6695 (grub_arch_memdisk_size): Likewise.
6696
6697 * kern/i386/pc/init.c (grub_arch_memdisk_addr): New function.
6698 (grub_arch_memdisk_size): Likewise.
6699
6700 * kern/i386/pc/startup.S (grub_memdisk_image_size): New variable.
6701 (codestart): Replace hardcoded `0x100000' with
6702 `GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR' macro.
6703
6704 * util/i386/pc/grub-mkimage.c: Include `<grub/misc.h>'.
6705 (generate_image): Add `memdisk_path' parameter. When `memdisk_path' is
6706 not NULL, append the contents of the file it refers to, at the end of
6707 the compressed kernel image. Initialize `grub_memdisk_image_size'
6708 variable (at `GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE' offset).
6709 (options): Add "memdisk"|'m' option.
6710 (main): Parse --memdisk|-m option, and pass user-provided path as
6711 parameter to generate_image().
6712
6713 2008-01-20 Robert Millan <rmh@aybabtu.com>
6714
6715 * kern/sparc64/ieee1275/openfw.c (grub_devalias_iterate): Copy debug
6716 grub_dprintf() calls from here ...
6717 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): ... to here.
6718
6719 2008-01-20 Robert Millan <rmh@aybabtu.com>
6720
6721 Fix detection of "real mode" when /options/real-mode? doesn't exist.
6722
6723 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_mmu): New variable
6724 declaration.
6725 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_mmu): New variable.
6726 (grub_ieee1275_find_options): If `grub_ieee1275_mmu' is 0, set
6727 `GRUB_IEEE1275_FLAG_REAL_MODE'.
6728 (cmain): Initialize `grub_ieee1275_mmu' (using /chosen/mmu integer
6729 property).
6730 * kern/powerpc/ieee1275/openfw.c (grub_map): Rely on pre-initialized
6731 `grub_ieee1275_mmu' rather than obtaining a handler on every call.
6732
6733 2008-01-19 Robert Millan <rmh@aybabtu.com>
6734
6735 Get rid of confusing function (superseded by
6736 `grub_ieee1275_get_integer_property')
6737 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_decode_int_4): Remove
6738 prototype.
6739 * kern/ieee1275/ieee1275.c (grub_ieee1275_decode_int_4): Remove
6740 function.
6741 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid use of
6742 grub_ieee1275_decode_int_4(), by obtaining integer properties directly
6743 in native endianness from grub_ieee1275_get_integer_property().
6744
6745 2008-01-19 Robert Millan <rmh@aybabtu.com>
6746
6747 * kern/powerpc/ieee1275/openfw.c (grub_halt): Issue "power-off"
6748 command after "shut-down", since implementations differ on which
6749 the command for halt is.
6750
6751 2008-01-19 Robert Millan <rmh@aybabtu.com>
6752
6753 * include/grub/i386/linuxbios/console.h: Add header protection.
6754 (grub_keyboard_controller_init): New function prototype.
6755 * term/i386/pc/at_keyboard.c (KEYBOARD_COMMAND_ISREADY): New macro.
6756 (KEYBOARD_COMMAND_READ): Likewise.
6757 (KEYBOARD_COMMAND_WRITE): Likewise.
6758 (KEYBOARD_SCANCODE_SET1): Likewise.
6759 (grub_keyboard_controller_write): New function.
6760 (grub_keyboard_controller_read): Likewise.
6761 (grub_keyboard_controller_init): Likewise.
6762
6763 * term/i386/pc/console.c: Include `<grub/machine/machine.h>'.
6764 (grub_console_init): On coreboot/LinuxBIOS, call
6765 grub_keyboard_controller_init().
6766
6767 2008-01-19 Robert Millan <rmh@aybabtu.com>
6768
6769 PowerPC changes provided by Pavel Roskin.
6770
6771 * kern/powerpc/ieee1275/cmain.c (cmain): Don't take any arguments.
6772 * kern/powerpc/ieee1275/crt0.S: Store r5 in grub_ieee1275_entry_fn,
6773 don't rely on cmain() doing it.
6774 * kern/i386/ieee1275/startup.S (_start): Store %eax in
6775 grub_ieee1275_entry_fn, don't rely on cmain() doing it.
6776
6777 2008-01-16 Robert Millan <rmh@aybabtu.com>
6778
6779 * include/grub/i386/linuxbios/memory.h
6780 (GRUB_MEMORY_MACHINE_LINUXBIOS_TABLE_ADDR): Remove macro.
6781 * kern/i386/linuxbios/table.c (grub_linuxbios_table_iterate): Do not
6782 receive `table_header' as argument. Instead, probe for it in the
6783 known memory ranges where it can be present.
6784 (grub_available_iterate): Do not pass a fixed `table_header' address
6785 to grub_linuxbios_table_iterate().
6786
6787 2008-01-15 Robert Millan <rmh@aybabtu.com>
6788
6789 * configure.ac: Add `i386-ieee1275' to the list of supported targets.
6790 * conf/i386-ieee1275.rmk: New file.
6791 * include/grub/i386/ieee1275/console.h: Likewise.
6792 * include/grub/i386/ieee1275/ieee1275.h: Likewise.
6793 * include/grub/i386/ieee1275/kernel.h: Likewise.
6794 * include/grub/i386/ieee1275/time.h: Likewise.
6795 * kern/i386/ieee1275/init.c: Likewise.
6796 * kern/i386/ieee1275/startup.S: Likewise.
6797
6798 2008-01-15 Robert Millan <rmh@aybabtu.com>
6799
6800 * kern/misc.c (grub_vsprintf): Do not reset `longlongfmt' to zero
6801 when pointers are 32-bit (but still do set it to one when they are
6802 64-bit).
6803
6804 2008-01-15 Robert Millan <rmh@aybabtu.com>
6805
6806 * include/grub/ieee1275/ieee1275.h
6807 (grub_ieee1275_get_integer_property): New function prototype.
6808
6809 * kern/ieee1275/ieee1275.c: Include `<grub/types.h>'.
6810 (grub_ieee1275_get_integer_property): New function. Wraps around
6811 grub_ieee1275_get_property() to handle endianness.
6812
6813 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Replace
6814 grub_ieee1275_get_property() with grub_ieee1275_get_integer_property()
6815 where appropriate.
6816 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Likewise.
6817 (grub_map): Likewise.
6818 * kern/sparc64/ieee1275/openfw.c (grub_map): Likewise.
6819
6820 2008-01-15 Bean <bean123ch@gmail.com>
6821
6822 * normal/execute.c (grub_script_exec_argument_to_string): Check for undefined variable.
6823 (grub_script_execute_cmdline): Reset grub_errno.
6824
6825 * normal/main.c (read_config_file): Reset grub_errno.
6826
6827 * normal/parse.y (script_init): New.
6828 (script): Move function and menuentry here.
6829 (delimiter): New.
6830 (command): Add delimiter at the end of command.
6831 (commands): Adjust to match the new command.
6832 (commandblock): Remove grub_script_lexer_record_start.
6833 (menuentry): Add grub_script_lexer_record_start, use the new commands.
6834 (if): Use the new commands.
6835
6836 * conf/common.rmk (pkgdata_MODULES): Add echo.mod.
6837
6838 2008-01-15 Robert Millan <rmh@aybabtu.com>
6839
6840 * normal/menu.c (run_menu): Move timeout message from here ...
6841 (print_timeout): ... to here.
6842 (run_menu): Use print_timeout() once during initial draw to print
6843 the whole message, and again in every clock tick to update only
6844 the number of seconds.
6845
6846 2008-01-15 Robert Millan <rmh@aybabtu.com>
6847
6848 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Obtain
6849 actual size of `available' from grub_ieee1275_get_property(), and
6850 restrict parsing to that bound.
6851
6852 2008-01-15 Christian Franke <franke@computer.org>
6853
6854 * util/grub-emu.c: Replace <argp.h> by <getopt.h>.
6855 (argp_program_version): Remove variable.
6856 (argp_program_bug_address): Likewise.
6857 (options): Convert from struct argp_option to struct option.
6858 (struct arguments): Remove.
6859 (parse_opt): Remove.
6860 (usage): New function.
6861 (main): Replace struct args members by simple variables.
6862 Replace argp_parse() by getopt_long().
6863 Add switch to evaluate options.
6864 Add missing "(...)" around root_dev in prefix string.
6865
6866 2008-01-14 Robert Millan <rmh@aybabtu.com>
6867
6868 * kern/powerpc/ieee1275/init.c (grub_exit): Reimplement as a wrapper
6869 for grub_ieee1275_exit(), in order to improve portability.
6870
6871 2008-01-14 Robert Millan <rmh@aybabtu.com>
6872
6873 * util/grub.d/10_linux.in (prefix): Define.
6874 (exec_prefix): Likewise. Both definitions are later used by `libdir'.
6875
6876 2008-01-13 Pavel Roskin <proski@gnu.org>
6877
6878 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Don't use
6879 grub_errno if no errors have been detected.
6880
6881 2008-01-12 Robert Millan <rmh@aybabtu.com>
6882
6883 * include/grub/util/getroot.h (grub_dev_abstraction_types): New enum.
6884 (grub_util_get_dev_abstraction): New function prototype.
6885
6886 * util/getroot.c: Include `<grub/util/getroot.h>'
6887 (grub_util_get_grub_dev): Move detection of abstraction type to ...
6888 (grub_util_get_dev_abstraction): ... here (new function).
6889
6890 * util/grub-probe.c: Convert PRINT_* to an enum. Add
6891 `PRINT_ABSTRACTION'.
6892 (probe): Probe for abstraction type when requested.
6893 (main): Understand `--target=abstraction'.
6894
6895 * util/i386/efi/grub-install.in: Add abstraction module to core
6896 image when it is found to be necessary.
6897 * util/i386/pc/grub-install.in: Likewise.
6898 * util/powerpc/ieee1275/grub-install.in: Likewise.
6899
6900 * util/update-grub_lib.in (font_path): Return system path without
6901 converting to GRUB path.
6902 * util/update-grub.in: Convert system path returned by font_path()
6903 to a GRUB path. Use `grub-probe -t abstraction' to determine what
6904 abstraction module is needed for loading fonts (if any). Export
6905 that as `GRUB_PRELOAD_MODULES'.
6906 * util/grub.d/00_header.in: Process `GRUB_PRELOAD_MODULES' (print
6907 insmod commands).
6908
6909 2008-01-12 Yoshinori K. Okuji <okuji@enbug.org>
6910
6911 Remove some unused code from reiserfs.
6912
6913 * fs/reiserfs.c (struct grub_reiserfs_key)
6914 [GRUB_REISERFS_KEYV2_BITFIELD]: Removed offset and type.
6915 (struct grub_reiserfs_node_body): Removed.
6916 (grub_reiserfs_get_key_v2_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
6917 Likewise.
6918 (grub_reiserfs_get_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
6919 Likewise.
6920 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
6921 Likewise.
6922 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
6923 Likewise.
6924 (grub_reiserfs_set_key_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
6925 Likewise.
6926 (grub_reiserfs_iterate_dir) [GRUB_REISERFS_KEYV2_BITFIELD]:
6927 Likewise.
6928 (grub_reiserfs_open) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
6929 (grub_reiserfs_read) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
6930 (grub_reiserfs_dir) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
6931
6932 2008-01-10 Robert Millan <rmh@aybabtu.com>
6933
6934 * util/update-grub_lib.in (grub_file_is_not_garbage): New function.
6935 Determines if a file is garbage left by packaging systems, etc.
6936 * util/update-grub.in: Use grub_file_is_not_garbage() as a condition
6937 for processing /etc/grub.d scripts.
6938 * util/grub.d/10_hurd.in: Fix `GRUB_DISTRIBUTOR' comparison.
6939 * util/grub.d/10_linux.in: Likewise. Use grub_file_is_not_garbage()
6940 as a condition for processing Linux images.
6941
6942 2008-01-10 Pavel Roskin <proski@gnu.org>
6943
6944 * include/grub/powerpc/libgcc.h (__ucmpdi2): New export. Needed
6945 to compile reiserfs.c on PowerPC.
6946
6947 2008-01-10 Robert Millan <rmh@aybabtu.com>
6948
6949 * kern/device.c (grub_device_iterate): Do not abort device iteration
6950 when one of the devices cannot be opened.
6951 * kern/disk.c (grub_disk_open): Do not account previous failures of
6952 unrelated functions when grub_errno is checked for.
6953
6954 2008-01-08 Robert Millan <rmh@aybabtu.com>
6955
6956 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): For
6957 `! grub_linux_is_bzimage', change order of address comparison to make
6958 it more intuitive, and improve "too big zImage" error message.
6959
6960 2008-01-08 Robert Millan <rmh@aybabtu.com>
6961
6962 * Makefile.in (uninstall): Handle `$(update-grub_SCRIPTS)' and
6963 `$(update-grub_DATA)'.
6964 (distcheck): Fix race condition when invoking `$(MAKE)' on multiple
6965 targets.
6966
6967 2008-01-07 Robert Millan <rmh@aybabtu.com>
6968
6969 * boot/i386/pc/boot.S (boot_drive_check): Add a comment indicating
6970 which instruction is modified by grub-setup during installation
6971 (since it wasn't obvious by only looking at this file).
6972
6973 2008-01-07 Robert Millan <rmh@aybabtu.com>
6974
6975 * TODO: Rewrite. Just refer to the wiki and the BTS instead of
6976 listing actual TODO items.
6977
6978 2008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
6979
6980 * fs/reiserfs.c (grub_reiserfs_get_key_v2_type): Handle endianness
6981 correctly.
6982 (grub_reiserfs_get_key_offset): Likewise.
6983 (grub_reiserfs_set_key_offset): Likewise.
6984 (grub_reiserfs_set_key_type): Likewise.
6985 (grub_reiserfs_iterate_dir): Return 1 if found, otherwise 0.
6986
6987 (GRUB_REISERFS_KEYV2_BITFIELD): Undefined. Probably it would be
6988 better to remove the bitfield version completely.
6989
6990 2008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
6991
6992 * fs/reiserfs.c (grub_reiserfs_iterate_dir): ENTRY_ITEM must be
6993 allocated from the heap, due to the fshelp implementation.
6994 (grub_reiserfs_dir): Free NODE, due to the same reason.
6995
6996 2008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
6997
6998 Mostly from Vincent Pelletier:
6999
7000 * fs/reiserfs.c: New file.
7001
7002 * conf/common.rmk (pkglib_MODULES): Added reiserfs.mod.
7003 (reiserfs_mod_SOURCES): New variable.
7004 (reiserfs_mod_CFLAGS): Likewise.
7005 (reiserfs_mod_LDFLAGS): Likewise.
7006
7007 * DISTLIST: Added boot/i386/pc/lnxboot.S, commands/hexdump.c,
7008 disk/ata.c, fs/cpio.c, fs/ntfscomp.c, fs/reiserfs.c,
7009 include/grub/ntfs.h, include/grub/i386/pc/machine.h, and
7010 normal/color.c.
7011
7012 2008-01-06 Robert Millan <rmh@aybabtu.com>
7013
7014 * normal/color.c: Remove `<grub/env.h>'.
7015
7016 2008-01-05 Jeroen Dekkers <jeroen@dekkers.cx>
7017
7018 * include/grub/normal.h: Include <grub/env.h>.
7019
7020 2008-01-05 Robert Millan <rmh@aybabtu.com>
7021
7022 * util/i386/pc/grub-setup.c (usage): Replace obsolete `(hd0,0)' in
7023 usage example with `(hd0,1)'.
7024 Reported by Samuel Thibault.
7025
7026 2008-01-05 Robert Millan <rmh@aybabtu.com>
7027
7028 * kern/i386/loader.S (grub_linux_is_bzimage): New variable.
7029 (grub_linux_boot_zimage): Rename to ...
7030 (grub_linux_boot): ... this.
7031 (grub_linux_boot_bzimage): Merge with `grub_linux_boot_zimage'.
7032 (grub_linux_boot_zimage): Conditionalize zImage copy.
7033
7034 * include/grub/i386/loader.h (grub_linux_is_bzimage): Add prototype.
7035 (grub_linux_boot_bzimage): Remove prototype.
7036 (grub_linux_boot_zimage): Rename to ...
7037 (grub_linux_boot): ... this.
7038
7039 * loader/i386/pc/linux.c (big_linux): Replace with `grub_linux_is_bzimage'.
7040 (grub_linux_boot): Remove function.
7041
7042 2008-01-05 Robert Millan <rmh@aybabtu.com>
7043
7044 * include/grub/normal.h (grub_env_write_color_normal): New prototype.
7045 (grub_env_write_color_highlight): Likewise.
7046 (grub_wait_after_message): Likewise.
7047
7048 * normal/color.c: New file.
7049
7050 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/color.c'.
7051 (normal_mod_DEPENDENCIES): Likewise.
7052
7053 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `normal/color.c'.
7054 (normal_mod_DEPENDENCIES): Likewise.
7055
7056 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add `normal/color.c'.
7057 (normal_mod_DEPENDENCIES): Likewise.
7058
7059 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `normal/color.c'.
7060 (normal_mod_DEPENDENCIES): Likewise.
7061
7062 * normal/menu_entry.c (run): Rely on grub_wait_after_message()
7063 for waiting after a message is printed.
7064 * normal/main.c (read_config_file): Likewise.
7065 (grub_normal_init): Register grub_env_write_color_normal() and
7066 grub_env_write_color_highlight() hooks. Mark `color_normal' and
7067 `color_highlight' variables as global.
7068
7069 * normal/menu.c (grub_wait_after_message): New function.
7070 (grub_color_menu_normal): New variable. Replaces ...
7071 (GRUB_COLOR_MENU_NORMAL): ... this macro.
7072 (grub_color_menu_highlight): New variable. Replaces ...
7073 (GRUB_COLOR_MENU_HIGHLIGHT): ... this macro.
7074 (draw_border): Set color state to `GRUB_TERM_COLOR_NORMAL' instead of
7075 `GRUB_TERM_COLOR_STANDARD'.
7076 (print_message): Use `grub_setcolorstate' to reload colors. Rename
7077 `normal_code' and `highlight_code' to `old_color_normal' and
7078 `old_color_highlight', respectively.
7079 (grub_menu_init_page): Update colors when drawing the menu, based on
7080 `menu_color_normal' and `menu_color_highlight' variables.
7081 (grub_menu_run): Rely on grub_wait_after_message() for waiting after
7082 a message is printed.
7083
7084 2008-01-05 Robert Millan <rmh@aybabtu.com>
7085
7086 * kern/env.c (grub_env_context_open): Propagate hooks for global
7087 variables to new context.
7088
7089 * kern/main.c (grub_set_root_dev): Export `root' variable.
7090
7091 2008-01-05 Robert Millan <rmh@aybabtu.com>
7092
7093 * util/biosdisk.c (get_os_disk): Check for devfs-style IDE and SCSI
7094 discs unconditionally, since udev and others have options to provide
7095 them.
7096
7097 2008-01-05 Robert Millan <rmh@aybabtu.com>
7098
7099 * normal/completion.c (iterate_dir): Skip `.' and `..' directories.
7100
7101 2008-01-04 Christian Franke <franke@computer.org>
7102
7103 * kern/i386/pc/init.c (grub_machine_init): Fix evaluation
7104 of eisa_mmap.
7105
7106 2008-01-03 Pavel Roskin <proski@gnu.org>
7107
7108 * kern/i386/linuxbios/init.c: Put "void" to all function
7109 declarations with no arguments.
7110 * kern/powerpc/ieee1275/init.c: Likewise.
7111 * term/i386/pc/at_keyboard.c: Likewise.
7112 * term/i386/pc/vga_text.c: Likewise.
7113 * util/grub-mkdevicemap.c: Likewise.
7114
7115 2008-01-02 Robert Millan <rmh@aybabtu.com>
7116
7117 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Improve error
7118 message when loaded image is out of bounds.
7119 (grub_multiboot_load_elf64): Likewise.
7120
7121 2008-01-02 Pavel Roskin <proski@gnu.org>
7122
7123 * util/grub.d/10_linux.in: Try version without ".old" when
7124 looking for initrd. It's better to use initrd from the newer
7125 kernel of the same version than no initrd at all.
7126
7127 2008-01-01 Robert Millan <rmh@aybabtu.com>
7128
7129 * util/biosdisk.c (get_os_disk): Fix check for IDE or SCSI discs.
7130
7131 2008-01-01 Vesa Jaaskelainen <chaac@nic.fi>
7132
7133 * include/grub/video.h: Added grub_video_unmap_color and
7134 grub_video_get_active_render_target.
7135 (grub_video_adapter): Added unmap_color and get_active_render_target.
7136
7137 * video/video.c: Added grub_video_unmap_color and
7138 grub_video_get_active_render_target.
7139 (grub_video_get_info): Changed method to accept NULL pointer as an
7140 argument to allow detection of active video adapter.
7141
7142 * video/i386/pc/vbe.c: Renamed grub_video_vbe_unmap_color as
7143 grub_video_vbe_unmap_color_int.
7144 Added grub_video_vbe_unmap_color and
7145 grub_video_vbe_get_active_render_target.
7146 (grub_video_vbe_adapter): Added unmap_color and
7147 get_active_render_target.
7148
7149 * video/i386/pc/vbeblit.c: Replaced grub_video_vbe_unmap_color usage
7150 with grub_video_vbe_unmap_color_int.
7151
7152 * term/gfxterm.c (DEFAULT_STANDARD_COLOR): Added.
7153 (DEFAULT_NORMAL_COLOR): Likewise.
7154 (DEFAULT_HIGHLIGHT_COLOR) Likewise.
7155 (DEFAULT_FG_COLOR): Removed.
7156 (DEFAULT_BG_COLOR): Likewise.
7157 (DEFAULT_CURSOR_COLOR): Changed value.
7158 (grub_virtual_screen): Added standard_color_setting,
7159 normal_color_setting, highlight_color_setting and term_color.
7160 (grub_virtual_screen): Removed fg_color_setting and bg_color_setting.
7161 (bitmap_width): Added.
7162 (bitmap_height): Likewise.
7163 (bitmap): Likewise.
7164 (set_term_color): Likewise.
7165 (grub_virtual_screen_setup): Changed to use new terminal coloring
7166 settings.
7167 (grub_gfxterm_init): Added init for bitmap.
7168 (grub_gfxterm_fini): Added destroy for bitmap.
7169 (redraw_screen_rect): Updated to use background bitmap and new
7170 terminal coloring.
7171 (scroll_up): Added optimization for case when there is no bitmap.
7172 (grub_gfxterm_cls): Fixed to use correct background color.
7173 (grub_virtual_screen_setcolorstate): Changed to use new terminal
7174 coloring.
7175 (grub_virtual_screen_setcolor): Likewise.
7176 (grub_virtual_screen_getcolor): Added.
7177 (grub_gfxterm_background_image_cmd): Likewise.
7178 (grub_video_term): Added setcolor and getcolor.
7179 (MOD_INIT): Added registration of background_image command.
7180 (MOD_TERM): Added unregistration for background_image command.
7181
7182 2007-12-30 Pavel Roskin <proski@gnu.org>
7183
7184 * loader/multiboot_loader.c: Fix multiboot command
7185 unregistration. Fix all typos in the word "multiboot".
7186
7187 2007-12-29 Pavel Roskin <proski@gnu.org>
7188
7189 * util/grub.d/10_linux.in: Refactor search for initrd. Add
7190 support for initrd names used in Fedora.
7191
7192 2007-12-26 Bean <bean123ch@gmail.com>
7193
7194 * conf/common.rmk (pkgdata_MODULES): Add cpio.mod.
7195 (cpio_mod_SOURCES): New variable.
7196 (cpio_mod_CFLAGS): Likewise.
7197 (cpio_mod_LDFLAGS): Likewise.
7198
7199 * fs/cpio.c: New file.
7200
7201 * conf/i386-pc.rmk (grub_emu_SOURCES): Add cpio.c.
7202
7203 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
7204
7205 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
7206
7207 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7208
7209 2007-12-25 Robert Millan <rmh@aybabtu.com>
7210
7211 * include/grub/term.h (struct grub_term): Add `getcolor' function.
7212 (grub_getcolor): New function.
7213
7214 * kern/term.c (grub_getcolor): New function.
7215 * normal/menu.c (GRUB_COLOR_MENU_NORMAL): New macro.
7216 (GRUB_COLOR_MENU_HIGHLIGHT): New macro.
7217 (print_entry): Set normal and highlight colors to
7218 `GRUB_COLOR_MENU_NORMAL' and `GRUB_COLOR_MENU_HIGHLIGHT',
7219 respectively, before printing and restore them to old
7220 values afterwards.
7221 (grub_menu_init_page): Likewise. Fill an additional colored space
7222 that would otherwise be left blank.
7223
7224 * term/efi/console.c (grub_console_getcolor): New function.
7225 (struct grub_console_term.getcolor): New variable.
7226 * term/i386/pc/console.c (grub_console_getcolor): New function.
7227 (struct grub_console_term.getcolor): New variable.
7228 * term/ieee1275/ofconsole.c (grub_ofconsole_getcolor): New function.
7229 (struct grub_console_term.getcolor): New variable.
7230
7231 * term/i386/pc/serial.c (grub_serial_setcolor): Remove function.
7232 (struct grub_console_term.setcolor): Remove variable.
7233 * term/i386/pc/vesafb.c (grub_virtual_screen_setcolor): Remove function.
7234 (struct grub_console_term.setcolor): Remove variable.
7235 * term/i386/pc/vga.c (grub_vga_setcolor): Remove function.
7236 (struct grub_console_term.setcolor): Remove variable.
7237 * term/gfxterm.c (grub_virtual_screen_setcolor): Remove function.
7238 (struct grub_console_term.setcolor): Remove variable.
7239
7240 2007-12-25 Robert Millan <rmh@aybabtu.com>
7241
7242 * configure.ac: Search for possible unifont.hex locations, and
7243 define UNIFONT_HEX if found.
7244
7245 * Makefile.in (UNIFONT_HEX): Define variable.
7246 (DATA): Rename to ...
7247 (PKGLIB): ... this. Update all users.
7248 (PKGDATA): New variable.
7249 (pkgdata_IMAGES): Rename to ...
7250 (pkglib_IMAGES): ... this. Update all users.
7251 (pkgdata_MODULES): Rename to ...
7252 (pkglib_MODULES): ... this. Update all users.
7253 (pkgdata_PROGRAMS): Rename to ...
7254 (pkglib_PROGRAMS): ... this. Update all users.
7255 (pkgdata_DATA): Rename to ...
7256 (pkglib_DATA): ... this. Update all users.
7257 (CLEANFILES): Redefine to `$(pkglib_DATA) $(pkgdata_DATA)'.
7258 (unicode.pff, ascii.pff): New rules.
7259 (all-local): Add `$(PKGDATA)' dependency.
7260 (install-local): Process `$(PKGDATA)'.
7261
7262 * util/update-grub_lib.in (font_path): Search for *.pff files in
7263 a few more locations, including `${pkgdata}'.
7264
7265 2007-12-23 Robert Millan <rmh@aybabtu.com>
7266
7267 Patch from Bean <bean123ch@gmail.com>:
7268 * disk/loopback.c (grub_loopback_read): Add missing bit shift to
7269 `size'.
7270
7271 2007-12-21 Bean <bean123ch@gmail.com>
7272
7273 * conf/common.rmk (pkgdata_MODULES): Add ntfscomp.mod.
7274 (ntfscomp_mod_SOURCES): New variable.
7275 (ntfscomp_mod_CFLAGS): Likewise.
7276 (ntfscomp_mod_LDFLAGS): Likewise.
7277
7278 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfscomp.c.
7279 (grub_probe_SOURCES): Likewise.
7280 (grub_emu_SOURCES): Likewise.
7281
7282 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
7283 (grub_emu_SOURCES): Likewise.
7284
7285 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
7286 (grub_emu_SOURCES): Likewise.
7287
7288 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
7289 (grub_emu_SOURCES): Likewise.
7290
7291 * fs/ntfs.c (grub_ntfscomp_func): New variable.
7292 (read_run_list): Renamed to grub_ntfs_read_run_list.
7293 (decomp_nextvcn): Moved to ntfscomp.c.
7294 (decomp_getch): Likewise.
7295 (decomp_get16): Likewise.
7296 (decomp_block): Likewise.
7297 (read_block): Likewise.
7298 (read_data): Partially moved to ntfscomp.c.
7299 (fixup): Change unsigned to grub_uint16_t.
7300 (read_mft): Change unsigned long to grub_uint32_t.
7301 (read_attr): Likewise.
7302 (read_data): Likewise.
7303 (read_run_data): Likewise.
7304 (read_run_list): Likewise.
7305 (read_mft): Likewise.
7306
7307 * fs/ntfscomp.c: New file.
7308
7309 * include/grub/ntfs.h: New file.
7310
7311 2007-12-16 Robert Millan <rmh@aybabtu.com>
7312
7313 * util/grub-mkdevicemap.c (make_device_map): Iterate up to 20 for
7314 IDE disk check, since Linux is known to support 20 IDE disks.
7315 Reported by Colin Watson.
7316
7317 2007-12-15 Bean <bean123ch@gmail.com>
7318
7319 * conf/i386-pc.rmk (pkgdata_IMAGES): Add lnxboot.img.
7320 (lnxboot_img_SOURCES): New variable.
7321 (lnxboot_img_ASFLAGS): Likewise.
7322 (lnxboot_img_LDFLAGS): Likewise.
7323
7324 * boot/i386/pc/lnxboot.S: New file.
7325
7326 2007-11-24 Pavel Roskin <proski@gnu.org>
7327
7328 * configure.ac: Test if '--build-id=none' is supported by the
7329 linker. If yes, add it to TARGET_LDFLAGS. Build ID causes
7330 objcopy to generate incorrect binary files (binutils
7331 2.17.50.0.18-1 as shipped by Fedora 8).
7332 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Use LDFLAGS when
7333 linking, so that build ID doesn't break the test.
7334
7335 2007-11-24 Pavel Roskin <proski@gnu.org>
7336
7337 * include/grub/i386/time.h: use "void" in the argument list
7338 of grub_cpu_idle().
7339 * include/grub/powerpc/time.h: Likewise.
7340 * include/grub/sparc64/time.h: Likewise.
7341
7342 2007-11-18 Christian Franke <franke@computer.org>
7343
7344 * util/console.c (grub_ncurses_getkey): Change curses KEY_* mapping,
7345 now return control chars instead of GRUB_CONSOLE_KEY_* constants.
7346 This fixes the problem that function keys did not work in grub-emu.
7347
7348 2007-11-18 Christian Franke <franke@computer.org>
7349
7350 * disk/host.c (grub_host_open): Remove attribute unused from
7351 name parameter. Add check for "host". This fixes the problem
7352 that grub-emu does not find partitions.
7353
7354 2007-11-18 Christian Franke <franke@computer.org>
7355
7356 * util/hostfs.c (is_dir): New function.
7357 (grub_hostfs_dir): Handle missing dirent.d_type case.
7358 (grub_hostfs_read): Add missing fseek().
7359 (grub_hostfs_label): Clear label pointer. This fixes a crash
7360 of grub-emu on "ls (host)".
7361
7362 2007-11-18 Christian Franke <franke@computer.org>
7363
7364 * include/grub/i386/pc/init.h (struct grub_machine_mmap_entry):
7365 Add attribute packed, gcc 3.4.4 on Cygwin aligns this
7366 to 64 bit boundary by default.
7367
7368 2007-11-18 Bean <bean123ch@gmail.com>
7369
7370 * conf/common.rmk (pkgdata_MODULES): Add hexdump.mod.
7371 (hexdump_mod_SOURCES): New variable.
7372 (hexdump_mod_CFLAGS): Likewise.
7373 (hexdump_mod_LDFLAGS): Likewise.
7374
7375 * conf/i386-pc.rmk (grub_emu_SOURCES): Add command/hexdump.c.
7376
7377 * conf/i386-efi.rmk (grub_emu_SOURCES): Add command/hexdump.c.
7378
7379 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add command/hexdump.c.
7380
7381 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add command/hexdump.c.
7382
7383 * include/grub/hexdump.h: New file.
7384
7385 * commands/hexdump.c: New file.
7386
7387 2007-11-10 Robert Millan <rmh@aybabtu.com>
7388
7389 * commands/i386/pc/play.c (beep_off): Switch order of arguments
7390 in grub_outb() calls.
7391 (beep_on): Likewise.
7392
7393 2007-11-10 Christian Franke <franke@computer.org>
7394
7395 * normal/menu.c (run_menu): Check for empty menu to avoid crash.
7396 (grub_menu_run): Likewise.
7397
7398 2007-11-10 Robert Millan <rmh@aybabtu.com>
7399
7400 * include/grub/i386/efi/machine.h: New file.
7401 * include/grub/i386/linuxbios/machine.h: Likewise.
7402 * include/grub/i386/pc/machine.h: Likewise.
7403 * include/grub/powerpc/ieee1275/machine.h: Likewise.
7404 * include/grub/sparc64/ieee1275/machine.h: Likewise.
7405
7406 * term/i386/pc/serial.c: Include <grub/machine/machine.h>.
7407 (serial_hw_io_addr): New variable.
7408 (serial_hw_get_port): Obtain port address from `serial_hw_io_addr'
7409 instead of `(unsigned short *) 0x400'.
7410
7411 2007-11-10 Bean <bean123ch@gmail.com>
7412
7413 * fs/ntfs.c (read_block): Fix a bug caused by adjacent blocks.
7414
7415 2007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
7416
7417 * conf/i386-pc.rmk (pkgdata_MODULES): Added vga.mod.
7418 (vga_mod_SOURCES): Added.
7419 (vga_mod_CFLAGS): Likewise.
7420 (vga_mod_LDFLAGS): Likewise.
7421
7422 * term/i386/pc/vga.c (get_map_mask): Switch order of arguments in
7423 grub_outb() calls.
7424 (set_map_mask): Likewise.
7425 (set_read_map): Likewise.
7426 (set_read_address): Likewise.
7427 (vga_font): Removed variable.
7428 (get_vga_glyph): Removed function.
7429 (invalidate_char): Likewise.
7430 (write_char): Changed to use grub_font_get_glyph() for font
7431 information.
7432 (grub_vga_putchar): Likewise.
7433 (grub_vga_getcharwidth): Likewise.
7434
7435 2007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
7436
7437 * conf/i386-pc.rmk (boot_img_LDFLAGS): Use COMMON_LDFLAGS for target
7438 flags.
7439 (pxeboot_img_LDFLAGS): Likewise.
7440 (diskboot_img_LDFLAGS): Likewise.
7441 (kernel_img_LDFLAGS): Likewise.
7442
7443 2007-11-06 Robert Millan <rmh@aybabtu.com>
7444
7445 * term/i386/pc/serial.c (serial_hw_put): Switch order of arguments
7446 in grub_outb() calls.
7447 (serial_hw_init): Likewise.
7448
7449 2007-11-05 Robert Millan <rmh@aybabtu.com>
7450
7451 * util/update-grub.in: Allow files in ${update_grub_dir} to contain
7452 spaces. Skip non-regular files.
7453
7454 2007-11-05 Robert Millan <rmh@aybabtu.com>
7455
7456 * kern/disk.c (grub_disk_firmware_fini)
7457 (grub_disk_firmware_is_tainted): New variables.
7458
7459 * include/grub/disk.h (grub_disk_firmware_fini)
7460 (grub_disk_firmware_is_tainted): Likewise.
7461
7462 * disk/i386/pc/biosdisk.c (GRUB_MOD_FINI(biosdisk)): Moved from here ...
7463 (grub_disk_biosdisk_fini): ... to here.
7464 (GRUB_MOD_FINI(biosdisk)): Implement using grub_disk_biosdisk_fini().
7465 (GRUB_MOD_INIT(biosdisk)): Abort when `grub_disk_firmware_is_tainted'
7466 is set. Register grub_disk_biosdisk_fini() in
7467 `grub_disk_firmware_fini'.
7468
7469 * disk/ata.c: Remove `<grub/machine/biosdisk.h>'.
7470 (GRUB_MOD_INIT(ata)): Remove grub_biosdisk_fini() call.
7471 Use `grub_disk_firmware_is_tainted' and `grub_disk_firmware_fini'
7472 to finish existing firmware disk interface.
7473
7474 * conf/i386-linuxbios.rmk (pkgdata_MODULES): Add `ata.mod'.
7475 (ata_mod_SOURCES): New variable.
7476 (ata_mod_CFLAGS): Likewise.
7477 (ata_mod_LDFLAGS): Likewise.
7478
7479 2007-11-05 Robert Millan <rmh@aybabtu.com>
7480
7481 * disk/ata.c: Remove `<grub/machine/time.h>'. Include `<grub/time.h>'.
7482 (grub_ata_wait): Reimplement using grub_millisleep().
7483
7484 * include/grub/misc.h (grub_div_roundup): Fix parenthesization.
7485 * include/grub/i386/time.h (grub_cpu_idle): Disable `hlt' instruction.
7486
7487 2007-11-03 Marco Gerards <marco@gnu.org>
7488
7489 * term/i386/pc/vga_text.c: Include <grub/cpu/io.h>.
7490 (CRTC_ADDR_PORT): New macro.
7491 (CRTC_DATA_PORT): Likewise.
7492 (CRTC_CURSOR): Likewise.
7493 (CRTC_CURSOR_ADDR_HIGH): Likewise.
7494 (CRTC_CURSOR_ADDR_LOW): Likewise.
7495 (update_cursor): New function.
7496 (grub_console_real_putchar): Call `update_cursor'.
7497 (grub_console_gotoxy): Likewise.
7498 (grub_console_cls): Set the default color when clearing the
7499 screen.
7500 (grub_console_setcursor): Implemented.
7501
7502 2007-11-03 Marco Gerards <marco@gnu.org>
7503
7504 * disk/ata.c (grub_ata_pio_read): Don't wait for the command to
7505 become activate.
7506 (grub_ata_pio_write): Likewise.
7507
7508 (grub_atapi_identify): Wait after issuing an ATA command.
7509 (grub_atapi_packet): Likewise.
7510 (grub_ata_identify): Likewise.
7511 (grub_ata_readwrite): Likewise.
7512
7513 2007-11-03 Marco Gerards <marco@gnu.org>
7514
7515 * disk/ata.c (grub_ata_pio_read): Detect and return the error code.
7516 (grub_ata_pio_write): Likewise.
7517 (grub_ata_readwrite): Use `grub_error', instead of
7518 returning `grub_errno'.
7519
7520 2007-11-03 Marco Gerards <marco@gnu.org>
7521
7522 * disk/ata.c (grub_ata_readwrite): Call grub_ata_pio_read and
7523 grub_ata_pio_write once for every single sector, instead of for
7524 multiple sectors.
7525
7526 2007-10-31 Robert Millan <rmh@aybabtu.com>
7527
7528 * configure.ac: Add `i386-linuxbios' to the list of supported targets.
7529
7530 * conf/i386-linuxbios.rmk: New file.
7531
7532 * kern/i386/pc/hardware.c: Likewise.
7533 * term/i386/pc/at_keyboard.c: Likewise.
7534 * term/i386/pc/vga_text.c: Likewise.
7535
7536 * include/grub/i386/linuxbios/boot.h: Likewise.
7537 * include/grub/i386/linuxbios/console.h: Likewise.
7538 * include/grub/i386/linuxbios/init.h: Likewise.
7539 * include/grub/i386/linuxbios/kernel.h: Likewise.
7540 * include/grub/i386/linuxbios/loader.h: Likewise.
7541 * include/grub/i386/linuxbios/memory.h: Likewise.
7542 * include/grub/i386/linuxbios/serial.h: Likewise.
7543 * include/grub/i386/linuxbios/time.h: Likewise.
7544
7545 * kern/i386/linuxbios/init.c: Likewise.
7546 * kern/i386/linuxbios/startup.S: Likewise.
7547 * kern/i386/linuxbios/table.c: Likewise.
7548
7549 2007-10-31 Marco Gerards <marco@gnu.org>
7550
7551 * conf/i386-pc.rmk (pkgdata_MODULES): Add `ata.mod'.
7552 (ata_mod_SOURCES): New variable.
7553 (ata_mod_CFLAGS): Likewise.
7554 (ata_mod_LDFLAGS): Likewise.
7555
7556 * disk/ata.c: New file.
7557
7558 * include/grub/disk.h (grub_disk_dev_id): Add
7559 `GRUB_DISK_DEV_ATA_ID'.
7560
7561 2007-10-31 Robert Millan <rmh@aybabtu.com>
7562
7563 * include/grub/i386/pc/init.h (grub_lower_mem): Moved from here ...
7564 * include/grub/i386/pc/memory.h (grub_lower_mem): ... to here.
7565
7566 * include/grub/i386/pc/init.h (grub_upper_mem): Moved from here ...
7567 * include/grub/i386/pc/memory.h (grub_upper_mem): ... to here.
7568
7569 * include/grub/i386/pc/memory.h: Include `<grub/symbol.h>' and
7570 `<grub/types.h>'.
7571
7572 * loader/i386/pc/multiboot.c: Include `<grub/machine/memory.h>'.
7573
7574 2007-10-27 Robert Millan <rmh@aybabtu.com>
7575
7576 * include/grub/types.h (ULONG_MAX): Define macro.
7577
7578 2007-10-22 Robert Millan <rmh@aybabtu.com>
7579
7580 * kern/i386/pc/startup.S: Remove `"kern/i386/realmode.S"'. Include
7581 `"../realmode.S"'.
7582 Remove `"kern/i386/loader.S"'. Include `"../loader.S"'.
7583
7584 2007-10-22 Robert Millan <rmh@aybabtu.com>
7585
7586 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove `disk/i386/pc/biosdisk.c'.
7587 (pkgdata_MODULES): Add `biosdisk.mod'.
7588 (biosdisk_mod_SOURCES, biosdisk_mod_CFLAGS, biosdisk_mod_LDFLAGS): New
7589 variables.
7590
7591 * disk/i386/pc/biosdisk.c: Include `<grub/dl.h>'.
7592 (grub_biosdisk_init): Replace with ...
7593 (GRUB_MOD_INIT(biosdisk)): ... this.
7594 (grub_biosdisk_fini): Replace with ...
7595 (GRUB_MOD_FINI(biosdisk)): ... this.
7596
7597 * kern/i386/pc/init.c: Remove `<grub/machine/biosdisk.h>'.
7598 (grub_machine_init): Remove call to grub_biosdisk_init().
7599 (grub_machine_fini): Remove call to grub_machine_fini().
7600
7601 * util/i386/pc/grub-install.in (modules): Add `biosdisk'.
7602
7603 2007-10-22 Robert Millan <rmh@aybabtu.com>
7604
7605 * include/grub/time.h: New file.
7606 * include/grub/i386/time.h: Likewise.
7607 * include/grub/powerpc/time.h: Likewise.
7608 * include/grub/sparc64/time.h: Likewise.
7609
7610 * include/grub/i386/pc/time.h (KERNEL_TIME_HEADER): Rename all
7611 instances to ...
7612 (KERNEL_MACHINE_TIME_HEADER): ... this.
7613 * include/grub/powerpc/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
7614 instances to ...
7615 (KERNEL_MACHINE_TIME_HEADER): ... this.
7616 * include/grub/sparc64/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
7617 instances to ...
7618 (KERNEL_MACHINE_TIME_HEADER): ... this.
7619
7620 * kern/i386/efi/init.c: Include `<grub/time.h>'.
7621 (grub_millisleep): New function.
7622 * kern/i386/pc/init.c: Include `<grub/time.h>'.
7623 (grub_millisleep): New function.
7624 * kern/powerpc/ieee1275/init.c: Include `<grub/time.h>'.
7625 Remove `grub/machine/time.h' include.
7626 (grub_millisleep): New function.
7627 * kern/sparc64/ieee1275/init.c: Include `<grub/time.h>'.
7628 Remove `grub/machine/time.h' include.
7629 (grub_millisleep): New function.
7630
7631 * include/grub/misc.h (grub_div_roundup): New function.
7632
7633 * kern/misc.c: Include `<grub/time.h>'.
7634 (grub_millisleep_generic): New function.
7635
7636 * conf/i386-efi.rmk (kernel_mod_HEADERS): Remove `i386/efi/time.h'.
7637 Add `time.h'.
7638 * conf/i386-pc.rmk (kernel_img_HEADERS): Remove `machine/time.h'.
7639 Add `time.h'.
7640 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Remove
7641 `machine/time.h'. Add `time.h'.
7642 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
7643
7644 2007-10-21 Robert Millan <rmh@aybabtu.com>
7645
7646 * include/grub/misc.h (grub_max): New function.
7647
7648 2007-10-21 Robert Millan <rmh@aybabtu.com>
7649
7650 * util/misc.c (grub_util_info): Call fflush() before returning.
7651
7652 2007-10-20 Robert Millan <rmh@aybabtu.com>
7653
7654 * genmk.rb (Image): Copy `extra_flags' from here ...
7655 (PModule): ... to here. Use it in `#{obj}: #{src}' rule.
7656
7657 * commands/i386/cpuid.c (grub_cmd_cpuid): Add __attribute__ ((unused))
7658 to `argc' and `args' arguments.
7659
7660 2007-10-17 Robert Millan <rmh@aybabtu.com>
7661
7662 * kern/i386/loader.S: New file.
7663
7664 * kern/i386/pc/startup.S (grub_linux_prot_size): Moved from here ...
7665 * kern/i386/loader.S (grub_linux_prot_size)... to here.
7666 * kern/i386/pc/startup.S (grub_linux_tmp_addr): Moved from here ...
7667 * kern/i386/loader.S (grub_linux_tmp_addr)... to here.
7668 * kern/i386/pc/startup.S (grub_linux_real_addr): Moved from here ...
7669 * kern/i386/loader.S (grub_linux_real_addr)... to here.
7670 * kern/i386/pc/startup.S (grub_linux_boot_zimage): Moved from here ...
7671 * kern/i386/loader.S (grub_linux_boot_zimage)... to here.
7672 * kern/i386/pc/startup.S (grub_linux_boot_bzimage): Moved from here ...
7673 * kern/i386/loader.S (grub_linux_boot_bzimage)... to here.
7674 * kern/i386/pc/startup.S (grub_multiboot_real_boot): Moved from here ...
7675 * kern/i386/loader.S (grub_multiboot_real_boot)... to here.
7676 * kern/i386/pc/startup.S (grub_multiboot2_real_boot): Moved from here ...
7677 * kern/i386/loader.S (grub_multiboot2_real_boot)... to here.
7678
7679 * kern/i386/realmode.S: New file.
7680
7681 * kern/i386/pc/startup.S (protstack): Moved from here ...
7682 * kern/i386/realmode.S (protstack)... to here.
7683 * kern/i386/pc/startup.S (gdt): Moved from here ...
7684 * kern/i386/realmode.S (gdt)... to here.
7685 * kern/i386/pc/startup.S (prot_to_real): Moved from here ...
7686 * kern/i386/realmode.S (prot_to_real)... to here.
7687
7688 * kern/i386/pc/startup.S: Include `kern/i386/loader.S' and
7689 `kern/i386/realmode.S'.
7690
7691 2007-10-17 Robert Millan <rmh@aybabtu.com>
7692
7693 * include/grub/i386/loader.h: New file.
7694
7695 * include/grub/i386/pc/loader.h (grub_linux_prot_size)
7696 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
7697 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
7698 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
7699 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): Moved from here ...
7700 * include/grub/i386/loader.h (grub_linux_prot_size)
7701 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
7702 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
7703 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
7704 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): ... to here.
7705
7706 * include/grub/i386/pc/loader.h: Include `grub/cpu/loader.h'.
7707
7708 2007-10-15 Robert Millan <rmh@aybabtu.com>
7709
7710 * normal/misc.c (grub_normal_print_device_info): Do not probe for
7711 filesystem when dev->disk is unset.
7712 Do probe for filesystem even when dev->disk->has_partitions is set.
7713 In case a filesystem is found, always report it.
7714 In case it isn't, if dev->disk->has_partitions is set, report that
7715 a partition table was found instead of reporting that no filesystem
7716 could be identified.
7717
7718 2007-10-12 Robert Millan <rmh@aybabtu.com>
7719
7720 * conf/powerpc-ieee1275.rmk (grub_mkimage_SOURCES): Replace reference
7721 to util/powerpc/ieee1275/grub-mkimage.c with util/elf/grub-mkimage.c.
7722
7723 * include/grub/types.h (grub_host_to_target16): New macro.
7724 (grub_host_to_target32): Likewise.
7725 (grub_host_to_target64): Likewise.
7726 (grub_target_to_host16): Likewise.
7727 (grub_target_to_host32): Likewise.
7728 (grub_target_to_host64): Likewise.
7729
7730 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
7731 Renamed from to ...
7732 (GRUB_MOD_ALIGN): ...this. Update all users.
7733
7734 * util/elf/grub-mkimage.c (load_note): Replace grub_cpu_to_be32 with
7735 grub_host_to_target32.
7736 Replace grub_be_to_cpu32 with grub_target_to_host32.
7737 (load_modules): Likewise.
7738 (add_segments): Replace grub_be_to_cpu16 with grub_target_to_host16.
7739 Replace grub_be_to_cpu32 with grub_target_to_host32.
7740 Replace grub_cpu_to_be16 with grub_host_to_target16.
7741 Replace grub_cpu_to_be32 grub_host_to_target32.
7742
7743 2007-10-12 Robert Millan <rmh@aybabtu.com>
7744
7745 * util/powerpc/ieee1275/grub-mkimage.c: Moved to ...
7746 * util/elf/grub-mkimage.c: ... here.
7747
7748 * DISTLIST: Add `util/elf/grub-mkimage.c'. Remove
7749 `util/powerpc/ieee1275/grub-mkimage.c'.
7750
7751 2007-10-07 Robert Millan <rmh@aybabtu.com>
7752
7753 * kern/powerpc/ieee1275/init.c: Rename HEAP_LIMIT to HEAP_MAX_ADDR,
7754 and make it easier to figure out.
7755 Add HEAP_MIN_SIZE and HEAP_MAX_ADDR definitions.
7756 (grub_claim_heap): Use HEAP_MAX_ADDR rather than taking a parameter.
7757 Do not avoid claiming a region above HEAP_MAX_ADDR if that would
7758 leave us with less than HEAP_MIN_SIZE total heap.
7759 Avoid our total amount of heap to surpass HEAP_MAX_SIZE.
7760
7761 2007-10-03 Robert Millan <rmh@aybabtu.com>
7762
7763 * include/grub/i386/io.h: New file.
7764 * commands/i386/pc/play.c (inb): Removed.
7765 (outb): Removed.
7766 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
7767 with grub_outb().
7768 * term/i386/pc/serial.c (inb): Removed.
7769 (outb): Removed.
7770 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
7771 with grub_outb().
7772 * term/i386/pc/vga.c (inb): Removed.
7773 (outb): Removed.
7774 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
7775 with grub_outb().
7776
7777 2007-10-02 Robert Millan <rmh@aybabtu.com>
7778
7779 * conf/i386-efi.rmk (grub_emu_SOURCES): Add util/hostfs.c.
7780 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7781 Reported by Marcin Kurek.
7782
7783 2007-09-07 Robert Millan <rmh@aybabtu.com>
7784
7785 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_test_flag): Detect
7786 SmartFirmware version updates (as released by Sven Luther), and avoid
7787 setting GRUB_IEEE1275_FLAG_NO_PARTITION_0 or
7788 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS unless the running version is
7789 known broken.
7790
7791 2007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
7792
7793 From Hitoshi Ozeki:
7794 * kern/i386/pc/init.c (compact_mem_regions): Decrease NUM_REGIONS
7795 when merging two regions.
7796
7797 2007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
7798
7799 * kern/rescue.c (grub_enter_rescue_mode): Free ARGS.
7800 * normal/completion.c (grub_normal_do_completion): Likewise.
7801 Reported by Hitoshi Ozeki.
7802
7803 2007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
7804
7805 Do not use devices at boot in chainloading.
7806
7807 * loader/i386/pc/chainloader.c (boot_drive): New variable.
7808 (boot_part_addr): Likewise.
7809 (grub_chainloader_boot): Simply call grub_chainloader_real_boot
7810 with BOOT_DRIVE and BOOT_PART_ADDR.
7811 (grub_chainloader_cmd): Set BOOT_DRIVE and BOOT_PART_ADDR.
7812 Reported by Hitoshi Ozeki <h-ozeki@ck2.so-net.ne.jp>.
7813
7814 2007-08-29 Robert Millan <rmh@aybabtu.com>
7815
7816 Patch from Simon Peter <dn.tlp@gmx.net>:
7817 * genmk.rb (Utility): Append $(#{src}_DEPENDENCIES) to #{obj} targets.
7818 * conf/i386-pc.rmk: Replace grub-probe_DEPENDENCIES with
7819 util/grub-probe.c_DEPENDENCIES. Replace grub-setup_DEPENDENCIES with
7820 util/i386/pc/grub-setup.c_DEPENDENCIES.
7821 * conf/i386-efi.rmk: Replace grub-probe_DEPENDENCIES with
7822 util/grub-probe.c_DEPENDENCIES.
7823 * conf/powerpc-ieee1275.rmk: Likewise.
7824
7825 2007-08-28 Robert Millan <rmh@aybabtu.com>
7826
7827 * util/i386/get_disk_name.c: New. Implement grub_util_get_disk_name()
7828 to tell grub-mkdevicemap how to name devices.
7829 * util/ieee1275/get_disk_name.c: Likewise (using "ofpathname -a"
7830 feature).
7831
7832 * conf/i386-efi.rmk (grub_mkdevicemap_SOURCES): Add
7833 util/i386/get_disk_name.c.
7834 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Likewise.
7835 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Add
7836 util/ieee1275/get_disk_name.c.
7837
7838 * include/grub/util/misc.h: grub_util_get_disk_name() declaration.
7839
7840 * DISTLIST: Add util/i386/get_disk_name.c and
7841 util/ieee1275/get_disk_name.c.
7842
7843 * util/grub-mkdevicemap.c: Replace device naming logic with
7844 grub_util_get_disk_name() calls.
7845
7846 2007-08-20 Robert Millan <rmh@aybabtu.com>
7847
7848 * normal/menu.c (run_menu): Refer to seconds as "s" not "seconds"
7849 (so that it works for both plural and singular quantities).
7850
7851 2007-08-05 Robert Millan <rmh@aybabtu.com>
7852
7853 * util/grub.d/10_linux.in (test_gt): Strip out vmlinu[xz]- prefix
7854 so that [xz] isn't taken into account when determining order.
7855
7856 2007-08-02 Marco Gerards <marco@gnu.org>
7857
7858 * DISTLIST: Add `disk/host.c', `fs/ntfs.c', `include/multiboot.h',
7859 `include/multiboot2.h', `include/grub/elfload.h',
7860 `include/multiboot.h', `include/grub/multiboot.h',
7861 `include/grub/multiboot_loader.h', `include/grub/multiboot2.h',
7862 `include/grub/i386/pc/biosdisk.h', `include/grub/util/biosdisk.h',
7863 `kern/elf.c', `loader/multiboot_loader.c',
7864 `loader/multiboot_loader_normal.c', `loader/multiboot2.c',
7865 `loader/i386/pc/multiboot2.c',
7866 `loader/powerpc/ieee1275/multiboot2.c', `util/hostfs.c' and
7867 `util/i386/pc/grub-mkrescue.in'. Remove
7868 `include/grub/biosdisk.h', `include/grub/i386/pc/multiboot.h',
7869 `include/grub/i386/pc/util/biosdisk.h' and
7870 `include/grub/powerpc/ieee1275/multiboot.h'.
7871
7872 2007-08-02 Bean <bean123ch@gmail.com>
7873
7874 * conf/common.rmk (pkgdata_MODULES): Add ntfs.mod.
7875 (ntfs_mod_SOURCES): New variable.
7876 (ntfs_mod_CFLAGS): Likewise.
7877 (ntfs_mod_LDFLAGS): Likewise.
7878
7879 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfs.c.
7880 (grub_probe_SOURCES): Likewise.
7881 (grub_emu_SOURCES): Likewise.
7882
7883 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
7884 (grub_emu_SOURCES): Likewise.
7885
7886 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
7887 (grub_emu_SOURCES): Likewise.
7888
7889 * conf/misc.c (grub_utf16_to_utf8): Fix unicode conversion bug.
7890
7891 * fs/ntfs.c: New file.
7892
7893 2007-08-02 Bean <bean123ch@gmail.com>
7894
7895 * disk.h (grub_disk): Use NESTED_FUNC_ATTR.
7896
7897 * file.h (grub_file): Likewise.
7898
7899 * fshelp.h (grub_fshelp_read_file): Likewise.
7900
7901 * util/i386/pc/grub-setup.c (setup): Likewise.
7902 (save_first_sector): Likewise.
7903 (save_blocklists): Likewise.
7904
7905 * fs/affs.c (grub_affs_read_file): Likewise.
7906
7907 * fs/ext2.c (grub_ext2_read_file): Likewise.
7908
7909 * fs/fat.c (grub_fat_read_data): Likewise.
7910
7911 * fs/fshelp.c (grub_fshelp_read_file): Likewise.
7912
7913 * fs/hfs.c (grub_hfs_read_file): Likewise.
7914
7915 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
7916
7917 * fs/jfs.c (grub_jfs_read_file): Likewise.
7918
7919 * fs/minix.c (grub_minix_read_file): Likewise.
7920
7921 * fs/sfs.c (grub_sfs_read_file): Likewise.
7922
7923 * fs/ufs.c (grub_ufs_read_file): Likewise.
7924
7925 * fs/xfs.c (grub_xfs_read_file): Likewise.
7926
7927 * command/blocklist.c (read_blocklist): Likewise.
7928 (print_blocklist): Likewise.
7929
7930 2007-08-02 Marco Gerards <marco@gnu.org>
7931
7932 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/host.c' and
7933 `util/hostfs.c'.
7934
7935 * disk/host.c: New file.
7936
7937 * util/hostfs.c: Likewise.
7938
7939 * fs/hfsplus.c (grub_hfsplus_mount): When reading out of disk,
7940 return `GRUB_ERR_BAD_FS'.
7941 * fs/sfs.c (grub_sfs_mount): Likewise.
7942 * fs/xfs.c (grub_xfs_mount): Likewise.
7943
7944 * include/grub/disk.h (enum grub_disk_dev_id): Add
7945 `GRUB_DISK_DEVICE_HOST_ID'.
7946
7947 * util/grub-emu.c (main): Initialize and de-initialize hostfs.
7948
7949 2007-07-24 Jerone Young <jerone@gmail.com>
7950
7951 * conf/i386-pc.rmk: Add Multiboot loader and multiboot 2 to multiboot
7952 modules for compilation.
7953 * conf/powerpc-ieee1275.rmk: Likewise.
7954
7955 * include/multiboot.h: Move multiboot definitions to one file. Rename
7956 many definitions to not get grub specific.
7957 * include/multiboot2.h: Create header with multiboot 2 definitions.
7958 * include/grub/multiboot.h: Header for grub specific function
7959 prototypes and definitions.
7960 * include/grub/multiboot2.h: Likewise.
7961 * include/grub/multiboot_loader.h: Likewise.
7962 * include/grub/i386/pc/multiboot.h: Removed.
7963 * include/grub/powerpc/ieee1275/multiboot.h: Removed.
7964
7965 * loader/multiboot_loader.c: Created to act as a proxy for multiboot 1
7966 and 2 to allow for one multiboot and module commands.
7967 * loader/multiboot2.c: Add multiboot2 functionality.
7968 * loader/i386/pc/multiboot.c: Modify for new multiboot header location
7969 and definition names.
7970 * loader/i386/pc/multiboot2.c: Created to add i386 specific multiboot
7971 2 functions.
7972 * loader/powerpc/ieee1275/multiboot2.c: Created to add powerpc
7973 ieee1275 specific multiboot2 code.
7974
7975 * kern/i386/pc/startup.S: Change headers and definition names for
7976 multiboot. Add function grub_multiboot2_real_boot for multiboot 2.
7977
7978 2007-07-22 Robert Millan <rmh@aybabtu.com>
7979
7980 * geninitheader.sh: Process file specified in first parameter rather
7981 than hardcoding grub_modules_init.lst.
7982 * geninit.sh: Likewise. Also, construct header name dynamically rather
7983 than hardcoding grub_modules_init.h.
7984
7985 * conf/common.rmk: Rename grub_modules_init.[ch] files associated with
7986 grub-emu to grub_emu_init.[ch]. Add rules to build analogous
7987 grub_probe_init.[ch] and grub_setup_init.[ch].
7988
7989 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Replace
7990 grub_modules_init.h with grub_emu_init.h.
7991 (grub_probe_DEPENDENCIES, grub_probe_SOURCES): Add new
7992 grub_probe_init.[ch] files.
7993 * conf/i386-efi.rmk: Likewise.
7994 * conf/i386-pc.rmk: Likewise.
7995 (grub_setup_DEPENDENCIES, grub_setup_SOURCES): Add new
7996 grub_setup_init.[ch] files.
7997
7998 * util/grub-emu.c: Replace grub_modules_init.h with grub_emu_init.h.
7999 * util/grub-probe.c: Include grub_probe_init.h. Use grub_init_all()
8000 to initialize modules rather than a list of hardcoded functions.
8001 * util/i386/pc/grub-setup.c: Include grub_setup_init.h. Use
8002 grub_init_all() to initialize modules rather than a list of hardcoded
8003 functions.
8004
8005 2007-07-22 Robert Millan <rmh@aybabtu.com>
8006
8007 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set
8008 GRUB_IEEE1275_FLAG_NO_PARTITION_0 flag when running on SmartFirmware.
8009
8010 2007-07-22 Robert Millan <rmh@aybabtu.com>
8011
8012 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
8013 GRUB_IEEE1275_FLAG_BROKEN_OUTPUT flag.
8014 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set this
8015 flag when running on SmartFirmware.
8016 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid running
8017 "output-device output" command when GRUB_IEEE1275_FLAG_BROKEN_OUTPUT
8018 was set.
8019
8020 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
8021 Increase partno when GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS flag is set,
8022 rather than decreasing it.
8023
8024 * util/i386/pc/grub-setup.c (setup): When embedding is required, but
8025 there's not enough space to do it, fail in the same way as when it
8026 can't be done because there are no partitions.
8027
8028 * util/powerpc/ieee1275/grub-install.in: Improve error message shown
8029 when nvsetenv failed.
8030
8031 2007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
8032
8033 * conf/i386-pc.rmk (CLEANFILES): Removed for grub-mkrescue,
8034 because this rule is automatically generated.
8035 (grub-mkrescue): Removed for the same reason as above.
8036
8037 2007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
8038
8039 Migrate to GNU General Public License Version 3.
8040
8041 * COPYING: Replaced with the plain text version of GPLv3.
8042
8043 * config.guess: Updated from gnulib.
8044 * config.sub: Likewise.
8045
8046 * geninit.sh: Output a GPLv3 copyright notice.
8047 * geninitheader.sh: Likewise.
8048 * genmodsrc.sh: Likewise.
8049 * gensymlist.sh.in: Likewise.
8050
8051 * boot/i386/pc/boot.S: Upgraded to GPLv3.
8052 * boot/i386/pc/diskboot.S: Likewise.
8053 * boot/i386/pc/pxeboot.S: Likewise.
8054 * commands/blocklist.c: Likewise.
8055 * commands/boot.c: Likewise.
8056 * commands/cat.c: Likewise.
8057 * commands/cmp.c: Likewise.
8058 * commands/configfile.c: Likewise.
8059 * commands/echo.c: Likewise.
8060 * commands/help.c: Likewise.
8061 * commands/ls.c: Likewise.
8062 * commands/search.c: Likewise.
8063 * commands/terminal.c: Likewise.
8064 * commands/test.c: Likewise.
8065 * commands/videotest.c: Likewise.
8066 * commands/i386/cpuid.c: Likewise.
8067 * commands/i386/pc/halt.c: Likewise.
8068 * commands/i386/pc/play.c: Likewise.
8069 * commands/i386/pc/reboot.c: Likewise.
8070 * commands/i386/pc/vbeinfo.c: Likewise.
8071 * commands/i386/pc/vbetest.c: Likewise.
8072 * commands/ieee1275/halt.c: Likewise.
8073 * commands/ieee1275/reboot.c: Likewise.
8074 * commands/ieee1275/suspend.c: Likewise.
8075 * disk/loopback.c: Likewise.
8076 * disk/lvm.c: Likewise.
8077 * disk/raid.c: Likewise.
8078 * disk/efi/efidisk.c: Likewise.
8079 * disk/i386/pc/biosdisk.c: Likewise.
8080 * disk/ieee1275/ofdisk.c: Likewise.
8081 * font/manager.c: Likewise.
8082 * fs/affs.c: Likewise.
8083 * fs/ext2.c: Likewise.
8084 * fs/fat.c: Likewise.
8085 * fs/fshelp.c: Likewise.
8086 * fs/hfs.c: Likewise.
8087 * fs/hfsplus.c: Likewise.
8088 * fs/iso9660.c: Likewise.
8089 * fs/jfs.c: Likewise.
8090 * fs/minix.c: Likewise.
8091 * fs/sfs.c: Likewise.
8092 * fs/ufs.c: Likewise.
8093 * fs/xfs.c: Likewise.
8094 * hello/hello.c: Likewise.
8095 * include/grub/acorn_filecore.h: Likewise.
8096 * include/grub/arg.h: Likewise.
8097 * include/grub/bitmap.h: Likewise.
8098 * include/grub/boot.h: Likewise.
8099 * include/grub/cache.h: Likewise.
8100 * include/grub/device.h: Likewise.
8101 * include/grub/disk.h: Likewise.
8102 * include/grub/dl.h: Likewise.
8103 * include/grub/elfload.h: Likewise.
8104 * include/grub/env.h: Likewise.
8105 * include/grub/err.h: Likewise.
8106 * include/grub/file.h: Likewise.
8107 * include/grub/font.h: Likewise.
8108 * include/grub/fs.h: Likewise.
8109 * include/grub/fshelp.h: Likewise.
8110 * include/grub/gzio.h: Likewise.
8111 * include/grub/hfs.h: Likewise.
8112 * include/grub/kernel.h: Likewise.
8113 * include/grub/loader.h: Likewise.
8114 * include/grub/lvm.h: Likewise.
8115 * include/grub/misc.h: Likewise.
8116 * include/grub/mm.h: Likewise.
8117 * include/grub/net.h: Likewise.
8118 * include/grub/normal.h: Likewise.
8119 * include/grub/parser.h: Likewise.
8120 * include/grub/partition.h: Likewise.
8121 * include/grub/pc_partition.h: Likewise.
8122 * include/grub/raid.h: Likewise.
8123 * include/grub/rescue.h: Likewise.
8124 * include/grub/script.h: Likewise.
8125 * include/grub/setjmp.h: Likewise.
8126 * include/grub/symbol.h: Likewise.
8127 * include/grub/term.h: Likewise.
8128 * include/grub/terminfo.h: Likewise.
8129 * include/grub/tparm.h: Likewise.
8130 * include/grub/types.h: Likewise.
8131 * include/grub/video.h: Likewise.
8132 * include/grub/efi/api.h: Likewise.
8133 * include/grub/efi/chainloader.h: Likewise.
8134 * include/grub/efi/console.h: Likewise.
8135 * include/grub/efi/console_control.h: Likewise.
8136 * include/grub/efi/disk.h: Likewise.
8137 * include/grub/efi/efi.h: Likewise.
8138 * include/grub/efi/pe32.h: Likewise.
8139 * include/grub/efi/time.h: Likewise.
8140 * include/grub/i386/linux.h: Likewise.
8141 * include/grub/i386/setjmp.h: Likewise.
8142 * include/grub/i386/types.h: Likewise.
8143 * include/grub/i386/efi/kernel.h: Likewise.
8144 * include/grub/i386/efi/loader.h: Likewise.
8145 * include/grub/i386/efi/time.h: Likewise.
8146 * include/grub/i386/pc/biosdisk.h: Likewise.
8147 * include/grub/i386/pc/boot.h: Likewise.
8148 * include/grub/i386/pc/chainloader.h: Likewise.
8149 * include/grub/i386/pc/console.h: Likewise.
8150 * include/grub/i386/pc/init.h: Likewise.
8151 * include/grub/i386/pc/kernel.h: Likewise.
8152 * include/grub/i386/pc/loader.h: Likewise.
8153 * include/grub/i386/pc/memory.h: Likewise.
8154 * include/grub/i386/pc/multiboot.h: Likewise.
8155 * include/grub/i386/pc/serial.h: Likewise.
8156 * include/grub/i386/pc/time.h: Likewise.
8157 * include/grub/i386/pc/vbe.h: Likewise.
8158 * include/grub/i386/pc/vbeblit.h: Likewise.
8159 * include/grub/i386/pc/vbefill.h: Likewise.
8160 * include/grub/i386/pc/vbeutil.h: Likewise.
8161 * include/grub/i386/pc/vga.h: Likewise.
8162 * include/grub/ieee1275/ieee1275.h: Likewise.
8163 * include/grub/ieee1275/ofdisk.h: Likewise.
8164 * include/grub/powerpc/libgcc.h: Likewise.
8165 * include/grub/powerpc/setjmp.h: Likewise.
8166 * include/grub/powerpc/types.h: Likewise.
8167 * include/grub/powerpc/ieee1275/biosdisk.h: Likewise.
8168 * include/grub/powerpc/ieee1275/console.h: Likewise.
8169 * include/grub/powerpc/ieee1275/ieee1275.h: Likewise.
8170 * include/grub/powerpc/ieee1275/kernel.h: Likewise.
8171 * include/grub/powerpc/ieee1275/loader.h: Likewise.
8172 * include/grub/powerpc/ieee1275/multiboot.h: Likewise.
8173 * include/grub/powerpc/ieee1275/time.h: Likewise.
8174 * include/grub/powerpc/ieee1275/util/biosdisk.h: Likewise.
8175 * include/grub/sparc64/libgcc.h: Likewise.
8176 * include/grub/sparc64/setjmp.h: Likewise.
8177 * include/grub/sparc64/types.h: Likewise.
8178 * include/grub/sparc64/ieee1275/console.h: Likewise.
8179 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
8180 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
8181 * include/grub/sparc64/ieee1275/time.h: Likewise.
8182 * include/grub/util/biosdisk.h: Likewise.
8183 * include/grub/util/getroot.h: Likewise.
8184 * include/grub/util/lvm.h: Likewise.
8185 * include/grub/util/misc.h: Likewise.
8186 * include/grub/util/raid.h: Likewise.
8187 * include/grub/util/resolve.h: Likewise.
8188 * io/gzio.c: Likewise.
8189 * kern/device.c: Likewise.
8190 * kern/disk.c: Likewise.
8191 * kern/dl.c: Likewise.
8192 * kern/elf.c: Likewise.
8193 * kern/env.c: Likewise.
8194 * kern/err.c: Likewise.
8195 * kern/file.c: Likewise.
8196 * kern/fs.c: Likewise.
8197 * kern/loader.c: Likewise.
8198 * kern/main.c: Likewise.
8199 * kern/misc.c: Likewise.
8200 * kern/mm.c: Likewise.
8201 * kern/parser.c: Likewise.
8202 * kern/partition.c: Likewise.
8203 * kern/rescue.c: Likewise.
8204 * kern/term.c: Likewise.
8205 * kern/efi/efi.c: Likewise.
8206 * kern/efi/init.c: Likewise.
8207 * kern/efi/mm.c: Likewise.
8208 * kern/i386/dl.c: Likewise.
8209 * kern/i386/efi/init.c: Likewise.
8210 * kern/i386/efi/startup.S: Likewise.
8211 * kern/i386/pc/init.c: Likewise.
8212 * kern/i386/pc/lzo1x.S: Likewise.
8213 * kern/i386/pc/startup.S: Likewise.
8214 * kern/ieee1275/ieee1275.c: Likewise.
8215 * kern/powerpc/cache.S: Likewise.
8216 * kern/powerpc/dl.c: Likewise.
8217 * kern/powerpc/ieee1275/cmain.c: Likewise.
8218 * kern/powerpc/ieee1275/crt0.S: Likewise.
8219 * kern/powerpc/ieee1275/init.c: Likewise.
8220 * kern/powerpc/ieee1275/openfw.c: Likewise.
8221 * kern/sparc64/cache.S: Likewise.
8222 * kern/sparc64/dl.c: Likewise.
8223 * kern/sparc64/ieee1275/init.c: Likewise.
8224 * kern/sparc64/ieee1275/openfw.c: Likewise.
8225 * loader/efi/chainloader.c: Likewise.
8226 * loader/efi/chainloader_normal.c: Likewise.
8227 * loader/i386/efi/linux.c: Likewise.
8228 * loader/i386/efi/linux_normal.c: Likewise.
8229 * loader/i386/pc/chainloader.c: Likewise.
8230 * loader/i386/pc/chainloader_normal.c: Likewise.
8231 * loader/i386/pc/linux.c: Likewise.
8232 * loader/i386/pc/linux_normal.c: Likewise.
8233 * loader/i386/pc/multiboot.c: Likewise.
8234 * loader/i386/pc/multiboot_normal.c: Likewise.
8235 * loader/powerpc/ieee1275/linux.c: Likewise.
8236 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
8237 * normal/arg.c: Likewise.
8238 * normal/cmdline.c: Likewise.
8239 * normal/command.c: Likewise.
8240 * normal/completion.c: Likewise.
8241 * normal/execute.c: Likewise.
8242 * normal/function.c: Likewise.
8243 * normal/lexer.c: Likewise.
8244 * normal/main.c: Likewise.
8245 * normal/menu.c: Likewise.
8246 * normal/menu_entry.c: Likewise.
8247 * normal/misc.c: Likewise.
8248 * normal/parser.y: Likewise.
8249 * normal/script.c: Likewise.
8250 * normal/i386/setjmp.S: Likewise.
8251 * normal/powerpc/setjmp.S: Likewise.
8252 * normal/sparc64/setjmp.S: Likewise.
8253 * partmap/acorn.c: Likewise.
8254 * partmap/amiga.c: Likewise.
8255 * partmap/apple.c: Likewise.
8256 * partmap/gpt.c: Likewise.
8257 * partmap/pc.c: Likewise.
8258 * partmap/sun.c: Likewise.
8259 * term/gfxterm.c: Likewise.
8260 * term/terminfo.c: Likewise.
8261 * term/efi/console.c: Likewise.
8262 * term/i386/pc/console.c: Likewise.
8263 * term/i386/pc/serial.c: Likewise.
8264 * term/i386/pc/vesafb.c: Likewise.
8265 * term/i386/pc/vga.c: Likewise.
8266 * term/ieee1275/ofconsole.c: Likewise.
8267 * util/biosdisk.c: Likewise.
8268 * util/console.c: Likewise.
8269 * util/genmoddep.c: Likewise.
8270 * util/getroot.c: Likewise.
8271 * util/grub-emu.c: Likewise.
8272 * util/grub-mkdevicemap.c: Likewise.
8273 * util/grub-probe.c: Likewise.
8274 * util/lvm.c: Likewise.
8275 * util/misc.c: Likewise.
8276 * util/raid.c: Likewise.
8277 * util/resolve.c: Likewise.
8278 * util/update-grub.in: Likewise.
8279 * util/update-grub_lib.in: Likewise.
8280 * util/grub.d/00_header.in: Likewise.
8281 * util/grub.d/10_hurd.in: Likewise.
8282 * util/grub.d/10_linux.in: Likewise.
8283 * util/i386/efi/grub-install.in: Likewise.
8284 * util/i386/efi/grub-mkimage.c: Likewise.
8285 * util/i386/pc/grub-install.in: Likewise.
8286 * util/i386/pc/grub-mkimage.c: Likewise.
8287 * util/i386/pc/grub-mkrescue.in: Likewise.
8288 * util/i386/pc/grub-setup.c: Likewise.
8289 * util/i386/pc/misc.c: Likewise.
8290 * util/powerpc/ieee1275/grub-install.in: Likewise.
8291 * util/powerpc/ieee1275/grub-mkimage.c: Likewise.
8292 * util/powerpc/ieee1275/misc.c: Likewise.
8293 * video/bitmap.c: Likewise.
8294 * video/video.c: Likewise.
8295 * video/i386/pc/vbe.c: Likewise.
8296 * video/i386/pc/vbeblit.c: Likewise.
8297 * video/i386/pc/vbefill.c: Likewise.
8298 * video/i386/pc/vbeutil.c: Likewise.
8299 * video/readers/tga.c: Likewise.
8300
8301 2007-07-02 Robert Millan <rmh@aybabtu.com>
8302
8303 * conf/i386-efi.rmk: Replace obsolete reference to
8304 util/i386/pc/biosdisk.c with util/biosdisk.c, and util/i386/pc/getroot.c
8305 with util/getroot.c.
8306 * conf/powerpc-ieee1275.rmk: Likewise.
8307 * conf/sparc64-ieee1275.rmk: Likewise.
8308
8309 * util/grub-emu.c (main): Fix unchecked pointer handling.
8310
8311 2007-07-02 Robert Millan <rmh@aybabtu.com>
8312
8313 * util/i386/efi/grub-install.in: Allow `grub_probe --target=partmap'
8314 invocation to fail, in order to support partition-less media.
8315
8316 * util/i386/pc/grub-install.in: Likewise.
8317
8318 * util/powerpc/ieee1275/grub-install.in: Use grub-probe to determine
8319 which fs or partmap modules are needed (akin to its sister scripts).
8320
8321 Also use grub-probe to get rid of unportable /proc/mounts check.
8322
8323 Print the same informational message that the other scripts do, before
8324 exiting.
8325
8326 2007-06-23 Robert Millan <rmh@aybabtu.com>
8327
8328 * util/update-grub_lib.in (font_path): New function. Determine whether
8329 a font file can be found and, if so, echo the GRUB path to it.
8330
8331 * util/update-grub.in: Handle multiple terminals depending on user
8332 input, platform availability and font file presence. Propagate
8333 variables of our findings to /etc/grub.d/ children.
8334
8335 * util/grub.d/00_header.in: Handle multiple terminals, based on
8336 environment setup by update-grub.
8337
8338 2007-06-23 Robert Millan <rmh@aybabtu.com>
8339
8340 * conf/i386-pc.rmk (pkgdata_MODULES): Add serial.mod.
8341
8342 2007-06-21 Robert Millan <rmh@aybabtu.com>
8343
8344 * include/grub/i386/pc/kernel.h: Define GRUB_KERNEL_MACHINE_DATA_END to
8345 indicate end of data section in kernel image.
8346 * include/grub/i386/efi/kernel.h: Define GRUB_KERNEL_MACHINE_PREFIX and
8347 GRUB_KERNEL_MACHINE_DATA_END.
8348
8349 * kern/i386/pc/startup.S: Do not initialize grub_prefix, only reserve
8350 space for it.
8351 * kern/i386/efi/startup.S: Likewise.
8352
8353 * util/i386/pc/grub-mkimage.c: Initialize grub_prefix to /boot/grub
8354 during image generation. Implement --prefix option to override this
8355 patch.
8356 * util/i386/efi/grub-mkimage.c: Likewise.
8357
8358 * util/update-grub_lib.in (convert_system_path_to_grub_path): Split
8359 code to make path relative to its root into a separate function.
8360
8361 * util/i386/pc/grub-install.in: Use newly provided
8362 make_system_path_relative_to_its_root() to convert ${grubdir}, then
8363 pass the result to grub-install --prefix.
8364
8365 2007-06-13 Robert Millan <rmh@aybabtu.com>
8366
8367 * include/grub/util/misc.h: Define DEFAULT_DIRECTORY and
8368 DEFAULT_DEVICE_MAP.
8369 * util/grub-emu.c: Use above definitions from misc.h instead of
8370 defining them.
8371 * util/grub-mkdevicemap.c: Likewise.
8372 * util/i386/pc/grub-setup.c: Likewise.
8373 * util/grub-probe.c: Likewise.
8374 (probe): Abort with grub_util_error() when either
8375 grub_guess_root_device or grub_util_get_grub_dev fails.
8376
8377 2007-06-12 Robert Millan <rmh@aybabtu.com>
8378
8379 * normal/command.c (grub_command_execute): Use NULL rather than 0 for
8380 "pager" assignment.
8381 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Likewise for
8382 "pcdata".
8383 * util/grub-probe.c (probe): Likewise for "drive_name".
8384
8385 2007-06-11 Robert Millan <rmh@aybabtu.com>
8386
8387 * util/i386/pc/grub-mkrescue.in: Pad both floppy images with zeroes,
8388 not just the cdrom one.
8389
8390 2007-06-11 Robert Millan <rmh@aybabtu.com>
8391
8392 * util/i386/pc/grub-mkrescue.in: Add "set -e".
8393 Add --pkglibdir=DIR option to override pkglibdir.
8394 Mention --image-type=TYPE in help output.
8395 Fix --grub-mkimage (it was a no-op).
8396 Abort gracefully when no parameter is given.
8397
8398 2007-06-11 Robert Millan <rmh@aybabtu.com>
8399
8400 * util/i386/pc/grub-mkrescue.in: New file.
8401 * conf/i386-pc.rmk: Add its build declarations. Put it in bin_SCRIPTS.
8402 * Makefile.in: Handle bin_SCRIPTS.
8403
8404 2007-06-10 Vesa Jaaskelainen <chaac@nic.fi>
8405
8406 * term/gfxterm.c (grub_gfxterm_init): Added support for specifying
8407 list of video modes.
8408
8409 2007-06-06 Robert Millan <rmh@aybabtu.com>
8410
8411 * util/update-grub_lib.in (convert_system_path_to_grub_path): Abort if
8412 file doesn't exist, or if it is in a filesystem grub can't read.
8413
8414 * util/update-grub.in: Set fallback for GRUB_FS check to "unknown". Do
8415 not abort if GRUB_DRIVE could not be defined. Rearrange generated
8416 header comment to fit in 80 columns when the variables are resolved.
8417
8418 * util/grub.d/00_header.in: Only set root variable when GRUB_DRIVE
8419 could be identified by update-grub. Remove redundant check for
8420 unifont.pff existence (since convert_system_path_to_grub_path now
8421 handles that).
8422
8423 2007-06-04 Robert Millan <rmh@aybabtu.com>
8424
8425 * conf/i386-efi.rmk (grub_probe_SOURCES): Add partmap/apple.c.
8426
8427 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise.
8428
8429 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add partmap/pc.c.
8430
8431 2007-06-04 Robert Millan <rmh@aybabtu.com>
8432
8433 * conf/powerpc-ieee1275.rmk: Enable grub-mkdevicemap and grub-probe.
8434
8435 * include/grub/partition.h: Declare grub_apple_partition_map_init and
8436 grub_apple_partition_map_fini.
8437
8438 * util/biosdisk.c
8439 (grub_util_biosdisk_open): Replace BLKGETSIZE with BLKGETSIZE64 (needed
8440 to access >2 TiB disks).
8441
8442 Print disk->total_sectors with %llu instead of %lu, since this
8443 variable is always 64-bit (prevents wrong disk size from being displayed
8444 on either >2 TiB disk or big-endian CPU).
8445
8446 (grub_util_biosdisk_get_grub_dev): Convert gpt_partition_map handling
8447 into a generic case that supports all (sane) partition maps.
8448
8449 Stop using grub_cpu_to_le32() on dos_part / bsd_part since it actually
8450 breaks big-endian.
8451
8452 * util/grub-probe.c: Call grub_apple_partition_map_init() before probe()
8453 and grub_apple_partition_map_fini() after that.
8454
8455 2007-06-01 Robert Millan <rmh@aybabtu.com>
8456
8457 * util/update-grub.in: Export GRUB_CMDLINE_LINUX.
8458
8459 * util/grub.d/00_header.in: Only enable gfxterm when
8460 convert_system_path_to_grub_path() succeeds.
8461
8462 2007-05-20 Robert Millan <rmh@aybabtu.com>
8463
8464 * util/update-grub_lib.in: New file.
8465 * DISTLIST: Add update-grub_lib.in.
8466 * conf/common.rmk: Generate update-grub_lib and install it in
8467 $(lib_DATA).
8468 * Makefile.in: Add install routine for $(lib_DATA).
8469
8470 * util/grub.d/00_header.in: Use convert_system_path_to_grub_path()
8471 function provided by update-grub_lib to support arbitrary paths of
8472 unifont.pff.
8473 * util/update-grub.in: Use convert_system_path_to_grub_path() to
8474 initialize GRUB_DRIVE_BOOT and GRUB_DRIVE_BOOT_GRUB variables.
8475
8476 2007-05-19 Robert Millan <rmh@aybabtu.com>
8477
8478 * commands/i386/cpuid.c: New module.
8479 * DISTLIST: Add it.
8480 * conf/i386-efi.rmk: Enable cpuid.mod.
8481 * conf/i386-pc.rmk: Likewise.
8482
8483 2007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
8484
8485 * kern/disk.c (grub_disk_read): Check return value of
8486 grub_realloc().
8487
8488 2007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
8489
8490 * util/getroot.c (grub_util_get_grub_dev): Support partitionable
8491 arrays.
8492 * disk/raid.c (grub_raid_open): Likewise.
8493
8494 2007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
8495
8496 * util/biosdisk.c (linux_find_partition): Allocate real_dev on the
8497 stack instead of on the heap.
8498
8499 * kern/disk.c (grub_disk_read): Make sure tmp_buf is big enough
8500 before doing a read on it.
8501
8502 * configure.ac: Only use -fno-stack-protector for the target
8503 environment.
8504
8505 2007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
8506
8507 * video/i386/pc/vbe.c (grub_video_vbe_create_render_target): Add
8508 __attribute_ ((unused)) to mode_type argument.
8509
8510 * util/getroot.c (grub_guess_root_device): Fix #endif.
8511
8512 * kern/misc.c (memcmp): Fix prototype.
8513
8514 * include/grub/partition.h [GRUB_UTIL]
8515 (grub_gpt_partition_map_init): Add prototype.
8516 (grub_gpt_partition_map_fini): Likewise.
8517
8518 * fs/jfs.c (struct grub_jfs_inode): Put __attribute__ ((packed)
8519 at the right place.
8520
8521 * fs/fat.c (grub_fat_mount): Replace ~0UL with ~0U.
8522 (grub_fat_read_data): Likewise.
8523 (grub_fat_find_dir): Likewise.
8524
8525 * font/manager.c (find_glyph): Make table a const.
8526 (grub_font_get_glyph): Remove bitmap from if statement.
8527
8528 2007-05-16 Jeroen Dekkers <jeroen@dekkers.cx>
8529
8530 * util/getroot.c (grub_guess_root_device): Remove RAID and LVM
8531 code, first search for device in /dev/mapper, then in /dev.
8532 (grub_util_get_grub_dev): New function.
8533 * include/grub/util/getroot.h (grub_util_get_grub_dev): Add
8534 prototype.
8535 * util/grub-probe.c (probe): Remove check for RAID, call
8536 grub_util_get_grub_dev() instead of
8537 grub_util_biosdisk_get_grub_dev().
8538 * util/grub-emu.c (main): Call grub_util_get_grub_dev() instead of
8539 grub_util_biosdisk_get_grub_dev().
8540 * util/i386/pc/grub-setup.c (main): Likewise.
8541
8542 2007-05-16 Robert Millan <rmh@aybabtu.com>
8543
8544 * DISTLIST: Update for the latest changes.
8545 * conf/i386-pc.rmk: Use the new paths for util/getroot.c,
8546 util/grub-mkdevicemap.c, util/grub-probe.c and util/biosdisk.c.
8547 * util/grub-emu.c: Replace grub/i386/pc/util/biosdisk.h with
8548 grub/util/biosdisk.h.
8549 * util/i386/pc/grub-setup.c: Replace grub/machine/util/biosdisk.h with
8550 grub/util/biosdisk.h.
8551
8552 2007-05-16 Robert Millan <rmh@aybabtu.com>
8553
8554 * util/grub.d/00_header.in: Set default gfxmode to `640x480'.
8555
8556 2007-05-16 Robert Millan <rmh@aybabtu.com>
8557
8558 * util/i386/efi/grub-install.in: New.
8559 * conf/i386-efi.rmk: Enable grub-mkdevicemap, grub-probe and the
8560 newly added grub-install.
8561 * util/biosdisk.c: Remove unnecessary grub/machine/biosdisk.h
8562 include.
8563 * util/getroot.c: Replace grub/i386/pc/util/biosdisk.h with
8564 grub/util/biosdisk.h.
8565 * util/grub-probe.c: Replace grub/machine/util/biosdisk.h with
8566 grub/util/biosdisk.h.
8567
8568 2007-05-16 Robert Millan <rmh@aybabtu.com>
8569
8570 * include/grub/i386/pc/util/biosdisk.h: Moved to ...
8571 * include/grub/util/biosdisk.h: ... here.
8572 * util/i386/pc/biosdisk.c: Moved to ...
8573 * util/biosdisk.c: ... here.
8574 * util/i386/pc/getroot.c: Moved to ...
8575 * util/getroot.c: ... here.
8576 * util/i386/pc/grub-mkdevicemap.c: Moved to ...
8577 * util/grub-mkdevicemap.c: ... here.
8578 * util/i386/pc/grub-probe.c: Moved to ...
8579 * util/grub-probe.c: ... here.
8580
8581 2007-05-15 Robert Millan <rmh@aybabtu.com>
8582
8583 * util/update-grub.in: Remove duplicated line in grub.cfg header
8584 message.
8585
8586 2007-05-13 Robert Millan <rmh@aybabtu.com>
8587
8588 * util/update-grub.in: Fix a few assumptions about the devices holding
8589 /, /boot and /boot/grub being the same.
8590 * util/grub.d/00_header.in: Likewise.
8591 * util/grub.d/10_hurd.in: Likewise.
8592 * util/grub.d/10_linux.in: Likewise.
8593
8594 * util/grub.d/10_linux.in: Implement Linux image sorting with arbitrary
8595 patterns. Use that to define the `.old' suffix as older than `'.
8596
8597 * util/grub.d/00_header.in: Set default gfxmode to `800x600x16'.
8598
8599 * util/update-grub.in: Add a reference to ${sysconfdir}/default/grub in
8600 the grub.cfg header message.
8601
8602 2007-05-11 Robert Millan <rmh@aybabtu.com>
8603
8604 * util/update-grub.in: Create device.map if it doesn't already exist,
8605 before attempting to run grub-probe.
8606 Check for grub-probe and grub-mkdevicemap with the same code
8607 grub-install is using.
8608 Remove test mode.
8609
8610 2007-05-09 Jeroen Dekkers <jeroen@dekkers.cx>
8611
8612 * Makefile.in: Add the datarootdir autoconf variable.
8613
8614 2007-05-09 Robert Millan <rmh@aybabtu.com>
8615
8616 * util/i386/pc/grub-probe.c (probe): When detecting partition map,
8617 fail gracefully if dev->disk->partition == NULL.
8618
8619 2007-05-07 Robert Millan <rmh@aybabtu.com>
8620
8621 * util/i386/pc/grub-probe.c: Add `grub-probe -t partmap' parameter to
8622 determine partition map module.
8623 * util/i386/pc/grub-install.in: Use this feature to decide which
8624 partition module to load, instead of hardcoding pc and gpt.
8625
8626 2007-05-07 Robert Millan <rmh@aybabtu.com>
8627
8628 * Makefile.in: Fix assumption that $(srcdir) has a trailing slash when
8629 source directory differs from build directory.
8630
8631 2007-05-05 Robert Millan <rmh@aybabtu.com>
8632
8633 * util/powerpc/ieee1275/grub-install.in: Fix syntax error in pkglibdir
8634 initialisation.
8635
8636 2007-05-05 Robert Millan <rmh@aybabtu.com>
8637
8638 * util/update-grub.in: Create ${grub_prefix} if it doesn't exist.
8639
8640 2007-05-05 Robert Millan <rmh@aybabtu.com>
8641
8642 * util/grub.d/10_linux.in: Allow the administrator to insert Linux
8643 command-line arguments via ${GRUB_CMDLINE_LINUX}.
8644
8645 2007-05-05 Robert Millan <rmh@aybabtu.com>
8646
8647 * conf/i386-pc.rmk (grub_setup_SOURCES): Add partmap/gpt.c.
8648 (grub_probe_SOURCES): Likewise.
8649 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): Detect
8650 GPT and initialize dos_part and bsd_part accordingly.
8651 * util/i386/pc/grub-setup.c (setup): Ditto for install_dos_part and
8652 install_bsd_part.
8653 (main): Activate gpt module for use during partition identification,
8654 and deactivate it afterwards.
8655 * util/i386/pc/grub-install.in: Add gpt module to core.img.
8656 * util/i386/pc/grub-probe.c (main): Activate gpt module for use during
8657 partition identification, and deactivate it afterwards.
8658
8659 2007-05-05 Robert Millan <rmh@aybabtu.com>
8660
8661 * term/i386/pc/console.c (grub_console_fini): Call
8662 grub_term_set_current() before grub_term_unregister().
8663
8664 2007-05-04 Robert Millan <rmh@aybabtu.com>
8665
8666 * DISTLIST: Add util/update-grub.in, util/grub.d/00_header.in,
8667 util/grub.d/10_hurd.in, util/grub.d/10_linux.in and util/grub.d/README.
8668 * Makefile.in: Build update-grub_SCRIPTS. Install update-grub_SCRIPTS
8669 and update-grub_DATA.
8670 * conf/common.rmk: Build and install update-grub components.
8671 * conf/common.mk: Regenerate.
8672 * util/update-grub.in: New. Core of update-grub.
8673 * util/grub.d/00_header.in: New. Generates grub.cfg header.
8674 * util/grub.d/10_hurd.in: New. Generates boot entries for the Hurd.
8675 * util/grub.d/10_linux.in: New. Generates boot entries for Linux.
8676 * util/grub.d/README: New. Document grub.d directory layout.
8677
8678 2007-05-01 Robert Millan <rmh@aybabtu.com>
8679
8680 * util/grub-emu.c: Move initialization functions
8681 grub_util_biosdisk_init() and grub_init_all() before
8682 grub_util_biosdisk_get_grub_dev(), which relies on them.
8683
8684 2007-04-19 Robert Millan <rmh@aybabtu.com>
8685
8686 * util/powerpc/ieee1275/grub-install.in: Initialize ${bindir}, since
8687 it is used later.
8688
8689 2007-04-18 Jerone Young <jerone@gmail.com>
8690
8691 * kernel/elf.c: Add missing parenthesis for conditional statement
8692 stanza.
8693
8694 2007-04-10 Jerone Young <jerone@gmail.com>
8695
8696 * util/i386/pc/getroot.c: Update so that if root device is /dev/root ,
8697 continue on and look for device node with real device name.
8698
8699 2007-04-10 Jerone Young <jerone@gmail.com>
8700
8701 * configure.ac: Add argument for autoconf to use transformation
8702 ability.
8703 * Makefile.in: Add autoconf package transformation code.
8704 * util/i386/pc/grub-install.in: Likewise.
8705 * util/powerpc/ieee1275/grub-install.in: Likewise.
8706
8707 2007-03-19 Yoshinori K. Okuji <okuji@enbug.org>
8708
8709 * fs/ext2.c (EXT2_GOOD_OLD_REVISION): New macro.
8710 (EXT2_GOOD_OLD_INODE_SIZE): Likewise.
8711 (EXT2_REVISION): Likewise.
8712 (EXT2_INODE_SIZE): Likewise.
8713 (struct grub_ext2_block_group): Added a missing member
8714 "used_dirs".
8715 (grub_ext2_read_inode): Divide by the inode size in a superblock
8716 instead of 128 to obtain INODES_PER_BLOCK.
8717 Use the macro EXT2_INODE_SIZE instead of directly using
8718 SBLOCK->INODE_SIZE.
8719
8720 2007-03-18 Yoshinori K. Okuji <okuji@enbug.org>
8721
8722 * fs/ext2.c (grub_ext2_read_inode): Use the inode size in a
8723 superblock instead of the structure size to compute an
8724 offset. This fixes the problem that GRUB could not read a
8725 filesystem when inode size is different from 128-byte.
8726
8727 2007-03-05 Marco Gerards <marco@gnu.org>
8728
8729 * normal/main.c (read_config_file): When "menu" is not set, create
8730 an initial context.
8731
8732 2007-02-21 Hollis Blanchard <hollis@penguinppc.org>
8733
8734 * kern/powerpc/ieee1275/init.c (HEAP_SIZE): Removed.
8735 (HEAP_LIMIT): New macro.
8736 (grub_claim_heap): Claim memory up to `heaplimit'.
8737
8738 2007-02-21 Hollis Blanchard <hollis@penguinppc.org>
8739
8740 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Link at 64KB.
8741 * kern/powerpc/ieee1275/init.c (_end): Add declaration.
8742 (_start): Likewise.
8743 (grub_arch_modules_addr): Return address after `_end'.
8744 * util/powerpc/ieee1275/grub-mkimage.c: Include grub/misc.h.
8745 (load_modules): Use new parameter as `p_paddr' and `p_vaddr'.
8746 (add_segments): Calculate `_end' from phdr size and location.
8747 (ALIGN_UP): Moved to ...
8748 * include/grub/misc.h: here.
8749 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
8750 New macro.
8751 (GRUB_IEEE1275_MODULE_BASE): Removed.
8752
8753 2007-02-20 Hollis Blanchard <hollis@penguinppc.org>
8754
8755 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Correct
8756 loop boundary.
8757
8758 2007-02-20 Hollis Blanchard <hollis@penguinppc.org>
8759
8760 * include/grub/elfload.h (grub_elf32_load_hook_t): Return grub_err_t.
8761 All users updated.
8762 (grub_elf64_load_hook_t): Likewise.
8763 * kern/elf.c: Call `grub_error_push' before `grub_error'. Improve
8764 debug output.
8765
8766 2007-02-20 Hollis Blanchard <hollis@penguinppc.org>
8767
8768 * kern/mm.c: Update copyright.
8769 (grub_mm_debug): Correct syntax error.
8770 (grub_mm_dump_free): New function.
8771 (grub_debug_free): Call `grub_free'.
8772 * include/grub/mm.h: Update copyright.
8773 (grub_mm_dump_free): Add declaration.
8774
8775 2007-02-12 Hollis Blanchard <hollis@penguinppc.org>
8776
8777 * include/grub/ieee1275/ieee1275.h: Update copyright.
8778 * kern/powerpc/ieee1275/init.c: Likewise.
8779 * kern/powerpc/ieee1275/openfw.c: Likewise.
8780
8781 * loader/powerpc/ieee1275/linux.c: Likewise.
8782 * include/grub/elfload.h: Likewise.
8783 * kern/elf.c: Likewise.
8784 (grub_elf32_load): Pass `base' and `size' parameters. Update all
8785 callers.
8786 (grub_elf64_load): Likewise.
8787 (grub_elf32_load_segment): Move to a nested function.
8788 (grub_elf64_load_segment): Likewise.
8789
8790 2007-02-12 Hollis Blanchard <hollis@penguinppc.org>
8791
8792 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): New
8793 prototype.
8794 * kern/powerpc/ieee1275/init.c (grub_heap_start): Removed.
8795 (grub_heap_len): Likewise.
8796 (HEAP_SIZE): New macro.
8797 (grub_claim_heap): New function.
8798 (grub_machine_init): Don't claim heap directly. Call
8799 `grub_claim_heap'.
8800 * kern/powerpc/ieee1275/openfw.c: Include alloca.h.
8801 (grub_available_iterate): New function.
8802
8803 2007-02-03 Thomas Schwinge <tschwinge@gnu.org>
8804
8805 * aclocal.m4 (grub_CHECK_STACK_PROTECTOR): New definition.
8806 * configure.ac: Use it for testing the HOST and TARGET compilers.
8807
8808 2006-12-13 Thomas Schwinge <tschwinge@gnu.org>
8809
8810 * Makefile.in (enable_grub_emu): New variable.
8811 * configure.ac (--enable-grub-emu): New option.
8812 Do the checks for (n)curses only if `--enable-grub-emu' is requested.
8813 * conf/i386-efi.rmk (sbin_UTILITIES): Add `grub-emu' only if requested.
8814 * conf/i386-pc.rmk: Likewise.
8815 * conf/powerpc-ieee1275.rmk: Likewise.
8816 * conf/sparc64-ieee1275.rmk (bin_UTILITIES): Likewise.
8817
8818 2006-12-12 Marco Gerards <marco@gnu.org>
8819
8820 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_MENU'.
8821
8822 * kern/env.c (grub_env_unset): Don't free the member `value' when
8823 the type is GRUB_ENV_VAR_DATA, in this case it's a user defined
8824 pointer.
8825
8826 * normal/main.c (current_menu): Removed.
8827 (free_menu): Unset the `menu' environment variable.
8828 (grub_normal_menu_addentry): Make use of the environment variable
8829 `menu', instead of using the global `current_menu'. Allocate
8830 memory for the sourcecode of this entry.
8831 (read_config_file): New argument `nested', changed all callers.
8832 Only in the case of a new context, initialize a new menu. Set the
8833 `menu' environment variable.
8834 (grub_normal_execute): Don't set and unset the environment
8835 variable `menu' here anymore. Only free the menu when leaving the
8836 context.
8837
8838 * util/i386/pc/biosdisk.c (linux_find_partition): Fixed a memory
8839 leak.
8840
8841 2006-12-11 Marco Gerards <marco@gnu.org>
8842
8843 * normal/menu_entry.c (run): Fix off by one bug so the last line
8844 is executed. Move the loader check to outside the loop.
8845
8846 2006-12-08 Hollis Blanchard <hollis@penguinppc.org>
8847
8848 * kern/powerpc/ieee1275/cmain.c (cmain): Mark r3 and r4 as `UNUSED'.
8849
8850 2006-11-25 Yoshinori K. Okuji <okuji@enbug.org>
8851
8852 * util/i386/pc/grub-mkimage.c (generate_image): Fix the offset of
8853 the number of sectors. Reported by Andrey Shuvikov
8854 <mr_hyro@yahoo.com>.
8855
8856 2006-11-11 Jeroen Dekkers <jeroen@dekkers.cx>
8857
8858 * kern/disk.c (grub_disk_read): When there is a read error, always
8859 try to read only the necessary data.
8860
8861 * conf/i386-pc.rmk (grub_probe_SOURCES): Add disk/lvm.c and
8862 disk/raid.c.
8863 * include/grub/disk.h [GRUB_UTIL] (grub_raid_init): New
8864 prototype.
8865 [GRUB_UTIL] (grub_raid_fini): Likewise.
8866 [GRUB_UTIL] (grub_lvm_init): Likewise.
8867 [GRUB_UTIL] (grub_lvm_fini): Likewise.
8868 * util/i386/pc/grub-probe.c (probe): Check whether DEVICE_NAME is
8869 RAID device and copy DEVICE_NAME to DRIVE_NAME in that case.
8870 (main): Call grub_raid_init(), grub_lvm_init(), grub_lvm_fini()
8871 and grub_raid_fini().
8872
8873 2006-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
8874
8875 * include/grub/types.h (__unused): Rename to UNUSED.
8876 * kern/elf.c (grub_elf32_size): Use UNUSED instead of __unused.
8877 (grub_elf64_size): Likewise.
8878
8879 2006-11-03 Hollis Blanchard <hollis@penguinppc.org>
8880
8881 * kern/elf.c (grub_elf_file): Call grub_file_seek. Call
8882 grub_error_push and grub_error_pop in the error-handling path.
8883 (grub_elf32_load_segment): Only call grub_file_read with non-zero
8884 length.
8885
8886 2006-11-03 Hollis Blanchard <hollis@penguinppc.org>
8887
8888 * conf/i386-efi.rmk (grub_emu_SOURCES): Add kern/elf.c.
8889 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
8890 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8891 (kernel_elf_SOURCES): Likewise.
8892 * conf/i386-efi.rmk (kernel_mod_HEADERS): Add elfload.h and cache.h.
8893 * conf/i386-pc.rmk (kernel_mod_HEADERS): Likewise.
8894 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
8895 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
8896 * conf/common.rmk (pkgdata_MODULES): Add elf.mod.
8897 (elf_mod_SOURCES): New variable.
8898 (elf_mod_CFLAGS): Likewise.
8899 (elf_mod_LDFLAGS): Likewise.
8900 * include/grub/types.h (__unused): New macro.
8901 * include/grub/elfload.h: New file.
8902 * kern/elf.c: Likewise.
8903 * loader/powerpc/ieee1275/linux.c: Include elfload.h.
8904 (ELF32_LOADMASK): New macro.
8905 (ELF64_LOADMASK): Likewise.
8906 (vmlinux): Removed.
8907 (grub_linux_load32): New function.
8908 (grub_linux_load64): Likewise.
8909 (grub_rescue_cmd_linux): Call grub_linux_load32 or grub_linux_load64.
8910 Use grub_elf_t instead of grub_file_t.
8911
8912 2006-11-02 Hollis Blanchard <hollis@penguinppc.org>
8913
8914 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): Add
8915 `catch_result' to struct set_color_args.
8916
8917 2006-10-28 Yoshinori K. Okuji <okuji@enbug.org>
8918
8919 * normal/menu.c: Include grub/script.h.
8920 * normal/menu_entry.c: Likewise.
8921 * include/grub/normal.h: Do not include grub/script.h.
8922
8923 2006-10-27 Hollis Blanchard <hollis@penguinppc.org>
8924
8925 * kern/disk.c (grub_disk_read): Correct debug printf formatting.
8926
8927 2006-10-27 Hollis Blanchard <hollis@penguinppc.org>
8928
8929 * kern/disk.c (grub_disk_open): Print debug messages when opening a
8930 disk.
8931 (grub_disk_close): Print debug messages when closing a disk.
8932 (grub_disk_read): Print debug messages when disk read fails.
8933 * kern/fs.c (grub_fs_probe): Print debug messages when detecting
8934 filesystem type.
8935 * kern/partition.c: Include misc.h.
8936 (grub_partition_iterate): Print debug messages when detecting
8937 partition type.
8938
8939 2006-10-27 Hollis Blanchard <hollis@penguinppc.org>
8940
8941 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Return error if `status'
8942 is negative.
8943 * kern/ieee1275/ieee1275.c (IEEE1275_IHANDLE_INVALID): Change to 0.
8944
8945 2006-10-26 Hollis Blanchard <hollis@penguinppc.org>
8946
8947 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
8948 Reverse GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS test.
8949
8950 2006-10-25 Jeroen Dekkers <jeroen@dekkers.cx>
8951
8952 * disk/lvm.c (grub_lvm_scan_device): Malloc sizeof(*lv) bytes
8953 instead of sizeof(lv). Patch by Michael Guntsche.
8954
8955 2006-10-18 Jeroen Dekkers <jeroen@dekkers.cx>
8956
8957 * disk/lvm.c: Rename VGS to VG_LIST.
8958 (grub_lvm_iterate): Change VGS->LV to VG-LV.
8959 (grub_lvm_open): Likewise.
8960 Thanks to Michael Guntsche for finding this bug.
8961
8962 2006-10-15 Yoshinori K. Okuji <okuji@enbug.org>
8963
8964 * configure.ac (AC_INIT): Bumped to 1.95.
8965
8966 2006-10-14 Robert Millan <rmh@aybabtu.com>
8967
8968 * util/i386/pc/getroot.c (grub_guess_root_device): Don't compare os_dev
8969 with "/dev/.static/dev/md".
8970
8971 2006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
8972
8973 * util/i386/pc/grub-probe.c (probe): Print DEVICE_NAME instead of
8974 DRIVE_NAME when grub_util_biosdisk_get_grub_dev fails. Open
8975 DRIVE_NAME instead of DEVICE_NAME. Make sure that DEVICE_NAME and
8976 DRIVE_NAME are always freed.
8977
8978 * util/i386/pc/biosdisk.c (make_device_name): Add one into
8979 DOS_PART, as a DOS partition is counted from one instead of zero
8980 now. Reported by Robert Millan.
8981
8982 2006-10-14 Robert Millan <rmh@aybabtu.com>
8983
8984 * util/i386/pc/getroot.c (grub_guess_root_device): Stop using
8985 grub_util_biosdisk_get_grub_dev to convert system device to GRUB device.
8986 * util/grub-emu.c (main): Use grub_util_biosdisk_get_grub_dev with the
8987 string returned by grub_guess_root_device.
8988 * util/i386/pc/grub-setup.c: Likewise.
8989 * util/i386/pc/grub-probefs.c: Likewise.
8990
8991 * util/i386/pc/grub-probefs.c: Rename to ...
8992 * util/i386/pc/grub-probe.c: ... this.
8993 * DISTLIST: Remove grub-probefs, add grub-probe.
8994 * conf/i386-efi.rmk: Likewise.
8995 * conf/i386-pc.rmk: Likewise.
8996 * util/i386/pc/grub-install.in: Likewise.
8997
8998 * util/i386/pc/grub-probe.c: Add --target=(fs|device|drive) option to
8999 choose which information we want to print.
9000
9001 2006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
9002
9003 * DISTLIST: Added commands/echo.c, disk/lvm.c, disk/raid.c,
9004 include/grub/bitmap.h, include/grub/lvm.h, include/grub/raid.h,
9005 include/grub/i386/pc/vbeutil.h, include/grub/util/lvm.h,
9006 include/grub/util/raid.h, util/lvm.c, util/raid.c, video/bitmap.c,
9007 video/readers/tga.c and video/i386/pc/vbeutil.c.
9008
9009 2006-10-14 Jeroen Dekkers <jeroen@dekkers.cx>
9010
9011 Added support for RAID and LVM.
9012
9013 * disk/lvm.c: New file.
9014 * disk/raid.c: Likewise.
9015 * include/grub/lvm.h: Likewise.
9016 * include/grub/raid.h: Likewise.
9017 * include/grub/util/lvm.h: Likewise.
9018 * include/grub/util/raid.h: Likewise.
9019 * util/lvm.c: Likewise.
9020 * util/raid.c: Likewise.
9021
9022 * include/grub/disk.h (grub_disk_dev_id): Add
9023 GRUB_DISK_DEVICE_RAID_ID and GRUB_DISK_DEVICE_LVM_ID.
9024 (grub_disk_get_size): New prototype.
9025 * kern/disk.c (grub_disk_open): Check whether grub_partition_probe()
9026 returns a partition.
9027 (grub_disk_get_size): New function.
9028
9029 * kern/i386/pc/init.c (make_install_device): Copy the prefix
9030 verbatim if grub_install_dos_part is -2.
9031
9032 * util/i386/pc/getroot.c (grub_guess_root_device): Support RAID
9033 and LVM devices.
9034
9035 * util/i386/pc/grub-setup.c (setup): New argument
9036 MUST_EMBED. Force embedding of GRUB when the argument is
9037 true. Close FILE before returning.
9038 (main): Add support for RAID and LVM.
9039
9040 * conf/common.rmk: Add RAID and LVM modules.
9041 * conf/i386-pc.rmk (grub_setup_SOURCES): Add util/raid.c and
9042 util/lvm.c.
9043 (grub_emu_SOURCES): Add disk/raid.c and disk/lvm.c.
9044
9045 * kern/misc.c (grub_strstr): New function.
9046 * include/grub/misc.h (grub_strstr): New prototype.
9047
9048 2006-10-10 Tristan Gingold <tristan.gingold@bull.net>
9049
9050 * include/grub/efi/api.h (GRUB_EFI_ERROR_CODE): Long constant.
9051
9052 2006-10-05 Tristan Gingold <tristan.gingold@bull.net>
9053
9054 * kern/misc.c (grub_strtoull): Guess the base only if not
9055 specified.
9056
9057 2006-10-01 Hollis Blanchard <hollis@penguinppc.org>
9058
9059 * kern/powerpc/ieee1275/cmain.c (cmain): Remove incomplete Old World
9060 PowerMac support.
9061
9062 2006-10-01 Hollis Blanchard <hollis@penguinppc.org>
9063
9064 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Cast `size' to long.
9065
9066 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_next_property):
9067 Remove `flags' argument. All callers changed.
9068 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_ROOT): Removed.
9069 (IEEE1275_IHANDLE_INVALID): New variable.
9070 (IEEE1275_CELL_INVALID): New variable.
9071 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
9072 grub_ieee1275_get_property_length, grub_ieee1275_instance_to_package,
9073 grub_ieee1275_package_to_path, grub_ieee1275_instance_to_path,
9074 grub_ieee1275_peer, grub_ieee1275_child, grub_ieee1275_open,
9075 grub_ieee1275_claim, grub_ieee1275_set_property): Error-check return
9076 codes from Open Firmware. All callers updated.
9077 (grub_ieee1275_next_property): Directly return Open Firmware return
9078 code.
9079 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
9080 Standardize error checking from `grub_ieee1275_get_property'.
9081 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Rename
9082 `devalias' to `aliases'. Correct comments. Consolidate error paths.
9083
9084 2006-10-01 Hollis Blanchard <hollis@penguinppc.org>
9085
9086 * kern/ieee1275/ieee1275.c (grub_ieee1275_instance_to_path): Rename
9087 `instance_to_package_args' to `instance_to_path_args'.
9088
9089 * kern/powerpc/ieee1275/init.c (grub_machine_init): Use
9090 `grub_ieee1275_chosen'.
9091
9092 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Call
9093 `grub_ieee1275_interpret'.
9094
9095 2006-09-25 Hollis Blanchard <hollis@penguinppc.org>
9096
9097 * util/powerpc/ieee1275/grub-mkimage.c: Include config.h.
9098
9099 2006-09-25 Hollis Blanchard <hollis@penguinppc.org>
9100
9101 * include/grub/powerpc/libgcc.h (__floatdisf): New prototype.
9102 (__cmpdi): Likewise.
9103
9104 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Pass 0 as
9105 `flags' to `grub_ieee1275_next_property'. Change `pathlen' to type
9106 `grub_ssize_t'.
9107
9108 * kern/powerpc/ieee1275/cmain.c: Include grub/misc.h.
9109
9110 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Change `actual'
9111 to type `grub_ssize_t'.
9112 (grub_rescue_cmd_linux): Cast -1 to `grub_off_t'.
9113
9114 2006-09-22 Marco Gerards <marco@gnu.org>
9115
9116 * normal/script.c (grub_script_create_cmdmenu): Skip leading
9117 newlines.
9118
9119 2006-09-22 Marco Gerards <marco@gnu.org>
9120
9121 * commands/echo.c: New file.
9122
9123 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/echo.c'.
9124
9125 * conf/common.rmk (echo_mod_SOURCES): New variable.
9126 (echo_mod_CFLAGS): Likewise.
9127 (echo_mod_LDFLAGS): Likewise.
9128
9129 2006-09-22 Marco Gerards <marco@gnu.org>
9130
9131 * normal/main.c (get_line): Malloc memory instead of using
9132 preallocated memory. Removed the arguments `cmdline' and
9133 `max_len'. Updated all callers.
9134
9135 2006-09-22 Marco Gerards <marco@gnu.org>
9136
9137 * conf/i386-efi.rmk (grub_emu_DEPENDENCIES): New variable.
9138 (normal_mod_DEPENDENCIES): Likewise.
9139
9140 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Likewise.
9141 (normal_mod_DEPENDENCIES): Likewise.
9142
9143 * conf/sparc64-ieee1275.rmk (normal_mod_DEPENDENCIES): Likewise.
9144
9145 2006-09-22 Johan Rydberg <jrydberg@gnu.org>
9146
9147 * genmk.rb: Add DEPENDENCIES variables to modules, utilities, and
9148 programs.
9149 * conf/i386-pc.rmk (grub_emu_DEPENDENCIES): Declare.
9150 (normal_mod_DEPENDENCIES): Likewise.
9151 * conf/i386-pc.mk: Regenerate.
9152 * conf/i386-efi.mk: Likewise
9153 * conf/common.mk: Likewise.
9154 * conf/powerpc-ieee1275.mk: Likewise.
9155 * conf/sparc64-ieee1275.mk: Likewise.
9156
9157 2006-09-22 Robert Millan <rmh@aybabtu.com>
9158
9159 Sync with i386 version.
9160 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Remove grub-emu, add grub-mkimage.
9161 * conf/powerpc-ieee1275.rmk (sbin_UTILITIES): Remove grub-mkimage, add grub-emu.
9162
9163 2006-09-21 Robert Millan <rmh@aybabtu.com>
9164
9165 Import from GRUB Legacy (lib/device.c):
9166 * util/i386/pc/grub-mkdevicemap.c (get_i2o_disk_name): New function.
9167 (init_device_map) [__linux__]: Add support for I2O devices.
9168
9169 2006-09-14 Marco Gerards <marco@gnu.org>
9170
9171 * conf/i386-pc.rmk (COMMON_LDFLAGS): Use `-m32' instead of
9172 `-melf_i386'.
9173
9174 2006-09-14 Robert Millan <rmh@aybabtu.com>
9175
9176 * util/i386/pc/grub-install.in: Skip menu.lst when removing
9177 /boot/grub/*.lst.
9178
9179 * util/i386/pc/getroot.c: Don't recurse into dotdirs (e.g. ".static").
9180
9181 * util/i386/pc/grub-mkdevicemap.c: Make sure the floppy device exists
9182 before adding it to device.map.
9183
9184 2006-08-15 Johan Rydberg <jrydberg@gnu.org>
9185
9186 * genmk.rb: Let GCC generate dependencies the first time it
9187 compiles a file; using the -MD option.
9188 * conf/common.mk: Regenerate.
9189 * conf/i386-pc.mk: Likewise.
9190 * conf/i386-efi.mk: Likewise.
9191 * conf/powerpc-ieee1275.mk: Likewise.
9192 * conf/sparc64-ieee1275.mk: Likewise.
9193
9194 2006-08-04 Yoshinori K. Okuji <okuji@enbug.org>
9195
9196 Move the prototypes of grub_setjmp and grub_longjmp to
9197 cpu/setjmp.h, so that each architecture may specify different
9198 attributes.
9199
9200 * include/grub/i386/setjmp.h (grub_setjmp): New prototype.
9201 (grub_longjmp): Likewise.
9202 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise..
9203 (grub_longjmp): Likewise.
9204 * include/grub/sparc64/setjmp.h (grub_setjmp): Likewise..
9205 (grub_longjmp): Likewise.
9206
9207 * include/grub/setjmp.h [!GRUB_UTIL] (grub_setjmp): Removed.
9208 [!GRUB_UTIL] (grub_longjmp): Removed.
9209
9210 2006-08-01 Pelletier Vincent <subdino2004@yahoo.fr>
9211
9212 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): IEEE1275
9213 "color!" method does not return any value.
9214
9215 2006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
9216
9217 * include/grub/bitmap.h: New file.
9218
9219 * include/grub/i386/pc/vbeutil.h: Likewise.
9220
9221 * video/bitmap.c: Likewise.
9222
9223 * video/readers/tga.c: Likewise.
9224
9225 * video/i386/pc/vbeutil.c: Likewise.
9226
9227 * commands/videotest.c: Code cleanup and updated to reflect to new
9228 video API.
9229
9230 * term/gfxterm.c: Likewise.
9231
9232 * video/video.c: Likewise.
9233
9234 * conf/i386-pc.rmk (pkgdata_MODULES): Added tga.mod and bitmap.mod.
9235 (vbe_mod_SOURCES): Added video/i386/pc/vbeutil.c.
9236 (bitmap_mod_SOURCES): New entry.
9237 (bitmap_mod_CFLAGS): Likewise.
9238 (bitmap_mod_LDFLAGS): Likewise.
9239 (tga_mod_SOURCES): Likewise.
9240 (tga_mod_CFLAGS): Likewise.
9241 (tga_mod_LDFLAGS): Likewise.
9242
9243 * include/grub/video.h (grub_video_blit_operators): New enum type.
9244 (grub_video_render_target): Changed as forward declaration and moved
9245 actual definition to be video driver specific.
9246 (grub_video_adapter.blit_bitmap): Added blitting operator.
9247 (grub_video_adapter.blit_render_target): Likewise.
9248 (grub_video_blit_bitmap): Likewise.
9249 (grub_video_blit_render_target): Likewise.
9250
9251 * include/grub/i386/pc/vbe.h (grub_video_render_target): Added
9252 driver specific render target definition.
9253 (grub_video_vbe_map_rgba): Added driver internal helper.
9254 (grub_video_vbe_unmap_color): Updated to use
9255 grub_video_i386_vbeblit_info.
9256 (grub_video_vbe_get_video_ptr): Likewise.
9257
9258 * include/grub/i386/pc/vbeblit.h
9259 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8): Updated to use
9260 grub_video_i386_vbeblit_info.
9261 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
9262 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
9263 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
9264 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
9265 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
9266 (grub_video_i386_vbeblit_index_index): Likewise.
9267 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): New blitter function.
9268 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
9269 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
9270 (grub_video_i386_vbeblit_blend): Added generic blitter for blend
9271 operator.
9272 (grub_video_i386_vbeblit_replace): Added generic blitter for replace
9273 operator.
9274
9275 * video/i386/pc/vbeblit.c: Updated to reflect changes on
9276 include/grub/i386/pc/vbeblit.h.
9277
9278 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8):
9279 Updated to use grub_video_i386_vbeblit_info.
9280 (grub_video_i386_vbefill_R8G8B8): Likewise.
9281 (grub_video_i386_vbefill_index): Likewise.
9282 (grub_video_i386_vbefill): Added generic filler.
9283
9284 * video/i386/pc/vbefill.c: Updated to reflect changes on
9285 include/grub/i386/pc/vbefill.h.
9286
9287 * video/i386/pc/vbe.c (grub_video_vbe_get_video_ptr): Updated to use
9288 grub_video_i386_vbeblit_info.
9289 (grub_video_vbe_unmap_color): Likewise.
9290 (grub_video_vbe_blit_glyph): Likewise.
9291 (grub_video_vbe_scroll): Likewise.
9292 (grub_video_vbe_draw_pixel): Removed function.
9293 (grub_video_vbe_get_pixel): Likewise.
9294 (grub_video_vbe_fill_rect): Moved all blitters to vbefill.c and
9295 updated code to use it.
9296 (common_blitter): Added common blitter for render target and bitmap.
9297 (grub_video_vbe_blit_bitmap): Updated to use common_blitter.
9298 (grub_video_vbe_blit_render_target): Likewise.
9299
9300 2006-07-30 Johan Rydberg <jrydberg@gnu.org>
9301
9302 * kern/efi/efi.c (grub_efi_set_text_mode): Assume console already
9303 is in text mode if there is no console control protocol instance
9304 available.
9305
9306 2006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
9307
9308 * include/grub/video.h: Code cleanup.
9309
9310 * include/grub/i386/pc/vbe.h: Likewise.
9311
9312 * video/i386/pc/vbe.c: Likewise.
9313
9314 * video/i386/pc/vbeblit.c: Likewise.
9315
9316 * video/i386/pc/vbefill.c: Likewise.
9317
9318 * video/video.c: Likewise. Also added more comments.
9319
9320 2006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
9321
9322 * disk/i386/pc/biosdisk.c (struct grub_biosdisk_drp): Moved to ...
9323 (struct grub_biosdisk_dap): Likewise.
9324
9325 * include/grub/i386/pc/biosdisk.h: ... to here. Also corrected
9326 linkage settings for all functions.
9327
9328 2006-07-12 Marco Gerards <marco@gnu.org>
9329
9330 * configure.ac (--enable-mm-debug): Fix typo.
9331
9332 * genkernsyms.sh.in: Use proper quoting for `CC'.
9333
9334 2006-07-02 Jeroen Dekkers <jeroen@dekkers.cx>
9335
9336 * conf/i386-pc.rmk (COMMON_ASFLAGS): Add "-m32".
9337 (normal_mod_ASFLAGS): Remove "-m32".
9338
9339 2006-06-14 Yoshinori K. Okuji <okuji@enbug.org>
9340
9341 * util/misc.c: Include config.h.
9342 [!HAVE_MEMALIGN]: Do not include malloc.h.
9343 (grub_memalign): Use posix_memalign, if present. Then, use
9344 memalign, if present. Otherwise, emit an error.
9345
9346 * util/grub-emu.c: Do not include malloc.h.
9347
9348 * include/grub/util/misc.h: Include unistd.h. This is required for
9349 FreeBSD, because off_t is defined in unistd.h. Reported by Harley
9350 D. Eades III <hde@foobar-qux.org>.
9351
9352 * configure.ac (AC_GNU_SOURCE): Added.
9353 (AC_CHECK_FUNCS): Check posix_memalign and memalign for the host
9354 type.
9355
9356 2006-06-09 Yoshinori K. Okuji <okuji@enbug.org>
9357
9358 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Make sure that
9359 ADDR_MAX does not exceed GRUB_LINUX_INITRD_MAX_ADDRESS.
9360
9361 2006-06-07 Jeroen Dekkers <jeroen@dekkers.cx>
9362
9363 * include/grub/types.h (grub_host_addr_t): Rename to
9364 grub_target_addr_t.
9365 (grub_host_off_t): Rename to grub_target_off_t.
9366 (grub_host_size_t): Rename to grub_target_size_t.
9367 (grub_host_ssize_t): Rename to grub_target_ssize_t.
9368 Refer to GRUB_TARGET_SIZEOF_VOID_P to define those variables.
9369
9370 * include/grub/kernel.h (struct grub_module_header): Change type
9371 of OFFSET to grub_target_off_t and type of SIZE to grub_target_size_t.
9372 (grub_module_info): Likewise.
9373
9374 2006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
9375
9376 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): The conditional
9377 of checking LINUX_MEM_SIZE was reverse. Reported by Jesus
9378 Velazquez <jesus.velazquez@gmail.com>.
9379
9380 2006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
9381
9382 Count partitions from 1 instead of 0 in the string representation
9383 of partitions. Still use 0-based internally.
9384
9385 * partmap/sun.c (grub_sun_is_valid): A cosmetic change.
9386 (sun_partition_map_iterate): Use grub_partition_t instead of
9387 struct grub_partition *. Cast DESC->START_CYLINDER to
9388 grub_uint64_t after converting the endian.
9389 (sun_partition_map_probe): Subtract 1 for PARTNUM.
9390 (sun_partition_map_get_name): Add 1 to P->INDEX.
9391
9392 * partmap/pc.c (grub_partition_parse): Subtract 1 for
9393 PCDATA->DOS_PART.
9394 (pc_partition_map_get_name): Add 1 into PCDATA->DOS_PART.
9395
9396 * partmap/gpt.c (gpt_partition_map_iterate): Initialize PARTNO to
9397 zero instead of one.
9398 (gpt_partition_map_probe): Subtract 1 for PARTNUM.
9399 (gpt_partition_map_get_name): Add 1 into P->INDEX.
9400
9401 * partmap/apple.c (apple_partition_map_iterate): Change the type
9402 of POS to unsigned.
9403 (apple_partition_map_probe): Subtract 1 for PARTNUM.
9404 (apple_partition_map_get_name): Add 1 into P->INDEX.
9405
9406 * partmap/amiga.c (amiga_partition_map_iterate): Change the type
9407 of POS to unsigned.
9408 (amiga_partition_map_iterate): Cast NEXT to grub_off_t to
9409 calculate the offset of a partition.
9410 (amiga_partition_map_probe): Subtract 1 for PARTNUM.
9411 (amiga_partition_map_get_name): Add 1 into P->INDEX.
9412
9413 * partmap/acorn.c (acorn_partition_map_find): Change the type of
9414 SECTOR to grub_disk_addr_t.
9415 (acorn_partition_map_iterate): Likewise.
9416 (acorn_partition_map_probe): Subtract 1 for PARTNUM.
9417 Change the type of SECTOR to grub_disk_addr_t. Declare P on the
9418 top.
9419 (acorn_partition_map_get_name): Add 1 into P->INDEX.
9420
9421 * kern/i386/pc/init.c (make_install_device): Add 1 into
9422 GRUB_INSTALL_DOS_PART.
9423
9424 * fs/iso9660.c (grub_iso9660_mount): Fixed a reversed
9425 conditional.
9426
9427 2006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
9428
9429 Clean up the code to support 64-bit addressing in disks and
9430 files. This change is not enough for filesystems yet.
9431
9432 * util/i386/pc/grub-setup.c (struct boot_blocklist): Change the
9433 type of "start" to grub_uint64_t.
9434 (setup): Change the types of KERNEL_SECTOR and FIRST_SECTOR to
9435 grub_disk_addr_t * and grub_disk_addr_t. Fix the format string in
9436 save_first_sector and save_blocklists. Use grub_le_to_cpu64 to
9437 convert addresses.
9438
9439 * util/i386/pc/biosdisk.c (open_device): Change the type of SECTOR
9440 to grub_disk_addr_t.
9441
9442 * partmap/gpt.c (gpt_partition_map_iterate): Fix the format
9443 string.
9444
9445 * partmap/pc.c (pc_partition_map_iterate): Likewise.
9446
9447 * partmap/amiga.c (amiga_partition_map_iterate): Cast RDSK.MAGIC
9448 to char *.
9449
9450 * normal/script.c (grub_script_parse): Remove unused MEMFREE.
9451
9452 * normal/parser.y (YYLTYPE_IS_TRIVIAL): New macro.
9453
9454 * normal/lexer.c (grub_script_yyerror): Specify unused to LEX.
9455
9456 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf64): Cast -1
9457 to grub_off_t, to detect an error from grub_file_seek.
9458 (grub_multiboot_load_elf32): Likewise.
9459
9460 * kern/misc.c (grub_strtoul): Use grub_strtoull. Return the
9461 maximum unsigned long value when an overflow is detected.
9462 (grub_strtoull): New function.
9463 (grub_divmod64): Likewise.
9464 (grub_lltoa): use grub_divmod64.
9465
9466 * kern/fs.c (struct grub_fs_block): Change the type of "offset" to
9467 grub_disk_addr_t.
9468 (grub_fs_blocklist_open): Increase P if P is not NULL to advance
9469 the pointer to next character. Use grub_strtoull instead of
9470 grub_strtoul.
9471 (grub_fs_blocklist_read): Change the types of SECTOR, OFFSET and
9472 SIZE to grub_disk_addr_t, grub_off_t and grub_size_t,
9473 respectively.
9474
9475 * kern/file.c (grub_file_read): Prevent an overflow of LEN, as the
9476 return value is signed.
9477 (grub_file_seek): Change the type of OLD to grub_off_t. Do not
9478 test if OFFSET is less than zero, as OFFSET is unsigned now.
9479
9480 * kern/disk.c (struct grub_disk_cache): Change the type of
9481 "sector" to grub_disk_addr_t.
9482 (grub_disk_cache_get_index): Change the type of SECTOR to
9483 grub_disk_addr_t. Calculate the hash with SECTOR casted to
9484 unsigned after shifting.
9485 (grub_disk_cache_invalidate): Change the type of SECTOR to
9486 grub_disk_addr_t.
9487 (grub_disk_cache_unlock): Likewise.
9488 (grub_disk_cache_store): Likewise.
9489 (grub_disk_check_range): Change the types of SECTOR, OFFSET, SIZE,
9490 START and LEN to grub_disk_addr_t *, grub_off_t *, grub_size_t,
9491 grub_disk_addr_t and grub_uint64_t, respectively.
9492 (grub_disk_read): Use an unsigned variable REAL_OFFSET for the
9493 body, as the value of OFFSET is tweaked by
9494 grub_disk_check_range. Change the types of START_SECTOR, LEN and
9495 POS to grub_disk_addr_t, grub_size_t and grub_size_t,
9496 respectively.
9497 (grub_disk_write): Use an unsigned variable REAL_OFFSET for the
9498 body, as the value of OFFSET is tweaked by
9499 grub_disk_check_range. Change the types of LEN and N to
9500 grub_size_t.
9501
9502 * io/gzio.c (struct grub_gzio): Change the types of "data_offset"
9503 and "saved_offset" to grub_off_t.
9504 (test_header): Cast BUF to char *.
9505 (get_byte): Cast GZIO->DATA_OFFSET to grub_off_t. Cast GZIO->INBUF
9506 to char *.
9507 (grub_gzio_read): Change the types of OFFSET and SIZE to
9508 grub_off_t and grub_size_t, respectively.
9509
9510 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_FORCE_LBA):
9511 Removed.
9512 (GRUB_BOOT_MACHINE_BOOT_DRIVE): Changed to 0x4c.
9513 (GRUB_BOOT_MACHINE_KERNEL_ADDRESS): Changed to 0x40.
9514 (GRUB_BOOT_MACHINE_KERNEL_SEGMENT): Changed to 0x42.
9515 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Changed to 0x4e.
9516 (GRUB_BOOT_MACHINE_LIST_SIZE): Increased to 12.
9517
9518 * include/grub/types.h (grub_off_t): Unconditionally set to
9519 grub_uint64_t.
9520 (grub_disk_addr_t): Changed to grub_uint64_t.
9521
9522 * include/grub/partition.h (struct grub_partition): Change the
9523 types of "start", "len" and "offset" to grub_disk_addr_t,
9524 grub_uint64_t and grub_disk_addr_t, respectively.
9525 (grub_partition_get_start): Return grub_disk_addr_t.
9526 (grub_partition_get_len): Return grub_uint64_t.
9527
9528 * include/grub/misc.h (grub_strtoull): New prototype.
9529 (grub_divmod64): Likewise.
9530
9531 * include/grub/fshelp.h (grub_fshelp_read_file): Change the types
9532 of SECTOR, LEN and FILESIZE to grub_disk_addr_t, grub_size_t and
9533 grub_off_t, respectively.
9534 All callers and references changed.
9535
9536 * include/grub/fs.h (struct grub_fs): Change the type of LEN to
9537 grub_size_t in "read".
9538 All callers and references changed.
9539
9540 * include/grub/file.h (struct grub_file): Change the types of
9541 "offset" and "size" to grub_off_t and grub_off_t,
9542 respectively. Change the type of SECTOR to grub_disk_addr_t in
9543 "read_hook".
9544 (grub_file_read): Change the type of LEN to grub_size_t.
9545 (grub_file_seek): Return grub_off_t. Change the type of OFFSET to
9546 grub_off_t.
9547 (grub_file_size): Return grub_off_t.
9548 (grub_file_tell): Likewise.
9549 All callers and references changed.
9550
9551 * include/grub/disk.h (struct grub_disk_dev): Change the types of
9552 SECTOR and SIZE to grub_disk_addr_t and grub_size_t in "read" and
9553 "write".
9554 (struct grub_disk): Change the type of "total_sectors" to
9555 grub_uint64_t. Change the type of SECTOR to grub_disk_addr_t in
9556 "read_hook".
9557 (grub_disk_read): Change the types of SECTOR, OFFSET and SIZE to
9558 grub_disk_addr_t, grub_off_t and grub_size_t, respectively.
9559 (grub_disk_write): Likewise.
9560 All callers and references changed.
9561
9562 * fs/iso9660.c (grub_iso9660_susp_iterate): Cast parameters to
9563 char * for grub_strncmp to silence gcc.
9564 (grub_iso9660_mount): Likewise.
9565 (grub_iso9660_mount): Likewise.
9566 (grub_iso9660_read_symlink): Likewise. Also, remove the nonsense
9567 return statement.
9568 (grub_iso9660_iterate_dir): Likewise.
9569 (grub_iso9660_label): Cast DATA->VOLDESC.VOLNAME to char *.
9570
9571 * fs/hfs.c (grub_hfs_read_file): Change the types of SECTOR and
9572 LEN to grub_disk_addr_t and grub_size_t, respectively.
9573
9574 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
9575
9576 * fs/jfs.c (grub_jfs_read_file): Likewise.
9577
9578 * fs/minix.c (grub_jfs_read_file): Likewise.
9579
9580 * fs/sfs.c (grub_jfs_read_file): Likewise.
9581
9582 * fs/ufs.c (grub_jfs_read_file): Likewise.
9583
9584 * fs/xfs.c (grub_jfs_read_file): Likewise.
9585
9586 * fs/fat.c (grub_fat_read_data): Change the types of SECTOR, LEN
9587 and SIZE to grub_disk_addr_t, grub_size_t and grub_size_t,
9588 respectively.
9589
9590 * fs/ext2.c (grub_ext2_read_block): When an error happens, set
9591 BLKNR to -1 instead of returning GRUB_ERRNO.
9592 (grub_ext2_read_file): Change the types of SECTOR and
9593 LEN to grub_disk_addr_t and grub_size_t, respectively.
9594
9595 * fs/affs.c (grub_affs_read_file): Change the types of SECTOR and
9596 LEN to grub_disk_addr_t and grub_size_t, respectively.
9597
9598 * font/manager.c (grub_font_get_glyph): Cast BITMAP to char * for
9599 grub_file_read.
9600
9601 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Fix the format
9602 string. Do not cast SECTOR explicitly.
9603
9604 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): Change the type of
9605 TOTAL_SECTORS to grub_uint64_t. Do not mask DRP->TOTAL_SECTORS.
9606 (grub_biosdisk_rw): Change the types of SECTOR and SIZE to
9607 grub_disk_addr_t and grub_size_t, respectively. If the sector is
9608 over 2TB and LBA mode is not supported, raise an error.
9609 (get_safe_sectors): New function.
9610 (grub_biosdisk_read): Use get_safe_sectors.
9611 (grub_biosdisk_write): Likewise.
9612
9613 * disk/efi/efidisk.c (grub_efidisk_read): Fix the format string.
9614 (grub_efidisk_write): Likewise.
9615
9616 * disk/loopback.c (delete_loopback): Cosmetic changes.
9617 (grub_cmd_loopback): Likewise. Also, test NEWDEV->FILENAME
9618 correctly.
9619 (grub_loopback_open): Likewise.
9620 (grub_loopback_read): Likewise. Also, change the type of POS to
9621 grub_off_t, and fix the usage of grub_memset.
9622
9623 * commands/i386/pc/play.c: Include grub/machine/time.h.
9624
9625 * commands/ls.c (grub_ls_list_files): Use "llu" instead of "d" to
9626 print FILE->SIZE.
9627
9628 * commands/configfile.c: Include grub/env.h.
9629
9630 * commands/cmp.c (grub_cmd_cmp): Do not use ERR, but use
9631 GRUB_ERRNO directly instead. Change the type of POS to
9632 grub_off_t. Follow the coding standard.
9633
9634 * commands/blocklist.c: Include grub/partition.h.
9635 (grub_cmd_blocklist): Return an error if the underlying device is
9636 not a disk. Take the starting sector of a partition into account,
9637 if a partition is used.
9638
9639 * boot/i386/pc/diskboot.S (bootloop): Adapted to the new offset of
9640 a length field.
9641 (lba_mode): Support 64-bit addresses.
9642 (chs_mode): Likewise.
9643 (copy_buffer): Adapted to the new offsets of a length field and a
9644 segment field.
9645 (blocklist_default_start): Allocate 64-bit space.
9646
9647 * boot/i386/pc/boot.S (force_lba): Removed.
9648 (boot_drive): Moved to under KERNEL_SECTOR.
9649 (kernel_sector): Moved to under KERNEL_SEGMENT. Allocate 64-bit
9650 space.
9651 (real_start): Set %si earlier. Remove code for FORCE_LBA, since it
9652 is useless.
9653 (lba_mode): Refactored to support a 64-bit address. More size
9654 optimization.
9655 (setup_sectors): Likewise.
9656
9657 2006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
9658
9659 * DISTLIST: Added include/grub/i386/linux.h. Removed
9660 include/grub/i386/pc/linux.h
9661
9662 * configure.ac (AC_INIT): Bumped to 1.94.
9663
9664 * config.guess: Updated from gnulib.
9665 * config.sub: Likewise.
9666 * install-sh: Likewise.
9667 * mkinstalldirs: Likewise.
9668
9669 2006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
9670
9671 * conf/common.rmk (grub_modules_init.lst): Depended on
9672 grub_emu_SOURCES, excluding grub_emu_init.c, instead of
9673 MODSRCFILES.
9674
9675 * genmk.rb (PModule::rule): Reverted the previous change.
9676
9677 2006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
9678
9679 * conf/common.rmk (grub_modules_init.lst): Depends on
9680 $(MODSRCFILES). Grep only the files in $(MODSRCFILES). Make sure
9681 that the target does not exist before producing.
9682 (grub_modules_init.h): Remove the target before generating.
9683 (grub_emu_init.c): Likewise.
9684
9685 * genmk.rb (PModule::rule): Add source files into MODSRCFILES.
9686
9687 2006-05-31 Jeroen Dekkers <jeroen@dekkers.cx>
9688
9689 * configure.ac: Don't set host_m32 for x86_64. Also reset LIBS
9690 for the target-specific tests. Make sure that we also have the
9691 up-to-date target variables for those tests.
9692
9693 2006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
9694
9695 * genmk.rb (Image::rule): Prefix CFLAGS or ASFLAGS with TARGET_.
9696 (PModule::rule): Likewise.
9697
9698 2006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
9699
9700 * genmk.rb (Image::rule): Set FLAG to CFLAGS or ASFLAGS instead of
9701 TARGET_CFLAGS or TARGET_ASFLAGS. There is no reason why
9702 target-specific flags should be prefixed.
9703 (PModule::rule): Likewise.
9704
9705 2006-05-30 Yoshinori K. Okuji <okuji@enbug.org>
9706
9707 * configure.ac (CMP): Check if cmp is available explicitly.
9708
9709 2006-05-29 Yoshinori K. Okuji <okuji@enbug.org>
9710
9711 * util/powerpc/ieee1275/grub-install.in (host_cpu): Removed.
9712 (target_cpu): New variable.
9713 (pkglibdir): Use target_cpu instead of host_cpu.
9714
9715 * util/i386/pc/grub-install.in (host_cpu): Removed.
9716 (target_cpu): New variable.
9717 (pkglibdir): Use target_cpu instead of host_cpu.
9718
9719 * util/genmoddep.c: Removed.
9720
9721 * kern/efi/mm.c (filter_memory_map): Use GRUB_CPU_SIZEOF_VOID_P
9722 instead of GRUB_HOST_SIZEOF_VOID_P.
9723 * kern/dl.c: Likewise.
9724
9725 * include/grub/i386/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed to
9726 ...
9727 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
9728 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
9729 (GRUB_TARGET_SIZEOF_LONG): ... this.
9730 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
9731 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
9732 * include/grub/powerpc/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
9733 to ...
9734 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
9735 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
9736 (GRUB_TARGET_SIZEOF_LONG): ... this.
9737 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
9738 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
9739 * include/grub/sparc64/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
9740 to ...
9741 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
9742 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
9743 (GRUB_TARGET_SIZEOF_LONG): ... this.
9744 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
9745 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
9746
9747 * include/grub/types.h [!GRUB_UTIL] (GRUB_CPU_SIZEOF_VOID_P): Use
9748 GRUB_TARGET_SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P.
9749 [!GRUB_UTIL] (GRUB_CPU_SIZEOF_LONG): Use GRUB_TARGET_SIZEOF_LONG
9750 instead of GRUB_HOST_SIZEOF_LONG.
9751 [!GRUB_UTIL]: Refer to GRUB_TARGET_WORDS_BIGENDIAN instead of
9752 GRUB_HOST_WORDS_BIGENDIAN to define or undefine
9753 GRUB_CPU_WORDS_BIGENDIAN.
9754 Refer to SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P to
9755 define grub_host_addr_t, grub_host_off_t, grub_host_size_t and
9756 grub_host_ssize_t.
9757
9758 * conf/i386-efi.rmk (noinst_UTILITIES): Removed.
9759 (genmoddep_SOURCES): Likewise.
9760 * conf/i386-pc.rmk (noinst_UTILITIES): Likewise.
9761 (genmoddep_SOURCES): Likewise.
9762 * conf/conf/powerpc-ieee1275.rmk (noinst_UTILITIES): Likewise.
9763 (genmoddep_SOURCES): Likewise.
9764 * conf/conf/conf/sparc64-ieee1275.rmk (noinst_UTILITIES):
9765 Likewise.
9766 (genmoddep_SOURCES): Likewise.
9767
9768 * genmoddep.awk: New file.
9769
9770 * genmk.rb (Image::rule): Use TARGET_CC, TARGET_CPPFLAGS,
9771 TARGET_CFLAGS, TARGET_ASFLAGS and TARGET_LDFLAGS instead of CC,
9772 CPPFLAGS, CFLAGS, ASFLAGS and LDFLAGS, respectively.
9773 (PModule::rule): Likewise.
9774 (Program::rule): Likewise.
9775 (Utility::rule): Use CC, CPPFLAGS, CFLAGS and LDFLAGS instead of
9776 BUILD_CC, BUILD_CPPFLAGS, BUILD_CFLAGS and BUILD_LDFLAGS,
9777 respectively.
9778
9779 * configure.ac: Rewritten intensively to use host and target
9780 instead of build and host, respectively.
9781
9782 * Makefile.in (pkglibdir): Use target_cpu instead of host_cpu.
9783 (host_cpu): Removed.
9784 (target_cpu): New variable.
9785 (CPPFLAGS): Added @CPPFLAGS@ and -DGRUB_LIBDIR=\"$(pkglibdir)\".
9786 (BUILD_CC): Removed.
9787 (BUILD_CFLAGS): Likewise.
9788 (BUILD_CPPFLAGS): Likewise.
9789 (TARGET_CC): New variable.
9790 (TARGET_CFLAGS): Likewise.
9791 (TARGET_CPPFLAGS): Likewise.
9792 (TARGET_LDFLAGS): Likewise.
9793 (AWK): Likewise.
9794 (include): Use target_cpu instead of host_cpu.
9795 (moddep.lst:): Use genmoddep.awk instead of genmoddep.
9796
9797 * DISTLIST: Added genmoddep.awk. Removed util/genmoddep.c.
9798
9799 2006-05-29 Vesa Jaaskelainen <chaac@nic.fi>
9800
9801 * include/grub/script.h (grub_script_cmdif): Renamed field 'bool' to
9802 'exec_to_evaluate'. Renamed field 'true' to 'exec_on_true'. Renamed
9803 field 'false' to 'exec_on_false'.
9804 (grub_script_create_cmdif): Renamed argument names to reflect above
9805 changes.
9806
9807 * normal/execute.c (grub_script_execute_cmdif): Likewise.
9808
9809 * normal/script.c (grub_script_create_cmdif): Likewise.
9810
9811 2006-05-28 Yoshinori K. Okuji <okuji@enbug.org>
9812
9813 * fs/hfsplus.c (grub_hfsplus_btree_recoffset): Moved to near the
9814 top.
9815 (grub_hfsplus_btree_recptr): Likewise.
9816 (grub_hfsplus_find_block): Do not take RETRY any longer. Use
9817 FILEBLOCK both to pass a block number and store next block
9818 number.
9819 (grub_hfsplus_read_block): Rewritten heavily to support an extent
9820 overflow file correctly. Specify errors appropriately, because
9821 fshelp expects that GRUB_ERRNO is set when fails. Reuse
9822 grub_hfsplus_btree_recptr to get the pointer to a found key.
9823 (grub_hfsplus_btree_search): Return 1 instead of 0 when no match
9824 is found.
9825
9826 * conf/i386-efi.rmk (pkgdata_MODULES): Added _linux.mod and
9827 linux.mod.
9828 (_linux_mod_SOURCES): New variable.
9829 (_linux_mod_CFLAGS): Likewise.
9830 (_linux_mod_LDFLAGS): Likewise.
9831 (linux_mod_SOURCES): Likewise.
9832 (linux_mod_CFLAGS): Likewise.
9833 (linux_mod_LDFLAGS): Likewise.
9834
9835 * DISTLIST: Added loader/i386/efi/linux.c,
9836 loader/i386/efi/linux_normal.c and
9837 include/grub/i386/efi/loader.h.
9838
9839 * loader/i386/efi/linux.c: New file.
9840 * loader/i386/efi/linux_normal.c: Likewise.
9841 * include/grub/i386/efi/loader.h: Likewise.
9842
9843 2006-05-27 Yoshinori K. Okuji <okuji@enbug.org>
9844
9845 * commands/blocklist.c: New file.
9846
9847 * DISTLIST: Added commands/blocklist.c.
9848
9849 * term/efi/console.c (grub_console_highlight_color): Use a lighter
9850 color for the background, and a darker color for the foreground.
9851 (grub_console_checkkey): Return READ_KEY.
9852 (grub_console_cls): Set the background to
9853 GRUB_EFI_BACKGROUND_BLACK temporarily to clean out the screen.
9854
9855 * kern/efi/efi.c (grub_efi_exit_boot_services): New function.
9856
9857 * include/grub/i386/linux.h (struct linux_kernel_params): Fixed
9858 the size of "padding5", "hd0_drive_info" and "hd1_drive_info".
9859
9860 * include/grub/efi/efi.h (grub_efi_exit_boot_services): New
9861 prototype.
9862
9863 * include/grub/efi/api.h (GRUB_EFI_TEXT_ATTR): Do not shift
9864 BG. The spec is wrong again.
9865
9866 * include/grub/normal.h [GRUB_UTIL] (grub_blocklist_init): New
9867 prototype.
9868 [GRUB_UTIL] (grub_blocklist_fini): Likewise.
9869
9870 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
9871 commands/blocklist.c.
9872 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
9873
9874 * conf/common.rmk (pkgdata_MODULES): Added blocklist.mod.
9875 (blocklist_mod_SOURCES): New variable.
9876 (blocklist_mod_CFLAGS): Likewise.
9877 (blocklist_mod_LDFLAGS): Likewise.
9878
9879 2006-05-20 Yoshinori K. Okuji <okuji@enbug.org>
9880
9881 * boot/i386/pc/boot.S (real_start): Set %si earlier to eliminate
9882 duplication.
9883 (lba_mode): Use %eax more intensively to reduce the code size.
9884
9885 2006-05-20 Marco Gerards <marco@gnu.org>
9886
9887 * normal/lexer.c (grub_script_yylex): Don't filter out newlines.
9888
9889 * normal/parser.y (commandblock): Defined as <cmd>. A subroutine
9890 for `menuentry'.
9891 (script): Accept leading newlines.
9892 (newlines): New rule to describe 0 or more newlines.
9893 (commands): Accept `command' with trailing newline. Fixed the
9894 order in which arguments were passed to `grub_script_add_cmd'.
9895 Accept commands separated by newlines.
9896 (function): Changed to accept newlines.
9897 (menuentry) Rewritten.
9898
9899 * normal/script.c (grub_script_create_cmdmenu): Add new entries in
9900 front of the list, instead of to the end.
9901
9902 2006-05-19 Yoshinori K. Okuji <okuji@enbug.org>
9903
9904 * util/i386/pc/grub-install.in (bindir): New variable.
9905 (grub_mkimage): Use BINDIR instead of SBINDIR. Reported by Lee
9906 Shaver <lbgwjl@gmail.com>.
9907
9908 2006-05-14 Yoshinori K. Okuji <okuji@enbug.org>
9909
9910 * kern/i386/pc/startup.S: Include grub/cpu/linux.h instead of
9911 grub/machine/linux.h
9912 * loader/i386/pc/linux.c: Likewise.
9913
9914 * include/grub/i386/pc/linux.h: Moved to ...
9915 * include/grub/i386/linux.h: ... here.
9916
9917 * include/grub/i386/linux.h (struct linux_kernel_params): New
9918 struct.
9919
9920 2006-05-09 Vesa Jaaskelainen <chaac@nic.fi>
9921
9922 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Corrected bounds
9923 checking.
9924 (grub_video_vbe_blit_glyph): Likewise.
9925 (grub_video_vbe_blit_bitmap): Likewise.
9926 (grub_video_vbe_blit_render_target): Likewise.
9927
9928 2006-05-09 Yoshinori K. Okuji <okuji@enbug.org>
9929
9930 * configure.ac (--with-platform): Properly quote the square
9931 brackets.
9932
9933 2006-05-08 Marco Gerards <marco@gnu.org>
9934
9935 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Renamed from
9936 this...
9937 (kernel_elf_HEADERS): ...to this. Updated all users.
9938 (grubof_symlist.c): Renamed from this...
9939 (kernel_elf_symlist.c): ...to this. Updated all users.
9940 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
9941 (grubof_SOURCES): Renamed from this...
9942 (kernel_elf_SOURCES): ...to this.
9943 (grubof_HEADERS): Renamed from this...
9944 (kernel_elf_HEADERS): ...to this.
9945 (grubof_CFLAGS): Renamed from this...
9946 (kernel_elf_CFLAGS): ...to this.
9947 (grubof_ASFLAGS): Renamed from this...
9948 (kernel_elf_ASFLAGS): ...to this.
9949 (grubof_LDFLAGS): Renamed from this...
9950 (kernel_elf_LDFLAGS): ...to this.
9951
9952 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Renamed from
9953 this...
9954 (kernel_elf_HEADERS): ...to this. Updated all users.
9955 (grubof_symlist.c): Renamed from this...
9956 (kernel_elf_symlist.c): ...to this. Updated all users.
9957 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
9958 (grubof_SOURCES): Renamed from this...
9959 (kernel_elf_SOURCES): ...to this.
9960 (grubof_HEADERS): Renamed from this...
9961 (kernel_elf_HEADERS): ...to this.
9962 (grubof_CFLAGS): Renamed from this...
9963 (kernel_elf_CFLAGS): ...to this.
9964 (grubof_ASFLAGS): Renamed from this...
9965 (kernel_elf_ASFLAGS): ...to this.
9966 (grubof_LDFLAGS): Renamed from this...
9967 (kernel_elf_LDFLAGS): ...to this.
9968
9969 * util/powerpc/ieee1275/grub-mkimage.c (add_segments): Use
9970 `kernel.elf' instead of `grubof'.
9971
9972 2006-05-08 Yoshinori K. Okuji <okuji@enbug.org>
9973
9974 Add --with-platform to configure. Use pkglibdir instead of
9975 pkgdatadir. This is reported by Roger Leigh.
9976
9977 * util/powerpc/ieee1275/grub-install.in (datadir): Removed.
9978 (host_vendor): Likewise.
9979 (host_os): Likewise.
9980 (pkgdatadir): Likewise.
9981 (platform): New variable.
9982 (pkglibdir): Likewise.
9983 Use PKGLIBDIR instead of PKGDATADIR.
9984
9985 * util/i386/pc/grub-install.in (datadir): Removed.
9986 (host_vendor): Likewise.
9987 (host_os): Likewise.
9988 (pkgdatadir): Likewise.
9989 (platform): New variable.
9990 (pkglibdir): Likewise.
9991 Use PKGLIBDIR instead of PKGDATADIR.
9992
9993 * util/powerpc/ieee1275/grub-mkimage.c (usage): Use GRUB_LIBDIR
9994 instead of GRUB_DATADIR.
9995 (main): Likewise.
9996 * util/i386/pc/grub-mkimage.c (usage): Likewise.
9997 (main): Likewise.
9998 * util/i386/efi/grub-mkimage.c (usage): Likewise.
9999 (main): Likewise.
10000
10001 * configure.ac (--with-platform): New option.
10002 Use PLATFORM instead of HOST_VENDOR to specify a platform.
10003
10004 * Makefile.in: Include a makefile based on PLATFORM instead of
10005 HOST_VENDOR.
10006 (pkgdatadir): Not appended by the machine type.
10007 (pkglibdir): Appended by the machine type.
10008 (host_vendor): Removed.
10009 (platform): New variable.
10010 (BUILD_CPPFLAGS): Specify GRUB_LIBDIR instead of GRUB_DATADIR.
10011 (install-local): Use PKGLIBDIR instead of PKGDATADIR.
10012 (uninstall): Likewise.
10013
10014 2006-05-07 Yoshinori K. Okuji <okuji@enbug.org>
10015
10016 Use the environment context in the menu. Remove the commands
10017 "default" and "timeout", and use variables instead.
10018
10019 * normal/menu.c: Include grub/env.h.
10020 (print_entry): Cast TITLE to silence gcc.
10021 (get_timeout): New function.
10022 (set_timeout): Likewise.
10023 (get_entry_number): Likewise.
10024 (run_menu): Use a default entry, a fallback entry and a timeout
10025 in the environment variables "default", "fallback" and
10026 "timeout". Also, tweak the default entry if it is not within the
10027 current menu entries.
10028 (grub_menu_run): Use a fallback entry in the environment variable
10029 "fallback".
10030
10031 * normal/main.c (read_config_file): Do not initialize
10032 NEWMENU->DEFAULT_ENTRY, NEWMENU->FALLBACK_ENTRY or
10033 NEWMENU->TIMEOUT.
10034 (grub_normal_execute): Use a data slot to store the menu.
10035
10036 * include/grub/normal.h (struct grub_menu): Removed default_entry,
10037 fallback_entry and timeout.
10038 (struct grub_menu_list): Removed.
10039 (grub_menu_list_t): Likewise.
10040 (struct grub_context): Likewise.
10041 (grub_context_t): Likewise.
10042 (grub_context_get): Likewise.
10043 (grub_context_get_current_menu): Likewise.
10044 (grub_context_push_menu): Likewise.
10045 (grub_context_pop_menu): Likewise.
10046 (grub_default_init): Likewise.
10047 (grub_default_fini): Likewise.
10048 (grub_timeout_init): Likewise.
10049 (grub_timeout_fini): Likewise.
10050
10051 * conf/sparc64-ieee1275.rmk (pkgdata_MODULES): Removed default.mod
10052 and timeout.mod.
10053 (normal_mod_SOURCES): Removed normal/context.c.
10054
10055 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Removed
10056 commands/default.c, commands/timeout.c and normal/context.c.
10057 (normal_mod_SOURCES): Removed normal/context.c.
10058
10059 * conf/i386-pc.rmk (grub_emu_SOURCES): Removed commands/default.c,
10060 commands/timeout.c and normal/context.c.
10061 (normal_mod_SOURCES): Removed normal/context.c.
10062
10063 * conf/i386-efi.rmk (grub_emu_SOURCES): Removed
10064 commands/default.c, commands/timeout.c and normal/context.c.
10065 (normal_mod_SOURCES): Removed normal/context.c.
10066
10067 * conf/common.rmk (pkgdata_MODULES): Removed default.mod and
10068 timeout.mod.
10069 (default_mod_SOURCES): Removed.
10070 (default_mod_CFLAGS): Likewise.
10071 (default_mod_LDFLAGS): Likewise.
10072 (timeout_mod_SOURCES): Removed.
10073 (timeout_mod_CFLAGS): Likewise.
10074 (timeout_mod_LDFLAGS): Likewise.
10075
10076 * DISTLIST: Removed commands/default.c, commands/timeout.c and
10077 normal/context.c.
10078
10079 * commands/default.c: Removed.
10080 * commands/timeout.c: Likewise.
10081 * normal/context.c: Likewise.
10082
10083 2006-05-07 Vesa Jaaskelainen <chaac@nic.fi>
10084
10085 * kern/i386/pc/startup.S (grub_exit): Added missing .code32 tag.
10086
10087 2006-05-02 Yoshinori K. Okuji <okuji@enbug.org>
10088
10089 * kern/env.c (struct grub_env_context): Removed "sorted". Renamed
10090 "next" to "prev" for readability.
10091 (struct grub_env_sorted_var): New struct.
10092 (grub_env_context): Renamed to ...
10093 (initial_context): ... this.
10094 (grub_env_var_context): Renamed to ...
10095 (current_context): ... this.
10096 (grub_env_find): Look only at CURRENT_CONTEXT.
10097 (grub_env_context_open): Rewritten to copy exported variables from
10098 previous context.
10099 (grub_env_context_close): Rewritten according to the new
10100 scheme. Also, add an assertion to prevent the initial context from
10101 removed.
10102 (grub_env_insert): Removed the code for the sorted list.
10103 (grub_env_remove): Likewise.
10104 (grub_env_export): Simply mark the variable with
10105 GRUB_ENV_VAR_GLOBAL.
10106 (grub_env_set): A cosmetic change for naming consistency.
10107 (grub_env_get): Likewise.
10108 (grub_env_unset): Likewise.
10109 (grub_env_iterate): Rewritten to sort variables within this
10110 function.
10111 (grub_register_variable_hook): Fixed for naming consistency. Call
10112 grub_env_find again, only if NAME is not found at the first time.
10113 (mangle_data_slot_name): New function.
10114 (grub_env_set_data_slot): Likewise.
10115 (grub_env_get_data_slot): Likewise.
10116 (grub_env_unset_data_slot): Likewise.
10117
10118 * include/grub/env.h (grub_env_var_type): New enum.
10119 (GRUB_ENV_VAR_LOCAL): New constant.
10120 (GRUB_ENV_VAR_GLOBAL): Likewise.
10121 (GRUB_ENV_VAR_DATA): Likewise.
10122 (struct grub_env_var): Removed "sort_next" and "sort_prevp". Added
10123 "type".
10124 (grub_env_set): Replace VAR with NAME for consistency.
10125 (grub_register_variable_hook): Likewise.
10126 (grub_env_export): Specify the name of the argument.
10127 (grub_env_set_data_slot): New prototype.
10128 (grub_env_get_data_slot): Likewise.
10129 (grub_env_unset_data_slot): Likewise.
10130
10131 2006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
10132
10133 Extend the loader so that GRUB can accept a loader which comes
10134 back to GRUB when a loaded image exits. Also, this change adds
10135 support for a chainloader on EFI.
10136
10137 * term/efi/console.c: Include grub/misc.h.
10138 (grub_console_checkkey): Display a scan code on the top for
10139 debugging. This will be removed once the EFI port gets stable.
10140 Correct the scan code mapping.
10141
10142 * kern/efi/mm.c (sort_memory_map): Sort in a descending order to
10143 allocate memory from larger regions, in order to reduce the number
10144 of allocated regions. Otherwise, the MacOSX loader panics.
10145 (filter_memory_map): Avoid less than 1MB for compatibility with
10146 other loaders.
10147 (add_memory_regions): Allocate from the tail of a region, if
10148 possible, to avoid allocating a region near to 1MB, for the MacOSX
10149 loader.
10150
10151 * kern/efi/init.c (grub_efi_set_prefix): Specify
10152 GRUB_EFI_IMAGE_HANDLE to grub_efi_get_loaded_image.
10153
10154 * kern/efi/efi.c (grub_efi_get_loaded_image): Accept a new
10155 argument IMAGE_HANDLE and specify it to get a loaded image.
10156 (grub_arch_modules_addr): Specify GRUB_EFI_IMAGE_HANDLE to
10157 grub_efi_get_loaded_image.
10158 (grub_efi_get_filename): Divide the length by the size of
10159 grub_efi_char16_t.
10160 (grub_efi_get_device_path): New function.
10161 (grub_efi_print_device_path): Print End Device Path nodes. Divide
10162 the length by the size of grub_efi_char16_t for a file path device
10163 path node.
10164
10165 * kern/loader.c (grub_loader_noreturn): New variable.
10166 (grub_loader_set): Accept a new argument NORETURN. Set
10167 GRUB_LOADER_NORETURN to NORETURN.
10168 All callers changed.
10169 (grub_loader_boot): If GRUB_LOADER_NORETURN is false, do not call
10170 grub_machine_fini.
10171
10172 * include/grub/efi/efi.h (grub_efi_get_device_path): New
10173 prototype.
10174 (grub_efi_get_loaded_image): Take an argument to specify an image
10175 handle.
10176
10177 * include/grub/loader.h (grub_loader_set): Added one more argument
10178 NORETURN.
10179
10180 * disk/efi/efidisk.c (make_devices): Use grub_efi_get_device_path
10181 instead of grub_efi_open_protocol.
10182 (grub_efidisk_get_device_name): Likewise.
10183 (grub_efidisk_close): Print a newline.
10184 (grub_efidisk_get_device_handle): Fixed to use
10185 GRUB_EFI_DEVICE_PATH_SUBTYPE instead of
10186 GRUB_EFI_DEVICE_PATH_TYPE.
10187
10188 * disk/efi/efidisk.c (device_path_guid): Moved to ...
10189 * kern/efi/efi.c (device_path_guid): ... here.
10190
10191 * conf/i386-efi.rmk (pkgdata_MODULES): Added _chain.mod and
10192 chain.mod.
10193 (kernel_mod_HEADERS): Added efi/disk.h.
10194 (_chain_mod_SOURCES): New variable.
10195 (_chain_mod_CFLAGS): Likewise.
10196 (_chain_mod_LDFLAGS): Likewise.
10197 (chain_mod_SOURCES): Likewise.
10198 (chain_mod_CFLAGS): Likewise.
10199 (chain_mod_LDFLAGS): Likewise.
10200
10201 * DISTLIST: Added include/grub/efi/chainloader.h,
10202 loader/efi/chainloader.c and loader/efi/chainloader_normal.c.
10203
10204 * include/grub/efi/chainloader.h: New file.
10205 * loader/efi/chainloader.c: Likewise.
10206 * loader/efi/chainloader_normal.c: Likewise.
10207
10208 2006-04-30 Marco Gerards <marco@gnu.org>
10209
10210 * commands/configfile.c (grub_cmd_source): New function.
10211 (GRUB_MOD_INIT): Register the commands `source' and `.'.
10212 (GRUB_MOD_FINI): De-register the commands `source' and `.'.
10213
10214 2006-04-30 Marco Gerards <marco@gnu.org>
10215
10216 * normal/execute.c (grub_script_execute_cmd): Change the return
10217 type to `grub_err_t'. Correctly return the error.
10218 (grub_script_execute_cmdline): In case a command line is not a
10219 command or a function, try to interpret it as an assignment.
10220
10221 2006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
10222
10223 * fs/hfsplus.c (grub_hfsplus_read_block): Fixed a memory leak.
10224 (grub_hfsplus_iterate_dir): Reordered to skip unknown nodes. Also,
10225 skip a node whose name is obviously invalid as UTF-16,
10226 i.e. contains a NUL character. Stop the iteration when the last
10227 directory entry is found. Instead of using the return value of
10228 grub_hfsplus_btree_iterate_node, store the value in RET and use
10229 it, because the iterator can be stopped by the last directory
10230 entry.
10231
10232 2006-04-30 Marco Gerards <marco@gnu.org>
10233
10234 * include/grub/env.h (grub_env_export): New prototype. Reported
10235 by Jan C. Kleinsorge <jan.kleinsorge@udo.edu>.
10236
10237 2006-04-30 Marco Gerards <marco@gnu.org>
10238
10239 * fs/hfsplus.c (grub_hfsplus_iterate_dir): Correctly calculate the
10240 size of the extents in a catalog file record.
10241
10242 2006-04-29 Marco Gerards <marco@gnu.org>
10243
10244 * commands/configfile.c (grub_cmd_configfile): Execute the
10245 configfile within its own context.
10246
10247 * include/grub/env.h (grub_env_context_open): New prototype.
10248 (grub_env_context_close): Likewise.
10249
10250 * kern/env.c (grub_env): Removed.
10251 (grub_env_sorted): Likewise.
10252 (grub_env_context): New variable.
10253 (grub_env_var_context): Likewise.
10254 (grub_env_find): Search both the active context and the global
10255 context.
10256 (grub_env_context_open): New function.
10257 (grub_env_context_close): Likewise.
10258 (grub_env_insert): Likewise.
10259 (grub_env_remove): Likewise.
10260 (grub_env_export): Likewise.
10261 (grub_env_set): Changed to use helper functions to avoid code
10262 duplication.
10263 (grub_env_iterate): Rewritten so both the current context and the
10264 global context are being used.
10265
10266 * normal/command.c (export_command): New function.
10267 (grub_command_init): Register the `export' function.
10268
10269 2006-04-26 Yoshinori K. Okuji <okuji@enbug.org>
10270
10271 * util/i386/pc/grub-mkimage.c (compress_kernel): Cast arguments
10272 explicitly to suppress gcc's warnings.
10273 * fs/fat.c (grub_fat_find_dir): Likewise.
10274 (grub_fat_label): Likewise.
10275 * fs/xfs.c (grub_xfs_read_inode): Likewise.
10276 (grub_xfs_mount): Likewise.
10277 (grub_xfs_label): Likewise.
10278 * fs/affs.c (grub_affs_mount): Likewise.
10279 (grub_affs_label): Likewise.
10280 (grub_affs_iterate_dir): Likewise.
10281 * fs/sfs.c (grub_sfs_mount): Likewise.
10282 (grub_sfs_iterate_dir): Likewise.
10283 * fs/ufs.c (grub_ufs_lookup_symlink): Likewise.
10284 * fs/hfs.c (grub_hfs_mount): Likewise.
10285 (grub_hfs_cmp_catkeys): Likewise.
10286 (grub_hfs_find_dir): Likewise.
10287 (grub_hfs_dir): Likewise.
10288 (grub_hfs_label): Likewise.
10289 * fs/jfs.c (grub_jfs_mount): Likewise.
10290 (grub_jfs_opendir): Likewise.
10291 (grub_jfs_getent): Likewise.
10292 (grub_jfs_lookup_symlink): Likewise.
10293 (grub_jfs_label): Likewise.
10294 * fs/hfsplus.c (grub_hfsplus_cmp_catkey): Likewise.
10295 (grub_hfsplus_iterate_dir): Likewise.
10296 (grub_hfsplus_btree_iterate_node): Made static.
10297
10298 * util/grub-emu.c (prefix): New variable.
10299 (grub_machine_set_prefix): New function.
10300 (main): Do not set the environment variable "prefix" here. Only
10301 set PREFIX, which is used later by grub_machine_set_prefix.
10302
10303 * include/grub/video.h: Do not include grub/symbol.h.
10304 (grub_video_register): Not exported. This symbol is not defined in
10305 the kernel.
10306 (grub_video_unregister): Likewise.
10307 (grub_video_iterate): Likewise.
10308 (grub_video_setup): Likewise.
10309 (grub_video_restore): Likewise.
10310 (grub_video_get_info): Likewise.
10311 (grub_video_get_blit_format): Likewise.
10312 (grub_video_set_palette): Likewise.
10313 (grub_video_get_palette): Likewise.
10314 (grub_video_set_viewport): Likewise.
10315 (grub_video_get_viewport): Likewise.
10316 (grub_video_map_color): Likewise.
10317 (grub_video_map_rgb): Likewise.
10318 (grub_video_map_rgba): Likewise.
10319 (grub_video_fill_rect): Likewise.
10320 (grub_video_blit_glyph): Likewise.
10321 (grub_video_blit_bitmap): Likewise.
10322 (grub_video_blit_render_target): Likewise.
10323 (grub_video_scroll): Likewise.
10324 (grub_video_swap_buffers): Likewise.
10325 (grub_video_create_render_target): Likewise.
10326 (grub_video_delete_render_target): Likewise.
10327 (grub_video_set_active_render_target): Likewise.
10328
10329 * include/grub/symbol.h [GRUB_SYMBOL_GENERATOR] (EXPORT_FUNC):
10330 Undefined.
10331 [GRUB_SYMBOL_GENERATOR] (EXPORT_VAR): Likewise.
10332
10333 * conf/sparc64-ieee1275.rmk (grubof_symlist.c): Depended on
10334 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
10335 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
10336 instead of $(srcdir)/genkernsyms.sh.
10337
10338 * conf/powerpc-ieee1275.rmk (grubof_symlist.c): Depended on
10339 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
10340 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
10341 instead of $(srcdir)/genkernsyms.sh.
10342
10343 * conf/i386-pc.rmk (symlist.c): Depended on config.h. Use
10344 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
10345 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
10346 instead of $(srcdir)/genkernsyms.sh.
10347
10348 * conf/i386-efi.rmk (symlist.c): Depended on config.h. Use
10349 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
10350 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
10351 instead of $(srcdir)/genkernsyms.sh.
10352
10353 * configure.ac (AC_CONFIG_FILES): Added gensymlist.sh and
10354 genkernsyms.sh.
10355
10356 * Makefile.in (DISTCLEANFILES): Added gensymlist.sh and
10357 genkernsyms.sh.
10358 (gensymlist.sh): New target.
10359 (genkernsyms.sh): Likewise.
10360
10361 * DISTLIST: Removed genkernsyms.sh and gensymlist.sh. Added
10362 genkernsyms.sh.in and gensymlist.sh.in.
10363
10364 * genkernsyms.sh: Removed.
10365 * gensymlist.sh: Likewise.
10366
10367 * genkernsyms.sh.in: New file.
10368 * gensymlist.sh.in: Likewise.
10369
10370 2006-04-25 Hollis Blanchard <hollis@penguinppc.org>
10371
10372 * kern/powerpc/ieee1275/init.c (grub_machine_set_prefix): Do not
10373 clobber "prefix", since we may have already set it manually.
10374
10375 2006-04-25 Hollis Blanchard <hollis@penguinppc.org>
10376
10377 * kern/misc.c (abort): New alias for grub_abort.
10378
10379 2006-04-25 Yoshinori K. Okuji <okuji@enbug.org>
10380
10381 A new machine-specific function "grub_machine_set_prefix" is
10382 defined. This is called after loading modules, so that a prefix
10383 initialization can use modules. Also, this change adds an
10384 intensive debugging feature for the memory manager via the
10385 configure option "--enable-mm-debug".
10386
10387 * partmap/gpt.c (gpt_partition_map_iterate): Add one more into
10388 PART.LEN.
10389
10390 * kern/sparc64/ieee1275/init.c (abort): Removed.
10391 (grub_stop): Likewise.
10392 (grub_exit): New function.
10393 (grub_set_prefix): Renamed to ...
10394 (grub_machine_set_prefix): ... this.
10395 (grub_machine_init): Do not call grub_set_prefix.
10396
10397 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Renamed to ...
10398 (grub_machine_set_prefix): ... this.
10399 (grub_machine_init): Do not call grub_set_prefix.
10400
10401 * kern/i386/pc/init.c (grub_machine_set_prefix): New function.
10402 (grub_machine_init): Do not set the prefix here.
10403
10404 * kern/i386/efi/init.c (grub_machine_set_prefix): New function.
10405
10406 * kern/efi/init.c: Include grub/mm.h.
10407 (grub_efi_set_prefix): New function.
10408
10409 * kern/efi/efi.c (grub_exit): Call grub_efi_fini.
10410 (grub_efi_get_filename): New function.
10411 (grub_print_device_path): Renamed to ...
10412 (grub_efi_print_device_path): ... this.
10413
10414 * kern/mm.c [MM_DEBUG] (grub_malloc): Undefined.
10415 [MM_DEBUG] (grub_realloc): Likewise.
10416 [MM_DEBUG] (grub_free): Likewise.
10417 [MM_DEBUG] (grub_memalign): Likewise.
10418 [MM_DEBUG] (grub_mm_debug): New variable.
10419 [MM_DEBUG] (grub_debug_malloc): New function.
10420 [MM_DEBUG] (grub_debug_free): New function.
10421 [MM_DEBUG] (grub_debug_realloc): New function.
10422 [MM_DEBUG] (grub_debug_memalign): New function.
10423
10424 * kern/misc.c (grub_abort): Print a newline to distinguish
10425 the message.
10426
10427 * kern/main.c (grub_main): Call grub_machine_set_prefix and
10428 grub_set_root_dev after loading modules. This is necessary when
10429 setting a prefix depends on modules.
10430
10431 * include/grub/efi/efi.h (grub_print_device_path): Renamed to ...
10432 (grub_efi_print_device_path): ... this.
10433 (grub_efi_get_filename): New prototype.
10434 (grub_efi_set_prefix): Likewise.
10435
10436 * include/grub/efi/disk.h: Include grub/efi/api.h, grub/symbol.h
10437 and grub/disk.h.
10438 (grub_efidisk_get_device_handle): New prototype.
10439 (grub_efidisk_get_device_name): Likewise.
10440
10441 * include/grub/mm.h: Include config.h.
10442 (MM_DEBUG): Removed.
10443 [MM_DEBUG && !GRUB_UTIL] (grub_mm_debug): New prototype.
10444 [MM_DEBUG && !GRUB_UTIL] (grub_malloc): New macro.
10445 [MM_DEBUG && !GRUB_UTIL] (grub_realloc): Likewise.
10446 [MM_DEBUG && !GRUB_UTIL] (grub_memalign): Likewise.
10447 [MM_DEBUG && !GRUB_UTIL] (grub_free): Likewise.
10448 [MM_DEBUG && !GRUB_UTIL] (grub_debug_malloc): New prototype.
10449 [MM_DEBUG && !GRUB_UTIL] (grub_debug_realloc): New prototype.
10450 [MM_DEBUG && !GRUB_UTIL] (grub_debug_memalign): New prototype.
10451 [MM_DEBUG && !GRUB_UTIL] (grub_debug_free): New prototype.
10452
10453 * include/grub/kernel.h (grub_machine_set_prefix): New prototype.
10454
10455 * disk/efi/efidisk.c: Include grub/partition.h.
10456 (iterate_child_devices): New function.
10457 (add_device): First, compare only last device path nodes, so that
10458 devices are sorted by the types.
10459 (grub_efidisk_get_device_handle): New function.
10460 (grub_efidisk_get_device_name): Likewise.
10461
10462 * configure.ac (--enable-mm-debug): New option to enable the
10463 memory manager debugging feature. This makes the binary much
10464 bigger, so is disabled by default.
10465
10466 2006-04-23 Yoshinori K. Okuji <okuji@enbug.org>
10467
10468 Use grub_abort instead of grub_stop, and grub_exit must be
10469 define in each architecture now. Also, this change adds support
10470 for EFI disks.
10471
10472 * util/i386/pc/grub-probefs.c: Include grub/term.h.
10473 (grub_getkey): New function.
10474 (grub_term_get_current): Likewise.
10475
10476 * util/i386/pc/grub-setup.c: Include grub/term.h.
10477 (grub_getkey): New function.
10478 (grub_term_get_current): Likewise.
10479
10480 * util/misc.c (grub_stop): Renamed to ...
10481 (grub_exit): ... this.
10482
10483 * kern/powerpc/ieee1275/init.c (abort): Renamed to ...
10484 (grub_exit): ... this.
10485 (grub_machine_init): Use grub_abort instead of abort.
10486 (grub_stop): Removed.
10487
10488 * kern/powerpc/ieee1275/cmain.c (cmain): Use grub_abort instead of
10489 abort.
10490
10491 * kern/i386/pc/startup.S (grub_exit): New function.
10492 (cold_reboot): New label.
10493
10494 * kern/efi/init.c: Include grub/efi/disk.h and grub/env.h.
10495 (grub_efi_init): Call grub_efidisk_init.
10496 (grub_efi_fini): Call grub_efidisk_fini.
10497
10498 * kern/efi/efi.c: Include grub/mm.h.
10499 (grub_efi_console_control_guid): Renamed to ...
10500 (console_control_guid): ... this.
10501 (grub_efi_loaded_image_guid): Renamed to ...
10502 (loaded_image_guid): ... this.
10503 (grub_efi_locate_handle): New function.
10504 (grub_efi_open_protocol): Likewise.
10505 (grub_efi_set_text_mode): Use CONSOLE_CONTROL_GUID instead of
10506 GRUB_EFI_CONSOLE_CONTROL_GUID.
10507 (grub_efi_exit): Removed.
10508 (grub_stop): Likewise.
10509 (grub_efi_get_loaded_image): Use grub_efi_open_protocol.
10510 (grub_exit): New function.
10511 (grub_print_device_path): Likewise.
10512
10513 * kern/rescue.c (grub_rescue_cmd_exit): New function.
10514 (grub_enter_rescue_mode): Register "exit".
10515
10516 * kern/misc.c (grub_real_dprintf): A cosmetic change.
10517 (grub_abort): New function.
10518
10519 * kern/err.c (grub_fatal): Use grub_abort instead of grub_stop.
10520
10521 * include/grub/sparc64/ieee1275/kernel.h (abort): Removed.
10522
10523 * include/grub/powerpc/ieee1275/kernel.h (abort): Removed.
10524
10525 * include/grub/efi/efi.h (grub_efi_exit): Removed.
10526 (grub_print_device_path): New prototype.
10527 (grub_efi_locate_handle): Likewise.
10528 (grub_efi_open_protocol): Likewise.
10529
10530 * include/grub/efi/disk.h (grub_efidisk_fini): New file.
10531 * disk/efi/efidisk.c: Likewise.
10532
10533 * DISTLIST: Added disk/efi/efidisk.c and include/grub/efi/disk.h.
10534
10535 * include/grub/efi/console_control.h
10536 (GRUB_EFI_CONSOLE_CONTROL_GUID): Use an array for the last 8 bytes.
10537
10538 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): Specify the
10539 last 8 bytes as an array.
10540 (GRUB_EFI_DISK_IO_GUID): New macro.
10541 (GRUB_EFI_BLOCK_IO_GUID): Likewise.
10542 (GRUB_EFI_DEVICE_PATH_GUID): Likewise.
10543 (grub_efi_ipv6_address_t): Change the type to grub_uint16_t from
10544 grub_uint8_t.
10545 (struct grub_efi_guid): Use an array to specify the last 8 bytes.
10546 (struct grub_efi_device_path): Rename the member "sub_type" to
10547 "subtype".
10548 (GRUB_EFI_DEVICE_PATH_TYPE): New macro.
10549 (GRUB_EFI_DEVICE_PATH_SUBTYPE): Likewise.
10550 (GRUB_EFI_DEVICE_PATH_LENGTH): Likewise.
10551 (GRUB_EFI_END_DEVICE_PATH_TYPE): Likewise.
10552 (GRUB_EFI_END_ENTIRE_DEVICE_PATH_SUBTYPE): Likewise.
10553 (GRUB_EFI_END_THIS_DEVICE_PATH_SUBTYPE): Likewise.
10554 (GRUB_EFI_END_ENTIRE_DEVICE_PATH): Likewise.
10555 (GRUB_EFI_NEXT_DEVICE_PATH): Likewise.
10556 (GRUB_EFI_HARDWARE_DEVICE_PATH_TYPE): Likewise.
10557 (GRUB_EFI_PCI_DEVICE_PATH_SUBTYPE): Likewise.
10558 (struct grub_efi_pci_device_path): New structure.
10559 (grub_efi_pci_device_path_t): New type.
10560 (GRUB_EFI_PCCARD_DEVICE_PATH_SUBTYPE): New macro.
10561 (struct grub_efi_pccard_device_path): New structure.
10562 (grub_efi_pccard_device_path_t): New type.
10563 (GRUB_EFI_MEMORY_MAPPED_DEVICE_PATH_SUBTYPE): New macro.
10564 (struct grub_efi_memory_mapped_device_path): New structure.
10565 (grub_efi_memory_mapped_device_path_t): New type.
10566 (GRUB_EFI_VENDOR_DEVICE_PATH_SUBTYPE): New macro.
10567 (struct grub_efi_vendor_device_path): New structure.
10568 (grub_efi_vendor_device_path_t): New type.
10569 (GRUB_EFI_CONTROLLER_DEVICE_PATH_SUBTYPE): New macro.
10570 (struct grub_efi_controller_device_path): New structure.
10571 (grub_efi_controller_device_path_t): New type.
10572 (GRUB_EFI_ACPI_DEVICE_PATH_TYPE): New macro.
10573 (GRUB_EFI_ACPI_DEVICE_PATH_SUBTYPE): Likewise.
10574 (struct grub_efi_acpi_device_path): New structure.
10575 (grub_efi_acpi_device_path_t): New type.
10576 (GRUB_EFI_EXPANDED_ACPI_DEVICE_PATH_SUBTYPE): New macro.
10577 (struct grub_efi_expanded_acpi_device_path): New structure.
10578 (grub_efi_expanded_acpi_device_path_t): New type.
10579 (GRUB_EFI_EXPANDED_ACPI_HIDSTR): New macro.
10580 (GRUB_EFI_EXPANDED_ACPI_UIDSTR): Likewise.
10581 (GRUB_EFI_EXPANDED_ACPI_CIDSTR): Likewise.
10582 (GRUB_EFI_MESSAGING_DEVICE_PATH_TYPE): Likewise.
10583 (GRUB_EFI_ATAPI_DEVICE_PATH_SUBTYPE): Likewise.
10584 (struct grub_efi_atapi_device_path): New structure.
10585 (grub_efi_atapi_device_path_t): New type.
10586 (GRUB_EFI_FIBRE_CHANNEL_DEVICE_PATH_SUBTYPE): New macro.
10587 (struct grub_efi_fibre_channel_device_path): New structure.
10588 (grub_efi_fibre_channel_device_path_t): New type.
10589 (GRUB_EFI_1394_DEVICE_PATH_SUBTYPE): New macro.
10590 (struct grub_efi_1394_device_path): New structure.
10591 (grub_efi_1394_device_path_t): New type.
10592 (GRUB_EFI_USB_DEVICE_PATH_SUBTYPE): New macro.
10593 (struct grub_efi_usb_device_path): New structure.
10594 (grub_efi_usb_device_path_t): New type.
10595 (GRUB_EFI_USB_CLASS_DEVICE_PATH_SUBTYPE): New macro.
10596 (struct grub_efi_usb_class_device_path): New structure.
10597 (grub_efi_usb_class_device_path_t): New type.
10598 (GRUB_EFI_I2O_DEVICE_PATH_SUBTYPE): New macro.
10599 (struct grub_efi_i2o_device_path): New structure.
10600 (grub_efi_i2o_device_path_t): New type.
10601 (GRUB_EFI_MAC_ADDRESS_DEVICE_PATH_SUBTYPE): New macro.
10602 (struct grub_efi_mac_address_device_path): New structure.
10603 (grub_efi_mac_address_device_path_t): New type.
10604 (GRUB_EFI_IPV4_DEVICE_PATH_SUBTYPE): New macro.
10605 (struct grub_efi_ipv4_device_path): New structure.
10606 (grub_efi_ipv4_device_path_t): New type.
10607 (GRUB_EFI_IPV6_DEVICE_PATH_SUBTYPE): New macro.
10608 (struct grub_efi_ipv6_device_path): New structure.
10609 (grub_efi_ipv6_device_path_t): New type.
10610 (GRUB_EFI_INFINIBAND_DEVICE_PATH_SUBTYPE): New macro.
10611 (struct grub_efi_infiniband_device_path): New structure.
10612 (grub_efi_infiniband_device_path_t): New type.
10613 (GRUB_EFI_UART_DEVICE_PATH_SUBTYPE): New macro.
10614 (struct grub_efi_uart_device_path): New structure.
10615 (grub_efi_uart_device_path_t): New type.
10616 (GRUB_EFI_VENDOR_MESSAGING_DEVICE_PATH_SUBTYPE): New macro.
10617 (struct grub_efi_vendor_messaging_device_path): New structure.
10618 (grub_efi_vendor_messaging_device_path_t): New type.
10619 (GRUB_EFI_MEDIA_DEVICE_PATH_TYPE): New macro.
10620 (GRUB_EFI_HARD_DRIVE_DEVICE_PATH_SUBTYPE): Likewise.
10621 (struct grub_efi_hard_drive_device_path): New structure.
10622 (grub_efi_hard_drive_device_path_t): New type.
10623 (GRUB_EFI_CDROM_DEVICE_PATH_SUBTYPE): New macro.
10624 (struct grub_efi_cdrom_device_path): New structure.
10625 (grub_efi_cdrom_device_path_t): New type.
10626 (GRUB_EFI_VENDOR_MEDIA_DEVICE_PATH_SUBTYPE): New macro.
10627 (struct grub_efi_vendor_media_device_path): New structure.
10628 (grub_efi_vendor_media_device_path_t): New type.
10629 (GRUB_EFI_FILE_PATH_DEVICE_PATH_SUBTYPE): New macro.
10630 (struct grub_efi_file_path_device_path): New structure.
10631 (grub_efi_file_path_device_path_t): New type.
10632 (GRUB_EFI_PROTOCOL_DEVICE_PATH_SUBTYPE): New macro.
10633 (struct grub_efi_protocol_device_path): New structure.
10634 (grub_efi_protocol_device_path_t): New type.
10635 (GRUB_EFI_BIOS_DEVICE_PATH_TYPE): New macro.
10636 (GRUB_EFI_BIOS_DEVICE_PATH_SUBTYPE): Likewise.
10637 (struct grub_efi_bios_device_path): New structure.
10638 (grub_efi_bios_device_path_t): New type.
10639 (struct grub_efi_disk_io): New structure.
10640 (grub_efi_disk_io_t): New type.
10641 (struct grub_efi_block_io_media): New structure.
10642 (grub_efi_block_io_media_t): New type.
10643 (struct grub_efi_block_io): New structure.
10644 (grub_efi_block_io_t): New type.
10645
10646 * include/grub/misc.h (grub_stop): Removed.
10647 (grub_exit): New prototype.
10648 (grub_abort): Likewise.
10649
10650 * include/grub/disk.h (enum grub_disk_dev_id): Added
10651 GRUB_DISK_DEVICE_EFIDISK_ID.
10652
10653 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added
10654 disk/efi/efidisk.c.
10655 (kernel_syms.lst): Remove the target if an error occurs.
10656
10657 2006-04-22 Yoshinori K. Okuji <okuji@enbug.org>
10658
10659 * kern/misc.c (grub_lltoa): Rewritten the decimal conversion part,
10660 as it was simply too buggy.
10661
10662 2006-04-21 Yoshinori K. Okuji <okuji@enbug.org>
10663
10664 * kern/misc.c (grub_lltoa): New function.
10665 (grub_vsprintf): Added support for the long long suffix,
10666 i.e. "ll".
10667
10668 2006-04-20 Hollis Blanchard <hollis@penguinppc.org>
10669
10670 * Makefile.in (LDFLAGS): Add variable.
10671 (LD): Remove variable.
10672 * configure.ac: Add -m32 to LDFLAGS.
10673 * genmk.rb (PModule#rule): Use $(CC) instead of $(LD).
10674 * conf/powerpc-ieee1275.rmk (COMMON_LDFLAGS): Add variable.
10675 (grubof_LDFLAGS): Use $(COMMON_LDFLAGS).
10676 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS, normal_mod_LDFLAGS,
10677 suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS): New
10678 variables.
10679 * conf/sparc64-ieee1275.rmk (COMMON_LDFLAGS): Add -nostdlib.
10680 * conf/i386-pc.rmk (COMMON_LDFLAGS): Add -nostdlib.
10681 * conf/i386-efi.rmk (COMMON_LDFLAGS): Add -nostdlib.
10682
10683 2006-04-20 Vesa Jaaskelainen <chaac@nic.fi>
10684
10685 * term/gfxterm.c (grub_gfxterm_getcharwidth): Fixed character
10686 length for unknown glyph.
10687
10688 2006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
10689
10690 Add support for pre-loaded modules into the EFI port.
10691
10692 * util/i386/efi/grub-mkimage.c (make_mods_section): Rewritten
10693 completely. Accept one more argument DIR. The caller has changed.
10694
10695 * kern/i386/efi/init.c (grub_arch_modules_addr): Removed.
10696
10697 * kern/efi/efi.c: Include grub/efi/pe32.h and grub/kernel.h.
10698 (grub_efi_loaded_image_guid): New variable.
10699 (grub_efi_get_loaded_image): New function.
10700 (grub_arch_modules_addr): Likewise.
10701
10702 * include/grub/efi/efi.h (grub_efi_get_loaded_image): New
10703 prototype.
10704
10705 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): New macro.
10706 (struct grub_efi_loaded_image): New structure.
10707 (grub_efi_loaded_image_t): New type.
10708
10709 2006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
10710
10711 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Compare the file
10712 size with GRUB_OS_AREA_SIZE as grub_size_t instead of
10713 grub_ssize_t. Reported by Jeff Chua <jeff84@silk.corp.fedex.com>.
10714
10715 2006-04-19 Roger Leigh <rleigh@whinlatter.ukfsn.org>
10716
10717 * DISTLIST: Added `util/powerpc/ieee1275/grub-install.in'.
10718
10719 2006-04-19 Yoshinori K. Okuji <okuji@enbug.org>
10720
10721 * DISTLIST: Added include/grub/efi/console.h,
10722 include/grub/efi/time.h, include/grub/i386/efi/kernel.h,
10723 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
10724
10725 * include/grub/efi/console.h: New file.
10726 * include/grub/efi/time.h: Likewise.
10727 * include/grub/i386/efi/kernel.h: Likewise.
10728 * kern/efi/init.c: Likewise.
10729 * kern/efi/mm.c: Likewise.
10730 * term/efi/console.c: Likewise.
10731
10732 * kern/i386/efi/init.c: Do not include grub/machine/time.h.
10733 (grub_stop): Removed.
10734 (grub_get_rtc): Likewise.
10735 (grub_machine_init): Simply call grub_efi_init.
10736 (grub_machine_fini): Call grub_efi_fini.
10737
10738 * kern/efi/efi.c: Include grub/machine/time.h and grub/term.h.
10739 (grub_efi_output_string): Removed.
10740 (grub_efi_stall): New function.
10741 (grub_stop): Likewise.
10742 (grub_get_rtc): Likewise.
10743
10744 * include/grub/efi/efi.h (grub_efi_output_string): Removed.
10745 (grub_efi_stall): New prototype.
10746 (grub_efi_allocate_pages): Likewise.
10747 (grub_efi_free_pages): Likewise.
10748 (grub_efi_get_memory_map): Likewise.
10749 (grub_efi_mm_init): Likewise.
10750 (grub_efi_mm_fini): Likewise.
10751 (grub_efi_init): Likewise.
10752 (grub_efi_fini): Likewise.
10753
10754 * include/grub/i386/efi/time.h: Do not include
10755 grub/symbol.h. Include grub/efi/time.h.
10756 (GRUB_TICKS_PER_SECOND): Removed.
10757 (grub_get_rtc): Likewise.
10758
10759 * include/grub/efi/api.h (struct grub_efi_memory_descriptor):
10760 Added padding. The EFI spec is buggy.
10761 (GRUB_EFI_BLACK): New macro.
10762 (GRUB_EFI_BLUE): Likewise.
10763 (GRUB_EFI_GREEN): Likewise.
10764 (GRUB_EFI_CYAN): Likewise.
10765 (GRUB_EFI_RED): Likewise.
10766 (GRUB_EFI_MAGENTA): Likewise.
10767 (GRUB_EFI_BROWN): Likewise.
10768 (GRUB_EFI_LIGHTGRAY): Likewise.
10769 (GRUB_EFI_BRIGHT): Likewise.
10770 (GRUB_EFI_DARKGRAY): Likewise.
10771 (GRUB_EFI_LIGHTBLUE): Likewise.
10772 (GRUB_EFI_LIGHTGREEN): Likewise.
10773 (GRUB_EFI_LIGHTCYAN): Likewise.
10774 (GRUB_EFI_LIGHTRED): Likewise.
10775 (GRUB_EFI_LIGHTMAGENTA): Likewise.
10776 (GRUB_EFI_YELLOW): Likewise.
10777 (GRUB_EFI_WHITE): Likewise.
10778 (GRUB_EFI_BACKGROUND_BLACK): Likewise.
10779 (GRUB_EFI_BACKGROUND_BLUE): Likewise.
10780 (GRUB_EFI_BACKGROUND_GREEN): Likewise.
10781 (GRUB_EFI_BACKGROUND_CYAN): Likewise.
10782 (GRUB_EFI_BACKGROUND_RED): Likewise.
10783 (GRUB_EFI_BACKGROUND_MAGENTA): Likewise.
10784 (GRUB_EFI_BACKGROUND_BROWN): Likewise.
10785 (GRUB_EFI_BACKGROUND_LIGHTGRAY): Likewise.
10786 (GRUB_EFI_TEXT_ATTR): Likewise.
10787
10788 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added kern/efi/efi.c,
10789 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
10790 (kernel_mod_HEADERS): Added efi/time.h.
10791
10792 2006-04-18 Yoshinori K. Okuji <okuji@enbug.org>
10793
10794 * DISTLIST: Added conf/i386-efi.mk, conf/i386-efi.rmk,
10795 include/grub/efi/api.h, include/grub/efi/console_control.h,
10796 include/grub/efi/efi.h, include/grub/efi/pe32.h,
10797 include/grub/i386/efi/time.h, kern/efi/efi.c,
10798 kern/i386/efi/init.c, kern/i386/efi/startup.S,
10799 and util/i386/efi/grub-mkimage.c.
10800
10801 * Makefile.in (RMKFILES): Added i386-efi.rmk.
10802
10803 * genmk.rb (PModule#rule): Do not export symbols if
10804 #{prefix}_EXPORTS is set to "no".
10805
10806 * conf/i386-efi.mk: New file.
10807 * conf/i386-efi.rmk: Likewise.
10808 * include/grub/efi/api.h: Likewise.
10809 * include/grub/efi/console_control.h: Likewise.
10810 * include/grub/efi/efi.h: Likewise.
10811 * include/grub/efi/pe32.h: Likewise.
10812 * include/grub/i386/efi/time.h: Likewise.
10813 * kern/efi/efi.c: Likewise.
10814 * kern/i386/efi/init.c: Likewise.
10815 * kern/i386/efi/startup.S: Likewise.
10816 * util/i386/efi/grub-mkimage.c: Likewise.
10817
10818 2006-04-17 Marco Gerards <marco@gnu.org>
10819
10820 * include/grub/script.h: Include <grub/parser.h> and
10821 "grub_script.tab.h".
10822 (struct grub_lexer_param): New struct.
10823 (struct grub_parser_param): Likewise.
10824 (grub_script_create_arglist): Pass the state in an argument.
10825 (grub_script_add_arglist): Likewise.
10826 (grub_script_create_cmdline): Likewise.
10827 (grub_script_create_cmdblock): Likewise.
10828 (grub_script_create_cmdif): Likewise.
10829 (grub_script_create_cmdmenu): Likewise.
10830 (grub_script_add_cmd): Likewise.
10831 (grub_script_arg_add): Likewise.
10832 (grub_script_lexer_ref): Likewise.
10833 (grub_script_lexer_deref): Likewise.
10834 (grub_script_lexer_record_start): Likewise.
10835 (grub_script_lexer_record_stop): Likewise.
10836 (grub_script_mem_record): Likewise.
10837 (grub_script_mem_record_stop): Likewise.
10838 (grub_script_malloc): Likewise.
10839 (grub_script_yylex): Likewise.
10840 (grub_script_yyparse): Likewise.
10841 (grub_script_yyerror): Likewise.
10842 (grub_script_yylex): Likewise.
10843 (grub_script_lexer_init): Return the state.
10844
10845 * normal/lexer.c (grub_script_lexer_state): Removed variable.
10846 (grub_script_lexer_done): Likewise.
10847 (grub_script_lexer_getline): Likewise.
10848 (grub_script_lexer_refs): Likewise.
10849 (script): Likewise.
10850 (newscript): Likewise.
10851 (record): Likewise.
10852 (recording): Likewise.
10853 (recordpos): Likewise.
10854 (recordlen): Likewise.
10855 (grub_script_lexer_init): Return the state instead of setting
10856 global variables.
10857 (grub_script_lexer_ref): Use the newly added argument for state
10858 instead of globals.
10859 (grub_script_lexer_deref): Likewise.
10860 (grub_script_lexer_record_start): Likewise.
10861 (grub_script_lexer_record_stop): Likewise.
10862 (recordchar): Likewise.
10863 (nextchar): Likewise.
10864 (grub_script_yylex2): Likewise.
10865 (grub_script_yylex): Likewise.
10866 (grub_script_yyerror): Likewise.
10867
10868 * normal/parser.y (func_mem): Removed variable.
10869 (menu_entry): Likewise.
10870 (err): Likewise.
10871 (%lex-param): New parser option.
10872 (%parse-param): Likewise.
10873 (script): Always return the AST.
10874 (argument): Pass the state around.
10875 (arguments): Likewise.
10876 (grubcmd): Likewise.
10877 (commands): Likewise.
10878 (function): Likewise.
10879 (menuentry): Likewise.
10880 (if_statement): Likewise.
10881 (if): Likewise.
10882
10883 * normal/script.c (grub_script_memused): Removed variable.
10884 (grub_script_parsed): Likewise.
10885 (grub_script_malloc): Added a state argument. Use that instead of
10886 global variables.
10887 (grub_script_mem_record): Likewise.
10888 (grub_script_mem_record_stop): Likewise.
10889 (grub_script_arg_add): Likewise.
10890 (grub_script_add_arglist): Likewise.
10891 (grub_script_create_cmdline): Likewise.
10892 (grub_script_create_cmdif): Likewise.
10893 (grub_script_create_cmdmenu): Likewise.
10894 (grub_script_add_cmd): Likewise.
10895 (grub_script_parse): Setup the state before calling the parser.
10896
10897 2006-04-16 Marco Gerards <marco@gnu.org>
10898
10899 * normal/command.c (grub_command_init): Remove the title command.
10900
10901 * normal/lexer.c (grub_script_yylex): Renamed from this...
10902 (grub_script_yylex2): ... to this.
10903 (grub_script_yylex): New function. Temporary
10904 introduced to filter some tokens.
10905 (grub_script_yyerror): Print a newline.
10906
10907 * normal/main.c (read_config_file): Output information about the
10908 lines that contain errors. Wait for a key after all lines have
10909 been processed. Don't return an empty menu.
10910
10911 * normal/parser.y (func_mem): Don't initialize.
10912 (menu_entry): Likewise.
10913 (err): New variable.
10914 (script): Don't return anything when an error was encountered.
10915 (ws, returns): Removed rules.
10916 (argument): Disabled concatenated variable support.
10917 (arguments): Remove explicit separators.
10918 (grubcmd): Likewise.
10919 (function): Likewise.
10920 (menuentry): Likewise.
10921 (if): Likewise.
10922 (commands): Likewise. Add error handling.
10923
10924 * normal/script.c (grub_script_create_cmdline): If
10925 `grub_script_parsed' is 0, assume the parser encountered an error.
10926
10927 2006-04-02 Yoshinori K. Okuji <okuji@enbug.org>
10928
10929 * configure.ac: Add support for EFI. Fix the typo
10930 BUILD_LDDFLAGS. Restore the LDFLAGS after testing.
10931
10932 2006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
10933
10934 * util/unifont2pff.rb: Removed unnecessary byte ordering. Now
10935 foreign multibyte characters should be shown correctly.
10936
10937 2006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
10938
10939 * normal/main.c (grub_normal_menu_addentry): Fixed menu size
10940 calculation.
10941 (read_config_file): Made it to close file before returning.
10942
10943 2006-03-31 Vesa Jaaskelainen <chaac@nic.fi>
10944
10945 * DISTLIST: Added include/grub/i386/pc/vbeblit.h,
10946 include/grub/i386/pc/vbefill.h, video/i386/pc/vbeblit.c,
10947 video/i386/pc/vbefill.c.
10948
10949 * conf/i386-pc.rmk (vbe_mod_SOURCES): Added video/i386/pc/vbeblit.c,
10950 video/i386/pc/vbefill.c.
10951
10952 * include/grub/video.h (grub_video_blit_format): New enum.
10953 (grub_video_mode_info): Added new member blit_format.
10954 (grub_video_get_blit_format): New function prototype.
10955
10956 * include/grub/i386/pc/vbe.h (grub_video_vbe_get_video_ptr): New
10957 function prototype.
10958 (grub_video_vbe_map_rgb): Likewise.
10959 (grub_video_vbe_unmap_color): Likewise.
10960
10961 * include/grub/i386/pc/vbeblit.h: New file.
10962
10963 * include/grub/i386/pc/vbefill.h: New file.
10964
10965 * video/video.c (grub_video_get_blit_format): New function.
10966 (grub_video_vbe_get_video_ptr): Re-declared as non-static.
10967 (grub_video_vbe_map_rgb): Likewise.
10968 (grub_video_vbe_unmap_color): Likewise.
10969
10970 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Changed to use more
10971 optimized fills.
10972 (grub_video_vbe_blit_render_target): Changed to use more optimized
10973 blits.
10974 (grub_video_vbe_setup): Added detection for optimized settings.
10975 (grub_video_vbe_create_render_target): Likewise.
10976
10977 * video/i386/pc/vbeblit.c: New file.
10978
10979 * video/i386/pc/vbefill.c: New file.
10980
10981 2006-03-30 Vesa Jaaskelainen <chaac@nic.fi>
10982
10983 * font/manager.c (grub_font_get_glyph): Removed font fixup from
10984 here...
10985
10986 * util/unifont2pff.rb: ... and moved it to here. Improved argument
10987 parsing to support both hex and dec ranges. If filename was missing
10988 show usage information.
10989
10990 2006-03-14 Vesa Jaaskelainen <chaac@nic.fi>
10991
10992 * DISTLIST: Added include/grub/video.h, term/gfxterm.c,
10993 video/video.c, commands/videotest.c. Removed term/i386/pc/vesafb.c.
10994
10995 * conf/i386-pc.rmk (pkgdata_MODULES): Added video.mod,
10996 gfxterm.mod, videotest.mod. Removed vga.mod, vesafb.mod.
10997 (video_mod_SOURCES): Added.
10998 (video_mod_CFLAGS): Likewise.
10999 (video_mod_LDFLAGS): Likewise.
11000 (gfxterm_mod_SOURCES): Likewise.
11001 (gfxterm_mod_CFLAGS): Likewise.
11002 (gfxterm_mod_LDFLAGS): Likewise.
11003 (videotest_mod_SOURCES): Likewise.
11004 (videotest_mod_CFLAGS): Likewise.
11005 (videotest_mod_LDFLAGS): Likewise.
11006 (vesafb_mod_SOURCES): Removed.
11007 (vesafb_mod_CFLAGS): Likewise.
11008 (vesafb_mod_LDFLAGS): Likewise.
11009 (vga_mod_SOURCES): Likewise.
11010 (vga_mod_CFLAGS): Likewise.
11011 (vga_mod_LDFLAGS): Likewise.
11012
11013 * commands/videotest.c: New file.
11014
11015 * font/manager.c (fill_with_default_glyph): Modified to use
11016 grub_font_glyph.
11017 (grub_font_get_glyph): Likewise.
11018 (fontmanager): Renamed from this...
11019 (font_manager): ... to this.
11020
11021 * include/grub/font.h (grub_font_glyph): Added new structure.
11022 (grub_font_get_glyph): Modified to use grub_font_glyph.
11023
11024 * include/grub/misc.h (grub_abs): Added as inline function.
11025
11026 * include/grub/video.h: New file.
11027
11028 * include/grub/i386/pc/vbe.h (GRUB_VBE_STATUS_OK): New macro.
11029 (GRUB_VBE_MEMORY_MODEL_PACKED_PIXEL): Likewise.
11030 (GRUB_VBE_MEMORY_MODEL_DIRECT_COLOR): Likewise.
11031 (grub_vbe_get_controller_info): Renamed from this...
11032 (grub_vbe_bios_get_controller_info): ... to this.
11033 (grub_vbe_get_mode_info): Renamed from this...
11034 (grub_vbe_bios_get_mode_info): ... to this.
11035 (grub_vbe_set_mode): Renamed from this...
11036 (grub_vbe_bios_set_mode): ... to this.
11037 (grub_vbe_get_mode): Renamed from this...
11038 (grub_vbe_bios_get_mode): ... to this.
11039 (grub_vbe_set_memory_window): Renamed from this...
11040 (grub_vbe_bios_set_memory_window): ... to this.
11041 (grub_vbe_get_memory_window): Renamed from this...
11042 (grub_vbe_bios_get_memory_window): ... to this.
11043 (grub_vbe_set_scanline_length): Renamed from this...
11044 (grub_vbe_set_scanline_length): ... to this.
11045 (grub_vbe_get_scanline_length): Renamed from this...
11046 (grub_vbe_bios_get_scanline_length): ... to this.
11047 (grub_vbe_set_display_start): Renamed from this...
11048 (grub_vbe_bios_set_display_start): ... to this.
11049 (grub_vbe_get_display_start): Renamed from this...
11050 (grub_vbe_bios_get_display_start): ... to this.
11051 (grub_vbe_set_palette_data): Renamed from this...
11052 (grub_vbe_bios_set_palette_data): ... to this.
11053 (grub_vbe_set_pixel_rgb): Removed.
11054 (grub_vbe_set_pixel_index): Likewise.
11055
11056 * kern/i386/pc/startup.S (grub_vbe_get_controller_info): Renamed
11057 from this...
11058 (grub_vbe_bios_get_controller_info): ... to this.
11059 (grub_vbe_get_mode_info): Renamed from this...
11060 (grub_vbe_bios_get_mode_info): ... to this.
11061 (grub_vbe_set_mode): Renamed from this...
11062 (grub_vbe_bios_set_mode): ... to this.
11063 (grub_vbe_get_mode): Renamed from this...
11064 (grub_vbe_bios_get_mode): ... to this.
11065 (grub_vbe_set_memory_window): Renamed from this...
11066 (grub_vbe_bios_set_memory_window): ... to this.
11067 (grub_vbe_get_memory_window): Renamed from this...
11068 (grub_vbe_bios_get_memory_window): ... to this.
11069 (grub_vbe_set_scanline_length): Renamed from this...
11070 (grub_vbe_set_scanline_length): ... to this.
11071 (grub_vbe_get_scanline_length): Renamed from this...
11072 (grub_vbe_bios_get_scanline_length): ... to this.
11073 (grub_vbe_set_display_start): Renamed from this...
11074 (grub_vbe_bios_set_display_start): ... to this.
11075 (grub_vbe_get_display_start): Renamed from this...
11076 (grub_vbe_bios_get_display_start): ... to this.
11077 (grub_vbe_set_palette_data): Renamed from this...
11078 (grub_vbe_bios_set_palette_data): ... to this.
11079 (grub_vbe_bios_get_controller_info): Fixed problem with registers
11080 getting corrupted after calling it. Added more pushes and pops.
11081 (grub_vbe_bios_set_mode): Likewise.
11082 (grub_vbe_bios_get_mode): Likewise.
11083 (grub_vbe_bios_get_memory_window): Likewise.
11084 (grub_vbe_bios_set_scanline_length): Likewise.
11085 (grub_vbe_bios_get_scanline_length): Likewise.
11086 (grub_vbe_bios_get_display_start): Likewise.
11087 (grub_vbe_bios_set_palette_data): Likewise.
11088
11089 * normal/cmdline.c (cl_set_pos): Refresh the screen.
11090 (cl_insert): Likewise.
11091 (cl_delete): Likewise.
11092
11093 * term/gfxterm.c: New file.
11094
11095 * term/i386/pc/vesafb.c: Removed file.
11096
11097 * video/video.c: New file.
11098
11099 * video/i386/pc/vbe.c (real2pm): Added new function.
11100 (grub_video_vbe_draw_pixel): Likewise.
11101 (grub_video_vbe_get_video_ptr): Likewise.
11102 (grub_video_vbe_get_pixel): Likewise
11103 (grub_video_vbe_init): Likewise.
11104 (grub_video_vbe_fini): Likewise.
11105 (grub_video_vbe_setup): Likewise.
11106 (grub_video_vbe_get_info): Likewise.
11107 (grub_video_vbe_set_palette): Likewise.
11108 (grub_video_vbe_get_palette): Likewise.
11109 (grub_video_vbe_set_viewport): Likewise.
11110 (grub_video_vbe_get_viewport): Likewise.
11111 (grub_video_vbe_map_color): Likewise.
11112 (grub_video_vbe_map_rgb): Likewise.
11113 (grub_video_vbe_map_rgba): Likewise.
11114 (grub_video_vbe_unmap_color): Likewise.
11115 (grub_video_vbe_fill_rect): Likewise.
11116 (grub_video_vbe_blit_glyph): Likewise.
11117 (grub_video_vbe_blit_bitmap): Likewise.
11118 (grub_video_vbe_blit_render_target): Likewise.
11119 (grub_video_vbe_scroll): Likewise.
11120 (grub_video_vbe_swap_buffers): Likewise.
11121 (grub_video_vbe_create_render_target): Likewise.
11122 (grub_video_vbe_delete_render_target): Likewise.
11123 (grub_video_vbe_set_active_render_target): Likewise.
11124 (grub_vbe_set_pixel_rgb): Remove function.
11125 (grub_vbe_set_pixel_index): Likewise.
11126 (index_color_mode): Remove static variable.
11127 (active_mode): Likewise.
11128 (framebuffer): Likewise.
11129 (bytes_per_scan_line): Likewise.
11130 (grub_video_vbe_adapter): Added new static variable.
11131 (framebuffer): Likewise.
11132 (render_target): Likewise.
11133 (initial_mode): Likewise.
11134 (mode_in_use): Likewise.
11135 (mode_list): Likewise.
11136
11137 2006-03-10 Marco Gerards <marco@gnu.org>
11138
11139 * configure.ac (AC_INIT): Bumped to 1.93.
11140
11141 * DISTLIST: Added `include/grub/hfs.h'.
11142
11143 2006-02-01 Yoshinori K. Okuji <okuji@enbug.org>
11144
11145 * boot/i386/pc/boot.S (general_error): Before looping, try INT
11146 18H, which might help the BIOS falling back to next boot media.
11147
11148 2006-01-25 Yoshinori K. Okuji <okuji@enbug.org>
11149
11150 * util/i386/pc/grub-install.in: Escape a backslash. Reported by
11151 Poe Chen <poe.poechen@gmail.com>.
11152
11153 2006-01-17 Marco Gerards <marco@gnu.org>
11154
11155 * include/grub/normal.h: Include <grub/script.h>.
11156 (grub_command_list): Removed struct.
11157 (grub_command_list_t): Removed type.
11158 (grub_menu_entry): Remove members `num' and `command_list'. Add
11159 members `commands' and `sourcecode'.
11160 * include/grub/script.h: Add inclusion guards.
11161 (grub_script_cmd_menuentry): New struct.
11162 (grub_script_execute_menuentry): New prototype.
11163 (grub_script_lexer_record_start): Likewise.
11164 (grub_script_lexer_record_stop): Likewise.
11165 * normal/execute.c (grub_script_execute_menuentry): New function.
11166 * normal/lexer.c (record, recording, recordpos, recordlen): New
11167 variables.
11168 (grub_script_lexer_record_start): New function.
11169 (grub_script_lexer_record_stop): Likewise.
11170 (recordchar): Likewise.
11171 (nextchar): Likewise.
11172 (grub_script_yylex): Use `nextchar' to fetch new characters. Use
11173 2048 as the buffer size. Add the tokens `menuentry' and `@'.
11174 * normal/main.c: Include <grub/parser.h> and <grub/script.h>
11175 (current_menu): New variable.
11176 (free_menu): Mainly rewritten.
11177 (grub_normal_menu_addentry): New function.
11178 (read_config_file): Rewritten.
11179 * normal/menu.c (run_menu_entry): Mainly rewritten.
11180 * normal/menu_entry.c (make_screen): Rewritten the code to insert
11181 the menu entry.
11182 (run): Mainly rewritten.
11183 * normal/parser.y (menu_entry): New variable.
11184 (GRUB_PARSER_TOKEN_MENUENTRY): New token.
11185 (menuentry): New rule.
11186 (command): Add `menuentry'.
11187 (if_statement): Allow additional returns before `fi'.
11188 * normal/script.c (grub_script_create_cmdmenu): New function.
11189
11190 2006-01-03 Marco Gerards <marco@gnu.org>
11191
11192 * INSTALL: GNU Bison is required.
11193 * configure.ac: Rewritten the test to detect Bison.
11194 * Makefile.in (YACC): New variable. Reported by Xun Sun
11195 <xun.sun.cn@gmail.com>.
11196
11197 2006-01-03 Marco Gerards <marco@gnu.org>
11198
11199 * fs/hfsplus.c (grub_hfsplus_read_block): Convert the offset of
11200 the HFS+ filesystem to filesystem blocks.
11201 (grub_hfsplus_iterate_dir): Cast the `fileinfo' assignment so a
11202 GCC warning is silenced.
11203
11204 2006-01-03 Marco Gerards <marco@gnu.org>
11205
11206 * partmap/apple.c (apple_partition_map_iterate): Convert the data
11207 read from disk from big endian to host byte order.
11208
11209 2006-01-03 Hollis Blanchard <hollis@penguinppc.org>
11210
11211 * fs/hfs.c: Include <grub/hfs.h>. Added reference to the official
11212 documentation.
11213 (GRUB_HFS_EMBED_HFSPLUS_SIG): New macro.
11214 (grub_hfs_mount): Grammar fix in error. Make sure this is not an
11215 embedded HFS+ filesystem.
11216 (GRUB_HFS_MAGIC, grub_hfs_extent, grub_hfs_datarecord_t)
11217 (grub_hfs_sblock): Move from here...
11218 * include/grub/hfs.h: To here... New file.
11219 * fs/hfsplus.c: Include <grub/hfs.h>. Added reference to the official
11220 documentation.
11221 (GRUB_HFSPLUS_MAGIC, GRUB_HFSPLUSX_MAGIC, GRUB_HFSPLUS_SBLOCK):
11222 New macros.
11223 (grub_hfsplus_volheader): Change type of member `magic' to
11224 `grub_uint16_t'.
11225 (grub_hfsplus_data): Add new member `embedded_offset'.
11226 (grub_hfsplus_read_block): Add the HFS+ wrapper offset to the
11227 returned block.
11228 (grub_hfsplus_mount): Read the HFS+ wrapper if it exists.
11229 Calculate the offset.
11230
11231 2005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
11232
11233 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRP_ADDR):
11234 Removed.
11235 (GRUB_BOOT_MACHINE_DRP_SIZE): Likewise.
11236
11237 2005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
11238
11239 * kern/env.c (grub_env_set): Check if ENV->VALUE instead of
11240 ENV->NAME is NULL after allocating ENV->VALUE.
11241
11242 2005-12-25 Marco Gerards <marco@gnu.org>
11243
11244 * kern/env.c (grub_env_set): Rewritten the error handling code.
11245
11246 2005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
11247
11248 * geninit.sh: Made more robust, and more portable.
11249
11250 2005-12-25 Marco Gerards <marco@gnu.org>
11251
11252 Add support for Apple HFS+ filesystems.
11253
11254 * fs/hfsplus.c: New file.
11255
11256 * DISTLIST: Added `fs/hfsplus.c'.
11257
11258 * conf/common.rmk (pkgdata_MODULES): Add `hfsplus.mod'.
11259 (hfsplus_mod_SOURCES): New variable.
11260 (hfsplus_mod_CFLAGS): Likewise.
11261 (hfsplus_mod_LDFLAGS): Likewise.
11262 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/hfsplus.c'.
11263 (grub_setup_SOURCES): Likewise.
11264 (grub_mkdevicemap_SOURCES): Likewise.
11265 (grub_emu_SOURCES): Likewise.
11266 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11267
11268 * fs/fshelp.c (grub_fshelp_log2blksize): New function.
11269
11270 * include/grub/fshelp.h (grub_fshelp_log2blksize): new prototype.
11271
11272 2005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
11273
11274 * DISTLIST: Added geninitheader.sh, geninit.sh, commands/test.c,
11275 commands/i386/pc/play.c, conf/common.mk, conf/common.rmk,
11276 include/grub/parser.h, include/grub/script.h, kern/parser.c,
11277 kern/sparc64/cache.S, normal/execute.c, normal/function.c,
11278 normal/lexer.c, normal/parser.y, normal/script.c, and
11279 partmap/gpt.c.
11280 Removed kern/sparc64/cache.c.
11281
11282 * conf/common.rmk (DISTCLEANFILES): Added grub_script.tab.c,
11283 grub_script.tab.h, grub_modules_init.lst, grub_modules_init.h,
11284 grub_emu_init.c.
11285
11286 * configure.ac (AC_INIT): Bumped to 1.92.
11287
11288 2005-12-24 Vesa Jaaskelainen <chaac@nic.fi>
11289
11290 * kern/err.c (grub_error_push): Added new function to support error
11291 stacks.
11292 (grub_error_pop): Likewise.
11293 (grub_error_stack_items): New local variable to support error stacks.
11294 (grub_error_stack_pos): Likewise.
11295 (grub_error_stack_assert): Likewise.
11296 (GRUB_ERROR_STACK_SIZE): Added new define to configure maximum error
11297 stack depth.
11298 (grub_print_error): Added support to print errors from error stack.
11299
11300 * include/grub/err.h (grub_error_push): Added function prototype.
11301 (grub_error_pop): Likewise.
11302
11303 2005-12-09 Hollis Blanchard <hollis@penguinppc.org>
11304
11305 * configure.ac: Accept `powerpc64' as host_cpu.
11306 (amd64): Rename to `biarch32'.
11307
11308 * kern/powerpc/cache.S (grub_arch_sync_caches): Handle
11309 non-cacheline-aligned addresses.
11310
11311 * kern/dl.c (grub_dl_load_core): Add grub_dprintf messages.
11312 (grub_dl_flush_cache): Likewise. Only call `grub_arch_sync_caches'
11313 if `size' is non-zero.
11314
11315 2005-12-03 Marco Gerards <mgerards@xs4all.nl>
11316
11317 * conf/common.rmk (grub_modules_init.lst): Use `-printf "%P\n"'
11318 and `cd' to make sure the filename is not prefixed with a
11319 directory name.
11320 (pkgdata_MODULES): Add `gpt.mod'.
11321 (gpt_mod_SOURCES): New variable.
11322 (gpt_mod_CFLAGS): Likewise.
11323 (gpt_mod_LDFLAGS): Likewise.
11324
11325 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/gpt.c'.
11326
11327 * include/grub/pc_partition.h (GRUB_PC_PARTITION_TYPE_GPT_DISK):
11328 New macro.
11329
11330 * partmap/gpt.c: New file.
11331
11332 * partmap/pc.c (pc_partition_map_iterate): Don't continue when a
11333 GPT partition map is detected.
11334
11335 2005-12-03 Vincent Pelletier <subdino2004@yahoo.fr>
11336
11337 * commands/i386/pc/play.c: New file.
11338 * conf/i386-pc.rmk (pkgdata_MODULES): Added play.mod.
11339 (play_mod_SOURCES, play_mod_CFLAGS, play_mod_LDFLAGS): New
11340 macros.
11341
11342 2005-11-27 Marco Gerards <mgerards@xs4all.nl>
11343
11344 * include/grub/dl.h (GRUB_MOD_INIT): Use `__attribute__
11345 ((unused))' to silence gcc warning.
11346
11347 2005-11-26 Hollis Blanchard <hollis@penguinppc.org>
11348
11349 * configure.ac: Correct `AC_PROG_YACC' test.
11350
11351 2005-11-22 Hollis Blanchard <hollis@penguinppc.org>
11352
11353 * util/powerpc/ieee1275/grub-install.in: Run the mount point
11354 check before installing files.
11355
11356 2005-11-22 Mike Small <smallm@panix.com>
11357
11358 * util/powerpc/ieee1275/grub-install.in (grubdir): Fixed partition
11359 number regex so multidigit numbers are recognized correctly.
11360
11361 2005-11-22 Mike Small <smallm@panix.com>
11362
11363 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Add a
11364 debugging message before attempting to claim memory.
11365 (grub_rescue_cmd_initrd): Add a claim debugging message and try
11366 multiple addresses in case of failure.
11367
11368 2005-11-22 Hollis Blanchard <hollis@penguinppc.org>
11369
11370 * term/tparm.c (get_space): Remove empty `if' statement.
11371
11372 * fs/ufs.c (grub_ufs_find_file): Remove `grub_le_to_cpu32'.
11373
11374 * kern/parser.c (check_varstate): Rename `state' to 's'.
11375
11376 2005-11-22 Hollis Blanchard <hollis@penguinppc.org>
11377
11378 * partmap/acorn.c: Change `unsigned' to `unsigned int'. Move all
11379 variable definitions to the beginning of each function. Sort stack
11380 variables by size.
11381 (find): Rename to `acorn_partition_map_find'. Cast `grub_disk_read'
11382 `buf' argument to `char *'.
11383
11384 2005-11-22 Hollis Blanchard <hollis@penguinppc.org>
11385
11386 * conf/powerpc-ieee1275.rmk: Include conf/common.mk.
11387 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
11388 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
11389 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
11390 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
11391 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
11392 configfile.mod, search.mod, gzio.mod and test.mod.
11393 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
11394 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
11395 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
11396 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
11397 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
11398 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
11399 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
11400 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
11401 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
11402 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
11403 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
11404 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
11405 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
11406 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
11407 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
11408 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
11409 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
11410 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
11411 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
11412 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
11413 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
11414 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
11415 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Removed.
11416
11417 * conf/common.mk (grub_modules_init.lst): Use `find' instead of
11418 `grep --include'.
11419 (pkgdata_MODULES): Add test.mod.
11420
11421 2005-11-18 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
11422
11423 * genmk.rb: Fixed list rules moved to Makefile.in. Recognise
11424 appending to variables with "+=".
11425 (PModule): Use full pathname to generate *.lst filenames.
11426
11427 * Makefile.in: Fixed list rules moved from genmk.rb.
11428 (.DELETE_ON_ERROR): New special target.
11429 (RMKFILES): Add common.rmk and sparc64-ieee1275.rmk.
11430
11431 * conf/i386-pc.rmk: Include conf/common.mk.
11432 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
11433 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
11434 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
11435 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
11436 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
11437 configfile.mod, search.mod, gzio.mod and test.mod.
11438 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
11439 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
11440 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
11441 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
11442 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
11443 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
11444 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
11445 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
11446 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
11447 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
11448 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
11449 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
11450 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
11451 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
11452 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
11453 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
11454 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
11455 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
11456 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
11457 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
11458 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
11459 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
11460 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Move from
11461 here...
11462 * conf/common.rmk: ... to here. New file.
11463
11464 * conf/common.mk: New file.
11465
11466 2005-11-18 Yoshinori K. Okuji <okuji@enbug.org>
11467
11468 * conf/powerpc-ieee1275.rmk (grub_script.tab.h): Unified to ...
11469 (grub_script.tab.c): ... here.
11470
11471 * conf/sparc64-ieee1275.rmk (grub_script.tab.h): Unified to ...
11472 (grub_script.tab.c): ... here.
11473
11474 * conf/i386-pc.rmk (grub_script.tab.h): Unified to ...
11475 (grub_script.tab.c): ... here.
11476
11477 * normal/command.c (grub_command_find): Fixed a memory leak of
11478 MODULE_NAME. Reported by Mike Small <smallm@panix.com>.
11479
11480 2005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
11481
11482 * include/grub/symbol.h: (FUNCTION): Use double quotes instead of
11483 "@" which marks the start of a comment on ARM.
11484 (VARIABLE): Likewise.
11485
11486 2005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
11487
11488 Add support for Linux/ADFS partition tables.
11489
11490 * partmap/acorn.c: New file.
11491
11492 * include/grub/acorn_filecore.h: Likewise.
11493
11494 * DISTLIST: Added `partmap/acorn.c' and
11495 `include/grub/acorn_filecore.h'.
11496
11497 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
11498 `partmap/acorn.c'.
11499 (pkgdata_MODULES): Add `acorn.mod'.
11500 (acorn_mod_SOURCES): New variable.
11501 (acorn_mod_CFLAGS): Likewise.
11502
11503 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
11504 `partmap/acorn.c'.
11505 (pkgdata_MODULES): Add `acorn.mod'.
11506 (acorn_mod_SOURCES): New variable.
11507 (acorn_mod_CFLAGS): Likewise.
11508
11509 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/acorn.c'.
11510 (pkgdata_MODULES): Add `acorn.mod'.
11511 (acorn_mod_SOURCES): New variable.
11512 (acorn_mod_CFLAGS): Likewise.
11513 (acorn_mod_LDFLAGS): Likewise.
11514
11515 * include/types.h (grub_disk_addr_t): New typedef.
11516
11517 2005-11-13 Marco Gerards <mgerards@xs4all.nl>
11518
11519 * geninit.sh: New file.
11520
11521 * geninitheader.sh: Likewise.
11522
11523 * commands/boot.c (grub_boot_init, grub_boot_fini): Removed.
11524 * commands/cat.c (grub_cat_init, grub_cat_fini): Likewise.
11525 * commands/cmp.c (grub_cmp_init, grub_cmp_fini): Likewise.
11526 * commands/configfile.c (grub_configfile_init)
11527 (grub_configfile_fini): Likewise.
11528 * commands/default.c (grub_default_init, grub_default_fini):
11529 Likewise.
11530 * commands/help.c (grub_help_init, grub_help_fini): Likewise.
11531 * commands/ls.c (grub_ls_init, grub_ls_fini): Likewise.
11532 * commands/search.c (grub_search_init, grub_search_fini): Likewise.
11533 * commands/terminal.c (grub_terminal_init, grub_terminal_fini):
11534 Likewise.
11535 * commands/test.c (grub_test_init, grub_test_fini): Likewise.
11536 * commands/timeout.c (grub_timeout_init, grub_timeout_fini):
11537 Likewise.
11538 * commands/i386/pc/halt.c (grub_halt_init, grub_halt_fini): Likewise.
11539 * commands/ieee1275/halt.c (grub_halt_init, grub_halt_fini):
11540 Likewise.
11541 * commands/i386/pc/reboot.c (grub_reboot_init, grub_reboot_fini):
11542 Likewise.
11543 * commands/ieee1275/reboot.c (grub_reboot_init, grub_reboot_fini):
11544 Likewise.
11545 * disk/loopback.c (grub_loop_init, grub_loop_fini): Likewise.
11546 * fs/affs.c (grub_affs_init, grub_affs_fini): Likewise.
11547 * fs/ext2.c (grub_ext2_init, grub_ext2_fini): Likewise.
11548 * fs/fat.c (grub_fat_init, grub_fat_fini): Likewise.
11549 * fs/hfs.c (grub_hfs_init, grub_hfs_fini): Likewise.
11550 * fs/iso9660.c (grub_iso9660_init, grub_iso9660_fini): Likewise.
11551 * fs/jfs.c (grub_jfs_init, grub_jfs_fini): Likewise.
11552 * fs/minix.c (grub_minix_init, grub_minix_fini): Likewise.
11553 * fs/sfs.c (grub_sfs_init, grub_sfs_fini): Likewise.
11554 * fs/ufs.c (grub_ufs_init, grub_ufs_fini): Likewise.
11555 * fs/xfs.c (grub_xfs_init, grub_xfs_fini): Likewise.
11556 * normal/main.c (grub_normal_init, grub_normal_fini): Likewise.
11557 * partmap/amiga.c (grub_amiga_partition_map_init)
11558 (grub_amiga_partition_map_fini): Likewise.
11559 * partmap/apple.c (grub_apple_partition_map_init)
11560 (grub_apple_partition_map_fini): Likewise.
11561 * partmap/pc.c (grub_pc_partition_map_init)
11562 (grub_pc_partition_map_fini): Likewise.
11563 * partmap/sun.c (grub_sun_partition_map_init,
11564 grub_sun_partition_map_fini): Likewise.
11565 * term/terminfo.c (grub_terminal_init, grub_terminal_fini):
11566 Likewise.
11567
11568 * util/grub-emu.c: Include <grub_modules_init.h>.
11569 (main): Don't initialize and de-initialize any modules directly,
11570 use `grub_init_all' and `grub_fini_all' instead.
11571
11572 * term/i386/pc/vesafb.c (grub_vesafb_init): Renamed to
11573 `grub_vesafb_mod_init'.
11574 (grub_vesafb_fini): Renamed to `grub_vesafb_mod_fini'. Updated
11575 all users.
11576 * term/i386/pc/vga.c (grub_vga_init): Renamed to
11577 `grub_vga_mod_init'. Updated all users.
11578 (grub_vga_fini): Renamed to `grub_vga_mod_fini'.
11579
11580 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `grub_emu_init.c'.
11581 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c): New
11582 rules.
11583
11584 * include/grub/dl.h (GRUB_MOD_INIT): Add argument `name'.
11585 Generate a function to initialize the module in utilities.
11586 Updated all callers.
11587 (GRUB_MOD_FINI): Add argument `name'. Generate a function to
11588 initialize the module in utilities. Updated all callers.
11589
11590 2005-11-09 Hollis Blanchard <hollis@penguinppc.org>
11591
11592 * term/ieee1275/ofconsole.c (grub_ofconsole_cls): Use both the ANSI
11593 escape sequence and a literal ^L to clear the screen.
11594
11595 * commands/ieee1275/suspend.c (grub_cmd_suspend): Clear the screen
11596 when returning from Open Firmware.
11597
11598 2005-11-09 Hollis Blanchard <hollis@penguinppc.org>
11599
11600 * term/ieee1275/ofconsole.c (grub_ofconsole_width): New variable.
11601 (grub_ofconsole_height): Likewise.
11602 (grub_ofconsole_putchar): If `grub_curr_x' exceeds console width,
11603 manually insert a '\n'.
11604 (grub_ofconsole_getwh): Set and return `grub_ofconsole_width' and
11605 `grub_ofconsole_height'. Return early if these are already set.
11606
11607 2005-11-07 Vincent Pelletier <subdino2004@yahoo.fr>
11608
11609 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
11610 `commands/test.c', `fs/affs.c', `fs/sfs.c', `fs/xfs.c',
11611 `normal/execute.c', `normal/lexer.c', `io/gzio.c',
11612 `kern/parser.c', `grub_script.tab.c', `normal/function.c'
11613 and `normal/script.c'.
11614 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
11615 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
11616 (test_mod_SOURCES): New variable.
11617 (test_mod_CFLAGS): Likewise.
11618 (test_mod_LDFLAGS): Likewise.
11619 (pkgdata_MODULES): Add `test.mod'.
11620 (grub_script.tab.c): New rule.
11621 (grub_script.tab.h): Likewise.
11622
11623 2005-11-07 Marco Gerards <mgerards@xs4all.nl>
11624
11625 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
11626 `commands/test.c', `normal/execute.c', `normal/lexer.c',
11627 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
11628 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
11629 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
11630 (test_mod_SOURCES): New variable.
11631 (test_mod_CFLAGS): Likewise.
11632 (pkgdata_MODULES): Add `test.mod'.
11633 (grub_script.tab.c): New rule.
11634 (grub_script.tab.h): Likewise.
11635
11636 2005-11-06 Marco Gerards <mgerards@xs4all.nl>
11637
11638 Add initial scripting support.
11639
11640 * commands/test.c: New file.
11641 * include/grub/script.h: Likewise.
11642 * normal/execute.c: Likewise.
11643 * normal/function.c: Likewise.
11644 * normal/lexer.c: Likewise.
11645 * normal/parser.y: Likewise.
11646 * normal/script.c: Likewise.
11647
11648 * configure.ac: Add `AC_PROG_YACC' test.
11649
11650 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/test.c',
11651 `normal/execute.c', `normal/lexer.c', `grub_script.tab.c',
11652 `normal/function.c' and `normal/script.c'.
11653 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
11654 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
11655 (test_mod_SOURCES, test_mod_CFLAGS, test_mod_LDFLAGS): New
11656 variables.
11657 (pkgdata_MODULES): Add `test.mod'.
11658 (grub_script.tab.c): New rule.
11659 (grub_script.tab.h): Likewise.
11660
11661 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TEST_FAILURE'.
11662
11663 * include/grub/normal.h (grub_test_init): New prototype.
11664 (grub_test_fini): Likewise.
11665
11666 * normal/command.c: Include <grub/script.h>.
11667 (grub_command_execute): Rewritten.
11668
11669 * util/grub-emu.c (main): Call `grub_test_init' and
11670 `grub_test_fini'.
11671
11672 2005-11-03 Hollis Blanchard <hollis@penguinppc.org>
11673
11674 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Initialize `msecs'
11675 to 0.
11676 * term/ieee1275/ofconsole.c (grub_ofconsole_checkkey): Return -1 if
11677 there are no pending characters.
11678
11679 2005-11-03 Hollis Blanchard <hollis@penguinppc.org>
11680
11681 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_get_devname): Use
11682 `grub_strndup' to drop device arguments. Replace unnecessary
11683 `grub_strndup' with `grub_strdup'.
11684
11685 2005-11-03 Hollis Blanchard <hollis@penguinppc.org>
11686
11687 * kern/term.c (grub_cls): Do not call grub_cur_term->cls() if the
11688 `debug' environment variable has been set.
11689
11690 2005-11-02 Hollis Blanchard <hollis@penguinppc.org>
11691
11692 * Makefile.in (install-local): Use $(DATA).
11693 (uninstall): Likewise.
11694 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Move grub-mkimage...
11695 (sbin_UTILITIES): ... to here.
11696 (sbin_SCRIPTS): New variable.
11697 (grub_install_SOURCES): New variable.
11698 * util/powerpc/ieee1275/grub-install.in: New file.
11699 * util/powerpc/ieee1275/grub-mkimage.c (kernel_path): Remove
11700 variable.
11701 (add_segments): Call `grub_util_get_path'.
11702
11703 2005-10-28 Yoshinori K. Okuji <okuji@enbug.org>
11704
11705 From Timothy Baldwin:
11706 * commands/ls.c (grub_ls_list_files): Close FILE with
11707 grub_file_close.
11708 * kern/misc.c (grub_vsprintf): Terminate the string S with NUL.
11709
11710 2005-10-24 Marco Gerards <mgerards@xs4all.nl>
11711
11712 * include/grub/parser.h: New file.
11713
11714 * kern/parser.c: Likewise.
11715
11716 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/parser.c'.
11717 (grub_setup_SOURCES): Likewise.
11718 (grub_probefs_SOURCES): Likewise.
11719 (grub_emu_SOURCES): Likewise.
11720 (kernel_img_HEADERS): Add `parser.h'.
11721
11722 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
11723 (grub_emu_SOURCES): Add `kern/parser.c'.
11724 (grubof_SOURCES): Likewise.
11725
11726 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
11727 (grubof_SOURCES): Add `kern/parser.c'.
11728
11729 * include/grub/misc.h (grub_split_cmdline): Removed prototype.
11730
11731 * kern/misc.c (grub_split_cmdline): Removed function.
11732
11733 * kern/rescue.c: Include <grub/parser.h>.
11734 (grub_enter_rescue_mode): Use `grub_parser_split_cmdline' instead
11735 of `grub_split_cmdline'.
11736
11737 * normal/command.c: Include <grub/parser.h>.
11738 (grub_command_execute): Use `grub_parser_split_cmdline' instead
11739 of `grub_split_cmdline'.
11740
11741 * normal/completion.c: Include <grub/parser.h>.
11742 (cmdline_state): New variable.
11743 (iterate_dir): End the filename with a quote depending on the
11744 command line state.
11745 (get_state): new function.
11746 (grub_normal_do_completion): Use `grub_parser_split_cmdline' to
11747 split the arguments and determine the current argument. When the
11748 argument string is not quoted, escape all spaces.
11749
11750 2005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
11751
11752 * normal/sparc64/setjmp.S: New file.
11753
11754 2005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
11755
11756 * include/grub/sparc64/libgcc.h: New file.
11757 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Remove -Av9.
11758 (normal_mod_SOURCES): Use normal/sparc64/setjmp.S instead of
11759 normal/sparc64/setjmp.c.
11760
11761 2005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
11762
11763 * kern/sparc64/dl.c: Rewritten for SPARCV9 ELF.
11764 * kern/sparc64/cache.S: New file.
11765 * kern/sparc64/cache.c: Removed.
11766 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Add -Av9.
11767 (COMMON_CFLAGS): Add -mno-app-regs. Remove -mcpu=v9 and
11768 -mtune=ultrasparc.
11769 (COMMON_LDFLAGS): Add -melf64_sparc.
11770 (grubof_HEADERS): Add sparc64/libgcc.h and machine/kernel.h.
11771 (grubof_SOURCES): Use cache.S instead of cache.c.
11772 (grubof_LDFLAGS): Add -mno-app-regs. Replace "-Xlinker
11773 --oformat -Xlinker elf64-sparc" by "-Bstatic,-melf64_sparc".
11774 (pkgdata_MODULES): Uncomment. Leave linux.mod and _linux.mod
11775 commented though.
11776 (normal_mod_SOURCES): Add normal/completion.c and normal/misc.c.
11777 (_linux_mod_SOURCES, _linux_mod_CFLAGS, linux_mod_SOURCES)
11778 (linux_mod_CFLAGS): Commented out.
11779 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS): New macro, commented
11780 out because module isn't built.
11781 (fshelp_mod_LDFLAGS, fat_mod_LDFLAGS, ext2_mod_LDFLAGS)
11782 (ufs_mod_LDFLAGS, minix_mod_LDFLAGS, hfs_mod_LDFLAGS)
11783 (jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS, normal_mod_LDFLAGS)
11784 (hello_mod_LDFLAGS, boot_mod_LDFLAGS, terminal_mod_LDFLAGS)
11785 (ls_mod_LDFLAGS, cmp_mod_LDFLAGS, cat_mod_LDFLAGS)
11786 (font_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
11787 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
11788 (suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS)
11789 (help_mod_LDFLAGS, default_mod_LDFLAGS, timeout_mod_LDFLAGS)
11790 (configfile_mod_LDFLAGS, search_mod_LDFLAGS, xfs_mod_SOURCES)
11791 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
11792 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
11793 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, gzio_mod_SOURCES)
11794 (gzio_mod_CFLAGS, gzio_mod_LDFLAGS): New macro.
11795
11796 2005-10-20 Yoshinori K. Okuji <okuji@enbug.org>
11797
11798 * util/i386/pc/grub-probefs.c (main): Call grub_xfs_init and
11799 grub_xfs_fini. Do not call grub_hfs_init or grub_hfs_fini any
11800 longer, because HFS should not be used on PC.
11801
11802 2005-10-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
11803
11804 * io/gzio.c (grub_gzio_read): Use OFFSET instead of FILE->OFFSET
11805 consistently within the loop.
11806
11807 2005-10-15 Marco Gerards <mgerards@xs4all.nl>
11808
11809 * fs/xfs.c (grub_xfs_iterate_dir): Detect an error if part of a
11810 directory can not be read.
11811
11812 2005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
11813
11814 * configure.ac (AC_INIT): Increase the version number to 1.91.
11815
11816 * DISTLIST: Added include/grub/terminfo.h, include/grub/tparm.h,
11817 include/grub/i386/pc/serial.h, term/terminfo.c, term/tparm.c and
11818 term/i386/pc/serial.c.
11819
11820 2005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
11821
11822 * kern/file.c (grub_file_seek): Seeking to an offset equal to a
11823 file size must be permitted.
11824
11825 * kern/i386/pc/startup.S (multiboot_trampoline): Fix a mistake
11826 between %ah and %al.
11827
11828 2005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
11829
11830 * fs/xfs.c (grub_xfs_iterate_dir): Change the type of BLK to
11831 grub_uint64_t.
11832 Call the hook with a NUL-terminated filename.
11833 (grub_xfs_mount): Use grub_be_to_cpu32 instead of
11834 grub_cpu_to_be32.
11835
11836 * kern/term.c (cursor_state): New variable.
11837 (grub_term_set_current): Reset the cursor state on a new
11838 terminal.
11839 (grub_setcursor): Rewritten to use CURSOR_STATE.
11840 (grub_getcursor): New function.
11841
11842 * include/grub/term.h (grub_getcursor): New prototype.
11843
11844 * io/gzio.c (test_header): Align BUF for accessing it as 32-bit
11845 integers on ARM. Reported by Timothy Baldwin
11846 <T.E.Baldwin99@members.leeds.ac.uk>.
11847
11848 2005-10-11 Marco Gerards <mgerards@xs4all.nl>
11849
11850 * fs/sfs.c (grub_sfs_open): Don't free `data->label' if it is not
11851 allocated.
11852 (grub_sfs_dir): Likewise.
11853
11854 2005-10-09 Marco Gerards <mgerards@xs4all.nl>
11855
11856 Add support for the SFS filesystem.
11857
11858 * fs/sfs.c: New file.
11859
11860 * DISTLIST: Added `fs/sfs.c'.
11861
11862 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/sfs.c'.
11863 (grub_probefs_SOURCES): Likewise.
11864 (grub_emu_SOURCES): Likewise.
11865 (pkgdata_MODULES): Add `sfs.mod'.
11866 (sfs_mod_SOURCES): New variable.
11867 (sfs_mod_CFLAGS): Likewise.
11868 (sfs_mod_LDFLAGS): Likewise.
11869
11870 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/sfs.c'.
11871 (pkgdata_MODULES): Add `sfs.mod'.
11872 (sfs_mod_SOURCES): New variable.
11873 (sfs_mod_CFLAGS): Likewise.
11874
11875 * util/grub-emu.c (main): Call `grub_sfs_init' and
11876 `grub_sfs_fini'.
11877
11878 * include/grub/fs.h (grub_sfs_init): New prototype.
11879 (grub_sfs_fini): Likewise.
11880
11881 2005-10-07 Marco Gerards <mgerards@xs4all.nl>
11882
11883 Add support for the AFFS filesystem.
11884
11885 * fs/affs.c: New file.
11886
11887 * DISTLIST: Added `fs/affs.c'.
11888
11889 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/affs.c'.
11890 (grub_probefs_SOURCES): Likewise.
11891 (grub_emu_SOURCES): Likewise.
11892 (pkgdata_MODULES): Add `affs.mod'.
11893 (affs_mod_SOURCES): New variable.
11894 (affs_mod_CFLAGS): Likewise.
11895 (affs_mod_LDFLAGS): Likewise.
11896
11897 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/affs.c'.
11898 (pkgdata_MODULES): Add `affs.mod'.
11899 (affs_mod_SOURCES): New variable.
11900 (affs_mod_CFLAGS): Likewise.
11901
11902 * util/grub-emu.c (main): Call `grub_affs_init' and
11903 `grub_affs_fini'.
11904
11905 * include/grub/fs.h (grub_affs_init): New prototype.
11906 (grub_affs_fini): Likewise.
11907
11908 2005-10-01 Marco Gerards <mgerards@xs4all.nl>
11909
11910 * fs/xfs.c (grub_xfs_iterate_dir): Add parentheses.
11911
11912 2005-10-01 Marco Gerards <mgerards@xs4all.nl>
11913
11914 * configure.ac: Accept `x86_64' as host_cpu. In that case add
11915 `-m32' to CFLAGS.
11916
11917 * genmk.rb (class PModule): Always use `$(#{prefix}_LDFLAGS)' when
11918 linking.
11919
11920 * conf/i386-pc.rmk (COMMON_CFLAGS): Add `-m32'.
11921 (COMMON_LDFLAGS): New variable.
11922 (kernel_img_LDFLAGS): Include `COMMON_FLAGS'.
11923 (_chain_mod_LDFLAGS, fshelp_mod_LDFLAGS, fat_mod_LDFLAGS)
11924 (ext2_mod_LDFLAGS, ufs_mod_LDFLAGS, minix_mod_LDFLAGS)
11925 (hfs_mod_LDFLAGS, jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS)
11926 (xfs_mod_LDFLAGS, _linux_mod_LDFLAGS, linux_mod_LDFLAGS)
11927 (normal_mod_LDFLAGS, hello_mod_LDFLAGS, boot_mod_LDFLAGS)
11928 (terminal_mod_LDFLAGS, ls_mod_LDFLAGS, cmp_mod_LDFLAGS)
11929 (cat_mod_LDFLAGS, help_mod_LDFLAGS, reboot_mod_LDFLAGS)
11930 (halt_mod_LDFLAGS, vga_mod_LDFLAGS, font_mod_LDFLAGS)
11931 (terminfo_mod_LDFLAGS, serial_mod_LDFLAGS, _multiboot_mod_LDFLAGS)
11932 (multiboot_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
11933 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
11934 (default_mod_LDFLAGS, timeout_mod_LDFLAGS, configfile_mod_LDFLAGS)
11935 (vbe_mod_LDFLAGS, vesafb_mod_LDFLAGS, vbeinfo_mod_LDFLAGS)
11936 (vbetest_mod_LDFLAGS, search_mod_LDFLAGS, gzio_mod_LDFLAGS): New
11937 variables.
11938 (normal_mod_ASFLAGS): Add `-m32'.
11939
11940 * include/grub/types.h (grub_host_addr_t, grub_host_off_t)
11941 (grub_host_size_t, grub_host_ssize_t): New types.
11942 (grub_addr_t, grub_off_t, grub_size_t, grub_ssize_t): Make type
11943 dependent of `GRUB_CPU_SIZEOF_VOID_P' instead on
11944 `GRUB_HOST_SIZEOF_VOID_P'.
11945
11946 * include/grub/kernel.h (struct grub_module_header): Type of
11947 member offset changed to `grub_host_off_t'. Type of member size
11948 changed to `grub_host_size_t'.
11949 (struct grub_module_info): Type of member offset changed to
11950 `grub_host_off_t'. Type of member size changed to
11951 `grub_host_size_t'.
11952
11953 2005-09-29 Yoshinori K. Okuji <okuji@enbug.org>
11954
11955 Make GRUB's kernel compliant to Multiboot Specification.
11956
11957 * kern/i386/pc/startup.S (multiboot_header): New label.
11958 (multiboot_entry): Likewise.
11959 (multiboot_trampoline): Likewise.
11960
11961 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
11962 Increased to 0x4A0.
11963
11964 * fs/xfs.c (grub_xfs_iterate_dir): Fix a syntax error. You may not
11965 put parentheses after a question mark.
11966 [!GRUB_UTIL] (my_mod): New variable.
11967
11968 * util/grub-emu.c (main): Call grub_xfs_init and grub_xfs_fini.
11969
11970 2005-09-28 Marco Gerards <mgerards@xs4all.nl>
11971
11972 Adds support for the XFS filesystem. Btrees are not supported
11973 yet.
11974
11975 * fs/xfs.c: New file.
11976
11977 * DISTLIST: Added `fs/xfs.c'.
11978
11979 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/xfs.c'.
11980 (grub_probefs_SOURCES): Likewise.
11981 (grub_emu_SOURCES): Likewise.
11982 (pkgdata_MODULES): Add `xfs.mod'.
11983 (xfs_mod_SOURCES): New variable.
11984 (xfs_mod_CFLAGS): Likewise.
11985
11986 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/xfs.c'.
11987 (pkgdata_MODULES): Add `xfs.mod'.
11988 (xfs_mod_SOURCES): New variable.
11989 (xfs_mod_CFLAGS): Likewise.
11990
11991 * util/grub-emu.c (main): Call `grub_xfs_init' and
11992 `grub_xfs_fini'.
11993
11994 * include/grub/fs.h (grub_xfs_init): New prototype.
11995 (grub_xfs_fini): Likewise.
11996
11997
11998 2005-09-18 Vesa Jaaskelainen <chaac@nic.fi>
11999
12000 * video/i386/pc/vbe.c (grub_vbe_set_video_mode): In indexed
12001 color modes, allow greater than 16 colors to be configured as
12002 a default palette.
12003
12004 2005-09-03 Yoshinori K. Okuji <okuji@enbug.org>
12005
12006 * normal/completion.c (complete_arguments): Add the qualifier
12007 const into OPTIONS.
12008
12009 From Omniflux <omniflux+lists@omniflux.com>:
12010 * include/grub/terminfo.h: New file.
12011 * include/grub/tparm.h: Likewise.
12012 * include/grub/i386/pc/serial.h: Likewise.
12013 * term/terminfo.c: Likewise.
12014 * term/tparm.c: Likewise.
12015 * term/i386/pc/serial.c: Likewise.
12016 * conf/i386-pc.rmk (pkgdata_MODULES): Added terminfo.mod and
12017 serial.mod.
12018 (terminfo_mod_SOURCES): New variable.
12019 (terminfo_mod_CFLAGS): Likewise.
12020 (serial_mod_SOURCES): Likewise.
12021 (serial_mod_CFLAGS): Likewise.
12022
12023 2005-08-31 Yoshinori K. Okuji <okuji@enbug.org>
12024
12025 * DISTLIST: Replaced boot/powerpc/ieee1275/crt0.S and
12026 boot/powerpc/ieee1275/cmain.c with kern/powerpc/ieee1275/crt0.S
12027 and kern/powerpc/ieee1275/cmain.c, respectively.
12028
12029 * boot/powerpc/ieee1275/crt0.S: Moved to ...
12030 * kern/powerpc/ieee1275/crt0.S: ... here.
12031
12032 * boot/powerpc/ieee1275/cmain.c: Moved to ...
12033 * kern/powerpc/ieee1275/cmain.c: ... here.
12034
12035 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Use
12036 kern/powerpc/ieee1275/crt0.S and kern/powerpc/ieee1275/cmain.c
12037 instead of boot/powerpc/ieee1275/crt0.S and
12038 boot/powerpc/ieee1275/cmain.c, respectively.
12039
12040 * boot/i386/pc/boot.S (lba_mode): Do not store the total number of
12041 sectors. It was not used anyway.
12042
12043 2005-08-30 Hollis Blanchard <hollis@penguinppc.org>
12044
12045 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): Fix
12046 `unused parameter' warning.
12047
12048 2005-08-30 Hollis Blanchard <hollis@penguinppc.org>
12049
12050 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): New
12051 function.
12052 (grub_ofconsole_term): Specify grub_ofconsole_getcharwidth as
12053 getcharwidth.
12054
12055 2005-08-28 Marco Gerards <metgerards@student.han.nl>
12056
12057 * include/grub/normal.h (enum grub_completion_type): Added
12058 `GRUB_COMPLETION_TYPE_ARGUMENT'.
12059
12060 * normal/cmdline.c (print_completion): Handle
12061 the `GRUB_COMPLETION_TYPE_ARGUMENT' type.
12062 * normal/menu_entry.c (store_completion): Likewise.
12063
12064 * normal/completion.c (complete_arguments): New function.
12065 (grub_normal_do_completion): Call `complete_arguments' when the
12066 current words start with a dash.
12067
12068 2005-08-27 Marco Gerards <metgerards@student.han.nl>
12069
12070 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Fix typo (use
12071 `gzio.mod' instead of `io.mod').
12072
12073 2005-08-22 Yoshinori K. Okuji <okuji@enbug.org>
12074
12075 * gendistlist.sh (EXTRA_DISTFILES): Added genfslist.sh.
12076 (DISTDIRS): Added io and video.
12077 Rewrite the search routine to make an output consistently.
12078
12079 * DISTLIST: Added conf/sparc64-ieee1275.mk,
12080 conf/sparc64-ieee1275.rmk, include/grub/gzio.h,
12081 include/grub/ieee1275/ieee1275.h, include/grub/ieee1275/ofdisk.h,
12082 io/gzio.c, kern/sparc64/cache.c, kern/sparc64/dl.c,
12083 kern/sparc64/ieee1275/init.c, kern/sparc64/ieee1275/openfw.c and
12084 util/powerpc/ieee1275/misc.c.
12085
12086 * include/grub/gzio.h: New file.
12087 * io/gzio.c: Likewise.
12088
12089 * kern/file.c (grub_file_close): Call grub_device_close only if
12090 FILE->DEVICE is not NULL.
12091
12092 * include/grub/mm.h [!NULL] (NULL): New macro.
12093
12094 * include/grub/err.h (GRUB_ERR_BAD_GZIP_DATA): New constant.
12095
12096 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added io/gzip.c.
12097 (pkgdata_MODULES): Added gzio.mod.
12098 (gzio_mod_SOURCES): New variable.
12099 (gzio_mod_CFLAGS): Likewise.
12100
12101 * conf/i386-pc.rmk (grub_emu_SOURCES): Added io/gzip.c.
12102 (pkgdata_MODULES): Added gzio.mod.
12103 (gzio_mod_SOURCES): New variable.
12104 (gzio_mod_CFLAGS): Likewise.
12105
12106 * commands/cat.c: Include grub/gzio.h.
12107 (grub_cmd_cat): Use grub_gzfile_open instead of
12108 grub_file_open.
12109
12110 * commands/cmp.c: Include grub/gzio.h.
12111 (grub_cmd_cmp): Use grub_gzfile_open instead of
12112 grub_file_open.
12113
12114 * loader/i386/pc/multiboot.c: Include grub/gzio.h.
12115 (grub_rescue_cmd_multiboot): Use grub_gzfile_open instead of
12116 grub_file_open.
12117 (grub_rescue_cmd_module): Likewise.
12118
12119 2005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
12120
12121 * conf/sparc64-ieee1275.rmk (grubof_SOURCES): The first file must be
12122 kern/sparc64/ieee1275/init.c because it contains _start.
12123 * conf/sparc64-ieee1275.mk: Generated from conf/sparc64-ieee1275.rmk.
12124
12125 2005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
12126
12127 * configure.ac: Add support for sparc64 host with ieee1275
12128 firmware.
12129 * configure: Generated from configure.ac.
12130 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Use grub_ssize_t
12131 instead of int.
12132 (grub_ofdisk_read): Likewise.
12133 (grub_ofdisk_open): Use %p to print pointer values, and cast the
12134 pointers as (void *) to remove a warning.
12135 (grub_ofdisk_close): Likewise.
12136 (grub_ofdisk_read): Likewise.
12137 * kern/ieee1275/ieee1275.c (grub_ieee1275_exit): This never
12138 returns, so make it return void to remove a warning.
12139 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_exit):
12140 Corresponding prototype change.
12141 * kern/mm.c (grub_mm_init_region): Use %p to print pointer
12142 values, and cast the pointers as (void *) to remove a warning.
12143 (grub_mm_dump): Likewise.
12144 * conf/sparc64-ieee1275.mk: New file.
12145 * conf/sparc64-ieee1275.rmk: Likewise.
12146 * include/grub/sparc64/setjmp.h: Likewise.
12147 * include/grub/sparc64/types.h: Likewise.
12148 * include/grub/sparc64/ieee1275/console.h: Likewise.
12149 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
12150 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
12151 * include/grub/sparc64/ieee1275/time.h: Likewise.
12152 * kern/sparc64/cache.c: Likewise.
12153 * kern/sparc64/dl.c: Likewise.
12154 * kern/sparc64/ieee1275/init.c: Likewise.
12155 * kern/sparc64/ieee1275/openfw.c: Likewise.
12156
12157 2005-08-21 Yoshinori K. Okuji <okuji@enbug.org>
12158
12159 * util/console.c (grub_ncurses_putchar): If C is greater than
12160 0x7f, set C to a question mark.
12161 (grub_ncurses_getcharwidth): New function.
12162 (grub_ncurses_term): Specify grub_ncurses_getcharwidth as
12163 getcharwidth.
12164
12165 * normal/menu.c (print_entry): Made aware of Unicode. First,
12166 convert TITLE to UCS-4, and predict the cursor position by
12167 grub_getcharwidth.
12168
12169 * include/grub/misc.h (grub_utf8_to_ucs4): Specify the qualifier
12170 const to SRC.
12171 * kern/misc.c (grub_utf16_to_utf8): Likewise.
12172
12173 2005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
12174
12175 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Specify
12176 the boot file by the option BOOT_IMAGE. Use grub_stpcpy instead of
12177 grub_strcat.
12178
12179 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Specify the boot
12180 file by the option BOOT_IMAGE. Use grub_stpcpy instead of
12181 grub_strcpy and grub_strlen. Take it into account that a space
12182 character is inserted as a delimiter.
12183
12184 2005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
12185
12186 * partmap/pc.c (pc_partition_map_iterate): Include the value of an
12187 invalid magic in the error.
12188
12189 * commands/search.c: New file.
12190
12191 * util/grub-emu.c (main): Call grub_search_init and
12192 grub_search_fini.
12193
12194 * kern/rescue.c (grub_rescue_print_disks): Removed.
12195 (grub_rescue_print_devices): New function.
12196 (grub_rescue_cmd_ls): Use grub_device_iterate with
12197 grub_rescue_print_devices instead of grub_disk_dev_iterate with
12198 grub_rescue_print_disks.
12199
12200 * kern/partition.c (grub_partition_iterate): Return the result of
12201 PARTMAP->ITERATE instead of GRUB_ERRNO.
12202
12203 * kern/device.c: Include grub/partition.h.
12204 (grub_device_iterate): New function.
12205
12206 * include/grub/partition.h (grub_partition_iterate): Return int
12207 instead of grub_err_t.
12208
12209 * include/grub/normal.h [GRUB_UTIL] (grub_search_init): New
12210 prototype.
12211 [GRUB_UTIL] (grub_search_fini): Likewise.
12212
12213 * include/grub/device.h (grub_device_iterate): New prototype.
12214
12215 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
12216 commands/search.c.
12217 (pkgdata_MODULES): Added search.mod.
12218 (search_mod_SOURCES): New variable.
12219 (search_mod_CFLAGS): Likewise.
12220
12221 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/search.c.
12222 (pkgdata_MODULES): Added search.mod.
12223 (search_mod_SOURCES): New variable.
12224 (search_mod_CFLAGS): Likewise.
12225
12226 * commands/ls.c (grub_ls_list_disks): Renamed to ...
12227 (grub_ls_list_devices): ... this, and use grub_device_iterate.
12228 All callers changed.
12229
12230 * DISTLIST: Added commands/search.c.
12231
12232 2005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
12233
12234 * kern/term.c (grub_putchar): Use grub_utf8_to_ucs4 for the
12235 conversion.
12236 (grub_getcharwidth): New function.
12237
12238 * kern/misc.c (grub_utf8_to_ucs4): New function.
12239
12240 * include/grub/term.h (struct grub_term): Added a new member
12241 "getcharwidth".
12242 (grub_getcharwidth): New prototype.
12243
12244 * include/grub/misc.h (grub_utf8_to_ucs4): New prototype.
12245
12246 * term/i386/pc/console.c (map_char): New function. Segregated from
12247 grub_console_putchar.
12248 (grub_console_putchar): Use map_char.
12249 (grub_console_getcharwidth): New function.
12250 (grub_console_term): Specified grub_console_getcharwidth as
12251 getcharwidth.
12252
12253 * term/i386/pc/vga.c (grub_vga_getcharwidth): New function.
12254 (grub_vga_term): Specified grub_vga_getcharwidth as getcharwidth.
12255
12256 * term/i386/pc/vesafb.c (grub_virtual_screen_setup): Return
12257 GRUB_ERRNO.
12258 (grub_vesafb_init): Do not use RC. Instead, use GRUB_ERRNO. Rely
12259 on grub_strtoul completely.
12260 (write_char): Declare local variables in the beginning of the
12261 function.
12262 (grub_vesafb_getcharwidth): New function.
12263 (grub_vesafb_term): Specified grub_vesafb_getcharwidth as
12264 getcharwidth.
12265
12266 2005-08-19 Yoshinori K. Okuji <okuji@enbug.org>
12267
12268 * DISTLIST: Replace commands/i386/pc/vbe_list_modes.c and
12269 commands/i386/pc/vbe_test.c with commands/i386/pc/vbeinfo.c and
12270 commands/i386/pc/vbetest.c.
12271
12272 * video/i386/pc/vbe.c (grub_vbe_probe): If INFOBLOCK is not NULL,
12273 call grub_vbe_get_controller_info again, because the returned
12274 information is volatile.
12275 (grub_vbe_set_video_mode): Mostly rewritten.
12276 (grub_vbe_get_video_mode): Use grub_vbe_probe and use
12277 grub_vbe_status_t correctly.
12278 (grub_vbe_get_video_mode_info): Likewise.
12279 (grub_vbe_set_pixel_rgb): Use a switch statement rather than
12280 several if statements.
12281
12282 * commands/i386/pc/vbe_list_modes.c: Renamed to ...
12283 * commands/i386/pc/vbeinfo.c: ... this.
12284
12285 * commands/i386/pc/vbe_test.c: Renamed to ...
12286 * commands/i386/pc/vbetest.c: ... this.
12287
12288 * commands/i386/pc/vbeinfo.c (grub_cmd_vbe_list_modes): Renamed to
12289 ...
12290 (grub_cmd_vbeinfo): ... this. Save video modes before
12291 iterating. Skip a video mode, if it is not available, not enough
12292 information is given or it is monochrome. Show the memory
12293 model. Leave the interpretation of MODEVAR to grub_strtoul
12294 completely.
12295 (GRUB_MOD_INIT): Rename vbe_list_modes to vbeinfo.
12296 (GRUB_MOD_FINI): Likewise.
12297
12298 * commands/i386/pc/vbetest.c (grub_cmd_vbe_test): Renamed to ...
12299 (grub_cmd_vbetest): ... this. Don't print unnecessarily. Use
12300 grub_err_t instead of grub_uint32_t. Don't use SPTR. Remove a
12301 duplicated grub_env_get. Leave the interpretation of MODEVAR to
12302 grub_strtoul completely.
12303 (real2pm): Removed.
12304 (GRUB_MOD_INIT): Rename vbe_test to vbetest.
12305 (GRUB_MOD_FINI): Likewise.
12306
12307 * normal/misc.c: Include grub/mm.h.
12308
12309 * conf/i386-pc.rmk (pkgdata_MODULES): Replaced vbe_test.mod and
12310 vbe_list_modes with vbetest.mod and vbeinfo.mod.
12311 (vbe_list_modes_mod_SOURCES): Removed.
12312 (vbe_list_modes_mod_CFLAGS): Likewise.
12313 (vbe_test_mod_SOURCES): Likewise.
12314 (vbe_test_mod_CFLAGS): Likewise.
12315 (vbeinfo_mod_SOURCES): New variable.
12316 (vbeinfo_mod_CFLAGS): Likewise.
12317 (vbetest_mod_SOURCES): Likewise.
12318 (vbetest_mod_CFLAGS): Likewise.
12319
12320 2005-08-18 Yoshinori K. Okuji <okuji@enbug.org>
12321
12322 * normal/misc.c: New file.
12323
12324 * DISTLIST: Added normal/misc.c.
12325
12326 * partmap/amiga.c (amiga_partition_map_iterate): Add an argument
12327 DISK to HOOK. Call HOOK with DISK.
12328 * partmap/apple.c (apple_partition_map_iterate): Likewise.
12329 * partmap/pc.c (pc_partition_map_iterate): Likewise.
12330 * partmap/sun.c (sun_partition_map_iterate): Likewise.
12331
12332 * normal/menu_entry.c (struct screen): Added a new member
12333 "completion_shown".
12334 (completion_buffer): New global variable.
12335 (make_screen): Set SCREEN->COMPLETION_SHOWN to zero.
12336 (store_completion): New function.
12337 (complete): Likewise.
12338 (clear_completions): Likewise.
12339 (grub_menu_entry_run): If SCREEN->COMPLETION_SHOWN is non-zero,
12340 call clear_completions and reset SCREEN->COMPLETION_SHOWN. If C is
12341 a tab, call complete.
12342
12343 * normal/completion.c (disk_dev): Removed.
12344 (print_simple_completion): Likewise.
12345 (print_partition_completion): Likewise.
12346 (print_func): New global variable.
12347 (add_completion): Do not take the arguments WHAT or PRINT any
12348 longer. Added a new argument TYPE. Instead of printing directly,
12349 call PRINT_FUNC if not NULL.
12350 All callers changed.
12351 (complete_device): Use a local variable DEV instead of
12352 DISK_DEV. Do not move CURRENT_WORD to the end of a device name.
12353 (grub_normal_do_completion): Take a new argument HOOK. Do not
12354 initialize DISK_DEV. Initialize PRINT_FUNC to HOOK. If RET is an
12355 empty string, return NULL instead.
12356 All callers changed.
12357
12358 * normal/cmdline.c (print_completion): New function.
12359
12360 * kern/partition.c (grub_partition_iterate): Add an argument DISK
12361 to HOOK.
12362 All callers changed.
12363
12364 * kern/disk.c (grub_print_partinfo): Removed.
12365
12366 * include/grub/partition.h (struct grub_partition_map): Add a new
12367 argument DISK into HOOK of ITERATE.
12368 (grub_partition_iterate): Add a new argument DISK to HOOK.
12369
12370 * include/grub/normal.h (enum grub_completion_type): New enum.
12371 (grub_completion_type_t): New type.
12372 (GRUB_COMPLETION_TYPE_COMMAND): New constant.
12373 (GRUB_COMPLETION_TYPE_DEVICE): Likewise.
12374 (GRUB_COMPLETION_TYPE_PARTITION): Likewise.
12375 (GRUB_COMPLETION_TYPE_FILE): Likewise.
12376 (grub_normal_do_completion): Added a new argument HOOK.
12377 (grub_normal_print_device_info): New prototype.
12378
12379 * include/grub/disk.h (grub_print_partinfo): Removed.
12380
12381 * conf/i386-pc.rmk (grub_emu_SOURCES): Added normal/misc.c.
12382 (normal_mod_SOURCES): Likewise.
12383 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
12384 (normal_mod_SOURCES): Likewise.
12385
12386 * commands/ls.c (grub_ls_list_disks): Use
12387 grub_normal_print_device_info instead of grub_print_partinfo. Free
12388 PNAME.
12389 (grub_ls_list_files): Use grub_normal_print_device_info instead of
12390 duplicating the code.
12391
12392 2005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
12393
12394 * commands/i386/pc/vbe_list_modes.c: Update source formatting to
12395 follow GCS more precisely.
12396 * commands/i386/pc/vbe_test.c: Likewise.
12397 * include/grub/i386/pc/vbe.h: Likewise.
12398 * term/i386/pc/vesafb.c: Likewise.
12399 * video/i386/pc/vbe.c: Likewise.
12400
12401 2005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
12402
12403 * DISTLIST: Added term/i386/pc/vesafb.c
12404 DISTLIST: Added video/i386/pc/vbe.c
12405 DISTLIST: Added commands/i386/pc/vbe_list_modes.c.
12406 DISTLIST: Added commands/i386/pc/vbe_test.c.
12407 * commands/i386/pc/vbe_list_modes.c: New file.
12408 * commands/i386/pc/vbe_test.c: Likewise.
12409 * term/i386/pc/vesafb.c: Likewise.
12410 * video/i386/pc/vbe.c: Likewise.
12411 * include/grub/i386/pc/vbe.h (GRUB_VBE_DEFAULT_VIDEO_MODE): Added define.
12412 (grub_vbe_probe) Added prototype.
12413 (grub_vbe_set_video_mode) Likewise.
12414 (grub_vbe_get_video_mode) Likewise.
12415 (grub_vbe_get_video_mode_info) Likewise.
12416 (grub_vbe_set_pixel_rgb) Likewise.
12417 (grub_vbe_set_pixel_index) Likewise.
12418 * conf/i386-pc.rmk (pkgdata_MODULES): Added vbe.mod.
12419 (pkgdata_MODULES): Added vesafb.mod.
12420 (pkgdata_MODULES): Added vbe_list_modes.mod.
12421 (pkgdata_MODULES): Added vbe_test.mod.
12422 (vbe_mod_SOURCES): Added.
12423 (vbe_mod_CFLAGS): Likewise.
12424 (vesafb_mod_SOURCES): Likewise.
12425 (vesafb_mod_CFLAGS): Likewise.
12426 (vbe_list_modes_mod_SOURCES): Likewise.
12427 (vbe_list_modes_mod_CFLAGS): Likewise.
12428 (vbe_test_mod_SOURCES): Likewise.
12429 (vbe_test_mod_CFLAGS): Likewise.
12430
12431 2005-08-14 Yoshinori K. Okuji <okuji@enbug.org>
12432
12433 * normal/command.c (grub_command_execute): If INTERACTIVE is
12434 false and GRUB_COMMAND_FLAG_NO_ECHO is not specified, print
12435 CMDLINE. Disable the pager if INTERACTIVE is true.
12436 All callers are changed.
12437
12438 * normal/main.c (grub_normal_execute): Read command.lst and fs.lst
12439 before reading a config file.
12440 * normal/main.c (read_config_file): Even if a command is not
12441 found, register it if it is within an entry.
12442
12443 * util/grub-emu.c: Include sys/types.h and unistd.h.
12444 (options): Added --hold.
12445 (struct arguments): Added a new member "hold".
12446 (parse_opt): If KEY is 'H', set ARGS->HOLD to ARG or -1 if ARG is
12447 missing.
12448 (main): Initialize ARGS.HOLD to zero. Wait until ARGS.HOLD is
12449 cleared by a debugger, if it is not zero.
12450
12451 * include/grub/normal.h (grub_command_execute): Add an argument
12452 INTERACTIVE.
12453
12454 2005-08-14 Vesa Jaaskelainen <chaac@nic.fi>
12455
12456 * DISTLIST: Added include/grub/i386/pc/vbe.h.
12457
12458 2005-08-13 Yoshinori K. Okuji <okuji@enbug.org>
12459
12460 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Replace the test
12461 program with another one, because the old one didn't detect a bug
12462 in gcc-3.4. Always use regparm 2, because the new test is still
12463 not enough for gcc-4.0. Someone must investigate a simple test
12464 case which detects a bug in gcc-4.0.
12465
12466 2005-08-12 Yoshinori K. Okuji <okuji@enbug.org>
12467
12468 * DISTLIST: Added normal/completion.c.
12469
12470 * normal/completion.c: New file.
12471
12472 * term/i386/pc/console.c (grub_console_getwh): New function.
12473 (grub_console_term): Assign grub_console_getwh to getwh.
12474
12475 * normal/cmdline.c (grub_tab_complete): Removed. Now the same
12476 function is defined in normal/completion.c as
12477 grub_normal_do_completion.
12478 (grub_cmdline_get): Use grub_normal_do_completion instead of
12479 grub_tab_complete.
12480
12481 * kern/partition.c (grub_partition_map_iterate): Return 1 if HOOK
12482 returns non-zero, otherwise return 0.
12483 (grub_partition_iterate): First, probe the partition map. Then,
12484 call ITERATE only for this partition map.
12485
12486 * kern/misc.c (grub_strncmp): Rewritten.
12487
12488 * kern/disk.c (grub_disk_dev_iterate): Return 1 if P->ITERATE
12489 returns non-zero. Otherwise return 0.
12490
12491 * include/grub/partition.h (grub_partition_map_iterate): Return
12492 int instead of void.
12493
12494 * include/grub/normal.h (grub_normal_do_completion): New prototype.
12495
12496 * include/grub/misc.h (grub_strncmp): Change the type of N to
12497 grub_size_t.
12498
12499 * include/grub/disk.h (grub_disk_dev_iterate): Return int instead
12500 of void.
12501
12502 * normal/menu.c (draw_border): Cast GRUB_TERM_BORDER_WIDTH to
12503 unsigned explicitly before comparing it with I.
12504
12505 * kern/main.c (grub_env_write_root): Add the attribute unused into
12506 VAR.
12507
12508 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
12509 normal/completion.c.
12510 (normal_mod_SOURCES): Likewise.
12511 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
12512 (normal_mod_SOURCES): Likewise.
12513
12514 * normal/command.c (grub_iterate_commands): If ITERATE returns
12515 non-zero, return one immediately.
12516
12517 2005-08-09 Vesa Jaaskelainen <chaac@nic.fi>
12518
12519 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vbe.h.
12520 * kern/i386/pc/startup.S: Updated Global Descriptor table's
12521 descriptions.
12522 (grub_vbe_get_controller_info): New function.
12523 (grub_vbe_get_mode_info): Likewise.
12524 (grub_vbe_set_mode): Likewise.
12525 (grub_vbe_get_mode): Likewise.
12526 (grub_vbe_set_memory_window): Likewise.
12527 (grub_vbe_get_memory_window): Likewise.
12528 (grub_vbe_set_scanline_length): Likewise.
12529 (grub_vbe_get_scanline_length): Likewise.
12530 (grub_vbe_set_display_start): Likewise.
12531 (grub_vbe_get_display_start): Likewise.
12532 (grub_vbe_set_palette_data): Likewise.
12533 * include/grub/i386/pc/vbe.h: New file.
12534
12535 2005-08-08 Hollis Blanchard <hollis@penguinppc.org>
12536
12537 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
12538 kern/ieee1275/of.c with kern/ieee1275/ieee1275.c.
12539 * DISTLIST: Likewise.
12540 * kern/ieee1275/of.c: Moved to ...
12541 * kern/ieee1275/ieee1275.c: ... here.
12542
12543 2005-08-08 Hollis Blanchard <hollis@penguinppc.org>
12544
12545 * term/ieee1275/ofconsole.c: Include <grub/mm.h>.
12546 (grub_ofconsole_getwh): Cast -1 to type grub_ieee1275_ihandle_t.
12547 Pass 0 as `end' parameter to grub_strtoul().
12548
12549 2005-08-08 Hollis Blanchard <hollis@penguinppc.org>
12550
12551 * include/grub/powerpc/ieee1275/console.h: Do not include
12552 <grub/types.h>. Do not include <grub/symbol.h>. Remove ASM_FILE
12553 ifdef.
12554 (grub_console_cur_color): Remove i386-specific prototype.
12555 (grub_console_real_putchar): Likewise.
12556 (grub_console_checkkey): Likewise.
12557 (grub_console_getkey): Likewise.
12558 (grub_console_getxy): Likewise.
12559 (grub_console_gotoxy): Likewise.
12560 (grub_console_cls): Likewise.
12561 (grub_console_setcursor): Likewise.
12562 * kern/powerpc/ieee1275/init.c: Don't include <grub/console.h>.
12563 Include <grub/machine/console.h>.
12564 * term/ieee1275/ofconsole.c: Likewise.
12565
12566 2005-08-08 Yoshinori K. Okuji <okuji@enbug.org>
12567
12568 * Makefile.in (LIBLZO): New variable.
12569
12570 * configure.ac: Check for LZO version 2.
12571
12572 * util/i386/pc/grub-mkimage.c [HAVE_LZO_LZO1X_H]: Include
12573 lzo/lzo1x.h instead of lzo1x.h.
12574
12575 * conf/i386-pc.rmk (grub_mkimage_LDFLAGS): Use $(LIBLZO) instead
12576 of -llzo.
12577
12578 * util/i386/pc/grub-setup.c (main): Do not free PREFIX
12579 twice. Reported by Vladimir Serbinenko <phcoder@gmail.com>.
12580
12581 * partmap/pc.c (pc_partition_map_probe): Restore P->DATA after
12582 copying the data from PARTITION to P.
12583
12584 2005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
12585
12586 * kern/rescue.c (grub_rescue_cmd_rmmod): If the reference count is
12587 negative, unload the module.
12588
12589 * util/i386/pc/grub-setup.c (setup): The name of the PC partition
12590 map is "pc_partition_map" but not "pc".
12591 (usage): Fix the description. The options are --boot-image and
12592 --core-image but not --boot-file or --core-file.
12593 (main): If not specified explicitly, make BOOT_FILE and CORE_FILE
12594 based on DEFAULT_BOOT_FILE and DEFAULT_CORE_FILE with DIR or
12595 DEFAULT_DIRECTORY.
12596
12597 * util/i386/pc/grub-install.in: Do not specify --boot-file or
12598 --core-file. Specify INSTALL_DEVICE as an argument.
12599
12600 * util/console.c: Include config.h.
12601 [HAVE_NCURSeS_CURSES_H]: Include ncurses/curses.h.
12602 [HAVE_NCURSES_H]: Include ncurses.h.
12603 [HAVE_CURSES_H]: Include curses.h.
12604 [!A_NORMAL] (A_NORMAL): Defined as zero.
12605 [!A_STANDOUT] (A_STANDOUT): Likewise.
12606
12607 * conf/i386-pc.rmk (grub_emu_LDFLAGS): Use $(LIBCURSES) instead of
12608 -lncurses.
12609 * conf/powerpc-ieee1275.rmk (grub_emu_LDFLAGS): Likewise.
12610
12611 * configure.ac: Check for curses libraries and headers.
12612
12613 * Makefile.in (LIBCURSES): New variable.
12614
12615 * genmk.rb (Script::rule): Set the executable bits.
12616
12617 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): The
12618 name of the PC partition map is "pc_partition_map" but not "pc".
12619
12620 2005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
12621
12622 * util/i386/pc/grub-install.in (grub_probefs): New variable.
12623 (modules): Likewise.
12624 (usage): Added descriptions for --modules and --grub-probefs.
12625 Handle --modules and --grub-probefs. Save the arguments in MODULES
12626 and GRUB_PROBEFS, respectively.
12627 Auto-detect a filesystem module against GRUBDIR. If the result is
12628 empty and modules are not specified explicitly, abort the
12629 installation. Add the result to MODULES.
12630
12631 * DISTLIST: Removed boot/powerpc/ieee1275/ieee1275.c,
12632 disk/powerpc/ieee1275/ofdisk.c,
12633 include/grub/powerpc/ieee1275/init.h and
12634 term/powerpc/ieee1275/ofconsole.c.
12635 Added disk/ieee1275/ofdisk.c, kern/ieee1275/of.c and
12636 term/ieee1275/ofconsole.c.
12637
12638 * include/grub/powerpc/ieee1275/console.h: Resurrected.
12639
12640 * COPYING: Upgraded to the latest version. Only the address of the
12641 FSF office has changed.
12642
12643 2005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
12644
12645 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
12646 kern/ieee1275.c with kern/ieee1275/of.c.
12647
12648 * kern/ieee1275.c: Moved to ...
12649 * kern/ieee1275/of.c: ... here.
12650
12651 2005-08-06 Yoshinori K. Okuji <okuji@enbug.org>
12652
12653 * conf/i386-pc.rmk (kernel_img_HEADERS): Reordered for
12654 readability.
12655
12656 * config.guess: Updated to the latest version from gnulib.
12657 * config.sub: Likewise.
12658 * install.sh: Likewise.
12659 * mkinstalldirs: Likewise.
12660
12661 * include/grub/console.h: Removed. This file is arch-specific. Do
12662 not put this in include/grub.
12663
12664 * include/grub/i386/pc/console.h: Resurrected.
12665
12666 * util/console.c: Include grub/machine/console.h instead of
12667 grub/console.h.
12668 * util/grub-emu.c: Likewise.
12669
12670 2005-08-04 Marco Gerards <metgerards@student.han.nl>
12671
12672 * kern/term.c (grub_putcode): Use `grub_getwh' instead of
12673 hardcoded value.
12674
12675 From Vincent Pelletier <subdino2004@yahoo.fr>
12676 * include/grub/term.h (GRUB_TERM_WIDTH, GRUB_TERM_HEIGHT):
12677 Redefined to use grub_getwh.
12678 (grub_term): New member named getwh.
12679 (grub_getwh): New prototype.
12680 * kern/term.c (grub_getwh): New function.
12681 * term/i386/pc/console.c (grub_console_getwh): New function.
12682 (grub_console_term): New member `getwh'.
12683 * term/i386/pc/vga.c (grub_vga_getwh): New function.
12684 (grub_vga_term): New member `getwh'.
12685 * term/ieee1275/ofconsole.c (grub_ofconsole_readkey): Use
12686 grub_ssize_t.
12687 (grub_ofconsole_getw): New function.
12688 (grub_ofconsole_init): Use grub_ssize_t and unsigned char.
12689 (grub_ofconsole_term): New field named getwh and new initial
12690 value.
12691
12692 2005-08-03 Hollis Blanchard <hollis@penguinppc.org>
12693
12694 * include/grub/powerpc/ieee1275/ieee1275.h: Move ...
12695 * include/grub/ieee1275/ieee1275.h: ... to here. All users updated.
12696 Move `abort', `grub_reboot', and `grub_halt' prototypes ...
12697 * include/grub/powerpc/ieee1275/kernel.h: ... to here.
12698 * commands/ieee1275/halt.c: Include <grub/machine/kernel.h> instead
12699 of <grub/machine/ieee1275.h>.
12700 * commands/ieee1275/reboot.c: Likewise.
12701 * boot/powerpc/ieee1275/ieee1275.c: Move ...
12702 * kern/ieee1275.c: ... to here. All users updated. Change all
12703 parameter structs to use new type `grub_ieee1275_cell_t'.
12704 * term/powerpc/ieee1275/ofconsole.c: Move ...
12705 * term/ieee1275/ofconsole.c: ... to here. All users updated.
12706 * disk/powerpc/ieee1275/ofdisk.c: Move ...
12707 * disk/ieee1275/ofdisk.c: ... to here. All users updated.
12708 * boot/powerpc/ieee1275/cmain.c: Change `grub_ieee1275_entry_fn' type
12709 to return int.
12710 * include/grub/i386/pc/console.h: Move to include/grub/console.h.
12711 Remove unused prototypes. All users updated.
12712 * include/grub/powerpc/ieee1275/console.h: Removed.
12713 * include/grub/powerpc/ieee1275/ieee1275.h: Define
12714 `grub_ieee1275_cell_t'.
12715 * kern/powerpc/ieee1275/openfw.c: Include <grub/machine/kernel.h>.
12716 Cast comparisons with -1 to the correct type.
12717 * loader/powerpc/ieee1275/linux.c (kernel_entry_t): Change parameter
12718 type to match `grub_ieee1275_entry_fn'.
12719
12720 2005-08-01 Yoshinori K. Okuji <okuji@enbug.org>
12721
12722 * DISTLIST: Added util/i386/pc/grub-probefs.c.
12723
12724 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-probefs.
12725 (grub_setup_SOURCES): Removed partmap/amiga.c, partmap/apple.c and
12726 partmap/sun.c.
12727 (grub_probefs_SOURCES): New variable.
12728
12729 * util/i386/pc/grub-probefs.c: New file.
12730
12731 * util/i386/pc/grub-setup.c (main): Call
12732 grub_pc_partition_map_init, grub_ufs_init, grub_minix_init,
12733 grub_hfs_init and grub_jfs_init to initialize the system. Call
12734 grub_ufs_fini, grub_minix_fini, grub_hfs_fini, grub_jfs_init and
12735 grub_pc_partition_map_fini to finish the system.
12736
12737 2005-07-31 Yoshinori K. Okuji <okuji@enbug.org>
12738
12739 * loader/i386/pc/multiboot.c (grub_multiboot_is_elf32): New
12740 function.
12741 (grub_multiboot_load_elf32): Likewise.
12742 (grub_multiboot_is_elf64): Likewise.
12743 (grub_multiboot_load_elf64): Likewise.
12744 (grub_multiboot_load_elf): Likewise.
12745 (grub_rescue_cmd_multiboot): Call grub_multiboot_load_elf to load
12746 an ELF32 or ELF64 file.
12747 This is based on a patch from Ruslan Nikolaev <nruslan@mail.com>.
12748
12749 From Serbinenko Vladimir <serbinenko.vova@list.ru>:
12750 * kern/disk.c (grub_print_partinfo): Check if FS->LABEL is not
12751 NULL before calling FS->LABEL.
12752 * fs/fat.c (grub_fat_dir): Initialize DIRNAME to NULL.
12753 * commands/ls.c (grub_ls_list_files): Show labels, if possible.
12754 (grub_ls_list_disks): Check if FS and FS->LABEL are not NULL
12755 before calling FS->LABEL.
12756
12757 2005-07-26 Yoshinori K. Okuji <okuji@enbug.org>
12758
12759 * util/i386/pc/grub-install.in (datadir): New variable.
12760 (libdir): Removed.
12761 (pkgdatadir): New variable.
12762 (pkglibdir): Removed.
12763
12764 2005-07-24 Yoshinori K. Okuji <okuji@enbug.org>
12765
12766 * DISTLIST: Added util/i386/pc/grub-install.in.
12767
12768 * util/i386/pc/grub-install.in: New file.
12769
12770 * conf/i386-pc.rmk (sbin_SCRIPTS): New variable.
12771 (grub_install_SOURCES): Likewise.
12772
12773 * genmk.rb: Added support for scripts.
12774 (Script): New class.
12775 (scripts): New variable.
12776
12777 * Makefile.in (install-local): Install sbin_SCRIPTS by
12778 INSTALL_SCRIPT.
12779 (uninstall): Remove sbin_SCRIPTS.
12780
12781 * util/i386/pc/grub-setup.c (main): If the argument is not a GRUB
12782 device, try to get a GRUB device by
12783 grub_util_biosdisk_get_grub_dev.
12784 Free DEST_DEV.
12785
12786 * util/i386/pc/grub-mkdevicemap.c (usage): Remove a duplicated
12787 description for --device-map.
12788
12789 2005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
12790
12791 Change the semantics of variable hooks. They now return strings
12792 instead of error values.
12793
12794 * util/i386/pc/grub-setup.c: Include grub/env.h.
12795 (setup): Use grub_device_set_root instead of grub_env_set.
12796
12797 * kern/rescue.c (grub_rescue_cmd_root): Use grub_env_set and
12798 grub_env_get instead of grub_device_set_root and
12799 grub_device_get_root, respectively.
12800
12801 * kern/main.c (grub_env_write_root): New function.
12802 (grub_set_root_dev): Register grub_env_write_hook for "root". Use
12803 grub_env_set instead of grub_device_set_root.
12804
12805 * kern/env.c (HASHSZ): Reduced to 13, because GRUB does not need
12806 many variables.
12807 (grub_env_set): Set ENV->VALUE to the result of ENV->WRITE_HOOK
12808 rather than calling ENV->WRITE_HOOK afterwards.
12809 (grub_env_get): Return the result of ENV->READ_HOOK rather than
12810 passing a pointer of a pointer.
12811 (grub_register_variable_hook): Change the types of "read_hook" and
12812 "write_hook" to grub_env_read_hook_t and grub_env_write_hook_t,
12813 respectively.
12814 Allocate the default empty string on the heap, because this string
12815 may be freed later.
12816
12817 * kern/device.c: Include grub/env.h.
12818 (grub_device_set_root): Removed.
12819 (grub_device_get_root): Likewise.
12820 (grub_device_open): Use grub_env_get instead of
12821 grub_device_get_root.
12822
12823 * include/grub/env.h (grub_env_read_hook_t): New type.
12824 (grub_env_write_hook_t): Likewise.
12825 (grub_env_var): Change the types of "read_hook" and "write_hook"
12826 to grub_env_read_hook_t and grub_env_write_hook_t, respectively.
12827 (grub_register_variable_hook): Likewise.
12828
12829 * include/grub/device.h (grub_device_set_root): Removed.
12830 (grub_device_set_root): Likewise.
12831
12832 * fs/fat.c (grub_fat_dir): Make a copy of PATH in DIRNAME, and
12833 make sure that DIRNAME terminates with '/', so that
12834 grub_fat_find_dir will fail if PATH is not a directory.
12835
12836 * commands/ls.c (grub_ls_list_files): Remove the qualifier const
12837 from DIRNAME.
12838 Use the qualifier auto for print_files and print_files_long.
12839 If FS->DIR sets GRUB_ERRNO to GRUB_ERR_BAD_FILE_TYPE, try DIRNAME
12840 as a regular file.
12841 Put a newline only if there is no error.
12842 (grub_cmd_ls): Remove grub_ls_print_files, because this is not
12843 used.
12844
12845 2005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
12846
12847 * kern/partition.c (grub_partition_probe): Initialize PART to
12848 NULL. Otherwise, when no partition map is registered, this returns
12849 a garbage.
12850
12851 2005-07-19 Yoshinori K. Okuji <okuji@enbug.org>
12852
12853 * partmap/apple.c (apple_partition_map_iterate): Check if POS
12854 equals GRUB_DISK_SECTOR_SIZE to see if the partition table is
12855 valid.
12856
12857 2005-07-18 Yoshinori K. Okuji <okuji@enbug.org>
12858
12859 * commands/ls.c (grub_ls_list_disks): Print the filesystem
12860 information on each device, if it does not have partitions. Print
12861 "Device" instead of "Disk", because this function is not specific
12862 to disk devices.
12863
12864 * normal/main.c (grub_rescue_cmd_normal): Make the variable CONFIG
12865 static to ensure that it is put on the memory rather than a
12866 register.
12867
12868 2005-07-17 Yoshinori Okuji <okuji@enbug.org>
12869
12870 * commands/cat.c (GRUB_MOD_INIT): Use better documentation.
12871 (grub_cat_init): Likewise.
12872 * loader/i386/pc/chainloader_normal.c (GRUB_MOD_INIT): Likewise.
12873 (options): Likewise.
12874 * commands/configfile.c (GRUB_MOD_INIT): Likewise.
12875 (grub_configfile_init): Likewise.
12876 * font/manager.c (GRUB_MOD_INIT): Likewise.
12877 * commands/help.c (GRUB_MOD_INIT): Likewise.
12878 (grub_help_init): Likewise.
12879 * normal/command.c (grub_command_init): Likewise.
12880 * loader/i386/pc/linux_normal.c (GRUB_MOD_INIT): Likewise.
12881 * disk/loopback.c (grub_loop_init): Likewise.
12882 (GRUB_MOD_INIT): Likewise.
12883 * commands/ls.c (grub_ls_init): Likewise.
12884 (GRUB_MOD_INIT): Likewise.
12885 (options): Likewise.
12886 * commands/boot.c (grub_boot_init): Likewise.
12887 (GRUB_MOD_INIT): Likewise.
12888 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Likewise.
12889 * commands/i386/pc/reboot.c (grub_reboot_init): Likewise.
12890 (GRUB_MOD_INIT): Likewise.
12891 * commands/cmp.c (grub_cmp_init): Likewise.
12892 (GRUB_MOD_INIT): Likewise.
12893
12894 * normal/arg.c: Use <> instead of "" to include header files.
12895 (SHORT_ARG_HELP): New macro.
12896 (SHORT_ARG_USAGE): Likewise.
12897 (help_options): Specify SHORT_ARG_HELP and SHORT_ARG_USAGE instead
12898 of 'h' and 'u' for help and usage, respectively. Use more GNU-like
12899 descriptions.
12900 (find_short): Check if C is 'h' or 'u' explicitly.
12901 (grub_arg_show_help): Use space characters instead of tabs. Treat
12902 SHORT_ARG_HELP and SHORT_ARG_USAGE exceptionally so that -h and -u
12903 are shown with --help and --usage only if they are not used for
12904 the command itself.
12905 (parse_option): Use SHORT_ARG_HELP and SHORT_ARG_USAGE instead of
12906 'h' and 'u'.
12907
12908 * include/grub/arg.h (struct grub_arg_option): Add the qualifier
12909 const into "longarg". Change the type of "shortarg" to int.
12910
12911 2005-07-17 Yoshinori Okuji <okuji@enbug.org>
12912
12913 * boot/i386/pc/boot.S (boot_drive_check): New label.
12914
12915 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRIVE_CHECK): New
12916 macro.
12917
12918 * util/i386/pc/grub-setup.c (setup): Added a workaround for BIOSes
12919 which do not pass a boot drive correctly. Copied from GRUB Legacy.
12920
12921 2005-07-17 Yoshinori Okuji <okuji@enbug.org>
12922
12923 * kern/i386/pc/startup.S (gate_a20_try_system_control_port_a):
12924 When turning off Gate A20, skip the check and return immediately,
12925 because this is not fatal usually.
12926
12927 2005-07-17 Yoshinori Okuji <okuji@enbug.org>
12928
12929 * conf/i386-pc.rmk (pxeboot_img_LDFLAGS): The text address should
12930 be 0x7C00 instead of 0x8000.
12931
12932 * boot/i386/pc/pxeboot.S: Rewritten.
12933
12934 * kern/i386/pc/startup.S (gate_a20_try_bios): No need to specify
12935 EXT_C.
12936 (gate_a20_check_state): Read a byte from 0x108000. Invert the
12937 result.
12938
12939 2005-07-16 Yoshinori K. Okuji <okuji@enbug.org>
12940
12941 * kern/i386/pc/startup.S (grub_gate_a20): Rewritten for
12942 robustness. This routine now supports a BIOS call and System
12943 Control Port A to modify the gate A20.
12944
12945 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
12946 Increased to 0x440.
12947
12948 2005-07-12 Hollis Blanchard <hollis@penguinppc.org>
12949
12950 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): dprintf the
12951 device path and resulting ihandle.
12952 (grub_ofdisk_close): dprintf the ihandle being closed.
12953 (grub_ofdisk_read): dprintf function parameters.
12954 * kern/mm.c (grub_mm_init_region): Likewise.
12955 * loader/powerpc/ieee1275/linux.c: Remove extra whitespace.
12956 (grub_linux_boot): dprintf the Linux entry point, initrd address and
12957 size, and boot arguments.
12958 (grub_rescue_cmd_linux): dprintf each ELF segment's address and size
12959 before loading into memory.
12960 (grub_rescue_cmd_initrd): dprintf the initrd's address and size
12961 before loading into memory.
12962
12963 2005-07-12 Yoshinori K. Okuji <okuji@enbug.org>
12964
12965 * kern/mm.c: Added much documentation.
12966 (GRUB_MM_ALIGN_LOG2): When GRUB_CPU_SIZEOF_VOID_P is
12967 8, set to 5 instead of 8.
12968
12969 2005-07-10 Yoshinori Okuji <okuji@enbug.org>
12970
12971 * DISTLIST: Added util/i386/pc/grub-mkimage.c.
12972
12973 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-mkdevicemap.
12974 (grub_mkdevicemap_SOURCES): New variable.
12975
12976 * util/i386/pc/grub-mkdevicemap.c: New file. Mostly copied from
12977 lib/device.c of GRUB Legacy.
12978
12979 2005-07-10 Yoshinori Okuji <okuji@enbug.org>
12980
12981 * commands/ls.c (grub_ls_list_files): Check if *PATH is NUL
12982 instead of PATH is NULL.
12983
12984 2005-07-09 Vincent Pelletier <subdino2004@yahoo.fr>
12985
12986 * commands/cmp.c (BUFFER_SIZE): New macro.
12987 (grub_cmd_cmp): Close the right file at the right time. Compare
12988 only data just read. Don't report files of different size as
12989 identical. Dynamically allocate buffers. Move variable
12990 declarations at the beginning of function.
12991
12992 2005-07-09 Yoshinori Okuji <okuji@enbug.org>
12993
12994 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): The return value was
12995 reverse.
12996
12997 2004-07-04 Vincent Pelletier <subdino2004@yahoo.fr>
12998
12999 * normal/cmdline.c (grub_cmdline_get): Don't fallback on ctrl-d
13000 when backspace is pressed at beginning of line.
13001
13002 2005-07-03 Yoshinori Okuji <okuji@enbug.org>
13003
13004 * DISTLIST: Added genfslist.sh.
13005
13006 * normal/main.c (fs_module_list): New variable.
13007 (autoload_fs_module): New function.
13008 (read_fs_list): Likewise.
13009 (grub_normal_execute): Call read_fs_list.
13010
13011 * kern/fs.c (grub_fs_autoload_hook): New variable.
13012 (grub_fs_probe): Added support for auto-loading.
13013
13014 * include/grub/normal.h (struct grub_fs_module_list): New struct.
13015 (grub_fs_module_list_t): New type.
13016
13017 * include/grub/fs.h (grub_fs_autoload_hook_t): New type.
13018 (grub_fs_autoload_hook): New prototype.
13019
13020 * genfslist.sh: New file.
13021
13022 * genmk.rb: Added a rule to generate a filesystem list.
13023
13024 2005-06-30 Marco Gerards <metgerards@student.han.nl>
13025
13026 * configure.ac: Fix the test for cross-compiling.
13027
13028 * genmk.rb (Program): Use `$(CC)' instead of `$(BUILD_CC)'. Don't
13029 define GRUB_UTIL anymore.
13030
13031 * util/powerpc/ieee1275/grub-mkimage.c (load_note): Endian fixes
13032 so this function works on other systems than just big endian.
13033 (load_modules): Likewise.
13034 (add_segments): Likewise.
13035
13036 2005-06-23 Hollis Blanchard <hollis@penguinppc.org>
13037
13038 * kern/misc.c (grub_vsprintf): Add `longfmt'. If format string
13039 contains `l' modifier, get a long from va_arg().
13040
13041 2005-06-23 Yoshinori K. Okuji <okuji@enbug.org>
13042
13043 * kern/mm.c (grub_free): If the next free block which is being
13044 merged is the first free block, set the first block to the block
13045 being freed.
13046 Reported by Vincent Guffens <guffens@inma.ucl.ac.be>.
13047
13048 2005-05-08 Hollis Blanchard <hollis@penguinppc.org>
13049
13050 * boot/powerpc/ieee1275/cmain.c (cmain): Initialize
13051 `grub_ieee1275_chosen'.
13052
13053 2005-05-08 Hollis Blanchard <hollis@penguinppc.org>
13054
13055 * boot/powerpc/ieee1275/cmain.c (module_info): Remove definition.
13056 (grub_ieee1275_chosen): New variable.
13057 (cmain): Initialize and use `grub_ieee1275_chosen' instead of
13058 `chosen'.
13059 * boot/powerpc/ieee1275/crt0.S (init_stack): Remove stack space.
13060 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
13061 Rename first argument to `phandle' for consistency.
13062 (grub_ieee1275_get_property_length): Likewise.
13063 (grub_ieee1275_next_property): Likewise. Change type of first argument
13064 to grub_ieee1275_phandle_t.
13065 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_entry_fn):
13066 Move export next to declaration.
13067 (grub_ieee1275_chosen): New variable.
13068 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MODULE_BASE):
13069 Correct cosmetic typo.
13070 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Use
13071 `grub_ieee1275_chosen'.
13072 * kern/powerpc/ieee1275/openfw.c (grub_map): Likewise.
13073 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Likewise.
13074 (grub_rescue_cmd_linux): Set `initrd_addr' to 0.
13075 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_refresh): Use
13076 `grub_ieee1275_chosen'.
13077
13078 2005-05-10 Hollis Blanchard <hollis@penguinppc.org>
13079
13080 * boot/powerpc/ieee1275/cmain.c (cmain): Remove code to parse
13081 /chosen/bootargs.
13082 * kern/powerpc/ieee1275/init.c (grub_machine_init): Parse
13083 /chosen/bootargs as "variable=value" pairs.
13084
13085 2005-05-08 Vincent Pelletier <subdino2004@yahoo.fr>
13086
13087 * include/grub/misc.h (grub_dprintf): New macro.
13088 (grub_real_dprintf): New prototype.
13089 (grub_strword): Likewise.
13090 (grub_iswordseparator): Likewise.
13091 * kern/misc.c (grub_real_dprintf): New function.
13092 (grub_strword): Likewise.
13093 (grub_iswordseparator): Likewise.
13094
13095 2005-04-30 Hollis Blanchard <hollis@penguinppc.org>
13096
13097 * boot/powerpc/ieee1275/cmain.c: Don't include grub/machine/init.h.
13098 (roundup): Remove macro.
13099 (grub_ieee1275_flags): Make static.
13100 (grub_ieee1275_realmode): Remove.
13101 (grub_ieee1275_test_flag): New function.
13102 (grub_ieee1275_set_flag): Likewise.
13103 (find_options): Rename to `grub_ieee1275_find_options'; update
13104 callers. Set GRUB_IEEE1275_FLAG_REAL_MODE and
13105 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS.
13106 (cmain): New prototype.
13107 (cmain): Use `grub_ieee1275_set_flag' instead of accessing
13108 `grub_ieee1275_flags' directly.
13109 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Remove
13110 machine/biosdisk.h.
13111 * disk/powerpc/ieee1275/ofdisk.c: Include grub/machine/ofdisk.h.
13112 Don't include grub/machine/init.h.
13113 (grub_ofdisk_open): Call `grub_ieee1275_test_flag'.
13114 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
13115 Remove prototype.
13116 (grub_ieee1275_realmode): Likewise.
13117 (grub_ieee1275_flag): New enum.
13118 (grub_ieee1275_test_flag): New prototype.
13119 (grub_ieee1275_set_flag): New prototype.
13120 * include/grub/powerpc/ieee1275/init.h: Remove file.
13121 * include/grub/powerpc/ieee1275/ofdisk.h: New file.
13122 * kern/powerpc/ieee1275/init.c: Don't include grub/machine/init.h.
13123 Include grub/machine/console.h. Include grub/machine/ofdisk.h.
13124 (grub_machine_fini): Don't call `grub_ieee1275_release'. Remove
13125 comment.
13126 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Call
13127 `grub_ieee1275_test_flag'.
13128 (grub_ieee1275_encode_devname): Likewise.
13129
13130 2005-04-21 Hollis Blanchard <hollis@penguinppc.org>
13131
13132 * include/grub/powerpc/ieee1275/ieee1275.h
13133 (grub_ieee1275_encode_devname): New prototype.
13134 (grub_ieee1275_get_filename): Likewise.
13135 * kern/powerpc/ieee1275/init.c (grub_translate_ieee175_path): New
13136 function.
13137 (grub_set_prefix): Likewise.
13138 (grub_machine_init): Call grub_set_prefix.
13139 * kern/powerpc/ieee1275/openfw.c: Fix typos.
13140 (grub_parse_type): New enum.
13141 (grub_ieee1275_get_devargs): New function.
13142 (grub_ieee1275_get_devname): Likewise.
13143 (grub_ieee1275_parse_args): Likewise.
13144 (grub_ieee1275_get_filename): Likewise.
13145 (grub_ieee1275_encode_devname): Likewise.
13146
13147 2005-03-30 Marco Gerards <metgerards@student.han.nl>
13148
13149 * kern/powerpc/ieee1275/init.c (grub_machine_fini): Don't call
13150 `grub_loader_unset'.
13151
13152 2005-03-26 Hollis Blanchard <hollis@penguinppc.org>
13153
13154 * commands/ieee1275/halt.c (grub_cmd_halt): Call grub_halt
13155 instead of grub_ieee1275_interpret.
13156 (grub_halt_init): New function.
13157 (grub_halt_fini): Likewise.
13158 (GRUB_MOD_INIT): Correct message grammar.
13159 * commands/ieee1275/reboot.c (grub_cmd_reboot): Call grub_reboot
13160 instead of grub_ieee1275_interpret.
13161 (grub_reboot_init): New function.
13162 (grub_reboot_fini): Likewise.
13163 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace
13164 commands/i386/pc/halt.c, commands/i386/pc/reboot.c, and
13165 util/i386/pc/misc.c with commands/ieee1275/halt.c,
13166 commands/ieee1275/reboot.c, and util/powerpc/ieee1275/misc.c.
13167 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_fini): New
13168 function.
13169 * include/grub/powerpc/ieee1275/console.h (grub_console_fini):
13170 Add prototype.
13171 * include/grub/powerpc/ieee1275/ieee1275.h (grub_reboot): Add
13172 prototype.
13173 (grub_halt): Likewise.
13174 * include/grub/powerpc/ieee1275/init.h: Remove inaccurate comment.
13175 (cmain): Remove __attribute__((unused)).
13176 * kern/powerpc/ieee1275/init.c (grub_heap_start): New variable.
13177 (grub_heap_len): Likewise.
13178 (grub_machine_fini): New function.
13179 * kern/powerpc/ieee1275/openfw.c (grub_reboot): New function.
13180 (grub_halt): Likewise.
13181 * term/powerpc/ieee1275/ofconsole.c (grub_console_fini): New
13182 function.
13183 * util/powerpc/ieee1275/misc.c: New file.
13184
13185 2005-03-19 Yoshinori K. Okuji <okuji@enbug.org>
13186
13187 * DISTLIST: New file.
13188 * gendistlist.sh: Likewise.
13189
13190 * Makefile.in (COMMON_DISTFILES): Removed.
13191 (BOOT_DISTFILES): Likewise.
13192 (CONF_DISTFILES): Likewise.
13193 (DISK_DISTFILES): Likewise.
13194 (FS_DISTFILES): Likewise.
13195 (INCLUDE_DISTFILES): Likewise.
13196 (KERN_DISTFILES): Likewise.
13197 (LOADER_DISTFILES): Likewise.
13198 (TERM_DISTFILES): Likewise.
13199 (UTIL_DISTFILES): Likewise.
13200 (DISTFILES): Likewise.
13201 (uninstall): Uninstall files in $(pkgdata_DATA).
13202 (DISTLIST): New target.
13203 (distdir): Use the contents of the file DISTLIST to get a list of
13204 distributed files.
13205
13206 2005-03-18 Yoshinori K. Okuji <okuji@enbug.org>
13207
13208 * fs/fat.c (grub_fat_mount): Ignore the 3rd bit of a media
13209 descriptor. This is ported from GRUB Legacy.
13210
13211 * gencmdlist.sh: Added an extra semicolon to make it work with
13212 old sed versions. Reported by Robert Bihlmeyer
13213 <robbe@orcus.priv.at>.
13214
13215 2005-03-08 Yoshinori Okuji <okuji@enbug.org>
13216
13217 Automatic loading of commands is supported.
13218
13219 * normal/main.c (read_command_list): New function.
13220 (grub_normal_execute): Call read_command_list.
13221
13222 * normal/command.c (grub_register_command): Return zero or CMD.
13223 Allocate CMD->NAME from the heap.
13224 Initialize CMD->MODULE_NAME to zero.
13225 Find the same name as well. If the same command is found and it is
13226 a dummy command, overwrite members. If it is not a dummy command,
13227 return zero.
13228 (grub_unregister_command): Free Q->NAME and Q->MODULE_NAME.
13229 (grub_command_find): If a dummy command is found, load a module
13230 and retry to find a command only once.
13231
13232 * normal/cmdline.c (grub_tab_complete): Call grub_command_find to
13233 make sure that each command is loaded.
13234
13235 * include/grub/normal.h (GRUB_COMMAND_FLAG_NOT_LOADED): New
13236 macro.
13237 (struct grub_command): Remove const from the member `name'.
13238 Add a new member `module_name'.
13239 (grub_register_command): Return grub_command_t.
13240
13241 * commands/help.c (grub_cmd_help): Call grub_command_find to make
13242 sure that each command is loaded.
13243
13244 * genmk.rb (PModule::rule): Specify a module name without the
13245 suffix ".mod" to gencmdlist.sh.
13246
13247 2005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
13248
13249 * gencmdlist.sh: New file.
13250
13251 * genmk.rb (PModule::rule): Generate a rule for a command list.
13252 Clean command.lst.
13253 Generate command.lst from $(COMMANDFILES).
13254
13255 * Makefile.in (COMMON_DISTFILES): Added gencmdlist.sh.
13256 (DATA): Added $(pkgdata_DATA).
13257 (install-local): Install files in $(pkgdata_DATA).
13258
13259 2005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
13260
13261 * term/i386/pc/vga.c (debug_command): Removed.
13262 (GRUB_MOD_INIT): Do not register the command "debug".
13263
13264 From Hollis Blanchard:
13265 * commands/configfile.c: New file.
13266 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
13267 commands/configfile.c.
13268 (pkgdata_MODULES): Added configfile.mod.
13269 (configfile_mod_SOURCES): New variable.
13270 (configfile_mod_CFLAGS): Likewise.
13271 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
13272 commands/configfile.c.
13273 (pkgdata_MODULES): Added configfile.mod.
13274 (configfile_mod_SOURCES): New variable.
13275 (configfile_mod_CFLAGS): Likewise.
13276 * util/grub-emu.c (main): Call grub_configfile_init and
13277 grub_configfile_fini.
13278 * include/grub/normal.h [GRUB_UTIL] (grub_configfile_init): New
13279 prototype.
13280 [GRUB_UTIL] (grub_configfile_fini): Likewise.
13281
13282 2005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
13283
13284 * normal/arg.c (grub_arg_show_help): Do not show the bug report
13285 address.
13286
13287 * commands/help.c (grub_cmd_help): Do not print newlines after
13288 the last command in print_command_help.
13289
13290 2005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
13291
13292 * commands/default.h: New file.
13293 * commands/timeout.h: Likewise.
13294 * normal/context.c: Likewise.
13295
13296 * util/misc.c: Do not include sys/times.h.
13297 Include sys/time.h and grub/machine/time.h.
13298 (grub_get_rtc): Rewritten with gettimeofday.
13299
13300 * util/grub-emu.c (main): Call grub_default_init and
13301 grub_timeout_init before grub_normal_init, and call
13302 grub_timeout_fini and grub_default_fini after grub_main.
13303
13304 * util/console.c (grub_ncurses_checkkey): Return the read
13305 character or -1.
13306
13307 * normal/menu.c (run_menu): Set MENU->TIMEOUT to -1 once it
13308 timeouts.
13309
13310 * normal/main.c (read_config_file): Push MENU. If this fails,
13311 print an error and wait for a user input.
13312 Print an error only if GRUB_ERRNO is not GRUB_ERR_NONE.
13313 If a menu is empty or an error occurs, pop MENU.
13314 (grub_normal_execute): Pop and free MENU after grub_menu_run
13315 returns.
13316
13317 * kern/loader.c (grub_loader_boot): Call grub_machine_fini.
13318
13319 * include/grub/powerpc/ieee1275/time.h [GRUB_UTIL]: Do not
13320 include time.h.
13321 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
13322 without GRUB_UTIL.
13323 * include/grub/i386/pc/time.h [GRUB_UTIL]: Do not include
13324 time.h.
13325 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
13326 without GRUB_UTIL.
13327
13328 * include/grub/normal.h (struct grub_menu_list): New struct.
13329 (grub_menu_list_t): New type.
13330 (struct grub_context): New struct.
13331 (grub_context_t): New type.
13332 (grub_register_command): Got rid of EXPORT_FUNC.
13333 (grub_unregister_command): Likewise.
13334 (grub_context_get): New prototype.
13335 (grub_context_get_current_menu): Likewise.
13336 (grub_context_push_menu): Likewise.
13337 (grub_context_pop_menu): Likewise.
13338 [GRUB_UTIL] (grub_default_init): Likewise.
13339 [GRUB_UTIL] (grub_default_fini): Likewise.
13340 [GRUB_UTIL] (grub_timeout_init): Likewise.
13341 [GRUB_UTIL] (grub_timeout_fini): Likewise.
13342
13343 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/default.c,
13344 commands/timeout.c and normal/context.c.
13345 (pkgdata_MODULES): Added default.mod and timeout.mod.
13346 (normal_mod_SOURCES): Added normal/context.c.
13347 (default_mod_SOURCES): New variable.
13348 (default_mod_CFLAGS): Likewise.
13349 (timeout_mod_SOURCES): Likewise.
13350 (timeout_mod_CFLAGS): Likewise.
13351 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Copied from
13352 conf/i386-pc.rmk.
13353 (pkgdata_MODULES): Added default.mod and timeout.mod.
13354 (normal_mod_SOURCES): Added normal/context.c.
13355 (default_mod_SOURCES): New variable.
13356 (default_mod_CFLAGS): Likewise.
13357 (timeout_mod_SOURCES): Likewise.
13358 (timeout_mod_CFLAGS): Likewise.
13359
13360 * Makefile.in (all-local): Added $(MKFILES).
13361
13362 2005-02-21 Vincent Pelletier <subdino2004@yahoo.fr>
13363
13364 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `partmap/sun.c'.
13365 (grub_emu_SOURCES): Likewise.
13366 (pkgdata_MODULES): Add `sun.mod'.
13367 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
13368 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
13369 `partmap/sun.c'.
13370 (pkgdata_MODULES): Add `sun.mod'.
13371 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
13372 * include/grub/partition.h (grub_sun_partition_map_init): New
13373 prototype.
13374 (grub_sun_partition_map_fini): Likewise.
13375 * partmap/sun.c: New file.
13376 * util/grub-emu.c (main): Initialize and de-initialize the sun
13377 partitionmap support.
13378
13379 2005-02-19 Yoshinori K. Okuji <okuji@enbug.org>
13380
13381 This implements an Emacs-like menu entry editor.
13382
13383 * normal/menu_entry.c: New file.
13384
13385 * util/console.c (grub_ncurses_putchar): Translate some Unicode
13386 characters to ASCII.
13387 (saved_char): New variable.
13388 (grub_ncurses_checkkey): Rewritten completely.
13389 (grub_ncurses_getkey): Likewise.
13390 (grub_ncurses_init): Call raw instead of cbreak.
13391
13392 * normal/menu.c (print_entry): Do not put a space.
13393 (init_page): Renamed to ...
13394 (grub_menu_init_page): ... this. All callers changed.
13395 (edit_menu_entry): Removed.
13396 (run_menu): Call grub_menu_entry_run instead of edit_menu_entry.
13397
13398 * normal/cmdline.c (grub_cmdline_run): Call grub_setcursor.
13399
13400 * kern/misc.c (grub_vprintf): Call grub_refresh.
13401
13402 * normal/menu.c (DISP_LEFT): Renamed to ...
13403 * include/grub/term.h (GRUB_TERM_DISP_LEFT): ... this.
13404 * normal/menu.c (DISP_UP): Renamed to ...
13405 * include/grub/term.h (GRUB_TERM_DISP_UP): ... this.
13406 * normal/menu.c (DISP_RIGHT): Renamed to ...
13407 * include/grub/term.h (GRUB_TERM_DISP_RIGHT): ... this.
13408 * normal/menu.c (DISP_DOWN): Renamed to ...
13409 * include/grub/term.h (GRUB_TERM_DISP_DOWN): ... this.
13410 * normal/menu.c (DISP_HLINE): Renamed to ...
13411 * include/grub/term.h (GRUB_TERM_DISP_HLINE): ... this.
13412 * normal/menu.c (DISP_VLINE): Renamed to ...
13413 * include/grub/term.h (GRUB_TERM_DISP_VLINE): ... this.
13414 * normal/menu.c (DISP_UL): Renamed to ...
13415 * include/grub/term.h (GRUB_TERM_DISP_UL): ... this.
13416 * normal/menu.c (DISP_UR): Renamed to ...
13417 * include/grub/term.h (GRUB_TERM_DISP_UR): ... this.
13418 * normal/menu.c (DISP_LL): Renamed to ...
13419 * include/grub/term.h (GRUB_TERM_DISP_LL): ... this.
13420 * normal/menu.c (DISP_LR): Renamed to ...
13421 * include/grub/term.h (GRUB_TERM_DISP_LR): ... this.
13422 * normal/menu.c (TERM_WIDTH): Renamed to ...
13423 * include/grub/term.h (GRUB_TERM_WIDTH): ... this.
13424 * normal/menu.c (TERM_HEIGHT): Renamed to ...
13425 * include/grub/term.h (GRUB_TERM_HEIGHT): ... this.
13426 * normal/menu.c (TERM_INFO_HEIGHT): Renamed to ...
13427 * include/grub/term.h (GRUB_TERM_INFO_HEIGHT): ... this.
13428 * normal/menu.c (TERM_MARGIN): Renamed to ...
13429 * include/grub/term.h (GRUB_TERM_MARGIN): ... this.
13430 * normal/menu.c (TERM_SCROLL_WIDTH): Renamed to ...
13431 * include/grub/term.h (GRUB_TERM_SCROLL_WIDTH): ... this.
13432 * normal/menu.c (TERM_TOP_BORDER_Y): Renamed to ...
13433 * include/grub/term.h (GRUB_TERM_TOP_BORDER_Y): ... this.
13434 * normal/menu.c (TERM_LEFT_BORDER_X): Renamed to ...
13435 * include/grub/term.h (GRUB_TERM_LEFT_BORDER_X): ... this.
13436 * normal/menu.c (TERM_BORDER_WIDTH): Renamed to ...
13437 * include/grub/term.h (GRUB_TERM_BORDER_WIDTH): ... this.
13438 * normal/menu.c (TERM_MESSAGE_HEIGHT): Renamed to ...
13439 * include/grub/term.h (GRUB_TERM_MESSAGE_HEIGHT): ... this.
13440 * normal/menu.c (TERM_BORDER_HEIGHT): Renamed to ...
13441 * include/grub/term.h (GRUB_TERM_BORDER_HEIGHT): ... this.
13442 * normal/menu.c (TERM_NUM_ENTRIES): Renamed to ...
13443 * include/grub/term.h (GRUB_TERM_NUM_ENTRIES): ... this.
13444 * normal/menu.c (TERM_FIRST_ENTRY_Y): Renamed to ...
13445 * include/grub/term.h (GRUB_TERM_FIRST_ENTRY_Y): ... this.
13446 * normal/menu.c (TERM_ENTRY_WIDTH): Renamed to ...
13447 * include/grub/term.h (GRUB_TERM_ENTRY_WIDTH): ... this.
13448 * normal/menu.c (TERM_CURSOR_X): Renamed to ...
13449 * include/grub/term.h (GRUB_TERM_CURSOR_X): ... this.
13450 All callers changed.
13451
13452 * include/grub/normal.h: New prototype.
13453
13454 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
13455 normal/menu_entry.c.
13456 (normal_mod_SOURCES): Likewise.
13457 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
13458 (normal_mod_SOURCES): Likewise.
13459
13460 2005-02-15 Yoshinori K. Okuji <okuji@enbug.org>
13461
13462 * include/grub/normal.h (grub_halt_init): New prototype.
13463 (grub_halt_fini): Likewise.
13464 (grub_reboot_init): Likewise.
13465 (grub_reboot_fini): Likewise.
13466
13467 * util/grub-emu.c: Include signal.h.
13468 (main_env): New global variable.
13469 (grub_machine_init): Ignore SIGINT. Otherwise grub-emu cannot
13470 catch C-c.
13471 (grub_machine_fini): New function.
13472 (main): Call grub_halt_init and grub_reboot_init before
13473 grub_main, and grub_reboot_fini and grub_halt_fini after it.
13474 Call setjmp with MAIN_ENV to go back afterwards.
13475 Call grub_machine_fini right before return.
13476
13477 * include/grub/util/misc.h: Include setjmp.h.
13478 (main_env): New prototype.
13479
13480 * include/grub/kernel.h (grub_machine_fini): New prototype.
13481 * include/grub/i386/pc/biosdisk.h (grub_biosdisk_fini): Likewise.
13482 * include/grub/i386/pc/console.h (grub_console_fini): Likewise.
13483
13484 * disk/i386/pc/biosdisk.c (grub_biosdisk_fini): New function.
13485 * kern/i386/pc/init.c (grub_machine_fini): Likewise.
13486 * term/i386/pc/console.c (grub_console_fini): Likewise.
13487
13488 * util/i386/pc/misc.c: New file.
13489
13490 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
13491 util/i386/pc/misc.c, commands/i386/pc/halt.c and
13492 commands/i386/pc/reboot.c.
13493
13494 2005-02-14 Guillem Jover <guillem@hadrons.org>
13495
13496 * include/grub/dl.h (grub_dl_check_header): New prototype.
13497 (grub_arch_dl_check_header): Change return type to grub_err_t,
13498 remove size parameter and export function. Update all callers.
13499 * kern/dl.c (grub_dl_check_header): New function.
13500 (grub_dl_load_core): Use `grub_dl_check_header' instead of
13501 `grub_arch_dl_check_header'. Check ELF type. Check if sections
13502 are inside the core.
13503 * kern/i386/dl.c (grub_arch_dl_check_header): Remove arch
13504 independent ELF header checks.
13505 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
13506 * loader/i386/pc/multiboot.c (grub_rescue_cmd_multiboot): Use
13507 `grub_dl_check_header' instead of explicit checks. Check for the
13508 ELF type.
13509 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Use
13510 `grub_dl_check_header' instead of explicit checks. Remove arch
13511 specific ELF header checks.
13512
13513 * util/grub-emu.c (grub_arch_dl_check_header): Remove the
13514 argument SIZE.
13515
13516 2005-02-13 Hollis Blanchard <hollis@penguinppc.org>
13517
13518 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add ls.mod.
13519 * include/grub/powerpc/libgcc.h (__mulsf3): New prototype.
13520
13521 2005-02-12 Hollis Blanchard <hollis@penguinppc.org>
13522
13523 * kern/partition.c (grub_partition_probe): Clear `grub_errno' and
13524 return 0 if `grub_errno' is GRUB_ERR_BAD_PART_TABLE.
13525 (part_map_iterate): Clear `grub_errno' and return 0 if
13526 `partmap->iterate' returns GRUB_ERR_BAD_PART_TABLE.
13527 * partmap/amiga.c (amiga_partition_map_iterate): Return
13528 GRUB_ERR_BAD_PART_TABLE if no partition map magic is found.
13529 * partmap/apple.c (apple_partition_map_iterate): Likewise.
13530
13531 2005-02-01 Guillem Jover <guillem@hadrons.org>
13532
13533 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Fix module
13534 help info.
13535
13536 2005-01-31 Marco Gerards <metgerards@student.han.nl>
13537
13538 * include/grub/powerpc/ieee1275/loader.h (grub_load_linux):
13539 Removed prototype.
13540 (grub_rescue_cmd_linux): New prototype.
13541 (grub_rescue_cmd_initrd): Likewise.
13542 * powerpc/ieee1275/linux.c (grub_linux_boot): Remove struct
13543 `bi_rec'.
13544 (grub_linux_release_mem): Release the memory for the initrd.
13545 (grub_load_linux): Renamed from this...
13546 (grub_rescue_cmd_linux): ...To this. Changed all callers.
13547 Changed `entry' not to be static. Loop over memory regions to
13548 find another one when the default fails.
13549 (grub_rescue_cmd_initrd): New function.
13550 (grub_linux_init): Remove function.
13551 (grub_linux_fini): Likewise.
13552 (GRUB_MOD_INIT): Register `initrd'.
13553 (GRUB_MOD_FINI): Unregister `initrd'.
13554 * powerpc/ieee1275/linux_normal.c (grub_linux_normal_init):
13555 Function removed.
13556 (grub_linux_normal_fini): Likewise.
13557 (GRUB_MOD_INIT): Register `initrd'.
13558 (GRUB_MOD_FINI): Unregister `initrd'.
13559
13560 2005-01-31 Marco Gerards <metgerards@student.han.nl>
13561
13562 * commands/help.c: New file.
13563 * normal/arg.c (show_help): Renamed to...
13564 (grub_arg_show_help): ... this.
13565 * commands/i386/pc/halt.c: New file.
13566 * commands/i386/pc/reboot.c: Likewise.
13567 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/help.c'.
13568 (pkgdata_MODULES): Add `reboot.mod', `halt.mod' and `help.mod'.
13569 (help_mod_SOURCES, help_mod_CFLAGS, reboot_mod_SOURCES)
13570 (reboot_mod_CFLAGS, halt_mod_SOURCES, halt_mod_CFLAGS): New
13571 variables.
13572 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
13573 `commands/help.c'.
13574 (pkgdata_MODULES): Add `help.mod'.
13575 (help_mod_SOURCES, help_mod_CFLAGS): New variables.
13576 * grub/i386/pc/init.h (grub_reboot): New prototype.
13577 (grub_halt): Likewise.
13578 * include/grub/normal.h (grub_arg_show_help): New prototype.
13579 (grub_help_init): Likewise.
13580 (grub_help_fini): Likewise.
13581 * util/grub-emu.c (main): Initialize and deinitialize the help
13582 command.
13583
13584 * normal/cmdline.c (grub_cmdline_get): Doc fix.
13585
13586 * normal/command.c (grub_command_init): Fixed the description of
13587 the `set' and `unset' commands.
13588
13589 2005-01-31 Marco Gerards <metgerards@student.han.nl>
13590
13591 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_interpret): New
13592 function.
13593 * commands/ieee1275/halt.c: New file.
13594 * commands/ieee1275/reboot.c: Likewise.
13595 * commands/ieee1275/suspend.c (grub_cmd_suspend): Use
13596 `__attribute__ ((unused))'. Some GCS related fixed.
13597 (grub_suspend_init) [GRUB_UTIL]: Function removed.
13598 (grub_suspend_fini): Likewise.
13599 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add `reboot.mod'
13600 and `halt.mod'.
13601 (reboot_mod_SOURCES, reboot_mod_CFLAGS, halt_mod_SOURCES)
13602 (halt_mod_CFLAGS): New variables.
13603 * include/grub/powerpc/ieee1275/ieee1275.h
13604 (grub_ieee1275_interpret): New prototype.
13605
13606 2005-01-29 Yoshinori K. Okuji <okuji@enbug.org>
13607
13608 * include/grub/misc.h (memmove): New prototype.
13609 (memcpy): Likewise.
13610
13611 2005-01-22 Hollis Blanchard <hollis@penguinppc.org>
13612
13613 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Don't initialize
13614 `devpath' to 0. Use `name' instead of `devpath' with `grub_strndup'.
13615
13616 2005-01-22 Marco Gerards <metgerards@student.han.nl>
13617
13618 * kern/misc.c (grub_strndup): Function rewritten.
13619
13620 2005-01-22 Vincent Pelletier <subdino2004@yahoo.fr>
13621
13622 * normal/menu.c (TERM_WIDTH): Macro redefined.
13623 (TERM_TOP_BORDER_Y): Likewise.
13624 (draw_border): Replaced while-loop by a for-loop. Make the number
13625 of lines consistent with the number of lines displayed in
13626 print_entries. Added a margin below the rectangle.
13627 (print_entry): Make the entry fit in the rectangle.
13628 (print_entries): Display the scroll arrows next to the right
13629 border.
13630
13631 2005-01-21 Marco Gerards <metgerards@student.han.nl>
13632
13633 * fs/minix.c (grub_minix_find_file): Reserve more space for
13634 `fpath' so the \0 can be stored. Use `grub_strcpy' instead of
13635 `grub_strncpy' to copy `path' into it.
13636
13637 2005-01-21 Marco Gerards <metgerards@student.han.nl>
13638
13639 Add the loopback device, a device via which files can be accessed
13640 as devices.
13641
13642 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/loopback.c'.
13643 (pkgdata_MODULES): Add loopback.mod.
13644 (loopback_mod_SOURCES): New variable.
13645 (loopback_mod_CFLAGS): Likewise.
13646 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
13647 `disk/loopback.c'.
13648 (pkgdata_MODULES): Add loopback.mod.
13649 (loopback_mod_SOURCES): New variable.
13650 (loopback_mod_CFLAGS): Likewise.
13651 * disk/loopback.c: new file.
13652 * include/grub/normal.h (grub_loop_init): New prototype.
13653 (grub_loop_fini): New prototype.
13654 * util/grub-emu.c (main): Initialize and de-initialize loopback
13655 support.
13656 * include/grub/disk.h (grub_disk_dev_id): Add
13657 `GRUB_DISK_DEVICE_LOOPBACK_ID'.
13658
13659 2005-01-20 Hollis Blanchard <hollis@penguinppc.org>
13660
13661 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_enter): New
13662 function.
13663 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add suspend.mod.
13664 (suspend_mod_SOURCES): New variable.
13665 (suspend_mod_CFLAGS): Likewise.
13666 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_enter):
13667 New prototype.
13668 * commands/ieee1275/suspend.c: New file.
13669
13670 2005-01-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
13671
13672 * include/grub/dl.h (GRUB_MOD_INIT): Changed `__attribute__
13673 ((unused))' to `__attribute__ ((used))'.
13674 (GRUB_MOD_FINI): Likewise.
13675 * kern/dl.c (grub_dl_load_file): Fix null pointer dereference.
13676 * genmk.rb (PModule): Assign space to common symbols when linking
13677 modules.
13678
13679 2005-01-20 Marco Gerards <metgerards@student.han.nl>
13680
13681 * include/grub/mm.h (grub_mm_init_region): Change the type of the
13682 `unsigned' arguments to `grub_size_t'.
13683 (grub_malloc): Likewise.
13684 (grub_realloc): Likewise.
13685 (grub_memalign): Likewise.
13686 * kern/i386/dl.c (grub_arch_dl_check_header): Likewise.
13687 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
13688 * util/misc.c (grub_malloc): Likewise.
13689 (grub_realloc): Likewise.
13690 * kern/mm.c (get_header_from_pointer): Change the casts to
13691 `unsigned' into a cast to `grub_size_t'.
13692
13693 * fs/fshelp.c (grub_fshelp_find_file): The `oldnode' should always
13694 point to `currnode' when `currnode' is changed.
13695
13696 * util/grub-emu.c (main): Initialize `progname'. Reported by Nico
13697 Schottelius <nico-linux@schottelius.org>.
13698
13699 2005-01-09 Hollis Blanchard <hollis@penguinppc.org>
13700
13701 * util/powerpc/ieee1275/grub-mkimage.c: Include <string.h>.
13702 (note_path): Remove variable.
13703 (GRUB_IEEE1275_NOTE_NAME): New macro.
13704 (GRUB_IEEE1275_NOTE_TYPE): Likewise.
13705 (grub_ieee1275_note_hdr): New structure.
13706 (grub_ieee1275_note_desc): Likewise.
13707 (grub_ieee1275_note): Likewise.
13708 (load_note): Remove `dir' argument. All callers updated. Remove
13709 `note_img' and `path'. Do not load a file from `note_path'.
13710 Initialize a struct grub_ieee1275_note and write that to `out'.
13711 Use GRUB_IEEE1275_MODULE_BASE instead of MODULE_BASE.
13712
13713 2005-01-05 Marco Gerards <metgerards@student.han.nl>
13714
13715 * util/misc.c (grub_util_read_image): Revert last change. It
13716 called `grub_util_read_at', which seeks from the beginning of the
13717 file.
13718
13719 2005-01-04 Hollis Blanchard <hollis@penguinppc.org>
13720
13721 * TODO: Add note about endianness in grub-mkimage.
13722 * boot/powerpc/ieee1275/crt0.S (note): Remove unused .note
13723 section.
13724 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Add grub-mkimage.
13725 (grub_mkimage_SOURCES): New target.
13726 * include/grub/kernel.h (grub_start_addr): Remove variable.
13727 (grub_end_addr): Likewise.
13728 (grub_total_module_size): Likewise.
13729 (grub_kernel_image_size): Likewise.
13730 (GRUB_MODULE_MAGIC): New constant.
13731 (grub_module_info): New structure.
13732 (grub_arch_modules_addr): New prototype.
13733 (grub_get_end_addr): Remove prototype.
13734 * include/grub/i386/pc/kernel.h (grub_end_addr): New prototype.
13735 * include/grub/powerpc/ieee1275/kernel.h: New file.
13736 * include/grub/util/misc.h (grub_util_get_fp_size): New
13737 prototype.
13738 (grub_util_read_at): Likewise.
13739 (grub_util_write_image_at): Likewise.
13740 * kern/main.c (grub_get_end_addr): Remove function.
13741 (grub_load_modules): Call grub_arch_modules_addr instead of using
13742 grub_end_addr. Look for a grub_module_info struct in memory. Use
13743 the grub_module_info fields instead of calling grub_get_end_addr
13744 as loop conditions. Move grub_add_unused_region code here.
13745 (grub_add_unused_region): Remove function.
13746 * kern/i386/pc/init.c: Include grub/cache.h.
13747 (grub_machine_init): Remove call to grub_get_end_addr. Remove
13748 one call to add_mem_region.
13749 (grub_arch_modules_addr): New function.
13750 * kern/powerpc/ieee1275/init.c (grub_end_addr): Remove variable.
13751 (grub_total_module_size): Likewise.
13752 Include grub/machine/kernel.h.
13753 (grub_arch_modules_addr): New function.
13754 * util/grub-emu.c (grub_end_addr): Remove variable.
13755 (grub_total_module_size): Likewise.
13756 (grub_arch_modules_addr): New function.
13757 * util/misc.c: Include unistd.h.
13758 (grub_util_get_fp_size): New function.
13759 (grub_util_read_at): Likewise.
13760 (grub_util_write_image_at): Likewise.
13761 (grub_util_read_image): Call grub_util_read_at.
13762 (grub_util_write_image): Call grub_util_write_image_at.
13763 * util/i386/pc/grub-mkimage.c (generate_image): Allocate
13764 additional memory in kernel_img for a struct grub_module_info.
13765 Fill in that grub_module_info.
13766 * util/powerpc/ieee1275/grub-mkimage.c: New file.
13767
13768 2005-01-03 Hollis Blanchard <hollis@penguinppc.org>
13769
13770 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_milliseconds):
13771 New function.
13772 * include/grub/powerpc/ieee1275/ieee1275.h
13773 (grub_ieee1275_milliseconds): New prototype.
13774 * include/grub/powerpc/ieee1275/time.h (GRUB_TICKS_PER_SECOND):
13775 Change to 1000.
13776 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Call
13777 grub_ieee1275_milliseconds.
13778
13779 2005-01-03 Hollis Blanchard <hollis@penguinppc.org>
13780
13781 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_realmode): New
13782 variable.
13783 (find_options): New function.
13784 (cmain): Call find_options.
13785 * include/grub/powerpc/ieee1275/ieee1275.h
13786 (grub_ieee1275_realmode): New extern variable.
13787 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Only call
13788 grub_map if grub_ieee1275_realmode is false.
13789
13790 2004-12-29 Marco Gerards <metgerards@student.han.nl>
13791
13792 * normal/cmdline.c (grub_cmdline_get): Redone logic so no empty
13793 lines are inserted and make it work like readline. Reported by
13794 Vincent Pelletier <subdino2004@yahoo.fr>.
13795
13796 2004-12-28 Marco Gerards <metgerards@student.han.nl>
13797
13798 * boot/powerpc/ieee1275/crt0.S (_start): Don't set up the stack.
13799
13800 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCE): Remove
13801 `kern/powerpc/cache.S'.
13802
13803 2004-12-27 Marco Gerards <metgerards@student.han.nl>
13804
13805 * genmk.rb: Handle the `Program' class in the main loop. Written
13806 by Johan Rydberg <jrydberg@gnu.org>.
13807 (Program): New class.
13808 (programs): New variable.
13809 * boot/powerpc/ieee1275/cmain.c: Include <grub/machine/ieee1275.h>
13810 instead of "grub/machine/ieee1275.h". Include <grub/kernel.h>
13811 instead of "grub/kernel.h". Include <grub/machine/init.h>.
13812 (help_arch): Function removed.
13813 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add
13814 `powerpc/libgcc.h' and `loader.h'.
13815 (pkgdata_PROGRAMS): New variable.
13816 (sbin_UTILITIES): Variable removed.
13817 (grub_emu_SOURCES): Added kern/powerpc/cache.S.
13818 (grubof_SOURCES): Variable re-defined so it only includes the
13819 core functionality.
13820 (grubof_CFLAGS): Remove `-DGRUBOF'.
13821 (pkgdata_MODULES, fshelp_mod_SOURCES, fshelp_mod_CFLAGS,
13822 (fat_mod_SOURCES, fat_mod_CFLAGS, ext2_mod_SOURCES)
13823 (ext2_mod_CFLAGS, ufs_mod_SOURCES, ufs_mod_CFLAGS)
13824 (minix_mod_SOURCES, minix_mod_CFLAGS, hfs_mod_SOURCES)
13825 (hfs_mod_CFLAGS, jfs_mod_SOURCES, jfs_mod_CFLAGS)
13826 (iso9660_mod_SOURCES, iso9660_mod_CFLAGS, _linux_mod_SOURCES)
13827 (_linux_mod_CFLAGS, linux_mod_SOURCES, linux_mod_CFLAGS)
13828 (normal_mod_SOURCES, normal_mod_CFLAGS, normal_mod_ASFLAGS)
13829 (hello_mod_SOURCES, hello_mod_CFLAGS, boot_mod_SOURCES)
13830 (boot_mod_CFLAGS, terminal_mod_SOURCES, terminal_mod_CFLAGS)
13831 (ls_mod_SOURCES, ls_mod_CFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
13832 (cat_mod_SOURCES, cat_mod_CFLAGS, font_mod_SOURCES)
13833 (font_mod_CFLAGS, amiga_mod_SOURCES, amiga_mod_CFLAGS)
13834 (apple_mod_SOURCES, apple_mod_CFLAGS, pc_mod_SOURCES)
13835 (pc_mod_CFLAGS): New variables.
13836 * disk/powerpc/ieee1275/ofdisk.c: Include <grub/machine/init.h>.
13837 (grub_ofdisk_iterate): Add a prototype for `dev_iterate'.
13838 * include/grub/dl.h (grub_arch_dl_sync_caches): New prototype.
13839 * include/grub/loader.h (grub_os_area_addr, grub_os_area_size):
13840 Moved from here...
13841 * include/grub/i386/pc/init.h (grub_os_area_addr)
13842 (rub_os_area_size): ... to here.
13843 * include/grub/powerpc/ieee1275/ieee1275.h
13844 (grub_ieee1275_entry_fn): Export symbol.
13845 * include/grub/powerpc/ieee1275/init.h: New file.
13846 * include/grub/powerpc/libgcc.h: Likewise.
13847 * include/grub/cache.h: Likewise.
13848 * kern/powerpc/cache.S: Likewise. Written by Hollis Blanchard
13849 <hollis@penguinppc.org>.
13850 * kern/dl.c: Include <grub/cache.h>.
13851 (grub_dl_flush_cache): New function.
13852 (grub_dl_load_core): Call `grub_dl_flush_cache' to flush the cache
13853 for this module.
13854 * kern/powerpc/ieee1275/init.c (grub_ofdisk_init)
13855 (grub_console_init): Removed prototypes.
13856 (grub_machine_init): Don't initialize the modules anymore.
13857 * kern/powerpc/ieee1275/openfw.c (grub_map): Make the function
13858 static.
13859 * include/grub/powerpc/types.h (GRUB_HOST_WORDS_LITTLEENDIAN):
13860 Macro undef removed.
13861 (GRUB_HOST_WORDS_BIGENDIAN): New macro.
13862 * kern/powerpc/dl.c (grub_arch_dl_relocate_symbols): Add
13863 relocation `R_PPC_REL32'. Return an error when the relocation is
13864 unknown.
13865 * Makefile.in (DATA): Add `$(pkgdata_PROGRAMS)'.
13866 * kern/i386/pc/init.c (grub_arch_sync_caches): New function.
13867 * util/misc.c (grub_arch_sync_caches): Likewise.
13868
13869 2004-12-19 Marco Gerards <metgerards@student.han.nl>
13870
13871 * conf/powerpc-ieee1275.rmk (MOSTLYCLEANFILES): Remove
13872 `symlist.c', add `grubof_symlist.c'.
13873 (symlist.c): Variable removed.
13874 (grubof_HEADERS): Variable added.
13875 (grubof_symlist.c): New target.
13876 (kernel_syms.lst): Use `grubof_HEADERS' instead of
13877 `kernel_img_HEADERS'.
13878 (grubof_SOURCES): Add `kern/powerpc/dl.c' and `grubof_symlist.c'.
13879 * kern/powerpc/dl.c: New file.
13880 * kern/powerpc/ieee1275/init.c (grub_arch_dl_check_header):
13881 Function removed.
13882 (grub_arch_dl_relocate_symbols): Likewise.
13883 (grub_register_exported_symbols): Likewise.
13884
13885 2004-12-13 Marco Gerards <metgerards@student.han.nl>
13886
13887 * fs/ext2.c (grub_ext2_open): Don't use data after freeing it.
13888 (grub_ext2_dir): Likewise. Don't return in case of an error, jump
13889 to fail instead. Reported by Vincent Pelletier
13890 <subdino2004@yahoo.fr>.
13891
13892 * fs/fshelp.c (grub_fshelp_find_file): Don't free `oldnode' when
13893 it is not allocated. Reported by Vincent Pelletier
13894 <subdino2004@yahoo.fr>.
13895
13896 * normal/cmdline.c (grub_tab_complete): Add a blank line to the
13897 output so the output looks better.
13898
13899 2004-12-04 Marco Gerards <metgerards@student.han.nl>
13900
13901 Modulize the partition map support and add support for the amiga
13902 partition map.
13903
13904 * commands/ls.c: Include <grub/partition.h> instead of
13905 <grub/machine/partition.h>.
13906 * kern/disk.c: Likewise.
13907 * kern/rescue.c: Likewise.
13908 * loader/i386/pc/chainloader.c: Likewise.
13909 * normal/cmdline.c: Likewise.
13910 * kern/powerpc/ieee1275/init.c: Likewise.
13911 (grub_machine_init): Call `grub_pc_partition_map_init',
13912 `grub_amiga_partition_map_init' and
13913 `grub_apple_partition_map_init'.
13914 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove
13915 `disk/i386/pc/partition.c'. Add `kern/partition.c'.
13916 (kernel_img_HEADERS): Remove `machine/partition.h'. Add
13917 `partition.h' and `pc_partition.h'.
13918 (grub_setup_SOURCES): Remove
13919 `disk/i386/pc/partition.c'. Add `kern/partition.c',
13920 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
13921 (grub_emu_SOURCES): Likewise.
13922 (pkgdata_MODULES): Add `amiga.mod', `apple.mod' and `pc.mod'.
13923 (amiga_mod_SOURCES, amiga_mod_CFLAGS, apple_mod_SOURCES)
13924 (apple_mod_CFLAGS, pc_mod_SOURCES, pc_mod_CFLAGS): New variables.
13925 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
13926 `disk/powerpc/ieee1275/partition.c'. Add `kern/partition.c',
13927 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
13928 (grubof_SOURCES): Likewise.
13929 * disk/i386/pc/partition.c: File removed.
13930 * disk/powerpc/ieee1275/partition.c: Likewise.
13931 * include/grub/powerpc/ieee1275/partition.h: Likewise.
13932 * include/grub/i386/pc/partition.h: Likewise.
13933 * kern/partition.c: New file.
13934 * partmap/amiga.c: Likewise.
13935 * partmap/apple.c: Likewise.
13936 * partmap/pc.c: Likewise.
13937 * include/grub/partition.h: Likewise..
13938 * include/grub/pc_partition.h: Likewise.
13939 * util/grub-emu.c: Include <grub/partition.h> instead of
13940 <grub/machine/partition.h>.
13941 (main): Call `grub_pc_partition_map_init',
13942 `grub_amiga_partition_map_init' and
13943 `grub_apple_partition_map_init' and deinitialize afterwards.
13944 * util/i386/pc/biosdisk.c: Include `#include
13945 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
13946 `<grub/machine/partition.h>'.
13947 * util/i386/pc/grub-setup.c: Likewise.
13948 * util/i386/pc/biosdisk.c: Likewise.
13949 (grub_util_biosdisk_get_grub_dev): Only access the PC specific
13950 partition information in case of a PC partition.
13951 * util/i386/pc/grub-setup.c: Include `#include
13952 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
13953 `<grub/machine/partition.h>'.
13954 (setup): Only access the PC specific partition information in case
13955 of a PC partition.
13956
13957 2004-11-17 Hollis Blanchard <hollis@penguinppc.org>
13958
13959 * kern/powerpc/ieee1275/init.c (grub_setjmp): Remove function.
13960 (grub_longjmp): Likewise.
13961 * include/grub/powerpc/setjmp.h (grub_jmp_buf): Set array size to
13962 20.
13963 * normal/powerpc/setjmp.S: New file.
13964 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
13965 `normal/powerpc/setjmp.S'.
13966 (grubof_CFLAGS): Add `-DGRUBOF'.
13967 * include/grub/setjmp.h [GRUB_UTIL]: Changed condition to
13968 [GRUB_UTIL && !GRUBOF].
13969
13970 2004-11-16 Marco Gerards <metgerards@student.han.nl>
13971
13972 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Skip any
13973 property named `name'. Correctly handle the error returned by
13974 `grub_ieee1275_finddevice' if a device can not be opened.
13975
13976 2004-11-02 Hollis Blanchard <hollis@penguinppc.org>
13977
13978 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_readkey): Test
13979 `actual' for negativity.
13980 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
13981 kern/fshelp.c.
13982
13983 2004-11-01 Marco Gerards <metgerards@student.han.nl>
13984
13985 * term/i386/pc/vga.c (VGA_HEIGHT): Changed to 350.
13986 (PAGE_OFFSET): New macro.
13987 (CRTC_ADDR_PORT): Likewise.
13988 (CRTC_DATA_PORT): Likewise.
13989 (START_ADDR_HIGH_REGISTER): Likewise.
13990 (START_ADDR_LOW_REGISTER): Likewise.
13991 (GRAPHICS_ADDR_PORT): Likewise.
13992 (GRAPHICS_DATA_PORT): Likewise.
13993 (READ_MAP_REGISTER): Likewise.
13994 (INPUT_STATUS1_REGISTER): Likewise.
13995 (INPUT_STATUS1_VERTR_BIT): Likewise.
13996 (page): New variable.
13997 (wait_vretrace): New function.
13998 (set_read_map): Likewise.
13999 (set_start_address): Likewise.
14000 (grub_vga_init): Use mode 0x10 instead of mode 0x12. Switch to
14001 the right page.
14002 (check_vga_mem): Take the page into account.
14003 (write_char): Likewise.
14004 (write_cursor): Likewise.
14005 (scroll_up): Likewise. Copy the page to the page that is not
14006 shown and switch between both pages.
14007 (grub_vga_putchar): Fix off by one error.
14008 (grub_vga_cls): Wait for the vertical retrace. Take the page into
14009 account.
14010
14011 2004-11-01 Marco Gerards <metgerards@student.han.nl>
14012
14013 Add support for iso9660 (including rockridge).
14014
14015 * conf/i386-pc.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
14016 (iso9660_mod_SOURCES): New variable.
14017 (iso9660_mod_CFLAGS): Likewise.
14018 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
14019 * include/grub/fs.h (grub_iso9660_init): New prototype.
14020 * util/grub-emu.c (main): Call `grub_iso9660_init'.
14021 * fs/iso9660.c: New file.
14022
14023 * include/grub/misc.h (grub_strncat): New prototype.
14024 * kern/misc.c (grub_strncat): New function.
14025
14026 * fs/hfs.c (grub_hfs_mount): Translate the error
14027 `GRUB_ERR_OUT_OF_RANGE' to `GRUB_ERR_BAD_FS'.
14028 * fs/jfs.c (grub_jfs_mount): Likewise.
14029 * fs/ufs.c (grub_ufs_mount): Likewise.
14030
14031 2004-10-28 Hollis Blanchard <hollis@penguinppc.org>
14032
14033 * boot/powerpc/ieee1275/cmain.c (cmain): Remove asm statements
14034 which initialized BAT registers.
14035 * boot/powerpc/ieee1275/ieee1275.c (IEEE1275_CALL_ENTRY_FN,
14036 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
14037 Move from here...
14038 * include/grub/powerpc/ieee1275/ieee1275.h (IEEE1275_CALL_ENTRY_FN,
14039 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
14040 ... to here.
14041 * kern/powerpc/ieee1275/openfw.c (grub_map): New function.
14042 (grub_mapclaim): Likewise.
14043 * loader/powerpc/ieee1275/linux.c (grub_load_linux): Use
14044 grub_mapclaim instead of grub_ieee1275_claim. Assign linux_addr by
14045 hand.
14046
14047 2004-10-19 Hollis Blanchard <hollis@penguinppc.org>
14048
14049 * conf/powerpc-ieee1275.rmk (COMMON_ASFLAGS): Remove -fno-builtin.
14050 (COMMON_CFLAGS): Remove -fno-builtin and -D__ASSEMBLY__. Add
14051 -ffreestanding and -msoft-float.
14052
14053 2004-10-15 Hollis Blanchard <hollis@penguinppc.org>
14054
14055 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Do not
14056 append ":0" to devpath if the GRUB_IEEE1275_NO_PARTITION_0 flag is
14057 set in grub_ieee1275_flags.
14058
14059 2004-10-14 Hollis Blanchard <hollis@penguinppc.org>
14060
14061 * include/grub/powerpc/ieee1275/ieee1275.h (abort): Add function
14062 prototype.
14063 * kern/powerpc/ieee1275/init.c (grub_machine_init): Call
14064 grub_console_init first.
14065 Change the memory range used for grub_ieee1275_claim and
14066 grub_mm_init_region.
14067 Print an error message if the claim fails.
14068 Include <grub/misc.h>.
14069
14070 2004-10-13 Hollis Blanchard <hollis@penguinppc.org>
14071
14072 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_iterate):
14073 Call grub_children_iterate for device nodes of type `scsi',
14074 `ide', or `ata'.
14075 (grub_ofdisk_open): Remove manual device alias resolution.
14076 Fix memory leak when device cannot be opened.
14077 * include/grub/powerpc/ieee1275/ieee1275.h
14078 (grub_children_iterate): New prototype.
14079 * kern/powerpc/ieee1275/openfw.c (grub_children_iterate):
14080 New function.
14081 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
14082 Return -1 if args.size was -1.
14083
14084 2004-10-11 Hollis Blanchard <hollis@penguinppc.org>
14085
14086 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_flags): New global.
14087 (cmain): Accept 3 parameters. Test for 0xdeadbeef, indicating Old
14088 World Macintosh. If Old Wold, set flag in grub_ieee1275_flags; claim
14089 Open Firmware's memory for it; claim memory from _start to _end.
14090 * boot/powerpc/ieee1275/crt0.S (__bss_start): New extern.
14091 (_end): New extern.
14092 (_start): Zero BSS from __bss_start to _end.
14093 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
14094 New extern.
14095 (GRUB_IEEE1275_NO_PARTITION_0): New #define.
14096
14097 2004-10-11 Hollis Blanchard <hollis@penguinppc.org>
14098
14099 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): Return
14100 -1 if args.base was -1.
14101
14102 2004-10-08 Hollis Blanchard <hollis@penguinppc.org>
14103
14104 * term/powerpc/ieee1275/ieee1275.c (grub_ofconsole_cls): Use an ANSI
14105 escape sequence instead of a literal ^L. Also call
14106 grub_ofconsole_gotoxy.
14107
14108 2004-10-03 Hollis Blanchard <hollis@penguinppc.org>
14109
14110 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): change
14111 void * arguments to grub_addr_t. All callers updated. Also make
14112 the `result' argument optional.
14113 (grub_ieee1275_release): change void * arguments to grub_addr_t.
14114 All callers updated.
14115
14116 2004-09-22 Hollis Blanchard <hollis@penguinppc.org>
14117
14118 * commands/ls.c (grub_ls_list_files): Use the string following the
14119 initial ')', if present, as the filesystem path.
14120 * kern/rescue.c (grub_rescue_cmd_ls): Likewise.
14121
14122 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): List crt0.S first.
14123
14124 2004-09-18 Yoshinori K. Okuji <okuji@enbug.org>
14125
14126 Make the source code of the menu interface more readable.
14127
14128 * normal/menu.c: Include grub/mm.h.
14129 (TERM_WIDTH): New macro.
14130 (TERM_HEIGHT): Likewise.
14131 (TERM_INFO_HEIGHT): Likewise.
14132 (TERM_MARGIN): Likewise.
14133 (TERM_SCROLL_WIDTH): Likewise.
14134 (TERM_TOP_BORDER_Y): Likewise.
14135 (TERM_LEFT_BORDER_X): Likewise.
14136 (TERM_BORDER_WIDTH): Likewise.
14137 (TERM_MESSAGE_HEIGHT): Likewise.
14138 (TERM_BORDER_HEIGHT): Likewise.
14139 (TERM_NUM_ENTRIES): Likewise.
14140 (TERM_FIRST_ENTRY_Y): Likewise.
14141 (TERM_ENTRY_WIDTH): Likewise.
14142 (TERM_CURSOR_X): Likewise.
14143 (draw_border): Use macros instead of magic numbers.
14144 (print_entry): Likewise.
14145 (print_entries): Likewise.
14146 (run_menu): Likewise. Also, handle the key 'e'.
14147 (run_menu_entry): Ignore empty command lines.
14148 (print_message): Added a new argument EDIT. If EDIT is true,
14149 print a different message.
14150 (init_page): Likewise.
14151 (edit_menu_entry): New function. Not implemented yet.
14152
14153 2004-09-17 Marco Gerards <metgerards@student.han.nl>
14154
14155 Add `linux.mod' and `multiboot.mod' so linux and multiboot kernels
14156 can be loaded from normal mode.
14157
14158 * conf/i386-pc.rmk (pkgdata_MODULES): Add `linux.mod' and
14159 `multiboot.mod'.
14160 (linux_mod_SOURCES, linux_mod_CFLAGS, multiboot_mod_SOURCES)
14161 (multiboot_mod_CFLAGS): New variables.
14162 * loader/i386/pc/linux_normal.c: New file.
14163 * loader/i386/pc/multiboot_normal.c: Likewise.
14164
14165 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Don't use the
14166 attribute `unused'.
14167
14168 * fs/ext2.c (grub_ext2_iterate_dir): Fix typos in inode type. Use
14169 `fdiro' to read the mode information from instead of `diro'.
14170
14171 * fs/fshelp.c (grub_fshelp_find_file): Set type to foundtype after
14172 looking up a symlink.
14173
14174 * include/grub/normal.h (GRUB_COMMAND_FLAG_NO_ARG_PARSE): New
14175 macro.
14176 * normal/command.c (grub_command_execute): Don't parse the
14177 arguments when `GRUB_COMMAND_FLAG_NO_ARG_PARSE' is set in the
14178 flags of the command.
14179
14180 * normal/menu.c (grub_menu_run): Fix typo.
14181
14182 2004-09-14 Hollis Blanchard <hollis@penguinppc.org>
14183
14184 * kern/powerpc/ieee1275/init.c (abort): Trap into Open Firmware.
14185
14186 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_gotoxy): Use
14187 `y + 1' instead of `y - 1'.
14188
14189 * conf/powerpc-ieee1275.rmk (grubof_LDFLAGS): Add `-N' and `-S'.
14190
14191 2004-09-14 Yoshinori K. Okuji <okuji@enbug.org>
14192
14193 From Hollis Blanchard <hollis@penguinppc.org>:
14194 * kern/misc.c (memmove): New alias for grub_memmove.
14195 (memcmp): New alias for grub_memcmp.
14196 (memset): New alias for grub_memset.
14197 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
14198 Change "int handle" to "grub_ieee1275_phandle_t handle".
14199 * include/grub/powerpc/ieee1275/ieee1275.h
14200 (grub_ieee1275_get_property): Likewise.
14201
14202 2004-09-12 Tomas Ebenlendr <ebik@ucw.cz>
14203
14204 Added normal mode command `chainloader' as module chain.mod, which
14205 depends on normal.mod and _chain.mod.
14206
14207 * conf/i386-pc.rmk (pkgdata_MODULES): Add `chain.mod'.
14208 (chain_mod_SOURCES, chain_mod_CFLAGS): Variables added.
14209 * include/grub/i386/pc/loader.h (grub_rescue_cmd_chainloader):
14210 Deleted prototype.
14211 * loader/i386/pc/chainloader.c (grub_rescue_cmd_chainloader): All
14212 but arguments parsing moved to ...
14213 (grub_chainloader_cmd): ... here. New function.
14214 * include/grub/i386/pc/chainloader.h: New file.
14215 * loader/i386/pc/chainloader_normal.c: Likewise.
14216
14217 2004-09-11 Marco Gerards <metgerards@student.han.nl>
14218
14219 * conf/i386-pc.rmk (kernel_img_SOURCES): Added kern/fshelp.c.
14220 (grub_mkimage_LDFLAGS): Likewise.
14221 (grub_emu_SOURCES): Likewise.
14222 (kernel_img_HEADERS): Added fshelp.h.
14223 * fs/ext2.c: Include <grub/fshelp.h>.
14224 (FILETYPE_REG): New macro.
14225 (FILETYPE_INO_REG): Likewise.
14226 (grub_ext_sblock): Renamed to `grub_ext2_sblock'.
14227 Changed all users.
14228 (ext2_block_group): Renamed to `grub_ext2_block_group'. Changed
14229 all users.
14230 (grub_fshelp_node): New struct.
14231 (grub_ext2_data): Added member `diropen'. Changed member `inode'
14232 to a pointer.
14233 (grub_ext2_get_file_block): Removed function.
14234 (grub_ext2_read_block): New function.
14235 (grub_ext2_read_file): Replaced parameter `data' by `node'.
14236 This function was written.
14237 (grub_ext2_mount): Read the root inode. Create a diropen struct.
14238 (grub_ext2_find_file): Removed function.
14239 (grub_ext2_read_symlink): New function.
14240 (grub_ext2_iterate_dir): Likewise.
14241 (grub_ext2_open): Rewritten.
14242 (grub_ext2_dir): Rewritten.
14243 * include/grub/fshelp.h: New file.
14244 * fs/fshelp.c: Likewise.
14245
14246 2004-09-10 Yoshinori K. Okuji <okuji@enbug.org>
14247
14248 * normal/menu.c: Include grub/loader.h and grub/machine/time.h.
14249 (print_message): Add a missing newline.
14250 (run_menu): Added timeout support.
14251 (run_menu_entry): New local function.
14252 (grub_menu_run): Added support for booting.
14253
14254 * kern/loader.c (grub_loader_is_loaded): New function.
14255
14256 * include/grub/powerpc/ieee1275/time.h: Include grub/symbol.h.
14257 (grub_get_rtc): Exported.
14258
14259 * include/grub/i386/pc/time.h: Include grub/symbol.h.
14260 (grub_get_rtc): Exported.
14261
14262 * include/grub/normal.h (struct grub_command_list): Remove
14263 constant from the member `command'.
14264
14265 * include/grub/loader.h (grub_loader_is_loaded): Declared.
14266
14267 * include/grub/err.h (GRUB_ERR_INVALID_COMMAND): New constant.
14268
14269 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/time.h.
14270
14271 2004-08-28 Marco Gerards <metgerards@student.han.nl>
14272
14273 Add support for the JFS filesystem.
14274
14275 * fs/jfs.c: New file.
14276 * include/grub/fs.h (grub_jfs_init): New prototype.
14277 (grub_jfs_fini): New prototype.
14278 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/jfs.c.
14279 (grub_emu_SOURCES): Likewise.
14280 (pkgdata_MODULES): Add jfs.mod.
14281 (jfs_mod_SOURCES): New variable.
14282 (jfs_mod_CFLAGS): Likewise.
14283 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs.jfs.c.
14284 (grubof_SOURCES): Likewise.
14285 * util/grub-emu.c (main): Initialize and deinitialize JFS support.
14286
14287 * fs/fat.c (grub_fat_find_dir): Convert the filename little
14288 endian to the host endian.
14289 (grub_fat_utf16_to_utf8): Move function from there...
14290 * kern/misc.c (grub_utf16_to_utf8): ...to here. Do not convert
14291 the endianness of the source string anymore.
14292 * include/grub/misc.h (grub_utf16_to_utf8): New prototype.
14293
14294 2004-08-24 Marco Gerards <metgerards@student.han.nl>
14295
14296 * commands/boot.c (grub_boot_init) [GRUB_UTIL]: Make conditional.
14297 (grub_boot_fini) [GRUB_UTIL]: Likewise.
14298 (GRUB_MOD_INIT) [!GRUB_UTIL]: Likewise.
14299 (GRUB_MOD_FINI) [!GRUB_UTIL]: Likewise.
14300
14301 * fs/hfs.c (grub_hfs_find_node): Add a prototype for `node_found'.
14302 (grub_hfs_iterate_dir): Make the function static. Add prototypes
14303 for `node_found' and `it_dir'.
14304 (grub_hfs_dir): Add prototype for `dir_hook'.
14305
14306 * fs/minix.c (grub_minix_get_file_block): Add prototype for
14307 `grub_get_indir'. Rename `indir' in two blocks to `indir16'
14308 and `indir32' to silence a gcc warning.
14309
14310 * include/grub/fs.h (grub_hfs_init): New prototype.
14311 (grub_hfs_fini): Likewise.
14312
14313
14314 2004-08-21 Yoshinori K. Okuji <okuji@enbug.org>
14315
14316 Each disk device has its own id now. This is useful to make use
14317 of multiple disk devices.
14318
14319 * include/grub/disk.h (grub_disk_dev_id): New enum.
14320 (GRUB_DISK_DEVICE_BIOSDISK_ID): New constant.
14321 (GRUB_DISK_DEVICE_OFDISK_ID): Likewise.
14322
14323 * disk/i386/pc/biosdisk.c (grub_biosdisk_dev): Specify
14324 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
14325
14326 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_dev): Specify
14327 GRUB_DISK_DEVICE_OFDISK_ID as an id.
14328
14329 * util/i386/pc/biosdisk.c (grub_util_biosdisk_dev): Specify
14330 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
14331
14332 * include/grub/disk.h (struct grub_disk_dev): Added a new member
14333 "id" which is used by the cache manager.
14334
14335 * normal/main.c (grub_normal_init_page): Use "GNU GRUB" instead
14336 of just "GRUB".
14337
14338 2004-08-18 Marco Gerards <metgerards@student.han.nl>
14339
14340 * fs/hfs.c: New file.
14341 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/hfs.c.
14342 (grub_emu_SOURCES): Likewise.
14343 (pkgdata_MODULES): Add hfs.mod.
14344 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/hfs.c.
14345 (grubof_SOURCES): Likewise.
14346 * util/grub-emu.c (main): Initialize and deinitialize HFS support.
14347
14348 * include/grub/misc.h (grub_strncasecmp): Add prototype.
14349 * kern/misc.c (grub_strncasecmp): Add function.
14350
14351 2004-08-14 Marco Gerards <metgerards@student.han.nl>
14352
14353 * include/grub/arg.h (GRUB_ARG_OPTION_OPTIONAL): Surround macro
14354 with parentheses.
14355
14356 * fs/ext2.c (FILETYPE_UNKNOWN): New macro.
14357 (grub_ext2_dir): In case the directory entry type is unknown, read
14358 it from the inode.
14359
14360 2004-08-02 Peter Bruin <pjbruin@dds.nl>
14361
14362 * loader/powerpc/ieee1275/linux.c (grub_linux_init): Pass
14363 grub_load_linux instead of grub_rescue_cmd_linux as second
14364 argument of grub_rescue_register_command.
14365
14366 * Makefile.in (RMKFILES): Add conf/powerpc-ieee1275.rmk.
14367
14368 2004-07-27 Marco Gerards <metgerards@student.han.nl>
14369
14370 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_release): New
14371 function.
14372 * commands/boot.c: Remove the check for `GRUB_UTIL'.
14373 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
14374 `loader/powerpc/ieee1275/linux.c',
14375 `loader/powerpc/ieee1275/linux_normal.c' and `commands/boot.c'.
14376 * include/grub/powerpc/ieee1275/ieee1275.h
14377 (grub_ieee1275_release): New prototype.
14378 * include/grub/powerpc/ieee1275/loader.h: Rewritten.
14379 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize
14380 normal, boot, linux and linux_normal.
14381 * loader/powerpc/ieee1275/linux.c: New file.
14382 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
14383
14384 2004-07-12 Marco Gerards <metgerards@student.han.nl>
14385
14386 * normal/arg.c (grub_arg_parse): Correct error handling after
14387 reallocating the argumentlist (check if `argl' is not null instead
14388 of checking if `args' is not null).
14389 * kern/mm.c (grub_realloc): Return the same pointer when using the
14390 same region, instead of returning the header address.
14391
14392 2004-07-11 Marco Gerards <metgerards@student.han.nl>
14393
14394 * disk/powerpc/ieee1275/partition.c (grub_partition_iterate): Skip
14395 one block instead of two when looking for the initial partition.
14396 (grub_partition_probe): Initialize the local variable `p' with 0.
14397 Use base 10 for the grub_strtoul call.
14398 * kern/misc.c (grub_strncpy): Fix off by one bug. Eliminated the
14399 need for one local variable.
14400 (grub_strtoul): Don't add the new value to `num', instead of that
14401 just assign it.
14402
14403 2004-07-11 Marco Gerards <metgerards@student.han.nl>
14404
14405 * conf/i386-pc.rmk (pkgdata_IMAGE): Add pxeboot.img.
14406 (pxeboot_img_SOURCES): New variable.
14407 (pxeboot_img_ASFLAGS): Likewise.
14408 (pxeboot_img_LDFLAGS): Likewise.
14409 * boot/i386/pc/pxeboot.S: New file. Based on pxeloader.S from
14410 GRUB Legacy and boot.S. Adopted for GRUB 2 by lode leroy
14411 <lode_leroy@hotmail.com>.
14412
14413 2004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
14414
14415 * kern/rescue.c (grub_enter_rescue_mode): Don't continue when
14416 there was no input.
14417
14418 2004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
14419
14420 * normal/cmdline.c (grub_set_history): Fix off by one bug. Fixed
14421 the history buffer logic.
14422
14423 2004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
14424
14425 * fs/ext2.c (FILETYPE_INO_MASK, FILETYPE_INO_DIRECTORY)
14426 (FILETYPE_INO_SYMLINK): New macros.
14427 (grub_ext2_find_file): Check if the node is a directory using the
14428 inode stat information instead of using the filetype in the
14429 dirent. Exclude the first character of an absolute symlink.
14430 (grub_ext2_dir): Mask out the filetype part of the mode member of
14431 the inode.
14432
14433 2004-05-24 Marco Gerards <metgerards@student.han.nl>
14434
14435 Add support for UFS version 1 and 2. Add support for the minix
14436 filesystem version 1 and 2, both the variants with 14 and 30 long
14437 filenames.
14438
14439 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ufs.c and
14440 fs/minix.c.
14441 (grub_emu_SOURCES): Likewise.
14442 (pkgdata_MODULES): Add ufs.mod and minix.mod.
14443 (ufs_mod_SOURCES): New variable.
14444 (ufs_mod_CFLAGS): Likewise.
14445 (minix_mod_SOURCES): Likewise.
14446 (minix_mod_CFLAGS): Likewise.
14447 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/ufs.c and
14448 fs/minix.c.
14449 (grubof_SOURCES): Likewise.
14450 * fs/ufs.c: New file.
14451 * fs/minix.c: New file.
14452 * include/grub/fs.h (grub_ufs_init): New prototype.
14453 (grub_ufs_fini): Likewise.
14454 (grub_minix_init): Likewise.
14455 (grub_minix_fini): Likewise.
14456 * util/grub-emu.c (main): Initialize and deinitialize UFS and
14457 minix fs.
14458
14459 2004-04-30 Jeroen Dekkers <jeroen@dekkers.cx>
14460
14461 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add normal/arg.c,
14462 commands/ls.c, commands/terminal.c, commands/boot.c,
14463 commands/cmp.c and commands/cat.c.
14464 (grubof_LDFLAGS): Add -nostdlib -static-libgcc -lgcc.
14465
14466 * kern/powerpc/ieee1275/init.c: Include "grub/env.h" instead of
14467 "env.h"
14468
14469 2004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
14470
14471 All symbols prefixed with PUPA_ and pupa_ are renamed to GRUB_
14472 and grub_, respectively. Because the conversion is trivial and
14473 mechanical, I omit the details here. Please refer to the CVS
14474 if you need more information.
14475
14476 2004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
14477
14478 * include/pupa: Renamed to ...
14479 * include/grub: ... this.
14480 * util/i386/pc/pupa-mkimage.c: Renamed to ...
14481 * util/i386/pc/grub-mkimage.c: ... this.
14482 * util/i386/pc/pupa-setup.c: Renamed to ...
14483 * util/i386/pc/grub-setup.c: ... this.
14484 * util/pupa-emu.c: Renamed to ...
14485 * util/grub-emu.c: ... this.
14486
14487 2004-03-29 Marco Gerards <metgerards@student.han.nl>
14488
14489 Add support for the newworld apple macintosh (PPC). This has been
14490 tested on the powerbook 2000 only. It only adds support for
14491 generic ieee1275 functions, console and disk support. This should
14492 be easy to port to other architectures with support for Open
14493 Firmware.
14494
14495 * configure.ac: Accept the powerpc as host_cpu. In the case of
14496 the powerpc cpu set the host_vendor to ieee1275. Make sure the i386
14497 specific tests are only executed while building for the i386.
14498 Inverse test for crosscompile.
14499 * genmk.rb (Utility): Allow assembler files.
14500 * normal/cmdline.c (pupa_tab_complete): Reset pupa_errno.
14501 * conf/powerpc-ieee1275.rmk: New file.
14502 * disk/powerpc/ieee1275/ofdisk.c: Likewise.
14503 * disk/powerpc/ieee1275/partition.c: Likewise.
14504 * include/pupa/powerpc/ieee1275/biosdisk.h: Likewise.
14505 * include/pupa/powerpc/ieee1275/console.h: Likewise.
14506 * include/pupa/powerpc/ieee1275/partition.h: Likewise.
14507 * include/pupa/powerpc/ieee1275/time.h: Likewise.
14508 * include/pupa/powerpc/ieee1275/util/biosdisk.h: Likewise.
14509 * include/pupa/powerpc/ieee1275/multiboot.h: Likewise.
14510 * include/pupa/powerpc/ieee1275/loader.h
14511 * include/pupa/powerpc/setjmp.h: Likewise.
14512 * include/pupa/powerpc/types.h: Likewise.
14513 * kern/powerpc/ieee1275/init.c: Likewise.
14514 * kern/powerpc/ieee1275/openfw.c: Likewise.
14515 * term/powerpc/ieee1275/ofconsole.c: Likewise.
14516
14517 These files were written by Johan Rydberg
14518 (jrydberg@night.trouble.net) and I only modified them slightly.
14519
14520 * boot/powerpc/ieee1275/cmain.c: New file.
14521 * boot/powerpc/ieee1275/crt0.S: Likewise.
14522 * boot/powerpc/ieee1275/ieee1275.c: Likewise.
14523 * include/pupa/powerpc/ieee1275/ieee1275.h: Likewise.
14524
14525 2004-03-14 Jeroen Dekkers <jeroen@dekkers.cx>
14526
14527 * Makefile.in: Update copyright.
14528 * genmodsrc.sh: Likewise.
14529 * gensymlist.sh: Likewise.
14530 * term/i386/pc/vga.c: Indent correctly.
14531
14532 * util/i386/pc/pupa-mkimage.c (usage): Use PACKAGE_BUGREPORT as
14533 bugreporting address.
14534 * util/i386/pc/pupa-setup.c (usage): Likewise,
14535 (main): Call pupa_ext2_init and pupa_ext2_fini.
14536
14537 * fs/fat.c (log2): Renamed to ...
14538 (fat_log2): ... this.
14539 All callers changed.
14540 * kern/misc.c (memcpy): Alias to pupa_memmove.
14541 * loader/i386/pc/multiboot.c (pupa_rescue_cmd_multiboot): Fix
14542 lvalue cast.
14543 * util/console.c (pupa_ncurses_fini): Return 0.
14544
14545 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open)[__linux__]:
14546 Move fail label here.
14547 [__GNU__]: Don't warn when using stat.
14548 (open_device)[!__linux__]: Check if FD < 0 instead of !FD.
14549 (pupa_util_biosdisk_get_pupa_dev)[__GNU__]: Change type of N to
14550 long int. Use strtol instead of strtoul.
14551
14552 2004-03-14 Marco Gerards <metgerards@student.han.nl>
14553
14554 * commands/boot.c: New file.
14555 * commands/cat.c: Likewise.
14556 * commands/cmp.c: Likewise.
14557 * commands/ls.c: Likewise.
14558 * commands/terminal.c: Likewise.
14559 * normal/command.c: Include <pupa/env.h> and <pupa/dl.h>.
14560 (pupa_register_command): Changed interface to match the new
14561 argument parser.
14562 (pupa_command_execute): Changed (almost rewritten) so it uses
14563 pupa_split_command. Added support for setting variables using the
14564 syntax `foo=bar'.
14565 (rescue_command): Changed to work with the new argument parser.
14566 (terminal_command): Moved from here to commands/terminal.c.
14567 (set_command): New function.
14568 (unset_command): New function.
14569 (insmod_command): New function.
14570 (rmmod_command): New function.
14571 (lsmod_command): New function.
14572 (pupa_command_init): Don't initialize the command terminal
14573 anymore. Initialize the commands set, unset, insmod, rmmod and
14574 lsmod.
14575 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/env.c.
14576 (kernel_img_HEADERS): Add arg.h and env.h.
14577 (pupa_mkimage_LDFLAGS): Add kern/env.c.
14578 (pupa_emu_SOURCES): Add kern/env.c, commands/ls.c,
14579 commands/terminal.c commands/boot.c commands/cmp.c commands/cat.c,
14580 normal/arg.c.
14581 (pkgdata_MODULES): Add ls.mod, boot.mod, cmp.mod, cat.mod and
14582 terminal.mod.
14583 (normal_mod_SOURCES): Add normal/arg.c and normal/arg.c.
14584 (boot_mod_SOURCES): New variable.
14585 (terminal_mod_SOURCES): Likewise.
14586 (ls_mod_SOURCES): Likewise.
14587 (cmp_mod_SOURCES): Likewise.
14588 (cat_mod_SOURCES): Likewise.
14589
14590 * normal/arg.c: New file.
14591 * kern/env.c: Likewise.
14592 * include/pupa/arg.h: Likewise.
14593 * include/pupa/env.h: Likewise.
14594 * font/manager.c (font_command): Changed to match argument parsing
14595 interface changes.
14596 (PUPA_MOD_INIT): Likewise.
14597 * hello/hello.c (pupa_cmd_hello): Likewise.
14598 (PUPA_MOD_INIT): Likewise.
14599 * include/pupa/disk.h: Include <pupa/device.h>.
14600 (pupa_print_partinfo): New prototype.
14601 * include/pupa/dl.h (pupa_dl_set_prefix): Prototype removed.
14602 (pupa_dl_get_prefix): Likewise.
14603 * include/pupa/misc.h: Include <pupa/err.h>.
14604 (pupa_isgraph): New prototype.
14605 (pupa_isdigit): Likewise.
14606 (pupa_split_cmdline): Likewise.
14607 * include/pupa/normal.h: Include <pupa/arg.h>.
14608 (pupa_command): Changed the prototype of the member `func' to
14609 match the argument parsing interface. Added member `options'.
14610 (pupa_register_command): Updated to match function.
14611 (pupa_arg_parse): New prototype.
14612 (pupa_hello_init) [PUPA_UTIL]: New prototype.
14613 (pupa_hello_fini) [PUPA_UTIL]: Likewise.
14614 (pupa_ls_init) [PUPA_UTIL]: Likewise.
14615 (pupa_ls_fini) [PUPA_UTIL]: Likewise.
14616 (pupa_cat_init) [PUPA_UTIL]: Likewise.
14617 (pupa_cat_fini) [PUPA_UTIL]: Likewise.
14618 (pupa_boot_init) [PUPA_UTIL]: Likewise.
14619 (pupa_boot_fini) [PUPA_UTIL]: Likewise.
14620 (pupa_cmp_init) [PUPA_UTIL]: Likewise.
14621 (pupa_cmp_fini) [PUPA_UTIL]: Likewise.
14622 (pupa_terminal_init) [PUPA_UTIL]: Likewise.
14623 (pupa_terminal_fini) [PUPA_UTIL]: Likewise.
14624 * kern/disk.c: Include <pupa/file.h>.
14625 (pupa_print_partinfo): New function.
14626 * kern/dl.c: Include <pupa/env.h>.
14627 (pupa_dl_dir): Variable removed.
14628 (pupa_dl_load): Use the environment variable `prefix' instead of
14629 the variable pupa_dl_dir.
14630 (pupa_dl_set_prefix): Function removed.
14631 (pupa_dl_get_prefix): Likewise.
14632 * kern/i386/pc/init.c: Include <pupa/env.h>.
14633 (pupa_machine_init): Use the environment variable `prefix' instead of
14634 using pupa_dl_set_prefix to set the prefix.
14635 * kern/main.c: Include <pupa/env.h>.
14636 (pupa_set_root_dev): Use the environment variable `prefix' instead of
14637 using pupa_dl_get_prefix to get the prefix.
14638 * kern/misc.c: Include <pupa/env.h>.
14639 (pupa_isdigit): New function.
14640 (pupa_isgraph): Likewise.
14641 (pupa_ftoa): Likewise.
14642 (pupa_vsprintf): Added support for printing values of the type
14643 `double'. Make it possible to format variable output when using
14644 formatting like `%1.2%f'.
14645 (pupa_split_cmdline): New function.
14646 * kern/rescue.c: Include <pupa/env.h>.
14647 (next_word): Removed function.
14648 (pupa_rescue_cmd_prefix): Likewise.
14649 (pupa_rescue_cmd_set): New function.
14650 (pupa_rescue_cmd_unset): New function.
14651 (pupa_enter_rescue_mode): Use the `pupa_split_cmdline' function to
14652 split the command line instead of splitting it here. Added
14653 support for setting variables using the syntax `foo=bar'. Don't
14654 initialize the prefix command anymore. Initialized the set and
14655 unset commands.
14656 * normal/cmdline.c: Include <pupa/env.h>.
14657 (pupa_tab_complete): Added prototypes for print_simple_completion,
14658 print_partition_completion, add_completion, iterate_commands,
14659 iterate_dev, iterate_part and iterate_dir. Moved code to print
14660 partition information from here to kern/disk.c.
14661 (pupa_cmdline_run): Don't check if the function exists anymore.
14662 * normal/main.c: Include <pupa/env.h>.
14663 (pupa_rescue_cmd_normal): Use the environment variable `prefix'
14664 instead of using pupa_dl_get_prefix to get the prefix.
14665 * term/i386/pc/vga.c: Include <pupa/arg.h>.
14666 (check_vga_mem): Cast pointers to `void *' to silence a gcc
14667 warning.
14668 (pupa_vga_putchar) [! DEBUG_VGA]: Removed for this case.
14669 (pupa_vga_setcolor): Declare unused variables with `__attribute__
14670 ((unused))' to silence a gcc warning.
14671 (pupa_vga_setcolor): Likewise.
14672 (debug_command): Changed to match argument parsing
14673 interface changes.
14674 * util/pupa-emu.c: Include <pupa/env.h>.
14675 (options): Added 0's for unused fields to silence a gcc warning.
14676 (argp): Likewise.
14677 (main): Use the environment variable `prefix' instead of using
14678 pupa_dl_set_prefix to set the prefix. Initialize the commands ls,
14679 boot, cmp, cat and terminal. Finish the commands boot, cmp, cat
14680 and terminal.
14681
14682 * util/i386/pc/getroot.c: Include <pupa/i386/pc/util/biosdisk.h>.
14683 * util/misc.c: Include <malloc.h>.
14684 (pupa_malloc): Rewritten so errors are correctly reported.
14685 (pupa_realloc): Likewise.
14686 (pupa_memalign): Likewise.
14687 (pupa_mm_init_region): Declare unused variables with
14688 `__attribute__ ((unused))' to silence a gcc warning.
14689 * normal/i386/setjmp.S: Remove tab at the end of the file to
14690 silence a gcc warning.
14691 * loader/i386/pc/linux.c (pupa_rescue_cmd_initrd): Declare unused
14692 variables with `__attribute__ ((unused))' to silence a gcc
14693 warning.
14694 * loader/i386/pc/multiboot.c (pupa_multiboot_unload): Make the
14695 local variable i unsigned to silence a gcc warning.
14696
14697 * kern/term.c: Include <pupa/misc.h>.
14698 (pupa_more_lines): New variable.
14699 (pupa_more): Likewise.
14700 (pupa_putcode): When the pager is active pause at the end of every
14701 screen.
14702 (pupa_set_more): New function.
14703 * include/pupa/term.h (pupa_set_more): New prototype.
14704
14705
14706 2004-03-07 Yoshinori K. Okuji <okuji@enbug.org>
14707
14708 Now this project is GRUB 2 rather than PUPA. The location of
14709 the CVS repository was moved to GRUB's.
14710
14711 * configure.ac: Use bug-grub as the reporting address.
14712 Use GRUB instead of PUPA.
14713 Change the version number to 1.90.
14714
14715 2004-02-24 Yoshinori K. Okuji <okuji@enbug.org>
14716
14717 * genkernsyms.sh: Updated copyright information.
14718 * genmk.rb: Likewise.
14719 * genmodsrc.sh: Likewise.
14720 * gensymlist.sh: Likewise.
14721 * boot/i386/pc/boot.S: Likewise.
14722 * boot/i386/pc/diskboot.S: Likewise.
14723 * disk/i386/pc/biosdisk.c: Likewise.
14724 * disk/i386/pc/partition.c: Likewise.
14725 * font/manager.c: Likewise.
14726 * fs/ext2.c: Likewise.
14727 * fs/fat.c: Likewise.
14728 * include/pupa/boot.h: Likewise.
14729 * include/pupa/device.h: Likewise.
14730 * include/pupa/disk.h: Likewise.
14731 * include/pupa/dl.h: Likewise.
14732 * include/pupa/elf.h: Likewise.
14733 * include/pupa/err.h: Likewise.
14734 * include/pupa/file.h: Likewise.
14735 * include/pupa/font.h: Likewise.
14736 * include/pupa/fs.h: Likewise.
14737 * include/pupa/kernel.h: Likewise.
14738 * include/pupa/loader.h: Likewise.
14739 * include/pupa/misc.h: Likewise.
14740 * include/pupa/mm.h: Likewise.
14741 * include/pupa/net.h: Likewise.
14742 * include/pupa/normal.h: Likewise.
14743 * include/pupa/rescue.h: Likewise.
14744 * include/pupa/setjmp.h: Likewise.
14745 * include/pupa/symbol.h: Likewise.
14746 * include/pupa/term.h: Likewise.
14747 * include/pupa/types.h: Likewise.
14748 * include/pupa/i386/setjmp.h: Likewise.
14749 * include/pupa/i386/types.h: Likewise.
14750 * include/pupa/i386/pc/biosdisk.h: Likewise.
14751 * include/pupa/i386/pc/boot.h: Likewise.
14752 * include/pupa/i386/pc/console.h: Likewise.
14753 * include/pupa/i386/pc/init.h: Likewise.
14754 * include/pupa/i386/pc/kernel.h: Likewise.
14755 * include/pupa/i386/pc/linux.h: Likewise.
14756 * include/pupa/i386/pc/loader.h: Likewise.
14757 * include/pupa/i386/pc/memory.h: Likewise.
14758 * include/pupa/i386/pc/multiboot.h: Likewise.
14759 * include/pupa/i386/pc/partition.h: Likewise.
14760 * include/pupa/i386/pc/time.h: Likewise.
14761 * include/pupa/i386/pc/vga.h: Likewise.
14762 * include/pupa/i386/pc/util/biosdisk.h: Likewise.
14763 * include/pupa/util/getroot.h: Likewise.
14764 * include/pupa/util/misc.h: Likewise.
14765 * include/pupa/util/resolve.h: Likewise.
14766 * kern/device.c: Likewise.
14767 * kern/disk.c: Likewise.
14768 * kern/dl.c: Likewise.
14769 * kern/err.c: Likewise.
14770 * kern/file.c: Likewise.
14771 * kern/fs.c: Likewise.
14772 * kern/loader.c: Likewise.
14773 * kern/main.c: Likewise.
14774 * kern/misc.c: Likewise.
14775 * kern/mm.c: Likewise.
14776 * kern/rescue.c: Likewise.
14777 * kern/term.c: Likewise.
14778 * kern/i386/dl.c: Likewise.
14779 * kern/i386/pc/init.c: Likewise.
14780 * kern/i386/pc/lzo1x.S: Likewise.
14781 * kern/i386/pc/startup.S: Likewise.
14782 * loader/i386/pc/chainloader.c: Likewise.
14783 * loader/i386/pc/linux.c: Likewise.
14784 * loader/i386/pc/multiboot.c: Likewise.
14785 * normal/cmdline.c: Likewise.
14786 * normal/command.c: Likewise.
14787 * normal/main.c: Likewise.
14788 * normal/menu.c: Likewise.
14789 * normal/i386/setjmp.S: Likewise.
14790 * term/i386/pc/console.c: Likewise.
14791 * term/i386/pc/vga.c: Likewise.
14792 * util/console.c: Likewise.
14793 * util/genmoddep.c: Likewise.
14794 * util/misc.c: Likewise.
14795 * util/pupa-emu.c: Likewise.
14796 * util/resolve.c: Likewise.
14797 * util/unifont2pff.rb: Likewise.
14798 * util/i386/pc/biosdisk.c: Likewise.
14799 * util/i386/pc/getroot.c: Likewise.
14800 * util/i386/pc/pupa-mkimage.c: Likewise.
14801 * util/i386/pc/pupa-setup.c: Likewise.
14802
14803 2004-02-15 Jeroen Dekkers <jeroen@dekkers.cx>
14804
14805 * fs/ext2.c (pupa_ext2_read_file): Correct the value of BLOCKEND
14806 when it is EXT2_BLOCK_SIZE (data). New argument READ_HOOK, all
14807 callers changed. Set DATA->DISK->READ_HOOK to READ_HOOK before
14808 reading and reset it after reading.
14809 (pupa_ext2_close): Return PUPA_ERR_NONE.
14810
14811 * include/pupa/i386/pc/linux.h (PUPA_LINUX_INITRD_MAX_ADDRESS):
14812 Correct value.
14813 (struct linux_kernel_header): Add kernel_version and
14814 initrd_addr_max.
14815 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Check whether
14816 pupa_file_read succeeds.
14817 (pupa_rescue_cmd_initrd): Implement.
14818
14819 2003-12-03 Marco Gerards <metgerards@student.han.nl>
14820
14821 * fs/ext2.c (pupa_ext2_label): New function.
14822 (pupa_ext2_fs): Added label.
14823 * fs/fat.c (pupa_fat_label): New function.
14824 (pupa_fat_fs): Added label.
14825 * include/pupa/fs.h (struct pupa_fs): Added prototype label.
14826
14827 * kern/misc.c (pupa_strndup): New function.
14828 * include/pupa/misc.h (pupa_strndup): New prototype.
14829
14830 * include/pupa/normal.h: Include <pupa/err.h>.
14831 (pupa_set_history): New prototype.
14832 (pupa_iterate_commands): New prototype.
14833 * normal/cmdline.c: Include <pupa/machine/partition.h>,
14834 <pupa/disk.h>, <pupa/file.h>.
14835 (hist_size): New variable.
14836 (hist_lines): Likewise.
14837 (hist_end): Likewise.
14838 (hist_used): Likewise.
14839 (pupa_set_history): New function.
14840 (pupa_history_get): Likewise.
14841 (pupa_history_add): Likewise.
14842 (pupa_history_replace): Likewise.
14843 (pupa_tab_complete): Likewise.
14844 (pupa_cmdline_run): Added tab completion and history buffer. Tab
14845 completion shows partitionnames while completing partitions, this
14846 feature was suggested by Jeff Bailey.
14847 * normal/command.c (pupa_iterate_commands): New function.
14848 * normal/main.c (PUPA_DEFAULT_HISTORY_SIZE): New macro.
14849 (pupa_normal_init): Initialize history buffer.
14850 (PUPA_MOD_INIT): Likewise.
14851 (pupa_normal_fini): Free the history buffer.
14852 (PUPA_MOD_FINI): Likewise.
14853
14854 * util/console.c (pupa_ncurses_getkey): Accept 127 as backspace
14855 key.
14856
14857 * aclocal.m4 (pupa_I386_CHECK_REGPARM_BUG): New DEFUN.
14858 * configure.ac [i386]: Check for regparam bug.
14859 (NESTED_FUNC_ATTR) [! i386]: Defined.
14860
14861 2003-11-17 Marco Gerards <metgerards@student.han.nl>
14862
14863 * conf/i386-pc.rmk (sbin_UTILITIES): Added pupa-emu.
14864 (pupa_setup_SOURCES): Added util/i386/pc/getroot.c.
14865 (pupa_emu_SOURCES): New variable.
14866 (pupa_emu_LDFLAGS): Likewise.
14867 * include/pupa/fs.h (pupa_ext2_init) [PUPA_UTIL]: New prototype.
14868 (pupa_ext2_fini) [PUPA_UTIL]: Likewise.
14869 * include/pupa/normal.h (pupa_normal_init) [PUPA_UTIL]: Likewise.
14870 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
14871 * include/pupa/setjmp.h [PUPA_UTIL]: Include <setjmp.h>.
14872 (pupa_jmp_buf): New typedef.
14873 (pupa_setjmp) [PUPA_UTIL]: New macro.
14874 (pupa_longjmp) [PUPA_UTIL]: Likewise.
14875 * include/pupa/term.h (struct pupa_term): New member `refresh'.
14876 (pupa_refresh): New prototype.
14877 * include/pupa/util/getroot.h: New file.
14878 * kern/misc.c (pupa_vsprintf): Refresh the screen after updating
14879 it.
14880 * kern/rescue.c (pupa_rescue_get_command_line): Likewise.
14881 (pupa_rescue_cmd_cat): Likewise.
14882 (pupa_rescue_cmd_ls): Likewise.
14883 (pupa_rescue_cmd_testload): Likewise.
14884 (pupa_rescue_cmd_lsmod): Likewise.
14885 * normal/cmdline.c (pupa_cmdline_get): Likewise.
14886 * normal/menu.c (run_menu): Likewise.
14887 * kern/term.c (pupa_cls): Likewise.
14888 (pupa_refresh): New function.
14889 * normal/normal.c (pupa_normal_init) [PUPA_UTIL]: New function.
14890 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
14891 * util/console.c: New file.
14892
14893 * util/i386/pc/getroot.c: New file.
14894 * util/i386/pc/pupa-setup.c: Include <pupa/util/getroot.h>.
14895 (pupa_putchar): New function.
14896 (pupa_refresh): Likewise.
14897 (xgetcwd): Function moved to ...
14898 (strip_extra_slashes): Likewise.
14899 (get_prefix): Likewise.
14900 * util/i386/pc/getroot.c: ... here.
14901 (find_root_device): Function moved and renamed to...
14902 * util/i386/pc/getroot.c (pupa_find_root_device): ... here.
14903 Changed all callers.
14904 * util/i386/pc/pupa-setup.c (guess_root_device): Function moved
14905 and renamed to...
14906 * util/i386/pc/getroot.c (pupa_guess_root_device): ... here.
14907 Changed all callers.
14908 * util/misc.c (pupa_memalign): New function.
14909 (pupa_mm_init_region): Likewise.
14910 (pupa_register_exported_symbols): Likewise.
14911 (pupa_putchar): Function removed.
14912 * util/pupa-emu.c: New file.
14913
14914 2003-11-16 Jeroen Dekkers <jeroen@dekkers.cx>
14915
14916 * conf/i386-pc.rmk (pkgdata_MODULES): Add _multiboot.mod.
14917 (_multiboot_mod_SOURCES): New variable.
14918 (_multiboot_mod_CFLAGS): Likewise.
14919 * loader/i386/pc/multiboot.c: New file.
14920 * include/pupa/i386/pc/multiboot.h: Likewise.
14921 * kern/i386/pc/startup.S: Include pupa/machine/multiboot.h.
14922 (pupa_multiboot_real_boot): New function.
14923 * include/pupa/i386/pc/loader.h: Include pupa/machine/multiboot.h.
14924 (pupa_multiboot_real_boot): New prototype.
14925 (pupa_rescue_cmd_multiboot): Likewise
14926 (pupa_rescue_cmd_module): Likewise.
14927
14928 * kern/loader.c (pupa_loader_set): Continue when
14929 pupa_loader_unload_func() fails.
14930 (pupa_loader_unset): New function.
14931 * include/pupa/loader.h (pupa_loader_unset): New prototype.
14932
14933 * kern/misc.c (pupa_stpcpy): New function.
14934 * include/pupa/misc.h (pupa_stpcpy): New prototype.
14935
14936 2003-11-12 Marco Gerards <metgerards@student.han.nl>
14937
14938 * disk/i386/pc/biosdisk.c (pupa_biosdisk_open): Correctly check
14939 for available extensions.
14940
14941 * include/pupa/i386/pc/time.h: New file.
14942 * kern/disk.c: Include <pupa/machine/time.h>.
14943 (PUPA_CACHE_TIMEOUT): New macro.
14944 (pupa_last_time): New variable.
14945 (pupa_disk_open): Flush the cache when there was a timeout.
14946 (pupa_disk_close): Reset the timer.
14947 * kern/i386/pc/startup.S (pupa_get_rtc): Renamed from
14948 pupa_currticks.
14949 * util/misc.c: Include <sys/times.h>
14950 (pupa_get_rtc): New function.
14951
14952 2003-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
14953
14954 * fs/ext2.c (struct pupa_ext2_inode): Declare struct datablocks
14955 as blocks.
14956 (pupa_ext2_get_file_block): Use blocks member.
14957
14958 * fs/ext2.c (pupa_ext2_read_file): Only set skipfirst for the
14959 first block. Return -1 instead of pupa_errno on error.
14960
14961 2003-10-27 Marco Gerards <metgerards@student.han.nl>
14962
14963 * README: In the pupa-mkimage example use _chain instead of chain
14964 and ext2 instead of fat.
14965 * TODO: Replace ext2fs with jfs as an example. Add an item for
14966 adding journal playback for ext2fs.
14967 * conf/i386-pc.rmk (pupa_setup_SOURCES): Added fs/ext2.c.
14968 (pkgdata_MODULES): Added ext2.mod.
14969 (ext2_mod_SOURCES): New variable.
14970 (ext2_mod_CFLAGS): Likewise.
14971 * include/pupa/err.h (pupa_err_t): Added PUPA_ERR_SYMLINK_LOOP.
14972 * include/pupa/misc.h (pupa_strncpy): New prototype.
14973 (pupa_strcat): Likewise.
14974 (pupa_strncmp): Likewise.
14975 * kern/misc.c (pupa_strcat): Enable function.
14976 (pupa_strncpy): New function.
14977 (pupa_strncmp): Likewise.
14978 * fs/ext2.c: New file.
14979
14980 * kern/disk.c (pupa_disk_read): Set pupa_errno to PUPA_ERR_NONE
14981 when the read failed before retrying.
14982 * util/i386/pc/biosdisk.c (_LARGEFILE_SOURCE): Removed.
14983 (_FILE_OFFSET_BITS): Likewise.
14984 * configure.ac: Added AC_SYS_LARGEFILE.
14985
14986 2003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
14987
14988 * genmk.rb (PModule#rule): Make sure to get only symbol names
14989 from the output of nm.
14990 Reported by Robert Millan <zeratul2@wanadoo.es>.
14991
14992 2003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
14993
14994 I forgot to check in these changes for a long time. This adds
14995 incomplete support for VGA console, and this is still very
14996 buggy. Also, a lot of consideration is required for I18N,
14997 UNICODE, and VGA font issues. Therefore, assume that this is
14998 such that "better than nothing".
14999
15000 * font/manager.c: New file.
15001 * include/pupa/font.h: Likewise.
15002 * include/pupa/i386/pc/vga.h: Likewise.
15003 * term/i386/pc/vga.c: Likewise.
15004 * util/unifont2pff.rb: Likewise.
15005
15006 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vga.h.
15007 (pkgdata_MODULES): Added vga.mod and font.mod.
15008 (vga_mod_SOURCES): New variables.
15009 (vga_mod_CFLAGS): Likewise.
15010 (font_mod_SOURCES): Likewise.
15011 (font_mod_CFLAGS): Likewise.
15012
15013 * include/pupa/err.h (PUPA_ERR_BAD_FONT): New constant.
15014
15015 * include/pupa/term.h: Include pupa/err.h.
15016 (struct pupa_term): Added init and fini.
15017 Changed the argument of putchar to pupa_uint32_t.
15018
15019 * include/pupa/i386/pc/console.h: Include pupa/symbol.h.
15020 (pupa_console_real_putchar): New prototype.
15021 (pupa_console_putchar): Removed.
15022 (pupa_console_checkkey): Exported.
15023 (pupa_console_getkey): Likewise.
15024
15025 * kern/misc.c (pupa_vsprintf): Add support for UNICODE
15026 characters.
15027
15028 * kern/term.c (pupa_term_set_current): Rewritten.
15029 (pupa_putchar): Likewise.
15030 (pupa_putcode): New function.
15031
15032 * kern/i386/pc/startup.S (pupa_console_putchar): Renamed to ...
15033 (pupa_console_real_putchar): ... this.
15034 (pupa_vga_set_mode): New function.
15035 (pupa_vga_get_font): Likewise.
15036
15037 * normal/command.c: Include pupa/term.h.
15038 (terminal_command): New function.
15039 (pupa_command_init): Register the command "terminal".
15040
15041 * normal/menu.c (DISP_LEFT): Changed to a UNICODE value.
15042 (DISP_UP): Likewise.
15043 (DISP_RIGHT): Likewise.
15044 (DISP_DOWN): Likewise.
15045 (DISP_HLINE): Likewise.
15046 (DISP_VLINE): Likewise.
15047 (DISP_UL): Likewise.
15048 (DISP_UR): Likewise.
15049 (DISP_LL): Likewise.
15050 (DISP_LR): Likewise.
15051
15052 * term/i386/pc/console.c (pupa_console_putchar): New function.
15053
15054 2003-02-08 NIIBE Yutaka <gniibe@m17n.org>
15055
15056 * util/resolve.c (pupa_util_resolve_dependencies): BUG
15057 FIX. Reverse the path_list.
15058
15059 * include/pupa/normal.h: Export pupa_register_command and
15060 pupa_unregister_command.
15061
15062 * hello/hello.c (pupa_cmd_hello): New module.
15063 * conf/i386-pc.rmk: Added hello.mod.
15064
15065 2003-01-31 Yoshinori K. Okuji <okuji@enbug.org>
15066
15067 * kern/i386/pc/lzo1x.S: New file.
15068
15069 * util/i386/pc/pupa-mkimage.c: Include lzo1x.h.
15070 (compress_kernel): New variable.
15071 (generate_image): Heavily modified to support compressing a
15072 large part of the core image.
15073
15074 * util/misc.c (pupa_util_read_image): Fix a file descriptor
15075 leak.
15076 (pupa_util_load_image): New function.
15077
15078 * kern/i386/pc/startup.S: Include pupa/machine/kernel.h.
15079 (pupa_compressed_size): New variable.
15080 (codestart): Enable Gate A20 here.
15081 Decompress the compressed part of the core image.
15082 Rearrange the code to put functions and variables which are
15083 required for initialization in the non-compressed part.
15084 Include lzo1x.S.
15085
15086 * kern/i386/pc/init.c (pupa_machine_init): Don't enable Gate A20
15087 here.
15088
15089 * include/pupa/util/misc.h (pupa_util_write_image): Declared.
15090
15091 * include/pupa/i386/pc/kernel.h
15092 (PUPA_KERNEL_MACHINE_COMPRESSED_SIZE): New macro.
15093 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): Increased by 4.
15094 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
15095 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
15096 (PUPA_KERNEL_MACHINE_RAW_SIZE): New macro.
15097
15098 * conf/i386-pc.rmk (pupa_mkimage_LDFLAGS): New variable.
15099
15100 * genmk.rb (Image#rule): Put LDFLAGS at the end of a line.
15101 (Utility#rule): Likewise.
15102
15103 * configure.ac: Check if LZO is available.
15104
15105 2003-01-20 Yoshinori K. Okuji <okuji@enbug.org>
15106
15107 * include/pupa/normal.h: New file.
15108 * include/pupa/setjmp.h: Likewise.
15109 * include/pupa/i386/setjmp.h: Likewise.
15110 * normal/cmdline.c: Likewise.
15111 * normal/command.c: Likewise.
15112 * normal/main.c: Likewise.
15113 * normal/menu.c: Likewise.
15114 * normal/i386/setjmp.S: Likewise.
15115
15116 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Made global.
15117 (pupa_rescue_cmd_initrd): Likewise.
15118
15119 * loader/i386/pc/chainloader.c (pupa_rescue_cmd_chainloader):
15120 Likewise.
15121
15122 * kern/i386/pc/startup.S (translation_table): New variable.
15123 (translate_keycode): New function.
15124 (pupa_console_getkey): Call translate_keycode.
15125
15126 * kern/rescue.c (attempt_normal_mode): New function.
15127 (pupa_enter_rescue_mode): Attempt to execute the normal mode. If
15128 it failed, print a message.
15129
15130 * kern/mm.c (pupa_real_malloc): Print more information when a
15131 free magic is broken.
15132 (pupa_free): If the first free header is not free actually, set
15133 it to P.
15134
15135 * kern/main.c (pupa_load_normal_mode): Just load the module
15136 "normal".
15137 (pupa_main): Don't print the message
15138 "Entering into rescue mode..." here.
15139
15140 * include/pupa/i386/pc/loader.h (pupa_rescue_cmd_initrd):
15141 Declared.
15142 (pupa_rescue_cmd_initrd): Likewise.
15143 (pupa_rescue_cmd_initrd): Likewise.
15144
15145 * include/pupa/symbol.h (FUNCTION): Specify the type.
15146 (VARIABLE): Likewise.
15147
15148 * include/pupa/err.h (pupa_err_t): Added
15149 PUPA_ERR_UNKNOWN_COMMAND.
15150
15151 * include/pupa/dl.h (pupa_dl_set_prefix): Exported.
15152 (pupa_dl_get_prefix): Likewise.
15153
15154 * conf/i386-pc.rmk (pkgdata_MODULES): Added normal.mod.
15155 Added _chain.mod and _linux.mod instead of chain.mod and
15156 linux.mod.
15157 (chain_mod_SOURCES): Renamed to ...
15158 (_chain_mod_SOURCES): ... this.
15159 (chain_mod_CFLAGS): Renamed to ...
15160 (_chain_mod_CFLAGS): ... this.
15161 (linux_mod_SOURCES): Renamed to ...
15162 (_linux_mod_SOURCES): ... this.
15163 (linux_mod_CFLAGS): Renamed to ...
15164 (_linux_mod_CFLAGS): ... this.
15165 (normal_mod_SOURCES): New variable.
15166 (normal_mod_CFLAGS): Likewise.
15167 (normal_mod_ASFLAGS): Likewise.
15168
15169 2003-01-18 Yoshinori K. Okuji <okuji@enbug.org>
15170
15171 * kern/rescue.c (pupa_rescue_cmd_rmmod): Call pupa_dl_unload, if
15172 possible.
15173
15174 * kern/dl.c (pupa_dl_ref): Refer depending modules
15175 recursively.
15176 (pupa_dl_unref): Unrefer depending modules recursively.
15177 Don't call pupa_dl_unload implicitly, because PUPA can crash if
15178 a module is unloaded before one depending on that module is
15179 unloaded.
15180 (pupa_dl_unload): Unload depending modules explicitly,
15181 if possible.
15182
15183 2003-01-17 Yoshinori K. Okuji <okuji@enbug.org>
15184
15185 * include/pupa/i386/pc/linux.h: New file.
15186 * loader/i386/pc/linux.c: Likewise.
15187
15188 * loader/i386/pc/chainloader.c (pupa_chainloader_boot_sector):
15189 Removed.
15190 (pupa_chainloader_unload): Return PUPA_ERR_NONE.
15191 (pupa_rescue_cmd_chainloader): Read the image to 0x7C00 instead
15192 of PUPA_CHAINLOADER_BOOT_SECTOR.
15193
15194 * kern/i386/pc/startup.S: Include pupa/machine/linux.h.
15195 (pupa_linux_prot_size): New variable.
15196 (pupa_linux_tmp_addr): Likewise.
15197 (pupa_linux_real_addr): Likewise.
15198 (pupa_linux_boot_zimage): New function.
15199 (pupa_linux_boot_bzimage): Likewise.
15200
15201 * kern/i386/pc/init.c (struct mem_region): New structure.
15202 (MAX_REGIONS): New macro.
15203 (mem_regions): New variable.
15204 (num_regions): Likewise.
15205 (pupa_os_area_addr): Likewise.
15206 (pupa_os_area_size): Likewise.
15207 (pupa_lower_mem): Likewise.
15208 (pupa_upper_mem): Likewise.
15209 (add_mem_region): New function.
15210 (compact_mem_regions): Likewise.
15211 (pupa_machine_init): Set PUPA_LOWER_MEM and PUPA_UPPER_MEM to
15212 the size of the conventional memory and that of so-called upper
15213 memory (before the first memory hole).
15214 Instead of adding each found region to free memory, use
15215 add_mem_region and add them after removing overlaps.
15216 Also, add only 1/4 of the upper memory to free memory. The rest
15217 is used for loading OS images. Maybe this is ad hoc, but this
15218 makes it much easier to relocate OS images when booting.
15219
15220 * kern/rescue.c (pupa_rescue_cmd_module): Removed.
15221 (pupa_enter_rescue_mode): Don't register initrd and module.
15222
15223 * kern/mm.c: Include pupa/dl.h.
15224
15225 * kern/main.c: Include pupa/file.h and pupa/device.h.
15226
15227 * kern/loader.c (pupa_loader_load_module_func): Removed.
15228 (pupa_loader_load_module): Likewise.
15229
15230 * kern/dl.c (pupa_dl_load): Use the suffix ``.mod'' instead of
15231 ``.o''.
15232
15233 * include/pupa/i386/pc/loader.h (pupa_linux_prot_size): Declared.
15234 (pupa_linux_tmp_addr): Likewise.
15235 (pupa_linux_real_addr): Likewise.
15236 (pupa_linux_boot_zimage): Likewise.
15237 (pupa_linux_boot_bzimage): Likewise.
15238
15239 * include/pupa/i386/pc/init.h (pupa_lower_mem): Declared.
15240 (pupa_upper_mem): Likewise.
15241 (pupa_gate_a20): Don't export, because turning off Gate A20 in a
15242 module is too dangerous.
15243
15244 * include/pupa/loader.h (pupa_os_area_addr): Declared.
15245 (pupa_os_area_size): Likewise.
15246 (pupa_loader_set): Remove the first argument. Loader doesn't
15247 manage modules or initrd any longer.
15248 (pupa_loader_load_module): Removed.
15249
15250 * conf/i386-pc.rmk (pkgdata_MODULES): Added linux.mod.
15251 (linux_mod_SOURCES): New variable.
15252 (linux_mod_CFLAGS): Likewise.
15253
15254 2003-01-07 Yoshinori K. Okuji <okuji@enbug.org>
15255
15256 * util/i386/pc/pupa-setup.c (setup): Convert the endianness of
15257 the length of a blocklist correctly.
15258
15259 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open) [__linux__]:
15260 Use ioctl only if the OS file is a block device.
15261 (pupa_util_biosdisk_open): Don't use ST.ST_BLOCKS, because it is
15262 not very useful for normal files.
15263
15264 * kern/main.c (pupa_set_root_dev): New function.
15265 (pupa_load_normal_mode): Likewise.
15266 (pupa_main): Call those above.
15267
15268 * include/pupa/types.h (pupa_swap_bytes16): Cast the result to
15269 pupa_uint16_t.
15270
15271 * include/pupa/kernel.h (pupa_enter_normal_mode): Removed.
15272
15273 2003-01-06 Yoshinori K. Okuji <okuji@enbug.org>
15274
15275 * util/i386/pc/pupa-setup.c: Include pupa/machine/kernel.h.
15276 (setup): Configure the installed partition information and the
15277 dl prefix.
15278
15279 * loader/i386/pc/chainloader.c (my_mod): New variable.
15280 (pupa_chainloader_unload): New function.
15281 (pupa_rescue_cmd_chainloader): Refer itself.
15282 (PUPA_MOD_INIT): Save its own module in MY_MOD.
15283
15284 * kern/i386/pc/startup.S (install_partition): Removed.
15285 (version_string): Likewise.
15286 (config_file): Likewise.
15287 (pupa_install_dos_part): New variable.
15288 (pupa_install_bsd_part): Likewise.
15289 (pupa_prefix): Likewise.
15290 (pupa_chainloader_real_boot): Call pupa_dl_unload_all.
15291
15292 * kern/i386/pc/init.c: Include pupa/machine/kernel.h, pupa/dl.h
15293 and pupa/misc.h.
15294 (make_install_device): New function.
15295 (pupa_machine_init): Set the dl prefix.
15296
15297 * kern/rescue.c: Include pupa/rescue.h and pupa/dl.h.
15298 (buf): Renamed to ...
15299 (linebuf): ... this.
15300 (pupa_rescue_cmd_prefix): New function.
15301 (pupa_rescue_cmd_insmod): Likewise.
15302 (pupa_rescue_cmd_rmmod): Likewise.
15303 (pupa_rescue_cmd_lsmod): Likewise.
15304 (pupa_enter_rescue_mode): Register new commands: prefix, insmod,
15305 rmmod and lsmod.
15306
15307 * kern/mm.c (pupa_memalign): If failed even after invalidating
15308 disk caches, unload unneeded modules and retry.
15309
15310 * kern/misc.c (pupa_memmove): New function.
15311 (pupa_memcpy): Removed.
15312 (pupa_strcpy): New function.
15313 (pupa_itoa): Made static.
15314
15315 * kern/dl.c (pupa_dl_iterate): New function.
15316 (pupa_dl_ref): Likewise.
15317 (pupa_dl_unref): Likewise.
15318 (pupa_dl_unload): Return if succeeded or not.
15319 (pupa_dl_unload_unneeded): New function.
15320 (pupa_dl_unload_all): Likewise.
15321 (pupa_dl_init): Renamed to ...
15322 (pupa_dl_set_prefix): ... this.
15323 (pupa_dl_get_prefix): New function.
15324
15325 * include/pupa/i386/pc/kernel.h: Include pupa/types.h.
15326 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): New macro.
15327 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
15328 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
15329 (pupa_install_dos_part): Declared.
15330 (pupa_install_bsd_part): Likewise.
15331 (pupa_prefix): Likewise.
15332 (pupa_boot_drive): Likewise.
15333
15334 * include/pupa/types.h: Fix a typo.
15335
15336 * include/pupa/misc.h (pupa_memcpy): New macro. Just an alias to
15337 pupa_memmove.
15338 (pupa_memmove): Declared.
15339 (pupa_strcpy): Likewise.
15340
15341 * include/pupa/dl.h (PUPA_MOD_INIT): Change the prototype. Now
15342 pupa_mod_init takes one argument, its own module.
15343 (pupa_dl_unload_unneeded): Declared.
15344 (pupa_dl_unload_all): Likewise.
15345 (pupa_dl_ref): Likewise.
15346 (pupa_dl_unref): Likewise.
15347 (pupa_dl_iterate): Likewise.
15348 (pupa_dl_init): Renamed to ...
15349 (pupa_dl_set_prefix): ... this.
15350 (pupa_dl_get_prefix): Declared.
15351
15352 * fs/fat.c [!PUPA_UTIL] (my_mod): New variable.
15353 (pupa_fat_dir) [!PUPA_UTIL]: Prevent the fat module from being
15354 unloaded.
15355 (pupa_fat_open) [!PUPA_UTIL]: Refer itself if succeeded.
15356 (pupa_fat_close) [!PUPA_UTIL]: Unrefer itself.
15357
15358 * configure.ac (tmp_CFLAGS): Added -Wshadow, -Wpointer-arith,
15359 -Wmissing-prototypes, -Wundef and -Wstrict-prototypes.
15360
15361 2003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
15362
15363 * util/i386/pc/pupa-setup.c (setup): Define the internal
15364 function find_first_partition_start at the top level, because GCC
15365 3.0.x cannot compile internal functions in deeper scopes
15366 correctly.
15367 (find_root_device): Use lstat instead of stat.
15368 Don't follow symbolic links.
15369 Fix the path-constructing code.
15370
15371 * util/i386/pc/biosdisk.c [__linux__] (BLKFLSBUF): New macro.
15372 (pupa_util_biosdisk_open) [__linux__]: Get the size of a device
15373 by a BLKGETSIZE ioctl first, because block devices don't fill
15374 the member st_mode of the structure stat on Linux.
15375 [__linux__] (linux_find_partition): Use a temporary buffer
15376 REAL_DEV for the working space. Copy it to DEV before returning.
15377 (open_device) [__linux__]: Call ioctl with BLKFLSBUF to make the
15378 buffer cache consistent.
15379 (get_os_disk) [__linux__]: Use the length 5 instead of 4 for
15380 strncmp. The previous value was merely wrong.
15381 (pupa_util_biosdisk_get_pupa_dev): Use stat instead of lstat.
15382
15383 * fs/fat.c (pupa_fat_read_data): Shift 4 instead of 12 when the
15384 FAT size is 12. The previous value was merely wrong.
15385
15386 * kern/main.c (pupa_main): Don't split the starting message from
15387 newlines.
15388
15389 * kern/term.c (pupa_putchar): Put CR after LF instead of before
15390 LF, because BIOS goes crazy about character attributes in this
15391 case.
15392
15393 2003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
15394
15395 * include/i386/pc/util/biosdisk.h: New file.
15396 * util/i386/pc/biosdisk.c: Likewise.
15397 * util/i386/pc/pupa-setup.c: Likewise.
15398
15399 * Makefile.in (INCLUDE_DISTFILES): Added
15400 include/pupa/i386/pc/util/biosdisk.h.
15401 (UTIL_DISTFILES): Added biosdisk.c and pupa-setup.c under the
15402 directory util/i386/pc.
15403 (install-local): Added a rule for sbin_UTILITIES.
15404 (uninstall): Likewise.
15405
15406 * util/i386/pc/pupa-mkimage.c (usage): Fix a typo in the doc.
15407
15408 * util/misc.c (xrealloc): New function.
15409 (pupa_malloc): Likewise.
15410 (pupa_free): Likewise.
15411 (pupa_realloc): Likewise.
15412 (pupa_stop): Likewise.
15413 (pupa_putchar): Likewise.
15414
15415 * kern/disk.c (pupa_disk_read): Prevent L from underflowing.
15416
15417 * include/pupa/util/misc.h (xrealloc): Declared.
15418
15419 * include/pupa/i386/pc/boot.h (PUPA_BOOT_MACHINE_BPB_START): New
15420 macro.
15421 (PUPA_BOOT_MACHINE_BPBEND): Renamed to ...
15422 (PUPA_BOOT_MACHINE_BPB_END): ... this.
15423
15424 * include/pupa/fs.h [PUPA_UTIL] (pupa_fat_init): Declared.
15425 [PUPA_UTIL] (pupa_fat_fini): Likewise.
15426
15427 * fs/fat.c [PUPA_UTIL] (pupa_fat_init): Defined. Maybe a better
15428 way should be implemented.
15429 [PUPA_UTIL] (pupa_fat_fini): Likewise.
15430
15431 * disk/i386/pc/biosdisk.c (pupa_biosdisk_call_hook): Increase
15432 the size of NAME for safety.
15433 (pupa_biosdisk_iterate): Search hard disks to 0x90 instead of
15434 0x88.
15435
15436 * conf/i386-pc.rmk (sbin_UTILITIES): New variable.
15437 (pupa_setup_SOURCES): Likewise.
15438
15439 * genmk.rb (Utility#rule): Add $(BUILD_CFLAGS) into the rules.
15440
15441 2002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
15442
15443 * kern/i386/pc/startup.S (push_get_mmap_entry): Revert to a
15444 bunch of pushl's from pusha, because this destroys the return
15445 value.
15446
15447 2002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
15448
15449 Use -mrtd and -mregparm=3 to reduce the generated code sizes.
15450 This means that any missing prototypes could be fatal. Also, you
15451 must take care when writing assembly code. See the comments at
15452 the beginning of startup.S, for more details.
15453
15454 * kern/i386/pc/startup.S (pupa_halt): Modified for the new
15455 compilation mechanism.
15456 (pupa_chainloader_real_boot): Likewise.
15457 (pupa_biosdisk_rw_int13_extensions): Likewise.
15458 (pupa_biosdisk_rw_standard): Likewise.
15459 (pupa_biosdisk_check_int13_extensions): Likewise.
15460 (pupa_biosdisk_get_diskinfo_int13_extensions): Likewise.
15461 (pupa_biosdisk_get_diskinfo_standard): Likewise.
15462 (pupa_get_memsize): Likewise.
15463 (pupa_get_mmap_entry): Likewise.
15464 (pupa_console_putchar): Likewise.
15465 (pupa_console_setcursor): Likewise.
15466 (pupa_getrtsecs): Use pushl instead of push.
15467
15468 * kern/i386/pc/init.c (pupa_machine_init): Use the scratch
15469 memory instead of the stack for a mmap entry, because some
15470 BIOSes may ignore the maximum size and overflow.
15471
15472 * conf/i386-pc.rmk (COMMON_CFLAGS): Added -mrtd and -mregparm=3.
15473
15474 * genmk.rb (PModule#rule): Compile automatically generated
15475 sources with module-specific CFLAGS as well as other sources.
15476
15477 2002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
15478
15479 * configure.ac: Check ld.
15480 Replace CFLAGS and CPPFLAGS with BUILD_CFLAGS and BUILD_CPPFLAGS
15481 respectively, before checking endianness and sizes.
15482
15483 * Makefile.in (LD): New variable.
15484
15485 2002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
15486
15487 * Makefile.in (BUILD_CC): CC -> BUILD_CC.
15488
15489 2002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
15490
15491 * Changelog: New file.
15492