]> git.proxmox.com Git - grub2.git/blame - ChangeLog
cleaned ATI fixes
[grub2.git] / ChangeLog
CommitLineData
0297aafb
FZ
12009-12-17 Felix Zielcke <fzielcke@z-51.de>
2
3 * gendistlist.sh: Use POSIX compliant `!' instead of `-not' in
4 the `find' command.
5
c179ebe4
VS
62009-12-16 Vladimir Serbinenko <phcoder@gmail.com>
7
8 UUID support for HFS.
9
10 * fs/hfs.c (grub_hfs_uuid): New function.
11 (grub_hfs_fs): New value .uuid.
12 * include/grub/hfs.h (grub_hfs_sblock): New field 'num_serial'.
13
574cce0c
FZ
142009-12-14 Felix Zielcke <fzielcke@z-51.de>
15
16 Fix a segfault with parsing unknown long options.
17
18 * util/grub-mkrelpath.c (options): Zero terminate it.
19
c4a3e41a
CPE
202009-12-13 Carles Pina i Estany <carles@pina.cat>
21
22 * include/grub/misc.h (grub_puts): New declaration.
23 (grub_puts_): Likewise.
24 * kern/mis.c (grub_puts): New definition.
25 (grub_puts_): Likewise.
26
2e8a7602
RM
272009-12-13 Robert Millan <rmh.grub@aybabtu.com>
28
29 * util/grub-probe.c (probe): Improve error message.
30
b50b77b9
RM
312009-12-13 Robert Millan <rmh.grub@aybabtu.com>
32
33 * loader/i386/multiboot_elfxx.c
34 (CONCAT(grub_multiboot_load_elf, XX)): Fix `grub_multiboot_payload_eip'
35 initialization.
36
372009-12-13 Vladimir Serbinenko <phcoder@gmail.com>
38
39 Relocator framework
40
41 * loader/i386/xnu_helper.S: Removed. All users updated.
42 * conf/i386.rmk (pkglib_MODULES): Add relocator.mod.
43 (relocator_mod_SOURCES): New variable.
44 (relocator_mod_CFLAGS): Likewise.
45 (relocator_mod_LDFLAGS): Likewise.
46 (relocator_mod_ASFLAGS): Likewise.
47 * conf/x86_64.rmk: Likewise.
48 * include/grub/i386/multiboot.h (grub_multiboot_payload_orig): Removed.
49 (grub_multiboot_payload_entry_offset): Likewise.
50 (grub_multiboot_forward_relocator): Likewise.
51 (grub_multiboot_forward_relocator_end): Likewise.
52 (grub_multiboot_backward_relocator): Likewise.
53 (grub_multiboot_backward_relocator_end): Likewise.
54 (grub_multiboot_payload_eip): New variable.
55 (grub_multiboot_payload_orig): Likewise.
56 * include/grub/i386/pc/memory.h: Include grub/i386/memory.h.
57 (GRUB_MEMORY_MACHINE_CR0_PE_ON): Move from here ...
58 * include/grub/i386/memory.h
59 (GRUB_MEMORY_CPU_CR0_PE_ON): ... to here
60 (GRUB_MEMORY_CPU_CR4_PAE_ON): New definition.
61 (GRUB_MEMORY_CPU_CR0_PAGING_ON): Likewise.
62 (GRUB_MEMORY_CPU_AMD64_MSR): Likewise.
63 (GRUB_MEMORY_CPU_AMD64_MSR_ON): Likewise.
64 * include/grub/i386/relocator.h: New file.
65 * include/grub/x86_64/relocator.h: Likewise.
66 * include/grub/i386/xnu.h: Include grub/cpu/relocator.h.
67 (XNU_RELOCATOR): New macro.
68 (grub_xnu_launcher_start): Remove.
69 (grub_xnu_launcher_end): Likewise.
70 * include/grub/xnu.h (grub_xnu_boot_resume): New prototype.
71 (grub_xnu_heap_real_start): Remove.
72 (grub_xnu_heap_start): Change to void *. All users updated.
73 * kern/i386/realmode.S (real_to_prot): Use GRUB_MEMORY_CPU_CR0_PE_ON.
74 * lib/i386/relocator.c: New file.
75 * lib/i386/relocator_asm.S: Likewise.
76 * lib/i386/relocator_backward.S: Likewise.
77 * lib/mips/relocator.c: Likewise.
78 * lib/mips/relocator_asm.S: Likewise.
79 * lib/relocator.c: Likewise.
80 * loader/i386/multiboot.c: Include grub/i386/relocator.h.
81 (entry): Removed.
82 (playground): Likewise.
83 (grub_multiboot_payload_orig): New variable.
84 (grub_multiboot_payload_dest): Likewise.
85 (grub_multiboot_payload_size): Likewise.
86 (grub_multiboot_payload_eip): Likewise.
87 (grub_multiboot_payload_esp): Likewise.
88 (grub_multiboot_boot): Use grub_relocator32_boot.
89 (grub_multiboot_unload): Free relocators.
90 (grub_multiboot): Setup stack. Use relocators.
91 * loader/i386/multiboot_elfxx.c: Include grub/i386/relocator.h.
92 (grub_multiboot_load_elfXX): Use relocators.
93 * loader/i386/multiboot_helper.S (grub_multiboot_payload_orig): Removed.
94 (grub_multiboot_payload_size): Likewise.
95 (grub_multiboot_payload_dest): Likewise.
96 (grub_multiboot_payload_entry_offset): Likewise.
97 (grub_multiboot_forward_relocator): Likewise.
98 (grub_multiboot_backward_relocator): Likewise.
99 (grub_multiboot_real_boot): Likewise.
100 * loader/i386/xnu.c (grub_xnu_heap_will_be_at): New variable.
101 (grub_xnu_entry_point): Likewise.
102 (grub_xnu_arg1): Likewise.
103 (grub_xnu_stack): Likewise.
104 (grub_xnu_launch): Removed.
105 (grub_xnu_boot_resume): New function.
106 (grub_xnu_boot): Use relocators.
107 * loader/i386/xnu_helper.S: Removed.
108 * loader/xnu.c (grub_xnu_heap_start): New variable.
109 (grub_xnu_heap_size): Likewise.
110 (grub_xnu_heap_malloc): Use relocators.
111 * loader/xnu_resume.c (grub_xnu_resume): Use relocators.
112
29eb90c6
VS
1132009-12-13 Vladimir Serbinenko <phcoder@gmail.com>
114
115 * kern/i386/pc/startup.S (multiboot_entry): Setup stack before calling
116 anything.
117
31027430
CPE
1182009-12-13 Carles Pina i Estany <carles@pina.cat>
119
120 * script/execute.c (grub_script_execute_cmdline): Set grub_errno to
121 GRUB_ERR_NONE before calling grub_env_set.
122
dc0c71d9
RM
1232009-12-12 Robert Millan <rmh@aybabtu.com>
124
125 * gendistlist.sh (EXTRA_DISTFILES): Add `genvideolist.sh'.
126 * genmk.rb (video): New variable.
127 (CLEANFILES, VIDEOFILES): Add #{video}.
128 (#{video}): New target rule.
129 * genvideolist.sh: New file.
130 * Makefile.in (pkglib_DATA): Add video.lst.
131 (video.lst): New target rule.
132 * util/grub-mkconfig.in: Initialize ${GRUB_VIDEO_BACKEND} using
133 `video.lst'.
134 * util/grub.d/30_os-prober.in: Replace `vbe' with
135 ${GRUB_VIDEO_BACKEND}.
136
2a4bfcf0
RM
1372009-12-11 Robert Millan <rmh.grub@aybabtu.com>
138
139 * THANKS: Add David Miller.
140
2a3aa4d5
RM
1412009-12-11 Vladimir Serbinenko <phcoder@gmail.com>
142
143 libpciaccess support.
144
145 * Makefile.in (LIBPCIACCESS): New variable.
146 (enable_grub_emu_pci): Likewise.
147 * conf/any-emu.rmk (grub_emu_SOURCES) [enable_grub_emu_pci]: Add
148 util/pci.c and commands/lspci.c.
149 (grub_emu_LDFLAGS) [enable_grub_emu_pci]: Add $(LIBPCIACCESS).
150 * configure.ac (grub-emu-pci): New option.
151 * include/grub/i386/pci.h (grub_pci_device_map_range): New function.
152 (grub_pci_device_unmap_range): Likewise.
153 * include/grub/pci.h [GRUB_UTIL]: Include grub/pciutils.h.
154 (grub_pci_device) [!GRUB_UTIL]: New structure. All users updated.
155 (grub_pci_address_t) [!GRUB_UTIL]: New type.
156 (grub_pci_device_t) [!GRUB_UTIL]: Likewise.
157 (grub_pci_get_bus) [!GRUB_UTIL]: New function.
158 (grub_pci_get_device) [!GRUB_UTIL]: Likewise.
159 (grub_pci_get_function) [!GRUB_UTIL]: Likewise.
160 * include/grub/pciutils.h: New file.
161 * util/pci.c: Likewise.
162
8d0502d9
FZ
1632009-12-11 Felix Zielcke <fzielcke@z-51.de>
164
165 * util/misc.c: Don't include <errno.h> twice.
166
0d56ed64
FZ
1672009-12-10 Felix Zielcke <fzielcke@z-51.de>
168
169 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): Show the disk
170 name in an error message.
171 (grub_biosdisk_rw): Likewise.
172
2e59983c
VS
1732009-12-10 Vladimir Serbinenko <phcoder@gmail.com>
174
175 Eliminate NTFS 4Gib barrier.
176
177 * fs/ntfs.c (read_attr): Use grub_disk_addr_t and grub_size_t.
178 (read_run_data): Likewise.
179 (grub_ntfs_read_run_list): Likewise.
180 (grub_ntfs_read_block): Likewise.
181 (grub_ntfs_iterate_dir): Likewise.
182 (read_mft): Likewise.
183 (read_data): Likewise.
184 Use COM_LOG_LEN.
185 * fs/ntfscomp.c (read_block): Cast ctx->target_vcn & 0xF to unsigned
186 to avoid 64-bit division
187 * include/grub/ntfs.h (COM_LOG_LEN): New definition.
188 (grub_ntfs_rlst): Use grub_disk_addr_t.
189
71ee178a
VS
1902009-12-10 Vladimir Serbinenko <phcoder@gmail.com>
191
192 Eliminate grub-fstest 4Gib barrier.
193
194 * util/grub-fstest.c (skip, leng): Use grub_disk_addr_t.
195 (read_file): Fix error reporting.
196
2520d4b8
VS
1972009-12-10 Vladimir Serbinenko <phcoder@gmail.com>
198
199 Eliminate hexdump 4Gib barrier.
200
201 * commands/hexdump.c (grub_cmd_hexdump): Use grub_disk_addr_t.
202 * lib/arg.c (grub_arg_parse): Use grub_strtoull.
203
e1f27065
VS
2042009-12-10 Vladimir Serbinenko <phcoder@gmail.com>
205
206 * kern/device.c (grub_device_iterate): Ignore errors during first scan.
207 Fixes amarsh bug.
208
1a0f7f45
RM
2092009-12-09 Bruce Dubbs <bruce.dubbs@gmail.com>
210
211 Remove miscellaneous files in distclean target.
212
213 * Makefile.in: Remove docs/{grub.info,version.texi,stamp-vti}
214
c631d9fb
CW
2152009-12-09 Colin Watson <cjwatson@ubuntu.com>
216
217 * util/grub-mkconfig_lib.in: Don't set grub_probe or grub_mkrelpath
218 if they're already set. This resolves the conflict between my
219 grub-install change on 2009-10-06 and Felix' change on 2009-11-11,
220 fixing the --grub-probe option again.
221 * util/sparc64/ieee1275/grub-install.in: Revert the last piece of my
222 change on 2009-10-06, so that we now once again source
223 `${libdir}/grub/grub-mkconfig_lib' after options have been parsed.
224
7c7b6106
RM
2252009-12-08 Robert Millan <rmh.grub@aybabtu.com>
226
227 * conf/common.rmk [sparc64-ieee1275] (grub_mkdevicemap_SOURCES): Use
228 `util/ieee1275/ofpath.c' and `util/ieee1275/devicemap.c' instead of
229 `util/devicemap.c'.
230
e3069ec1
CPE
2312009-12-08 Carles Pina i Estany <carles@pina.cat>
232
233 * include/grub/misc.h (grub_printf_): New declaration.
234 * kern/misc.c (grub_printf_): New definition.
235 * normal/main.c (grub_normal_reader_init): Use `grub_printf_' and `N_'
236 instead of `grub_printf' and `_'.
237 * normal/menu_entry.c (store_completion): Likewise.
238 (run): Likewise.
239 (grub_menu_entry_run): Likewise.
240 * normal/menu_text.c (grub_wait_after_message): Likewise.
241 (notify_booting): Likewise.
242 (notify_fallback): Likewise.
243 (notify_execution_failure): Likewise.
244
d6ceebf1
CW
2452009-12-07 Colin Watson <cjwatson@ubuntu.com>
246
247 * configure.ac: Check for vasprintf.
248 * util/misc.c (asprintf): Move allocation from here ...
249 (vasprintf): ... to here. New function.
250 (xasprintf): New function.
251 * include/grub/util/misc.h (vasprintf, xasprintf): Add
252 prototypes.
253 * util/getroot.c (grub_util_get_grub_dev): Use xasprintf.
254 * util/grub-mkfont.c (write_font): Likewise.
255 * util/grub-probe.c (probe): Likewise.
256 * util/hostdisk.c (make_device_name): Likewise.
257
de6daa8b
DM
2582009-12-06 David S. Miller <davem@sunset.davemloft.net>
259
260 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Recognize
261 anything even prefixed with 'cdrom' as a cdrom.
262
df91e679
FZ
2632009-12-06 Felix Zielcke <fzielcke@z-51.de>
264
265 * util/misc.c (make_system_path_relative_to_its_root): Correctly cope with
266 mount points.
267
98d3dc02
CPE
2682009-12-05 Carles Pina i Estany <carles@pina.cat>
269
270 * gettext/gettext.c: Include `<grub/list.h>'. Define grub_gettext_msg,
271 grub_gettext_msg_list.
272 (grub_gettext_gettranslation_from_position): Return const char *
273 and not char *.
274 (grub_gettext_translate): Add the translated strings into a list,
275 returns from the list if existing there.
276 (grub_gettext_init_ext): Add \n at the end of grub_dprintf string.
277 (grub_gettext_delete_list): Delete the list.
278 (grub_gettext_env_write_lang): Call grub_gettext_delete_list when
279 lang environment variable is changed.
280 (GRUB_MOD_FINI): Call grub_gettext_delete_list.
281
b283f108
VS
2822009-12-05 Vladimir Serbinenko <phcoder@gmail.com>
283
284 Rename kernel.mod to kernel.img.
285
286 * conf/i386-efi.rmk (pkglib_MODULES): Change kernel.mod to kernel.img.
287 (kernel_mod_EXPORTS): Rename to ...
288 (kernel_img_EXPORTS): ... this.
289 (kernel_mod_SOURCES): Rename to ...
290 (kernel_img_SOURCES): ... this.
291 (kernel_mod_HEADERS): Rename to ...
292 (kernel_img_HEADERS): ... this. All users updated.
293 (kernel_mod_CFLAGS): Rename to ...
294 (kernel_img_CFLAGS): ... this.
295 (kernel_mod_ASFLAGS): Rename to ...
296 (kernel_img_ASFLAGS): ... this.
297 (kernel_mod_LDFLAGS): Rename to ...
298 (kernel_img_LDFLAGS): ... this.
299 * conf/x86_64-efi.rmk: Likewise.
300 * util/i386/efi/grub-mkimage.c (read_kernel_module): Rename to ...
301 (read_kernel_image): ... this. All users updated.
302 (read_kernel_image): Read "kernel.img" instead of "kernel.mod".
303
69055f8a
CPE
3042009-12-05 Carles Pina i Estany <carles@pina.cat>
305
306 * normal/menu_text.c (grub_color_menu_high): Gettexttize string.
307 (print_spaces): New function.
308 (grub_print_ucs4): New function.
309 (getstringwidth): New function.
310 (print_message_indented): New function.
311 (print_message): Gettexttize strings using print_message_indented.
312 (run_menu): Replaces grub_printf by print_spaces and dynamic terminal
313 width.
314 (get_entry_number): Gettextize and uses dynamic terminal width.
315 (notify_booting, notify_fallback, notify_execution_failure):
316 Gettextize.
317 * normal/menu_entry.c (store_completion): Cleanup the gettextized
318 string.
319 (run): Likewise.
320 (grub_menu_entry_run): Likewise.
321 * PO/POTFILES: Add normal/menu_entry.c.
322
f616f51c
VS
3232009-12-05 Vladimir Serbinenko <phcoder@gmail.com>
324
325 * configure.ac (TARGET_ASFLAGS): Add "-D<MACHINE>".
326
57bbe3be
CPE
3272009-12-05 Carles Pina i Estany <carles@pina.cat>
328
329 * util/grub-install.in: Install gettext .mo files.
330 * util/grub-mkrescue.in (process_input_dir): Copy gettext .mo files.
331
013d67a1
CPE
3322009-12-05 Carles Pina i Estany <carles@pina.cat>
333
334 * gettext/gettext.c (grub_gettext_init_ext): Replace grub_printf with
335 grub_dprintf.
336
fb954db0
RM
3372009-12-05 Robert Millan <rmh.grub@aybabtu.com>
338
339 * kern/ieee1275/openfw.c (grub_reboot): Disable for i386. The
340 non-firmware-dependant one in realmode.S takes precedence.
341
6b8474f8
RM
3422009-12-04 Robert Millan <rmh.grub@aybabtu.com>
343
344 * commands/halt.c: Replace misc arch-specific headers with
345 `<grub/misc.h>'.
346 * commands/reboot.c: Likewise.
347 * commands/i386/pc/halt.c: Replace `<grub/machine/init.h>' with
348 `<grub/misc.h>'.
349 * conf/i386-coreboot.rmk (kernel_img_HEADERS): Remove `cpu/reboot.h'.
350 (halt_mod_SOURCES): Move `kern/i386/halt.c' from here ...
351 (kernel_img_SOURCES): ... to here.
352
353 * include/grub/efi/efi.h (grub_reboot, grub_halt): Remove prototypes.
354 * include/grub/i386/pc/init.h: Likewise.
355 * include/grub/powerpc/ieee1275/kernel.h: Likewise.
356 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
357
358 * include/grub/misc.h (grub_reboot, grub_halt): New prototypes.
359
360 * include/grub/i386/halt.h: Remove.
361 * include/grub/i386/reboot.h: Likewise.
362
363 * kern/i386/halt.c: Remove `<grub/cpu/halt.h>'.
364
4b2e6ca2
DM
3652009-12-03 David S. Miller <davem@sunset.davemloft.net>
366
367 * conf/sparc64-ieee1275.rmk (grub_mkimage_SOURCES,
368 grub_setup_SOURCES, grub_ofpathname_SOURCES): Add gnulib/progname.c
369 * util/sparc64/ieee1275/grub-mkimage.c: Include <grub/i18n.h> and
370 "progname.h"
371 * util/sparc64/ieee1275/grub-ofpathname.c: Likewise.
372 * util/sparc64/ieee1275/grub-setup.c: Likewise.
373 (usage): Add missing comma in printf.
374
5239348f
RM
3752009-12-02 Robert Millan <rmh.grub@aybabtu.com>
376
377 Use the same reboot approach on i386 coreboot and qemu as we do on
378 BIOS.
379
380 * conf/i386-coreboot.rmk (kernel_img_HEADERS): Add `cpu/reboot.h'.
381 (reboot_mod_SOURCES): Remove `kern/i386/reboot.c'.
382 * kern/i386/reboot.c: Remove.
383 * include/grub/i386/reboot.h (grub_reboot): Export function.
384 * kern/i386/pc/startup.S (grub_reboot): Move from here ...
385 * kern/i386/realmode.S (grub_reboot): ... to here. Jump to
386 0xf000:0xfff0 instead of 0xffff:0x0000.
387 [!GRUB_MACHINE_PCBIOS] (prot_to_real): Do not restore interrupts.
388 * kern/i386/qemu/startup.S: Include `"../realmode.S"'.
389
ef34cbd4
RM
3902009-11-30 Robert Millan <rmh.grub@aybabtu.com>
391
392 Fix $srcdir != $objdir build.
393
394 * Makefile.in (po/%.po): Rewrite as ...
395 ($(foreach lang, $(LINGUAS), $(srcdir)/po/$(lang).po)): ... this.
396
dc9837ea
ST
3972009-11-29 Samuel Thibault <samuel.thibault@ens-lyon.org>
398
399 Fix GNU/Hurd grub-install crash.
400 * util/grub-probe.c (probe): Try to access `path' only when it is not
401 NULL.
402
2f857f98
VS
4032009-11-28 Vladimir Serbinenko <phcoder@gmail.com>
404
405 Correct module naming.
406
407 * video/efi_uga.c (GRUB_MOD_INIT(efi_fb)): Renamed from this ...
408 (GRUB_MOD_INIT(efi_uga)): ... to this
409 (GRUB_MOD_FINI(efi_fb)): Renamed from this ...
410 (GRUB_MOD_FINI(efi_uga)): ... to this
411 * video/efi_gop.c (GRUB_MOD_INIT(efi_fb)): Renamed from this ...
412 (GRUB_MOD_INIT(efi_gop)): ... to this
413 (GRUB_MOD_FINI(efi_fb)): Renamed from this ...
414 (GRUB_MOD_FINI(efi_gop)): ... to this
415
c5448046
RM
4162009-11-28 Robert Millan <rmh.grub@aybabtu.com>
417
418 * util/mkisofs/mkisofs.c (ld_options): Mark all `arg' strings as
419 translatable.
420 (usage): Translate `arg' strings using gettext().
421 Thanks to Jordi Mallach for the suggestion.
422
c85184ad
VS
4232009-11-28 Vladimir Serbinenko <phcoder@gmail.com>
424
425 GOP support. Based on patch from Bean
426 (http://lists.gnu.org/archive/html/grub-devel/2009-08/msg00384.html)
427
428 * video/efi_gop.c: New file.
429 * include/grub/efi/graphics_output.h: Likewise.
430 * conf/i386-efi.rmk (pkglib_MODULES): Add `efi_gop.mod'.
431 (efi_fb_mod_SOURCES, efi_fb_mod_CFLAGS, efi_fb_mod_LDFLAGS): New
432 variables.
433 * conf/x86_64-efi.rmk: Likewise.
434
8a4c48d8
VS
4352009-11-28 Vladimir Serbinenko <phcoder@gmail.com>
436
437 Rename efi_fb to efi_uga.
438
439 * conf/i386-efi.rmk (pkglib_MODULES): Rename 'efi_fb.mod' to
440 'efi_uga.mod'.
441 (efi_fb_mod_SOURCES): Rename this ...
442 (efi_uga_mod_SOURCES): ... to this.
443 (efi_fb_mod_CFLAGS): Rename this ...
444 (efi_uga_mod_CFLAGS): ... to this.
445 (efi_fb_mod_LDFLAGS): Rename this ...
446 (efi_uga_mod_LDFLAGS): ... to this.
447 * conf/x86_64-efi.rmk (pkglib_MODULES): Rename 'efi_fb.mod' to
448 'efi_uga.mod'.
449 (efi_fb_mod_SOURCES): Rename this ...
450 (efi_uga_mod_SOURCES): ... to this.
451 (efi_fb_mod_CFLAGS): Rename this ...
452 (efi_uga_mod_CFLAGS): ... to this.
453 (efi_fb_mod_LDFLAGS): Rename this ...
454 (efi_uga_mod_LDFLAGS): ... to this.
455 * video/efi_fb.c: Move this ...
456 * video/efi_uga.c: ... to this. Change prefix to 'grub_video_uga_'.
457
fb6c1a7b
RM
4582009-11-27 Robert Millan <rmh.grub@aybabtu.com>
459
460 * po/README: New file. Explain our PO file workflow.
461
3bc7896c
RM
4622009-11-27 Robert Millan <rmh.grub@aybabtu.com>
463
464 * po/ChangeLog: Remove. Move relevant entries back to ...
465 * ChangeLog: ... here.
466 * po/ca.po: Remove (now handled by TLP).
467 * po/id.po: Likewise.
468 * po/zh_CN.po: Likewise.
469 * Makefile.in (LINGUAS): Initialize in a way that supports
470 empty set.
471
9ed4841d
RM
4722009-11-27 Robert Millan <rmh.grub@aybabtu.com>
473
474 * Makefile.in (LINGUAS): Rewrite by scanning po/ directory instead of
475 reliing on po/LINGUAS.
476 ($(foreach lang, $(LINGUAS), $(srcdir)/po/$(lang).po)): Rewrite as ...
477 (po/%.po): ... this.
478
242668a2
FZ
4792009-11-26 Felix Zielcke <fzielcke@z-51.de>
480
481 * util/i386/efi/grub-mkimage.c: Include "progname.h".
482 (main): Use `program_name' instead of nonexistent `progname'.
483
e30dd392
FZ
4842009-11-26 Felix Zielcke <fzielcke@z-51.de>
485
486 * conf/i386-efi.rmk (grub_mkimage_SOURCES): Add `gnulib/progname.c'.
487 * conf/x86_64-efi.rmk (grub_mkimage_SOURCES): Likewise.
488
7656de4f
RM
4892009-11-26 Robert Millan <rmh.grub@aybabtu.com>
490
491 * conf/i386-coreboot.rmk: Cleanup stale filenames from my previous
492 commit.
493 * conf/i386-efi.rmk: Likewise.
494 * conf/i386-ieee1275.rmk: Likewise.
495 * conf/powerpc-ieee1275.rmk: Likewise.
496 * conf/sparc64-ieee1275.rmk: Likewise.
497 * conf/x86_64-efi.rmk: Likewise.
498
db77c4d4
FZ
4992009-11-26 Felix Zielcke <fzielcke@z-51.de>
500
501 * conf/any-emu.rmk (grub_emu_SOURCES): Add `gnulib/progname.c'.
502
a755bb04
FZ
5032009-11-26 Felix Zielcke <fzielcke@z-51.de>
504
505 * conf/any-emu.rmk (grub_mkfont_SOURCES): Add `gnulib/progname.c'.
506
8a4c07fd
RM
5072009-11-26 Robert Millan <rmh.grub@aybabtu.com>
508
509 * conf/common.rmk (sbin_UTILITIES): Add `grub-mkdevicemap'.
510 (grub_mkdevicemap_SOURCES): New variable.
511 (grub_probe_SOURCES, grub_fstest_SOURCES, grub_mkfont_SOURCES)
512 (grub_mkrelpath_SOURCES, grub_editenv_SOURCES)
513 (grub_pe2elf_SOURCES): Add `gnulib/progname.c'.
514 * conf/i386-coreboot.rmk (sbin_UTILITIES): Remove `grub-mkdevicemap'.
515 (grub_mkdevicemap_SOURCES): Remove.
516 * conf/i386-efi.rmk: Likewise.
517 * conf/i386-ieee1275.rmk: Likewise.
518 * conf/i386-pc.rmk: Likewise.
519 * conf/powerpc-ieee1275.rmk: Likewise.
520 * conf/sparc64-ieee1275.rmk: Likewise.
521 * conf/x86_64-efi.rmk: Likewise.
522 * util/elf/grub-mkimage.c: Include `<grub/i18n.h>' and `"progname.h"'.
523 (usage): Fix strings to use `program_name'.
524 (main): Initialize gettext.
525 * util/grub-editenv.c: Likewise.
526 * util/grub-emu.c: Likewise.
527 * util/grub-fstest.c: Likewise.
528 * util/grub-mkdevicemap.c: Likewise.
529 * util/grub-mkfont.c: Likewise.
530 * util/grub-mkrelpath.c: Likewise.
531 * util/grub-pe2elf.c: Likewise.
532 * util/grub-probe.c: Likewise.
533 * util/sparc64/ieee1275/grub-mkimage.c: Likewise.
534 * util/sparc64/ieee1275/grub-ofpathname.c: Likewise.
535 * util/sparc64/ieee1275/grub-setup.c: Likewise.
536
537 * util/misc.c: Include `"progname.h"'.
538 (progname): Remove variable.
539 (grub_util_warn, grub_util_info, grub_util_error): Use `program_name'.
540
6f61ed55
FZ
5412009-11-25 Felix Zielcke <fzielcke@z-51.de>
542
543 * util/grub.d/10_linux.in (linux_entry): Quote the arguments to
544 printf and print a newline after the menuentry header line.
545 * util/grub.d/10_kfreebsd.in (kfreebsd_entry): Likewise.
546
f022876b
FZ
5472009-11-25 Felix Zielcke <fzielcke@z-51.de>
548
549 autoconf >= 2.60 support $(localedir).
550
551 * INSTALL: Note that autoconf 2.60 is required.
552 * configure.ac (AC_PREREQ): Bump to 2.60.
553 * util/grub.d/10_kfreebsd.in (TEXTDOMAINDIR): Set to lowercased @localedir@.
554 * util/grub.d/10_linux.in (TEXTDOMAINDIR): Likewise.
555
6717926e
YB
5562009-11-25 Yves Blusseau <yves.blusseau@zetam.org>
557
558 * configure.ac: move the call to AM_GNU_GETTEXT to avoid warnings when
559 aclocal is run.
560
08806a54
RM
5612009-11-25 Robert Millan <rmh.grub@aybabtu.com>
562
563 * normal/main.c (grub_normal_read_line): Fix off-by-one
564 buffer overflow.
565
13b33fba
RM
5662009-11-25 Robert Millan <rmh.grub@aybabtu.com>
567
568 * normal/main.c (grub_normal_execute): Replace "parser.sh" with
569 "parser.grub" in grub_command_execute() call.
570
4a8572e9
CPE
5712009-11-24 Carles Pina i Estany <carles@pina.cat>
572
573 * conf/i386-coreboot.rmk (kernel_img_HEADERS): Add i18n.h.
574 * conf/i386-efi.rmk: Likewise.
575 * conf/i386-ieee1275.rmk: Likewise.
576 * conf/i386-pc.rmk: Likewise.
577 * conf/powerpc-ieee1275.rmk: Likewise.
578 * conf/sparc64-ieee1275.rmk: Likewise.
579 * conf/x86_64-efi.rmk: Likewise.
580 * gettext/gettex.c: Include <grub/i18n.h>.
581 * include/grub/misc.h (grub_gettext_dummy, grub_gettext): Move from
582 here ...
583 * include/grub/i18n.h: ... to here
584 * include/grub/i18n.h: ... to here.
585 * kern/misc.c: Include <grub/i18n.h>
586 (grub_gettext_dummy): Move above user.
587
bee48093
FZ
5882009-11-24 Felix Zielcke <fzielcke@z-51.de>
589
590 * util/Makefile.in (install-local): Convert a `for' into a normal
591 shell expansion.
592
a031e91c
RM
5932009-11-24 Robert Millan <rmh.grub@aybabtu.com>
594
595 * autogen.sh: Add automake call.
596 * config.guess: Remove.
597 * config.sub: Likewise.
598 * install-sh: Likewise.
599
26bec39d
FZ
6002009-11-24 Felix Zielcke <fzielcke@z-51.de>
601
602 * util/Makefile.in (install-local): Fix the use of $lang shell variable.
603
8e2532fd
FZ
6042009-11-24 Felix Zielcke <fzielcke@z-51.de>
605
606 * util/Makefile.in (install-local): Convert a make `$(foreach)'
607 function to a normal shell `for'.
608
fefa1b7d
FZ
6092009-11-24 Felix Zielcke <fzielcke@z-51.de>
610
611 * conf/i386-coreboot.rmk (grub_mkimage_SOURCES): Add `gnulib/progname.c'.
612
4501250b
FZ
6132009-11-24 Felix Zielcke <fzielcke@z-51.de>
614
615 * util/grub-mkrelpath.c: New file.
616 * conf/common.rmk (bin_UTILITIES): Add grub-mkrelpath.
617 (grub_mkrelpath_SOURCES): New variable.
618 * include/grub/util/misc.h: New function prototype.
619 * util/misc.c (make_system_path_relative_to_its_root): New function.
620
621 * util/grub-mkconfig_lib.in (bindir): New variable.
622 (grub_mkrelpath): Likewise.
623 (make_system_path_relative_to_its_root): Use grub-mkrelpath.
624
625 * util/probe.c (probe): Make the file path relative to its root.
626 Change a info message to use the GRUB path. Enable again the
627 check if we can read the file with GRUB facilities.
628
629 * util/i386/pc/grub-setup.c (setup): Make core.img path relative
630 to its root.
631
11d9778b
FZ
6322009-11-24 Felix Zielcke <fzielcke@z-51.de>
633
634 * Makefile.in: Don't include GRUB_CONTRIB makefiles with emu
635 platform.
636
4465287d
FZ
6372009-11-24 Felix Zielcke <fzielcke@z-51.de>
638
639 * util/getroot.c (grub_util_get_dev_abstraction): Properly use
640 strncmp().
641
62b47f22
FZ
6422009-11-24 Felix Zielcke <fzielcke@z-51.de>
643
644 * util/getroot.c (grub_util_is_dmraid): New function.
645 (grub_util_get_dev_abstraction): Treat dmraid and multipath
646 devices as normal ones, not as LVM.
647
1eafb9b9 6482009-11-23 Carles Pina i Estany <carles@pina.cat>
c3ea6bd4
CPE
649
650 * conf/common.rmk: Add grub-gettext_lib target and updates
651 lib_DATA and CLEANFILES. Adds gettext.mod SOURCES, CFLAGS,
652 LDFLAGS.
653 * gettext/gettext.c: New file. (Reads mo files).
654 * include/grub/file.h (grub_file_pread): New prototype.
655 * include/grub/i18n.h (_): New prototype.
656 * include/grub/misc.h (grub_gettext_dummy, grub_gettext): New
657 prototypes.
658 * kern/misc.c (grub_gettext_dummy): New function.
659 * normal/menu_text.c: Include <grub/i18n.h>.
660 * normal/menu_text.c (print_timeout): Gettexttize string.
661 * normal/menu_text.c (print_message): Gettexttize string.
3bc7896c
RM
662 * po/POTFILES: Add `normal/menu_text.c'.
663 * po/ca.po: Add new translations.
c3ea6bd4
CPE
664 * util/grub.d/00_header.in: Define locale_dir and lang. insmod
665 gettext module and defines locale_dir and lang in grub.cfg.
666 * NEWS: Add gettext support.
667
0fdb2568
RM
6682009-11-23 Robert Millan <rmh.grub@aybabtu.com>
669
670 * util/hostdisk.c: Include `<grub/i18n.h>'.
671 (find_grub_drive): Use ARRAY_SIZE for map size calculation.
672 (make_device_name): Rewrite using asprintf.
673 (convert_system_partition_to_system_disk): Replace 0 with NULL.
674 (find_system_device): If a device is not found, generate one just
675 by reusing the OS path name.
676 (read_device_map): Make it permissible for device.map not to exist.
677
f515aa62
RM
6782009-11-23 Robert Millan <rmh.grub@aybabtu.com>
679
680 * script/sh/execute.c: Move from here ...
681 * script/execute.c: ... to here. Update all users.
682 * script/sh/function.c: Move from here ...
683 * script/function.c: ... to here. Update all users.
684 * script/sh/lexer.c: Move from here ...
685 * script/lexer.c: ... to here. Update all users.
686 * script/sh/main.c: Move from here ...
687 * script/main.c: ... to here. Update all users.
688 * script/sh/parser.y: Move from here ...
689 * script/parser.y: ... to here. Update all users.
690 * script/sh/script.c: Move from here ...
691 * script/script.c: ... to here. Update all users.
692
f84b481b
RM
6932009-11-23 Robert Millan <rmh.grub@aybabtu.com>
694
695 * configure.ac: Detect all `emu' platforms. Define
696 GRUB_MACHINE_* macros in TARGET_CFLAGS. Remove
697 --enable-grub-emu logic. Disable include/grub/machine
698 symlink on `emu' platforms.
699
700 * genkernsyms.sh.in: Use @TARGET_CFLAGS@ during symbol generation.
701 * gensymlist.sh.in: Likewise.
702
703 * include/grub/i386/coreboot/machine.h: Remove file.
704 * include/grub/i386/efi/machine.h: Likewise.
705 * include/grub/i386/ieee1275/machine.h: Likewise.
706 * include/grub/i386/pc/machine.h: Likewise.
707 * include/grub/i386/qemu/machine.h: Likewise.
708 * include/grub/powerpc/ieee1275/machine.h: Likewise.
709 * include/grub/sparc64/ieee1275/machine.h: Likewise.
710 * include/grub/x86_64/efi/machine.h: Likewise.
711
712 * commands/acpi.c: Remove `<grub/machine/machine.h>'.
713 * commands/halt.c: Likewise.
714 * commands/reboot.c: Likewise.
715 * include/grub/autoefi.h: Likewise.
716 * include/grub/i386/at_keyboard.h: Likewise.
717 * include/grub/i386/kernel.h: Likewise.
718 * include/grub/i386/loader.h: Likewise.
719 * include/grub/i386/pc/memory.h: Likewise.
720 * kern/dl.c: Likewise.
721 * kern/i386/coreboot/init.c: Likewise.
722 * loader/i386/bsd.c: Likewise.
723 * loader/i386/linux.c: Likewise.
724 * loader/multiboot_loader.c: Likewise.
725 * term/i386/pc/serial.c: Likewise.
726 * term/usb_keyboard.c: Likewise.
727
728 * include/grub/time.h [!GRUB_MACHINE_EMU]: Remove
729 `<grub/machine/machine.h>'
730 [!GRUB_MACHINE_EMU] (GRUB_TICKS_PER_SECOND): New macro.
731 * util/misc.c: Remove `<grub/machine/machine.h>' and
732 `<grub/machine/time.h>'.
733
734 * Makefile.in (enable_grub_emu): Remove variable.
735 Include $(srcdir)/conf/any-emu.mk for the `emu' platform.
736
737 * conf/any-emu.rmk: New file.
738 * conf/common.rmk (grub_emu_init.lst, grub_emu_init.h)
739 (grub_emu_init.c): Move from here ...
740 * conf/any-emu.rmk: ... to here.
741
742 * conf/i386-coreboot.rmk (sbin_UTILITIES): Remove `grub-emu'.
743 (grub_emu_SOURCES, grub_emu_LDFLAGS): Move from here ...
744 * conf/any-emu.rmk: ... to here.
745
4efeab03
RM
7462009-11-23 Robert Millan <rmh.grub@aybabtu.com>
747
748 * include/grub/parser.h (grub_parser_register): Document need
749 of `name' parameter.
750 * normal/main.c (grub_normal_read_line): Simplify prompt string.
751 * script/sh/main.c (grub_sh_parser, GRUB_MOD_INIT(sh)): Rename
752 "sh" to "grub".
753
ea1dd8bf
RM
7542009-11-23 Robert Millan <rmh.grub@aybabtu.com>
755
756 * Makefile.in ($(srcdir)/po/$(PACKAGE).pot): Pass --keyword=N_ to
757 `$(XGETTEXT)'.
758 * include/grub/i18n.h (N_): New macro.
759 * util/mkisofs/mkisofs.h: Likewise.
760 * util/mkisofs/mkisofs.c (ld_options): Wrap all translatable strings
761 around N_().
762 (usage): Use gettext() to translate help strings when printing them.
763
0c140626
RM
7642009-11-23 Robert Millan <rmh.grub@aybabtu.com>
765
766 Based on patch from Bean
767 (http://lists.gnu.org/archive/html/grub-devel/2009-08/msg00384.html)
768
769 * video/efi_fb.c: New file.
770 * conf/i386-efi.rmk (pkglib_MODULES): Add `efi_fb.mod'.
771 (efi_fb_mod_SOURCES, efi_fb_mod_CFLAGS, efi_fb_mod_LDFLAGS): New
772 variables.
773 * conf/x86_64-efi.rmk: Likewise.
774
87d58298
RM
7752009-11-22 Robert Millan <rmh.grub@aybabtu.com>
776
777 * util/i386/pc/grub-mkimage.c: Ungettextize grub_util_info() strings.
778 * util/i386/pc/grub-setup.c: Likewise.
779
994cc3a3
ST
7802009-11-21 Samuel Thibault <samuel.thibault@ens-lyon.org>
781
782 * util/getroot.c [__GNU__]: Include <hurd.h>, <hurd/lookup.h>, and
783 <hurd/fs.h>
784 [__GNU__] (grub_guess_root_device): Call file_name_lookup and
785 file_get_storage_info to implement grub_guess_root_device.
786
26a61d6a
FZ
7872009-11-21 Felix Zielcke <fzielcke@z-51.de>
788
789 * Makefile.in (target): Use make's builtin $(shell) function
790 instead of calling directly $(SHELL) to create the locale directories,
791 inside the $(foreach) function.
792
74ff1dd5
FZ
7932009-11-21 Felix Zielcke <fzielcke@z-51.de>
794
795 * util/grub-mkrescue.in: Print an error and usage if output option
796 has not been given.
797
0b787d0e
FZ
7982009-11-21 Felix Zielcke <fzielcke@z-51.de>
799
800 Patch from Loïc Minier <loic.minier@ubuntu.com>.
801 * util/grub.d/30_os-prober.in: Cope with Linux entries where
802 root and /boot are on different devices.
803
1164b270
RM
8042009-11-21 Robert Millan <rmh.grub@aybabtu.com>
805
806 Fix build for srcdir != objdir.
807
808 * Makefile.in (po/$(PACKAGE).pot): Rename to ...
809 ($(srcdir)/po/$(PACKAGE).pot): ... this. Run $(XGETTEXT) from
810 $(srcdir).
811 ($(foreach lang, $(LINGUAS), po/$(lang).po)): Rename to ...
812 ($(foreach lang, $(LINGUAS), $(srcdir)/po/$(lang).po): ... this. Use $^
813 reference for input.
814
13774a2f
RM
8152009-11-21 Robert Millan <rmh.grub@aybabtu.com>
816
817 * util/grub-mkrescue.in: Use source directory direcly (without copiing
818 or hardlinking it). Remove -J option, Joliet is not compatible with
819 multiple source directories.
820
efda854e
RM
8212009-11-21 Carles Pina i Estany <carles@pina.cat>
8222009-11-21 Robert Millan <rmh.grub@aybabtu.com>
823
824 * util/grub-mkrescue.in: Recognize `--override-directory' option.
825 (process_input_dir): New function. Process an arbitrary input
826 directory.
827 Misc adjustments to support both "override mode" and system-wide mode.
828
6c09890c
FZ
8292009-11-20 Felix Zielcke <fzielcke@z-51.de>
830
831 * configure.ac (UNIFONT_BDF): Rename to ...
832 (FONT_SOURCE): ... this. Update all users.
833
a797824f
FZ
8342009-11-20 Felix Zielcke <fzielcke@z-51.de>
835
836 * configure.ac: Add `/usr/share/fonts/X11/misc/unifont.pcf.gz'
837 to the list of unifont files to look for.
838
cd4f42b0
RM
8392009-11-19 Robert Millan <rmh.grub@aybabtu.com>
840
841 Patch from Joe Auricchio <jauricchio@gmail.com>
842 * commands/minicmd.c (grub_mini_cmd_clear): New function.
843 (GRUB_MOD_INIT(minicmd)): Register grub_mini_cmd_clear().
844 (GRUB_MOD_FINI(minicmd)): Unregister grub_mini_cmd_clear().
845
393c783d
FZ
8462009-11-19 Felix Zielcke <fzielcke@z-51.de>
847
848 * Makefile.in (install-local): Add a missing backslash.
849
b2f1e327
FZ
8502009-11-19 Felix Zielcke <fzielcke@z-51.de>
851
852 * include/grub/x86_64/io.h: New file.
853
f577f7a0
RM
8542009-11-19 Robert Millan <rmh.grub@aybabtu.com>
855
856 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `gnulib/progname.c'.
857 * util/i386/pc/grub-setup.c: Include `<grub/i18n.h>'.
858 Include `"progname.h"'.
859 (main): Initialize gettext.
860 * util/i386/pc/grub-setup.c: Gettexttize.
861 * util/i386/pc/grub-mkimage.c: Likewise.
862
863 * Makefile.in (po/*.po): Redefine as ...
864 ($(foreach lang, $(LINGUAS), po/$(lang).po)): ... this.
865
3bc7896c
RM
866 * po/POTFILES: Add `util/i386/pc/grub-setup.c'.
867
c37943b6
RM
8682009-11-19 Robert Millan <rmh.grub@aybabtu.com>
869
870 * conf/common.rmk (grub_mkisofs_SOURCES): Add `gnulib/progname.c'.
871 * util/mkisofs/mkisofs.c: Include `"progname.h"'.
872 (program_name): Remove.
873 (main): Initialize gettext support.
6323f705
RM
874 * util/mkisofs/mkisofs.h: Include `<locale.h>'.
875 Include `<libintl.h>'.
876 (_): New macro.
c37943b6
RM
877
878 * util/mkisofs/eltorito.c: Gettexttize.
879 * util/mkisofs/joliet.c: Likewise.
880 * util/mkisofs/mkisofs.c: Likewise.
c37943b6
RM
881 * util/mkisofs/multi.c: Likewise.
882 * util/mkisofs/rock.c: Likewise.
883 * util/mkisofs/tree.c: Likewise.
884 * util/mkisofs/write.c: Likewise.
885
3bc7896c
RM
886 * po/POTFILES: Update with new files.
887
5ce77c6e
RM
8882009-11-18 Robert Millan <rmh.grub@aybabtu.com>
889
890 * util/mkisofs/eltorito.c: Fix minor mistake in license text.
891 * util/mkisofs/iso9660.h: Likewise.
892 * util/mkisofs/joliet.c: Likewise.
893 * util/mkisofs/mkisofs.c: Likewise.
894 * util/mkisofs/mkisofs.h: Likewise.
895 * util/mkisofs/rock.c: Likewise.
896 * util/mkisofs/tree.c: Likewise.
897 * util/mkisofs/write.c: Likewise.
898
899 * util/mkisofs/eltorito.c (rcsid): Remove.
900 * util/mkisofs/hash.c: Likewise.
901 * util/mkisofs/joliet.c: Likewise.
902 * util/mkisofs/name.c: Likewise.
903 * util/mkisofs/rock.c: Likewise.
904 * util/mkisofs/tree.c: Likewise.
905 * util/mkisofs/write.c: Likewise.
906
1dabbc77
RM
9072009-11-18 Robert Millan <rmh.grub@aybabtu.com>
908
909 * util/mkisofs/match.c: Rewrite from scratch, using a linked list
910 instead of static allocation.
911 * util/mkisofs/match.h: Likewise.
912
633877cb
RM
9132009-11-18 Robert Millan <rmh.grub@aybabtu.com>
914
3bc7896c
RM
915 * po/POTFILES-shell: New file. List `util/grub.d/10_kfreebsd.in'
916 and `util/grub.d/10_linux.in'.
633877cb
RM
917 * Makefile.in (po/$(PACKAGE).pot): Process `po/POTFILES-shell' for
918 translatable Shell files.
919
af1c0c85
RM
9202009-11-18 Robert Millan <rmh.grub@aybabtu.com>
921
922 * Makefile.in ($(srcdir)/aclocal.m4): New target.
923
769ae37b
RM
9242009-11-17 Robert Millan <rmh.grub@aybabtu.com>
925
926 * INSTALL: Document Automake is needed for bootstrap.
3bc7896c 927 * po/ca.po: Fix PO-Revision-Date and Language-Team fields.
769ae37b
RM
928 * util/grub.d/10_kfreebsd.in (bindir): New variable.
929 Add gettext initialization.
930 (kfreebsd_entry): Make menuentry output translatable.
931
9322009-11-17 Robert Millan <rmh.grub@aybabtu.com>
933
934 * Makefile.in (XGETTEXT, MSGMERGE, MSGFMT): New variables.
935 (po/$(PACKAGE).pot): Replace `xgettext' with `$(XGETTEXT)'.
936 (po/*.po): Replace `msgmerge' with `$(MSGMERGE)'.
937 (po/%.mo): Replace `msgfmt' with `$(MSGFMT)'.
938 (LINGUAS): Auto-generate using `po/LINGUAS'.
3bc7896c 939 * po/LINGUAS: New file.
769ae37b
RM
940
9412009-11-17 Robert Millan <rmh.grub@aybabtu.com>
942
943 * configure.ac: Call AM_GNU_GETTEXT() (defines localedir, among
944 other things).
945 * Makefile.in (CPPFLAGS): Add `-DLOCALEDIR=\"$(localedir)\"'.
946 * util/i386/pc/grub-mkimage.c (main): Issue setlocale() and
947 bindtextdomain() calls for gettext initialization.
948
9492009-11-17 Robert Millan <rmh.grub@aybabtu.com>
950
951 * gnulib/progname.c: New file (imported from Gnulib).
952 * gnulib/progname.h: Likewise.
953 * conf/i386-pc.rmk (grub_mkimage_SOURCES): Add `gnulib/progname.c'.
954 * util/i386/pc/grub-mkimage.c: Include `"progname.h"'.
955 (usage): Replace `progname' with `program_name'.
956 (main): Use set_program_name() for program name initialization.
957
9582009-11-17 Robert Millan <rmh.grub@aybabtu.com>
959
960 * conf/common.rmk (grub_mkisofs_CFLAGS): Move `-I$(srcdir)/gnulib'
961 from here ...
962 * Makefile.in (CPPFLAGS): ... to here.
963
9642009-11-16 Robert Millan <rmh.grub@aybabtu.com>
965
966 * aclocal.m4: Move from here ...
967 * acinclude.m4: ... to here.
968 * autogen.sh: Add call to `aclocal'.
969 * configure.ac: Add AM_INIT_AUTOMAKE() after AC_INIT() call.
970
9712009-11-16 Robert Millan <rmh.grub@aybabtu.com>
972
973 * Makefile.in (CLEANFILES): Add `po/*.mo'.
974 (LINGUAS): New variable.
975 (all-local): Add `$(foreach lang, $(LINGUAS), po/$(lang).mo)'.
976 (install-local): Install MO files.
977 (po/$(PACKAGE).pot, po/*.po, po/%.mo): New rules.
978 * include/grub/i18n.h: New file.
3bc7896c
RM
979 * po/POTFILES: New file.
980 * po/ca.po: New file.
769ae37b
RM
981 * util/grub.d/10_linux.in (bindir): New variable.
982 Add gettext initialization.
983 (linux_entry): Make menuentry output translatable.
984 * util/i386/pc/grub-mkimage.c: Include `<grub/i18n.h>'.
985 (usage): Make --help output translatable.
986 (main): Initialize gettext.
987
02c0a6ad
RM
9882009-11-17 Robert Millan <rmh.grub@aybabtu.com>
989
990 * import_gcry.py: New file (written by Vladimir with minor
991 adjustments).
992 * autogen.sh: Use import_gcry.py to auto-generate GRUB-ified
993 ciphers.
994 * INSTALL: Document that Python is required for bootstrap.
995
9962009-11-17 Robert Millan <rmh.grub@aybabtu.com>
997
998 Import ciphers from libgcrypt 1.4.4.
999
1000 * lib/libgcrypt/cipher/ChangeLog
1001 * lib/libgcrypt/cipher/ac.c
1002 * lib/libgcrypt/cipher/arcfour.c
1003 * lib/libgcrypt/cipher/bithelp.h
1004 * lib/libgcrypt/cipher/blowfish.c
1005 * lib/libgcrypt/cipher/camellia-glue.c
1006 * lib/libgcrypt/cipher/camellia.c
1007 * lib/libgcrypt/cipher/camellia.h
1008 * lib/libgcrypt/cipher/cast5.c
1009 * lib/libgcrypt/cipher/cipher.c
1010 * lib/libgcrypt/cipher/crc.c
1011 * lib/libgcrypt/cipher/des.c
1012 * lib/libgcrypt/cipher/dsa.c
1013 * lib/libgcrypt/cipher/ecc.c
1014 * lib/libgcrypt/cipher/elgamal.c
1015 * lib/libgcrypt/cipher/hash-common.c
1016 * lib/libgcrypt/cipher/hash-common.h
1017 * lib/libgcrypt/cipher/hmac-tests.c
1018 * lib/libgcrypt/cipher/md.c
1019 * lib/libgcrypt/cipher/md4.c
1020 * lib/libgcrypt/cipher/md5.c
1021 * lib/libgcrypt/cipher/primegen.c
1022 * lib/libgcrypt/cipher/pubkey.c
1023 * lib/libgcrypt/cipher/rfc2268.c
1024 * lib/libgcrypt/cipher/rijndael-tables.h
1025 * lib/libgcrypt/cipher/rijndael.c
1026 * lib/libgcrypt/cipher/rmd.h
1027 * lib/libgcrypt/cipher/rmd160.c
1028 * lib/libgcrypt/cipher/rsa.c
1029 * lib/libgcrypt/cipher/seed.c
1030 * lib/libgcrypt/cipher/serpent.c
1031 * lib/libgcrypt/cipher/sha1.c
1032 * lib/libgcrypt/cipher/sha256.c
1033 * lib/libgcrypt/cipher/sha512.c
1034 * lib/libgcrypt/cipher/tiger.c
1035 * lib/libgcrypt/cipher/twofish.c
1036 * lib/libgcrypt/cipher/whirlpool.c
1037
af2f93ac
RM
10382009-11-16 Robert Millan <rmh.grub@aybabtu.com>
1039
1040 Fix build for systems without error().
1041
1042 * gnulib/error.c: New file (imported from Gnulib).
1043 * gnulib/error.h: Likewise.
1044 * conf/common.rmk (grub_mkisofs_SOURCES): Add `gnulib/error.c'.
1045 * util/mkisofs/mkisofs.c (program_name): Remove `static' qualifier
1046 (this variable is now used by error()).
1047
73fb3dd5
FZ
10482009-11-16 Felix Zielcke <fzielcke@z-51.de>
1049
814f5e96
FZ
1050 * util/mkisofs/name.c (iso9660_file_length): Use isascii macro
1051 instead of relying that char is signed.
73fb3dd5 1052
a691ca33
VS
10532009-11-16 Vladimir Serbinenko <phcoder@gmail.com>
1054
1055 * fs/i386/pc/pxe.c (grub_pxefs_open): Correctly handle PXE choosing
1056 blocksize different from specified.
1057 (grub_pxefs_read): Likewise.
1058
2af8f0f4
FZ
10592009-11-16 Felix Zielcke <fzielcke@z-51.de>
1060
1061 Enable ata.mod on x86_64-efi, i386-efi and i386-ieee1275.
1062
1063 * disk/ata.c (grub_ata_dumpinfo): Add a cast.
1064 (grub_ata_readwrite): Likewise. Update 2 format strings.
1065 (grub_atapi_read): Likewise.
1066
1067 * conf/i386-coreboot.rmk (pkglib_MODULES): Move `ata.mod' from here ...
1068 * conf/i386.rmk (pkglib_MODULES): ... to here ...
1069 * conf/x86_64-efi.rmk (pkglib_MODULES): ... and here.
1070 * conf/i386-coreboot.rmk (ata_mod_SOURCES, ata_mod_CFLAGS)
1071 (ata_mod_LDFLAGS): Move from here ...
1072 * conf/i386.rmk: ... to here ...
1073 * conf/x86_64-efi.rmk: ... and here.
1074 * conf/i386-pc.rmk (pkglib_MODULES): Remove `ata.mod'
1075 (ata_mod_SOURCES, ata_mod_CFLAGS, ata_mod_LDFLAGS): Remove.
1076
83bdecaf
RM
10772009-11-16 Robert Millan <rmh.grub@aybabtu.com>
1078
1079 Relicense multiboot.h, with RMS' blessing.
1080
1081 * include/multiboot.h: Change to X11 license.
1082
fd6fd3d7
RM
10832009-11-15 Robert Millan <rmh.grub@aybabtu.com>
1084
1085 Support --version in grub-mkisofs.
1086
1087 * util/mkisofs/mkisofs.c (rcsid): Remove variable.
1088 (OPTION_VERSION): New macro.
1089 (ld_options): Recognize --version.
1090 (usage): Move `program_name' from here ...
1091 (program_name): ... to here. Add `static' qualifier.
1092 (main): Recognize `OPTION_VERSION'.
1093
16a88c49
FZ
10942009-11-15 Felix Zielcke <fzielcke@z-51.de>
1095
1096 * Makefile.in (TARGET_CPPFLAGS): Replace `-isystem=$(srcdir)/include'
1097 with `-nostdinc -isystem $(shell $(TARGET_CC) -print-file-name=include)'.
1098
a4158476
RM
10992009-11-14 Robert Millan <rmh.grub@aybabtu.com>
1100
1101 Fix help2man generation for mkisofs.
1102
1103 * util/mkisofs/mkisofs.c (ld_options): Recognize --help.
1104 (usage): Send output to stdout (rather than stderr).
1105
fc2208b0
RM
11062009-11-14 Robert Millan <rmh.grub@aybabtu.com>
1107
1108 * conf/i386-coreboot.rmk (grub_mkrescue_SOURCES): Replace
1109 `util/i386/coreboot/grub-mkrescue.in' with `util/grub-mkrescue.in'.
1110 * conf/i386-pc.rmk (grub_mkrescue_SOURCES): Replace
1111 `util/i386/pc/grub-mkrescue.in' with `util/grub-mkrescue.in'.
1112 (bin_SCRIPTS): Add `grub-mkfloppy'.
1113 (grub_mkfloppy_SOURCES): New variable.
1114
1115 * util/grub-mkrescue.in: New file.
1116 * util/i386/pc/grub-mkfloppy.in: New file.
1117
1118 * util/i386/coreboot/grub-mkrescue.in: Remove.
1119 * util/i386/pc/grub-mkrescue.in: Remove.
1120
8d0edf4a
RM
11212009-11-13 Robert Millan <rmh.grub@aybabtu.com>
1122
1123 * include/grub/multiboot.h (struct grub_multiboot_header): Move
1124 from here ...
1125 * include/multiboot.h (struct multiboot_header): ... to here. Update
1126 all users.
1127 * include/grub/multiboot.h (struct grub_multiboot_info): Move
1128 from here ...
1129 * include/multiboot.h (struct multiboot_info): ... to here. Update
1130 all users.
1131 * include/grub/multiboot.h (struct grub_multiboot_mmap_entry): Move
1132 from here ...
1133 * include/multiboot.h (struct multiboot_mmap_entry): ... to here.
1134 Update all users.
1135 * include/grub/multiboot.h (struct grub_mod_list): Move
1136 from here ...
1137 * include/multiboot.h (struct multiboot_mod_list): ... to here.
1138 Update all users.
1139
a73f5969
RM
11402009-11-13 Robert Millan <rmh.grub@aybabtu.com>
1141
1142 * include/multiboot2.h (multiboot_word): Rename from this ...
1143 (multiboot2_word): ... to this. Update all users.
1144 (multiboot_header): Rename from this ...
1145 (multiboot2_header): ... to this. Update all users.
1146 (multiboot_tag_header): Rename from this ...
1147 (multiboot2_tag_header): ... to this. Update all users.
1148 (multiboot_tag_start): Rename from this ...
1149 (multiboot2_tag_start): ... to this. Update all users.
1150 (multiboot_tag_name): Rename from this ...
1151 (multiboot2_tag_name): ... to this. Update all users.
1152 (multiboot_tag_module): Rename from this ...
1153 (multiboot2_tag_module): ... to this. Update all users.
1154 (multiboot_tag_memory): Rename from this ...
1155 (multiboot2_tag_memory): ... to this. Update all users.
1156 (multiboot_tag_unused): Rename from this ...
1157 (multiboot2_tag_unused): ... to this. Update all users.
1158 (multiboot_tag_end): Rename from this ...
1159 (multiboot2_tag_end): ... to this. Update all users.
1160
1c8927f0
RM
11612009-11-13 Robert Millan <rmh.grub@aybabtu.com>
1162
1163 Disable Multiboot2 in i386-ieee1275. It didn't actually work, and on
1164 this platform we should support Multiboot1 first.
1165
1166 * conf/i386-ieee1275.rmk (pkglib_MODULES): Remove `multiboot.mod'.
1167 (multiboot_mod_SOURCES, multiboot_mod_CFLAGS)
1168 (multiboot_mod_LDFLAGS, multiboot_mod_ASFLAGS): Remove.
1169
6e1e0d89
RM
11702009-11-12 Robert Millan <rmh.grub@aybabtu.com>
1171
1172 * util/mkisofs/eltorito.c (init_boot_catalog): Handle return code
1173 of write calls (converting them to fwrite() if they aren't already).
1174 (get_torito_desc): Likewise.
1175 * util/mkisofs/rock.c (generate_rock_ridge_attributes): Likewise.
1176
7f2b34d8
RM
11772009-11-12 Robert Millan <rmh.grub@aybabtu.com>
1178
1179 * util/i386/pc/grub-install.in: Move from here ...
1180 * util/grub-install.in: ... to here. Update all users.
1181
c0ef3311
CW
11822009-11-11 Colin Watson <cjwatson@ubuntu.com>
1183
1184 * util/powerpc/ieee1275/grub-mkrescue.in: Fix --version output.
1185
e1f240ff
RM
11862009-11-11 Robert Millan <rmh.grub@aybabtu.com>
1187
1188 Support for El Torito without floppy emulation.
1189
1190 * util/mkisofs/eltorito.c: Include `<errno.h>'.
1191 (init_boot_catalog): Improve error handling.
1192 (get_torito_desc): Don't use floppy emulation unless requested by
1193 user. Patch boot information table when requested via
1194 `-boot-info-table'.
1195 * util/mkisofs/iso9660.h (struct eltorito_boot_info): New struct.
1196 * util/mkisofs/mkisofs.c (use_eltorito_emul_floppy)
1197 (use_boot_info_table): New variables.
1198 (OPTION_BOOT_INFO_TABLE, OPTION_NO_EMUL_BOOT)
1199 (OPTION_ELTORITO_EMUL_FLOPPY): New macros.
1200 (ld_options): Handle `-boot-info-table', `-no-emul-boot' and
1201 `--eltorito-emul-floppy'.
1202 (main): Handle `OPTION_BOOT_INFO_TABLE', `OPTION_NO_EMUL_BOOT'
1203 and `OPTION_ELTORITO_EMUL_FLOPPY'.
1204 * util/mkisofs/mkisofs.h (use_eltorito_emul_floppy)
1205 (use_boot_info_table, get_731): New prototypes.
1206 * util/mkisofs/write.c (get_731): New function.
1207
af7d4de5
FZ
12082009-11-11 Felix Zielcke <fzielcke@z-51.de>
1209
1210 Fix the generation of the man page.
1211
1212 * util/pc/i386/grub-install.in: Source
1213 `${libdir}/grub/grub-mkconfig_lib' after options have been parsed.
1214
2c55dbc0
RM
12152009-11-11 Robert Millan <rmh.grub@aybabtu.com>
1216
1217 Large file support for grub-mkisofs.
1218
1219 * conf/common.rmk (grub_mkisofs_CFLAGS): Add `-D_FILE_OFFSET_BITS=64'.
1220 * util/mkisofs/mkisofs.c (next_extent, last_extent)
1221 (session_start): Upgrade type to `uint64_t'. Update all users.
1222 * util/mkisofs/mkisofs.h: Include `<stdint.h>'.
1223 (struct directory_entry): Upgrade type of `starting_block' and
1224 `size' to `uint64_t'. Update all users.
1225 (struct deferred): Remove unused structure.
1226 (xfwrite): Upgrade type of `count' and `size' to `uint64_t'.
1227 Update all users.
1228 * util/mkisofs/tree.c (stat_filter, lstat_filter): Return -1 when
1229 file is larger than `UINT32_MAX'.
1230 * util/mkisofs/write.c (xfwrite): Upgrade type of `count' and
1231 `size' to `uint64_t'. Update all users. Fix handling of fwrite()
1232 return value.
1233 (struct deferred_write): Upgrade type of `extent' and `size' to
1234 `uint64_t'. Update all users.
1235 (last_extent_written): Upgrade type to `uint64_t'. Update all
1236 users.
1237 (write_one_file): Upgrade type of `count' and `size' to `uint64_t'.
1238 Update all users. Upgrade type of `remain' to `int64_t' and
1239 `use' to `size_t'. Use error() to handle fread() errors.
1240 (write_files): Rely on write_one_file() rather than calling
1241 xfwrite() directly.
1242
6a9cead5
FZ
12432009-11-09 Felix Zielcke <fzielcke@z-51.de>
1244
1245 * util/mkisofs/mkisofs.c (ld_options): Fix a spelling mistake.
1246
4825d790
RM
12472009-11-09 Robert Millan <rmh.grub@aybabtu.com>
1248
1249 * util/mkisofs/fnmatch.c: Remove.
1250 * util/mkisofs/getopt1.c: Likewise.
1251 * util/mkisofs/getopt.c: Likewise.
1252 * conf/common.rmk (grub_mkisofs_SOURCES): Replace
1253 `util/mkisofs/fnmatch.c', `util/mkisofs/getopt1.c' and
1254 `util/mkisofs/getopt.c' with `gnulib/fnmatch.c',
1255 `gnulib/getopt1.c' and `gnulib/getopt.c'.
1256 (grub_mkisofs_CFLAGS): Add `-I$(srcdir)/gnulib'.
1257
1258 * configure.ac: Detect `mingw32msvc' host_os.
1259 Check for lstat(), getuid() and getgid().
1260
1261 * util/mkisofs/joliet.c: Include `<stdint.h>'. Replace all
1262 instances of `u_char' with `uint8_t'.
1263
1264 * util/mkisofs/mkisofs.h: Include `<sys/stat.h>'.
1265 [!HAVE_GETUID] (getuid): New function (stub).
1266 [!HAVE_GETGID] (getgid): Likewise.
1267 [!HAVE_LSTAT] (lstat): Likewise.
1268 [!S_IROTH] (S_IROTH): New macro (dummy).
1269 [!S_IRGRP] (S_IRGRP): Likewise.
1270
84b860d8
RM
12712009-11-09 Robert Millan <rmh.grub@aybabtu.com>
1272
1273 * gnulib/fnmatch_loop.c (EXT): Fix warning (signed and unsigned type in
1274 conditional expression).
1275
66e9b712
RM
12762009-11-09 Robert Millan <rmh.grub@aybabtu.com>
1277
1278 Import from Gnulib.
1279
1280 * gnulib/fnmatch.c: New file.
1281 * gnulib/fnmatch.h: Likewise.
1282 * gnulib/fnmatch_loop.c: Likewise.
1283 * gnulib/getopt.c: Likewise.
1284 * gnulib/getopt.h: Likewise.
1285 * gnulib/getopt1.c: Likewise.
1286 * gnulib/getopt_int.h: Likewise.
1287 * gnulib/gettext.h: Likewise.
1288
34f4a5b0
RM
12892009-11-09 Robert Millan <rmh.grub@aybabtu.com>
1290
1291 * normal/dyncmd.c (read_command_list): Replace `0' with `NULL'.
1292 * normal/handler.c (read_handler_list): Likewise.
1293
ac451143
RM
12942009-11-09 Robert Millan <rmh.grub@aybabtu.com>
1295
1296 Misc cleanup.
1297
1298 * kern/command.c (grub_register_command_prio): Use
1299 grub_zalloc() instead of explicitly zeroing data.
1300 * kern/list.c: Include `<grub/mm.h>'.
1301 (grub_named_list_find): Replace `0' with `NULL'.
1302 * normal/autofs.c (struct grub_fs_module_list): Remove ad-hoc type.
1303 (fs_module_list): Change type to `grub_named_list_t'. Update all
1304 users.
1305 * normal/dyncmd.c (read_command_list): Add space between function
1306 call and parenthesis.
1307 * normal/handler.c (read_handler_list): Likewise.
1308
4089b167
RM
13092009-11-09 Robert Millan <rmh.grub@aybabtu.com>
1310
1311 * normal/auth.c (punishment_delay): Moved from here ...
1312 (grub_auth_strcmp): ... to here (inside function).
1313
325f5037
RM
13142009-11-09 Robert Millan <rmh.grub@aybabtu.com>
1315
1316 * include/grub/list.h (struct grub_named_list): Remove `const'
1317 qualifier from `name'.
1318 (struct grub_prio_list): Likewise.
1319
7aea29a3
RM
13202009-11-09 Robert Millan <rmh.grub@aybabtu.com>
1321
1322 * normal/auth.c: Include `<grub/time.h>'.
1323 (grub_auth_strcmp): Replace `strcmp' with `grub_strcmp'.
1324
3fd6f044
RM
13252009-11-09 Robert Millan <rmh.grub@aybabtu.com>
1326
1327 * normal/auth.c (punishment_delay): New variable.
1328 (grub_auth_strcmp): Rewrite using grub_get_time_ms ().
1329 (grub_auth_check_authentication): Punish failed login attempts with
1330 an incremental (2^N) delay.
1331
a4cd68e4
RM
13322009-11-09 Robert Millan <rmh.grub@aybabtu.com>
1333
1334 * conf/common.rmk (grub_mkisofs_CFLAGS): Prefix include
1335 path with $(srcdir).
1336
7ad12f43
VS
13372009-11-09 Vladimir Serbinenko <phcoder@gmail.com>
1338
1339 * normal/auth.c (grub_auth_strcmp): Fixed incorrect variable usage.
1340
c1129f03
RM
13412009-11-09 Robert Millan <rmh.grub@aybabtu.com>
1342
1343 * util/i386/coreboot/grub-mkrescue.in: New file.
1344 * conf/i386-coreboot.rmk (bin_SCRIPTS, grub_mkrescue_SOURCES): New
1345 variables.
1346
1347 * conf/common.rmk (bin_UTILITIES): Add `grub-mkisofs'.
1348 (grub_mkisofs_SOURCES, grub_mkisofs_CFLAGS): New variables.
1349 * configure.ac: Add header and function checks to satisfy grub-mkisofs
1350 requirements.
1351 * util/mkisofs/defaults.h: New file.
1352 * util/mkisofs/eltorito.c: Likewise.
1353 * util/mkisofs/exclude.h: Likewise.
1354 * util/mkisofs/fnmatch.c: Likewise.
1355 * util/mkisofs/getopt.c: Likewise.
1356 * util/mkisofs/getopt1.c: Likewise.
1357 * util/mkisofs/hash.c: Likewise.
1358 * util/mkisofs/include/fctldefs.h: Likewise.
1359 * util/mkisofs/include/mconfig.h: Likewise.
1360 * util/mkisofs/include/prototyp.h: Likewise.
1361 * util/mkisofs/include/statdefs.h: Likewise.
1362 * util/mkisofs/iso9660.h: Likewise.
1363 * util/mkisofs/joliet.c: Likewise.
1364 * util/mkisofs/match.c: Likewise.
1365 * util/mkisofs/match.h: Likewise.
1366 * util/mkisofs/mkisofs.c: Likewise.
1367 * util/mkisofs/mkisofs.h: Likewise.
1368 * util/mkisofs/multi.c: Likewise.
1369 * util/mkisofs/name.c: Likewise.
1370 * util/mkisofs/rock.c: Likewise.
1371 * util/mkisofs/tree.c: Likewise.
1372 * util/mkisofs/write.c: Likewise.
1373
ec8bb77d
VS
13742009-11-09 Vladimir Serbinenko <phcoder@gmail.com>
1375
1376 * normal/auth.c (grub_auth_strcmp): Fix bug which resulted in function
1377 being insecure.
1378
3716b12c
RM
13792009-11-08 Robert Millan <rmh.grub@aybabtu.com>
1380
1381 * util/i386/pc/grub-mkrescue.in: Fix miss-identification as
1382 `grub-mkimage' (and use $0 when possible).
1383
b97b7b91
RM
13842009-11-08 Robert Millan <rmh.grub@aybabtu.com>
1385
1386 * kern/i386/multiboot_mmap.c (grub_machine_mmap_init): Improve
1387 error message for excessively large memory map.
1388
04114812
RM
13892009-11-08 Robert Millan <rmh.grub@aybabtu.com>
1390
1391 * autogen.sh: Use `sh gendistlist.sh' to avoid reliing on
1392 executable bit.
1393
e4eb2373
RM
13942009-11-08 Robert Millan <rmh.grub@aybabtu.com>
1395
1396 * kern/i386/multiboot_mmap.c (grub_machine_mmap_init): Improve error
1397 message for coreboot users.
1398
c926e1d5 13992009-11-07 Robert Millan <rmh.grub@aybabtu.com>
1400
1401 Fix build with GNU gold.
1402
1403 * conf/i386-pc.rmk (boot_img_LDFLAGS, pxeboot_img_LDFLAGS)
1404 (diskboot_img_LDFLAGS, lnxboot_img_LDFLAGS)
1405 (cdboot_img_LDFLAGS): Prepend `0x' qualifier to hexadecimal
1406 link addresses.
1407 * aclocal.m4: Likewise.
1408
86e5b1db 14092009-11-04 Felix Zielcke <fzielcke@z-51.de>
1410
1411 * configure.ac (AC_PREREQ): Bump to 2.59d.
1412 * INSTALL: Make it more clear when Autoconf and Ruby are
1413 needed and when to run `./autogen.sh'.
1414
246cd78f 14152009-11-03 Samuel Thibault <samuel.thibault@ens-lyon.org>
1416
1417 * util/grub.d/30_os-prober.in: Restore default behavior for unsupported
1418 OSes.
1419
4f9dfb37 14202009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
1421
1422 * util/grub.d/30_os-prober.in: Add GNU/Hurd support
1423
b82bd5e1 14242009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
1425
1426 * util/grub.d/10_hurd.in: Drop /dev/ prefix from root device path before
1427 giving it to GNU Mach.
1428
ff1a9bca 14292009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
1430
1431 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): Subtract 1 from
1432 GNU partition number to get internal GRUB partition number.
1433
61697d9c 14342009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
1435
1436 * util/grub.d/10_hurd.in: Call prepare_grub_to_access_device
1437 ${GRUB_DEVICE_BOOT} before loading /boot kernel.
1438
a50569e1 14392009-11-01 Robert Millan <rmh.grub@aybabtu.com>
1440
1441 Based on patch from BVK Chaitanya <bvk.groups@gmail.com>
1442 * kern/misc.c (grub_strchr, grub_strrchr): Fix to handle c == '\0'
1443 case.
1444
5b153867 14452009-11-01 Felix Zielcke <fzielcke@z-51.de>
1446
1447 * Makefile.in (TARGET_CPPFLAGS): Add `-I$(srcdir)/include'.
1448
d9e2cd70 14492009-10-30 Robert Millan <rmh.grub@aybabtu.com>
1450
1451 Fix build problem.
1452
1453 * Makefile.in (TARGET_CPPFLAGS): Replace `-nostdinc' with
1454 `-isystem=$(srcdir)/include'.
1455
805111a4 14562009-10-30 Robert Millan <rmh.grub@aybabtu.com>
1457
1458 * util/i386/pc/grub-install.in: Remove hint that device.map should be
1459 checked (grub-install doesn't currently rely on it).
1460
fa6e945f 14612009-10-29 Robert Millan <rmh.grub@aybabtu.com>
1462
1463 Revert SVN r2660.
1464
1465 * conf/common.rmk (script/sh/lexer.c_DEPENDENCIES): Moved from here ...
1466 * conf/i386-coreboot.rmk (script/sh/lexer.c_DEPENDENCIES): ... to here.
1467 * conf/i386-efi.rmk (script/sh/lexer.c_DEPENDENCIES): ... and here.
1468 * conf/i386-ieee1275.rmk: Likewise.
1469 * conf/i386-pc.rmk: Likewise.
1470 * conf/powerpc-ieee1275.rmk: Likewise.
1471 * conf/sparc64-ieee1275.rmk: Likewise.
1472 * conf/x86_64-efi.rmk: Likewise.
1473
cee15086 14742009-10-28 Robert Millan <rmh.grub@aybabtu.com>
1475
1476 * Makefile.in (TARGET_CPPFLAGS): Add `-nostdinc'.
1477
95b9239e 14782009-10-28 Robert Millan <rmh.grub@aybabtu.com>
1479
1480 * include/grub/misc.h: Stop checking for APPLE_CC.
1481
2ed19dfd 14822009-10-28 Robert Millan <rmh.grub@aybabtu.com>
1483
1484 * kern/i386/coreboot/init.c (grub_exit): Reimplement in a way that
1485 doesn't cause an infinite call loop.
1486
fdcdde19 14872009-10-28 Felix Zielcke <fzielcke@z-51.de>
1488
1489 * commands/acpi.c (grub_cmd_acpi): Fix the out of memory error
1490 strings.
1491
cefabfe1 14922009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1493
1494 * autogen.sh: Support addition of external modules via `GRUB_CONTRIB'
1495 variable.
1496 * Makefile.in: Likewise.
1497
ed96ab6d 14982009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1499
1500 * gendistlist.sh: Simplify .svn check. Skip .bzr as well.
1501
0579b753 15022009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1503
1504 * Makefile.in (RMKFILES): Rewrite using $(wildcard).
1505
478df409 15062009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1507
1508 * disk/scsi.c: Remove `<grub/machine/kernel.h>' (not needed).
1509
083d1679 15102009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1511
1512 * gensymlist.sh.in (COMPILE_TIME_ASSERT): Copy macro declaration
1513 from here ...
1514 * include/grub/misc.h (COMPILE_TIME_ASSERT): ... to here.
1515
5947ae32 15162009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1517
1518 * Makefile.in (docs/grub.info): Use make syntax to ignore errors
1519 in $(MAKEINFO) invocation. This makes it clear in output that
1520 errors are being ignored.
1521
94180ff6 15222009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1523
1524 * conf/i386-coreboot.rmk (script/sh/lexer.c_DEPENDENCIES): Moved
1525 from here ...
1526 * conf/common.rmk (script/sh/lexer.c_DEPENDENCIES): ... to here.
1527 * conf/i386-efi.rmk (script/sh/lexer.c_DEPENDENCIES): Remove.
1528 * conf/i386-ieee1275.rmk: Likewise.
1529 * conf/i386-pc.rmk: Likewise.
1530 * conf/powerpc-ieee1275.rmk: Likewise.
1531 * conf/sparc64-ieee1275.rmk: Likewise.
1532 * conf/x86_64-efi.rmk: Likewise.
1533
9031b03a 15342009-10-26 Colin Watson <cjwatson@ubuntu.com>
1535
1536 * util/grub-editenv.c (main): If only a command is given, use
1537 DEFAULT_DIRECTORY "/" GRUB_ENVBLK_DEFCFG as a default file name.
1538 (usage): FILENAME is now optional and has a default.
1539
e4f6809b 15402009-10-26 Colin Watson <cjwatson@ubuntu.com>
1541
1542 Improve grub-mkconfig performance when there are several menu
1543 entries on a single filesystem.
1544
1545 * util/grub.d/10_linux.in (linux_entry): Cache the output of
1546 prepare_grub_to_access_device.
1547 * util/grub.d/10_kfreebsd.in (kfreebsd_entry): Likewise.
1548 * util/grub.d/30_os-prober.in: Likewise.
1549
67937d4d 15502009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1551
1552 * util/grub.d/10_freebsd.in: Remove.
1553 * util/grub.d/10_kfreebsd.in: New file (based on 10_linux.in).
1554 * configure.ac: Set host_kernel=kfreebsd for FreeBSD and GNU/kFreeBSD.
1555
ee3756cc 15562009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1557
5c35048e 1558 * docs/grub.cfg: Fix example usage of *BSD loaders.
ee3756cc 1559
4dea1c6f 15602009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1561
1562 * util/i386/pc/grub-setup.c (setup): Add missing parameter to
1563 grub_util_error() call.
1564
042484d7 15652009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1566
1567 * include/grub/fs.h [GRUB_UTIL] (struct grub_fs): Add
1568 `reserved_first_sector' member.
1569 * fs/ext2.c [GRUB_UTIL] (grub_ext2_fs): Initialize
1570 `reserved_first_sector' to 1.
1571 * fs/fat.c [GRUB_UTIL] (grub_fat_fs): Likewise.
1572 * fs/ntfs.c [GRUB_UTIL] (grub_ntfs_fs): Likewise.
1573 * fs/hfsplus.c [GRUB_UTIL] (grub_hfsplus_fs): Likewise.
1574 * util/i386/pc/grub-setup.c (setup): Add safety check that probes for
1575 filesystems which begin at first sector.
1576 (options): New option --skip-fs-probe.
1577 (main): Handle --skip-fs-probe and pass it to setup().
1578
d64448a7 15792009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1580
1581 * include/grub/misc.h: Fix wrong evaluation of APPLE_CC.
1582 (memset): Fix function prototype.
1583
508d42ec 15842009-10-25 Robert Millan <rmh.grub@aybabtu.com>
15852009-10-25 Vasily Averin <vvs@parallels.com>
1586
1587 * fs/ext2.c (grub_ext2_iterate_dir): Avoid infinite loop when
1588 `dirent.direntlen == 0'.
1589
b240e30c 15902009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1591
1592 * fs/cpio.c [MODE_USTAR]: Initialize `tar' module instead of
1593 `cpio'.
1594 [! MODE_USTAR]: Initialize `cpio' module instead of `tar'.
1595
346e7fbe 15962009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1597
1598 * configure.ac: Check for `__ashldi3', `__ashrdi3', `__lshrdi3',
1599 `__trampoline_setup' and `__ucmpdi2'.
1600 * include/grub/powerpc/libgcc.h: Only export symbols for functions
1601 that libgcc provides.
1602
cdb308b0 16032009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1604
1605 * include/grub/powerpc/libgcc.h (memset): Remove function prototype.
1606 * include/grub/sparc64/libgcc.h (memset): Likewise.
1607 * include/grub/misc.h (memset, memcmp): New function prototypes.
1608
fb26abc2 16092009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1610
1611 * fs/cpio.c [MODE_USTAR]: Finish `tar' module instead of
1612 `cpio'.
1613 [! MODE_USTAR]: Finish `cpio' module instead of `tar'.
1614
f6693890 16152009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1616
1617 Patch from Samuel Thibault <samuel.thibault@ens-lyon.org>
1618 * docs/grub.cfg: Compensate for recent change in multiboot
1619 loader (since 2009-08-14 it won't pass filename to payload).
1620 * util/grub.d/10_hurd.in: Likewise.
1621
0933cdc0 16222009-10-21 Felix Zielcke <fzielcke@z-51.de>
1623
1624 * config.guess: Update to latest version from config git
1625 repository.
1626 * config.sub: Likewise.
1627
3b2fe8c2 16282009-10-20 Robert Millan <rmh.grub@aybabtu.com>
1629
1630 Fix build on sparc64.
1631
1632 * configure.ac: Perform checks for libgcc symbols before
1633 adding `-nostdlib' to LDFLAGS.
1634
46695a62 16352009-10-16 Vladimir Serbinenko <phcoder@gmail.com>
1636
1637 Let user specify OpenBSD root device.
1638
1639 * loader/i386/bsd.c (openbsd_root): New variable.
1640 (openbsd_opts): New option 'root'.
1641 (OPENBSD_ROOT_ARG): New macro.
1642 (grub_openbsd_boot): Use 'openbsd_root'.
1643 (grub_cmd_openbsd): Fill 'openbsd_root'.
1644
d2b6b7fc 16452009-10-16 Robert Millan <rmh.grub@aybabtu.com>
1646
1647 * NEWS: Misc adjustments.
1648
421bd7ac 16492009-10-16 Vladimir Serbinenko <phcoder@gmail.com>
1650
1651 * NEWS: Mentioned XNU, ACPI, gptsync, password and parttool.
1652
f1d29d87 16532009-10-16 Robert Millan <rmh.grub@aybabtu.com>
1654
1655 * configure.ac: Bump version to 1.97.
1656
6f3cd880 16572009-10-16 Colin Watson <cjwatson@ubuntu.com>
1658
1659 * configure.ac (TARGET_CFLAGS): Add -mno-mmx -mno-sse -mno-sse2
1660 -mno-3dnow on x86 architectures. Some toolchains enable these
1661 features by default, but they rely on registers that aren't enabled
1662 in GRUB. Thanks to Vladimir Serbinenko for the suggestion.
1663
035f7122 16642009-10-15 Robert Millan <rmh.grub@aybabtu.com>
1665
1666 Make entry text a bit more readable.
1667
1668 * util/grub.d/10_linux.in: Add `with' before `Linux'.
1669
44998e58 16702009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
1671
1672 * loader/i386/pc/xnu.c (grub_xnu_set_video): Fix loading splash image.
1673
cd2851b3 16742009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
1675
1676 * commands/xnu_uuid.c (grub_cmd_xnu_uuid): Remove duplicated bitwise
1677 operations.
1678
c6f3b249 16792009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
1680
1681 * configure.ac: Add missing dollar.
1682
6b5886ba 16832009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
1684
1685 Revert 2009-06-10 Pavel Roskin <proski@gnu.org>
1686
1687 * configure.ac: Put checks for __bswapsi2 and __bswapdi2.
1688 * include/grub/powerpc/libgcc.h: Don't use weak attribute for all
1689 exports.
1690 * include/grub/sparc64/libgcc.h: Likewise. Use
1691 preprocessor conditionals.
1692
e9d66f6d 16932009-10-14 Robert Millan <rmh.grub@aybabtu.com>
1694
1695 * conf/common.rmk (grub-dumpbios): Remove rule.
1696 (sbin_SCRIPTS, CLEANFILES): Remove `grub-dumpbios'.
1697 * util/grub-dumpbios.in: Remove file.
1698
9155bc17 16992009-10-14 Robert Millan <rmh.grub@aybabtu.com>
1700
1701 Refer to kernel of FreeBSD "kFreeBSD" to avoid confusion between
1702 the Operating System (FreeBSD) and its kernel (kernel of FreeBSD).
1703
1704 * loader/i386/bsd.c (grub_freebsd_boot): Read kernel environment
1705 from "kFreeBSD" namespace (rather than "FreeBSD"). Update all
1706 users.
1707
1708 (GRUB_MOD_INIT (bsd)): Rename "freebsd" command to "kfreebsd",
1709 "openbsd" to "kopenbsd", "netbsd" to "knetbsd", "freebsd_loadenv"
1710 to "kfreebsd_loadenv", "freebsd_module" to "kfreebsd_module",
1711 and "freebsd_module_elf" to "kfreebsd_module_elf". Update all
1712 users.
1713
bf7f7a18 17142009-10-12 Robert Millan <rmh.grub@aybabtu.com>
1715
1716 * term/tparm.c: Switch to GPLv3.
1717
86564c26 17182009-10-09 Robert Millan <rmh.grub@aybabtu.com>
1719
1720 * include/grub/i386/cpuid.h: Add header protection.
1721
5c936493 17222009-10-09 Robert Millan <rmh.grub@aybabtu.com>
1723
1724 Fail gracefuly when attempting to load 64-bit kFreeBSD on IA32 CPU.
1725
1726 * include/grub/i386/cpuid.h: New file.
1727 * commands/i386/cpuid.c: Include `<grub/i386/cpuid.h>'.
1728 (has_longmode): Rename to ...
1729 (grub_cpuid_has_longmode): ... this. Update all users. Remove
1730 `static' attribute.
1731 * loader/i386/bsd.c: Include `<grub/i386/cpuid.h>'.
1732 (grub_bsd_load_elf): Fail if load of 64-bit kernel was requested
1733 on a CPU that doesn't implement AMD64 instruction set.
1734
186e7cf2 17352009-10-06 Colin Watson <cjwatson@ubuntu.com>
1736
1737 * Makefile.in (docs/stamp-vti): Depend on configure.ac as well, so
1738 that version.texi is rebuilt on version number changes.
1739
83b65c4a 17402009-10-06 Colin Watson <cjwatson@ubuntu.com>
1741
1742 * Makefile.in: Don't set info_INFOS unless makeinfo was found.
1743 Fixes bug #27602.
1744
d244281c 17452009-10-06 Colin Watson <cjwatson@ubuntu.com>
1746
1747 * util/i386/pc/grub-install.in: Source
1748 ${libdir}/grub/grub-mkconfig_lib before option processing, in order
1749 that the --grub-probe option will work.
1750 * util/sparc64/ieee1275/grub-install.in: Likewise.
1751
da25306d 17522009-10-05 Robert Millan <rmh.grub@aybabtu.com>
1753
1754 * configure.ac: Bump version to 1.97~beta4.
1755
e8ee83c0 17562009-10-03 Robert Millan <rmh.grub@aybabtu.com>
1757
1758 Resync grub-mkdevicemap in x86_64-efi.
1759
1760 * conf/x86_64-efi.rmk (sbin_UTILITIES): Enable `grub-mkdevicemap'.
1761 (grub_mkdevicemap_SOURCES): Add missing `util/deviceiter.c' and
1762 `util/devicemap.c'.
1763
50dcabcf 17642009-10-01 Colin Watson <cjwatson@ubuntu.com>
1765
1766 * util/grub-editenv.c (create_envblk_file): Write new block with a
1767 .new suffix and then rename it into place, to ensure atomic
1768 creation.
1769
0e51c3a7 17702009-09-28 Robert Millan <rmh.grub@aybabtu.com>
1771
1772 Do not automatically install headers.
1773
1774 * Makefile.in (include_DATA): Remove. Update all users.
1775
31299a95 17762009-09-26 Robert Millan <rmh.grub@aybabtu.com>
1777
1778 * conf/common.rmk (pkglib_MODULES): Remove `lua.mod'.
1779 (lua_mod_SOURCES, lua_mod_CFLAGS, lua_mod_LDFLAGS): Remove.
1780
1781 * util/osdetect.lua: Remove.
1782 * script/lua/lauxlib.c: Likewise.
1783 * script/lua/ldebug.c: Likewise.
1784 * script/lua/grub_main.c: Likewise.
1785 * script/lua/lauxlib.h: Likewise.
1786 * script/lua/ldebug.h: Likewise.
1787 * script/lua/ltablib.c: Likewise.
1788 * script/lua/liolib.c: Likewise.
1789 * script/lua/lstrlib.c: Likewise.
1790 * script/lua/lualib.h: Likewise.
1791 * script/lua/ldo.c: Likewise.
1792 * script/lua/ldump.c: Likewise.
1793 * script/lua/ldo.h: Likewise.
1794 * script/lua/loslib.c: Likewise.
1795 * script/lua/lundump.c: Likewise.
1796 * script/lua/grub_lib.c: Likewise.
1797 * script/lua/ldblib.c: Likewise.
1798 * script/lua/lundump.h: Likewise.
1799 * script/lua/lmem.c: Likewise.
1800 * script/lua/grub_lib.h: Likewise.
1801 * script/lua/lmathlib.c: Likewise.
1802 * script/lua/lstate.c: Likewise.
1803 * script/lua/ltm.c: Likewise.
1804 * script/lua/lvm.c: Likewise.
1805 * script/lua/lmem.h: Likewise.
1806 * script/lua/lstate.h: Likewise.
1807 * script/lua/ltm.h: Likewise.
1808 * script/lua/ltable.c: Likewise.
1809 * script/lua/lvm.h: Likewise.
1810 * script/lua/llex.c: Likewise.
1811 * script/lua/lgc.c: Likewise.
1812 * script/lua/grub_lua.h: Likewise.
1813 * script/lua/loadlib.c: Likewise.
1814 * script/lua/lfunc.c: Likewise.
1815 * script/lua/lopcodes.c: Likewise.
1816 * script/lua/lparser.c: Likewise.
1817 * script/lua/ltable.h: Likewise.
1818 * script/lua/llex.h: Likewise.
1819 * script/lua/lgc.h: Likewise.
1820 * script/lua/lfunc.h: Likewise.
1821 * script/lua/lbaselib.c: Likewise.
1822 * script/lua/lopcodes.h: Likewise.
1823 * script/lua/lparser.h: Likewise.
1824 * script/lua/lzio.c: Likewise.
1825 * script/lua/linit.c: Likewise.
1826 * script/lua/lobject.c: Likewise.
1827 * script/lua/llimits.h: Likewise.
1828 * script/lua/lstring.c: Likewise.
1829 * script/lua/lzio.h: Likewise.
1830 * script/lua/lapi.c: Likewise.
1831 * script/lua/lcode.c: Likewise.
1832 * script/lua/lua.h: Likewise.
1833 * script/lua/lobject.h: Likewise.
1834 * script/lua/lstring.h: Likewise.
1835 * script/lua/lapi.h: Likewise.
1836 * script/lua/lcode.h: Likewise.
1837 * script/lua/luaconf.h: Likewise.
1838
cb8a2c38 18392009-09-26 Colin Watson <cjwatson@ubuntu.com>
1840
1841 * docs/grub.texi (Command-line and menu entry commands): Document
1842 date and echo commands.
1843
6b9b6276 18442009-09-24 Pavel Roskin <proski@gnu.org>
1845
1846 * include/grub/kernel.h (struct grub_module_header): Remove
1847 `grub_module_header_types'. Make `type' unsigned. Make `size'
1848 32-bit on all platforms.
1849 * util/elf/grub-mkimage.c (load_modules): Treat `type' as an
1850 8-bit field. Use grub_host_to_target32() for `size'.
1851 * util/i386/efi/grub-mkimage.c (make_mods_section): Likewise.
1852 * util/i386/pc/grub-mkimage.c (generate_image): Likewise.
1853 * util/sparc64/ieee1275/grub-mkimage.c (generate_image): Likewise.
1854
4e5a02a7 18552009-09-24 Robert Millan <rmh.grub@aybabtu.com>
1856
1857 Fix "lost keypress" bug in at_keyboard.
1858
1859 * term/i386/pc/at_keyboard.c (grub_at_keyboard_checkkey): New function.
1860 Checks for readyness of input buffer (without flushing it).
1861 (grub_at_keyboard_term): Use grub_at_keyboard_checkkey() rather
1862 than grub_at_keyboard_getkey_noblock() for `checkkey' struct member.
1863
c6dcedf6 18642009-09-24 Robert Millan <rmh.grub@aybabtu.com>
1865
1866 * util/i386/pc/grub-mkimage.c (generate_image): Enclose BIOS-specific
1867 size check within GRUB_MACHINE_PCBIOS section.
1868
74c958b1 18692009-09-24 Robert Millan <rmh.grub@aybabtu.com>
1870
1871 * include/grub/i386/at_keyboard.h (KEYBOARD_ISREADY): Negate
1872 return value.
1873 * term/i386/pc/at_keyboard.c (grub_keyboard_getkey): Negate
1874 KEYBOARD_ISREADY check.
1875 (grub_at_keyboard_checkkey): Rename to ...
1876 (grub_at_keyboard_getkey_noblock): ... this. Update all users.
1877 Remove gratuitous cast.
1878
ff420223 18792009-09-23 Colin Watson <cjwatson@ubuntu.com>
1880
1881 * configure.ac: Call AC_PROG_MKDIR_P.
1882 * Makefile.in (docs/stamp-vti): Create docs directory. Create
1883 version.texi in $(builddir) rather than $(srcdir).
1884 (docs/grub.info): Create docs directory. Prepend $(builddir)/docs
1885 to makeinfo's @include search path.
1886
d96875df 18872009-09-23 Felix Zielcke <fzielcke@z-51.de>
1888
1889 * util/grub-mkconfig_lib.in (grub_file_is_not_garbage): Cope with `*.dpkg-*'
1890
9b3f8365 18912009-09-23 Felix Zielcke <fzielcke@z-51.de>
1892
1893 * util/grub-mkconfig_lib.in (grub_file_is_not_garbage): Add support
1894 for `*.dpkg-new'.
1895
c44c90db 18962009-09-21 Colin Watson <cjwatson@ubuntu.com>
1897
1898 Build info documentation. Some code borrowed from Automake.
1899
1900 * configure.ac: Check for makeinfo.
1901 * Makefile.in (MAKEINFO, INFOS, info_INFOS): New variables.
1902 (MAINTAINER_CLEANFILES): Add $(INFOS), docs/stamp-vti, and
1903 docs/version.texi.
1904 (MOSTLYCLEANFILES): Add vti.tmp.
1905 (docs/version.texi, docs/stamp-vti): Update automatically.
1906 (docs/grub.info): Build info documentation. Use --force and ignore
1907 errors for now.
1908 (all-local): Add $(INFOS).
1909 (install-local): Install info files.
1910 (uninstall): Uninstall info files.
1911 * docs/version.texi: Remove from revision control. This file is
1912 automatically generated on build now.
1913 * gendistlist.sh: Add `*.info'.
1914
e0b37bb5 19152009-09-21 Felix Zielcke <fzielcke@z-51.de>
1916
1917 * kern/term.c: Fix indentation.
1918
5a78865b 19192009-09-21 Felix Zielcke <fzielcke@z-51.de>
1920
1921 * util/hostdisk.c: Fix a comment.
1922
dace7e8a 19232009-09-20 Robert Millan <rmh.grub@aybabtu.com>
1924
1925 Fix regression introduced in r2539.
1926
1927 * term/usb_keyboard.c (USB_HID_DEVICE_TO_HOST): Change from 0x61
1928 to 0xA1.
1929
a83d079b 19302009-09-19 Colin Watson <cjwatson@ubuntu.com>
1931
1932 * util/grub.d/30_os-prober.in: Don't throw away stderr from
4cbbccec 1933 os-prober. Under normal operation, it does not print anything to
1934 stderr; if it does, we need to debug it, and throwing away stderr
1935 makes that excessively difficult.
a83d079b 1936
be94a509 19372009-09-16 Vladimir Serbinenko <phcoder@gmail.com>
1938
1939 * mmap/mmap.c (grub_cmd_badram): Fix off-by-one error.
1940
63f745e8 19412009-09-16 Robert Millan <rmh.grub@aybabtu.com>
1942
1943 * aclocal.m4 (AC_LANG_PROGRAM): New macro. Overrides stock
1944 AC_LANG_PROGRAM from autoconf.
1945 (grub_ASM_USCORE, grub_PROG_OBJCOPY_ABSOLUTE): Add missing
1946 prototypes (fixes warning).
1947
1948 * configure.ac: Add `-Werror' to TARGET_CFLAGS unless
1949 `--disable-werror' was used.
1950
bbb2a70f 19512009-09-16 Robert Millan <rmh.grub@aybabtu.com>
1952
1953 * partmap/msdos.c (pc_partition_map_iterate): Fix possible use of
1954 uninitialized `lastaddr'.
1955
77c24f1d 19562009-09-15 Vladimir Serbinenko <phcoder@gmail.com>
1957
0f0b8c87 1958 * partmap/msdos.c (pc_partition_map_iterate): Detect and break loops.
77c24f1d 1959
07197f23 19602009-09-14 Colin Watson <cjwatson@ubuntu.com>
1961
1962 * commands/test.c (get_fileinfo): Return immediately if
1963 grub_fs_probe fails.
1964
dabf1798 19652009-09-14 José Martínez <xosemp@gmail.com>
1966
1967 * commands/acpi.c (grub_cmd_acpi): Fix loading ACPI tables from file.
1968
d52109a7 19692009-09-14 Colin Watson <cjwatson@ubuntu.com>
1970
1971 * util/grub.d/30_os-prober.in: Cope with Windows 7 in os-prober
1972 output.
1973
56532179 19742009-09-13 Robert Millan <rmh.grub@aybabtu.com>
1975
1976 * configure.ac: Remove --enable-grub-pe2elf. Only build
1977 grub-pe2elf when needed by the build system itself.
1978 * conf/common.rmk: Remove $(enable_grub_pe2elf) check.
1979
8ef070f5 19802009-09-12 Robert Millan <rmh.grub@aybabtu.com>
1981
1982 * configure.ac: Bump version to 1.97~beta3.
1983 * docs/version.texi: Likewise.
1984
61229557 19852009-09-12 Robert Millan <rmh.grub@aybabtu.com>
1986
1987 * video/i386/pc/vbe.c (grub_vbe_get_video_mode_info): Move packed
1988 mode special handling (grub_vbe_bios_set_dac_palette_width() call)
1989 from here ...
1990 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS]
1991 (grub_linux_setup_video): ... to here (with some adjustments).
1992
5c9f8d84 19932009-09-12 Robert Millan <rmh.grub@aybabtu.com>
1994
1995 Fix memory corruption issue (spotted by Colin Watson).
1996
1997 * kern/i386/pc/startup.S (grub_vbe_bios_getset_dac_palette): Fix bug
1998 causing returned size to be stored in an incorrect memory location.
1999 Fix use of uninitialized value when storing the returned size.
2000
e8f5d6e9 20012009-09-12 Yves Blusseau <blusseau@zetam.org>
2002
2003 Change clean rules to properly remove files
2004
2005 * genmk.rb: add new clean rules
2006 * Makefile.in (clean): add the new targets
2007 (mostlyclean): likewise
2008
cda2a409 20092009-09-11 Colin Watson <cjwatson@ubuntu.com>
2010
2011 * include/grub/ntfs.h (struct grub_fshelp_node): Change `size'
2012 to grub_uint64_t.
2013 * fs/ntfs.c (init_file): Understand 64-bit sizes for
2014 non-resident files.
2015
86695375 20162009-09-11 Colin Watson <cjwatson@ubuntu.com>
2017
2018 * configure.ac: Don't look for help2man when cross-compiling. Fixes
2019 part of bug #27349.
2020
8aa1541a 20212009-09-10 Felix Zielcke <fzielcke@z-51.de>
2022
2023 * util/grub-mkconfig.in: Make the created config mode 400 and
2024 print a warning if it fails.
2025
48d9bb0a 20262009-09-10 Robert Millan <rmh.grub@aybabtu.com>
2027
2028 * util/grub.d/40_custom.in: Ask user to type custom entries below
2029 comment, rather than below 'exec tail' line.
2030
3b0521be 20312009-09-10 Colin Watson <cjwatson@ubuntu.com>
2032
2033 * util/grub.d/40_custom.in: Make sure that the explanatory text is
2034 visible in grub.cfg.
2035
50051d55 20362009-09-10 Colin Watson <cjwatson@ubuntu.com>
2037
2038 * util/grub.d/40_custom.in: Make it a little clearer how to use this
2039 file.
2040
c0d34387 20412009-09-10 Felix Zielcke <fzielcke@z-51.de>
2042
2043 * docs/grub.cfg: Add an example menu entry for memtest86+.
2044
80a608f3 20452009-09-09 Felix Zielcke <fzielcke@z-51.de>
2046
a2094832 2047 * config.guess: Update to latest version from config git.
80a608f3 2048 * config.sub: Likewise.
2049
99423078 20502009-09-08 Colin Watson <cjwatson@ubuntu.com>
2051
2052 * script/sh/execute.c (grub_script_execute_cmdline): Set "?" in
2053 unknown-command case. Fixes bug #27320.
2054
44454e4c 20552009-09-08 Felix Zielcke <fzielcke@z-51.de>
2056
2057 * kern/rescue_parser.c (grub_rescue_parse_line): Only suggest to try
2058 `help' if the command exists.
2059
e30d87ad 20602009-09-06 Robert Millan <rmh.grub@aybabtu.com>
2061
2062 * INSTALL: Require GCC 4.1.3 or later.
2063
9a86f1ec 20642009-09-06 Yves Blusseau <blusseau@zetam.org>
2065
2066 * Makefile.in (RMKFILES): add i386-qemu.rmk
2067 (MAINTAINER_CLEANFILES): add $(srcdir)/DISTLIST $(srcdir)/config.h.in
2068 $(srcdir)/stamp-h.in
2069
7f26d466 20702009-09-05 Robert Millan <rmh.grub@aybabtu.com>
2071
2072 * util/grub-probe.c (probe): Comment out buggy codepath, which
2073 was unexpectedly enabled by Colin Watson's 2009-09-02 fix. This
2074 should be re-enabled after 1.97.
2075
3a613259 20762009-09-05 Felix Zielcke <fzielcke@z-51.de>
2077
2078 * gendistlist.sh: Add `grub-dumpdevtree' and `*.lua' to the list
2079 find searches for.
2080
197f76c7 20812009-09-04 Vladimir Serbinenko <phcoder@gmail.com>
2082
2083 * loader/i386/xnu.c (grub_cpu_xnu_fill_devicetree): Remove
2084 unnecessary calls to grub_error.
2085
70ba68ce 20862009-09-04 Colin Watson <cjwatson@ubuntu.com>
2087
2088 * NEWS: Mention `keystatus' and Unicode fonts.
2089
4ff0d7a4 20902009-09-04 Robert Millan <rmh.grub@aybabtu.com>
2091
2092 * configure.ac: Bump version to 1.97~beta2.
2093 * docs/version.texi: Likewise.
2094
77c55a87 20952009-09-03 Colin Watson <cjwatson@ubuntu.com>
2096
2097 * configure.ac: By default, GCC 4.4 generates .eh_frame sections
2098 containing unwind information in some cases where it previously did
2099 not. Use -fno-dwarf2-cfi-asm if available to restore the old
2100 behaviour. See http://patchwork.kernel.org/patch/8555/ for related
2101 discussion.
2102
f79572cd 21032009-09-02 Yves BLUSSEAU <blusseau@zetam.org>
2104
2105 Embedding loadenv module into grub-emu
2106
2107 * conf/i386-pc.rmk (grub_emu_SOURCES): add lib/envblk.c and
2108 commands/loadenv.c
2109 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise
2110 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise
2111 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise
2112 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise
2113 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise
2114 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise
2115
93a81088 21162009-09-03 Magnus Granberg <zorry@ume.nu>
2117
2118 * aclocal.m4: Add grub_CHECK_PIE. It check if the compiler
2119 include -fPIE in the default specs.
2120 * configure.ac: Check if pie_possible is yes and add -fno-PIE
2121 to TARGET_CFLAGS.
2122
160034b2 21232009-09-03 Felix Zielcke <fzielcke@z-51.de>
2124
2125 * INSTALL: Note that GNU Bison 2.3 or later is required.
2126
087c07c4 21272009-09-03 Colin Watson <cjwatson@ubuntu.com>
2128
2129 * kern/i386/pc/startup.S: Fix typo.
2130
cbf978c0 21312009-09-02 Vladimir Serbinenko <phcoder@gmail.com>
2132
2133 * efiemu/loadcore.c (SUFFIX (grub_efiemu_loadcore_load)): Fix style
2134 according to GCS.
2135
21362009-09-02 Colin Watson <cjwatson@ubuntu.com>
f0910644 2137
2138 * docs/grub.texi (Naming convention): Describe one-based partition
2139 numbering.
2140 (Device syntax): Likewise.
2141 (File name syntax): Likewise.
2142 (Block list syntax): Likewise.
2143 (Making a GRUB bootable CD-ROM): Talk about grub.cfg rather than
2144 menu.lst.
2145 (File name syntax): Likewise.
2146 (Command-line and menu entry commands): Document acpi, blocklist,
2147 crc, export, insmod, keystatus, ls, set, and unset commands.
2148
f3e8cdfd 21492009-09-02 Colin Watson <cjwatson@ubuntu.com>
2150
2151 * commands/keystatus.c (GRUB_MOD_INIT (keystatus)): Adjust summary
2152 to avoid implying that only one of --shift, --ctrl, or --alt may be
2153 used.
2154
c0bc232b 21552009-09-02 Colin Watson <cjwatson@ubuntu.com>
2156
2157 * util/grub-probe.c (probe): Test st.st_mode using S_ISREG macro
2158 rather than comparing against S_IFREG, which will almost never work.
2159
aa0f752d 21602009-09-01 Vladimir Serbinenko <phcoder@gmail.com>
2161
2162 * commands/loadenv.c (check_blocklists): Fix off-by-one error.
2163 (write_blocklists): Likewise.
2164
ecb3166a 21652009-09-01 Colin Watson <cjwatson@ubuntu.com>
2166
2167 * script/lua/grub_lua.h (fputs): Supply a format string as the first
2168 argument to grub_printf.
2169
c403a125 21702009-09-01 Felix Zielcke <fzielcke@z-51.de>
31aba781 2171
2172 * genmk.rb: Add quotes around $(TARGET_OBJ2ELF) to cope with
c403a125 2173 non GNU test.
31aba781 2174
b5e7312c 21752009-08-30 Vladimir Serbinenko <phcoder@gmail.com>
2176
2177 * kern/file.c (grub_file_read): Spelling fix
2178
fe00f472 21792009-08-30 Vladimir Serbinenko <phcoder@gmail.com>
2180
2181 * loader/i386/bsdXX.c (SUFFIX (grub_freebsd_load_elfmodule)): Fix
2182 loading of headers in some cases.
2183
cc55302e 21842009-08-30 Robert Millan <rmh.grub@aybabtu.com>
2185
2186 * configure.ac: Bump version to 1.97~beta1.
2187 * docs/version.texi: Likewise.
2188
5c90cdd2 21892009-08-29 Vladimir Serbinenko <phcoder@gmail.com>
64bf71d0 2190
2191 * include/grub/i386/xnu.h: Add license header.
2192 include grub/err.h explicitly.
2193
c90edae4 21942009-08-29 Robert Millan <rmh.grub@aybabtu.com>
2195
2196 * util/grub.d/10_freebsd.in: Detect `ufs1' and `ufs2' and map them
2197 to `ufs' in the vfs.root.mountfrom kernel parameter.
2198
d8888b5c 21992009-08-29 Robert Millan <rmh.grub@aybabtu.com>
2200
2201 * term/i386/pc/serial.c: Include `<grub/machine/memory.h>'.
2202
2203 [GRUB_MACHINE_PCBIOS] (serial_hw_io_addr): Macroify initialization
2204 value (0x0400 -> GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR).
2205
2206 [! GRUB_MACHINE_PCBIOS] (GRUB_SERIAL_PORT_NUM): Calculate using
2207 `ARRAY_SIZE' macro.
2208
6f07b921 22092009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
2210
2211 * kern/file.c (grub_file_read): Check offset.
2212 * fs/hfs.c (grub_hfs_read_file): Remove unnecessary offset check.
2213 * fs/jfs.c (grub_jfs_read_file): Likewise.
2214 * fs/ntfs.c (grub_ntfs_read): Likewise.
2215 * fs/reiserfs.c (grub_reiserfs_read): Likewise.
2216 * fs/minix.c (grub_minix_read_file): Correct offset check.
2217 * fs/ufs.c (grub_ufs_read_file): Likewise.
2218
b4f34077 22192009-08-28 Colin Watson <cjwatson@ubuntu.com>
2220
2221 * term/i386/pc/console.c (bios_data_area): Cast
2222 GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR explicitly.
2223
e7c69859 22242009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
2225
2226 1-bit optimised blitters.
2227
2228 * include/grub/fbblit.h (grub_video_fbblit_replace_32bit_1bit): New
2229 prototype.
2230 (grub_video_fbblit_replace_24bit_1bit): Likewise.
2231 (grub_video_fbblit_replace_16bit_1bit): Likewise.
2232 (grub_video_fbblit_replace_8bit_1bit): Likewise.
2233 (grub_video_fbblit_blend_XXXA8888_1bit): Likewise.
2234 (grub_video_fbblit_blend_XXX888_1bit): Likewise.
2235 (grub_video_fbblit_blend_XXX565_1bit): Likewise.
2236 * video/fb/fbblit.c (grub_video_fbblit_replace_32bit_1bit): New
2237 function.
2238 (grub_video_fbblit_replace_24bit_1bit): Likewise.
2239 (grub_video_fbblit_replace_16bit_1bit): Likewise.
2240 (grub_video_fbblit_replace_8bit_1bit): Likewise.
2241 (grub_video_fbblit_blend_XXXA8888_1bit): Likewise.
2242 (grub_video_fbblit_blend_XXX888_1bit): Likewise.
2243 (grub_video_fbblit_blend_XXX565_1bit): Likewise.
2244 * video/fb/video_fb.c (common_blitter): Use 1-bit optimised blitters
2245 when possible.
2246 * video/video.c (grub_video_get_blit_format): Return
2247 GRUB_VIDEO_BLIT_FORMAT_1BIT_PACKED if bpp = 1.
2248
a57da43f 22492009-08-28 Colin Watson <cjwatson@ubuntu.com>
2250
2251 * normal/cmdline.c (grub_cmdline_get): Supply a format string as
2252 the first argument to grub_printf.
2253
4cbe67e5 22542009-08-28 Colin Watson <cjwatson@ubuntu.com>
22552009-08-28 Robert Millan <rmh.grub@aybabtu.com>
2256
2257 Add `getkeystatus' terminal method. Add a new `keystatus' command
2258 to query it.
2259
2260 * include/grub/term.h (GRUB_TERM_STATUS_SHIFT,
2261 GRUB_TERM_STATUS_CTRL, GRUB_TERM_STATUS_ALT): Definitions for
2262 modifier key bitmasks.
2263 (struct grub_term_input): Add `getkeystatus' member.
2264 (grub_getkeystatus): Add prototype.
2265 * kern/term.c (grub_getkeystatus): New function.
2266
2267 * include/grub/i386/pc/memory.h
2268 (GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR): New macro.
2269 (struct grub_machine_bios_data_area): Define necessary parts of BIOS
2270 Data Area layout.
2271 * term/i386/pc/console.c (grub_console_getkeystatus): New function.
2272 (grub_console_term_input): Set `getkeystatus' member.
2273 * term/usb_keyboard.c (grub_usb_hid): Macroify HID protocol
2274 constants.
2275 (grub_usb_keyboard_getreport): Likewise.
2276 (grub_usb_keyboard_checkkey): Likewise.
2277 (grub_usb_keyboard_getkeystatus): New function.
2278 (grub_usb_keyboard_term): Set `getkeystatus' member.
2279
2280 * commands/keystatus.c: New file.
2281 * conf/common.rmk (pkglib_MODULES): Add keystatus.mod.
2282 (keystatus_mod_SOURCES): New variable.
2283 (keystatus_mod_CFLAGS): Likewise.
2284 (keystatus_mod_LDFLAGS): Likewise.
2285 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add
2286 commands/keystatus.c.
2287 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
2288 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2289 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
2290 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2291 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2292 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
4cbe67e5 2293
6e2a9085 22942009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
2295
2296 Split befs.mod and afs.mod into *_be.mod and *.mod
2297
2298 * conf/common.rmk (grub_probe_SOURCES): Add afs_be.c and befs_be.c.
2299 (grub_fstest_SOURCES): Likewise.
2300 (pkglib_MODULES): Add afs_be.mod and befs_be.mod.
2301 (afs_be_mod_SOURCES): New variable.
2302 (afs_be_mod_CFLAGS): Likewise.
2303 (afs_be_mod_LDFLAGS): Likewise.
2304 (befs_be_mod_SOURCES): Likewise.
2305 (befs_be_mod_CFLAGS): Likewise.
2306 (befs_be_mod_LDFLAGS): Likewise.
2307 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add afs_be.c and befs_be.c.
2308 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
2309 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2310 * conf/i386-pc.rmk (grub_setup_SOURCES): Likewise.
2311 (grub_emu_SOURCES): Likewise.
2312 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2313 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2314 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
2315 * fs/afs_be.c: New file.
2316 * fs/befs_be.c: New file.
2317 * fs/afs.c (GRUB_AFS_FSNAME_SUFFIX): New definition.
2318 (GRUB_AFS_FSNAME): Use GRUB_AFS_FSNAME_SUFFIX.
2319 (U16): Replaced with ...
2320 (grub_afs_to_cpu16): ...this. All users updated.
2321 (U32): Replaced with ...
2322 (grub_afs_to_cpu32): ...this. All users updated.
2323 (U64): Replaced with ...
2324 (grub_afs_to_cpu64): ...this. All users updated.
2325 (GRUB_AFS_BO_LITTLE_ENDIAN): Remove.
2326 (GRUB_AFS_BO_BIG_ENDIAN): Likewise.
ad8ea1f4 2327 (grub_afs_validate_sblock): Check only one endianness.
6e2a9085 2328 (GRUB_MOD_INIT (befs)) [MODE_BIGENDIAN && MODE_BFS]: Rename to ..
2329 (GRUB_MOD_INIT (befs_be)) [MODE_BIGENDIAN && MODE_BFS]: ... this.
2330 (GRUB_MOD_INIT (afs)) [MODE_BIGENDIAN && !MODE_BFS]: Rename to ..
2331 (GRUB_MOD_INIT (afs_be)) [MODE_BIGENDIAN && !MODE_BFS]: ... this.
2332 (GRUB_MOD_FINI (befs)) [MODE_BIGENDIAN && MODE_BFS]: Rename to ..
2333 (GRUB_MOD_FINI (befs_be)) [MODE_BIGENDIAN && MODE_BFS]: ... this.
2334 (GRUB_MOD_FINI (afs)) [MODE_BIGENDIAN && !MODE_BFS]: Rename to ..
2335 (GRUB_MOD_FINI (afs_be)) [MODE_BIGENDIAN && !MODE_BFS]: ... this.
2336
32a71655 23372009-08-26 Bean <bean123ch@gmail.com>
2338
2339 * fs/xfs.c (GRUB_XFS_INO_INOINAG): Replace 1L with 1LL to support
2340 64-bit number.
2341 (GRUB_XFS_FSB_TO_BLOCK): Likewise.
2342 (grub_xfs_inode_block): Change return type to grub_uint64_t.
2343 (grub_xfs_read_inode): Change type of block to grub_uint64_t.
2344
552bf6c5 23452009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
2346
2347 NetBSD memory map support.
2348
2349 * include/grub/i386/bsd.h (NETBSD_BTINFO_MEMMAP): New definition.
2350 (grub_netbsd_btinfo_mmap_header): New structure.
2351 (grub_netbsd_btinfo_mmap_entry): Likewise.
2352 * loader/i386/bsd.c (grub_netbsd_boot): Pass memory map.
2353
1ae2078c 23542009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
2355
2356 Enable bsd.mod on coreboot.
2357
2358 * conf/i386-coreboot.rmk (pkglib_MODULES): Add bsd.mod.
2359 (bsd_mod_SOURCES): New variable.
2360 (bsd_mod_CFLAGS): Likewise.
2361 (bsd_mod_LDFLAGS): Likewise.
2362 (bsd_mod_ASFLAGS): Likewise.
2363 * loader/i386/bsd.c [!GRUB_MACHINE_PCBIOS]: Fix includes.
2364 (grub_bsd_get_device) [!GRUB_MACHINE_PCBIOS]: Set *biosdev to 0xff.
2365
beefc598 23662009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
2367
2368 Cleanup NetBSD root support.
2369
2370 * loader/i386/bsd.c (grub_netbsd_boot): Remove call to
2371 grub_bsd_get_device.
2372 Fix typo.
2373
3b76e68b 23742009-08-25 Felix Zielcke <fzielcke@z-51.de>
2375
2376 * util/grub.d/00_header.in: Move check for the video backend of
2377 gfxterm from here ...
2378 * util/grub-mkconfig.in: ... to here. Enable gfxterm if there's
2379 a suitable video backend.
2380
aea664ea 23812009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
2382
2383 Fix breakage in grub-setup.
2384
2385 * util/i386/pc/grub-setup.c (setup): Use "part_msdos" instead of
2386 "msdos_partition_map".
2387
ff747d50 23882009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
2389
2390 Fix breakage in normal/auth.c.
2391
2392 * normal/auth.c (grub_iswordseparator): New function.
2393
e7e1f93f 23942009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
2395
2396 Authentication support.
2397
2398 * commands/password.c: New file.
2399 * conf/common.rmk (pkglib_MODULES): Add password.mod.
2400 (password_mod_SOURCES): New variable.
2401 (password_mod_CFLAGS): Likewise.
2402 (password_mod_LDFLAGS): Likewise.
2403 (normal_mod_SOURCES): Add normal/auth.c.
2404 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add commands/password.c and
2405 normal/auth.c.
2406 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
2407 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2408 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
2409 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2410 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2411 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
2412 * include/grub/auth.h: New file.
2413 * include/grub/err.h (grub_err_t): New enum value
2414 GRUB_ERR_ACCESS_DENIED.
2415 * include/grub/menu.h (grub_menu_entry): New fields 'restricted' and
2416 'users'.
2417 * include/grub/normal.h (grub_cmdline_get): New argument 'history'.
2418 * normal/cmdline.c (grub_cmdline_get): New argument 'history'. All
2419 users updated.
2420 * normal/auth.c: New file.
2421 * normal/main.c (grub_normal_add_menu_entry): Handle --users option.
2422 (grub_cmdline_run): Don't allow to go to command line without
2423 authentication.
2424 * normal/menu.c (grub_menu_execute_entry): Handle restricted entries.
2425 * normal/menu_entry.c (grub_menu_entry_run): Don't allow editing
2426 menuentry without superuser rights.
2427 * normal/menu_viewer.c (grub_menu_viewer_show_menu): Don't exit if
2428 user isn't a superuser.
2429
70f1161d 24302009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
2431
2432 Save space by inlining misc.c functions.
2433
2434 * kern/misc.c (grub_iswordseparator): Made static.
2435 * kern/misc.c (grub_strcat): Moved from here ...
2436 * include/grub/misc.h (grub_strcat): ... here. Inlined.
2437 * kern/misc.c (grub_strncat): Moved from here ...
2438 * include/grub/misc.h (grub_strncat): ... here. Inlined.
2439 * kern/misc.c (grub_strcasecmp): Moved from here ...
2440 * include/grub/misc.h (grub_strcasecmp): ... here. Inlined.
2441 * kern/misc.c (grub_strncasecmp): Moved from here ...
2442 * include/grub/misc.h (grub_strncasecmp): ... here. Inlined.
2443 * kern/misc.c (grub_isalpha): Moved from here ...
2444 * include/grub/misc.h (grub_isalpha): ... here. Inlined.
2445 * kern/misc.c (grub_isdigit): Moved from here ...
2446 * include/grub/misc.h (grub_isdigit): ... here. Inlined.
2447 * kern/misc.c (grub_isgraph): Moved from here ...
2448 * include/grub/misc.h (grub_isgraph): ... here. Inlined.
2449 * kern/misc.c (grub_tolower): Moved from here ...
2450 * include/grub/misc.h (grub_tolower): ... here. Inlined.
2451
48e40bff 24522009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
2453
2454 * script/sh/function.c (grub_script_function_find): Cut error message
2455 not to flood terminal.
2456 * script/sh/lexer.c (grub_script_yylex): Remove command line length
2457 limit.
2458 * script/sh/script.c (grub_script_arg_add): Duplicate string.
2459
c385bfc3 24602009-08-24 Colin Watson <cjwatson@ubuntu.com>
2461
2462 * term/usb_keyboard.c (grub_usb_keyboard_getreport): Make
2463 `report' grub_uint8_t *.
2464 (grub_usb_keyboard_checkkey): Make `data' elements grub_uint8_t.
2465 Use a 50-millisecond timeout rather than just repeating
2466 grub_usb_keyboard_getreport 50 times.
2467 (grub_usb_keyboard_getkey): Make `data' elements grub_uint8_t.
2468
2d21e3e8 24692009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
2470
2471 Rename *_partition_map to part_*
2472
2473 * partmap/acorn.c (grub_acorn_partition_map): Set name to 'part_acorn'.
2474 * partmap/amiga.c (grub_amiga_partition_map): Set name to 'part_amiga'.
2475 * partmap/apple.c (grub_apple_partition_map): Set name to 'part_apple'.
2476 * partmap/gpt.c (grub_gpt_partition_map): Set name to 'part_gpt'.
2477 All users updated.
2478 * partmap/msdos.c (grub_msdos_partition_map): Set name to 'part_msdos'.
2479 All users updated.
2480 * partmap/sun.c (grub_sun_partition_map): Set name to 'part_sun'.
2481 * util/grub-probe.c (probe_partmap): Don't transform partition name
2482 to get module name.
2483
dd103c4e 24842009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
2485
2486 Fix OpenBSD and NetBSD support.
2487
2488 * include/grub/i386/bsd.h (GRUB_BSD_TEMP_BUFFER): Change to resolve
2489 memory address conflict.
2490 (OPENBSD_MMAP_ACPI): New definition.
2491 (OPENBSD_MMAP_NVS): Likewise.
2492 * loader/i386/bsd.c (grub_openbsd_boot): Support OPENBSD_MMAP_ACPI
2493 and OPENBSD_MMAP_NVS.
2494 Add memory map terminator
2495 Explicit cast when calling grub_unix_real_boot.
ad8ea1f4 2496 (grub_netbsd_boot): Explicit cast when calling grub_unix_real_boot.
dd103c4e 2497
16c84d74 24982009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
2499
2500 Let user specify NetBSD root device.
2501
2502 * loader/i386/bsd.c (netbsd_root): New variable.
2503 (netbsd_opts): New option 'root'.
2504 (NETBSD_ROOT_ARG): New macro.
2505 (grub_netbsd_boot): Use 'netbsd_root'.
2506 (grub_bsd_unload): Free 'netbsd_root'.
2507 (grub_cmd_netbsd): Fill 'netbsd_root'.
2508
adb29902 25092009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
2510
2511 Support for 64-bit NetBSD.
2512
2513 * loader/i386/bsd.c (grub_bsd_load_elf): Apply correct mask to entry
2514 point when booting non-FreeBSD.
2515
f5ae9f74 25162009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
2517
2518 Support --no-smp and --no-acpi for NetBSD.
2519
2520 * include/grub/i386/bsd.h (NETBSD_AB_NOSMP): New definition.
2521 (NETBSD_AB_NOACPI): Likewise.
2522 * loader/i386/bsd.c (netbsd_opts): New entries no-smp and no-acpi.
2523 (netbsd_flags): Add NETBSD_AB_NOSMP, NETBSD_AB_NOACPI.
2524
de74f136 25252009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
2526
2527 * fs/hfsplus.c (grub_hfsplus_mount): Don't ignore grub_hfsplus_read_file
2528 errors.
2529 (grub_hfsplus_btree_iterate_node): Don't ignore grub_hfsplus_read_file
2530 errors. Call grub_error when needed.
2531
e9a925da 25322009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
2533
2534 * commands/search.c (search_fs): Try searching without autoload first.
2535 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Load
2536 filesystem module explicitly for faster booting.
2537
5174302b 25382009-08-23 Colin Watson <cjwatson@ubuntu.com>
2539
2540 * util/grub-mkconfig.in: Export GRUB_DISABLE_OS_PROBER.
2541
c8c80635 25422009-08-23 Colin Watson <cjwatson@ubuntu.com>
2543
2544 * util/grub.d/30_os-prober.in: Disable os-prober if
2545 `GRUB_DISABLE_OS_PROBER' was set to true.
2546
71acf5e5 25472009-08-23 Robert Millan <rmh.grub@aybabtu.com>
2548
2549 * partmap/pc.c: Rename to ...
2550 * partmap/msdos.c: ... this. Update all users.
2551 (grub_pc_partition_map): Rename to ...
2552 (grub_msdos_partition_map): ... this. Update all users.
2553
2554 * parttool/pcpart.c: Rename to ...
2555 * parttool/msdospart.c: ... this. Update all users.
2556
2557 * include/grub/pc_partition.h: Rename to ...
2558 * include/grub/msdos_partition.h: ... this. Update all users.
2559 (grub_pc_partition_bsd_entry): Rename to ...
2560 (grub_msdos_partition_bsd_entry): ... this. Update all users.
2561 (grub_pc_partition_disk_label): Rename to ...
2562 (grub_msdos_partition_disk_label): ... this. Update all users.
2563 (grub_pc_partition_entry): Rename to ...
2564 (grub_msdos_partition_entry): ... this. Update all users.
2565 (grub_pc_partition_mbr): Rename to ...
2566 (grub_msdos_partition_mbr): ... this. Update all users.
2567 (grub_pc_partition): Rename to ...
2568 (grub_msdos_partition): ... this. Update all users.
2569 (grub_pc_partition_is_empty): Rename to ...
2570 (grub_msdos_partition_is_empty): ... this. Update all users.
2571 (grub_pc_partition_is_extended): Rename to ...
2572 (grub_msdos_partition_is_extended): ... this. Update all users.
2573 (grub_pc_partition_is_bsd): Rename to ...
2574 (grub_msdos_partition_is_bsd): ... this. Update all users.
2575
2576 * conf/common.rmk (amiga_mod_SOURCES, amiga_mod_CFLAGS)
2577 (amiga_mod_LDFLAGS, apple_mod_SOURCES, apple_mod_CFLAGS)
2578 (apple_mod_LDFLAGS, msdos_mod_SOURCES, msdos_mod_CFLAGS)
2579 (msdos_mod_LDFLAGS, sun_mod_SOURCES, sun_mod_CFLAGS)
2580 (sun_mod_LDFLAGS, acorn_mod_SOURCES, acorn_mod_CFLAGS)
2581 (acorn_mod_LDFLAGS, gpt_mod_SOURCES, gpt_mod_CFLAGS)
2582 (gpt_mod_LDFLAGS): Rename to ...
2583 (part_amiga_mod_SOURCES, part_amiga_mod_CFLAGS, part_amiga_mod_LDFLAGS)
2584 (part_apple_mod_SOURCES, part_apple_mod_CFLAGS, part_apple_mod_LDFLAGS)
2585 (part_msdos_mod_SOURCES, part_msdos_mod_CFLAGS, part_msdos_mod_LDFLAGS)
2586 (part_sun_mod_SOURCES, part_sun_mod_CFLAGS, part_sun_mod_LDFLAGS)
2587 (part_acorn_mod_SOURCES, part_acorn_mod_CFLAGS, part_acorn_mod_LDFLAGS)
2588 (part_gpt_mod_SOURCES, part_gpt_mod_CFLAGS)
2589 (part_gpt_mod_LDFLAGS): ... this.
2590 (pkglib_MODULES): Prefix partition modules with `part_'. Rename
2591 `pcpart.mod' to `msdospart.mod'.
2592 (pcpart_mod_SOURCES, pcpart_mod_CFLAGS, pcpart_mod_LDFLAGS): Rename
2593 to ...
2594 (msdospart_mod_SOURCES, msdospart_mod_CFLAGS)
2595 (msdospart_mod_LDFLAGS): ... this.
2596
c11fded5 25972009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
2598
2599 * loader/i386/bsd.c (freebsd_opts): Rewritten to use extcmd.
2600 (openbsd_opts): Likewise.
2601 (netbsd_opts): Likewise.
2602 (freebsd_flags): Added 0 terminator.
2603 (openbsd_flags): Likewise.
2604 (netbsd_flags): Likewise.
2605 (grub_bsd_parse_flags): Rewritten to use extcmd. All users updated.
2606 (grub_cmd_freebsd): Transformed into extended command.
2607 (grub_cmd_openbsd): Likewise.
2608 (grub_cmd_netbsd): Likewise.
2609 (cmd_freebsd): Changed type to grub_extcmd_t.
2610 (cmd_openbsd): Likewise.
2611 (cmd_netbsd): Likewise.
2612 (GRUB_MOD_INIT (bsd)): Register grub_cmd_freebsd, grub_cmd_netbsd and
2613 grub_cmd_openbsd as extended commands.
2614 (GRUB_MOD_FINI (bsd)): Use grub_unregister_extcmd for cmd_freebsd,
2615 cmd_netbsd and cmd_openbsd
2616
11d1c769 26172009-08-22 Vladimir Serbinenko <phcoder@gmail.com>
2618
2619 * commands/xnu_uuid.c (transform): Use grub_memcpy instead of memcpy.
2620
7a9094e5 26212009-08-21 Pavel Roskin <proski@gnu.org>
2622
5496c37e 2623 * Makefile.in (install-local): When checking if a file is in the
2624 build directory, use "test -e" to detect symlinks.
2625
7a9094e5 2626 * Makefile.in (install-local): Remove all files in
2627 $(DESTDIR)$(pkglibdir) before installing new files there.
2628
e53cea11 26292009-08-18 Felix Zielcke <fzielcke@z-51.de>
2630
2631 * util/powerpc/ieee1275/grub-mkrescue.in (grub_mkimage): Use
2632 grub-mkelfimage.
2633
9aced544 26342009-08-18 Felix Zielcke <fzielcke@z-51.de>
2635
2636 * util/grub-mkconfig.in: Don't use gfxterm by default if not
2637 explicitly specified by the user.
2638
b7da6bab 26392009-08-18 Pavel Roskin <proski@gnu.org>
2640
2641 * include/grub/fbfill.h (struct grub_video_fbrender_target): Use
2642 grub_uint8_t pointer for data.
2643 * include/grub/fbutil.h (struct grub_video_fbblit_info):
2644 Likewise.
2645 * video/fb/fbutil.c: Remove unnecessary casts.
2646
19f1b335 26472009-08-17 Michal Suchanek <hramrach@centrum.cz>
2648
2649 VBE cleanup.
2650
2651 * video/i386/pc/vbe.c (vbe_mode_in_use): Removed (duplicate).
2652 (grub_vbe_set_video_mode): Save active mode info
2653 only after setting the mode.
2654 (grub_video_vbe_setup): Call 'grub_vbe_set_video_mode' with NULL as
2655 second argument.
2656
2f467aa9 26572009-08-17 Michal Suchanek <hramrach@centrum.cz>
2658
2659 Rename variables for clarity.
2660
2661 * video/i386/pc/vbe.c (active_mode_info): Renamed to ...
2662 (active_vbe_mode_info): ... this. All users updated.
2663 (framebuffer): Rename 'active_mode' to 'active_vbe_mode'.
2664 All users updated.
2665 (initial_mode): Rename to ...
2666 (initial_vbe_mode): ... this. All users updated.
2667 (mode_in_use): Rename to ..
2668 (vbe_mode_in_use): ... this. All users updated.
2669 (mode_list): Rename to ..
2670 (vbe_mode_list): ... this. All users updated.
2671 (grub_vbe_set_video_mode): Rename 'mode' to 'vbe_mode', 'mode_info' to
2672 'vbe_mode_info' and 'old_mode' to 'old_vbe_mode'.
2673 (grub_video_vbe_init): Rename 'rm_mode_list' to 'rm_vbe_mode_list' and
2674 'mode_list_size' to 'vbe_mode_list_size'.
2675 (grub_video_vbe_setup): Rename 'mode_info' to 'vbe_mode_info',
2676 'best_mode_info' to 'best_vbe_mode_info' and
2677 'best_mode' to 'best_vbe_mode'
2678
6025fcd7 26792009-08-17 Michal Suchanek <hramrach@centrum.cz>
2680
2681 Remove duplicate grub_video_fb_get_video_ptr.
2682
2683 * include/grub/fbutil.h (get_data_ptr): Rename to ...
2684 (grub_video_fb_get_video_ptr): ... this.
2685 * include/grub/video_fb.h (grub_video_fb_get_video_ptr): Removed.
2686 * video/fb/fbutil.c: Add comment about addressing.
2687 (get_data_ptr): Rename to ...
2688 (grub_video_fb_get_video_ptr): ... this. All users updated.
2689 * video/fb/video_fb.c (grub_video_fb_get_video_ptr): Remove.
2690
cc8c6faf 26912009-08-17 Robert Millan <rmh.grub@aybabtu.com>
2692
2693 * fs/fat.c (grub_fat_read_data): Remove `#if 0' braces around the
2694 grub_dprintf() that was just added.
2695
08aa61f0 26962009-08-17 Robert Millan <rmh.grub@aybabtu.com>
2697
2698 * loader/i386/linux.c (GRUB_ASSUME_LINUX_HAS_FB_SUPPORT)
2699 (DEFAULT_VIDEO_MODE): Remove macros.
2700 (grub_linux_boot): Remove assumption that Linux has FB support,
2701 and use "text" as default video mode.
2702
7cef4f75 27032009-08-15 Vladimir Serbinenko <phcoder@gmail.com>
2704
2705 * fs/affs.c (grub_affs_read_symlink): Change leftover grub_printf into
2706 grub_dprintf.
2707 * fs/fat.c (grub_fat_read_data): Likewise.
2708
e1f39873 27092009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2710
2711 * loader/i386/multiboot.c (grub_multiboot): Don't pass filename to
2712 payload.
2713 (grub_module): Likewise.
2714
c166d79e 27152009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2716
2717 * loader/i386/multiboot.c (grub_multiboot_unload): Don't free mbi and
2718 mbi->cmdline but free playground.
2719
c60cee8e 27202009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2721
2722 Handle group offset on UFS1.
2723
2724 * fs/ufs.c (grub_ufs_sblock): New field 'cylg_mask'.
2725 (grub_ufs_read_inode) [!MODE_UFS2]: handle cylg_offset and cylg_mask.
2726
c0d8b5d4 27272009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2728
2729 Split ufs.mod into ufs1.mod and ufs2.mod.
2730
2731 * conf/common.rmk (grub_probe_SOURCES): Add fs/ufs2.c.
2732 (grub_fstest_SOURCES): Likewise.
2733 (pkglib_MODULES): Remove ufs.mod. Add ufs1.mod and ufs2.mod.
2734 (ufs_mod_SOURCES): Remove.
2735 (ufs_mod_CFLAGS): Likewise.
2736 (ufs_mod_LDFLAGS): Likewise.
2737 (ufs1_mod_SOURCES): New variable.
2738 (ufs1_mod_CFLAGS): Likewise.
2739 (ufs1_mod_LDFLAGS): Likewise.
25fbd77a 2740 (ufs2_mod_SOURCES): New variable.
2741 (ufs2_mod_CFLAGS): Likewise.
2742 (ufs2_mod_LDFLAGS): Likewise.
c0d8b5d4 2743 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add fs/ufs2.c.
2744 * conf/i386-efi.rmk (util/i386/efi/grub-mkimage.c_DEPENDENCIES):
2745 Likewise.
2746 (grub_emu_SOURCES): Likewise.
2747 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2748 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
2749 (grub_setup_SOURCES): Likewise.
2750 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2751 * conf/sparc64.rmk (grub_emu_SOURCES): Likewise.
2752 (grub_setup_SOURCES): Likewise.
2753 * conf/x86_64-efi.rmk (util/i386/efi/grub-mkimage.c_DEPENDENCIES):
2754 Likewise.
2755 * fs/ufs2.c: New file.
2756 * fs/ufs.c: Separate UFS1 from UFS2 by using preprocessor.
2757
d3539132 27582009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2759
2760 Framebuffer split.
2761
2762 * commands/i386/pc/vbetest.c (grub_cmd_vbetest): Restore video
2763 subsystem at the end.
2764 * conf/common.rmk (pkglib_MODULES): Add video_fb.mod.
2765 (video_fb_mod_SOURCES): New variable.
2766 (video_fb_mod_CFLAGS): Likewise.
2767 (video_fb_mod_LDFLAGS): Likewise.
2768 * conf/i386-pc.rmk (vbe_mod_SOURCES): Remove video/i386/pc/vbeblit.c,
2769 video/i386/pc/vbefill.c and video/i386/pc/vbeutil.c.
2770 * video/i386/pc/vbeblit.c: Moved from here ...
2771 * video/fb/fbblit.c: ..here. Replaced 'vbe' with 'fb'.
2772 * video/i386/pc/vbefill.c: Moved from here ...
2773 * video/fb/fbfill.c: ..here. Replaced 'vbe' with 'fb'.
2774 * video/i386/pc/vbeutil.c: Moved from here ...
2775 * video/fb/fbutil.c: ..here. Replaced 'vbe' with 'fb'.
2776 * include/grub/i386/pc/vbeblit.h: Moved from here ...
2777 * include/grub/fbblit.h: ... here. Replaced 'vbe' with 'fb'.
2778 * include/grub/i386/pc/vbefill.h: Moved from here ...
2779 * include/grub/fbfill.h: ... here. Replaced 'vbe' with 'fb'.
2780 * include/grub/i386/pc/vbeutil.h: Moved from here ...
2781 * include/grub/fbutil.h: ... here. Replaced 'vbe' with 'fb'.
2782 * include/grub/i386/pc/vbe.h: Moved framebuffer part ...
2783 * include/grub/video_fb.h: ... here. Replaced 'vbe' with 'fb'.
2784 * include/grub/video.h (GRUB_VIDEO_RENDER_TARGET_FRONT_BUFFER): Removed.
2785 (GRUB_VIDEO_RENDER_TARGET_BACK_BUFFER): Likewise.
2786 (grub_video_adapter): Added 'get_info_and_fini'.
2787 (grub_video_get_info_and_fini): New prototype.
2788 (grub_video_set_mode): make modestring const char *.
2789 * loader/i386/linux.c (grub_linux_setup_video): Use
2790 grub_video_get_info_and_fini.
2791 (grub_linux_boot): Move modesetting just before booting.
2792 * loader/i386/pc/xnu.c (grub_xnu_set_video): Use
2793 grub_video_get_info_and_fini.
2794 * video/i386/pc/vbe.c: Moved framebuffer part ...
2795 * video/fb/video_fb.c: ... here. Replaced 'vbe' with 'fb'.
2796 * video/i386/pc/vbe.c (grub_vbe_set_video_mode): Use
2797 grub_video_fbstd_colors and grub_video_fb_set_palette.
2798 (grub_video_vbe_init): Clear 'framebuffer' variable and use
2799 grub_video_fb_init.
2800 (grub_video_vbe_fini): Use grub_video_fb_fini.
2801 (grub_video_vbe_setup): Use framebuffer.render_target instead of
2802 render_target and use grub_video_fb_set_active_render_target and
2803 grub_video_fb_set_palette.
2804 (grub_video_vbe_set_palette): Use grub_video_fb_set_palette.
2805 (grub_video_vbe_set_viewport): Use grub_video_fb_set_viewport.
2806 (grub_video_vbe_adapter): Use framebuffer.
2807 * video/video.c (grub_video_get_info_and_fini): New function.
2808 (grub_video_set_mode): Make modestring const char *.
2809 (GRUB_MOD_INIT(video_video)): Don't set variables to 0 since these
2810 values are already initialised.
2811
d404ee56 28122009-08-14 Pavel Roskin <proski@gnu.org>
2813
2814 * boot/i386/pc/cdboot.S: Use LOCAL for local labels. Eliminate
2815 ABS and APPLE_CC.
2816 * boot/i386/pc/diskboot.S: Likewise.
2817 * boot/i386/pc/lnxboot.S: Likewise. Hardcode the number of code
2818 sectors allow compilation on MacOSX.
2819 * conf/i386-pc.rmk: Enable unconditional compilation of
2820 lnxboot.img.
2821
9a10df16 28222009-08-13 Colin Watson <cjwatson@ubuntu.com>
2823
2824 * util/grub-mkconfig.in: Export GRUB_HIDDEN_TIMEOUT.
2825 * util/grub.d/00_header.in: Enter interruptible sleep if
2826 GRUB_HIDDEN_TIMEOUT is set.
2827
be3c9ca7 28282009-08-13 Yves Blusseau <blusseau@zetam.org>
2829
2830 * include/grub/symbol.h: Add the LOCAL macro.
2831 * boot/i386/pc/boot.S: Use the LOCAL macro for all labels
2832 starting with "L_".
2833
1f9e557e 28342009-08-13 Pavel Roskin <proski@gnu.org>
2835
9ca62843 2836 * boot/i386/pc/boot.S: Remove ABS macro, it's not required by
2837 any modern compilers we support.
2838
1f9e557e 2839 * boot/i386/pc/boot.S: Remove all code dependent on APPLE_CC.
2840 Use local labels starting with "L_" so that Apple assembler
2841 knows they are local.
2842
81623db6 28432009-08-10 Robert Millan <rmh.grub@aybabtu.com>
2844
2845 * include/grub/i386/bsd.h (KERNEL_TYPE_NONE, KERNEL_TYPE_FREEBSD)
2846 (KERNEL_TYPE_OPENBSD, KERNEL_TYPE_NETBSD): Convert to ...
2847 (bsd_kernel_types): ... this enum.
2848
2849 * loader/i386/bsd.c (grub_cmd_freebsd_loadenv, grub_cmd_freebsd_module)
2850 (grub_cmd_freebsd_module_elf): Abort with "You need to load the
2851 kernel first." when `kernel_type' is set to KERNEL_TYPE_NONE.
2852
2853 (grub_bsd_load_aout, grub_bsd_load, grub_cmd_freebsd_loadenv)
2854 (grub_cmd_freebsd_module, grub_cmd_freebsd_module_elf)
2855 (GRUB_MOD_INIT (bsd)): Fix capitalization in a few error
2856 messages.
2857
f5d35e7a 28582009-08-08 Robert Millan <rmh.grub@aybabtu.com>
2859
2860 * util/grub-dumpdevtree: Moved from here ...
2861 * util/i386/efi/grub-dumpdevtree: ... to here.
2862 (hexify): New function. Converts a string to its hex version.
2863 Generate hex versions of "efi" and "device-properties" by calling
2864 hexify() on the ASCII strings rather than by hardcoding numbers.
2865
d1e1d527 28662009-08-08 Robert Millan <rmh.grub@aybabtu.com>
2867
2868 * fs/jfs.c: Update copyright year.
2869
1ebbe064 28702009-08-08 Felix Zielcke <fzielcke@z-51.de>
2871
2872 * util/grub.d/00_header.in: Fix a comment.
2873 * util/grub.d/10_linux.in: Likewise.
2874 * util/grub.d/10_windows.in: Likewise.
2875 * util/grub.d/10_hurd.in: Likewise.
2876
a78c8d24 28772009-08-08 Felix Zielcke <fzielcke@z-51.de>
2878
2879 * util/grub-mkconfig.in: Allow the user to specify the used font
2880 with GRUB_FONT.
2881
29a6b9e8 28822009-08-08 Pavel Roskin <proski@gnu.org>
2883
b5f16cc4 2884 * include/grub/powerpc/libgcc.h: Export __ashrdi3() if
2885 available, xfs.mod needs it now.
2886
2f5cb827 2887 * util/grub-mkconfig_lib.in (version_test_numeric): Don't use
2888 the "g" modifier in sed when the intention is to strip something
2889 once. This fixes comparison of kernels with multiple dashes.
2890
29a6b9e8 2891 * util/grub-mkconfig.in: Define datarootdir, datadir may depend
2892 on it. Add missing space before closing bracket. Fix
2893 misleading formatting.
2894
892a3d98 28952009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2896
2897 * docs/grub.texi: Major overhaul. Remove all sections that are
2898 specific to GRUB Legacy, or mostly composed of Legacy-specific
2899 information.
2900
ed94253f 29012009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2902
2903 * docs/version.texi: New file. Provides version information for
2904 grub.texi.
2905
126d6628 29062009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2907
2908 * docs/grub.texi: Update CVS information to SVN.
2909 Replace outdated "GRUB 2 will include" phrase with "GRUB 2 includes".
2910
998b5aa9 29112009-08-07 Felix Zielcke <fzielcke@z-51.de>
2912
2913 * util/grub-mkconfig.in: Remove a wrong `fi'.
2914
818e094a 29152009-08-07 Felix Zielcke <fzielcke@z-51.de>
2916
2917 * fs/uuid.c (grub_jfs_superblock): New fields unused2 and uuid.
2918 (grub_jfs_uuid): New function.
2919 (grub_jfs_fs): Set uuid field to grub_jfs_uuid.
2920
b969c52f 29212009-08-07 Felix Zielcke <fzielcke@z-51.de>
2922
2923 * util/grub-mkconfig_lib.in (font_path): Move the functionality
2924 of it to ...
2925 * util/grub-mkconfig.in: ... here. Prefer unicode.pf2 and
2926 unifont.pf2 over ascii.pf2. Export LANG=C in case ascii.pf2 gets used.
2927
7a4894cc 29282009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2929
2930 * util/grub.d/10_linux.in (test_numeric): Moved from here ...
2931 * util/grub-mkconfig_lib.in (version_test_numeric): ... to here.
2932 Update all users.
2933
2934 * util/grub.d/10_linux.in (test_gt): Strip any basename prefix,
2935 not just "vmlinu[zx]".
2936 Moved from here ...
2937 * util/grub-mkconfig_lib.in (version_test_gt): ... to here. Update
2938 all users.
2939
2940 * util/grub.d/10_linux.in (find_latest): Moved from here ...
2941 * util/grub-mkconfig_lib.in (version_find_latest): ... to here. Update
2942 all users.
2943
4e2171f8 29442009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2945
2946 * util/grub.d/10_freebsd.in: Use an absolute device path for
2947 `vfs.root.mountfrom'. Set `vfs.root.mountfrom.options=rw'.
2948
6dcfcb32 29492009-08-06 Felix Zielcke <fzielcke@z-51.de>
2950
2951 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Fix
2952 handling of multiple abstraction modules.
2953
f56a8756 29542009-08-04 Robert Millan <rmh.grub@aybabtu.com>
2955
2956 Fix a bug resulting in black screen when loading Linux using a
2957 packed video mode.
2958
2959 * kern/i386/pc/startup.S (grub_vbe_bios_getset_dac_palette_width): New
2960 function.
2961
2962 * include/grub/i386/pc/vbe.h (GRUB_VBE_CAPABILITY_DACWIDTH): New macro.
2963 (grub_vbe_bios_getset_dac_palette_width): New function.
2964 (grub_vbe_bios_get_dac_palette_width)
2965 (grub_vbe_bios_set_dac_palette_width): New macros (act as wrappers for
2966 grub_vbe_bios_getset_dac_palette_width()).
2967
2968 * video/i386/pc/vbe.c (grub_vbe_probe): Use `GRUB_VBE_STATUS_OK' to
2969 check for return status.
2970 (grub_vbe_get_video_mode_info): When getting information for a packed
2971 mode (<= 8 bpp), obtain DAC palette width using
2972 grub_vbe_bios_getset_dac_palette_width(), and use that for initializing
2973 {red,green,blue}_mark_size.
2974
222671b2 29752009-08-04 Felix Zielcke <fzielcke@z-51.de>
2976
ecb1a6d9 2977 * commands/search.c (options): Fix help output to match actual code.
222671b2 2978
f84114f5 29792009-08-02 Vladimir Serbinenko <phcoder@gmail.com>
2980
2981 * commands/hexdump.c (grub_cmd_hexdump): Use grub_disk_read instead
2982 of homegrown code.
2983
bd288a20 29842009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
e768b770 2985
2986 * util/hostfs.c (grub_hostfs_dir): Don't use DT_DIR: It doesn't work
2987 on XFS or ReiserFS.
2988
8aab5e25 29892009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
2990
2991 Support Apple partition map with sector size different from 512 bytes.
2992
2993 * partmap/apple.c (grub_apple_header): New field 'blocksize'.
2994 (apple_partition_map_iterate): Respect 'aheader.blocksize'
2995 and 'apart.partmap_size'.
2996
6ad6258a 29972009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
29982009-08-01 Robert Millan <rmh.grub@aybabtu.com>
2999
3000 Fix cpuid command.
3001
3002 * commands/i386/cpuid.c (options): New variable.
3003 (grub_cmd_cpuid): Return real error.
3004 (GRUB_MOD_INIT(cpuid)): Declare options.
3005
67459bc6 30062009-07-31 Vladimir Serbinenko <phcoder@gmail.com>
3007
3008 * partmap/pc.c (pc_partition_map_iterate): Check that boot flags are
3009 valid.
3010
fbc6ab54 30112009-07-31 Bean <bean123ch@gmail.com>
3012
3013 * fs/xfs.c (grub_xfs_sblock): Change unused5 field to log2_sect and
3014 log2_inode.
3015 (grub_fshelp_node): Move inode field to the end.
3016 (grub_xfs_data): Remove inode field.
3017 (grub_xfs_inode_block): Calculate inode size using sblock.
3018 (grub_xfs_inode_offset): Likewise.
3019 (grub_xfs_read_inode): Calculate inode size using sblock.
3020 (grub_xfs_read_block): Replace XFS_INODE_EXTENTS with nrec.
3021 (grub_xfs_iterate_dir): Calculate inode size using sblock.
3022 (grub_xfs_mount): Use grub_zalloc instead of grub_malloc. Realloc data
3023 to match inode size.
3024 (grub_xfs_dir): goto mount_fail when mount fails, as data->diropen is
3025 not accessible when data is null.
3026 (grub_xfs_open): Likewise.
3027
f45d6cfc 30282009-07-31 Bean <bean123ch@gmail.com>
3029
3030 * disk/lvm.c (grub_lvm_scan_device): Ignore extra copy of metadata.
3031 Don't change pv->disk if it's already set.
3032
3033 * disk/raid.c (grub_raid_scan_device): Merge this function into ...
3034 (grub_raid_register): ... here.
3035 (grub_raid_rescan): Removed.
3036
3037 * include/grub/raid.h (grub_raid_rescan): Removed.
3038
3039 * util/grub-fstest.c: Remove include file <grub/raid.h>.
3040 (fstest): Replace grub_raid_rescan with module fini function followed
3041 by init function.
3042
3043 * util/grub-probe.c: Add include file <grub/raid.h>.
3044 (probe_raid_level): New function.
3045 (probe): Detect abstraction by walking the disk device, support two
3046 level of abstraction (LVM on RAID) when detecting partition map.
3047
24443b5a 30482009-07-31 Pavel Roskin <proski@gnu.org>
3049
3050 * disk/raid5_recover.c (grub_raid5_recover): Revert conversion
3051 to grub_zalloc(), it was erroneous.
3052 Reported by Bean <bean123ch@gmail.com>
3053
a275d9e7 30542009-07-30 Vladimir Serbinenko <phcoder@gmail.com>
3055
3056 * util/i386/pc/grub-setup.c (setup): Check that no partition is in
ad8ea1f4 3057 embedding zone, not only the first one.
a275d9e7 3058
56c5a47f 30592009-07-29 Joe Auricchio <jauricchio@gmail.com>
3060
3061 * term/gfxterm.c (clear_char): New function.
3062 (grub_virtual_screen_setup): Use clear_char.
3063 (scroll_up): Likewise.
3064 (grub_virtual_screen_cls): Likewise.
3065
67bb323a 30662009-07-29 Felix Zielcke <fzielcke@z-51.de>
3067
3068 * util/deviceiter.c (get_acceleraid_disk_name): New static
3069 function.
3070 (grub_util_iterate_devices): Handle Accelraid devices.
3071 * util/hostdisk.c (convert_system_partition_to_system_disk): Likewise.
3072
388a7c75 30732009-07-28 Robert Millan <rmh.grub@aybabtu.com>
3074
3075 * loader/i386/linux.c (grub_cmd_linux): Use ',' rather than ';' as
3076 separator for the suggested gfxpayload string (';' collides with the
3077 parser and needs escaping).
3078
3bb7abcf 30792009-07-28 Vladimir Serbinenko <phcoder@gmail.com>
3080
3081 * loader/i386/multiboot_helper.S (grub_multiboot_backward_relocator):
3082 Clear direction flag before jumping to OS.
3083 (grub_multiboot2_real_boot): Likewise.
3084
2ddd36d7 30852009-07-28 Felix Zielcke <fzielcke@z-51.de>
3086
3087 * util/i386/pc/grub-install: Fix parsing of --disk-module
3088 option.
3089
c521b62b 30902009-07-28 Felix Zielcke <fzielcke@z-51.de>
3091
3092 * util/i386/pc/grub-setup.c (setup): Fix 2 incorrect checks
3093 when embedding.
3094
880e0a0c 30952009-07-26 Felix Zielcke <fzielcke@z-51.de>
3096
3097 * util/grub-mkconfig.in (package_version): New variable.
3098 Use it do display the version.
3099
2366e356 31002009-07-25 Felix Zielcke <fzielcke@z-51.de>
3101
3102 * kern/file.c (grub_file_open): Revert to previous check with
3103 grub_errno.
3104
7ad8c80e 31052009-07-25 Vladimir Serbinenko <phcoder@gmail.com>
3106
3107 * commands/probe.c (GRUB_MOD_INIT (probe)): Remove "[--target=target]"
3108 from help line. It's out of sync with code.
3109
72b9658b 31102009-07-25 Vladimir Serbinenko <phcoder@gmail.com>
3111
3112 * kern/parser.c (grub_parser_execute): Fix a bug causing truncated
3113 entries on failed boot.
3114
77435277 31152009-07-25 Felix Zielcke <fzielcke@z-51.de>
3116
3117 * kern/file.c (grub_file_open): Fix an error check.
3118
fcaa8b21 31192009-07-24 Vladimir Serbinenko <phcoder@gmail.com>
3120
35d16c74 3121 * util/i386/pc/grub-setup.c (setup): Fix segmentation fault when
3122 partition map couldn't be identified.
fcaa8b21 3123
48904cd1 31242009-07-23 Pavel Roskin <proski@gnu.org>
3125
ef3c317f 3126 * commands/xnu_uuid.c (transform): Use GRUB_CPU_WORDS_BIGENDIAN
3127 instead of WORDS_BIGENDIAN. Use grub_le_to_cpu32(), so that the
3128 case of little endian words becomes just an optimization.
3129 Respect const modifier.
ad8ea1f4 3130 (md5_final): Use code that doesn't depend on endianness.
ef3c317f 3131
48904cd1 3132 * include/grub/misc.h (ALIGN_UP): Cast align to the type of addr
3133 to avoid loss of upper bits if align is unsigned and shorter
3134 than addr.
3135
260c9a89 31362009-07-21 Vladimir Serbinenko <phcoder@gmail.com>
3137
3138 UUID support for UFS
3139
3140 * fs/ufs.c (grub_ufs_sblock): Add uuidhi and uuidlow.
3141 (grub_ufs_uuid): New function.
3142 (grub_ufs_fs): add .uuid
3143
f76ce889 31442009-07-21 Pavel Roskin <proski@gnu.org>
3145
3146 * kern/dl.c (grub_dl_check_header): Make static.
3147
6a6cbcaf 31482009-07-21 Felix Zielcke <fzielcke@z-51.de>
3149
3150 * util/grub.d/30_os-prober.in: Remove unused CHAINROOT. Don't
3151 add drivemap for Vista. It breaks Windows 7.
3152
cffcddb2 31532009-07-21 Vladimir Serbinenko <phcoder@gmail.com>
3154
3155 * fs/ufs.c (grub_ufs_sblock): Fix offset of mtime2 which was off by
3156 128 bytes
3157
1ef44b80 31582009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
3159
3160 Add BFS support
3161
3162 * conf/common.rmk (grub_probe_SOURCES): Add fs/befs.c.
3163 (grub_fstest_SOURCES): Likewise.
3164 (pkglib_MODULES): Add befs.mod.
3165 (befs_mod_SOURCES): New variable.
3166 (befs_mod_CFLAGS): Likewise.
3167 (befs_mod_LDFLAGS): Likewise.
3168 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
3169 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
3170 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3171 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
3172 (grub_setup_SOURCES): Likewise.
3173 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3174 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
3175 (grub_setup_SOURCES): Likewise.
3176 * fs/befs.c: New file.
3177 * fs/afs.c (GRUB_AFS_FSNAME): New declaration.
3178 (GRUB_AFS_SBLOCK_SECTOR): Likewise.
3179 (GRUB_AFS_SBLOCK_MAGIC1) [MODE_BFS]: New conditional declaration.
3180 (GRUB_AFS_BTREE_MAGIC) [MODE_BFS]: Likewise
3181 (B_KEY_INDEX_ALIGN): New declaration.
3182 (B_KEY_INDEX_OFFSET): Use B_KEY_INDEX_ALIGN.
3183 (grub_afs_bnode) [MODE_BFS]: Make key_count and key_size 16-bit
3184 (grub_afs_btree) [MODE_BFS]: New conditional declaration.
3185 (grub_afs_sblock) [MODE_BFS]: Remove link_count.
3186 (grub_afs_validate_sblock) [MODE_BFS]: Support BFS
3187 (grub_afs_mount) [MODE_BFS]: Likewise.
3188 (grub_afs_dir) [MODE_BFS]: Divide mtime by 65536 and not 1000000.
3189 (grub_afs_fs): Use GRUB_AFS_FSNAME
3190 (GRUB_MOD_INIT (afs)) [MODE_BFS]: Rename to ...
3191 (GRUB_MOD_INIT (befs)) [MODE_BFS]: ... this
3192 (GRUB_MOD_FINI (afs)) [MODE_BFS]: Rename to ...
3193 (GRUB_MOD_FINI (befs)) [MODE_BFS]: ... this
3194
4f253044 31952009-07-19 Yves BLUSSEAU <yves.grub-devel@zetam.org>
3196
3197 * util/getroot.c (find_root_device): Add support for MacOSX.
3198 * util/hostdisk.c: Likewise.
3199
57a55913 32002009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
3201
3202 * font/font.c (find_glyph): Check whether a font is present to avoid
3203 segmentation fault.
75421ca9 3204
32052009-07-20 Joe Auricchio <jauricchio@gmail.com>
04c7c429 3206
3207 * term/gfxterm.c (grub_virtual_screen_setup): Clear virtual_screen.
3208
e98cd0c2 32092009-07-20 Pavel Roskin <proski@gnu.org>
3210
3211 * configure.ac: Trim excessively wordy excuses.
3212
1d2d169a 32132009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
3214
3215 Add symlink, mtime and label support to AtheFS.
3216
3217 * fs/afs.c (grub_afs_sblock): Declare `name' as char.
3218 (grub_afs_iterate_dir): Handle symlinks.
3219 (grub_afs_open): Use grub_afs_read_symlink.
3220 (grub_afs_dir): Likewise.
3221 Pass mtime.
3222 (grub_afs_label): New function.
3223 (grub_afs_fs): Add grub_afs_label.
3224 (grub_afs_read_symlink): New function.
3225
186f3189 32262009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
3227
3228 Fix AtheFS support.
3229
3230 * fs/afs.c: Fix comments style.
3231 (grub_afs_blockrun): Declare as packed.
3232 (grub_afs_datastream): Likewise.
3233 (grub_afs_bnode): Likewise.
3234 (grub_afs_btree): Likewise.
3235 (grub_afs_sblock): Likewise.
3236 Declare `name' as char.
3237 (grub_afs_inode): Declare as packed.
3238 Change void *vnode to grub_uint32_t unused.
3239 (grub_afs_iterate_dir): Check that key_size is positive.
3240 (grub_afs_mount): Don't read superblock twice.
75421ca9 3241 (grub_afs_dir): Don't free node in case of error,
186f3189 3242 grub_fshelp_find_file already handles this.
3243 (grub_afs_open): Likewise.
3244
5680109e 32452009-07-19 Pavel Roskin <proski@gnu.org>
3246
3247 * Makefile.in: Remove LIBLZO and enable_lzo.
3248 * conf/i386-pc.rmk: Remove lzo support.
3249 * configure.ac: Remove checks for lzo, don't define ENABLE_LZMA.
3250 * include/grub/i386/pc/kernel.h: Define ENABLE_LZMA. Remove lzo
3251 support.
3252 * kern/i386/pc/lzo1x.S: Remove.
3253 * kern/i386/pc/startup.S: Remove lzo support.
3254 * util/i386/pc/grub-mkimage.c: Likewise.
3255
ac70fa32 32562009-07-19 Vladimir Serbinenko <phcoder@gmail.com>
3257
3258 * disk/usbms.c (grub_usbms_transfer): Fix double semicolon.
3259 * fs/xfs.c (grub_xfs_dir): Likewise.
3260 * fs/afs.c (grub_afs_dir): Likewise.
3261 * fs/iso9660.c (grub_iso9660_iterate_dir): Likewise.
3262 (grub_iso9660_open): Likewise.
3263 * fs/jfs.c (grub_jfs_open): Likewise.
3264 * fs/ext2.c (grub_ext2_dir): Likewise.
3265 * include/grub/macho.h (grub_macho_fat_arch): Likewise.
3266 * script/sh/lexer.c (grub_script_yylex): Likewise.
75421ca9 3267
eab58da2 32682009-07-16 Pavel Roskin <proski@gnu.org>
3269
d2838156 3270 * configure.ac: Never add "-c" to CFLAGS.
3271
55c70904 3272 * configure.ac: Fix incorrect comparison for grub_cv_cc_efiemu.
3273
43e6200c 3274 * configure.ac: Fix wrong use of grub_cv_cc_no_red_zone where
3275 grub_cv_cc_efiemu should be used.
3276
ce7a733d 3277 * configure.ac: Typo fixes.
3278
eab58da2 3279 * kern/mm.c (grub_zalloc): New function.
3280 (grub_debug_zalloc): Likewise.
3281 * include/grub/mm.h: Declare grub_zalloc() and
3282 grub_debug_zalloc().
3283 * util/misc.c (grub_zalloc): New function.
3284 * bus/usb/uhci.c (grub_uhci_pci_iter): Use grub_zalloc()
3285 instead of grub_malloc(), remove unneeded initializations.
3286 * bus/usb/usbhub.c (grub_usb_hub_add_dev): Likewise.
3287 * commands/extcmd.c (grub_extcmd_dispatcher): Likewise.
3288 * commands/parttool.c (grub_cmd_parttool): Likewise.
3289 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): Likewise.
3290 * disk/raid5_recover.c (grub_raid5_recover): Likewise.
3291 * disk/raid6_recover.c (grub_raid6_recover): Likewise.
3292 * disk/usbms.c (grub_usbms_finddevs): Likewise.
3293 * efiemu/mm.c (grub_efiemu_request_memalign): Likewise.
3294 * efiemu/pnvram.c (grub_efiemu_pnvram): Likewise.
3295 (grub_cmd_efiemu_pnvram): Likewise.
3296 * fs/i386/pc/pxe.c (grub_pxefs_open): Likewise.
3297 * fs/iso9660.c (grub_iso9660_mount): Likewise.
3298 (grub_iso9660_iterate_dir): Likewise.
3299 * fs/jfs.c (grub_jfs_opendir): Likewise.
3300 * fs/ntfs.c (list_file): Likewise.
3301 (grub_ntfs_mount): Likewise.
3302 * kern/disk.c (grub_disk_open): Likewise.
3303 * kern/dl.c (grub_dl_load_core): Likewise.
3304 * kern/elf.c (grub_elf_file): Likewise.
3305 * kern/env.c (grub_env_context_open): Likewise.
3306 (grub_env_set): Likewise.
3307 (grub_env_set_data_slot): Likewise.
3308 * kern/file.c (grub_file_open): Likewise.
3309 * kern/fs.c (grub_fs_blocklist_open): Likewise.
3310 * loader/i386/multiboot.c (grub_module): Likewise.
3311 * loader/xnu.c (grub_xnu_create_key): Likewise.
3312 (grub_xnu_create_value): Likewise.
3313 * normal/main.c (grub_normal_add_menu_entry): Likewise.
3314 (read_config_file): Likewise.
3315 * normal/menu_entry.c (make_screen): Likewise.
3316 * partmap/sun.c (sun_partition_map_iterate): Likewise.
3317 * script/sh/lexer.c (grub_script_lexer_init): Likewise.
3318 * script/sh/script.c (grub_script_parse): Likewise.
3319 * video/bitmap.c (grub_video_bitmap_create): Likewise.
3320 * video/readers/jpeg.c (grub_video_reader_jpeg): Likewise.
3321 * video/readers/png.c (grub_png_output_byte): Likewise.
3322 (grub_video_reader_png): Likewise.
3323
830afef7 33242009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
5ce5507f 3325
3326 Enable all targets that can be built by default
3327
830afef7 3328 * configure.ac: enable efiemu runtime, grub-emu, grub-emu-usb,
5ce5507f 3329 grub-mkfont and grub-fstest if they can be built
3330
ee293aee 33312009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
3332
3333 Fix hang and segmentation fault in grub-emu-usb
3334
3335 * disk/scsi.c (grub_scsi_open): return err and not grub_errno
3336 * util/usb.c (grub_libusb_devices): likewise
3337 (grub_libusb_init): rename to ...
3338 (GRUB_MOD_INIT (libusb)):...this
3339 (grub_libusb_fini): rename to ..
3340 (GRUB_MOD_FINI (libusb)):...this
3341 * disk/usbms.c (grub_usbms_transfer): fix retry logic
3342 * include/grub/disk.h (grub_raid_init): removed, it's useless
3343 (grub_raid_fini): likewise
3344 (grub_lvm_init): likewise
3345 (grub_lvm_fini): likewise
3346 * util/grub-emu.c (main): don't call grub_libusb_init, it's done
3347 by grub_init_all
3348
94414221 33492009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
3350
3351 Fix libusb
3352
3353 * Makefile.in (LIBUSB): new macro
3354 * genmk.rb (Utility/print_tail): new method
3355 (Utility/rule): use intermediary variable #{prefix}_OBJECTS
3356 (top level): call util.print_tail at the end.
3357
59ade63d 33582009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
3359
3360 Make FreeBSD accept zpool.cache
3361
3362 * loader/i386/bsd.c (grub_freebsd_add_meta_module): spoof filename if
3363 type is /boot/zfs/zpool.cache
3364
a58da8c7 33652009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
3366
3367 Fix 64-bit efiemu
3368
3369 * include/grub/efiemu/efiemu.h (grub_efiemu_configuration_table64_t):
3370 correct wrong typedef
3371 * efiemu/prepare.c (SUFFIX (grub_efiemu_prepare)): minor style fixes
3372
20591577 33732009-07-15 Pavel Roskin <proski@gnu.org>
3374
560ca572 3375 * include/grub/disk.h (struct grub_disk_dev): Use enum for id.
3376 * kern/disk.c (struct grub_disk_cache): Likewise.
3377
e8e8e4fd 3378 * commands/probe.c (options): Typo fix.
3379
fde24e10 3380 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_BPB_END):
3381 Increase to 0x5a to accommodate FAT32. Adjust other offsets
3382 accordingly.
3383 Original patch by Yves Blusseau <yves.grub-devel@zetam.org>
3384
379c54c1 3385 * boot/i386/pc/boot.S (general_error_string): Add DOS newline at
3386 the end of "Error" to make the message more readable.
3387
7bd8f5bf 3388 * boot/i386/pc/boot.S (kernel_segment): Remove.
3389 (copy_buffer): Use GRUB_BOOT_MACHINE_KERNEL_ADDR in segment 0
3390 for destination.
3391
40b132c5 3392 * boot/i386/pc/boot.S (boot_version): Remove.
3393 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_VER_MAJ):
3394 Remove.
3395
20591577 3396 * include/grub/i386/pc/boot.h: Sort all offsets.
3397 (GRUB_BOOT_MACHINE_KERNEL_ADDRESS): Remove, it's unused.
3398 (GRUB_BOOT_MACHINE_KERNEL_SEGMENT): Likewise.
3399 * boot/i386/pc/boot.S: Assert location of every offset listed in
3400 include/grub/i386/pc/boot.h.
3401
2df32b2c 34022009-07-13 Pavel Roskin <proski@gnu.org>
3403
44b5d879 3404 * include/grub/i386/coreboot/machine.h: Rename
3405 GRUB_MACHINE_LINUXBIOS to GRUB_MACHINE_COREBOOT.
3406 * loader/multiboot_loader.c (grub_cmd_multiboot_loader): Allow
3407 multiboot 1 for GRUB_MACHINE_COREBOOT and GRUB_MACHINE_QEMU.
3408
17dc3751 3409 * kern/dl.c: Force native word size to suppress warnings when
3410 compiling grub-emu.
3411
2df32b2c 3412 * kern/device.c (grub_device_iterate): Change struct part_ent to
3413 hold the name, not a pointer to it. Use one grub_malloc() per
3414 partition, not two. Free partition_name if grub_malloc() fails.
3415 Set ents to NULL only before grub_partition_iterate() is called.
3416
75c59f59 34172009-07-11 Bean <bean123ch@gmail.com>
3418
3419 * kern/ieee1275/openfw.c (grub_children_iterate): Fix size of
3420 childname.
3421
0ae1bf88 34222009-07-10 Bean <bean123ch@gmail.com>
34232009-07-10 Robert Millan <rmh.grub@aybabtu.com>
3424
3425 * kern/ieee1275/openfw.c (grub_children_iterate)
3426 (grub_devalias_iterate): Fix size evaluation for property or path
3427 strings, which was broken since r2132.
3428
8279cade 34292009-07-07 Pavel Roskin <proski@gnu.org>
3430
7d8a52d3 3431 * commands/search.c (search_file): Merge into ...
3432 (search_fs): ... this. Accept search type as argument.
3433 (grub_cmd_search): Pass search type to search_fs().
3434
25f9a05a 3435 * include/grub/util/console.h: New file.
3436 * util/console.c: Use it instead of grub/machine/console.h.
3437 * util/grub-emu.c: Likewise.
3438
8279cade 3439 * lib/arg.c (find_long_option): Remove.
3440 (find_long): Add `len' argument, make `s' const char *.
3441 (grub_arg_parse): Parse long options in place, not in a
3442 temporary buffer.
3443
4a11b60f 34442009-07-06 Pavel Roskin <proski@gnu.org>
3445
99f68041 3446 * commands/search.c (search_fs): Fix potential NULL pointer
3447 dereference.
3448
4a11b60f 3449 * commands/search.c (search_fs): Replace QUID macro with quid_fn
3450 function pointer.
3451
e110f4de 34522009-07-06 Daniel Mierswa <impulze@impulze.org>
3453
3454 * commands/search.c (search_fs): Use grub_strcasecmp() for UUID
3455 comparison.
3456
46eeb6a2 34572009-07-05 Pavel Roskin <proski@gnu.org>
3458
bab74958 3459 * include/grub/i386/linux.h (struct linux_kernel_params):
3460 Restore padding3, it's still needed.
3461
46eeb6a2 3462 * util/grub.d/10_freebsd.in: Fix spelling of `device.hints' on
3463 FreeBSD.
3464 * util/osdetect.lua: Likewise.
3465
b4a1dc79 34662009-07-05 Bean <bean123ch@gmail.com>
3467
3468 * conf/common.rmk (lua_mode_SOURCES): Add script/lua/lstrlib.c.
3469
3470 * script/lua/grub_lib.c (grub_lua_run): Check input parameter.
3471 (grub_lua_getenv): Likewise.
3472 (grub_lua_setenv): Likewise.
3473 (save_errno): New function.
3474 (push_result): Likewise.
3475 (grub_lua_enum_device): Likewise.
3476 (grub_lua_enum_file): Likewise.
3477 (grub_lua_file_open): Likewise.
3478 (grub_lua_file_close): Likewise.
3479 (grub_lua_file_seek): Likewise.
3480 (grub_lua_file_read): Likewise.
3481 (grub_lua_file_getline): Likewise.
3482 (grub_lua_file_getsize): Likewise.
3483 (grub_lua_file_getpos): Likewise.
3484 (grub_lua_file_eof): Likewise.
3485 (grub_lua_file_exist): Likewise.
3486 (grub_lua_add_menu): Likewise.
3487
3488 * script/lua/grub_lua.h (isupper): New inline function.
3489 (islower): Likewise.
3490 (ispunct): Likewise.
3491 (isxdigit): Likewise.
3492 (strcspn): Change to normal function.
3493 (strpbkr): New function declaration.
3494 (memchr): Likewise.
3495
3496 * script/lua/grub_main.c (scan_str): New function.
3497 (strcspn): Likewise.
3498 (strpbrk): Likewise.
3499 (memchr): Likewise.
3500
3501 * script/lua/linit.c (lualibs): Enable the string library.
3502
3503 * util/osdetect.lua: New file.
3504
2da92295 35052009-07-04 Robert Millan <rmh.grub@aybabtu.com>
3506
3507 * include/grub/i386/linux.h (struct linux_kernel_params): Add
3508 `capabilities' member.
3509
b2582ec9 35102009-07-02 Pavel Roskin <proski@gnu.org>
3511
3512 * genparttoollist.sh: Add missing newline at the end.
3513
32622956 35142009-07-01 Pavel Roskin <proski@gnu.org>
3515
87a7339e 3516 * kern/x86_64/efi/callwrap.S: Add missing newline at the end.
3517
d23af54e 3518 * util/hostdisk.c (open_device): Remove `const' from
3519 `sysctl_size', as sysctlbyname() can change it (in this case it
3520 doesn't actually happen).
3521
c94b18a9 3522 * include/grub/types.h: Define GRUB_LONG_MAX and GRUB_LONG_MIN
3523 using signed long int constants.
3524
c6cd3ef0 3525 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): Make `p'
3526 constant to avoid a warning on FreeBSD.
3527
0df63420 3528 * util/hostdisk.c (device_is_wholedisk): Compile only on systems
3529 where it's needed.
3530
999577f1 3531 * Makefile.in: Install include/grub/machine symlink.
3532
6f41557f 3533 * Makefile.in: When installing symlinks, use "cp -fR", which
3534 works on FreeBSD and MacOSX.
3535 From Yves Blusseau <cl7m42e02@sneakemail.com>
3536
c8d22988 3537 * kern/dl.c (grub_dl_resolve_symbol): Make static.
3538 * include/grub/dl.h: Remove grub_dl_resolve_symbol().
3539
1b96e952 3540 * util/misc.c: Move grub_reboot() and grub_halt() ...
3541 * util/grub-emu.c: ... here. Make main_env static.
3542 * include/grub/util/misc.h: Remove main_env.
3543
2ef0084d 3544 * kern/mm.c: Use correct format to print size_t.
3545
32622956 3546 * include/grub/elf.h: Define Elf_Sword and Elf_Xword.
3547 * kern/i386/dl.c: Use ELF symbols without "32" or "64".
3548 * kern/powerpc/dl.c: Likewise.
3549 * kern/sparc64/dl.c: Likewise.
3550 * kern/x86_64/dl.c: Likewise.
3551
3f7f0cd0 35522009-07-01 Robert Millan <rmh.grub@aybabtu.com>
3553
3554 Fix grub-emu build on sparc64-ieee1275.
3555
75421ca9 3556 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Synchronize with ...
3f7f0cd0 3557 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): ... this.
3558
211d06b5 35592009-07-01 Robert Millan <rmh.grub@aybabtu.com>
3560
3561 * util/misc.c: Include `<setjmp.h>' and `<grub/machine/machine.h>'.
3562 (grub_reboot, grub_halt): New functions.
3563
3564 * util/i386/pc/misc.c: Delete. Update all users.
3565 * util/sparc64/ieee1275/misc.c: Likewise.
3566 * util/powerpc/ieee1275/misc.c: Likewise.
3567
aaf53e3c 35682009-07-01 Robert Millan <rmh.grub@aybabtu.com>
3569
3570 * conf/i386.rmk (setjmp_mod_SOURCES)
3571 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): Move to ...
3572 * conf/common.rmk (setjmp_mod_SOURCES)
3573 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): ... here, and modify
3574 to use $(target_cpu).
3575 * conf/x86_64-efi.rmk (setjmp_mod_SOURCES)
3576 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): Remove.
3577 * conf/powerpc-ieee1275.rmk: Likewise.
3578 * conf/sparc64-ieee1275.rmk: Likewise.
3579
3580 * conf/i386-pc.rmk (kernel_img_SOURCES): Use
3581 $(target_cpu) for kern/$(target_cpu)/dl.c.
3582 * conf/i386-efi.rmk: Likewise.
3583 * conf/i386-ieee1275.rmk: Likewise.
3584 * conf/x86_64-efi.rmk: Likewise.
3585 * conf/i386-coreboot.rmk: Likewise.
3586 * conf/powerpc-ieee1275.rmk (kernel_img_SOURCES): Use
3587 $(target_cpu) for kern/$(target_cpu)/dl.c and for
3588 kern/$(target_cpu)/cache.S.
3589 * conf/sparc64-ieee1275.rmk: Likewise.
3590
a337130b 35912009-07-01 Robert Millan <rmh.grub@aybabtu.com>
3592
3593 * include/grub/i386/linux.h (linux_kernel_params): Change `mmap_size'
3594 type to `grub_uint8_t', and adjust `padding9' accordingly.
3595
c6fe4d53 35962009-06-29 Robert Millan <rmh.grub@aybabtu.com>
3597
b09db61d 3598 * include/grub/i386/linux.h (GRUB_VIDEO_TYPE_TEXT): New macro.
3599
c6fe4d53 3600 * loader/i386/linux.c [__i386__] (grub_linux_boot): Simplify inline
3601 assembly in final jump, using register constraints.
3602
b09db61d 3603 (grub_linux_boot): For text mode, initialize `have_vga' using
3604 GRUB_VIDEO_TYPE_TEXT rather than 0 (this changes its value to 1).
3605
3606 Initialize `video_cursor_x' and `video_cursor_y' as late as possible,
3607 right before the final jump.
3608
3609 Set `video_mode' to 0x3.
3610
3611 Document initialization of `video_page', `video_mode' and
3612 `video_ega_bx'.
3613
28333ad0 36142009-06-29 Robert Millan <rmh.grub@aybabtu.com>
3615
3616 * include/grub/i386/linux.h (GRUB_LINUX_FLAG_QUIET): New macro.
3617 * loader/i386/linux.c (grub_cmd_linux): Recognize "quiet" option,
75421ca9 3618 and set GRUB_LINUX_FLAG_QUIET appropriately.
28333ad0 3619
02164e1b 36202009-06-29 Robert Millan <rmh.grub@aybabtu.com>
3621
3622 Fix build on Debian / sparc.
3623
3624 * configure.ac: Recognize `sparc' target_cpu (as sparc64).
3625
18b6c557 36262009-06-28 Pavel Roskin <proski@gnu.org>
3627
85f2aab6 3628 * kern/i386/qemu/mmap.c (grub_machine_mmap_iterate): Use cast to
3629 fix a warning.
3630
18b6c557 3631 * util/grub.d/10_linux.in: Match SUSE style initrd names.
3632
ad760f81 36332009-06-27 Robert Millan <rmh.grub@aybabtu.com>
3634
3635 * loader/i386/linux.c (grub_linux_boot): Fix uninitialized use of
3636 `err'.
3637
87a4623b 36382009-06-27 Robert Millan <rmh.grub@aybabtu.com>
3639
3640 Revert r2338.
3641
3642 * loader/i386/linux.c (grub_cmd_linux): Don't call grub_error when
3643 file can't be opened. grub_file_open() is already supposed to set
75421ca9 3644 grub_errno / grub_errmsg appropriately.
87a4623b 3645 * loader/i386/pc/linux.c (grub_cmd_linux): Likewise.
3646
8231fb77 36472009-06-27 Pavel Roskin <proski@gnu.org>
36482009-06-27 Robert Millan <rmh.grub@aybabtu.com>
3649
3650 * include/grub/dl.h: Include grub/elf.h.
3651 (struct grub_dl): Add symtab field.
3652 * kern/dl.c [GRUB_MACHINE_QEMU]: Define
3653 GRUB_MODULES_MACHINE_READONLY.
3654 (grub_dl_resolve_symbols): Populate mod->symtab, making a copy
3655 of the header for read-only modules.
3656 (grub_dl_unload): Free mod->symtab for read-only modules.
3657 * kern/i386/dl.c: Use mod->symtab.
3658 * kern/powerpc/dl.c: Likewise.
3659 * kern/sparc64/dl.c: Likewise.
3660 * kern/x86_64/dl.c: Likewise.
3661
3662 * conf/i386-qemu.rmk: New file.
3663 * kern/i386/qemu/startup.S: Likewise.
3664 * kern/i386/qemu/mmap.c: Likewise.
3665 * boot/i386/qemu/boot.S: Likewise.
3666 * include/grub/i386/qemu/time.h: Likewise.
3667 * include/grub/i386/qemu/serial.h: Likewise.
3668 * include/grub/i386/qemu/kernel.h: Likewise.
3669 * include/grub/i386/qemu/console.h: Likewise.
3670 * include/grub/i386/qemu/boot.h: Likewise.
3671 * include/grub/i386/qemu/init.h: Likewise.
3672 * include/grub/i386/qemu/machine.h: Likewise.
3673 * include/grub/i386/qemu/loader.h: Likewise.
3674 * include/grub/i386/qemu/memory.h: Likewise.
3675
3676 * conf/i386-coreboot.rmk (GRUB_BOOT_MACHINE_LINK_ADDR)
3677 (GRUB_KERNEL_MACHINE_LINK_ADDR): New variables.
3678 [qemu] (pkglib_IMAGES): Add `boot.img'.
3679 [qemu] (boot_img_SOURCES, boot_img_ASFLAGS, boot_img_LDFLAGS)
3680 [qemu] (boot_img_FORMAT): New variables.
3681 [qemu] (bin_UTILITIES): Add `grub-mkimage'.
3682 [qemu] (grub_mkimage_SOURCES, grub_mkimage_CFLAGS): New variables.
3683 [qemu] (kernel_img_SOURCES, kernel_img_HEADERS, kernel_img_CFLAGS)
3684 [qemu] (kernel_img_ASFLAGS, kernel_img_LDFLAGS)
3685 [qemu] (kernel_img_FORMAT): New variables.
3686
3687 * configure.ac: Recognise `i386-qemu'.
3688
3689 * util/i386/pc/grub-mkimage.c (compress_kernel): Add dummy variant
3690 (for no compression).
3691 [GRUB_MACHINE_QEMU] (generate_image): Misc adjustments to produce
3692 a valid i386 ROM image. Make `GRUB_KERNEL_MACHINE_COMPRESSED_SIZE',
3693 `GRUB_KERNEL_MACHINE_INSTALL_DOS_PART' and
3694 `GRUB_KERNEL_MACHINE_INSTALL_BSD_PART' optional features (with
3695 ifdefs).
3696
97fe384e 36972009-06-27 Pavel Roskin <proski@gnu.org>
3698
3699 * efiemu/prepare.c: Eliminate TYPE macro, it makes code hard to
3700 read.
3701 * efiemu/prepare32.c: Likewise.
3702 * efiemu/prepare64.c: Likewise.
3703
c402ab17 37042009-06-26 Pavel Roskin <proski@gnu.org>
3705
3706 * include/grub/types.h: Define GRUB_TARGET_WORDSIZE.
3707 * include/grub/elf.h: Define symbols without "32" or "64" based
3708 on GRUB_TARGET_WORDSIZE.
3709 * include/grub/multiboot2.h: Use GRUB_TARGET_WORDSIZE.
3710 * efiemu/loadcore32.c: Redefine GRUB_TARGET_WORDSIZE, remove own
3711 ELF definitions.
3712 * efiemu/loadcore64.c: Likewise.
3713 * loader/i386/bsd32.c: Likewise.
3714 * loader/i386/bsd64.c: Likewise.
3715 * kern/dl.c: Remove own ELF definitions.
3716 * util/i386/efi/grub-mkimage.c: Likewise.
3717
9bbdfd4d 37182009-06-23 Robert Millan <rmh.grub@aybabtu.com>
3719
3720 * kern/i386/pc/startup.S (real_to_prot): Access `gdtdesc' using
3721 segment 0x0 unconditionally, because the reference generated by
3722 GAS is an absolute address.
3723
a42ce6e9 37242009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3725
3726 * include/grub/i386/kernel.h: Include `<grub/machine/machine.h>'.
3727 [! GRUB_MACHINE_IEEE1275]: Set `GRUB_MOD_ALIGN' to 0x1.
3728
c952cf92 37292009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3730
3731 * commands/search.c (grub_cmd_search): Macroify hardcoded args[]
3732 indexes. Check for -f explicitly.
cc3752ad 3733 (search_file): Improve error message.
3734 (GRUB_MOD_INIT(search)): Add missing `-n' to help output.
c952cf92 3735
132a0a59 37362009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3737
3738 * conf/i386-pc.rmk (GRUB_MEMORY_MACHINE_LINK_ADDR): Rename to ...
3739 (GRUB_KERNEL_MACHINE_LINK_ADDR): ... this. Update all users.
3740
387a140c 37412009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3742
3743 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/misc.S'.
3744 * conf/i386-ieee1275.rmk: Likewise.
3745 * conf/i386-coreboot.rmk: Likewise.
3746
3747 * kern/i386/pc/startup.S (grub_stop): Remove function.
3748 * kern/i386/ieee1275/startup.S: Likewise.
3749 * kern/i386/coreboot/startup.S: Likewise.
3750 * kern/i386/misc.S (grub_stop): New function.
3751
41da9665 37522009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3753
3754 * kern/i386/pc/startup.S (real_to_prot): Move from here ...
3755 * kern/i386/realmode.S (real_to_prot): ... to here.
3756
bf337234 37572009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3758
3759 * conf/i386-ieee1275.rmk (pkglib_PROGRAMS): Replace `kernel.elf'
3760 with `kernel.img'.
3761 (kernel_elf_SOURCES): Rename to ...
3762 (kernel_img_SOURCES): ... this.
3763 (kernel_elf_HEADERS): Rename to ...
3764 (kernel_img_HEADERS): ... this. Update all users.
3765 (kernel_elf_ASFLAGS): Rename to ...
3766 (kernel_img_ASFLAGS): ... this.
3767 (kernel_elf_CFLAGS): Rename to ...
3768 (kernel_img_CFLAGS): ... this.
3769 (kernel_elf_LDFLAGS): Rename to ...
3770 (kernel_img_LDFLAGS): ... this.
3771 * conf/i386-coreboot.rmk: Likewise.
3772 * conf/powerpc-ieee1275.rmk: Likewise.
3773
3774 * util/elf/grub-mkimage.c (add_segments): Replace "kernel.elf"
3775 with "kernel.img".
3776
f52196ff 37772009-06-21 Pavel Roskin <proski@gnu.org>
3778
c3cee413 3779 * loader/powerpc/ieee1275/linux.c (offset_phdr): Fix prototypes
3780 to match nested functions.
3781 * loader/sparc64/ieee1275/linux.c: Likewise.
3782
f52196ff 3783 * conf/i386-ieee1275.rmk: Define kernel_elf_ASFLAGS.
3784
58750afc 37852009-06-21 Robert Millan <rmh.grub@aybabtu.com>
3786
3787 * configure.ac: Enable `END_SYMBOL' / `BSS_START_SYMBOL' test on
3788 all i386 platforms.
3789
15355c7d 37902009-06-21 Robert Millan <rmh.grub@aybabtu.com>
3791
3792 Fix asm file handling on ELF, and remove workarounds.
3793
3794 * genmk.rb (class Programs): Detect assembly files, and set ASFLAGS
75421ca9 3795 and -DASM_FILE=1 appropriately (copied from `class Images' stanza).
15355c7d 3796 * kern/i386/ieee1275/startup.S (ASM_FILE): Remove macro.
3797 * kern/i386/coreboot/startup.S (ASM_FILE): Likewise.
3798
3f3ec72b 37992009-06-21 Vladimir Serbinenko <phcoder@gmail.com>
3800
3801 Load BSD ELF modules
3802
3803 * conf/i386-pc.rmk (bsd_mod_SOURCES): Add loader/i386/bsd32.c
3804 and loader/i386/bsd64.c
3805 * include/grub/i386/bsd.h (FREEBSD_MODTYPE_MODULE): Remove
3806 (FREEBSD_MODTYPE_ELF_MODULE): New definition
3807 (FREEBSD_MODTYPE_ELF_MODULE_OBJ): Likewise
3808 (grub_freebsd_load_elfmodule32): New declaration
3809 (grub_freebsd_load_elfmoduleobj64): Likewise
3810 (grub_freebsd_load_elf_meta32): Likewise
3811 (grub_freebsd_load_elf_meta64): Likewise
3812 (grub_freebsd_add_meta): Likewise
3813 (grub_freebsd_add_meta_module): Likewise
3814 * loader/i386/bsd.c (grub_freebsd_add_meta): Make global
3815 (grub_freebsd_add_meta_module): Likewise and move module-specific
3816 parts to grub_cmd_freebsd and grub_cmd_freebsd_module
3817 (grub_cmd_freebsd): Add elf-kernel specific parts
3818 based on grub_freebsd_add_meta_module
3819 (grub_cmd_freebsd_module): Add type parsing moved from
3820 grub_freebsd_add_meta_module
3821 (grub_cmd_freebsd_module_elf): New function
3822 (cmd_freebsd_module_elf): New variable
3823 (GRUB_MOD_INIT): Register freebsd_module_elf
3824 * loader/i386/bsd32.c: New file
3825 * loader/i386/bsd64.c: Likewise
3826 * loader/i386/bsdXX.c: Likewise
3827 * kern/elf.c (grub_elf32_load): Let hook decide which pheaders to load
3828 (grub_elf64_load): Likewise
3829 * include/grub/elfload.h (grub_elf32_load_hook_t): New parameter do_load
3830 All users updated
3831 (grub_elf64_load_hook_t): Likewise
3832
0db15301 38332009-06-21 Colin Watson <cjwatson@ubuntu.com>
3834
3835 * util/grub-mkconfig.in (GRUB_DISABLE_LINUX_RECOVERY): Export
3836 variable.
3837 * util/grub.d/10_linux.in: If GRUB_DISABLE_LINUX_RECOVERY is true,
3838 don't write a menu entry for recovery mode.
3839
546796c1 38402009-06-20 Robert Millan <rmh.grub@aybabtu.com>
3841
3842 * util/i386/pc/grub-mkimage.c (main): Oops, free `output' only
3843 after it's no longer needed.
3844
cd7310d5 38452009-06-20 Robert Millan <rmh.grub@aybabtu.com>
3846
3847 * include/grub/i386/loader.h (grub_linux_prot_size)
3848 (grub_linux_tmp_addr, grub_linux_real_addr)
3849 (grub_linux_is_bzimage, grub_linux16_boot): Declare only on
3850 GRUB_MACHINE_PCBIOS.
3851 * util/i386/pc/grub-mkimage.c (compress_kernel): Move
3852 common grub_util_info() call to ...
3853 (generate_image): ... here.
3854 Fix use of uninitialized memory, comparison of signed with
3855 unsigned integers and memory leak.
3856 Remove bogus module address message.
3857
ab32d3b5 38582009-06-20 Vladimir Serbinenko <phcoder@gmail.com>
3859
3860 * disk/mdraid_linux.c (GRUB_MOD_FINI): use grub_raid_unregister and not
3861 grub_raid_register
3862 * disk/dmraid_nvidia.c (GRUB_MOD_FINI): likewise
3863
024ef597 38642009-06-19 Pavel Roskin <proski@gnu.org>
3865
3866 * configure.ac: Remove stray AC_MSG_CHECKING.
3867
3ac72b51 38682009-06-19 Vladimir Serbinenko <phcoder@gmail.com>
3869
3870 * disk/scsi.c (grub_scsi_open): use continue instead of big if
dd74360c 3871
e14cd814 38722009-06-18 Pavel Roskin <proski@gnu.org>
3873
3874 * conf/common.rmk: Add fs_file.mod.
3875 * disk/fs_file.c: New file.
3876 * include/grub/disk.h (enum grub_disk_dev_id): Add
3877 GRUB_DISK_DEVICE_FILE_ID.
3878
26586d98 38792009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
3880
3881 Fix build with Apple's toolchain. Part 2
3882
3883 * aclocal.m4 (grub_PROG_TARGET_CC): add missing prototype for main and
3884 a fake start
3885
26de2bcd 38862009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
3887
3888 Fix build with Apple's toolchain. Part 1
3889
3890 * commands/i386/pc/drivemap_int13h.S: use assembly-time constants
3891 for long calls
3892 * configure.ac: remove a leftover AC_MSG_RESULT
dd74360c 3893 (CFLAGS): don't add -Wl,--defsym,___main=0x8100 when building with
26de2bcd 3894 Apple's toolchain
3895
09b3490b 38962009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
3897
3898 Fix warnings
3899
3900 * fs/ntfscomp.c (decomp_get16): initialize c1 and c2
3901 (decomp_block): initialize ch
3902 use grub_memcpy instead of memcpy
3903
c22a006a 39042009-06-17 Pavel Roskin <proski@gnu.org>
3905
d3638678 3906 * include/grub/i386/coreboot/console.h: Don't use the i386-pc
3907 version, use declarations needed to use vga_text as the startup
3908 console.
3909
c22a006a 3910 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Remove
3911 term/i386/pc/at_keyboard.c, it doesn't need to be compiled into
3912 the kernel.
3913 * kern/i386/coreboot/init.c: Don't call grub_at_keyboard_init()
3914 and grub_at_keyboard_fini(), it's done on module load and
3915 unload.
3916
05b129e0 39172009-06-17 Felix Zielcke <fzielcke@z-51.de>
3918
3919 * loader/i386/linux.c (grub_cmd_linux): Set grub_error if the
3920 file can't be found.
3921 * loader/i386/pc/linux.c (grub_cmd_linux): Likewise.
3922
cf24ed9e 39232009-06-17 Vladimir Serbinenko <phcoder@gmail.com>
3924
3925 Fix newline handling
3926
3927 * include/grub/script_sh.h (grub_lexer_param): new field was_newline
dd74360c 3928 * script/sh/lexer.c (grub_script_lexer_init): initialize was_newline
cf24ed9e 3929 (grub_script_yylex): don't segfault on unterminated script
3930 newline terminates command and variable
3931
74aa8e4b 39322009-06-17 Vladimir Serbinenko <phcoder@gmail.com>
3933
3934 avoid double grub_adjust_range call. Bug reported by David Simner
3935
3936 * kern/disk.c (grub_disk_write): change to raw disk access before
3937 calling disk_read
3938
1bd265f3 39392009-06-17 Colin Watson <cjwatson@ubuntu.com>
3940
3941 * util/elf/grub-mkimage.c (usage): Prefix each option line with two
3942 spaces, for the benefit of help2man.
3943 * util/i386/efi/grub-mkimage.c (usage): Likewise.
3944
a2d08c06 39452009-06-16 Pavel Roskin <proski@gnu.org>
3946
3947 * kern/i386/halt.c: Include grub/machine/init.h.
3948 * kern/i386/reboot.c: Include grub/cpu/reboot.h.
3949
b97bcb19 39502009-06-16 Felix Zielcke <fzielcke@z-51.de>
3951
3952 * util/grub.d/30_os-prober.in: Use ${root} in the generated
3953 drivemap menuentry.
3954
0644f96c 39552009-06-16 James Jarvis <James.Jarvis@ed.ac.uk>
3956
3957 * commands/help.c GRUB_MOD_INIT(echo): Fix the help output of
3958 `echo' command.
3959
3ef17a2e 39602009-06-16 Pavel Roskin <proski@gnu.org>
3961
3962 * boot/i386/pc/boot.S: Remove root_drive. Assert offset of
3963 boot_drive_check by using GRUB_BOOT_MACHINE_DRIVE_CHECK. Don't
3964 save %dx, we only need %dl and we never change it.
3965 * boot/i386/pc/cdboot.S: Don't set the root drive.
3966 * boot/i386/pc/pxeboot.S: Likewise.
3967 * include/grub/i386/pc/boot.h: Remove
3968 GRUB_BOOT_MACHINE_ROOT_DRIVE, adjust
3969 GRUB_BOOT_MACHINE_DRIVE_CHECK.
3970 * include/grub/i386/pc/kernel.h: Remove grub_root_drive.
3971 * kern/i386/pc/init.c (make_install_device): Remove references
3972 to grub_root_drive.
3973 * kern/i386/pc/startup.S: Likewise.
3974 * util/i386/pc/grub-setup.c (setup): Don't set root_drive.
3975
693fe637 39762009-06-16 Vladimir Serbinenko <phcoder@gmail.com>
3977
3978 xnu_uuid command
3979
3980 * commands/xnu_uuid.c: new file
3981 * conf/common.rmk (pkglib_MODULES): add xnu_uuid.mod
3982 (xnu_uuid_mod_SOURCES): new variable
3983 (xnu_uuid_mod_CFLAGS): likewise
3984 (xnu_uuid_mod_LDFLAGS): likewise
3985 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/probe.c
3986 * conf/i386-ieee1275.rmk: likewise
3987 * conf/i386-pc.rmk: likewise
3988 * conf/powerpc-ieee1275.rmk: likewise
3989 * conf/sparc64-ieee1275.rmk: likewise
3990 * util/grub.d/30_os-prober.in: use UUID for Mac OS X/Darwin
3991
c9da87d0 39922009-06-16 Pavel Roskin <proski@gnu.org>
3993
3994 * configure.ac: Avoid '==' in test command, it's not portable.
3995
9c6f4596 39962009-06-16 Vladimir Serbinenko <phcoder@gmail.com>
3997
3998 Probe command
3999
4000 * commands/probe.c: new file
4001 * conf/common.rmk (pkglib_MODULES): add probe.mod
4002 (probe_mod_SOURCES): new variable
4003 (probe_mod_CFLAGS): likewise
4004 (probe_mod_LDFLAGS): likewise
4005 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/probe.c
4006 * conf/i386-ieee1275.rmk: likewise
4007 * conf/i386-pc.rmk: likewise
4008 * conf/powerpc-ieee1275.rmk: likewise
4009 * conf/sparc64-ieee1275.rmk: likewise
4010
70b7f9fd 40112009-06-15 Vladimir Serbinenko <phcoder@gmail.com>
4012
4013 Fix handling of string like \"hello\" and "a
4014 b"
4015
4016 * script/sh/lexer.c (check_textstate): accept GRUB_PARSER_STATE_ESC
4017 (grub_script_yylex): fix parsing of quoting, escaping and newline
4018
71c79a6b 40192009-06-13 Vladimir Serbinenko <phcoder@gmail.com>
4020
dd74360c 4021 * loader/i386/multiboot.c (grub_multiboot_get_bootdev): fix partition
71c79a6b 4022 handling
dd74360c 4023
0644f96c 40242009-06-13 Jun Inoue <jun.lambda@gmail.com>
880fc3c4 4025
4026 * util/grub-mkconfig.in: Fix parsing of --output option.
4027
e40893c3 40282009-06-12 Pavel Roskin <proski@gnu.org>
4029
4030 * Makefile.in (pkgdata_SRCDIR): Remove. genmodsrc.sh and
4031 genmk.rb don't need to be generated or installed.
4032
3a1acfe2 40332009-06-12 Vladimir Serbinenko <phcoder@gmail.com>
4034
4035 * commands/i386/pc/drivemap_int13h.S: add more comments
4036
3a4575d4 40372009-06-11 Pavel Roskin <proski@gnu.org>
4038
0658e928 4039 * Makefile.in (uninstall): Uninstall manuals.
4040
ca0388f0 4041 * Makefile.in: Rename lib_DATA to lib_SCRIPTS, move it from
4042 PKGLIB to SCRIPTS. This fixes installation of grub-mkconfig_lib
4043 and update-grub_lib in two places.
4044 * conf/common.rmk: Rename lib_DATA to lib_SCRIPTS.
4045
e3b27c39 4046 * disk/usbms.c (grub_usbms_transfer): Initialize `err' to fix
4047 a compiler warning.
4048
3a4575d4 4049 * loader/i386/bsd.c (grub_freebsd_boot): Rename `entry' to
4050 `entry_lo' to fix variable shadowing.
4051
af1f4f55 40522009-06-11 Christian Franke <franke@computer.org>
4053
4054 * kern/misc.c (__enable_execute_stack): Add missing return type
4055 to prevent gcc warning.
4056
5225e649 40572009-06-11 Felix Zielcke <fzielcke@z-51.de>
4058
4059 * conf/i386-ieee1275.rmk (COMMON_LDFLAGS): Remove `-static -lgcc'.
4060
7d83bd47 40612009-06-11 Pavel Roskin <proski@gnu.org>
4062
c1cb63ba 4063 * Makefile.in: Don't rely on any scripts being executable.
4064 Always use $(SHELL) to run shell scripts.
4065
7d83bd47 4066 * configure.ac: Always define ___main if using -nostdlib. This
4067 fixes tests on Cygwin.
4068
948f48e7 40692009-06-11 Giuseppe Caizzone <acaizzo@gmail.com>
4070
4071 UDF fix
4072
7d83bd47 4073 * fs/udf.c (grub_udf_read_block): handle the fact that ad->length
948f48e7 4074 is in bytes and not in blocks
7d83bd47 4075
8ada9bc1 40762009-06-11 Pavel Roskin <proski@gnu.org>
4077
4078 * kern/i386/halt.c (grub_halt): Make `i' unsigned to fix a
4079 warning.
4080
25ad2323 40812009-06-11 Felix Zielcke <fzielcke@z-51.de>
4082
4083 * util/grub.d/30_os-prober.in: Fix a comment. Source
4084 ${libdir}/grub/grub-mkconfig_lib. Use prepare_grub_to_access_device
4085 to set the root device. Place drivemap command in the generated
4086 chain entry.
4087
e65acb0c 40882009-06-11 Pavel Roskin <proski@gnu.org>
4089
4090 * configure.ac: Remove host_m32. Issues with 64-bit utilities
4091 have long been resolved.
4092
f285fe2d 40932009-06-11 Colin Watson <cjwatson@ubuntu.com>
4094
bd47b0b5 4095 * util/grub.d/10_linux.in: Capitalise "Linux".
4096
f285fe2d 4097 * util/grub-pe2elf.c (usage): Fix references to grub-editenv.
4098
a0c62e4e 40992009-06-11 Pavel Roskin <proski@gnu.org>
4100
b6783cb2 4101 * kern/efi/efi.c (grub_exit): Add infinite loop at the end to
4102 fix a gcc warning and ensure that the function won't ever exit.
4103
dde032e8 4104 * kern/i386/ieee1275/init.c: Add missing prototype for
4105 grub_stop_floppy().
4106
22cd079d 4107 * loader/ieee1275/multiboot2.c [__i386__]: Include
4108 grub/cpu/multiboot.h.
4109
a0c62e4e 4110 * term/i386/pc/serial.c (serial_translate_key_sequence): Avoid
4111 casts to short - they are not portable and cause warnings. Fix
4112 use of uninitialized values in input_buf. Use ARRAY_SIZE.
4113
63963d17 41142009-06-11 Vladimir Serbinenko <phcoder@gmail.com>
4115
4116 Drivemap fixes
4117
4118 * commands/i386/pc/drivemap.c (grub_get_root_biosnumber_drivemap):
4119 new function
4120 (grub_get_root_biosnumber_saved): new variable
4121 (GRUB_MOD_INIT): register grub_get_root_biosnumber_drivemap
4122 (GRUB_MOD_FINI): unregister grub_get_root_biosnumber_drivemap
775dbc4d 4123 * commands/i386/pc/drivemap_int13h.S (grub_drivemap_handler): restore
63963d17 4124 %dx after the call if necessary
4125 * conf/common.rmk (pkglib_MODULES): remove boot.mod
4126 (boot_mod_SOURCES): remove
4127 (boot_mod_CFLAGS): remove
4128 (boot_mod_LDFLAGS): remove
4129 * conf/i386-coreboot.rmk (pkglib_MODULES): add boot.mod
4130 (boot_mod_SOURCES): new variable
4131 (boot_mod_CFLAGS): likewise
4132 (boot_mod_LDFLAGS): likewise
4133 * conf/i386-efi.rmk: likewise
4134 * conf/i386-ieee1275.rmk: likewise
4135 * conf/i386-pc.rmk: likewise
4136 * conf/powerpc-ieee1275.rmk: likewise
4137 * conf/sparc64-ieee1275.rmk: likewise
4138 * conf/x86_64-efi.rmk: likewise
4139 * include/grub/i386/pc/biosnum.h: new file
4140 * lib/i386/pc/biosnum.c: likewise
4141 * loader/i386/bsd.c (grub_bsd_get_device): use grub_get_root_biosnumber
4142 * loader/i386/multiboot.c (grub_multiboot_get_bootdev): likewise
4143 * loader/i386/pc/chainloader.c (grub_chainloader_cmd): likewise
775dbc4d 4144
33abf7ae 41452009-06-10 Pavel Roskin <proski@gnu.org>
4146
5ac35b35 4147 * io/gzio.c (test_header): Don't reuse one buffer for all data.
4148 Use separate variables. Read only the file size at the end, but
4149 not the checksum that we don't use.
4150
5c5215d5 4151 * kern/file.c (grub_file_read): Use void pointer for the buffer.
4152 Adjust all callers.
4153
27d5fef7 4154 * kern/ieee1275/openfw.c: Remove libc includes.
4155 * kern/ieee1275/cmain.c: Likewise.
4156 * include/grub/ieee1275/ieee1275.h: Likewise.
4157
33abf7ae 4158 * kern/i386/coreboot/init.c: Include grub/cpu/tsc.h to fix
4159 compiler warnings.
4160
19d50c2b 41612009-06-10 Felix Zielcke <fzielcke@z-51.de>
4162
4163 * Makefile.in: Remove all trailing whitespace.
4164 * conf/i386-pc.rmk: Likewise.
4165 * conf/powerpc-ieee1275.rmk: Likewise.
4166 * conf/sparc64-ieee1275.rmk: Likewise.
4167 * docs/grub.texi: Likewise.
4168 * docs/texinfo.tex: Likewise.
4169 * disk/fs_uuid.c: Likewise.
4170 * disk/lvm.c: Likewise.
4171 * disk/scsi.c: Likewise.
4172 * disk/ata.c: Likewise.
4173 * disk/ieee1275/ofdisk.c: Likewise.
4174 * disk/i386/pc/biosdisk.c: Likewise.
4175 * disk/host.c: Likewise.
4176 * disk/raid.c: Likewise.
4177 * disk/efi/efidisk.c: Likewise.
4178 * disk/usbms.c: Likewise.
4179 * disk/memdisk.c: Likewise.
4180 * disk/loopback.c: Likewise.
4181 * kern/powerpc/dl.c: Likewise.
4182 * kern/device.c: Likewise.
4183 * kern/dl.c: Likewise.
4184 * kern/sparc64/dl.c: Likewise.
4185 * kern/ieee1275/ieee1275.c: Likewise.
4186 * kern/term.c: Likewise.
4187 * kern/fs.c: Likewise.
4188 * kern/i386/dl.c: Likewise.
4189 * kern/i386/pc/startup.S: Likewise.
4190 * kern/i386/pc/init.c: Likewise.
4191 * kern/i386/pc/mmap.c: Likewise.
4192 * kern/i386/pc/lzo1x.S: Likewise.
4193 * kern/i386/ieee1275/init.c: Likewise.
4194 * kern/i386/realmode.S: Likewise.
4195 * kern/i386/tsc.c: Likewise.
4196 * kern/partition.c: Likewise.
4197 * kern/corecmd.c: Likewise.
4198 * kern/file.c: Likewise.
4199 * kern/efi/efi.c: Likewise.
4200 * kern/efi/init.c: Likewise.
4201 * kern/efi/mm.c: Likewise.
4202 * kern/main.c: Likewise.
4203 * kern/err.c: Likewise.
4204 * kern/env.c: Likewise.
4205 * kern/disk.c: Likewise.
4206 * kern/generic/millisleep.c: Likewise.
4207 * kern/generic/rtc_get_time_ms.c: Likewise.
4208 * kern/misc.c: Likewise.
4209 * kern/parser.c: Likewise.
4210 * genmk.rb: Likewise.
4211 * configure.ac: Likewise.
4212 * boot/i386/pc/diskboot.S: Likewise.
4213 * boot/i386/pc/pxeboot.S: Likewise.
4214 * boot/i386/pc/boot.S: Likewise.
4215 * boot/i386/pc/lnxboot.S: Likewise.
4216 * boot/i386/pc/cdboot.S: Likewise.
4217 * parttool/pcpart.c: Likewise.
4218 * video/readers/tga.c: Likewise.
4219 * video/video.c: Likewise.
4220 * video/bitmap.c: Likewise.
4221 * lib/envblk.c: Likewise.
4222 * lib/i386/setjmp.S: Likewise.
4223 * fs/xfs.c: Likewise.
4224 * fs/afs.c: Likewise.
4225 * fs/fat.c: Likewise.
4226 * fs/ntfs.c: Likewise.
4227 * fs/udf.c: Likewise.
4228 * fs/affs.c: Likewise.
4229 * fs/iso9660.c: Likewise.
4230 * fs/hfs.c: Likewise.
4231 * fs/fshelp.c: Likewise.
4232 * fs/ext2.c: Likewise.
4233 * fs/jfs.c: Likewise.
4234 * fs/reiserfs.c: Likewise.
4235 * fs/hfsplus.c: Likewise.
4236 * fs/minix.c: Likewise.
4237 * fs/cpio.c: Likewise.
4238 * fs/sfs.c: Likewise.
4239 * fs/ufs.c: Likewise.
4240 * efiemu/prepare.c: Likewise.
4241 * efiemu/loadcore_common.c: Likewise.
4242 * efiemu/runtime/efiemu.sh: Likewise.
4243 * efiemu/runtime/efiemu.S: Likewise.
4244 * efiemu/runtime/efiemu.c: Likewise.
4245 * efiemu/pnvram.c: Likewise.
4246 * efiemu/main.c: Likewise.
4247 * efiemu/i386/pc/cfgtables.c: Likewise.
4248 * efiemu/i386/loadcore64.c: Likewise.
4249 * efiemu/i386/loadcore32.c: Likewise.
4250 * efiemu/loadcore.c: Likewise.
4251 * efiemu/symbols.c: Likewise.
4252 * efiemu/mm.c: Likewise.
4253 * include/grub/autoefi.h: Likewise.
4254 * include/grub/datetime.h: Likewise.
4255 * include/grub/term.h: Likewise.
4256 * include/grub/hfs.h: Likewise.
4257 * include/grub/lvm.h: Likewise.
4258 * include/grub/i386/tsc.h: Likewise.
4259 * include/grub/i386/linux.h: Likewise.
4260 * include/grub/i386/xnu.h: Likewise.
4261 * include/grub/i386/efiemu.h: Likewise.
4262 * include/grub/i386/pc/biosdisk.h: Likewise.
4263 * include/grub/i386/pc/memory.h: Likewise.
4264 * include/grub/i386/pc/vbe.h: Likewise.
4265 * include/grub/parttool.h: Likewise.
4266 * include/grub/video.h: Likewise.
4267 * include/grub/memory.h: Likewise.
4268 * include/grub/fs.h: Likewise.
4269 * include/grub/partition.h: Likewise.
4270 * include/grub/xnu.h: Likewise.
4271 * include/grub/efi/api.h: Likewise.
4272 * include/grub/efi/pe32.h: Likewise.
4273 * include/grub/efi/memory.h: Likewise.
4274 * include/grub/multiboot.h: Likewise.
4275 * include/grub/usbdesc.h: Likewise.
4276 * include/grub/multiboot2.h: Likewise.
4277 * include/grub/acpi.h: Likewise.
4278 * include/grub/efiemu/efiemu.h: Likewise.
4279 * include/grub/disk.h: Likewise.
4280 * include/grub/ieee1275/ieee1275.h: Likewise.
4281 * include/grub/net.h: Likewise.
4282 * include/grub/machoload.h: Likewise.
4283 * include/grub/macho.h: Likewise.
4284 * include/multiboot.h: Likewise.
4285 * genmoddep.awk: Likewise.
4286 * normal/main.c: Likewise.
4287 * normal/menu_entry.c: Likewise.
4288 * normal/menu_viewer.c: Likewise.
4289 * normal/completion.c: Likewise.
4290 * normal/cmdline.c: Likewise.
4291 * normal/misc.c: Likewise.
4292 * normal/datetime.c: Likewise.
4293 * bus/usb/usbtrans.c: Likewise.
4294 * bus/usb/ohci.c: Likewise.
4295 * bus/usb/uhci.c: Likewise.
4296 * bus/usb/usb.c: Likewise.
4297 * mmap/efi/mmap.c: Likewise.
4298 * mmap/i386/pc/mmap_helper.S: Likewise.
4299 * mmap/i386/pc/mmap.c: Likewise.
4300 * mmap/i386/mmap.c: Likewise.
4301 * mmap/i386/uppermem.c: Likewise.
4302 * mmap/mmap.c: Likewise.
4303 * commands/acpi.c: Likewise.
4304 * commands/echo.c: Likewise.
4305 * commands/blocklist.c: Likewise.
4306 * commands/loadenv.c: Likewise.
4307 * commands/usbtest.c: Likewise.
4308 * commands/boot.c: Likewise.
4309 * commands/parttool.c: Likewise.
4310 * commands/search.c: Likewise.
4311 * commands/cat.c: Likewise.
4312 * commands/i386/pc/play.c: Likewise.
4313 * commands/i386/pc/drivemap.c: Likewise.
4314 * commands/i386/pc/vbeinfo.c: Likewise.
4315 * commands/i386/pc/acpi.c: Likewise.
4316 * commands/i386/pc/vbetest.c: Likewise.
4317 * commands/ls.c: Likewise.
4318 * commands/cmp.c: Likewise.
4319 * commands/test.c: Likewise.
4320 * commands/efi/acpi.c: Likewise.
4321 * commands/gptsync.c: Likewise.
4322 * commands/help.c: Likewise.
4323 * partmap/amiga.c: Likewise.
4324 * partmap/apple.c: Likewise.
4325 * partmap/acorn.c: Likewise.
4326 * partmap/pc.c: Likewise.
4327 * partmap/sun.c: Likewise.
4328 * partmap/gpt.c: Likewise.
4329 * script/sh/lexer.c: Likewise.
4330 * script/sh/function.c: Likewise.
4331 * font/font.c: Likewise.
4332 * font/font_cmd.c: Likewise.
4333 * loader/powerpc/ieee1275/linux.c: Likewise.
4334 * loader/efi/chainloader.c: Likewise.
4335 * loader/multiboot_loader.c: Likewise.
4336 * loader/macho.c: Likewise.
4337 * loader/i386/multiboot.c: Likewise.
4338 * loader/i386/linux.c: Likewise.
4339 * loader/i386/pc/linux.c: Likewise.
4340 * loader/i386/pc/multiboot2.c: Likewise.
4341 * loader/i386/pc/chainloader.c: Likewise.
4342 * loader/i386/pc/xnu.c: Likewise.
4343 * loader/i386/bsd_trampoline.S: Likewise.
4344 * loader/i386/efi/linux.c: Likewise.
4345 * loader/i386/multiboot_elfxx.c: Likewise.
4346 * loader/i386/bsd_helper.S: Likewise.
4347 * loader/i386/bsd.c: Likewise.
4348 * loader/i386/linux_trampoline.S: Likewise.
4349 * loader/i386/xnu_helper.S: Likewise.
4350 * loader/i386/xnu.c: Likewise.
4351 * loader/i386/bsd_pagetable.c: Likewise.
4352 * loader/i386/multiboot_helper.S: Likewise.
4353 * loader/xnu.c: Likewise.
4354 * loader/xnu_resume.c: Likewise.
4355 * io/gzio.c: Likewise.
4356 * term/efi/console.c: Likewise.
4357 * term/terminfo.c: Likewise.
4358 * term/ieee1275/ofconsole.c: Likewise.
4359 * term/i386/pc/serial.c: Likewise.
4360 * term/i386/pc/vesafb.c: Likewise.
4361 * term/i386/pc/vga.c: Likewise.
4362 * term/usb_keyboard.c: Likewise.
4363 * term/gfxterm.c: Likewise.
4364 * aclocal.m4: Likewise.
4365 * util/lvm.c: Likewise.
4366 * util/grub.d/30_os-prober.in: Likewise.
4367 * util/grub.d/10_hurd.in: Likewise.
4368 * util/console.c: Likewise.
4369 * util/grub-macho2img.c: Likewise.
4370 * util/grub-probe.c: Likewise.
4371 * util/hostfs.c: Likewise.
4372 * util/i386/pc/grub-mkimage.c: Likewise.
4373 * util/i386/pc/grub-setup.c: Likewise.
4374 * util/i386/efi/grub-mkimage.c: Likewise.
4375 * util/grub-mkconfig.in: Likewise.
4376 * util/raid.c: Likewise.
4377 * util/resolve.c: Likewise.
4378 * util/grub-mkdevicemap.c: Likewise.
4379 * util/grub-emu.c: Likewise.
4380 * util/getroot.c: Likewise.
4381 * util/hostdisk.c: Likewise.
4382 * util/usb.c: Likewise.
4383 * util/grub-editenv.c: Likewise.
4384 * util/misc.c: Likewise.
4385
d2d49665 43862009-06-10 Felix Zielcke <fzielcke@z-51.de>
4387
4388 * gendistlist.sh (EXTRA_DISTFILES): Add `genhandlerlist.sh' and
4389 `genparttoollist.sh'.
4390 (DISTDIRS): Add `efiemu', `mmap', `parttool' and `script'.
4391 Add `*.sh' to the list find searches for and change `mdate.sh'
4392 to `mdate-sh'.
4393
fe052e37 43942009-06-10 Pavel Roskin <proski@gnu.org>
4395
2763ac18 4396 * include/grub/multiboot2.h: Provide compatibility defines for
4397 multiboot2.h.
4398 * include/multiboot2.h: Include stdint.h only if needed, using
4399 angle brackets.
4400 * loader/i386/pc/multiboot2.c: Include multiboot2.h after
4401 grub/multiboot2.h.
4402 * loader/ieee1275/multiboot2.c: Likewise.
4403 * loader/multiboot2.c: Likewise.
4404 * loader/multiboot_loader.c: Likewise.
4405
437e6adc 4406 * configure.ac: Use -nostdlib when probing for the target. It
4407 should not be required to have libc for the target.
4408
06a6836c 4409 * configure.ac: Remove checks for __bswapsi2 and __bswapdi2,
4410 they fail without libc headers for the target.
4411 * include/grub/powerpc/libgcc.h: Use weak attribute for all
4412 exports.
4413 * include/grub/sparc64/libgcc.h: Likewise. Don't use
4414 preprocessor conditionals.
4415
fe052e37 4416 * conf/common.rmk: Compile tar.mod from tar.c, not cpio.c. The
4417 build system doesn't need to be aware of the tar.c internals.
4418
afd22553 44192009-06-09 Michel Hermier <michel.hermier@gmail.com>
87b8f28c 4420
afd22553 4421 * fs/i386/pc/pxe.c (grub_pxefs_read): Fix returned values.
8ec4a6d0 4422
6b787c4f 44232009-06-09 Robert Millan <rmh.grub@aybabtu.com>
4424
4425 * util/deviceiter.c (grub_util_iterate_devices): Increase number of
4426 disk limit to 26 for IDE, Virtio, Xen and SCSI.
4427
44282009-06-09 Felix Zielcke <fzielcke@z-51.de>
4429
4430 * util/i386/pc/grub-install.in: Change the error message if UUIDs
473d1e45 4431 aren't available if ata.mod gets used.
6b787c4f 4432
473d1e45 44332009-06-09 Oliver Henshaw <oliver.henshaw@gmail.com>
e23721e8 4434
473d1e45 4435 * bus/usb/ohci.c (grub_ohci_pci_iter): Link struct only after
e23721e8 4436 initialising controller.
473d1e45 4437 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
e23721e8 4438
255a27d4 44392009-06-08 Felix Zielcke <fzielcke@z-51.de>
4440
4441 * util/i386/pc/grub-install.in: Add a parameter --disk-module
4442 to choose between ata and biosdisk module on i386-pc.
4443
473d1e45 44442009-06-08 Oliver Henshaw <oliver.henshaw@gmail.com>
69da8877 4445
d55842d8 4446 * bus/usb/ohci.c (grub_ohci_pci_iter): Define the Class,
4447 Subclass and Programming Interface fields in terms of the 3 byte
4448 Class Code register.
4449 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
4450
fa5db0b1 4451 * bus/usb/ohci.c (grub_ohci_pci_iter): Check that programming
4452 interface is OHCI. Add grub_dprintf for symmetry with
4453 bus/usb/uhci.c.
4454 * bus/usb/uhci.c (grub_uhci_pci_iter): Check that programming
4455 interface is UHCI. Add interf variable for programming
4456 interface. Print interface with class/subclass.
4457
c0947beb 4458 * bus/usb/ohci.c: Set interf with correct field.
4459
69da8877 4460 * bus/usb/uhci.c: Remove unneeded doubled lines.
4461 * bus/usb/ohci.c: Likewise. Change interf to grub_uint32_t.
4462 Remove whitespace inside comment.
4463
9e172e30 44642009-06-08 Robert Millan <rmh.grub@aybabtu.com>
4465
4466 * loader/i386/linux.c (grub_cmd_linux): When processing `vga=', use
4467 as fallback an equivalent option without depth.
4468
de65ee2b 44692009-06-08 Vladimir Serbinenko <phcoder@gmail.com>
4470
4471 Not fail if unable to retrieve C/H/S on LBA disks
4472
473d1e45 4473 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): behave gracefully
de65ee2b 4474 if unable to retrieve C/H/S on LBA disks
4475
b57ea2c9 44762009-06-08 Pavel Roskin <proski@gnu.org>
4477
4478 * fs/hfs.c (grub_hfs_find_dir): Use union to avoid a warning
4479 about aliasing.
4480
af361263 44812009-06-08 Felix Zielcke <fzielcke@z-51.de>
4482
4483 * Makefile.in (uninstall): Remove all $lib_DATA files.
4484
4c9ec6b3 44852009-06-08 Vladimir Serbinenko <phcoder@gmail.com>
4486
4487 Bugfix: install on partitionless device
4488
4489 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): check if os_dev
4490 is a whole disk
4491
e76fc924 44922009-06-08 Felix Zielcke <fzielcke@z-51.de>
4493
4494 * Makefile.in (uninstall): Remove all $include_DATA files.
4495
ba5a0d05 44962009-06-08 Felix Zielcke <fzielcke@z-51.de>
4497
4498 * commands/true.c: New file. Implement the true and false commands.
4499 * conf/common.rmk.c (pkglib_MODULES): Add `true.mod'.
4500 (true_mod_SOURCES): New variable.
4501 (true_mod_CFLAGS): Likewise.
4502 (true_mod_LDFLAGS): Likewise.
4503
c8048e32 45042009-06-05 Colin D Bennett <colin@gibibit.com>
4505
4506 Optimized font character lookup using binary search instead of linear
4507 search. Fonts now are required to have the character index ordered by
4508 code point.
4509
4510 * font/font.c (load_font_index): Verify that fonts have ordered
4511 character indices.
4512 (find_glyph): Use binary search instead of linear search to find a
4513 character in a font.
4514
408305be 45152009-06-05 Michael Scherer <misc@mandriva.org>
4516
4517 * fs/hfsplus.c (grub_hfsplus_mount): Determine if the filesystem
4518 uses case sensitive btree.
4519 (grub_hfsplus_iterate_dir): Use GRUB_FSHELP_CASE_INSENSITIVE
4520 only for case insensitive filesystems.
4521
8ee1e0d9 45222009-06-05 Vladimir Serbinenko <phcoder@gmail.com>
4523
4524 * conf/i386-pc.rmk (efiemu_mod_CFLAGS): remove -Werror -Wall
4525 * conf/common.rmk (search_mod_CFLAGS): likewise
4526
a9966eb1 45272009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4528
473d1e45 4529 * kern/i386/pc/startup.S [APPLE_CC]: block of nops to
a9966eb1 4530 compensate a compiler bug
4531
9e7100fb 45322009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4533
473d1e45 4534 * include/grub/term.h (GRUB_TERM_BACKSPACE): explicitly define as 8
9e7100fb 4535 instead of '\b'
473d1e45 4536
ede21d71 45372009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4538
4539 Definitions for creating asm symbols with Apple's CC
4540
4541 * include/grub/symbol.h [APPLE_CC] (FUNCTION): new macro
4542 [APPLE_CC] (VARIABLE): likewise
4543
9dbf7653 45442009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4545
4546 Disable lnxboot.img when compiled
4547 with Apple's CC
4548
4549 * conf/i386-pc.rmk (pkglib_IMAGES): remove lnxboot.img
4550 pkglib_IMAGES [! TARGET_APPLE_CC] (pkglib_IMAGES): add lnxboot.img
4551 * boot/i386/pc/lnxboot.S [APPLE_CC]: define an #error
4552 [! APPLE_CC] (CODE_LENG): skip
4553 [! APPLE_CC] (setup_sects): likewise
4554 [! APPLE_CC]: skip filling
473d1e45 4555
e93cdc3d 45562009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4557
4558 Address in trampolines based on 32-bit registers when compiled
4559 with Apple's CC
4560
473d1e45 4561 * loader/i386/xnu_helper.S [APPLE_CC]: use 32-bit registers
e93cdc3d 4562 for addresses
4563 * loader/i386/linux_trampoline.S [APPLE_CC]: likewise
4564
6c688477 45652009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4566
4567 Avoid aliases when compiling with Apple's CC for PCBIOS machine
4568
4569 * kern/misc.c [APPLE_CC] (memcpy): new function
4570 [APPLE_CC] (memmove): likewise
4571 [APPLE_CC && !GRUB_UTIL] (grub_err_printf): likewise
473d1e45 4572 (memcpy): define alias conditionally on !APPLE_CC
6c688477 4573 (memset): likewise
4574 (abort): likewise
4575 * include/grub/misc.h (memove): don't define when both GRUB_UTIL and
4576 APPLE_CC are defined
4577 * include/grub/list.h [APPLE_CC] (grub_assert_fail): new function
4578 (grub_assert_fail): make prototype conditional
4579
e37ffc5c 45802009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4581
4582 Use grub-macho2img when compiling with Apple's CC for PCBIOS machine
4583
473d1e45 4584 * conf/common.rmk (bin_UTILITIES): add (on false on condition)
4585 grub-macho2img
e37ffc5c 4586 (CLEANFILES): add grub-macho2img
4587 (grub_macho2img_SOURCES): new variable
4588 * kern/i386/pc/startup.S (bss_start): new variable
4589 (bss_end): likewise
4590 * genmk.rb: use grub-macho2img for *.img when compiled with Apple's CC
4591 * util/grub-macho2img.c: new file
4592
cf00df31 45932009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4594
4595 Use objconv when compiling with Apple's CC
4596
4597 * conf/i386-pc.rmk (efiemu32.o): use OBJCONV if defined
4598 (efiemu64.o): likewise
4599 (efiemu64_c.o): omit -mcmodel=large and add -DAPPLE_CC=1
4600 when compiling with Apple's CC
4601 (efiemu64_s.o): likewise
4602 * configure.ac: check for objconv when compiling with Apple's CC
4603 * genmk.rb: use objconv for modules when compiled with Apple's CC
473d1e45 4604
d119a20c 46052009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4606
4607 Define segment as well as section when compiling with
4608 Apple's CC
4609
4610 * efiemu/runtime/efiemu.c (PHYSICAL_ATTRIBUTE): new definition
4611 (efiemu_set_virtual_address_map): declare with PHYSICAL_ATTRIBUTE
4612 (efiemu_convert_pointer): likewise
4613 (efiemu_set_virtual_address_map): likewise
4614 (efiemu_convert_pointer): likewise
4615 (efiemu_getcrc32): likewise
4616 (init_crc32_table): likewise
4617 (reflect): likewise
4618 * include/grub/dl.h (GRUB_MOD_NAME): define segment with Apple's CC
4619 (GRUB_MOD_DEP): likewise
473d1e45 4620
c8600122 46212009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4622
4623 Allow a compilation without -mcmodel=large
4624
4625 * kern/efi/mm.c (grub_efi_allocate_pages): don't allocate >4GiB
4626 when compiled without -mcmodel=large
473d1e45 4627 (filter_memory_map): remove memory post 4 GiB when compiled
c8600122 4628 without -mcmodel=large
473d1e45 4629 * configure.ac: fail gracefully and add -DMCMODEL_SMALL=1 to
c8600122 4630 TARGET_CFLAGS when -mcmodel=large isn't supported
473d1e45 4631
e8df1d4e 46322009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4633
4634 Remove nested functions in efiemu core
4635
4636 * efiemu/runtime/efiemu.c (reflect): make static instead of nested
473d1e45 4637
cc6c3ac1 46382009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4639
4640 Avoid clobbering %ebx/%rbx in inline assembly with Apple's CC
4641
4642 * efiemu/runtime/efiemu.c (write_cmos): use %cl instead of %bl as
4643 temporary storage
473d1e45 4644 * include/grub/i386/tsc.h (grub_get_tsc): restore %rbx/%ebx when
4645 using Apple's CC
cc6c3ac1 4646 (grub_cpu_is_tsc_supported): likewise
4647 * loader/i386/xnu.c (guessfsb): restore %rbx/%ebx in inline assembly
473d1e45 4648
3e325901 46492009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4650
4651 Absolute addressing through constant with Apple's cc
4652
4653 * kern/i386/pc/startup.S: Define necessary constants
4654 and address through it when using ABS with Apple's CC
4655 * boot/i386/pc/diskboot.S: likewise
4656 * boot/i386/pc/boot.S: likewise
4657 * boot/i386/pc/lnxboot.S: likewise
4658 * boot/i386/pc/cdboot.S: likewise
4659 * mmap/i386/pc/mmap_helper.S: likewise
4660 * commands/i386/pc/drivemap_int13h.S: likewise
4661
2b167a72 46622009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4663
4664 Check if compiler is apple cc
4665
4666 * Makefile.in (ASFLAGS): new variable
4667 (TARGET_ASFLAGS): likewise
4668 (TARGET_MODULE_FORMAT): likewise
4669 (TARGET_APPLE_CC): likewise
4670 (OBJCONV): likewise
4671 (TARGET_IMG_CFLAGS): likewise
4672 (TARGET_CPPFLAGS): add includedir
4673 * configure.ac: call grub_apple_cc and grub_apple_target_cc
4674 (TARGET_IMG_LDFLAGS): Add -Wl,-Ttext,. All users updated
4675 Check for linker script only if compiler isn't Apple's CC
4676 (TARGET_MODULE_FORMAT): set
4677 (TARGET_APPLE_CC): likewise
4678 (TARGET_ASFLAGS): likewise
4679 (ASFLAGS): likewise
4680 Check for objcopy only if compiler isn't Apple's CC
4681 Check for BSS symbol only if compiler isn't Apple's CC
4682 * genmk.rb: adapt nm options if we use Apple's utils
4683 * aclocal.m4 (grub_apple_cc): new test
4684 (grub_apple_target_cc): likewise
473d1e45 4685
fb14123e 46862009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4687
4688 Simplify sed expressions and improve awk
4689
4690 * Makefile.in (install-local): simplify sed expression
4691 * gencmdlist.sh: likewise
4692 * genmoddep.awk: avoid adding module as a dependency of itself
4693
5b889789 46942009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4695
4696 Add missing start symbols
4697
4698 * boot/i386/pc/boot.S: add start
fb14123e 4699 * boot/i386/pc/pxeboot.S: likewise
473d1e45 4700
fd2bf2e3 47012009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4702
4703 Fix wrong assumptions with grub-mkimage on EFI
473d1e45 4704
4705 * i386/efi/grub-mkimage.c (read_kernel_module): don't write prefix here
fd2bf2e3 4706 (relocate_addresses): consider both r_addend and value at offset
4707 (make_mods_section): zerofill modinfo and header
4708 (convert_elf): write prefix here
473d1e45 4709
5389763d 47102009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4711
4712 Use .asciz instead of .string
4713
4714 * i386/pc/diskboot.S: use .asciz instead of .string
4715 * i386/pc/boot.S: likewise
4716 * include/grub/dl.h (GRUB_MOD_DEP): likewise
4717 (GRUB_MOD_NAME): likewise
473d1e45 4718
3eb5ed4e 47192009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4720
4721 gfxpayload support
4722
4723 * commands/videotest.c (grub_cmd_videotest): use grub_video_set_mode
4724 * include/grub/video.h (GRUB_VIDEO_MODE_TYPE_PURE_TEXT): new definition
4725 (grub_video_setup): remove
4726 (grub_video_set_mode): new prototype
4727 * loader/i386/linux.c (DEFAULT_VIDEO_MODE): new definition
4728 (vid_mode): remove
4729 (linux_vesafb_res): compile only on PCBIOS
4730 (grub_linux_boot): support gfxpayload
4731 * loader/i386/pc/xnu.c (video_hook): new function
4732 (grub_xnu_set_video): support gfxpayload
4733 * term/gfxterm.c (DEFAULT_VIDEO_WIDTH): removed
4734 (DEFAULT_VIDEO_HEIGHT): likewise
4735 (DEFAULT_VIDEO_FLAGS): likewise
4736 (DEFAULT_VIDEO_MODE): new definition
4737 (video_hook): new function
4738 (grub_gfxterm_init): use grub_video_set_mode
473d1e45 4739 * util/grub.d/30_os-prober.in: remove explicit modesetting before
3eb5ed4e 4740 loading xnu
4741 * video/video.c (grub_video_setup): removed
473d1e45 4742 (grub_video_set_mode): new function based on grub_gfxterm_init and
3eb5ed4e 4743 grub_video_setup
4744
4b0e1143 47452009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4746
4747 Avoid calling biosdisk in drivemap
4748
4749 * commands/i386/pc/drivemap.c (parse_biosdisk): remove
4750 (revparse_biosdisk): likewise
4751 (list_mappings): derive name from id directly
4752 (grub_cmd_drivemap): use tryparse_diskstring
473d1e45 4753
fda6cb98 47542009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4755
4756 Script fixes
4757
4758 * include/grub/script_sh.h (grub_script_cmdline): remove cmdline
4759 (grub_lexer_param): add tokenonhold
4760 (grub_script_create_cmdline): remove cmdline. All callers updated
4761 (grub_script_function_create): make functionname
4762 grub_script_arg. All callers updated
4763 (grub_script_execute_argument_to_string): new prototype
4764 * kern/parser.c (state_transitions): reorder
4765 (grub_parser_cmdline_state): fix a bug and make more compact
473d1e45 4766 * script/sh/execute.c (grub_script_execute_argument_to_string):
fda6cb98 4767 make global
4768 (grub_script_execute_cmdline): use new format
4769 * script/sh/function.c (grub_script_function_create): make functionname
4770 grub_script_arg. All callers updated
473d1e45 4771 * script/sh/lexer.c (grub_script_lexer_init): initialize tokenonhold
fda6cb98 4772 (grub_script_yylex): remove
4773 (grub_script_yylex2): renamed to ...
4774 (grub_script_yylex): ...renamed
4775 parse the expressions like a${b}c
4776 * script/sh/parser.y (GRUB_PARSER_TOKEN_ARG): new typed terminal
4777 (GRUB_PARSER_TOKEN_VAR): remove
4778 (GRUB_PARSER_TOKEN_NAME): likewise
4779 ("if"): declare as typeless
4780 ("while"): likewise
4781 ("function"): likewise
4782 ("else"): likewise
4783 ("then"): likewise
4784 ("fi"): likewise
4785 (text): remove
4786 (argument): likewise
4787 (script): accept empty scripts and make exit on error
4788 (arguments): use GRUB_PARSER_TOKEN_ARG
4789 (function): likewise
4790 (command): move error handling to script
4791 (menuentry): move grub_script_lexer_ref before
473d1e45 4792 * script/sh/script.c (grub_script_create_cmdline): remove cmdline
fda6cb98 4793 argument. All callers updated
4794
f4448a07 47952009-06-04 Robert Millan <rmh.grub@aybabtu.com>
4796
4797 Prevent GRUB from probing floppies during boot.
4798
4799 * conf/common.rmk (search_mod_CFLAGS): Use `-Werror -Wall'.
4800 * commands/search.c (options): Add --no-floppy.
4801 (search_fs, search_file, grub_cmd_search): Support --no-floppy.
4802 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Use
4803 --no-floppy when searching for UUIDs.
4804
2bf5885a 48052009-06-04 Robert Millan <rmh.grub@aybabtu.com>
4806
4807 Simplify the code duplication in commands/search.c.
4808
4809 * commands/search.c (search_label, search_fs_uuid): Merge into ...
4810 (search_fs): ... this. Update all users.
4811
f6fd460a 48122009-06-03 Felix Zielcke <fzielcke@z-51.de>
4813
4814 * util/grub-mkconfig.in (update_grub_dir): Rename to grub_mkconfig_dir.
4815
cbb3c83e 48162009-05-28 Pavel Roskin <proski@gnu.org>
4817
57788cfd 4818 * Makefile.in: Don't use "cp -d", it doesn't work on FreeBSD.
4819 Remove the original symlink explicitly.
4820
cbb3c83e 4821 * fs/hfs.c (grub_hfs_find_dir): Skip sequences of slashes, not
4822 just one slash. That's how grub_fshelp_find_file() does it.
4823
cd0d5e30 48242009-05-26 Pavel Roskin <proski@gnu.org>
4825
f0f8bbe2 4826 * genmk.rb: Avoid shadowing variable `s', rename the outer `s'
4827 to `str'.
4828
cd0d5e30 4829 * util/getroot.c (grub_util_get_dev_abstraction): Mark os_dev as
4830 possibly unused.
4831
8c2cab51 48322009-05-25 Christian Franke <franke@computer.org>
4833
4834 * disk/ata.c (grub_ata_wait_not_busy): Add debug output of status
4835 register.
4836 (grub_atapi_identify): Add wait after drive select.
4837 (grub_ata_identify): Do more strict status register check before
4838 calling grub_atapi_identify (). Suppress error message if status
4839 register is 0x00 after command failure. Add status register
4840 check after PIO read to avoid bogus identify due to stuck DRQ.
4841 Thanks to Pavel Roskin for testing.
4842 (grub_device_initialize): Remove unsafe status register check.
4843 Thanks to 'phcoder' for problem report and patch.
4844 Prevent sign extension in debug message.
4845
230c0ad6 48462009-05-23 Colin D Bennett <colin@gibibit.com>
4847
4848 Cleaned up `include/grub/normal.h'. Grouped prototypes by
4849 definition file, and functions defined in `normal/menu.c' have had
4850 their prototypes moved to `include/grub/menu.h' for consistency.
4851
4852 * include/grub/menu.h (grub_menu_execute_callback): Added; moved
4853 from normal.h.
4854 (grub_menu_get_entry): Likewise.
4855 (grub_menu_get_timeout): Likewise.
4856 (grub_menu_set_timeout): Likewise.
4857 (grub_menu_execute_entry): Likewise.
4858 (grub_menu_execute_with_fallback): Likewise.
4859 (grub_menu_entry_run): Likewise.
4860
4861 * include/grub/normal.h: Re-ordered and grouped function
4862 prototypes by file that the function is defined in.
4863 (grub_menu_execute_callback): Removed; moved to menu.h.
4864 (grub_menu_get_entry): Likewise.
4865 (grub_menu_get_timeout): Likewise.
4866 (grub_menu_set_timeout): Likewise.
4867 (grub_menu_execute_entry): Likewise.
4868 (grub_menu_execute_with_fallback): Likewise.
4869 (grub_menu_entry_run): Likewise.
4870 (grub_menu_addentry): Renamed from this ...
4871 (grub_normal_add_menu_entry): ... to this.
4872
4873 * normal/main.c (grub_menu_addentry): Renamed from this ...
4874 (grub_normal_add_menu_entry): ... to this.
4875
4876 * script/sh/execute.c (grub_script_execute_menuentry): Update
4877 reference to renamed grub_menu_addentry function.
4878
861f03a5 48792009-05-23 Felix Zielcke <fzielcke@z-51.de>
4880
4881 * commands/i386/pc/drivemap.c (MODNAME): Remove. Update all users.
4882
96b1619a 48832009-05-22 Pavel Roskin <proski@gnu.org>
4884
bf6a5fb2 4885 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Remove.
4886 * configure.ac: Don't call grub_I386_CHECK_REGPARM_BUG. Define
4887 NESTED_FUNC_ATTR using AH_BOTTOM. Use regparm(1) only when
4888 compiling for the i386 targets, but not for the utilities.
4889
96b1619a 4890 * include/grub/i386/pc/kernel.h (grub_boot_drive): Change type
4891 to grub_uint8_t.
4892 (grub_root_drive): Likewise.
4893 * kern/i386/pc/startup.S (grub_boot_drive): Change size to byte,
4894 remove alignment.
4895 (grub_root_drive): Change size to byte.
4896 (grub_start_addr): Remove.
4897 (grub_end_addr): Likewise.
4898 (grub_apm_bios_info): Likewise.
4899
b729776b 49002009-05-21 Felix Zielcke <fzielcke@z-51.de>
4901
4902 * normal/i386: Remove.
4903 * normal/powerpc: Likewise.
4904 * normal/sparc64: Likewise.
4905 * normal/x86_64: Likewise.
4906
0a15ce80 49072009-05-19 Vladimir Serbinenko <phcoder@gmail.com>
4908
4909 * conf/x86_64-efi.rmk (linux_mod_ASFLAGS): Add missing variable
473d1e45 4910 * loader/i386/linux_trampoline.S: Fix indentation
0a15ce80 4911 * loader/i386/xnu_helper.S: Likewise
d6da58e6 4912
33db9015 49132009-05-18 Colin D Bennett <colin@gibibit.com>
4914
d6da58e6 4915 Display error messages when parsing a Lua statement fails.
4916 Previously, executing a syntactically invalid statement like
4917 ")foo" or "bar;" would silently fail.
33db9015 4918
4919 * script/lua/grub_main.c (handle_lua_error): New function.
d6da58e6 4920 (grub_lua_parse_line): Improved reporting of Lua parser and
4921 execution errors.
33db9015 4922
46422c89 49232009-05-17 Vladimir Serbinenko <phcoder@gmail.com>
4924
4925 Remove -Werror which causes build to fail on some systems
4926
4927 * conf/i386-pc.rmk (xnu_mod_CFLAGS): Remove -Werror -Wall
4928 * conf/i386-efi.rmk (xnu_mod_CFLAGS): Likewise
4929 * conf/x86_64-efi.rmk (xnu_mod_CFLAGS): Likewise
18f547ad 4930
22f53a96 49312009-05-17 Vladimir Serbinenko <phcoder@gmail.com>
4932
4933 trampoline for linux on 64-bit platform
4934
18f547ad 4935 * conf/x86_64-efi.rmk (linux_mod_SOURCES): added
4936 loader/i386/efi/linux_trampoline.S
4937 * include/grub/x86_64/efi/loader.h (grub_linux_real_boot): removed
473d1e45 4938 declaration
d6da58e6 4939 * kern/x86_64/efi/startup.S (grub_linux_real_boot): moved from
4940 here
22f53a96 4941 * loader/i386/linux_trampoline.S: moved here
d6da58e6 4942 * loader/i386/efi/linux.c (allocate_pages): reserve space for
4943 trampoline
22f53a96 4944 (jumpvector): removed
4945 (grub_linux_trampoline_start): new declaration
4946 (grub_linux_trampoline_end): likewise
4947 (grub_linux_boot): use trampoline when on 64-bit platform
4948 * loader/i386/linux.c: likewise
4949
cb5a0f40 49502009-05-16 Pavel Roskin <proski@gnu.org>
4951
4952 * script/lua/grub_lib.c (grub_lua_getenv): Make name and value
4953 const to avoid a warning.
4954 (grub_lua_setenv): Likewise.
4955 * script/lua/grub_main.c (grub_lua_parse_line): Use size_t for
4956 lmsg to fix a warning.
4957
334f2c28 49582009-05-16 Felix Zielcke <fzielcke@z-51.de>
4959
4960 * conf/i386.rmk (setjmp_mod_CFLAGS): Rename to ...
7dd10fce 4961 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
4962 * conf/x86_64-efi.rmk (setjmp_mod_CFLAGS): Rename to ...
4963 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
4964 * conf/powerpc-ieee1275.rmk (setjmp_mod_CFLAGS): Rename to ...
4965 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
4966 * conf/sparc64-ieee1275.rmk (setjmp_mod_CFLAGS): Rename to ...
4967 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
334f2c28 4968
59e5d3ec 49692009-05-16 Felix Zielcke <fzielcke@z-51.de>
4970
4971 * util/grub-mkconfig.in: Export GRUB_TERMINAL_INPUT.
4972
9d87a1ba 49732009-05-16 Bean <bean123ch@gmail.com>
4974
4975 * conf/common.rmk (pkglib_MODULES): Add lua.mod.
4976 (lua_mod_SOURCES): New variable.
4977 (lua_mod_CFLAGS): Likewise.
4978 (lua_mod_LDFLAGS): Likewise.
4979
4980 * conf/i386.rmk (pkglib_MODULES): Add setjmp.mod.
4981 (setjmp_mod_SOURCES): New variable.
4982 (setjmp_mod_CFLAGS): Likewise.
4983 (setjmp_LDFLAGS): Likewise.
4984
4985 * conf/x86_64-efi.rmk (pkglib_MODULES): Add setjmp.mod.
4986 (setjmp_mod_SOURCES): New variable.
4987 (setjmp_mod_CFLAGS): Likewise.
4988 (setjmp_LDFLAGS): Likewise.
4989
4990 * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add setjmp.mod.
4991 (setjmp_mod_SOURCES): New variable.
4992 (setjmp_mod_CFLAGS): Likewise.
4993 (setjmp_LDFLAGS): Likewise.
4994
4995 * conf/sparc64-ieee1275.rmk (pkglib_MODULES): Add setjmp.mod.
4996 (setjmp_mod_SOURCES): New variable.
4997 (setjmp_mod_CFLAGS): Likewise.
4998 (setjmp_LDFLAGS): Likewise.
4999
5000 * normal/i386/setjmp.S: Moved from here ...
5001 * lib/i386/setjmp.S: ... Moved here
5002 * normal/x86_64/setjmp.S: Moved from here ...
5003 * lib/x86_64/setjmp.S: ... Moved here
5004 * normal/powerpc/setjmp.S: Moved from here ...
5005 * lib/powerpc/setjmp.S: ... Moved here
5006 * normal/sparc64/setjmp.S: Moved from here ...
5007 * lib/sparc64/setjmp.S: ... Moved here
5008
5009 * include/grub/i386/setjmp.h (grub_setjmp): Don't use attribute
5010 returns_twice in mingw.
5011
5012 * script/lua/grub_lib.c: New file.
5013 * script/lua/grub_lib.h: Likewise.
5014 * script/lua/grub_lua.h: Likewise.
5015 * script/lua/grub_main.c: Likewise.
5016 * script/lua/lapi.c: Likewise.
5017 * script/lua/lapi.h: Likewise.
5018 * script/lua/lauxlib.c: Likewise.
5019 * script/lua/lauxlib.h: Likewise.
5020 * script/lua/lbaselib.c: Likewise.
5021 * script/lua/lcode.c: Likewise.
5022 * script/lua/lcode.h: Likewise.
5023 * script/lua/ldblib.c: Likewise.
5024 * script/lua/ldebug.c: Likewise.
5025 * script/lua/ldebug.h: Likewise.
5026 * script/lua/ldo.c: Likewise.
5027 * script/lua/ldo.h: Likewise.
5028 * script/lua/ldump.c: Likewise.
5029 * script/lua/lfunc.c: Likewise.
5030 * script/lua/lfunc.h: Likewise.
5031 * script/lua/lgc.c: Likewise.
5032 * script/lua/lgc.h: Likewise.
5033 * script/lua/linit.c: Likewise.
5034 * script/lua/liolib.c: Likewise.
5035 * script/lua/llex.c: Likewise.
5036 * script/lua/llex.h: Likewise.
5037 * script/lua/llimits.h: Likewise.
5038 * script/lua/lmathlib.c: Likewise.
5039 * script/lua/lmem.c: Likewise.
5040 * script/lua/lmem.h: Likewise.
5041 * script/lua/loadlib.c: Likewise.
5042 * script/lua/lobject.c: Likewise.
5043 * script/lua/lobject.h: Likewise.
5044 * script/lua/lopcodes.c: Likewise.
5045 * script/lua/lopcodes.h: Likewise.
5046 * script/lua/loslib.c: Likewise.
5047 * script/lua/lparser.c: Likewise.
5048 * script/lua/lparser.h: Likewise.
5049 * script/lua/lstate.c: Likewise.
5050 * script/lua/lstate.h: Likewise.
5051 * script/lua/lstring.c: Likewise.
5052 * script/lua/lstring.h: Likewise.
5053 * script/lua/lstrlib.c: Likewise.
5054 * script/lua/ltable.c: Likewise.
5055 * script/lua/ltable.h: Likewise.
5056 * script/lua/ltablib.c: Likewise.
5057 * script/lua/ltm.c: Likewise.
5058 * script/lua/ltm.h: Likewise.
5059 * script/lua/lua.h: Likewise.
5060 * script/lua/luaconf.h: Likewise.
5061 * script/lua/lualib.h: Likewise.
5062 * script/lua/lundump.c: Likewise.
5063 * script/lua/lundump.h: Likewise.
5064 * script/lua/lvm.c: Likewise.
5065 * script/lua/lvm.h: Likewise.
5066 * script/lua/lzio.c: Likewise.
5067 * script/lua/lzio.h: Likewise.
5068
5e898c9d 50692009-05-16 Bean <bean123ch@gmail.com>
5070
5071 * include/grub/kernel.h (grub_module_header_types): Add type
5072 OBJ_TYPE_CONFIG.
5073
5074 * kern/main.c (grub_load_config): New function.
5075 (grub_main): Call grub_load_config to read boot config.
5076
5077 * grub-mkimage (generate_image): New parameter config_path.
5078 (options): New option --config.
5079 (main): Parse --config option, and pass it to generate_image.
5080
cf353a47 50812009-05-14 Christian Franke <franke@computer.org>
5082
5083 * commands/i386/pc/drivemap_int13h.S: Add missing EXT_C for symbols.
5084 This fixes build on Cygwin.
5085
3834887f 50862009-05-14 Pavel Roskin <proski@gnu.org>
5087
5088 * commands/i386/pc/drivemap_int13h.S: Eliminate unconditional
5089 jump. This saves two bytes, so the typical case of 2 swapped
5090 drives would fit 32 bytes.
5091
8090fc01 50922009-05-13 Pavel Roskin <proski@gnu.org>
5093
ac963883 5094 * loader/i386/multiboot.c (grub_multiboot): Cast mmap_addr to
5095 grub_uint32_t to avoid a warning.
5096
8090fc01 5097 * loader/i386/linux.c (allocate_pages): When assigning
5098 real_mode_mem, cast through grub_size_t to fix a warning. The
5099 code already makes sure that the value would fit a pointer.
5100 (grub_linux_setup_video): Cast render_target->data to
5101 grub_size_t to fix a warning.
5102
18f547ad 51032009-05-13 Javier Martín <lordhabbit@gmail.com>
4246b8a9 5104
5105 * commands/i386/pc/drivemap.c: New file - implement drivemap
5106 command.
5107 * commands/i386/pc/drivemap_int13h.S: New file - int13 handler.
5108 * conf/i386-pc.rmk: Add drivemap.c and drivemap_int13h.S.
5109
6f6a8b28 51102009-05-13 Pavel Roskin <proski@gnu.org>
5111
5112 * util/i386/pc/grub-setup.c (setup): Remove unused variable
5113 embedding_area_exists.
5114
15fbf4c4 51152009-05-13 Robert Millan <rmh.grub@aybabtu.com>
5116
5117 * util/i386/pc/grub-setup.c (setup): Restructure code flow to make
5118 it easier to understand / work with.
59978c8a 5119 Improve warning messages for cases where there's no embedding area,
5120 or when it is too small (or core.img too large).
15fbf4c4 5121
238e871f 51222009-05-13 Pavel Roskin <proski@gnu.org>
5123
0ab3a9a4 5124 * loader/i386/pc/multiboot2.c: Add necessary includes for
5125 grub_multiboot2_real_boot().
5126
a2c8c5f8 5127 * fs/iso9660.c (grub_iso9660_iterate_dir): The file mode in the
5128 PX record is always little-endian. We only need the lower 2
5129 bytes of the mode.
5130
faec96af 5131 * fs/cpio.c: Use the same name "struct head" for tar and cpio to
5132 facilitate code reuse.
5133 (grub_cpio_mount): Use "struct head", not a char buffer. This
5134 fixes a warning reported by gcc 4.4.
5135
238e871f 5136 * kernel/disk.c (grub_disk_read): Use void pointer for the
5137 buffer.
5138 (grub_disk_write): Use const void pointer for the buffer.
5139 Adjust all callers. Remove unnecessary casts.
5140
901d2f0c 51412009-05-10 Robert Millan <rmh.grub@aybabtu.com>
5142
5143 * util/i386/pc/grub-install.in: Update copyright year.
5144
18f547ad 51452009-05-09 Vladimir Serbinenko <phcoder@gmail.com>
2eac4c16 5146
5147 gptsync
5148
5149 * commands/gptsync.c: new file
5150 * conf/common.rmk (pkglib_MODULES): add gptsync.mod
5151 (gptsync_mod_SOURCES): new variable
5152 (gptsync_mod_CFLAGS): likewise
5153 (gptsync_mod_LDFLAGS): likewise
18f547ad 5154 * include/grub/pc_partition.h (GRUB_PC_PARTITION_TYPE_NTFS):
2eac4c16 5155 new definition
5156 (GRUB_PC_PARTITION_TYPE_HFS): likewise
5157 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/gptsync.c
5158 * conf/i386-ieee1275.rmk: likewise
5159 * conf/i386-pc.rmk: likewise
5160 * conf/powerpc-ieee1275.rmk: likewise
5161
b4ba690a 51622009-05-09 Vladimir Serbinenko <phcoder@gmail.com>
5163
5164 Fixed grub-emu
5165
5166 * kern/dl.c (grub_dl_ref): omit when compiling grub-emu
5167 (grub_dl_ref): likewise
5168
317e1a44 51692009-05-08 Robert Millan <rmh.grub@aybabtu.com>
5170
5171 * util/i386/pc/grub-setup.c (setup): Factorize find_usable_region(),
5172 split in two functions (one for msdos and one for gpt).
5173
041b8094 51742009-05-08 Pavel Roskin <proski@gnu.org>
5175
752473c2 5176 * disk/raid.c (grub_raid_block_xor): Make buf2 constant, it's
5177 not modified.
5178
041b8094 5179 * disk/raid6_recover.c (grub_raid6_recover): Fix warnings about
5180 uninitialized err[0] and err[1]. Rename them to bad1 and bad2.
5181 Initialize them with -1. Add sanity check for bad1. Eliminate
5182 nerr variable.
5183
172800ce 51842009-05-08 David S. Miller <davem@davemloft.net>
5185
5186 * util/sparc64/ieee1275/grub-ofpathname.c (main): Set progname.
5187
29aa5e81 51882009-05-06 Robert Millan <rmh.grub@aybabtu.com>
5189
5190 * util/i386/pc/grub-setup.c (setup): Fix check for embed region
473d1e45 5191 existence.
29aa5e81 5192
96613b62 51932009-05-05 Felix Zielcke <fzielcke@z-51.de>
5194
5195 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
1905c57b 5196 `kern/rescue_reader.c', `kern/rescue_parser.c' and `normal/autofs.c'.
96613b62 5197
eef73c8a 51982009-05-05 David S. Miller <davem@davemloft.net>
5199
5200 * util/sparc64/ieee1275/grub-install.in: Fix sed arg quoting.
5201
119494b5 52022009-05-05 Pavel Roskin <proski@gnu.org>
5203
5204 * include/grub/dl.h [GRUB_UTIL]: Provide inline implementations
5205 of grub_dl_ref() and grub_dl_unref().
5206 * commands/parttool.c: Remove preprocessor conditionals around
5207 grub_dl_ref() and grub_dl_unref().
5208 * fs/affs.c: Likewise.
5209 * fs/afs.c: Likewise.
5210 * fs/cpio.c: Likewise.
5211 * fs/ext2.c: Likewise.
5212 * fs/fat.c: Likewise.
5213 * fs/hfs.c: Likewise.
5214 * fs/hfsplus.c: Likewise.
5215 * fs/iso9660.c: Likewise.
5216 * fs/jfs.c: Likewise.
5217 * fs/minix.c: Likewise.
5218 * fs/ntfs.c: Likewise.
5219 * fs/reiserfs.c: Likewise.
5220 * fs/sfs.c: Likewise.
5221 * fs/udf.c: Likewise.
5222 * fs/ufs.c: Likewise.
5223 * fs/xfs.c: Likewise.
5224 * include/grub/dl.h: Likewise.
5225 * loader/xnu.c: Likewise.
5226
de5fd76e 52272009-05-04 Pavel Roskin <proski@gnu.org>
5228
5229 * commands/acpi.c: Remove unused variable my_mod.
5230 * partmap/amiga.c: Likewise.
5231 * partmap/apple.c: Likewise.
5232 * partmap/gpt.c: Likewise.
5233 * partmap/pc.c: Likewise.
5234 * partmap/sun.c: Likewise.
5235 * term/gfxterm.c: Likewise.
5236 * term/i386/pc/vesafb.c: Likewise.
5237 * term/i386/pc/vga.c: Likewise.
5238
983598ad 52392009-05-04 David S. Miller <davem@davemloft.net>
5240
5241 * kern/ieee1275/openfw.c (grub_children_iterate): Fix string
5242 pointer args to grub_ieee1275_get_property().
5243
8aadec43 5244 * conf/sparc64-ieee1275.rmk: Fix build due to missing '\'.
5245
9554b15e 5246 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Bypass cdrom
5247 devices, and do not traverse down under controller nodes.
5248
67e23c90 5249 * disk/ieee1275/ofdisk.c (compute_dev_path): New.
5250 (grub_ofdisk_open): Use it to un-escape "," characters.
5251 * kern/disk.c (find_part_sep): New.
5252 (grub_disk_open): Use it to find the first non-escaped ','
5253 character in the disk name.
5254 * util/ieee1275/devicemap.c (escape_of_path): New.
5255 (grub_util_emit_devicemap_entry): Use it.
5256 * util/sparc64/ieee1275/grub-install.in: Update script to
5257 strip partition specifiers properly by not triggering on
5258 '\' escaped ',' characters.
5259
74bfdd2f 52602009-05-04 Robert Millan <rmh.grub@aybabtu.com>
5261
5262 * include/grub/i386/linux.h (GRUB_LINUX_VID_MODE_VESA_START): Set
5263 to 0x300.
5264 * loader/i386/linux.c (vga_modes, linux_vesafb_res): Add a few
5265 resolutions.
5266 (linux_vesafb_modes): Add a lot of additional modes to the list (based
5267 on documentation from Wikipedia).
5268
4241d2b1 52692009-05-04 Pavel Roskin <proski@gnu.org>
5270
5271 * disk/ata.c: Spelling fixes.
5272 * disk/raid.c: Likewise.
5273 * disk/usbms.c: Likewise.
5274 * disk/dmraid_nvidia.c: Likewise.
5275 * kern/ieee1275/openfw.c: Likewise.
5276 * kern/ieee1275/init.c: Likewise.
5277 * kern/ieee1275/cmain.c: Likewise.
5278 * boot/i386/pc/cdboot.S: Likewise.
5279 * video/readers/png.c: Likewise.
5280 * video/i386/pc/vbe.c: Likewise.
5281 * fs/udf.c: Likewise.
5282 * fs/hfs.c: Likewise.
5283 * fs/reiserfs.c: Likewise.
5284 * efiemu/runtime/efiemu.c: Likewise.
5285 * efiemu/main.c: Likewise.
5286 * efiemu/mm.c: Likewise.
5287 * include/grub/elf.h: Likewise.
5288 * include/grub/xnu.h: Likewise.
5289 * include/grub/usbdesc.h: Likewise.
5290 * include/grub/usb.h: Likewise.
5291 * include/grub/script_sh.h: Likewise.
5292 * include/grub/lib/LzmaEnc.h: Likewise.
5293 * include/grub/efiemu/efiemu.h: Likewise.
5294 * include/grub/command.h: Likewise.
5295 * normal/menu.c: Likewise.
5296 * normal/main.c: Likewise.
5297 * normal/datetime.c: Likewise.
5298 * bus/usb/uhci.c: Likewise.
5299 * mmap/i386/uppermem.c: Likewise.
5300 * mmap/mmap.c: Likewise.
5301 * commands/acpi.c: Likewise.
5302 * commands/test.c: Likewise.
5303 * partmap/apple.c: Likewise.
5304 * font/font.c: Likewise.
5305 * loader/sparc64/ieee1275/linux.c: Likewise.
5306 * loader/macho.c: Likewise.
5307 * loader/i386/bsd_trampoline.S: Likewise.
5308 * loader/i386/bsd.c: Likewise.
5309 * loader/xnu.c: Likewise.
5310 * term/i386/pc/vesafb.c: Likewise.
5311 * term/usb_keyboard.c: Likewise.
5312 * util/resolve.c: Likewise.
5313 * util/getroot.c: Likewise.
5314
0cfc0083 53152009-05-04 Felix Zielcke <fzielcke@z-51.de>
5316
5317 * conf/i386-pc.rmk (libpkg_DATA): Rename to pkglib_DATA.
5318
7c1d00cd 53192009-05-04 Robert Millan <rmh.grub@aybabtu.com>
5320
5321 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS] (grub_cmd_linux): Fix
5322 build error.
5323
b01f0548 53242009-05-04 Robert Millan <rmh.grub@aybabtu.com>
5325
5326 * loader/i386/linux.c (grub_cmd_linux): Make "vga=" compatibility
5327 parameter only available on BIOS.
5328
ecc3eb22 53292009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
5330
5331 Removed wrong semicolon in declaration
5332
5333 * grub/misc.h (grub_dprintf): remove semicolon
5334
112972a9 53352009-05-04 Robert Millan <rmh.grub@aybabtu.com>
5336
5337 * loader/i386/linux.c (GRUB_ASSUME_LINUX_HAS_FB_SUPPORT): New macro.
5338 (grub_linux_boot): Don't check for `linux_vesafb_modes' bounds (this
5339 is done by grub_cmd_linux() now).
5340 [! GRUB_ASSUME_LINUX_HAS_FB_SUPPORT]: If "vga=" parameter wasn't set,
5341 restore video to text mode.
5342 (grub_cmd_linux): Default `vid_mode' initialization to 0, which
5343 indicates lack of "vga=" parameter. "vga=0" is mapped to
5344 `GRUB_LINUX_VID_MODE_NORMAL'.
5345
afd5c115 53462009-05-04 Felix Zielcke <fzielcke@z-51.de>
5347
5348 * conf/i386-efi.rmk (grub_emu_SOURCES): Remove `normal/execute.c',
5349 `normal/lexer.c', `kern/rescue.c', `normal/function.c', `normal/misc.c'
5350 and `normal/script.c'. Add `kern/rescue_reader.c',
18f547ad 5351 `kern/rescue_parser.c', `script/sh/main.c', `script/sh/execute.c',
afd5c115 5352 `script/sh/function.c', `script/sh/lexer.c', `script/sh/script.c' and
5353 `grub_script.tab.c'.
5354
5355 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5356 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
5357 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5358 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
5359 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
5360
faa517ce 5361 * Makefile.in: Remove duplicated 2008 in Copyright line.
5362
ae0c0bdc 53632009-05-04 Robert Millan <rmh.grub@aybabtu.com>
5364
473d1e45 5365 * util/misc.c (grub_util_warn): New function. Emits a warning
ae0c0bdc 5366 unconditionally.
5367 * include/grub/util/misc.h (grub_util_warn): New declaration.
5368
5369 * util/i386/pc/grub-install.in: Understand --force and pass it down
5370 to grub-setup.
5371
5372 * util/i386/pc/grub-setup.c (main): Understand --force and pass it
5373 down to setup().
5374 (setup): Improve error messages and add warnings when requested to
5375 install in odd layouts. Refuse to install using blocklists unless
5376 --force was set.
5377
18f547ad 53782009-05-04 martin f. krafft <madduck@madduck.net>
c149b500 5379
5380 * disk/raid.c (grub_raid_scan_device): Improve debug message.
5381
6d260daa 53822009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
5383
5384 Updated copyright year
5385
5386 * fs/hfsplus.c: updated copyright year
18f547ad 5387
69f853f8 53882009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
5389
5390 HFS+ UUID
5391
18f547ad 5392 * fs/hfsplus.c (grub_hfsplus_volheader): added num_serial field
69f853f8 5393 in the space previously used by unused3
5394 (grub_hfsplus_uuid): new function
5395 (grub_hfsplus_fs): added uuid field
5396
4c402e73 53972009-05-03 Pavel Roskin <proski@gnu.org>
5398
5399 * disk/ata.c: Don't cast mod to void in GRUB_MOD_INIT to
5400 suppress warnings. It's no longer needed.
5401 * disk/host.c: Likewise.
5402 * disk/ata_pthru.c: Likewise.
5403 * disk/loopback.c: Likewise.
5404 * hook/datehook.c: Likewise.
5405 * parttool/pcpart.c: Likewise.
5406 * fs/i386/pc/pxe.c: Likewise.
5407 * fs/ntfscomp.c: Likewise.
5408 * efiemu/main.c: Likewise.
5409 * mmap/mmap.c: Likewise.
5410 * commands/crc.c: Likewise.
5411 * commands/hexdump.c: Likewise.
5412 * commands/hdparm.c: Likewise.
5413 * commands/acpi.c: Likewise.
5414 * commands/echo.c: Likewise.
5415 * commands/minicmd.c: Likewise.
5416 * commands/blocklist.c: Likewise.
5417 * commands/memrw.c: Likewise.
5418 * commands/loadenv.c: Likewise.
5419 * commands/usbtest.c: Likewise.
5420 * commands/lsmmap.c: Likewise.
5421 * commands/boot.c: Likewise.
5422 * commands/parttool.c: Likewise.
5423 * commands/configfile.c: Likewise.
5424 * commands/search.c: Likewise.
5425 * commands/ieee1275/suspend.c: Likewise.
5426 * commands/cat.c: Likewise.
5427 * commands/i386/pc/pxecmd.c: Likewise.
5428 * commands/i386/pc/play.c: Likewise.
5429 * commands/i386/pc/halt.c: Likewise.
5430 * commands/i386/pc/vbeinfo.c: Likewise.
5431 * commands/i386/pc/vbetest.c: Likewise.
5432 * commands/lspci.c: Likewise.
5433 * commands/date.c: Likewise.
5434 * commands/handler.c: Likewise.
5435 * commands/ls.c: Likewise.
5436 * commands/test.c: Likewise.
5437 * commands/cmp.c: Likewise.
5438 * commands/efi/loadbios.c: Likewise.
5439 * commands/efi/fixvideo.c: Likewise.
5440 * commands/halt.c: Likewise.
5441 * commands/help.c: Likewise.
5442 * commands/reboot.c: Likewise.
5443 * hello/hello.c: Likewise.
5444 * script/sh/main.c: Likewise.
5445 * loader/xnu.c: Likewise.
5446 * term/terminfo.c: Likewise.
5447 * term/i386/pc/serial.c: Likewise.
5448 * term/usb_keyboard.c: Likewise.
5449
515b5079 54502009-05-03 David S. Miller <davem@davemloft.net>
5451
5452 * normal/menu.c: Include grub/parser.h
5453
dfc31a22 54542009-05-03 Pavel Roskin <proski@gnu.org>
5455
2fee74f1 5456 * mmap/efi/mmap.c (grub_mmap_malign_and_register): Return void*,
5457 not char*.
5458 * mmap/i386/mmap.c (grub_mmap_malign_and_register): Likewise.
5459 Suggested by Javier Martín <lordhabbit@gmail.com>
5460
dfc31a22 5461 * util/i386/pc/grub-mkrescue.in: Allow for the case when
5462 efiemu??.o doesn't exist.
5463 * util/i386/pc/grub-install.in: Likewise. Use "cp -f" for
5464 copying.
5465
18f547ad 54662009-05-03 Bean <bean123ch@gmail.com> Vladimir Serbinenko <phcoder@gmail.com>
cef17233 5467
5468 FreeBSD 64-bit support
5469
18f547ad 5470 * conf/i386-pc.rmk (bsd_mod_SOURCES): add loader/i386/bsd_helper.S
cef17233 5471 and loader/i386/bsd_trampoline.S
5472 (bsd_mod_ASFLAGS): new variable
5473 * include/grub/i386/bsd.h (FREEBSD_MODINFOMD_SMAP): new definition
5474 (FREEBSD_MODTYPE_KERNEL64): likewise
5475 (grub_bsd64_trampoline_start): likewise
5476 (grub_bsd64_trampoline_end): likewise
5477 (grub_bsd64_trampoline_selfjump): likewise
5478 (grub_bsd64_trampoline_gdt): likewise
5479 * include/grub/i386/loader.h (grub_unix_real_boot): moved from here ...
5480 * include/grub/i386/bsd.h (grub_unix_real_boot): ... moved here
5481 * kern/i386/loader.S (grub_unix_real_boot): moved from here ...
5482 * loader/i386/bsd_helper.S (grub_unix_real_boot): moved here
18f547ad 5483 * include/grub/gpt_partition.h (grub_gpt_partentry): Corrected the type
cef17233 5484 of "attrib" member
5485 * loader/i386/bsd_pagetable.c: new file
5486 * loader/i386/bsd_trampoline.S: likewise
5487 * loader/i386/bsd.c (ALIGN_QWORD): new macro
5488 (ALIGN_VAR): likewise
5489 (entry_hi): new variable
5490 (kern_end_mdofs): likewise
5491 (is_64bit): likewise
5492 (grub_freebsd_add_meta): use ALIGN_VAR
5493 (grub_e820_mmap): new declaration
5494 (grub_freebsd_add_mmap): new function
5495 (grub_freebsd_add_meta_module): support 64 bit kernels
5496 (grub_freebsd_list_modules): use ALIGN_VAR
5497 (gdt_descriptor): new declaration
5498 (grub_freebsd_boot): support 64 bit kernels
5499 (grub_bsd_elf64_hook): new function
5500 (grub_bsd_load_elf): support elf64
5501
038c5720 55022009-05-03 Bean <bean123ch@gmail.com>
5503
5504 * script/sh/execute.c (grub_script_execute_cmdif): Reset grub_errno
5505 after we get the result of if statement.
5506
fc45fb58 55072009-05-03 Bean <bean123ch@gmail.com>
5508
5509 * Makefile.in (enable_efiemu): New variable.
5510
5511 * conf/i386-pc.rmk: Only compile efiemu runtimes when enable_efiemu is
5512 set.
5513 (efiemu32.o): Use macro $< for source file, add $(srcdir) to include
5514 path.
5515 (efi64_c.o): Use macro $< for source file, add $(srcdir) to include
5516 path, add -mno-red-zone option.
5517 (efiemu64_s.o): Likewise.
5518 (efiemu64.o): Use macro $^ for source file.
5519
5520 * configure.ac (--enable-efiemu): New option.
5521
bbee0f2b 55222009-05-03 Vladimir Serbinenko <phcoder@gmail.com>
5523
5524 xnu support
5525
5526 * conf/i386-efi.rmk (kernel_mod_HEADERS): added i386/pit.h
5527 (pkglib_MODULES): add xnu.mod
5528 (xnu_mod_SOURCES): new variable
5529 (xnu_mod_CFLAGS): likewise
5530 (xnu_mod_LDFLAGS): likewise
5531 (xnu_mod_ASFLAGS): likewise
5532 * conf/i386-pc.rmk: likewise
5533 * conf/x86_64-efi.rmk: likewise
7dd4a573 5534 * include/grub/efi/efi.h (grub_efi_finish_boot_services):
bbee0f2b 5535 new declaration
5536 * include/grub/i386/macho.h: new file
5537 * include/grub/i386/xnu.h: likewise
5538 * include/grub/macho.h: likewise
5539 * include/grub/machoload.h: likewise
5540 * include/grub/x86_64/macho.h: likewise
5541 * include/grub/x86_64/xnu.h: likewise
5542 * include/grub/xnu.h: likewise
5543 * kern/efi/efi.c (grub_efi_finish_boot_services): new function
5544 * kern/efi/mm.c (MAX_HEAP_SIZE): increase
5545 * loader/i386/efi/xnu.c: new file
5546 * loader/i386/pc/xnu.c: likewise
5547 * loader/i386/xnu.c: likewise
5548 * loader/i386/xnu_helper.S: likewise
5549 * loader/macho.c: likewise
5550 * loader/xnu.c: likewise
5551 * loader/xnu_resume.c: likewise
5552 * util/grub-dumpdevtree: likewise
5553 * include/grub/i386/pit.h: include grub/err.h
5554 (grub_pit_wait): export
5555 * util/grub.d/30_os-prober.in: support Darwin/Mac OS X
7dd4a573 5556
5caf964d 55572009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
5558
5559 Efiemu
7dd4a573 5560
5caf964d 5561 * conf/i386-pc.rmk: new modules efiemu, efiemu_acpi, efiemu_pnvram,
7dd4a573 5562 _linux_efi, linux_efi.
5563 new files in grub-emu
5caf964d 5564 new targets efiemu32.o and efiemu64.o
5565 * loader/linux_normal_efiemu.c: likewise
5566 * loader/i386/efi/linux.c: added preliminary efiemu support
7dd4a573 5567 * util/i386/pc/grub-install.in: add efiemu??.o to the list of
5caf964d 5568 files to copy
5569 * include/grub/autoefi.h: new file
7dd4a573 5570 * include/grub/i386/efiemu.h: likewise
5caf964d 5571 * include/grub/i386/pc/efiemu.h: likewise
5572 * include/grub/efi/api.h: add LL suffix when necessary
5573 new definitions relating to tables
5574 * include/grub/efiemu/efiemu.h: new file
5575 * include/grub/efiemu/runtime.h: likewise
5576 * efiemu/prepare.c: likewise
5577 * efiemu/loadcore_common.c: likewise
5578 * efiemu/loadcore64.c: likewise
5579 * efiemu/runtime/efiemu.sh: likewise
5580 * efiemu/runtime/efiemu.S: likewise
5581 * efiemu/runtime/efiemu.c: likewise
5582 * efiemu/runtime/config.h: likewise
5583 * efiemu/prepare32.c: likewise
5584 * efiemu/main.c: likewise
5585 * efiemu/modules/pnvram.c: likewise
5586 * efiemu/modules/i386: likewise
5587 * efiemu/modules/i386/pc: likewise
5588 * efiemu/modules/acpi.c: likewise
5589 * efiemu/i386/pc/cfgtables.c: likewise
5590 * efiemu/i386/loadcore64.c: likewise
5591 * efiemu/i386/loadcore32.c: likewise
5592 * efiemu/prepare64.c: likewise
5593 * efiemu/loadcore.c: likewise
5594 * efiemu/symbols.c: likewise
5595 * efiemu/mm.c: likewise
5596 * efiemu/loadcore32.c: likewise
7dd4a573 5597
55982009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
f8efe3ad 5599
5600 ACPI spoofing
5601
5602 * commands/acpi.c: new file
5603 * commands/i386/pc/acpi.c: likewise
5604 * commands/efi/acpi.c: likewise
5605 * include/grub/acpi.h: likewise
5606 * conf/i386-pc.rmk (pkglib_MODULES): added acpi.mod
5607 (acpi_mod_SOURCES): new variable
5608 (acpi_mod_CFLAGS): likewise
5609 (acpi_mod_LDFLAGS): likewise
5610 * conf/i386-efi.rmk: likewise
5611 * conf/x86_64-efi.rmk: likewise
5612
7dd4a573 56132009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
28a85665 5614
5615 Missing part from mmap patch
5616
5617 * mmap/efi/mmap.c (grub_machine_mmap_unregister): renamed to
5618 (grub_mmap_unregister)
5619 (grub_mmap_free_and_unregister): use grub_mmap_register
5620
7dd4a573 56212009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
09d842b9 5622
5623 Mmap services
5624
5625 * loader/i386/efi/linux.c (grub_linux_boot): use grub_mmap_iterate
5626 * loader/i386/linux.c (find_mmap_size): likewise
5627 (allocate_pages): likewise
5628 * loader/i386/multiboot.c (grub_get_multiboot_mmap_len): likewise
5629 (grub_fill_multiboot_mmap): likewise
5630 (grub_multiboot): use grub_mmap_get_lower and grub_mmap_get_upper
5631 * loader/i386/pc/linux.c (grub_cmd_linux): use grub_mmap_get_lower
5632 * include/grub/i386/bsd.h (OPENBSD_MMAP_AVAILABLE): new definition
5633 (OPENBSD_MMAP_RESERVED): likewise
5634 * include/grub/i386/pc/memory.h: include grub/memory.h
5635 (grub_lower_mem): removed
5636 (grub_upper_mem): likewise
5637 (GRUB_MACHINE_MEMORY_ACPI): new definition
5638 (GRUB_MACHINE_MEMORY_NVS): likewise
5639 (GRUB_MACHINE_MEMORY_MAX_TYPE): likewise
5640 (GRUB_MACHINE_MEMORY_HOLE): likewise
5641 (grub_machine_mmap_register): likewise
5642 (grub_machine_mmap_unregister): likewise
5643 (grub_machine_get_upper): likewise
5644 (grub_machine_get_lower): likewise
5645 (grub_machine_get_post64): likewise
5646 * include/grub/i386/efi/memory.h: new file
5647 * include/grub/x86_64/efi/memory.h: likewise
5648 * include/grub/efi/memory.h: likewise
5649 * conf/i386-pc.rmk (pkglib_MODULES): added mmap.mod
5650 (mmap_mod_SOURCES): new variable
5651 (mmap_mod_LDFLAGS): likewise
5652 (mmap_mod_ASFLAGS): likewise
5653 * conf/i386-coreboot.rmk: likewise
5654 * conf/i386-ieee1275.rmk: likewise
5655 * conf/i386-efi.rmk: likewise
5656 * conf/x86_64-efi.rmk: likewise
5657 * include/grub/types.h (UINT_TO_PTR): new macro
5658 (PTR_TO_UINT32): likewise
5659 (PTR_TO_UINT64): likewise
5660 * include/grub/memory.h: new file
5661 * mmap/i386/pc/mmap.c: likewise
5662 * mmap/i386/pc/mmap_helper.S: likewise
5663 * mmap/i386/uppermem.c: likewise
5664 * mmap/mmap.c: likewise
5665 * mmap/efi/mmap.c: likewise
7dd4a573 5666 * kern/i386/coreboot/init.c (grub_machine_init): don't use
09d842b9 5667 grub_upper_mem
5668 * kern/i386/pc/init.c (grub_lower_mem): removed variable
5669 (grub_upper_mem): likewise
5670 (grub_machine_init): don't use grub_upper_mem,
5671 make grub_lower_mem local
5672 * loader/i386/bsd.c (grub_openbsd_boot): use grub_mmap_get_lower,
5673 grub_mmap_iterate and grub_mmap_get_upper
5674 (grub_netbsd_boot): use grub_mmap_get_lower and grub_mmap_get_upper
5675
d558e6b5 56762009-05-02 Bean <bean123ch@gmail.com>
5677
5678 * conf/common.rmk (grub_script.tab.c): Change normal/parser.y to
5679 script/sh/parser.y.
5680 (pkglib_MODULES): Add normal.mod and sh.mod.
5681 (normal_SOURCES): New variable.
5682 (normal_mod_CFLAGS): Likewise.
5683 (normal_mod_LDFLAGS): Likewise.
5684 (sh_mod_SOURCES): Likewise.
5685 (sh_mod_CFLAGS): Likewise.
5686 (sh_mod_LDFLAGS): Likewise.
5687
5688 * conf/i386-pc.rmk (normal/lexer.c_DEPENDENCIES): Changed to
5689 script/sh/lexer.c_DEPENDENCIES.
5690 (kernel_img_SOURCES): Remove kern/rescue.c, and kern/reader.c,
5691 kern/rescue_reader.c and kern/rescue_parser.c.
5692 (kernel_img_HEADERS): Remove rescue.h, add reader.h.
5693 (grub_emu_SOURCES): Change source files.
5694 (pkglib_MODULES): Remove normal.mod.
5695 (normal_SOURCES): Removed.
5696 (normal_mod_CFLAGS): Likewise.
5697 (normal_mod_LDFLAGS): Likewise.
5698 * conf/i386-coreboot.rmk: Likewise.
5699 * conf/i386-efi.rmk: Likewise.
5700 * conf/i386-ieee1276.rmk: Likewise.
5701 * conf/powerpc-ieee1275.rmk: Likewise.
5702 * conf/sparc64-ieee1275.rmk: Likewise.
5703 * conf/x86_64-efi.rmk: Likewise.
5704
5705 * include/grub/command.h (grub_command_execute): New inline function.
5706
5707 * include/grub/menu.h (grub_menu_entry): Removed commands field.
5708
5709 * include/grub/normal.h: Remove <grub/setjmp.h>.
5710 (grub_fs_module_list): Moved to normal/autofs.c.
5711 (grub_exit_env): Removed.
5712 (grub_command_execute): Likewise.
5713 (grub_normal_menu_addentry): Renamed to grub_menu_addentry, removed
5714 parameter script.
5715 (read_command_list): New function declaration.
5716 (read_fs_list): Likewise.
5717
5718 * include/parser.h: Include <grub/reader.h>.
5719 (grub_parser_split_cmdline): Change type of getline parameter.
5720 (grub_parser): New structure.
5721 (grub_parser_class): New variable.
5722 (grub_parser_execute): New function declaration.
5723 (grub_register_rescue_parser): Likewise.
5724 (grub_parser_register): New inline function.
5725 (grub_parser_unregister): Likewise.
5726 (grub_parser_get_current): Likewise.
5727 (grub_parser_set_current): Likewise.
5728
5729 * include/grub/reader.h: New file.
5730 * kern/reader.c: Likewise.
5731 * kern/rescue_parser.c: Likewise.
5732 * kern/rescue_reader.c: Likewise.
5733 * normal/autofs.c: Likewise.
5734 * normal/dyncmd.c: Likewise.
5735
5736 * include/grub/rescue.h: Removed.
5737 * normal/command.h: Likewise.
5738
5739 * include/grub/script.h: Moved to ...
5740 * include/grub/script_sh.h: ... Moved here.
5741 * normal/execute.c: Moved to ...
5742 * script/sh/execute.c: ... Moved here.
5743 * normal/function.c: Moved to ...
5744 * script/sh/function.c: ... Moved here.
5745 * normal/lexer.c: Moved to ...
5746 * script/sh/lexer.c: ... Moved here.
5747 * normal/parser.y: Moved to ...
5748 * script/sh/parser.y: ... Moved here.
5749 * normal/script.c: Moved to ...
5750 * script/sh/script.c: ... Moved here.
5751
5752 * normal/main.c: Remove <grub/rescue.h> and <grub/script.h>, include
5753 <grub/reader.h>.
5754 (grub_exit_env): Removed.
5755 (fs_module_list): Moved to normal/autofs.c.
5756 (grub_file_getline): Don't handle comment here.
5757 (free_menu): Skip removed field entry->commands.
5758 (grub_normal_menu_addentry): Removed as grub_menu_entry, removed
5759 script parameter.
5760 (read_config_file): Removed nested parameter, change getline function.
5761 (grub_enter_normal_mode): Removed.
5762 (grub_dyncmd_dispatcher): Moved to normal/dyncmd.c.
5763 (read_command_list): Likewise.
5764 (autoload_fs_module): Moved to normal/autofs.c.
5765 (read_fs_list): Likewise.
5766 (reader_nested): New variable.
5767 (grub_normal_execute): Run parser.sh to switch to sh parser.
5768 (grub_cmd_rescue): Removed.
5769 (cmd_normal): Removed.
5770 (grub_cmd_normal): Unregister itself at the beginning. Don't register
5771 rescue command.
5772 (grub_cmdline_run): New function.
5773 (grub_normal_reader_init): Likewise.
5774 (grub_normal_read_line): Likewise.
5775 (grub_env_write_pager): Likewise.
5776 (cmdline): New variable.
5777 (grub_normal_reader): Likewise.
5778 (GRUB_MOD_INIT): Register normal reader and set as current, register
5779 pager hook, register normal command with grub_register_command_prio,
5780 so that it won't show up in command.lst.
5781 (GRUB_MOD_FINI): Unregister normal reader, unhook pager, clear
5782 grub_fs_autoload_hook.
5783
5784 * normal/menu.c: Remove <grub/script.h>, add <grub/command.h>.
5785 (grub_menu_execute_entry): Replace grub_script_execute with
5786 grub_parser_execute, change parameter to grub_command_execute.
5787
5788 * normal/menu_text.c: Remove <grub/script.h>.
5789
5790 * normal/menu_entry.c: Remove <grub/script.h>, add <grub/command.h>
5791 and <grub/parser.h>.
5792 (run): Change editor_getline to use new parser interface. Change
5793 parameter to grub_command_execute.
5794
5795 * kern/main.c: Remove <grub/rescue.h>, include <grub/command.h>,
5796 <grub/reader.h> and <grub/parser.h>.
5797 (grub_load_normal_mode): Execute normal command.
5798 (grub_main): Call grub_register_core_commands,
5799 grub_register_rescue_parser and grub_register_rescue_reader, use
5800 grub_reader_loop to enter input loop.
5801
7dd4a573 5802 * kern/parser.c (grub_parser_split_cmdline): Change type of
5803 getline parameter.
d558e6b5 5804 (grub_parser_class): New variable.
5805 (grub_parser_execute): New function.
5806
5807 * loader/i386/multiboot.c: Remove <grub/rescue.h>.
5808 * loader/multiboot2.c: Likewise.
5809 * loader/sparc64/ieee1275/linux.c: Likewise.
5810
5811 * util/grub-emu.c (read_command_list): New dummy function.
5812
18db813d 58132009-05-02 Robert Millan <rmh.grub@aybabtu.com>
5814
5815 * util/deviceiter.c (grub_util_iterate_devices): Increase max drive
5816 count to 16 for CCISS and IDA.
5817
6c67de15 58182009-05-02 Robert Millan <rmh.grub@aybabtu.com>
5819
5820 * normal/menu_text.c (grub_wait_after_message): Print a newline
5821 after waiting for user input.
5822
5823 * loader/i386/linux.c: Include `<grub/normal.h>'.
5824 (grub_cmd_linux): Improve the error message about `ask' mode, by
5825 waiting for user input so it's not missed (we can do this, since
5826 user requested interaction).
5827
d9dc87b0 58282009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
5829
5830 Added missing lst to grub-mkrescue
5831
5832 * util/i386/pc/grub-mkrescue.in: added ${input_dir}/handler.lst
5833 and ${input_dir}/parttool.lst
5834
ac8a2baa 58352009-04-30 David S. Miller <davem@davemloft.net>
5836
ad22a610 5837 * util/hostdisk.c (device_is_wholedisk): New function.
5838 (grub_util_biosdisk_get_grub_dev): Shortcut when hdg.start is
5839 zero only if device_is_wholedisk() returns true.
5840
6966215d 5841 * util/hostdisk.c (convert_system_partition_to_system_disk):
5842 Handle virtual disk devices named /dev/vdiskX as found on sparc
5843 and powerpc.
5844
ac8a2baa 5845 * kern/sparc64/ieee1275/init.c (grub_machine_set_prefix): If
5846 lettered partition specifier is found, convert to numbered.
5847
979b4fb4 58482009-04-29 David S. Miller <davem@davemloft.net>
5849
e2bf39b2 5850 * include/grub/powerpc/ieee1275/memory.h: Include ieee1275.h.
5851 * include/grub/sparc64/ieee1275/memory.h: Likewise.
5852
3c64e104 5853 * normal/command.c: Add missing newline at end of file.
5854
979b4fb4 5855 * commands/lsmmap.c (grub_cmd_lsmmap): Add casts to avoid printf
5856 warnings.
5857 * kern/ieee1275/openfw.c (grub_claimmap): Likewise.
5858 * disk/ieee1275/ofdisk.c (grub_ofdisk_open, grub_ofdisk_close,
5859 grub_ofdisk_read): Likewise, and deal similarly with the fact that
5860 ihandles have a 32-bit type but need to be stored in a "void *".
5861
136d9f82 58622009-04-28 Pavel Roskin <proski@gnu.org>
5863
9459c306 5864 * disk/fs_uuid.c (grub_fs_uuid_open): Use parent->data for dev,
5865 not disk. Adjust all dependencies.
2e08a26a 5866 (grub_fs_uuid_close): Use grub_device_close(), not
9459c306 5867 grub_disk_close().
5868
136d9f82 5869 * disk/fs_uuid.c (grub_fs_uuid_open): Allocate memory to copy
5870 parent's partition, don't copy it by reference, as it gets freed
5871 on close.
5872
7dd4a573 58732009-04-27 Vladimir Serbinenko <phcoder@gmail.com>
75a807cf 5874
5875 Preboot hooks support
5876
5877 * commands/boot.c (struct grub_preboot_t): new declaration
5878 (preboots_head): new variable
5879 (preboots_tail): likewise
5880 (grub_loader_register_preboot_hook): new function
5881 (grub_loader_unregister_preboot_hook): likewise
5882 (grub_loader_set): launch preboot hooks
5883 * include/grub/loader.h (grub_loader_preboot_hook_prio_t): new type
5884 (grub_loader_register_preboot_hook): new declaration
5885 (grub_loader_unregister_preboot_hook): likewise
5886
5af922b5 58872009-04-27 Vladimir Serbinenko <phcoder@gmail.com>
5888
5889 Warning fix
5890
7dd4a573 5891 * disk/scsi.c (grub_scsi_open): added missing cast when
5af922b5 5892 calling grub_dprintf
5893
a5562c30 58942009-04-26 Vladimir Serbinenko <phcoder@gmail.com>
5895
5896 Bug and warning fixes
5897
7dd4a573 5898 * include/grub/i386/pc/init.h (grub_stop_floppy): added missing
a5562c30 5899 declaration
5900 * commands/test.c (test_parse): fixed bug with file tests and corrected
5901 declaration of find_file
5902
4006f85c 59032009-04-26 Pavel Roskin <proski@gnu.org>
5904
5905 * Makefile.in: Don't install empty manual pages if help2man is
5906 missing. Use help2man option for output, not shell redirection.
5907
5c77c3de 59082009-04-26 David S. Miller <davem@davemloft.net>
5909
5910 * util/grub-mkdevicemap.c (make_device_map): Add missing
5911 NESTED_FUNC_ATTR to process_device().
5912
033b10a8 59132009-04-25 Vladimir Serbinenko <phcoder@gmail.com>
5914
5915 Test command
5916
5917 * commands/test.c: rewritten to use bash-like test
5918
e4343593 59192009-04-25 Vladimir Serbinenko <phcoder@gmail.com>
5920
5921 Parttool autoloading and improvements
5922
7dd4a573 5923 * Makefile.in (pkglib_DATA): add parttool.lst
e4343593 5924 (parttool.lst): new target
5925 * genmk.rb: generate parttool-*
5926 (CLEANFILES): add #{parttool}
5927 (PARTTOOLFILES): new variable
5928 * genparttoollist.sh: new file
7dd4a573 5929 * parttool/pcpart.c (grub_pcpart_boot): more feedback
e4343593 5930 (grub_pcpart_type): likewise
5931 * commands/parttool.c (helpmsg): new variable
5932 (grub_cmd_parttool): output help if not enough arguments are supplied
5933 autoload modules
5934 (GRUB_MOD_INIT(parttool)): use helpmsg
5935
0d312500 59362009-04-24 David S. Miller <davem@davemloft.net>
5937
7dd4a573 5938 Avoiding opening same device multiple times in device iterator.
0d312500 5939
5940 * kern/device.c: (grub_device_iterate): Define struct part_ent,
7dd4a573 5941 and use it to build a list of partitions in iterate_disk() and
0d312500 5942 iterate_partition().
5943
ac20caff 5944 * disk/fs_uuid.c (grub_fs_uuid_close): Call grub_disk_close()
5945 on disk->data.
5946
0dcf7495 5947 * disk/ieee1275/nand.c (grub_nand_iterate): Return
5948 grub_devalias_iterate() result instead of unconditional 0.
5949 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Likewise.
5950 Also, capture hook return value, either directly or via
5951 grub_children_iterate(), and propagate to caller.
5952 * include/grub/ieee1275/ieee1275.h (grub_devalias_iterate,
5953 grub_children_iterate): Return value is now 'int' instead of
5954 'grub_err_t'.
5955 * kern/ieee1275/openfw.c (grub_children_iterate): Fix to behave
5956 like a proper iterator, stopping when hooks return non-zero.
5957 (grub_devalias_iterate): Likewise.
5958
c8c08833 59592009-04-23 David S. Miller <davem@davemloft.net>
5960
5961 * kern/sparc64/ieee1275/openfw.c: Unused, delete.
5962
f01005a8 59632009-04-22 David S. Miller <davem@davemloft.net>
5964
5965 * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): If size_cells
5966 is larger than address_cells, use that value for address_cells too.
5967
4e8269da 5968 * include/grub/ieee1275/ieee1275.h (IEEE1275_MAX_PROP_LEN,
5969 IEEE1275_MAX_PATH_LEN): Define.
5970 * kern/ieee1275/openfw.c (grub_children_iterate): Dynamically
5971 allocate 'childtype', 'childpath', 'childname', and 'fullname'.
5972 (grub_devalias_iterate): Dynamically allocate 'aliasname' and
5973 'devtype'. Explicitly NULL terminate devalias expansion.
5974
a1447506 5975 * util/sparc64/ieee1275/misc.c: New file.
5976 * util/sparc64/ieee1275/grub-setup.c: New file.
5977 * util/sparc64/ieee1275/grub-ofpathname.c: New file.
5978 * util/sparc64/ieee1275/grub-mkimage.c: New file.
5979 * util/sparc64/ieee1275/grub-install.in: New file.
5980 * util/ieee1275/ofpath.c: New file.
5981 * util/ieee1275/devicemap.c: New file.
5982 * util/devicemap.c: New file.
5983 * util/deviceiter.c: New file.
5984 * kern/sparc64/ieee1275/init.c: New file.
5985 * include/grub/util/ofpath.h: New file.
5986 * include/grub/util/deviceiter.h: New file.
5987 * util/grub-mkdevicemap.c: Include deviceiter.h.
5988 Implement using grub_util_emit_devicemap_entry and
5989 grub_util_iterate_devices.
5990 * conf/i386-corebook.rmk: Build util/deviceiter.c and
5991 util/devicemap.c into grub-mkdevicemap
5992 * conf/i386-efi.rmk: Likewise.
5993 * conf/i386-ieee1275.rmk: Likewise.
5994 * conf/i386-pc.rmk: Likewise.
5995 * conf/powerpc-ieee1275.rmk: Likewise.
5996 * conf/sparc64-ieee1275.rmk: Add rules to build boot block
5997 images and installation utilities. Build kernel as image
5998 instead of as elf binary. Use common rules as much as possible.
5999
7dd4a573 60002009-04-19 Vladimir Serbinenko <phcoder@gmail.com>
0aefc632 6001
6002 Correct GPT definition
6003
7dd4a573 6004 * include/grub/gpt_partition.h (grub_gpt_partentry): Corrected the type
0aefc632 6005 of "attrib" member
6006
c6c5219f 60072009-04-19 Felix Zielcke <fzielcke@z-51.de>
6008
6009 * INSTALL: Replace `autogen.sh' with `./autogen.sh'.
6010
0552ff9f 60112009-04-19 David S. Miller <davem@davemloft.net>
6012
6013 * loader/sparc64/ieee1275/linux.c: Include grub/command.h
6014 (grub_rescue_cmd_linux): Rename to...
6015 (grub_cmd_linux): and fix prototype.
6016 (grub_rescue_cmd_initrd): Rename to...
6017 (grub_cmd_initrd): and fix prototype.
6018 (cmd_linux, cmd_initrd): New.
6019 (GRUB_MOD_INIT(linux)): Use grub_register_command().
6020 (GRUB_MOD_FINI(linux): Use grub_unregister_command().
6021
d1a282fc 60222009-04-17 Pavel Roskin <proski@gnu.org>
6023
07c5039f 6024 * bus/usb/ohci.c (grub_ohci_transaction): Fix incorrect printf
6025 format.
6026 (grub_ohci_transfer): Likewise.
6027
b012002d 6028 * bus/usb/usbtrans.c (grub_usb_control_msg): Warning fix.
6029
1bc09c35 6030 * loader/multiboot_loader.c (grub_cmd_multiboot_loader): Fix
6031 return without a value. Fix inconsistent indentation.
6032
e0ff9126 6033 * fs/i386/pc/pxe.c (grub_pxefs_dir): Fix function prototype to
6034 match struct grub_fs.
6035
d1a282fc 6036 * disk/ata.c (grub_ata_pciinit): Use NESTED_FUNC_ATTR.
6037 * bus/usb/ohci.c (grub_ohci_pci_iter): Likewise.
6038 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
6039 * commands/lspci.c (grub_lspci_iter): Likewise.
6040
a96df3f2 60412009-04-16 Bean <bean123ch@gmail.com>
6042
6043 * commands/efi/loadbios.c (grub_cmd_fakebios): Add missing return
6044 value.
6045
41bb0fe9 60462009-04-15 Pavel Roskin <proski@gnu.org>
6047
6048 * include/grub/types.h: Rename ULONG_MAX to GRUB_ULONG_MAX and
6049 LONG_MAX to GRUB_LONG_MAX. Introduce GRUB_LONG_MIN. Update all
6050 users of ULONG_MAX, LONG_MAX and LONG_MIN to use the new
6051 definitions.
6052
596c6970 60532009-04-15 Felix Zielcke <fzielcke@z-51.de>
6054
6055 * disk/lvm.c (grub_lvm_scan_device): Add `LVM' to the error messages,
7dd4a573 6056 that no multiple data or metadata areas are supported and `Unknown
596c6970 6057 metadata header'.
6058
7dd4a573 60592009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
0d5d5653 6060
6061 Move loader out of the kernel
6062
6063 * kern/loader.c: moved to ...
6064 * commands/boot.c: ... moved here
6065 * commands/minicmd.c (grub_mini_cmd_boot): moved to ...
6066 * commands/boot.c (grub_cmd_boot): moved here. All users updated
6067 * include/grub/kernel.h (grub_machine_fini): export
6068 * include/grub/loader.h (grub_loader_is_loaded): update declaration
6069 (grub_loader_set): likewise
6070 (grub_loader_unset): likewise
6071 (grub_loader_boot): likewise
6072 * conf/common.rmk: new module boot.mod
6073 (pkglib_MODULES): add boot.mod
6074 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): remove kern/loader.c
6075 (grub_emu_SOURCES): likewise
6076 * conf/i386-efi.rmk (kernel_elf_SOURCES): likewise
6077 (grub_emu_SOURCES): likewise
6078 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): likewise
6079 (grub_emu_SOURCES): likewise
6080 * conf/i386-pc.rmk (kernel_elf_SOURCES): likewise
6081 (grub_emu_SOURCES): likewise
6082 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): likewise
6083 (grub_emu_SOURCES): likewise
7dd4a573 6084 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): likewise
6085 (grub_emu_SOURCES): likewise
0d5d5653 6086 * conf/x86_64-efi.rmk (kernel_elf_SOURCES): likewise
7dd4a573 6087 (grub_emu_SOURCES): likewise
0d5d5653 6088
7dd4a573 60892009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
5999d619 6090
6091 use grub_lltoa instead of grub_itoa and grub_ltoa for all purposes
7dd4a573 6092
5999d619 6093 * kern/misc.c (grub_itoa): Removed function
6094 (grub_ltoa): likewise
6095 (grub_vsprintf): use grub_lltoa
6096
7dd4a573 60972009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
13c00781 6098
6099 Restore grub-emu
6100
6101 * conf/i386-pc.rmk (grub_emu_SOURCES): add normal/handler.c
6102 * conf/i386-coreboot.rmk: likewise
6103 * conf/i386-ieee1275.rmk: likewise
6104 * conf/powerpc-ieee1275.rmk: likewise
7dd4a573 6105
20318222 61062009-04-15 Felix Zielcke <fzielcke@z-51.de>
6107
6108 * INSTALL: Add that `./autogen.sh' needs to be run before
6109 `./configure.'.
6110
d05f0df3 61112009-04-14 Bean <bean123ch@gmail.com>
6112
6113 * Makefile.in (pkglib_DATA): Add handler.lst.
6114 (handler.lst): New rule.
6115
6116 * conf/i386-pc.rmk (normal_mod_SOURCES): Add normal/handler.c.
6117 * conf/i386-coreboot.rmk: Likewise.
6118 * conf/i386-ieee1275.rmk: Likewise.
6119 * conf/i386-efi.rmk: Likewise.
6120 * conf/x86_64-efi.rmk: Likewise.
6121 * conf/powerpc-ieee1275.rmk: Likewise.
6122 * conf/sparc64-ieee1275.rmk: Likewise.
6123
6124 * genhandlerlist.sh: New file.
6125
6126 * genmk.rb: Add rules to generate handler.lst.
6127
6128 * include/grub/normal.h (grub_file_getline): New function definition.
6129 (read_handler_list): Likewise.
6130 (free_handler_list): Likewise.
6131
6132 * include/grub/term.h (grub_term_register_input): Add name parameter
6133 for auto generation of handler.lst.
6134 (grub_term_register_output): Likewise.
6135
6136 * normal/handler.c: New file.
6137
6138 * normal/main.c (get_line): Renamed to grub_file_getline.
6139 (read_config_file): Use the newly renamed grub_file_getline.
6140 (read_command_list): Likewise.
6141 (read_fs_list): Likewise.
6142 (grub_normal_execute): Call read_handler_list to parse handler.lst.
6143 (GRUB_MOD_FINI): Call free_handler_list to free handler list.
6144
6145 * term/efi/console.c (grub_console_init): Add name parameter for auto
6146 generation of handler.lst.
6147 * term/gfxterm.c: Likewise.
6148 * term/i386/pc/at_keyboard.c: Likewise.
6149 * term/i386/pc/console.c: Likewise.
6150 * term/i386/pc/serial.c: Likewise.
6151 * term/i386/pc/vesafb.c: Likewise.
6152 * term/i386/pc/vga.c: Likewise.
6153 * term/i386/pc/vga_text.c: Likewise.
6154 * term/ieee1275/ofconsole.c: Likewise.
6155 * term/usb_keyboard.c: Likewise.
6156
33c846be 61572009-04-14 Bean <bean123ch@gmail.com>
6158
6159 * util/grub-pe2elf.c (write_symbol_table): Terminate short name symbol
6160 properly with null character.
6161
4484e01e 61622009-04-14 Felix Zielcke <fzielcke@z-51.de>
6163
6164 * configure: Remove.
6165 * config.h.in: Likewise.
f93d668e 6166 * stamp-h.in: Likewise.
4484e01e 6167 * DISTLIST: Likewise.
6168 * conf/common.mk: Likewise.
6169 * conf/i386-coreboot.mk: Likewise.
6170 * conf/i386-efi.mk: Likewise.
6171 * conf/i386-ieee1275.mk: Likewise.
6172 * conf/i386.mk: Likewise.
6173 * conf/i386-pc.mk: Likewise.
6174 * conf/powerpc-ieee1275.mk: Likewise.
6175 * conf/sparc64-ieee1275.mk: Likewise.
6176 * conf/x86_64-efi.mk: Likewise.
6177
6178 * INSTALL: Remove the sentence that Ruby and autoconf are only required if you
6179 develop on GRUB.
6180
7dd4a573 61812009-04-14 John Stanley <jpsinthemix@verizon.net>
5c5bf96a 6182 David S. Miller <davem@davemloft.net>
6183
6184 * util/hostdisk.c (make_device_name): Fix buffer length
6185 calculations.
6186
e25b5a8c 61872009-04-14 Felix Zielcke <fzielcke@z-51.de>
6188
6189 * util/hostdisk.c [__FreeBSD__ || __FreeBSD_kernel__]: Include
6190 <sys/param.h> and <sys/sysctl.h>.
6191 (open_device) [__FreeBSD__ || __FreeBSD_kernel_]: Use sysctlgetbyname()
6192 to add 0x10 to `kern.geom.debugflags' if it's not already set, before
6193 opening the device and reset them afterwards.
6194
1f1f580c 61952009-04-13 Pavel Roskin <proski@gnu.org>
6196
6197 * conf/common.rmk (grub_fstest_SOURCES): Add normal/datetime.c.
6198 Reported by John Stanley <jpsinthemix@verizon.net>
6199
7ebc2d6b 62002009-04-13 Robert Millan <rmh@aybabtu.com>
6201
6202 * util/grub.d/10_freebsd.in: Detect Debian GNU/kFreeBSD and use
7dd4a573 6203 that name for menuentries when appropriate.
7ebc2d6b 6204
d8ba3667 62052009-04-13 Felix Zielcke <fzielcke@z-51.de>
6206
6207 * util/grub.d/10_freebsd.in: Add a missing `fi'.
6208
cba416eb 62092009-04-13 Robert Millan <rmh@aybabtu.com>
6210
6211 * loader/i386/linux.c (grub_cmd_linux): Don't pass `vga=ask' parameter
6212 to Linux, simply abort telling the user it's no longer supported.
6213
a547a745 62142009-04-13 Felix Zielcke <fzielcke@z-51.de>
6215
6216 * util/grub.d/10_freebsd.in: Don't exit if /boot/devices.hints
7dd4a573 6217 doesn't exist. Check also for /boot/kernel/kernel.gz. Print
a547a745 6218 `freebsd_loadenv' only when devices.hints exist.
6219
232a769c 62202009-04-13 Pavel Roskin <proski@gnu.org>
6221
6222 * term/usb_keyboard.c (grub_usb_keyboard_getkey): Warning fixes.
6223
c3012039 62242009-04-13 Felix Zielcke <fzielcke@z-51.de>
6225
6226 * util/i386/pc/grub-install.in (install_drive): Remove the BSD
6227 partition number.
6228 (grub_drive): Likewise.
6229
234022fe 62302009-04-13 David S. Miller <davem@davemloft.net>
6231
6232 * kern/sparc64/ieee1275/ieee1275.c: New file.
6233 * include/grub/sparc64/ieee1275/ieee1275.h (IEEE1275_MAP_WRITE,
6234 IEEE1275_MAP_READ, IEEE1275_MAP_EXEC, IEEE1275_MAP_LOCKED,
6235 IEEE1275_MAP_CACHED, IEEE1275_MAP_SE, IEEE1275_MAP_GLOBAL,
6236 IEEE1275_MAP_IE, IEEE1275_MAP_DEFAULT): Define.
6237 (grub_ieee1275_map_physical, grub_ieee1275_claim_vaddr,
6238 grub_ieee1275_alloc_physmem): Declare new exported functions.
6239
d8e1836c 6240 * include/grub/sparc64/ieee1275/loader.h: New file.
6241 * include/grub/sparc64/ieee1275/memory.h: Likewise.
6242 * include/grub/sparc64/kernel.h: Likewise.
6243 * loader/sparc64/ieee1275/linux.c: Likewise.
6244
96bd81ec 6245 * conf/common.rmk (grub_probe_SOURCES): Add Sun partition module.
6246 (grub_fstest_SOURCES): Likewise.
6247
6a4737e5 6248 * util/hostdisk.c (make_device_name): Do not make any assumptions
6249 about the length of drive names.
6250
1d7a72fd 6251 * kern/dl.c (grub_dl_load_file): Close file immediately when
6252 we are done using it.
6253
56bc2471 62542009-04-12 David S. Miller <davem@davemloft.net>
6255
6256 * kern/misc.c (grub_ltoa): Fix cast when handling negative
6257 values. Noticed by Pavel Roskin.
6258
df38d0bb 6259 * configure.ac: Check for __bswapsi2 and__bswapdi2 using
6260 target compiler.
7dd4a573 6261
e382e93a 6262 * genmk.rb: Add more flexible image type specification, also
6263 pass --strip-unneeded to objcopy.
6264 * conf/i386-pc.rmk: Use *_FORMAT.
6265 * conf/i386-pc.mk: Rebuilt.
6266
f5dbbca9 6267 * disk/ieee1275/ofdisk.c (struct ofdisk_hash_ent): New struct.
6268 (OFDISK_HASH_SZ): Define.
6269 (ofdisk_hash): New hash table.
6270 (ofdisk_hash_fn, ofdisk_hash_find, ofdisk_hash_add): New functions.
6271 (grub_ofdisk_open): Use ofdisk_hash_ent address as disk->id
6272 instead of device phandle which is not unique.
6273
91c88b12 6274 * kern/sparc64/ieee1275/init.c: Delete, replace with...
6275 * kern/sparc64/ieee1275/crt0.S: assembler implementation.
6276 * include/grub/sparc64/ieee1275/kernel.h: Declare grub_prefix[].
6277 (GRUB_MOD_ALIGN, GRUB_MOD_GAP, GRUB_KERNEL_MACHINE_TOTAL_MODULE_SIZE,
6278 GRUB_KERNEL_MACHINE_KERNEL_IMAGE_SIZE,
6279 GRUB_KERNEL_MACHINE_COMPRESSED_SIZE, GRUB_KERNEL_MACHINE_PREFIX,
6280 GRUB_KERNEL_MACHINE_DATA_END): Define.
6281 (grub_kernel_image_size, grub_total_module_size): Declare.
6282
5b5d4aa5 62832009-04-12 Pavel Roskin <proski@gnu.org>
6284
7dd4a573 6285 * configure.ac: Change the logic when we check for target tools.
6286 Do it when the target is specified and it's different from the
6287 specified value of the host.
5b5d4aa5 6288
c91e1793 62892009-04-11 Felix Zielcke <fzielcke@z-51.de>
6290
6291 * util/hostdisk.c [__FreeBSD_kernel__]: Include sys/disk.h.
6292 (grub_util_biosdisk_open) [__FreeBSD_kernel__]: Add support for
6293 GNU/kFreeBSD. Check if a device is a character device. Use
6294 DIOCGMEDIASIZE to get the size.
6295 (convert_system_partition_to_system_disk) [__FreeBSD_kernel__]: Add
6296 support for GNU/kFreeBSD.
6297 (grub_util_biosdisk_get_grub_dev) [__FreeBSD_kernel__]: Check if OS_DEV
6298 is a character device instead of a block device. Add support for
6299 FreeBSD device names.
6300
6301 * util/getroot.c (find_root_device) [__FreeBSD_kernel__]: Check if ENT
6302 is a character device instead of a block device.
6303
6304 * util/grub-probe.c (probe) [__FreeBSD_kernel__]: Check if DEVICE_NAME
6305 is a character device instead of a block device.
6306
b1ac8644 63072009-04-11 Andrey Shuvikov <mr_hyro@yahoo.com>
6308
6309 * util/hostdisk.c [__FreeBSD__]: Include sys/disk.h.
6310 (grub_util_biosdisk_open) [__FreeBSD__]: Add support for
6311 FreeBSD. Check if a device is a character device. Use
6312 DIOCGMEDIASIZE to get the size.
6313 (convert_system_partition_to_system_disk) [__FreeBSD__]: Add
6314 support for FreeBSD.
6315 (grub_util_biosdisk_get_grub_dev) [__FreeBSD__]: Check if OS_DEV
6316 is a character device instead of a block device. Add support for
6317 FreeBSD device names.
6318
6319 * util/getroot.c (find_root_device) [__FreeBSD__]: Check if ENT is
6320 a character device instead of a block device.
6321 (grub_util_check_char_device): New function.
6322
6323 * util/grub-probe.c (probe) [__FreeBSD__]: Check if DEVICE_NAME is
6324 a character device instead of a block device.
6325
6326 * include/grub/util/getroot.h (grub_util_check_char_device): New
6327 prototype.
6328
a3f7515a 63292009-04-11 David S. Miller <davem@davemloft.net>
6330
6331 * conf/sparc64-ieee1275.rmk (kernel_img_LDFLAGS): Link with
6332 static libgcc.
6333 * configure.ac: Check for __bswapsi2 and __bswapdi2 presence.
6334 * include/grub/sparc64/libgcc.h (__bswapsi2): Export libgcc
6335 function, if present.
6336 (__bswapdi2): Likewise.
6337
0d44993d 6338 * include/grub/sparc64/ieee1275/boot.h: New file.
6339 * boot/sparc64/ieee1275/boot.S: Likewise.
6340 * boot/sparc64/ieee1275/diskboot.S: Likewise.
6341
ed3d2bc2 6342 * kern/misc.c (grub_ltoa): New function.
6343 (grub_vsprintf): Use it to format 'long' integers.
6344
d3bfb59c 63452009-04-10 David S. Miller <davem@davemloft.net>
6346
6347 * disk/ieee1275/nand.c (grub_nand_open): All ieee1275 call arg
6348 slots are of type grub_ieee1275_cell_t.
6349 (grub_nand_read): Likewise.
6350 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_INVALID,
6351 IEEE1275_IHANDLE_INVALID): Use grub_ieee1275_cell_t since these
6352 macros are used to compare values in arg/ret block of the call.
6353 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
6354 grub_ieee1275_next_property, grub_ieee1275_get_property_length,
6355 grub_ieee1275_instance_to_package, grub_ieee1275_package_to_path,
6356 grub_ieee1275_instance_to_path, grub_ieee1275_write,
6357 grub_ieee1275_read, grub_ieee1275_seek, grub_ieee1275_peer,
6358 grub_ieee1275_child, grub_ieee1275_parent, grub_ieee1275_open,
6359 grub_ieee1275_close, grub_ieee1275_set_property,
6360 grub_ieee1275_set_color): All ieee1275 call arg slots are of type
6361 grub_ieee1275_cell_t.
6362 * kern/ieee1275/openfw.c (grub_map): Likewise.
6363 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_ihandle_t,
6364 grub_ieee1275_phandle_t): Define as grub_unit32_t type.
6365
450e2238 6366 * kern/ieee1275/init.c (grub_machine_init): Make 'actual' grub_ssize_t.
6367 * kern/ieee1275/openfw.c (grub_children_iterate): Likewise.
6368 (grub_devalias_iterate): Likewise.
6369
7dd4a573 63702009-04-10 Vladimir Serbinenko <phcoder@gmail.com>
6df8cc76 6371
6372 UFS improvements
6373
6374 * fs/ufs.c (INODE_NBLOCKS): new definition
6375 (struct grub_ufs_dirent): added fields for non-BSD dirents
6376 (grub_ufs_get_file_block): fixed double indirect handling
6377 (grub_ufs_lookup_symlink): use more robust way to determine whether
6378 symlink is inline
6379 (grub_ufs_find_file): support for non-BSD dirents
6380 (grub_ufs_dir): support for non-BSD dirents
6381
e7e6862a 63822009-04-10 Bean <bean123ch@gnail.com>
6383
6384 * include/grub/efi/api.h (grub_efi_configuration_table): Add packed
6385 attribute, otherwise the size would be wrong for i386 platform.
6386
6387 * include/grub/pci.h (grub_pci_read_word): New inline function.
6388 (grub_pci_read_byte): Likewise.
6389 (grub_pci_write): Likewise.
6390 (grub_pci_write_word): Likewise.
6391 (grub_pci_write_byte): Likewise.
6392
6393 * include/grub/pci.h (grub_pci_iteratefunc_t): Add NESTED_FUNC_ATTR.
6394
6395 * loader/i386/efi/linux.c (fake_bios_data): Moved to loadbios module.
6396 (find_framebuf): Scan pci to locate the frame buffer address.
6397
6398 * commands/efi/fixvideo.c: New file.
6399
6400 * commands/efi/loadbios.c: Likewise.
6401
6402 * commands/memrw.c: Likewise.
6403
6404 * util/grub-dumpbios.in: Likewise.
6405
6406 * conf/common.rmk (grub-dumpbios): New utility.
6407 (pkglib_MODULES): New module memrw.mod.
6408 (memrw_mod_SOURCE): New macro.
6409 (memrw_mod_CFLAGS): Likewise.
6410 (memrw_mod_LDFLAGS): Likewise.
6411
7dd4a573 6412 * conf/i386-efi.rmk (pkglib_MODULES): New module loadbios.mod and
e7e6862a 6413 fixvideo.mod.
6414 (loadbios_mod_SOURCE): New macro.
6415 (loadbios_mod_CFLAGS): Likewise.
6416 (loadbios_mod_LDFLAGS): Likewise.
6417 (fixvideo_mod_SOURCE): Likewise.
6418 (fixvideo_mod_CFLAGS): Likewise.
6419 (fixvideo_mod_LDFLAGS): Likewise.
6420
7dd4a573 6421 * conf/x86_64.rmk (pkglib_MODULES): New module loadbios.mod and
e7e6862a 6422 fixvideo.mod.
6423 (loadbios_mod_SOURCE): New macro.
6424 (loadbios_mod_CFLAGS): Likewise.
6425 (loadbios_mod_LDFLAGS): Likewise.
6426 (fixvideo_mod_SOURCE): Likewise.
6427 (fixvideo_mod_CFLAGS): Likewise.
6428 (fixvideo_mod_LDFLAGS): Likewise.
6429
af63ada2 64302009-04-08 Felix Zielcke <fzielcke@z-51.de>
6431
6432 * disk/lvm.c (grub_lvm_scan_device): Add a missing NULL check.
6433
c2cdde70 64342009-04-07 David S. Miller <davem@davemloft.net>
6435
6436 * kern/sparc64/dl.c (grub_arch_dl_relocate_symbols): Add
6437 support for R_SPARC_OLO10 relocations. Fix compile warning for
6438 R_SPARC_WDISP30 case.
ea3f72cf 6439 * kern/sparc64/cache.S: Fix grub_arch_sync_caches implementation.
c2cdde70 6440
761319cf 64412009-04-06 Pavel Roskin <proski@gnu.org>
6442
1007d1f5 6443 * include/grub/misc.h (ARRAY_SIZE): New macro.
6444 * include/grub/i386/linux.h (GRUB_LINUX_VID_MODE_VESA_START):
6445 New macro.
6446 * loader/i386/linux.c (allocate_pages): Use free_pages().
6447 (grub_linux_unload): Don't use free_pages().
6448 (grub_linux_boot): Prevent accessing linux_vesafb_modes with a
6449 wrong index. Treat all other modes as text modes.
6450 (grub_cmd_linux): Initialize vid_mode unconditionally to
6451 GRUB_LINUX_VID_MODE_NORMAL. Recognize and support "vga=ask".
6452
761319cf 6453 * commands/help.c (print_command_help): Use cmd->prio, not
6454 cmd->flags to check for GRUB_PRIO_LIST_FLAG_ACTIVE.
6455
ea761d40 64562009-04-06 Vladimir Serbinenko <phcoder@gmail.com>
7dd4a573 6457
ea761d40 6458 Parttool
6459
6460 * parttool/pcpart.c: new file
6461 * commands/parttool.c: likewise
6462 * conf/common.rmk (pkglib_MODULES): Added parttool.mod and pcpart.mod
6463 (parttool_mod_SOURCES): new variable
6464 (parttool_mod_CFLAGS): likewise
6465 (parttool_mod_LDFLAGS): likewise
6466 (pcpart_mod_SOURCES): likewise
6467 (pcpart_mod_CFLAGS): likewise
6468 (pcpart_mod_LDFLAGS): likewise
7dd4a573 6469 * conf/i386-coreboot.rmk (grub_emu_SOURCES): added commands/parttool.c
ea761d40 6470 and parttool/pcpart.c
6471 * conf/i386-efi.rmk: likewise
6472 * conf/i386-ieee1275.rmk: likewise
6473 * conf/i386-pc.rmk: likewise
6474 * conf/powerpc-ieee1275.rmk: likewise
6475 * conf/sparc64-ieee1275.rmk: likewise
6476 * conf/x86_64-ieee1275.rmk: likewise
6477
05aaebfb 64782009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
6479
6480 Support for mtime and further expandability of dir command
6481
6482 * include/grub/lib/datetime.h: moved to ...
7dd4a573 6483 * include/grub/datetime.h: ... moved here and added
05aaebfb 6484 declaration of grub_unixtime2datetime. All users updated
7dd4a573 6485 * include/grub/fs.h: new syntax for dir and mtime functions in
6486 struct grub_fs
05aaebfb 6487 * include/grub/fshelp.h: new declarations of GRUB_FSHELP_TYPE_MASK
6488 and GRUB_FSHELP_FLAGS_MASK
6489 * commands/ls.c (grub_ls_list_files): Write mtime in long format
6490 * fs/ext2.c (grub_ext2_dir): use new dir syntax and supply mtime
6491 (grub_ext2_mtime): new function
6492 * fs/hfsplus.c (grub_hfsplus_dir): use new dir syntax and supply mtime
6493 (grub_hfsplus_mtime): new function
6494 * fs/ufs.c (GRUB_UFS_ATTR_TYPE): new definition
6495 (GRUB_UFS_ATTR_FILE): likewise
6496 (GRUB_UFS_ATTR_LNK): likewise
6497 (struct grub_ufs_sblock): new fields mtime
6498 (grub_ufs_read_inode): new parameter to read inode to a separate buffer
6499 all users updated
6500 (grub_ufs_dir): mtime support
6501 (grub_ufs_mtime): new function
6502 * fs/affs.c (grub_affs_dir): use new dir syntax
6503 * fs/afs.c (grub_afs_dir): likewise
6504 * fs/cpio.c (grub_cpio_dir): likewise
6505 * fs/fat.c (grub_fat_find_dir): likewise
6506 * fs/hfs.c (grub_hfs_dir): likewise
6507 * fs/iso9660.c (grub_iso9660_dir): likewise
6508 * fs/jfs.c (grub_jfs_dir): likewise
6509 * fs/minix.c (grub_minix_dir): likewise
6510 * fs/ntfs.c (grub_ntfs_dir): likewise
6511 * fs/reiserfs.c (grub_reiserfs_dir): likewise
6512 * fs/sfs.c (grub_sfs_dir): likewise
6513 * fs/xfs.c (grub_xfs_dir): likewise
6514 * util/hostfs.c (grub_hostfs_dir): likewise
6515 * lib/datetime.c: moved to ...
6516 * normal/datetime.c: ... moved here
6517 (grub_unixtime2datetime): new function
6518 * kern/rescue.c (grub_rescue_print_files): use new dir syntax
7dd4a573 6519 * normal/completion.c (iterate_dir): use new dir syntax
6520 * normal/misc.c (grub_normal_print_device_info): tell the
05aaebfb 6521 last modification time of a volume
7dd4a573 6522 * kern/fs.c (grub_fs_probe): updated dummy function to use new syntax
05aaebfb 6523 * conf/common.rmk: added lib/datetime.c to ls.mod
7dd4a573 6524 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add normal/datetime.c
05aaebfb 6525 (normal_mod_SOURCES): likewise
6526 (datetime_mod_SOURCES): Removed lib/datetime.c
6527 * conf/i386-efi.rmk: likewise
7dd4a573 6528 * conf/i386-ieee1275.rmk: likewise
05aaebfb 6529 * conf/i386-pc.rmk: likewise
6530 * conf/powerpc-ieee1275.rmk: likewise
7dd4a573 6531 * conf/sparc64-ieee1275.rmk: likewise
6532 * conf/x86_64-efi.rmk: likewise
05aaebfb 6533
8a7e1a14 65342009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
6535
6536 Trim trailing spaces in FAT label and support mtools-like labels
7dd4a573 6537
6538 * fs/fat.c (grub_fat_iterate_dir): New function based
8a7e1a14 6539 on grub_fat_find_dir
6540 (grub_fat_find_dir): use grub_fat_iterate_dir
6541 (grub_fat_label): likewise
6542
04186a9c 65432009-04-04 Vladimir Serbinenko <phcoder@gmail.com>
6544
7dd4a573 6545 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): add list.h
04186a9c 6546 and command.h
6547 remove extraneous kernel_elf_HEADERS
6548
da4c0bb6 65492009-04-04 Bean <bean123ch@gnail.com>
6550
6551 * include/grub/util/misc.h: Add dummy function fsync for mingw.
6552
6553 * util/misc.c: Likewise.
6554
54ad9555 65552009-04-04 Yoshinori K. Okuji <okuji@enbug.org>
6556
6557 * loader/i386/efi/linux.c (fake_bios_data): Use grub_dprintf
6558 instead of grub_printf.
6559
7a6bf9f2 65602009-04-03 Robert Millan <rmh@aybabtu.com>
6561
6562 * loader/i386/linux.c (grub_linux_setup_video): Fill
6563 `params->{red,green,blue,reserved}_{mask_size,field_pos}' with
6564 values from `mode info' structure instead of hardcoded
6565 values.
6566
3fcc2083 65672009-04-01 Pavel Roskin <proski@gnu.org>
6568
6569 * Makefile.in: Remove all references to MODULE_LDFLAGS, it's
6570 unused now.
6571 * genmk.rb: Likewise.
6572 * configure.ac: Likewise.
6573
5ec9740b 65742009-04-01 Manoel Abranches <mrabran@linux.vnet.ibm.com>
6575
6576 * aclocal.m4: Move --build-id=none from MODULE_LDFLAGS to
6577 TARGET_LDFLAGS. This corrects a problem with grub-mkelfimage.
6578
5270cec8 65792009-04-01 David S. Miller <davem@davemloft.net>
6580
6581 * normal/sparc64/setjmp.S: Fix setjmp implementation.
7dd4a573 6582 * include/grub/sparc64/setjmp.h (grub_jmp_buf): Update.
5270cec8 6583 (grub_setjmp): Mark with 'returns_twice' attribute.
6584 * include/grub/i386/setjmp.h (grub_setjmp): Likewise
6585 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise.
6586 * include/grub/x86_64/setjmp.h (grub_setjmp): Likewise.
6587
9c3dd854 65882009-04-01 Robert Millan <rmh@aybabtu.com>
6589
6590 Reapply fix from 2008-07-28 which was accidentally reverted; also
6591 perform the same fix to a similar check in same function.
6592
6593 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
6594 with the same number are found, just use issue a warning with
6595 grub_dprintf(), as this error has been reported to be non-fatal.
6596
0d818b7e 65972009-03-31 Pavel Roskin <proski@gnu.org>
6598
6599 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Provide safe default
6600 for cross-compilation.
6601
95646d92 66022009-03-30 Robert Millan <rmh@aybabtu.com>
6603
6604 Fix i386-ieee1275 build.
6605
6606 * include/grub/i386/ieee1275/loader.h (grub_multiboot2_real_boot):
6607 Remove declaration.
6608
6a003ed1 66092009-03-30 Pavel Roskin <proski@gnu.org>
6610
6611 * fs/hfs.c (grub_hfs_strncasecmp): Integrate into ...
6612 (grub_hfs_cmp_catkeys): ... this. Don't assume strings to be
6613 zero-terminated, rely only on the strlen value. Fix comparison
6614 of strings differing in length.
6615
92f33540 66162009-03-30 Robert Millan <rmh@aybabtu.com>
6617
6618 * loader/i386/linux.c (grub_cmd_linux): Check for zImage before
6619 checking for abi version. Improve error messages on BIOS to notify
6620 user about `linux16' command.
6621
a8c48fd5 66222009-03-29 Vladimir Serbinenko <phcoder@gmail.com>
6623
f968172e 6624 Leak fixes
a8c48fd5 6625
f968172e 6626 * kern/disk.c (grub_disk_cache_store): Invalidate previous cache
6627 in case of collision
6628 * disk/scsi.c (grub_scsi_open): free scsi in case of error
a8c48fd5 6629
9c323f09 66302009-03-29 Robert Millan <rmh@aybabtu.com>
6631
6632 * loader/i386/linux.c (grub_cmd_linux): Parse "vga=" parameter and
6633 set `vid_mode' accordingly.
6634 (grub_linux_boot): Process `vid_mode' and set video mode.
6635
ae68f423 66362009-03-29 Robert Millan <rmh@aybabtu.com>
6637
6638 * util/grub.d/10_linux.in (linux_entry): New function.
6639 Factorize generation of Linux boot entries.
6640
5709cfc4 66412009-03-29 Yoshinori K. Okuji <okuji@enbug.org>
6642
6643 Make the format of Environment Block plain text. The boot loader
6644 part is not tested well yet.
7dd4a573 6645
5709cfc4 6646 * util/grub-editenv.c (DEFAULT_ENVBLK_SIZE): New macro.
6647 (buffer): Removed.
6648 (envblk): Likewise.
6649 (usage): Remove "info" and "clear". Add "unset". Update the
6650 description of "set", as this does not delete variables any
6651 longer.
6652 (create_envblk_file): Complete rewrite.
6653 (open_envblk_file): Likewise.
6654 (cmd_info): Removed.
6655 (cmd_list): Likewise.
6656 (cmd_set): Likewise.
6657 (cmd_clear): Likewise.
6658 (list_variables): New function.
6659 (write_envblk): Likewise.
6660 (set_variables): Likewise.
6661 (unset_variables): Likewise.
6662 (main): Complete rewrite.
6663
6664 * commands/loadenv.c (buffer): Removed.
6665 (envblk): Likewise.
6666 (open_envblk_file): New function.
6667 (read_envblk_file): Complete rewrite.
6668 (grub_cmd_load_env): Likewise.
6669 (grub_cmd_list_env): Likewise.
6670 (struct blocklist): New struct.
6671 (free_blocklists): New function.
6672 (check_blocklists): Likewise.
6673 (write_blocklists): Likewise.
6674 (grub_cmd_save_env): Complete rewrite.
6675
6676 * include/grub/lib/envblk.h (GRUB_ENVBLK_SIGNATURE): Replaced with
6677 a plain text signature.
6678 (GRUB_ENVBLK_MAXLEN): Removed.
6679 (struct grub_envblk): Complete rewrite.
6680 (grub_envblk_find): Removed.
6681 (grub_envblk_insert): Likewise.
6682 (grub_envblk_open): New prototype.
6683 (grub_envblk_set): Likewise.
6684 (grub_envblk_delete): Put const to VALUE.
6685 (grub_envblk_iterate): Put const to NAME and VALUE.
6686 (grub_envblk_close): New prototype.
6687 (grub_envblk_buffer): New inline function.
6688 (grub_envblk_size): Likewise.
6689
6690 * lib/envblk.c: Include grub/mm.h.
6691 (grub_env_find): Removed.
6692 (grub_envblk_open): New function.
6693 (grub_envblk_close): Likewise.
6694 (escaped_value_len): Likewise.
6695 (find_next_line): Likewise.
6696 (grub_envblk_insert): Removed.
6697 (grub_envblk_set): New function.
6698 (grub_envblk_delete): Complete rewrite.
6699 (grub_envblk_iterate): Likewise.
6700
a9368fd3 67012009-03-28 Robert Millan <rmh@aybabtu.com>
6702
6703 * conf/i386-pc.rmk (pkglib_MODULES): Add `linux16.mod'.
6704 (linux16_mod_SOURCES, linux16_mod_CFLAGS, linux16_mod_LDFLAGS): New
6705 variables. Use 16-bit loader.
6706 (linux_mod_SOURCES, linux_mod_CFLAGS, linux_mod_LDFLAGS): Use 32-bit
6707 loader.
6708 * kern/i386/loader.S (grub_linux_boot): Rename to ...
6709 (grub_linux16_boot): ... this. Update all users.
6710 * loader/i386/linux.c (grub_linux32_boot): Rename to ...
6711 (grub_linux_boot): ... this. Update all users.
6712
6713 * loader/i386/pc/linux.c (GRUB_MOD_INIT(linux)): Rename to ...
6714 (GRUB_MOD_INIT(linux16)): ... this. Rename `linux' and `initrd'
6715 commands to `linux16' and `initrd16'.
6716 (GRUB_MOD_FINI(linux)): Rename to ...
6717 (GRUB_MOD_FINI(linux16)): ... this.
6718
e4dd5a7e 67192009-03-24 Pavel Roskin <proski@gnu.org>
6720
6721 * genmk.rb: Define ASM_FILE for *.S files for *.lst generation,
6722 not just for compilation.
6723
c04d6e05 67242009-03-22 Vladimir Serbinenko <phcoder@gmail.com>
6725
6726 Move multiboot helper out of kernel
6727
6728 * conf/i386-pc.rmk (multiboot_mod_SOURCES): Add
6729 `loader/i386/multiboot_helper.S'.
6730 * conf/i386-coreboot.rmk: Likewise
6731 * conf/i386-ieee1275.rmk: Likewise
6732
6733 * kern/i386/loader.S: Move multiboot helpers from here...
6734 * loader/i386/multiboot_helper.S: ...moved here
6735 * include/grub/i386/loader.h: Move declarations of multiboot
6736 helpers from here...
6737 * include/grub/i386/multiboot.h: ...moved here
6738 * loader/i386/multiboot.c: Added include of grub/cpu/multiboot.h
6739
42a5b3fc 67402009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
6741
6742 * kern/env.c (grub_env_context_open): Added an argument to specify
6743 whether a new context inherits exported variables from current
6744 one. This is useful when making a sandbox to interpret a config
6745 file.
6746 All callers updated.
6747
6748 * include/grub/env.h (grub_env_context_open): Updated the prototype.
6749
b28bbc4e 67502009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
6751
6752 * kern/env.c (grub_env_context_close): Fix memory leaks.
6753
f04f02e4 67542009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
6755
6756 * normal/main.c (grub_normal_execute): Added an argument
6757 BATCH to specify if an interactive interface should be provided
6758 after reading a config file.
6759 All callers updated.
6760 (read_command_list): Prevent being executed twice.
6761 (read_fs_list): Likewise.
6762
42a5b3fc 6763 * include/grub/normal.h (grub_normal_execute): Updated the
6764 prototype.
f04f02e4 6765
41473ac2 67662009-03-22 Pavel Roskin <proski@gno.org>
6767
fbc00b0c 6768 * kern/powerpc/ieee1275/startup.S: Replace EXT_C(start) with
6769 _start.
6770 * kern/i386/pc/startup.S: Likewise.
6771 * kern/i386/efi/startup.S: Likewise.
6772 * kern/i386/ieee1275/startup.S: Likewise.
6773 * kern/i386/coreboot/startup.S: Likewise.
6774 * kern/x86_64/efi/startup.S: Likewise.
6775
41473ac2 6776 * aclocal.m4 (grub_CHECK_START_SYMBOL): Remove.
6777 * configure.ac: Don't call grub_CHECK_START_SYMBOL.
6778 * kern/i386/pc/startup.S: Use _start instead of START_SYMBOL.
6779
2274cc8f 67802009-03-21 Vladimir Serbinenko <phcoder@gmail.com>
6781
6782 Bugfixes in multiboot for bugs uncovered by solaris kernel.
6783
6784 * loader/i386/multiboot_elfxx.c (grub_multiboot_load_elf): Corrected
6785 limit detection.
6786 Use vaddr of correct segment for entry_point.
6787
b1b797cb 67882009-03-21 Bean <bean123ch@gmail.com>
6789
6790 * commands/blocklist.c: Add include file <grub/command.h>, remove
6791 <grub/normal.h> and <grub/arg.h>.
6792 (grub_cmd_blocklist): Use the new command interface.
6793 (GRUB_MOD_INIT): Likewise.
6794 (GRUB_MOD_FINI): Likewise.
6795 * commands/boot.c: Likewise.
6796 * commands/cat.c: Likewise.
6797 * commands/cmp.c: Likewise.
6798 * commands/configfile.c: Likewise.
6799 * commands/crc.c: Likewise.
6800 * commands/echo.c: Likewise.
6801 * commands/halt.c: Likewise.
6802 * commands/handler.c: Likewise.
6803 * commands/hdparm.c: Likewise.
6804 * commands/help.c: Likewise.
6805 * commands/hexdump.c: Likewise.
6806 * commands/loadenv.c: Likewise.
6807 * commands/ls.c: Likewise.
6808 * commands/lsmmap.c: Likewise.
6809 * commands/lspci.c: Likewise.
6810 * commands/loadenv.c: Likewise.
6811 * commands/read.c: Likewise.
6812 * commands/reboot.c: Likewise.
6813 * commands/search.c: Likewise.
6814 * commands/sleep.c: Likewise.
6815 * commands/test.c: Likewise.
6816 * commands/usbtest.c: Likewise.
6817 * commands/videotest.c: Likewise.
6818 * commands/i386/cpuid.c: Likewise.
6819 * commands/i386/pc/halt.c: Likewise.
6820 * commands/i386/pc/play.c: Likewise.
6821 * commands/i386/pc/pxecmd.c: Likewise.
6822 * commands/i386/pc/vbeinfo.c: Likewise.
6823 * commands/i386/pc/vbetest.c: Likewise.
6824 * commands/ieee1275/suspend.c: Likewise.
6825 * disk/loopback.c: Likewise.
6826 * font/font_cmd.c: Likewise.
6827 * hello/hello.c: Likewise.
6828 * loader/efi/appleloader.c: Likewise.
6829 * loader/efi/chainloader.c: Likewise.
6830 * loader/i386/bsd.c: Likewise.
6831 * loader/i386/efi/linux.c: Likewise.
6832 * loader/i386/ieee1275/linux.c: Likewise.
6833 * loader/i386/linux.c: Likewise.
6834 * loader/i386/pc/chainloader.c: Likewise.
6835 * loader/i386/pc/linux.c: Likewise.
6836 * loader/powerpc/ieee1275/linux.c: Likewise.
6837 * loader/multiboot_loader.c: Likewise.
6838 * term/gfxterm.c: Likewise.
6839 * term/i386/pc/serial.c: Likewise.
6840 * term/terminfo.c: Likewise.
6841
6842 * term/i386/pc/vesafb.c: Removed <grub/arg.h>.
6843 * term/i386/pc/vga.c: Likewise.
6844 * video/readers/jpeg.c: Likewise.
6845 * video/readers/png.c: Likewise.
6846 * video/readers/tga.c: Likewise.
6847
6848 * util/grub-fstest (cmd_loopback): Removed.
6849 (cmd_blocklist): Likewise.
6850 (cmd_ls): Likewise.
6851 (grub_register_command): Likewise.
6852 (grub_unregister_command): Likewise.
6853 (execute_command): Use grub_command_find to locate command and execute
6854 it.
6855
6856 * include/grub/efi/chainloader.h: Removed.
6857 * loader/efi/chainloader_normal.c: Likewise.
6858 * loader/i386/bsd_normal.c: Likewise.
6859 * loader/i386/pc/chainloader_normal.c: Likewise.
6860 * loader/i386/pc/multiboot_normal.c: Likewise.
6861 * loader/linux_normal.c: Likewise.
6862 * loader/multiboot_loader_normal.c: Likewise.
6863 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
6864
6865 * gencmdlist.sh: Scan new registration command grub_register_extcmd
6866 and grub_register_command_p1.
6867
6868 * conf/common.rmk (grub_fstest_SOURCES): Add kern/list.c,
6869 kern/command.c, lib/arg.c and commands/extcmd.c.
6870 (pkglib_MODULES): Remove boot.mod, and minicmd.mod and extcmd.mod.
6871 (minicmd_mod_SOURCES): New variable.
6872 (minicmd_mod_CFLAGS): Likewise.
6873 (minicmd_mod_LDFLAGS): Likewise.
6874 (extcmd_mod_SOURCES): Likewise.
6875 (extcmd_mod_CFLAGS): Likewise.
6876 (extcmd_mod_LDFLAGS): Likewise.
6877 (boot_mod_SOURCES): Removed.
6878 (boot_mod_CFLAGS): Likewise.
6879 (boot_mod_LDFLAGS): Likewise.
6880
6881 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/command.c and
6882 kern/corecmd.c.
6883 (kernel_img_HEADERS): Add command.h.
6884 (grub_emu_SOURCES): Remove commands/boot.c and normal/arg.c, add
6885 commands/minicmd.c, kern/command.c, kern/corecmd.c, commands/extcmd.c
6886 and lib/arg.c.
6887 (pkglib_MODULES): Change _linux.mod, _chain.mod, _bsd.mod and
6888 _multiboot.mod as linux.mod, chain.mod, bsd.mod and multiboot.mod,
6889 remove the corresponding normal mode command.
6890 (normal_mod_SOURCES): Remove normal/arg.c.
6891 * conf/i386-coreboot.rmk: Likewise.
6892 * conf/i386-efi.rmk: Likewise.
6893 * conf/i386-ieee1275.rmk: Likewise.
6894 * conf/powerpc-ieee1275.rmk: Likewise.
6895 * conf/x86_64-efi.rmk: Likewise.
6896
6897 * include/grub/arg.h: Move from here ...
6898 * include/grub/lib/arg.h: ... to here.
6899
6900 * normal/arg.c: Move from here ...
6901 * lib/arg.c: ... to here.
6902
6903 * commands/extcmd.c: New file.
6904 * commands/minicmd.c: Likewise.
6905 * include/grub/command.h: Likewise.
6906 * include/grub/extcmd.h: Likewise.
6907 * kern/command.c: Likewise.
6908 * kern/corecmd.c: Likewise.
6909
6910 * kern/list.c (grub_list_iterate): Return int instead of void.
6911 (grub_list_insert): New function.
6912 (grub_prio_list_insert): Likewise.
6913
6914 * kern/rescue.c (grub_rescue_command): Removed.
6915 (grub_rescue_command_list): Likewise.
6916 (grub_rescue_register_command): Likewise.
6917 (grub_rescue_unregister_command): Likewise.
6918 (grub_rescue_cmd_boot): Move to minicmd.c
6919 (grub_rescue_cmd_help): Likewise.
6920 (grub_rescue_cmd_info): Likewise.
6921 (grub_rescue_cmd_boot): Likewise.
6922 (grub_rescue_cmd_testload): Likewise.
6923 (grub_rescue_cmd_dump): Likewise.
6924 (grub_rescue_cmd_rmmod): Likewise.
6925 (grub_rescue_cmd_lsmod): Likewise.
6926 (grub_rescue_cmd_exit): Likewise.
6927 (grub_rescue_print_devices): Moved to corecmd.c.
6928 (grub_rescue_print_files): Likewise.
6929 (grub_rescue_cmd_ls): Likewise.
6930 (grub_rescue_cmd_insmod): Likewise.
6931 (grub_rescue_cmd_set): Likewise.
6932 (grub_rescue_cmd_unset): Likewise.
7d074e3c 6933 (attempt_normal_mode): Use grub_command_find to get normal module.
b1b797cb 6934 (grub_enter_rescue_mode): Use grub_register_core_commands to register
7d074e3c 6935 commands, remove grub_rescue_register_command calls.
b1b797cb 6936
7d074e3c 6937 * normal/command.c (grub_register_command): Removed.
b1b797cb 6938 (grub_unregister_command): Likewise.
6939 (grub_command_find): Likewise.
6940 (grub_iterate_commands): Likewise.
6941 (rescue_command): Likewise.
6942 (export_command): Moved to corecmd.c.
6943 (set_command): Removed.
6944 (unset_command): Likewise.
6945 (insmod_command): Likewise.
6946 (rmmod_command): Likewise.
6947 (lsmod_command): Likewise.
6948 (grub_command_init): Likewise.
6949
6950 * normal/completion.c (iterate_command): Use cmd->prio to check for
6951 active command.
6952 (complete_arguments): Use grub_extcmd_t structure to find options.
6953 (grub_normal_do_completion): Change function grub_iterate_commands to
6954 grub_command_iterate.
6955
6956 * normal/execute.c (grub_script_execute_cmd): No need to parse
6957 argument here.
6958
6959 * normal/main.c (grub_dyncmd_dispatcher): New function.
6960 (read_command_list): Register unload commands as dyncmd.
6961 (grub_cmd_normal): Use new command interface, register rescue,
6962 unregister normal at entry, register normal, unregister rescue at exit.
6963
6964 * include/grub/list.h (grub_list_test_t): New type.
6965 (grub_list_iterate): Return int instead of void.
6966 (grub_list_insert): New function.
6967 (GRUB_AS_NAMED_LIST_P): New macro.
6968 (GRUB_AS_PRIO_LIST): Likewise.
6969 (GRUB_AS_PRIO_LIST_P): Likewise.
6970 (GRUB_PRIO_LIST_PRIO_MASK): New constant.
6971 (GRUB_PRIO_LIST_FLAG_ACTIVE): Likewise.
6972 (grub_prio_list): New structure.
6973 (grub_prio_list_insert): New function.
6974 (grub_prio_list_remove): New inline function.
6975
6976 * include/grub/normal.h: Remove <grub/arg.h>, add <grub/command.h>.
6977 (GRUB_COMMAND_FLAG_CMDLINE): Moved to command.h.
6978 (GRUB_COMMAND_FLAG_MENU): Likewise.
6979 (GRUB_COMMAND_FLAG_BOTH): Likewise.
6980 (GRUB_COMMAND_FLAG_TITLE): Likewise.
6981 (GRUB_COMMAND_FLAG_NO_ECHO): Likewise.
6982 (GRUB_COMMAND_FLAG_NO_ARG_PARSE): Removed.
6983 (GRUB_COMMAND_FLAG_NOT_LOADED): Likewise.
6984 (grub_command): Likewise.
6985 (grub_register_command): Likewise.
6986 (grub_command_find): Likewise.
6987 (grub_iterate_commands): Likewise.
6988 (grub_command_init): Likewise.
6989 (grub_arg_parse): Likewise.
6990 (grub_arg_show_help): Likewise.
6991
6992 * include/grub/rescue.h (grub_rescue_register_command): Removed.
6993 (grub_rescue_unregister_command): Likewise.
6994
6995 * include/grub/i386/bsd.h: Remove grub_rescue_cmd_freebsd,
6996 grub_rescue_cmd_openbsd, grub_rescue_cmd_netbsd,
6997 grub_rescue_cmd_freebsd_loadenv and grub_rescue_cmd_freebsd_module.
6998
6999 * include/grub/i386/efi/loader.h: Remove grub_rescue_cmd_linux and
7000 grub_rescue_cmd_initrd.
7001 * include/grub/i386/loader.h: Likewise.
7002 * include/grub/x86_64/loader.h: Likewise.
7003
7004 * include/grub/i386/pc/chainloader.h: Remove grub_chainloader_cmd.
7005
1f4147aa 70062009-03-21 Bean <bean123ch@gmail.com>
7007
7008 * util/hostdisk.c (read_device_map): Use grub_util_get_disk_size
7009 instead of stat in mingw environment.
7010
7011 * util/misc.c (grub_millisleep): Use Sleep in mingw environment.
7012
7013 * aclocal.m4 (grub_CHECK_LINK_DIR): New function.
7014
7015 * configure.ac: Use grub_CHECK_LINK_DIR to determine whether to use
7016 AC_CONFIG_LINKS.
7017
2156d5ba 70182009-03-21 Bean <bean123ch@gmail.com>
7019
7020 * fs/ext2.c (grub_ext2_mount): Change errno to GRUB_ERR_BAD_FS for
7021 out of range error.
7022
177b82ca 70232009-03-18 Michel Dänzer <michel@daenzer.net>
7024
7025 * fs/ext2.c (grub_ext2_read_block): Take endianness into account when
7026 checking inode flags for EXT4_EXTENTS_FLAG.
7027
14aad807 70282009-03-18 Robert Millan <rmh@aybabtu.com>
7029
7030 * loader/i386/linux.c: Include `<grub/video.h>' and
7031 `<grub/i386/pc/vbe.h>'..
7032 (grub_linux_setup_video): New function. Loosely based on the EFI one.
7033 (grub_linux32_boot): Attempt to configure video settings with
7034 grub_linux_setup_video().
7035 (grub_rescue_cmd_linux): Set noreturn=0 in grub_loader_set, in order
7036 to avoid grub_console_fini() which would step out of graphical mode
7037 unconditionally.
7038
8cf83a27 70392009-03-14 Robert Millan <rmh@aybabtu.com>
7040
7041 Fix build on powerpc.
7042 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Add `handler.h'.
7043
40164e75 70442009-03-12 Vladimir Serbinenko <phcoder@gmail.com>
7045
7046 * term/gfxterm.c (GRUB_MOD_FINI(term_gfxterm)): Correct name of
7047 background image command.
7048
c58bc32a 70492009-03-12 Colin D Bennett <colin@gibibit.com>
7050
7051 * term/gfxterm.c (draw_cursor): Ensure character is redrawn.
7052 (grub_gfxterm_putchar): Extract pairs of identical calls to
7053 draw_cursor out of conditional blocks.
7054
5415144a 70552009-03-11 Pavel Roskin <proski@gnu.org>
7056
7057 * fs/hfs.c (grub_hfs_strncasecmp): New function.
7058 (grub_hfs_cmp_catkeys): Use HFS specific string comparison.
7059
6394042e 70602009-03-11 Robert Millan <rmh@aybabtu.com>
7061
7062 * loader/i386/multiboot_elfxx.c
7063 (CONCAT(grub_multiboot_load_elf, XX)): Do not reject ET_DYN files.
7064
b7b50e5f 70652009-03-11 Felix Zielcke <fzielcke@z-51.de>
7066
7067 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add `kern/list.c' and
7068 `kern/handler.c'.
7069
1ca7fc96 70702009-03-11 Robert Millan <rmh@aybabtu.com>
7071
7072 * loader/i386/multiboot.c (code_size): New variable.
7073 (grub_multiboot): Define offsets by adding to `code_size' rather
7d074e3c 7074 than subtracting from `grub_multiboot_payload_size'. Provide
1ca7fc96 7075 4-byte alignment to MBI and others by increasing
7d074e3c 7076 `boot_loader_name_length' appropriately.
1ca7fc96 7077
7078 * loader/i386/multiboot_elfxx.c
7079 (CONCAT(grub_multiboot_load_elf, XX)): Initialize `code_size'.
7080
a83ea1d2 70812009-03-09 Felix Zielcke <fzielcke@z-51.de>
7082
7083 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove duplicated
7084 `fs/ext2.c'.
7085
aa9f3bff 70862009-03-08 Robert Millan <rmh@aybabtu.com>
7087
7088 Make loader/i386/linux.c usable on i386-pc again.
7089
7090 * kern/i386/pc/init.c (grub_machine_init): Disable addition of low
7091 memory to heap.
7092 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS] (allocate_pages): Remove
7093 `#error' stanza.
7094
d8b3b60e 70952009-03-07 Bean <bean123ch@gmail.com>
7096
7097 * loader/i386/efi/linux.c (grub_rescue_cmd_initrd): Fix a bug in initrd
7098 allocation.
7099
b362c9e9 71002009-03-06 Robert Millan <rmh@aybabtu.com>
7101
7102 Fix display issue on terminals with screen size other than 80x25
7103 (e.g. gfxterm with resolution higher than 640x480).
7104
7105 * normal/main.c (grub_normal_init_page): Display title text in a
7d074e3c 7106 position relative to the center of the terminal instead of relying
b362c9e9 7107 on a hardcoded offset.
7108
9304eef1 71092009-03-04 Robert Millan <rmh@aybabtu.com>
7110
7111 Filter /etc/grub.d/10_* so that only add-ons for native kernels are
7112 installed.
7113
7114 * Makefile.in (host_kernel): New variable.
7115 * conf/common.rmk (grub-mkconfig_SCRIPTS): Conditionalize all 10_*.in
7116 scripts instead of just the windows one.
7117 * configure.ac: Initialize and AC_SUBST `host_kernel'.
7118
eabc95fb 71192009-03-04 Felix Zielcke <fzielcke@z-51.de>
2ba60b62 7120
7121 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `kern/list.c' and
7122 `kern/handler.c'.
7123 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
7124 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
7125 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
7126 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7127 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7128 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7129
ceb1223c 71302009-03-04 Felix Zielcke <fzielcke@z-51.de>
7131
7132 * partmap/pc.c (pc_partition_map_iterate): Skip over invalid BSD partitions
7133 or if there's no space for the disk label and print the partition number on a
7134 invalid magic.
7135
4910684a 71362009-03-04 Felix Zielcke <fzielcke@z-51.de>
7137
7138 * util/misc.c: Include <time.h>.
7139 (grub_millisleep): New function.
7140
7e9ca17a 71412009-03-04 Bean <bean123ch@gmail.com>
7142
7143 * configure.ac: Only test -mcmodel=large option in x86_64-efi, also add
7144 another option -mno-red-zone.
7145
7146 * commands/handler.c: Change module description.
7147
7148 * kern/handler.c: Add missing space at the end of description line.
7149
7150 * kern/list.c: Likewise.
7151
f501677c 71522009-03-03 Robert Millan <rmh@aybabtu.com>
7153
7154 Move more components to the relocation area, and fix mbi pointer
7155 handling to use the destination rather than the origin (thanks to
7156 Vladimir Serbinenko for spotting).
7157
7158 * loader/i386/multiboot.c (mbi_dest): New variable.
7159 (grub_multiboot_boot): Use `mbi_dest' instead of `mbi'.
7160 (grub_multiboot): Put cmdline, boot_loader_name and mbi in the
7161 relocation area.
7162
9902d047 71632009-03-01 Bean <bean123ch@gmail.com>
7164
50fb7002 7165 * include/grub/efi/api.h (GRUB_EFI_MPS_TABLE_GUID): New constant.
9902d047 7166 (GRUB_EFI_ACPI_TABLE_GUID): Likewise.
7167 (GRUB_EFI_ACPI_20_TABLE_GUID): Likewise.
7168 (GRUB_EFI_SMBIOS_TABLE_GUID): Likewise.
7169
7170 * loader/i386/efi/linux.c (acpi_guid): New variable.
7171 (acpi_guid): Likewise.
7172 (EBDA_SEG_ADDR): New constant.
7173 (LOW_MEM_ADDR): Likewise.
7174 (FAKE_EBDA_SEG): Likewise.
7175 (fake_bios_data): New function.
7176 (grub_linux_boot): Call fake_bios_data.
7177
71b9f361 71782009-03-01 Bean <bean123ch@gmail.com>
7179
7180 * commands/terminal.c: Removed.
7181
7182 * commands/handler.c: New file.
7183
7184 * include/grub/list.h: Likewise.
7185
7186 * include/grub/handler.h: Likewise.
7187
7188 * kern/list.c: Likewise.
7189
7190 * kern/handler.c: Likewise.
7191
7192 * kern/term.h: Include header file <grub/handler.h>.
7193 (grub_term_input): Move next field to the beginning.
7194 (grub_term_output): Likewise.
7195 (grub_term_input_class): New variable.
7196 (grub_term_output_class): Likewise.
7197 (grub_term_register_input): Changed to inline function.
7198 (grub_term_register_output): Likewise.
7199 (grub_term_unregister_input): Likewise.
7200 (grub_term_unregister_output): Likewise.
7201 (grub_term_set_current_input): Likewise.
7202 (grub_term_set_current_output): Likewise.
7203 (grub_term_get_current_input): Likewise.
7204 (grub_term_get_current_output): Likewise.
7205 (grub_term_iterate_input): Removed.
7206 (grub_term_iterate_output): Likewise.
7207
7208 * kern/term.c (grub_term_list_input): Removed.
7209 (grub_term_list_output): Likewise.
7210 (grub_term_input_class): New variable.
7211 (grub_term_output_class): Likewise.
50fb7002 7212 (grub_cur_term_input): Change variable as macro.
71b9f361 7213 (grub_cur_term_output): Likewise.
7214 (grub_term_register_input): Removed.
7215 (grub_term_register_output): Likewise.
7216 (grub_term_unregister_input): Likewise.
7217 (grub_term_unregister_output): Likewise.
7218 (grub_term_set_current_input): Likewise.
7219 (grub_term_set_current_output): Likewise.
7220 (grub_term_iterate_input): Likewise.
7221 (grub_term_iterate_output): Likewise.
7222 (grub_term_get_current_input): Likewise.
7223 (grub_term_get_current_output): Likewise.
7224
7225 * util/grub-editenv.c: Include header file <grub/handler.h>.
7226 (grub_term_get_current_input): Removed.
7227 (grub_term_get_current_output): Likewise.
7228 (grub_term_input_class): New variable.
50fb7002 7229 (grub_term_output_class): Likewise.
71b9f361 7230
7231 * util/grub-fstest.c (grub_term_get_current_input): Removed.
7232 (grub_term_get_current_output): Likewise.
7233 (grub_term_input_class): New variable.
50fb7002 7234 (grub_term_output_class): Likewise.
71b9f361 7235
7236 * util/grub-probe.c (grub_term_get_current_input): Removed.
7237 (grub_term_get_current_output): Likewise.
7238 (grub_term_input_class): New variable.
50fb7002 7239 (grub_term_output_class): Likewise.
71b9f361 7240
7241 * util/i386/pc/grub-setup.c (grub_term_get_current_input): Removed.
7242 (grub_term_get_current_output): Likewise.
7243 (grub_term_input_class): New variable.
50fb7002 7244 (grub_term_output_class): Likewise.
71b9f361 7245
7246 * conf/common.rmk (pkglib_MODULES): Replace terminal with handler.
7247 (terminal_mod_SOURCES): Likewise.
7248 (terminal_mod_CFLAGS): Likewise.
7249 (terminal_mod_LDFLAGS): Likewise.
7250
7251 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace terminal.c with
7252 handler.c.
7253 (kernel_img_SOURCES): Add list.c and handler.c.
7254 (kernel_img_HEADERS): Add list.h and handler.h.
7255
7256 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
7257 handler.c.
7258 (kernel_mod_SOURCES): Add list.c and handler.c.
7259 (kernel_mod_HEADERS): Add list.h and handler.h.
7260
7261 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Replace terminal.c with
7262 handler.c.
7263 (kernel_elf_SOURCES): Add list.c and handler.c.
7264 (kernel_elf_HEADERS): Add list.h and handler.h.
7265
7266 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
7267 handler.c.
7268 (kernel_elf_SOURCES): Add list.c and handler.c.
7269 (kernel_elf_HEADERS): Add list.h and handler.h.
7270
7271 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
7272 handler.c.
7273 (kernel_mod_SOURCES): Add list.c and handler.c.
7274 (kernel_mod_HEADERS): Add list.h and handler.h.
7275
7276 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
7277 handler.c.
7278 (kernel_elf_SOURCES): Add list.c and handler.c.
7279 (kernel_elf_HEADERS): Add list.h and handler.h.
7280
8a31787f 72812009-02-27 Robert Millan <rmh@aybabtu.com>
7282
7283 Factorize elf32 / elf64 code in Multiboot loader. This will
7284 prevent it from getting out of sync again.
7285
7286 * loader/i386/multiboot.c (grub_multiboot_is_elf32,
7287 grub_multiboot_load_elf32, grub_multiboot_is_elf64,
7288 grub_multiboot_load_elf64): Move from here ...
7289 * loader/i386/multiboot_elfxx.c (grub_multiboot_is_elf,
7290 grub_multiboot_load_elf): ... to here (new file).
7291
51cd3dfc 72922009-02-27 Robert Millan <rmh@aybabtu.com>
7293
7294 * util/grub.d/10_linux.in: Rename "single-user mode" to
7295 "recovery mode".
7296
6e8c9c3a 72972009-02-27 Vladimir Serbinenko <phcoder@gmail.com>
7298
7299 Don't leak in SCSI code.
7300 * disk/scsi.c (grub_scsi_close): free `scsi'.
7301
4b6bf4f9 73022009-02-27 Robert Millan <rmh@aybabtu.com>
7303
7304 * loader/i386/pc/multiboot.c: Move from here ...
7305 * loader/i386/multiboot.c: ... to here. Update all users.
7306
b9413424 73072009-02-27 Robert Millan <rmh@aybabtu.com>
7308
7309 Patch from Alexandre Bique <bique.alexandre@gmail.com>
7310 * util/i386/pc/grub-setup.c (setup): Fix directory path.
7311
50fb7002 73122009-02-27 Krzysztof Smiechowicz <deadwood@wp.pl>
34519c3f 7313
7314 * fs/sfs.c (grub_sfs_read_extent): Correction to traversing extent
7315 b-tree.
7316
8cc50345 73172009-02-27 Robert Millan <rmh@aybabtu.com>
7318
7319 * kern/misc.c (grub_strtoull): Fix bug (it mistakenly parsed the
7320 `0x' qualifier as 0 when base is specified as parameter).
7321
6e09b8b7 73222009-02-24 Bean <bean123ch@gmail.com>
7323
7324 * configure.ac: Check for -mcmodel=large in x86_64 target.
7325
7326 * include/grub/efi/api.h (efi_call_10): New macro.
7327 (efi_wrap_10): New function.
7328
7329 * include/grub/efi/pe32.h (GRUB_PE32_REL_BASE_HIGH): New macro.
7330 (GRUB_PE32_REL_BASED_HIGH): Likewise.
7331 (GRUB_PE32_REL_BASED_LOW): Likewise.
7332 (GRUB_PE32_REL_BASED_HIGHLOW): Likewise.
7333 (GRUB_PE32_REL_BASED_HIGHADJ): Likewise.
7334 (GRUB_PE32_REL_BASED_MIPS_JMPADDR): Likewise.
7335 (GRUB_PE32_REL_BASED_SECTION): Likewise.
7336 (GRUB_PE32_REL_BASED_REL): Likewise.
7337 (GRUB_PE32_REL_BASED_IA64_IMM64): Likewise.
7338 (GRUB_PE32_REL_BASED_DIR64): Likewise.
7339 (GRUB_PE32_REL_BASED_HIGH3ADJ): Likewise.
7340
7341 * kern/x86_64/dl.c (grub_arch_dl_relocate_symbols): Fixed relocation
7342 issue.
7343
7344 * kern/x86_64/efi/callwrap.S (efi_wrap_6): Bug fix.
7345 (efi_wrap_10): New function.
7346
7347 * kern/x86_64/efi/startup.S (codestart): Use relative addressing.
7348
7349 * loader/efi/appleloader.c (devpath_5): Add support for late 2008
7350 MB/MBP model (NV chipset).
7351 (devdata_devs): Add devpath_5 to the list.
7352
7353 * load/i386/efi/linux.c (video_base): Remove variable.
7354 (RGB_MASK): New macro.
7355 (RGB_MAGIC): Likewise.
7356 (LINE_MIN): Likewise.
7357 (LINE_MAX): Likewise.
7358 (FBTEST_STEP): Likewise.
7359 (FBTEST_COUNT): Likewise.
7360 (fb_list): New variable.
7361 (grub_find_video_card): Remove function.
7362 (find_framebuf): New function.
7363 (grub_linux_setup_video): Use find_framebuf to get frame buffer and
7364 line length.
7365
7366 * util/i386/efi/grub-mkimage.c (grub_reloc_section): Fix relocation
7367 problem for x86_64.
7368
74b21bee 73692009-02-22 Vesa Jääskeläinen <chaac@nic.fi>
7370
7371 Patch #25624 by Kevin Lacquement <kevin@lacqui>.
7372
7373 * util/grub-mkconfig.in: Use ${grub_mkdevicemap} instead of hard
7374 coding tool name.
7375
a455f472 73762009-02-22 Robert Millan <rmh@aybabtu.com>
7377
7378 * include/multiboot.h (MULTIBOOT_INFO_ALIGN): New macro.
7379 * loader/i386/pc/multiboot.c (grub_multiboot): Include the MBI
7380 in our relocation, instead of using it directly from heap. Also
7381 use `MULTIBOOT_INFO_ALIGN' to ensure it is aligned.
7382
6374daf3 73832009-02-21 Robert Millan <rmh@aybabtu.com>
7384
7385 Implement USB keyboard support (based on patch by Marco Gerards)
7386
7387 * conf/i386-pc.rmk (pkglib_MODULES): Add `usb_keyboard.mod'.
7388 (usb_keyboard_mod_SOURCES, usb_keyboard_mod_CFLAGS)
7389 (usb_keyboard_mod_LDFLAGS): New variables.
7390
7391 * term/usb_keyboard.c: New file.
7392
8fa4ea70 73932009-02-14 Vladimir Serbinenko <phcoder@gmail.com>
7394
7395 Corrected wrong declaration
7396
7397 * kern/disk.c: corrected declaration of grub_disk_ata_pass_through.
7398
353976ac 73992009-02-14 Christian Franke <franke@computer.org>
7400
7401 * commands/lspci.c (grub_pci_classes): Add `SATA Controller'.
7402 (grub_lspci_iter): Print class code and programming interface byte.
7403
6aa1169b 74042009-02-14 Christian Franke <franke@computer.org>
7405
7406 * gendistlist.sh: Ignore `.svn' directories.
7407
265372ca 74082009-02-14 Felix Zielcke <fzielcke@z-51.de>
7409
7410 * fs/fat.c: Add 2009 to Copyright line.
7411
9ff516f3 74122009-02-14 Christian Franke <franke@computer.org>
7413
7414 * commands/hdparm.c: New file. Provides `hdparm' command
7415 which sends ATA commands via grub_disk_ata_pass_through ().
7416
7417 * conf/i386-pc.rmk: Add ata_pthru.mod and hdparm.mod.
7418
7419 * disk/ata.c: Include <grub/ata.h>. Move <grub/misc.h>
7420 and <grub/cpu/io.h> to include/grub/ata.h.
7421 (enum grub_ata_addressing_t): Move to include/grub/ata.h.
7422 (GRUB_CDROM_SECTOR_SIZE): Remove.
7423 (GRUB_ATA_*): Move to include/grub/ata.h.
7424 (GRUB_ATAPI_*): Likewise.
7425 (enum grub_ata_commands): Likewise.
7426 (enum grub_ata_timeout_milliseconds): Likewise.
7427 (struct grub_ata_device): Likewise.
7428 (grub_ata_regset): Likewise.
7429 (grub_ata_regget): Likewise.
7430 (grub_ata_regset2): Likewise.
7431 (grub_ata_regget2): Likewise.
7432 (grub_ata_check_ready): Likewise.
7433 (grub_ata_wait_not_busy): Remove static, exported in
7434 include/grub/ata.h.
7435 (grub_ata_wait_drq): Likewise.
7436 (grub_ata_pio_read): Likewise.
7437
7438 * disk/ata_pthru.c: New file. Provides grub_ata_pass_through ()
7439 function for hdparm.mod.
7440
7441 * include/grub/ata.h: New file, contains declarations from
7442 disk/ata.c.
7443 (enum grub_ata_commands): Add new commands for commands/hdparm.c.
7444
7445 * include/grub/disk.h (grub_disk_ata_pass_through_parms): New struct.
7446 (grub_disk_ata_pass_through): New exported variable.
7447
7448 * kern/disk.c (grub_disk_ata_pass_through): New variable.
7449
772e23da 74502009-02-13 Colin D Bennett <colin@gibibit.com>
7451
7452 Support multiple fallback entries, and provide an API to support
7453 executing default+fallback menu entries. Renamed the `terminal' menu
7454 viewer to `text'.
7455
7456 * include/grub/normal.h (grub_normal_text_menu_viewer): New global
7457 variable declaration.
7458 (grub_menu_execute_callback): New structure declaration.
7459 (grub_menu_execute_callback_t): New typedef.
7460 (grub_menu_execute_with_fallback): New function declaration.
7461 (grub_menu_get_entry): Likewise.
7462 (grub_menu_get_timeout): Likewise.
7463 (grub_menu_set_timeout): Likewise.
7464
7465 * normal/main.c (GRUB_MOD_INIT(normal)): Refer to new variable name.
7466
7467 * normal/menu.c (grub_wait_after_message): Moved to
7468 `normal/menu_text.c'.
7469 (draw_border): Likewise.
7470 (print_message): Likewise.
7471 (print_entry): Likewise.
7472 (print_entries): Likewise.
7473 (grub_menu_init_page): Likewise.
7474 (get_entry_number): Likewise.
7475 (print_timeout): Likewise.
7476 (run_menu): Likewise.
7477 (grub_menu_execute_entry): Likewise.
7478 (show_text_menu): Likewise.
7479 (get_and_remove_first_entry_number): New function.
7480 (grub_menu_execute_with_fallback): Likewise.
7481 (get_entry): Renamed to ...
7482 (grub_menu_get_entry): .. this and made it global.
7483 (get_timeout): Renamed to ...
7484 (grub_menu_get_timeout): ... this and made it global.
7485 (set_timeout): Renamed to ...
7486 (grub_menu_set_timeout): ... this and made it global.
7487 (grub_normal_terminal_menu_viewer): Renamed to ...
7488 (grub_normal_text_menu_viewer): ... this.
7489
7490 * normal/menu_text.c: New file. Extracted text-menu-specific code
7491 from normal/menu.c.
7492
7493 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add `normal/menu_text.c'.
7494 (normal_mod_SOURCES): Likewise.
7495
7496 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
7497 (normal_mod_SOURCES): Likewise.
7498
7499 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7500 (normal_mod_SOURCES): Likewise.
7501
7502 * conf/i386-pc.rmk, (grub_emu_SOURCES): Likewise.
7503 (normal_mod_SOURCES): Likewise.
7504
7505 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7506 (normal_mod_SOURCES): Likewise.
7507
7508 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7509 (normal_mod_SOURCES): Likewise.
7510
7511 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
7512 (normal_mod_SOURCES): Likewise.
7513
16ac430e 75142009-02-11 Robert Millan <rmh@aybabtu.com>
7515
7516 * util/grub.d/00_header.in: Update old reference to `font' command.
7517
06ff20fc 75182009-02-10 Felix Zielcke <fzielcke@z-51.de>
7519
7520 * fs/fat.c (grub_fat_mount): Fix wrong comparison.
7521
7522 Based on patch from Javier Martín.
7523
96da9407 75242009-02-09 Felix Zielcke <fzielcke@z-51.de>
7525
7526 * conf/common.rmk (grub_probe_SOURCES): Move fs/ext2.c before fs/fat.c
50fb7002 7527 to avoid false positives with FAT.
96da9407 7528 (grub_fstest_SOURCES): Likewise.
7529 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
7530 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
7531 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7532 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
7533 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7534 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7535
6dca6fe4 75362009-02-09 Felix Zielcke <fzielcke@z-51.de>
7537
06ff20fc 7538 * fs/fat.c (grub_fat_mount): Try to avoid false positives by checking
6dca6fe4 7539 bpb.version_specific.fat12_or_fat16.fstype and
7540 bpb.version_specific.fat32.fstype.
7541
2550c62f 75422009-02-08 Robert Millan <rmh@aybabtu.com>
7543
be110b30 7544 * fs/tar.c: Replace "fs/cpio.c" with "cpio.c".
2550c62f 7545
56978920 75462009-02-08 Robert Millan <rmh@aybabtu.com>
7547
7548 * Makefile.in (host_os, host_cpu): New variables.
7549 (target_os): Remove. Update all users.
7550
d64399b5 75512009-02-08 Marco Gerards <marco@gnu.org>
7552
7553 * Makefile.in (enable_grub_emu_usb): New variable.
7554 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/scsi.c'.
7555 (grub_emu_SOURCES) [grub_emu_SOURCES]: Add `disk/usbms.c',
7556 `util/usb.c', `bus/usb/usb.c' and `commands/usbtest.c'.
7557 (grub_emu_LDFLAGS): Add `$(LIBUSB)'.
7558 (pkglib_MODULES): Add `usb.mod', `uhci.mod', `ohci.mod',
7559 `usbtest.mod' and `usbms.mod'.
7560 (usb_mod_SOURCES, usb_mod_CFLAGS, usb_mod_LDFLAGS)
7561 (usbtest_mod_SOURCES, usbtest_mod_CFLAGS, usbtest_mod_LDFLAGS)
7562 (uhci_mod_SOURCES, uhci_mod_CFLAGS, uhci_mod_LDFLAGS,
7563 (ohci_mod_SOURCES, ohci_mod_CFLAGS, ohci_mod_LDFLAGS)
7564 (usbms_mod_SOURCES, usbms_mod_CFLAGS, usbms_mod_LDFLAGS): New
7565 variables.
7566
7567 * disk/usbms.c: New file.
7568
7569 * include/grub/usb.h: Likewise.
7570
7571 * include/grub/usbtrans.h: Likewise.
7572
7573 * include/grub/usbdesc.h: Likewise.
7574
7575 * bus/usb/usbtrans.c: Likewise.
7576
7577 * bus/usb/ohci.c: Likewise.
7578
7579 * bus/usb/uhci.c: Likewise.
7580
7581 * bus/usb/usbhub.c: Likewise.
7582
7583 * bus/usb/usb.c: Likewise.
7584
7585 * commands/usbtest.c: Likewise.
7586
7587 * util/usb.c: Likewise.
50fb7002 7588
d64399b5 7589 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_IO'.
7590
7591 * configure.ac: Test for libusb presence.
50fb7002 7592
d64399b5 7593 * util/grub-emu.c (main) [HAVE_LIBUSB_H]: Call `grub_libusb_init'.
7594
2b40d6bb 75952009-02-08 Vesa Jääskeläinen <chaac@nic.fi>
7596
7597 * kern/mm.c: Add more comments.
7598
73a4ce81 75992009-02-08 Robert Millan <rmh@aybabtu.com>
7600
7601 Patch from Javier Martín.
7602 * fs/ext2.c (EXT2_DRIVER_SUPPORTED_INCOMPAT): Add
7603 `EXT4_FEATURE_INCOMPAT_FLEX_BG'.
7604
f821ce59 76052009-02-08 Robert Millan <rmh@aybabtu.com>
7606
7607 * fs/cpio.c: Split tar functionality to ...
7608 * fs/tar.c: ... here (new file). Update all users.
7609
aebfc4b0 76102009-02-07 Robert Millan <rmh@aybabtu.com>
7611
7612 * fs/ext2.c (grub_ext2_mount): Avoid mounting filesystems with
7613 backward-incompatible features.
7614
7615 Based on patch from Javier Martín, with some adjustments.
7616
50fb7002 76172009-02-07 Michael Scherer <misc@mandriva.org>
cea15bca 7618
7619 * fs/hfs.c (grub_hfsplus_iterate_dir): Treat hfs+ as case insensitive.
7620
0bb5115e 76212009-02-07 Robert Millan <rmh@aybabtu.com>
7622
7623 * conf/common.rmk (grub_probe_SOURCES, grub_fstest_SOURCES): Move
7624 position of `disk/lvm.c' to ensure grub_init_all() always picks it
7625 after the RAID stuff.
7626
38a0f8e7 76272009-02-05 Vesa Jääskeläinen <chaac@nic.fi>
7628
50fb7002 7629 Fixes problem when running vbetest command as reported by
38a0f8e7 7630 Vladimir Serbinenko <phcoder@gmail.com>.
7631
7632 * (grub_vbe_set_video_mode): Fixed problem with text modes.
7633
3143cc1c 76342009-02-04 Felix Zielcke <fzielcke@z-51.de>
7635
7636 util/getroot.c (grub_util_get_grub_dev): Add support for /dev/mdNpN and
7637 /dev/md/NpN style mdraid devices.
7638
9cba6fce 76392009-02-03 Felix Zielcke <fzielcke@z-51.de>
7640
7641 * util/unifont2pff.rb: Remove.
7642
e507a2c1 76432009-02-03 Felix Zielcke <fzielcke@z-51.de>
7644
7645 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add a missing trailing
7646 `#'.
7647
d2c2b4cd 76482009-02-03 Felix Zielcke <fzielcke@z-51.de>
7649
7650 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/menu_viewer.c'.
7651 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
7652 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
7653 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
7654 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7655 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7656 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7657
b4315fb0 76582009-02-02 Christian Franke <franke@computer.org>
7659
7660 * lib/hexdump.c (hexdump): Print at most 3 lines if data is identical.
7661
de3aa260 76622009-02-01 Felix Zielcke <fzielcke@z-51.de>
7663
7c3ff286 7664 * INSTALL: Note that we now require at least autoconf 2.59 and
7665 that LZO is optional.
de3aa260 7666
825a182b 76672009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
7668
7669 Base on patch on bug #24154 created by Tomas Tintera
7670 <trosos@seznam.cz>.
7671
7672 * video/i386/pc/vbe.c (grub_video_vbe_scroll): Fix downward scrolling.
7673
a69ef770 76742009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
7675
7c3ff286 7676 Based on patch on bug #25318 created by Bernhard Rosenkraenzer
a69ef770 7677 <bero@arklinux.org>.
7678
7679 * normal/parser.y (script_init): Add missing semicolon.
7680
6fa42fa6 76812009-01-31 Colin D Bennett <colin@gibibit.com>
7682
7c3ff286 7683 * normal/main.c: Add include to grub/menu_viewer.h.
6fa42fa6 7684 (free_menu_entry_classes): Added.
7685 (grub_normal_menu_addentry): Added class property handling.
7686 (grub_normal_execute): Changed to use new menu viewer for menu viewing.
7687 (GRUB_MOD_INIT(normal)): Added register for text based menu viewer.
7688
7689 * normal/menu_viewer.c: New file.
7690
7691 * normal/menu.c (run_menu_entry): Renamed to ...
7692 (grub_menu_execute_entry): ... this and made it as global.
7693 (grub_menu_run): Renamed to ...
7694 (show_text_menu): ... this and made it local.
7695 (show_text_menu): Adapt to new function names.
7696 (grub_normal_terminal_menu_viewer): New global variable.
7697
7698 * include/grub/menu.h: New file.
7699
7700 * include/grub/menu_viewer.h: New file.
7701
7702 * include/grub/normal.h: Added include to grub/menu.h.
7703 (grub_menu_entry): Moved to include/grub/menu.h.
7704 (grub_menu_entry_t): Likewise.
7705 (grub_menu): Likewise.
7706 (grub_menu_t): Likewise.
7707 (grub_normal_terminal_menu_viewer): Added.
7708 (grub_menu_execute_entry): Likewise.
7709 (grub_menu_run): Removed.
7710
7711 * DISTLIST: Added include/grub/menu.h.
7712 Added include/grub/menu_viewer.h.
7713 Added normal/menu_viewer.c.
7714
77152009-01-31 Vesa Jääskeläinen <chaac@nic.fi>
7716
7717 * normal/execute.c (grub_script_execute_menuentry): Changed to use
7718 arglist for menutitle arguments.
7719
7720 * normal/main.c (grub_normal_menu_addentry): Likewise.
7721
7722 * normal/parser.y (menuentry): Likewise.
7723
7724 * normal/script.c (grub_script_create_cmdmenu): Likewise.
7725
7726 * include/grub/script.h (grub_script_cmd_menuentry): Likewise.
7727 (grub_script_create_cmdmenu): Likewise.
7728
7729 * include/grub/normal.h (grub_normal_menu_addentry): Likewise.
7730
7731 * conf/i386-pc.rmk (normal_mod_SOURCES): Adapt Colin D Bennett's
7732 changes.
7733
7734 * conf/x86_64-efi.rmk (normal_mod_SOURCES): Likewise.
7735
7736 * conf/i386-coreboot.rmk (normal_mod_SOURCES): Likewise.
7737
7738 * conf/i386-efi.rmk (normal_mod_SOURCES): Likewise.
7739
7740 * conf/i386-ieee1275.rmk (normal_mod_SOURCES): Likewise.
7741
7742 * conf/powerpc-ieee1275.rmk (normal_mod_SOURCES): Likewise.
7743
7744 * conf/sparc64-ieee1275.rmk (normal_mod_SOURCES): Likewise.
7745
56192c23 77462009-01-30 Christian Franke <franke@computer.org>
7747
7748 * normal/arg.c (grub_arg_show_help): Add indentation if '\n' appears
7749 in option help text.
7750
d72521b3 77512009-01-27 Pavel Roskin <proski@gnu.org>
7752
7753 * disk/fs_uuid.c (search_fs_uuid): Ignore case of the UUID.
7754
994b5e84 77552009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
7756
7757 * commands/lsmmap.c: Add include to grub/machine/memory.h.
7758
7759 * fs/i386/pc/pxe.c (grub_pxefs_open): Fix sign problem.
7760
7761 * term/i386/pc/at_keyboard.c (GRUB_MOD_FINI(at_keyboard)): Use proper
7762 unregister function.
7763
6a7eab2c 77642009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
7765
7766 * disk/scsi.c (grub_scsi_read): Fix sign problem.
7767
7768 * term/i386/pc/vga_text.c (grub_vga_text_init_fini). Fix declaration.
7769
7770 * util/grub-mkfont.c (usage): Fix typo.
7771
7772 * util/elf/grub-mkimage.c (load_modules): Fix warning.
7773
1806b56e 77742009-01-26 Daniel Mierswa <impulze@impulze.org>
7775
3fb18f09 7776 * fs/fat.c (grub_fat_uuid): Fix shift of the first two bytes.
7777
336e1fb9 7778 * commands/search.c (search_fs_uuid): Ignore case of the UUID.
7779
1806b56e 7780 * kern/misc.c (grub_strcasecmp): New function.
7781 (grub_strcasecmp): Use grub_size_t instead of int for length.
7782 Fix return value.
7783 * include/grub/misc.h: Update function prototypes.
7784
580b2a0f 77852009-01-26 Robert Millan <rmh@aybabtu.com>
7786
7787 * configure.ac: Fix cross-compilation check.
ef257b36 7788
d31c24f1 77892009-01-22 Christian Franke <franke@computer.org>
7790
7791 * kern/misc.c (grub_vsprintf): Fix size and termination of `format2'
7792 (precision) digit string. Allow `.format2' without `format1' (width).
7793 Limit input chars for `%s' output to `format2' if specified. This is
7794 compatible with standard printf ().
7795
3138b44c 77962009-01-22 Christian Franke <franke@computer.org>
7797
7798 * disk/ata.c (grub_ata_wait_status): Replace by ...
7799 (grub_ata_wait_not_busy): ... this function. Checks only BSY bit,
7800 other status bits may be invalid while BSY is asserted.
7801 (grub_ata_check_ready): New function.
7802 (grub_ata_cmd): Removed.
7803 (grub_ata_wait_drq): New function.
7804 (grub_ata_strncpy): Remove inline.
7805 (grub_ata_pio_read): Reduce to actual block transfer. BSY wait
7806 and error check now done by grub_ata_wait_drq ().
7807 (grub_ata_pio_write): Likewise.
7808 (grub_atapi_identify): Set DEV before check for !BSY. Use
7809 grub_ata_wait_drq () to wait for data.
7810 (grub_ata_device_initialize): Add status register check to
7811 detect missing SATA slave devices. Add debug messages.
7812 (grub_atapi_wait_drq): Use grub_ata_wait_not_busy ().
7813 (grub_atapi_packet): Set DEV before check for !BSY. Replace
7814 transfer loop by grub_ata_pio_write ().
7815 (grub_ata_identify): Set DEV before check for !BSY. Use
7816 grub_ata_wait_drq () to wait for data.
ef257b36 7817 (grub_ata_setaddress): Set DEV before check for !BSY.
3138b44c 7818 (grub_ata_readwrite): Remove duplicate code, handle batch/rest and
7819 read/write in one loop. Fix invalid command on write. Fix incomplete
7820 command on (size % batch) == 0. Add missing error check after write of
7821 last block. Add debug messages.
7822 (grub_atapi_read): Replace transfer loop by grub_ata_pio_read ().
7823
59a64ef6 78242009-01-19 Christian Franke <franke@computer.org>
7825
7826 * disk/ata.c (GRUB_ATAPI_REG_*): New defines.
7827 (GRUB_ATAPI_IREASON_*): Likewise.
7828 (grub_ata_pio_write): Fix timeout error return.
7829 (grub_atapi_identify): Add grub_ata_wait () after cmd.
7830 (grub_atapi_wait_drq): New function.
7831 (grub_atapi_packet): New parameter `size'.
7832 Use grub_atapi_wait_drq () and direct write instead of
7833 grub_ata_pio_write ().
7834 (grub_atapi_read): Replace grub_ata_pio_read () by a loop which
7835 reads the number of bytes requested by the device for each DRQ
7836 assertion.
7837 (grub_atapi_write): Remove old implementation, return not
7838 implemented instead.
7839
1cfe20b3 78402009-01-19 Christian Franke <franke@computer.org>
7841
7842 * disk/scsi.c (grub_scsi_read10): Use scsi->blocksize instead
7843 of 512 to calculate data size.
7844 (grub_scsi_read12): Likewise.
7845 (grub_scsi_write10): Likewise.
7846 (grub_scsi_write12): Likewise.
7847 (grub_scsi_read): Adjust size according to blocksize.
7848 Add checks for invalid blocksize and unaligned transfer.
7849
bee5fe5d 78502009-01-19 Vesa Jääskeläinen <chaac@nic.fi>
7851
7852 * font/font.c (grub_font_loader_init): Re-position unknown glyph.
7853
ef257b36 7854 * term/gfxterm.c (write_char): Fix background rendering for wide
bee5fe5d 7855 width glyphs.
7856
3e643f8c 78572009-01-19 Robert Millan <rmh@aybabtu.com>
7858
7859 * config.guess: Update to latest version from config git.
7860 * config.sub: Likewise.
7861
4fa80998 78622009-01-17 Felix Zielcke <fzielcke@z-51.de>
7863
7864 * Makefile.in: Change font compilation to use new grub-mkfont instead
7865 of java version.
7866
7867 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: Remove.
7868 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
7869 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
7870 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
7871 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
7872 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
7873 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
7874 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
7875 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
7876
7086085b 78772009-01-16 Christian Franke <franke@computer.org>
7878
7879 * disk/ata.c (enum grub_ata_commands): Remove EXEC_DEV_DIAGNOSTICS.
7880 (enum grub_ata_timeout_milliseconds): New enum.
7881 (grub_ata_wait_status): Add parameter milliseconds.
7882 (grub_ata_cmd): Remove variable `err'. Remove wait for !DRQ to allow
7883 recovery from timed-out commands.
7884 (grub_ata_pio_read): Add parameter milliseconds. Fix error return,
7885 return grub_errno instead of REG_ERROR.
7886 (grub_ata_pio_write): Add parameter milliseconds.
7887 (grub_atapi_identify): Fix size of ATAPI IDENTIFY sector.
7888 Pass milliseconds to grub_ata_wait_status () and
7889 grub_ata_pio_read ().
7890 (grub_atapi_packet): Pass milliseconds to grub_ata_pio_write ().
7891 (grub_ata_identify): Remove variable `ataerr'. Pass milliseconds to
7892 grub_ata_wait_status (). Fix IDENTIFY timeout check.
7893 (grub_ata_device_initialize): Remove EXECUTE DEVICE DIAGNOSTICS.
7894 It is not suitable for device detection, because DEV bit is ignored,
7895 the command may run too long, and not all devices set the signature
7896 properly.
7897 (grub_ata_pciinit): Clear grub_errno before grub_ata_device_initialize ().
7898 (grub_ata_setaddress): Pass milliseconds to grub_ata_wait_status ().
7899 Fix device selection, DEV bit must be set first to address the registers
7900 of the correct device.
7901 (grub_ata_readwrite): Pass milliseconds to grub_ata_wait_status () and
7902 grub_ata_pio_read/write ().
7903 (grub_atapi_read): Pass milliseconds to grub_ata_pio_read ().
7904 (grub_atapi_write): Pass milliseconds to grub_ata_pio_write ().
7905
4a412913 79062009-01-13 Carles Pina i Estany <carles@pina.cat>
7907
7908 * util/grub-editenv.c (main): Use fseeko(), not fseek().
7909
7795c55e 79102009-01-13 Bean <bean123ch@gmail.com>
d913988c 7911
7912 * util/grub-mkfont.c (write_font): forget to remove some debug code.
7913
7795c55e 79142009-01-13 Bean <bean123ch@gmail.com>
e52db1f7 7915
7916 * Makefile.in: (enable_grub_mkfont): New variable.
7917 (freetype_cflags): Likewise.
7918 (freetype_libs): Likewise.
7919
7920 * common.rmk (bin_UTILITIES): Add `grub-mkfont' if requested.
7921 (grub_mkfont_SOURCES): New variable.
7922 (grub_mkfont_CFLAGS): Likewise.
7923 (grub_mkfont_LDFLAGS): Likewise.
7924
7925 * configure.ac (--enable-grub-mkfont): New option. Check for freetype2
7926 library if `--enable-grub-mkfont' is requested.
7927 (enable_grub_mkfont): New variable.
7928 (freetype_cflags): Likewise.
7929 (freetype_libs): Likewise.
7930
7931 * util/grub-mkfont.c: New file.
7932
093af1fe 79332009-01-12 Christian Franke <franke@computer.org>
7934
7935 * disk/ata.c (grub_ata_pciinit): Fix bit numbers of compatibility
7936 mode check. Fix setting of compat_use[].
7937
f36cc108 79382009-01-10 Robert Millan <rmh@aybabtu.com>
7939
7940 Update a few copyright years which we forgot to do in 2008 (only for
7941 files whose changes made in 2008 were copyright-significant)
7942
7943 * Makefile.in: Add 2008 to Copyright line.
7944 * disk/ieee1275/ofdisk.c: Likewise.
7945 * disk/efi/efidisk.c: Likewise.
7946 * kern/dl.c: Likewise.
7947 * kern/sparc64/ieee1275/init.c: Likewise.
7948 * kern/mm.c: Likewise.
7949 * kern/efi/mm.c: Likewise.
7950 * boot/i386/pc/boot.S: Likewise.
7951 * genfslist.sh: Likewise.
7952 * fs/iso9660.c: Likewise.
7953 * fs/hfs.c: Likewise.
7954 * fs/jfs.c: Likewise.
7955 * fs/minix.c: Likewise.
7956 * fs/ufs.c: Likewise.
7957 * gensymlist.sh.in: Likewise.
7958 * genkernsyms.sh.in: Likewise.
7959 * include/grub/misc.h: Likewise.
7960 * include/grub/types.h: Likewise.
7961 * include/grub/symbol.h: Likewise.
7962 * include/grub/elf.h: Likewise.
7963 * include/grub/kernel.h: Likewise.
7964 * include/grub/disk.h: Likewise.
7965 * include/grub/dl.h: Likewise.
7966 * include/grub/i386/linux.h: Likewise.
7967 * include/grub/i386/pc/biosdisk.h: Likewise.
7968 * include/grub/efi/api.h: Likewise.
7969 * include/grub/efi/pe32.h: Likewise.
7970 * include/grub/util/misc.h: Likewise.
7971 * normal/execute.c: Likewise.
7972 * normal/arg.c: Likewise.
7973 * normal/completion.c: Likewise.
7974 * normal/lexer.c: Likewise.
7975 * normal/parser.y: Likewise.
7976 * normal/misc.c: Likewise.
7977 * commands/i386/pc/vbeinfo.c: Likewise.
7978 * commands/hexdump.c: Likewise.
7979 * commands/terminal.c: Likewise.
7980 * commands/ls.c: Likewise.
7981 * commands/help.c: Likewise.
7982 * partmap/pc.c: Likewise.
7983 * loader/efi/chainloader.c: Likewise.
7984 * loader/multiboot_loader.c: Likewise.
7985 * loader/i386/pc/multiboot2.c: Likewise.
7986 * term/efi/console.c: Likewise.
7987 * term/i386/pc/serial.c: Likewise.
7988 * util/lvm.c: Likewise.
7989 * util/console.c: Likewise.
7990 * util/i386/efi/grub-mkimage.c: Likewise.
7991 * util/raid.c: Likewise.
7992
7f02114b 79932009-01-06 Vesa Jääskeläinen <chaac@nic.fi>
7994
7995 * commands/videotest.c: Removed include to grub/machine/memory.h.
7996
7997 * conf/i386-pc.rmk (pkglib_MODULES): Removed video.mod, gfxterm.mod,
7998 videotest.mod, bitmap.mod, tga.mod, jpeg.mod, png.mod.
7999 (video_mod_SOURCES): Removed.
8000 (video_mod_CFLAGS): Likewise.
8001 (video_mod_LDFLAGS): Likewise.
8002 (gfxterm_mod_SOURCES): Likewise.
8003 (gfxterm_mod_CFLAGS): Likewise.
8004 (gfxterm_mod_LDFLAGS): Likewise.
8005 (videotest_mod_SOURCES): Likewise.
8006 (videotest_mod_CFLAGS): Likewise.
8007 (videotest_mod_LDFLAGS): Likewise.
8008 (bitmap_mod_SOURCES): Likewise.
8009 (bitmap_mod_CFLAGS): Likewise.
8010 (bitmap_mod_LDFLAGS): Likewise.
8011 (tga_mod_SOURCES): Likewise.
8012 (tga_mod_CFLAGS): Likewise.
8013 (tga_mod_LDFLAGS): Likewise.
8014 (jpeg_mod_SOURCES): Likewise.
8015 (jpeg_mod_CFLAGS): Likewise.
8016 (jpeg_mod_LDFLAGS): Likewise.
8017 (png_mod_SOURCES): Likewise.
8018 (png_mod_CFLAGS): Likewise.
8019 (png_mod_LDFLAGS): Likewise.
8020
8021 * conf/common.rmk (pkglib_MODULES): Added video.mod, videotest.mod,
8022 bitmap.mod, tga.mod, jpeg.mod, png.mod, font.mod, gfxterm.mod
8023 (video_mod_SOURCES): Added.
8024 (video_mod_CFLAGS): Likewise.
8025 (video_mod_LDFLAGS): Likewise.
8026 (videotest_mod_SOURCES): Likewise.
8027 (videotest_mod_CFLAGS): Likewise.
8028 (videotest_mod_LDFLAGS): Likewise.
8029 (bitmap_mod_SOURCES): Likewise.
8030 (bitmap_mod_CFLAGS): Likewise.
8031 (bitmap_mod_LDFLAGS): Likewise.
8032 (tga_mod_SOURCES): Likewise.
8033 (tga_mod_CFLAGS): Likewise.
8034 (tga_mod_LDFLAGS): Likewise.
8035 (jpeg_mod_SOURCES): Likewise.
8036 (jpeg_mod_CFLAGS): Likewise.
8037 (jpeg_mod_LDFLAGS): Likewise.
8038 (png_mod_SOURCES): Likewise.
8039 (png_mod_CFLAGS): Likewise.
8040 (png_mod_LDFLAGS): Likewise.
8041 (gfxterm_mod_SOURCES): Likewise.
8042 (gfxterm_mod_CFLAGS): Likewise.
7795c55e 8043 (gfxterm_mod_LDFLAGS): Likewise.
7f02114b 8044
8045 * term/gfxterm.c: Removed include to grub/machine/memory.h,
8046 grub/machine/console.h.
8047
644fff97 80482009-01-04 Jerone Young <jerone@gmail.com>
8049
8050 Make on screen instructions clearer
8051
8052 Based on patch created by Jidanni <jidanni@jidanni.org>
8053
8054 * normal/menu.c: print clearer instructions on the screen
8055
1e901a75 80562009-01-02 Colin D Bennett <colin@gibibit.com>
8057
8058 New font engine.
34c44600 8059
1e901a75 8060 Additional changes by Vesa Jääskeläinen <chaac@nic.fi> to adapt to
8061 build system and fixed gfxterm.c to work with different sized fonts.
8062
8063 * configure.ac: Changed UNIFONT_HEX to UNIFONT_BDF.
34c44600 8064
1e901a75 8065 * configure: Re-generated.
34c44600 8066
1e901a75 8067 * DISTLIST: Removed font/manager.c.
8068 Added font/font.c.
8069 Added font/font_cmd.c.
34c44600 8070
1e901a75 8071 * Makefile.in: Changed UNIFONT_HEX to UNIFONT_BDF. Added Font tool
8072 compilation.
34c44600 8073
1e901a75 8074 * include/grub/misc.h (grub_utf8_to_ucs4): Changed prototype. Changed users.
34c44600 8075
8076 * kern/misc.c (grub_utf8_to_ucs4): Changed prototype.
1e901a75 8077
8078 * kern/term.c: Changed users of grub_utf8_to_ucs4.
34c44600 8079
1e901a75 8080 * normal/menu.c: Likewise.
34c44600 8081
1e901a75 8082 * conf/common.rmk (font_mod_SOURCES): Removed font/manager.c.
8083 (font_mod_SOURCES): Added font/font_cmd.c, font/font.c.
34c44600 8084
1e901a75 8085 * include/grub/font.h: Replaced with new file.
34c44600 8086
1e901a75 8087 * include/grub/video.h (GRUB_VIDEO_MODE_TYPE_ALPHA): Changed value.
8088 (GRUB_VIDEO_MODE_TYPE_DOUBLE_BUFFERED): Likewise.
8089 (GRUB_VIDEO_MODE_TYPE_COLOR_MASK): Likewise.
8090 (GRUB_VIDEO_MODE_TYPE_1BIT_BITMAP): Added.
8091 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_1BIT_PACKED.
34c44600 8092 (grub_video_mode_info): Added bg_red, bg_green, bg_blue, bg_alpha,
1e901a75 8093 fg_red, fg_green, fg_blue, fg_alpha.
8094 (grub_video_adapter): Removed blit_glyph.
34c44600 8095 (grub_video_blit_glyph): Removed.
8096
1e901a75 8097 * font/manager.c: Removed file.
34c44600 8098
8099 * font/font.c: New file.
8100
1e901a75 8101 * font/font_cmd.c: Likewise.
34c44600 8102
1e901a75 8103 * video/video.c (grub_video_blit_glyph): Removed.
34c44600 8104
1e901a75 8105 * video/i386/pc/vbe.c (grub_video_vbe_map_rgb): Added 1-bit support.
8106 (grub_video_vbe_map_rgba): Likewise.
8107 (grub_video_vbe_unmap_color_int): Likewise.
8108 (grub_video_vbe_blit_glyph): Removed.
8109 (grub_video_vbe_adapter): Removed blit_glyph.
34c44600 8110
1e901a75 8111 * video/i386/pc/vbeutil.c (get_data_ptr): Added 1-bit support.
8112 (get_pixel): Likewise.
34c44600 8113 (set_pixel): Likewise.
8114
1e901a75 8115 * commands/videotest.c (grub_cmd_videotest): Added more tests for fonts.
34c44600 8116
1e901a75 8117 * term/gfxterm.c: Adapted to new font engine.
34c44600 8118
1e901a75 8119 * term/i386/pc/vesafb.c: Marked as deprecated. Made it compile.
34c44600 8120
1e901a75 8121 * term/i386/pc/vga.c: Likewise.
34c44600 8122
1e901a75 8123 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: New file.
34c44600 8124
1e901a75 8125 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
34c44600 8126
1e901a75 8127 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
34c44600 8128
1e901a75 8129 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
34c44600 8130
1e901a75 8131 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
34c44600 8132
1e901a75 8133 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
34c44600 8134
1e901a75 8135 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
34c44600 8136
1e901a75 8137 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
34c44600 8138
1e901a75 8139 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
8140
8141 * util/grub.d/00_header.in: Changed to use new loadfont command.
34c44600 8142
1e901a75 8143 * util/grub-mkconfig_lib.in: Changed font extension.
8144
278922e8 81452008-12-28 Felix Zielcke <fzielcke@z-51.de>
8146
8147 * util/getroot.c (grub_util_get_grub_dev): Add support for
8148 /dev/md/dNNpNN style partitionable mdraid devices.
8149
3ced05cf 81502008-12-12 Alex Smith <alex@alex-smith.me.uk>
8151
8152 * fs/i386/pc/pxe.c (grub_pxefs_open): Handle the one open connection
8153 at a time limit of the PXE TFTP API correctly.
8154 (grub_pxefs_close): Likewise.
8155
7fd0ee30 81562008-11-29 Robert Millan <rmh@aybabtu.com>
8157
34c44600 8158 * disk/ata.c (grub_ata_pciinit): Handle errors raised by
7fd0ee30 8159 grub_ata_device_initialize() calls.
8160
34c44600 81612008-11-28 Krzysztof Smiechowicz <deadwood@wp.pl>
0c5e79ab 8162
8163 * fs/affs.c (grub_affs_iterate_dir): Return failure when directory
8164 iteration failed.
8165 * fs/sfs.c (grub_sfs_iterate_dir): Likewise.
8166
89313780 81672008-11-28 Robert Millan <rmh@aybabtu.com>
8168
8169 Fix build on powerpc-ieee1275. Based on patch created by
8170 Manoel Abranches <mrabran@linux.vnet.ibm.com>.
8171 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
8172 `kern/ieee1275/mmap.c'.
8173 * include/grub/powerpc/ieee1275/memory.h: New file.
8174
15257703 8175 Provide grub-install on coreboot.
8176 * conf/i386-coreboot.rmk (sbin_SCRIPTS): Add `grub-install'.
8177 (grub_install_SOURCES): New variable.
8178 * util/i386/pc/grub-install.in: Add a few condition checks to make it
8179 usable on coreboot.
8180
9fc5388a 81812008-11-25 Felix Zielcke <fzielcke@z-51.de>
8182
8183 * util/grub-fstest.c (grub_term_get_current_input): Change return type
8184 to `grub_term_input_t'.
8185 (grub_term_get_current_output): Change return type to
8186 `grub_term_output_t'.
8187
bc3a2f31 81882008-11-22 Robert Millan <rmh@aybabtu.com>
8189
34c44600 8190 Fix breakage on coreboot due to declaration mismatch.
bc3a2f31 8191 * term/i386/pc/vga_text.c (grub_vga_text_init_fini): New function.
8192 (grub_vga_text_term): Use grub_vga_text_init_fini() instead of
8193 grub_vga_text_cls().
8194
80fc88f2 8195 * kern/i386/loader.S (grub_multiboot_backward_relocator): Improve
34c44600 8196 comments. Avoid copying one more byte than necessary (just in case).
80fc88f2 8197
cbf36fd3 8198 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Change link address
8199 to 0x200000 (avoids trouble with some OFW implementations, and matches
8200 with the one in Yaboot).
8201 Reported by Manoel Abranches
8202
73e8e268 82032008-11-20 Robert Millan <rmh@aybabtu.com>
3cf6ac19 8204
8205 * kern/i386/coreboot/init.c (grub_time_tics): Remove variable.
8206 (grub_get_rtc, grub_exit): Abort with grub_fatal() if called.
8207
73e8e268 8208 * util/grub-mkconfig_lib.in (grub_warn): New function.
8209 (convert_system_path_to_grub_path): Use grub_warn() when issuing
8210 warnings, to obtain consistent formatting.
8211 * util/grub.d/00_header.in: Likewise.
8212 * util/update-grub_lib.in: Likewise.
8213
e94045a1 8214 * loader/i386/linux.c (allocate_pages): Fix a warning.
40f9faa4 8215 Move comment text to `#error' stanza.
e94045a1 8216
79d29fd7 8217 Harmonize ieee1275's grub_available_iterate() with the generic
8218 grub_machine_mmap_iterate() interface (fixes a recently-introduced
8219 build problem on i386-ieee1275):
8220 * kern/ieee1275/openfw.c (grub_available_iterate): Moved from here ...
8221 * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): ... here. Add third
8222 parameter `type'. Update all users of this function.
8223 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
8224 `kern/ieee1275/mmap.c'.
8225 * kern/ieee1275/init.c
8226 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): Replace
8227 with ...
8228 (grub_machine_mmap_iterate): ... this.
8229 * include/grub/i386/pc/memory.h (grub_machine_mmap_iterate): Change
8230 return type to `grub_err_t'. Update all implementations of this
8231 function prototype.
8232 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_iterate):
8233 Likewise.
8234
60d6b16e 8235 Add `lsmmap' command (lists firmware-provided memory map):
8236 * commands/lsmmap.c: New file.
8237 * conf/i386-pc.rmk (pkglib_MODULES): Add `lsmmap.mod'.
8238 (lsmmap_mod_SOURCES, lsmmap_mod_CFLAGS, lsmmap_mod_LDFLAGS): New
8239 variables.
8240 * conf/powerpc-ieee1275.rmk: Likewise.
8241 * conf/i386-coreboot.rmk: Likewise.
8242 * conf/i386-ieee1275.rmk: Likewise.
8243
ebaaf49b 82442008-11-19 Robert Millan <rmh@aybabtu.com>
8245
8246 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Fix a typo.
92907110 8247 * loader/i386/linux.c (grub_rescue_cmd_initrd): Implement a few needed
8248 constraints to initrd allocation (based on code from
8249 loader/i386/pc/linux.c). Without them, initrd was allocated too high
8250 for Linux to find it.
ebaaf49b 8251
dfab719f 82522008-11-14 Robert Millan <rmh@aybabtu.com>
8253
8254 * fs/cpio.c (grub_cpio_open): Compare `name' and `fn' by hand in
8255 order to cope with duplicate slashes.
8256
10fc3eb9 82572008-11-14 Robert Millan <rmh@aybabtu.com>
8258
8259 * include/grub/i386/coreboot/memory.h (GRUB_MEMORY_MACHINE_LOWER_SIZE):
8260 Redefine to match with GRUB_MEMORY_MACHINE_UPPER_START (0x100000). We
8261 don't want to mess with lower memory, because it is used in the Linux
8262 loader.
8263
8264 * loader/i386/linux.c (allocate_pages): Allocate `real_mode_mem' in
34c44600 8265 an appropriate place in lower memory, between 0x10000 and 0x90000,
10fc3eb9 8266 like loader/i386/efi/linux.c does. Linux often panics if real_mode_mem
8267 is in our heap (probably as a result of it being corrupted during
2f2a3442 8268 decompression). Add #error instance with comment to explain why this
8269 loader isn't currently usable on PC/BIOS.
10fc3eb9 8270
e2e07847 82712008-11-14 Robert Millan <rmh@aybabtu.com>
8272
8273 * term/i386/pc/serial.c [! GRUB_MACHINE_PCBIOS]
34c44600 8274 (GRUB_SERIAL_PORT_NUM): Fix miscalculation.
e2e07847 8275
fe8e8d69 82762008-11-12 Robert Millan <rmh@aybabtu.com>
8277
8278 Make loader/i386/linux.c buildable on i386-pc (although disabled).
8279
8280 * include/grub/i386/pc/init.h: Include `<grub/machine/memory.h>'.
8281 (struct grub_machine_mmap_entry, grub_machine_mmap_iterate): Move
8282 from here ...
8283 * include/grub/i386/pc/memory.h: ... to here.
8284
976b07d0 82852008-11-12 Robert Millan <rmh@aybabtu.com>
8286
8287 Fix build problems on i386-ieee1275 and *-efi (introduced by vga_text
8288 split).
8289
8290 * include/grub/i386/pc/console.h: Include `<grub/i386/vga_common.h>'.
8291 (grub_console_cur_color, grub_console_real_putchar)
8292 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
8293 (grub_console_setcolorstate, grub_console_setcolor)
8294 (grub_console_getcolor): Move from here ...
8295 * include/grub/i386/vga_common.h: ... to here (new file).
8296
8297 * term/i386/pc/vga_text.c: Replace `<grub/machine/console.h>' with
8298 `<grub/i386/vga_common.h>' and `<grub/cpu/io.h>' with
8299 `<grub/i386/io.h>'.
8300 * term/i386/vga_common.c: Replace `<grub/machine/console.h>' with
8301 `<grub/i386/vga_common.h>'.
8302
76679cd3 83032008-11-12 Robert Millan <rmh@aybabtu.com>
8304
8305 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `term/i386/vga_common.c'.
8306 * conf/i386.rmk (pkglib_MODULES): Add `vga_text.mod'.
8307 (vga_text_mod_SOURCES, vga_text_mod_CFLAGS, vga_text_mod_LDFLAGS): New
8308 variables.
8309 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
8310 `term/i386/pc/console.c' with `term/i386/vga_common.c'.
8311
8312 * kern/i386/coreboot/init.c (grub_machine_init): Replace call to
8313 grub_console_init() with call to grub_vga_text_init().
8314 (grub_machine_fini): Replace call to
8315 grub_console_fini() with call to grub_vga_text_fini() and
8316 grub_at_keyboard_fini().
8317
8318 * include/grub/i386/pc/console.h: Include `<grub/term.h>'.
8319 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
8320 (grub_console_setcolorstate, grub_console_setcolor)
8321 (grub_console_getcolor): New function prototypes.
8322
8323 * term/i386/pc/vga_text.c: Include `<grub/dl.h>'.
8324 (grub_vga_text_getxy, grub_vga_text_gotoxy, grub_vga_text_cls)
8325 (grub_vga_text_setcursor): Static-ize.
8326 (grub_vga_text_term): New structure.
8327 (GRUB_MOD_INIT(vga_text), GRUB_MOD_FINI(vga_text)): New functions.
8328
8329 * term/i386/pc/console.c: Remove `<grub/machine/machine.h>'.
8330 (grub_console_cur_color, grub_console_standard_color)
8331 (grub_console_normal_color, grub_console_highlight_color)
8332 (map_char, grub_console_putchar, grub_console_getcharwidth)
8333 (grub_console_getwh, grub_console_setcolorstate, grub_console_setcolor)
8334 (grub_console_getcolor): Move from here ...
8335 * term/i386/vga_common.c: ... to here (same function names).
8336
95b841d3 83372008-11-12 Robert Millan <rmh@aybabtu.com>
8338
8339 Use newly-added Multiboot support in coreboot.
8340
8341 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
8342 `kern/i386/coreboot/mmap.c' with `kern/i386/multiboot_mmap.c'.
8343
8344 * kern/i386/coreboot/startup.S: Enable Multiboot header, fix its
8345 alignment, set `MULTIBOOT_MEMORY_INFO' flag.
8346 (codestart): Store the MBI in `startup_multiboot_info' when we're
8347 being loaded using Multiboot.
8348
8349 * kern/i386/coreboot/init.c (grub_machine_init): Move
8350 grub_at_keyboard_init() call to beginning of function (useful for
8351 debugging). Call grub_machine_mmap_init() before attempting to use
8352 grub_machine_mmap_iterate().
8353 (grub_lower_mem, grub_upper_mem): Move from here ...
8354 * kern/i386/multiboot_mmap.c (grub_lower_mem, grub_upper_mem): ... to
8355 here (new file).
8356
8357 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_init): New
8358 function prototype.
8359
761ca975 83602008-11-12 Robert Millan <rmh@aybabtu.com>
8361
8362 Fix a regression introduced by the at_keyboard.mod split. Because
8363 some terminals are default on some platforms and non-default on
8364 others, the first terminal being registered determines which is
8365 going to be default.
8366
8367 * kern/term.c (grub_term_register_input): If this is the first
8368 terminal being registered, set it as the current one.
8369 (grub_term_register_output): Likewise.
8370
8371 * term/efi/console.c (grub_console_init): Do not call
8372 grub_term_set_current_output() or grub_term_set_current_input().
8373 * term/ieee1275/ofconsole.c (grub_console_init): Likewise.
8374 * term/i386/pc/console.c (grub_console_init): Likewise.
8375 (grub_console_fini): Do not call grub_term_set_current_input()
8376 (but leave grub_term_set_current_output() to restore text mode).
8377
6c529df7 83782008-11-10 Robert Millan <rmh@aybabtu.com>
8379
8380 * util/grub.d/00_header.in: Add backward compatibility check for
8381 versions of terminal.mod that don't understand `terminal_input' or
8382 `terminal_output'.
8383
132e4113 83842008-11-09 Robert Millan <rmh@aybabtu.com>
8385
8386 * commands/terminal.c (GRUB_MOD_FINI(terminal)): Unregister
8387 `terminal_input' / `terminal_output', not `terminal'.
8388
ac293d50 83892008-11-08 Robert Millan <rmh@aybabtu.com>
8390
8391 * Makefile.in (include_DATA): Fix srcdir=. assumption.
2a9c5940 8392 (DISTCLEANFILES): Add `build_env.mk'.
ac293d50 8393
0025933a 83942008-11-08 Robert Millan <rmh@aybabtu.com>
8395
8396 * term/i386/pc/vesafb.c (grub_vesafb_term): Change type to
dba3f844 8397 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
0025933a 8398 members. Update all users.
8399 * util/console.c (grub_ncurses_term): Split in ...
8400 (grub_ncurses_term_input): ... this, and ...
8401 (grub_ncurses_term_output): ... this. Update all users.
dcb6fa0a 8402 * term/ieee1275/ofconsole.c: Remove stale `#endif'.
0025933a 8403
37c86336 84042008-11-08 Robert Millan <rmh@aybabtu.com>
8405
8406 * Makefile.in (PKGLIB): Add $(pkglib_BUILDDIR).
8407 (PKGDATA): Add $(pkgdata_SRCDIR).
8408 (pkglib_BUILDDIR): New variable.
8409 (pkgdata_SRCDIR): New variable.
8410 (build_env.mk): New target.
8411 (include_DATA): New variable.
8412 (install-local): Install $(include_DATA) files in $(includedir).
8413
b6c15a2d 84142008-11-07 Pavel Roskin <proski@gnu.org>
8415
d99d46f1 8416 * gendistlist.sh: Use C locale for sorting to ensure consistent
8417 output on all systems.
8418
b6c15a2d 8419 * util/grub.d/00_header.in: Remove incorrect space before
8420 "serial".
8421
c32ee8c9 84222008-11-07 Robert Millan <rmh@aybabtu.com>
8423
8424 * include/multiboot2.h (struct multiboot_header): Add `flags' member as
8425 per specification.
8426 * loader/multiboot2.c (grub_multiboot2): Fix Multiboot2 header check.
8427 * loader/multiboot_loader.c (find_multi_boot2_header): New function
8428 (based on find_multi_boot1_header).
8429 (grub_rescue_cmd_multiboot_loader): Check for Multiboot2 header,
8430 using find_multi_boot2_header(), and abort if neither Multiboot or
8431 Multiboot headers were found.
8432
651c29b7 84332008-11-07 Robert Millan <rmh@aybabtu.com>
8434
8435 Modularize at_keyboard.mod:
8436
8437 * conf/i386.rmk (pkglib_MODULES): Add `at_keyboard.mod'.
8438 (at_keyboard_mod_SOURCES, at_keyboard_mod_CFLAGS)
8439 (at_keyboard_mod_LDFLAGS): New variables.
8440
8441 Actual terminal split:
8442
8443 * include/grub/term.h (struct grub_term): Split in ...
8444 (struct grub_term_input): ... this, and ...
8445 (struct grub_term_output): ... this. Update all users.
8446 (grub_term_set_current): Split in ...
8447 (grub_term_set_current_input): ... this, and ...
8448 (grub_term_set_current_output): ... this.
8449 (grub_term_get_current): Split in ...
8450 (grub_term_get_current_input): ... this, and ...
8451 (grub_term_get_current_output): ... this.
8452 (grub_term_register): Split in ...
8453 (grub_term_register_input): ... this, and ...
8454 (grub_term_register_output): ... this.
8455 (grub_term_unregister): Split in ...
8456 (grub_term_unregister_input): ... this, and ...
8457 (grub_term_unregister_output): ... this.
8458 (grub_term_iterate): Split in ...
8459 (grub_term_iterate_input): ... this, and ...
8460 (grub_term_iterate_output): ... this.
8461
8462 * kern/term.c (grub_term_list): Split in ...
8463 (grub_term_list_input): ... this, and ...
8464 (grub_term_list_output): ... this. Update all users.
8465 (grub_cur_term): Split in ...
8466 (grub_cur_term_input): ... this, and ...
8467 (grub_cur_term_output): ... this. Update all users.
8468 (grub_term_set_current): Split in ...
8469 (grub_term_set_current_input): ... this, and ...
8470 (grub_term_set_current_output): ... this.
8471 (grub_term_get_current): Split in ...
8472 (grub_term_get_current_input): ... this, and ...
8473 (grub_term_get_current_output): ... this.
8474 (grub_term_register): Split in ...
8475 (grub_term_register_input): ... this, and ...
8476 (grub_term_register_output): ... this.
8477 (grub_term_unregister): Split in ...
8478 (grub_term_unregister_input): ... this, and ...
8479 (grub_term_unregister_output): ... this.
8480 (grub_term_iterate): Split in ...
8481 (grub_term_iterate_input): ... this, and ...
8482 (grub_term_iterate_output): ... this.
8483
8484 * kern/misc.c (grub_abort): Split use of grub_term_get_current() into
8485 a check for input and one for output (and only attempt to get keys
8486 from user when input works).
8487
8488 * util/grub-probe.c (grub_term_get_current): Split in ...
8489 (grub_term_get_current_input): ... this, and ...
8490 (grub_term_get_current_output): ... this.
8491 * util/grub-fstest.c: Likewise.
8492 * util/i386/pc/grub-setup.c: Likewise.
8493 * util/grub-editenv.c: Likewise.
8494
8495 Portability adjustments:
8496
8497 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Remove
8498 `term/i386/pc/at_keyboard.c'.
8499 * kern/ieee1275/init.c [__i386__] (grub_machine_init): Remove call to
8500 grub_keyboard_controller_init() (now handled by terminal .init).
8501 * kern/i386/coreboot/init.c (grub_machine_init): Add call to
8502 grub_at_keyboard_init().
8503 * include/grub/i386/ieee1275/console.h (grub_keyboard_controller_init)
8504 (grub_console_checkkey, grub_console_getkey): Remove (now provided by
8505 at_keyboard.mod via input terminal interface).
8506 * include/grub/i386/coreboot/console.h: Convert into a stub for
8507 `<grub/i386/pc/console.h>'.
8508
8509 Migrate full terminals to new API:
8510
8511 * term/efi/console.c (grub_console_term): Split into ...
8512 (grub_console_term_input): ... this, and ...
8513 (grub_console_term_output): ... this. Update all users.
8514 * term/ieee1275/ofconsole.c: Remove __i386__ hack.
8515 (grub_ofconsole_init): Split into ...
8516 (grub_ofconsole_init_input): ... this, and ...
8517 (grub_ofconsole_init_output): ... this.
8518 (grub_ofconsole_term): Split into ...
8519 (grub_ofconsole_term_input): ... this, and ...
8520 (grub_ofconsole_term_output): ... this. Update all users.
8521 * term/i386/pc/serial.c (grub_serial_term): Split into ...
8522 (grub_serial_term_input): ... this, and ...
8523 (grub_serial_term_output): ... this. Update all users.
8524 * term/i386/pc/console.c (grub_console_term): Split into ...
8525 (grub_console_term_input): ... this, and ...
8526 (grub_console_term_output): ... this. Update all users.
8527 (grub_console_term_input): Only enable it on PC/BIOS platform.
8528 (grub_console_init): Remove grub_keyboard_controller_init() call.
8529
8530 Migrate input terminals to new API:
8531
8532 * term/i386/pc/at_keyboard.c: Replace `cpu' and `machine' with
8533 `i386' and `i386/pc' to enable build on x86_64 (this driver is
8534 i386-specific anyway).
8535 (grub_console_checkkey): Rename to ...
8536 (grub_at_keyboard_checkkey): ... this. Static-ize. Update all
8537 users.
8538 (grub_keyboard_controller_orig): New variable.
8539 (grub_console_getkey): Rename to ...
8540 (grub_at_keyboard_getkey): ... this. Static-ize. Update all
8541 users.
8542 (grub_keyboard_controller_init): Static-ize. Save original
8543 controller value so that it can be restored ...
8544 (grub_keyboard_controller_fini): ... here (new function).
8545 (grub_at_keyboard_term): New structure.
8546 (GRUB_MOD_INIT(at_keyboard), GRUB_MOD_FINI(at_keyboard)): New
8547 functions.
8548
8549 Migrate output terminals to new API:
8550
8551 * term/i386/pc/vga.c (grub_vga_term): Change type to
8552 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
8553 members. Update all users.
8554 * term/gfxterm.c (grub_video_term): Change type to
8555 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
8556 members. Update all users.
8557 * include/grub/i386/pc/console.h (grub_console_checkkey)
8558 (grub_console_getkey): Do not export (no longer needed by gfxterm,
8559 etc).
8560
8561 Migrate `terminal' command and userland tools to new API:
8562
8563 * commands/terminal.c (grub_cmd_terminal): Split into ...
8564 (grub_cmd_terminal_input): ... this, and ...
8565 (grub_cmd_terminal_output): ... this.
8566 (GRUB_MOD_INIT(terminal)): Split `terminal' command in two commands:
8567 `terminal_input' and `terminal_output'.
8568 * util/grub.d/00_header.in: Adjust `terminal' calls to new
8569 `terminal_input' / `terminal_output' API.
8570 * util/grub-mkconfig.in: Export ${GRUB_TERMINAL_INPUT} and
8571 ${GRUB_TERMINAL_OUTPUT} instead of ${GRUB_TERMINAL} (and if user
8572 provided ${GRUB_TERMINAL}, convert it).
8573
96e5d876 85742008-11-04 Robert Millan <rmh@aybabtu.com>
8575
8576 * util/grub.d/10_freebsd.in: New file. Generate grub configuration
8577 for FreeBSD.
8578 * conf/common.rmk (grub-mkconfig_SCRIPTS): Add 10_freebsd.
8579
556f3775 85802008-11-03 Bean <bean123ch@gmail.com>
8581
8582 * kern/elf.c (grub_elf32_load): Revert to previous code.
8583 (grub_elf64_load): Likewise.
8584
8585 * loader/i386/bsd.c (grub_bsd_elf32_hook): Change return address.
8586
926b9823 85872008-11-01 Robert Millan <rmh@aybabtu.com>
8588
8589 * Makefile.in (CPPFLAGS): Fix builddir=. assumption.
8590 (TARGET_CPPFLAGS): Likewise.
8591 * genmk.rb (mod_src): Fix builddir=. and srcdir=. assumptions.
8592
1432e958 85932008-11-01 Carles Pina i Estany <carles@pina.cat>
8594
8595 * normal/menu.c (run_menu): Add Previous and Next Page keys in menu.
8596
dba3f844 85972008-10-29 Guillem Jover <guillem.jover@nokia.com>
de4fa71c 8598
8599 * disk/lvm.c (grub_lvm_scan_device): Fix error recovery by delaying the
8600 addition of objects until the code is not going to be able to fail.
8601
dba3f844 86022008-10-29 Guillem Jover <guillem.jover@nokia.com>
b7279447 8603
8604 * disk/lvm.c (grub_lvm_scan_device): Fix possible NULL value handling
8605 (add a missing NULL check, and correct them by moving the pointer
8606 operations after the actual check).
8607
7ab28c21 86082008-10-29 Robert Millan <rmh@aybabtu.com>
8609
8610 * util/i386/pc/grub-install.in: Handle empty string as output from
8611 make_system_path_relative_to_its_root().
8612
1b7748eb 86132008-10-05 Hans Lambermont <hans@lambermont.dyndns.org>
8614
8615 * disk/lvm.c (grub_lvm_scan_device): Allocate buffer space for the
8616 circular metadata worst case scenario. If the metadata is circular
8617 then copy the wrap in place.
8618 * include/grub/lvm.h: Add GRUB_LVM_MDA_HEADER_SIZE, from the LVM2
8619 project lib/format_text/layout.h
8620 Circular metadata bug found and patch debugged by Jan Derk Gerlings.
8621
c9618ab2 86222008-10-03 Felix Zielcke <fzielcke@z-51.de>
8623
7a36edca 8624 * util/i386/pc/grub-install.in: Source grub-mkconfig_lib instead of update-grub_lib.
c9618ab2 8625
bf981c62 86262008-10-03 Felix Zielcke <fzielcke@z-51.de>
8627
8628 * util/update-grub_lib.in: Mention filename in warning message.
8629
6d994591 86302008-09-29 Felix Zielcke <fzielcke@z-51.de>
8631
8632 * NEWS: Update for rename of update-grub to grub-mkconfig.
8633
18ade780 86342008-09-29 Felix Zielcke <fzielcke@z-51.de>
8635
8636 * util/update-grub_lib.in: Copy to ...
8637 * util/grub-mkconfig_lib.in: ... this. Update all users.
7c3ff286 8638 * util/update-grub_lib.in: Make it a stub to `grub-mkconfig_lib.in'.
18ade780 8639 * util/update-grub.in: Rename to ...
8640 * util/grub-mkconfig.in: ... this. Update all users. Remove `-y'
8641 option. Add `--output' option to allow users to specify the generated
8642 configuration file. Default to stdout.
8643 (update_grub_dir): Rename to ...
8644 (grub_mkconfig_dir): ... this.
8645 (grub_cfg): Default to an empty string.
8646 * conf/common.rmk (update-grub): Rename to ...
8647 (grub-mkconfig): ... this.
8648 (update-grub_lib): Copy to ...
8649 (grub-mkconfig_lib): ... this.
8650 (update-grub_SCRIPTS): Copy to ...
8651 (grub-mkconfig_SCRIPTS): ... this. Update all users.
8652 (update-grub_DATA): Rename to ...
8653 (grub-mkconfig_DATA): ... this.
8654
556ce6ac 86552008-09-28 Robert Millan <rmh@aybabtu.com>
8656
8657 * fs/iso9660.c (struct grub_iso9660_primary_voldesc): Rename `created'
8658 to `modified'. Add the real `created' field.
8659 (grub_iso9660_uuid): Use `modified' rather than `created' for
8660 constructing the UUID.
8661
86622008-09-28 Felix Zielcke <fzielcke@z-51.de>
eb079ba9 8663
8664 fs/jfs.c (grub_jfs_find_file): Treat multiple slashes like one.
8665 Based on code from Tomas Ebenlendr <ebik@ucw.cz>.
8666
92274e85 86672008-09-28 Bean <bean123ch@gmail.com>
8668
8669 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a bug in the previous patch.
8670 Thanks to Christian Franke for finding this bug.
8671
add6f17a 86722008-09-25 Robert Millan <rmh@aybabtu.com>
8673
8674 * util/grub-mkdevicemap.c (make_device_map): Actually replace all
8675 instances of grub_util_get_disk_name() (see previous commit).
8676
d2a367b8 86772008-09-25 Robert Millan <rmh@aybabtu.com>
8678
8679 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Remove
8680 `util/i386/get_disk_name.c'.
8681 * conf/i386-efi.rmk: Likewise.
8682 * conf/x86_64-efi.rmk: Likewise.
8683 * conf/i386-coreboot.rmk: Likewise.
8684 * conf/i386-ieee1275.rmk: Likewise.
8685 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Remove
8686 `util/ieee1275/get_disk_name.c'.
8687 * include/grub/util/misc.h (grub_util_get_disk_name): Remove.
8688 * util/ieee1275/get_disk_name.c: Remove file.
8689 * util/i386/get_disk_name.c: Remove file.
8690 * util/grub-mkdevicemap.c (make_device_map): Back to hardcoding
8691 "hd%d" for device.map entries, rather than using
8692 grub_util_get_disk_name().
8693
81a06771 86942008-09-24 Carles Pina i Estany <carles@pina.cat>
b0c301f7 8695
8696 * disk/dmraid_nvidia.c (grub_dmraid_nv_detect): Fix `unused parameter'
8697 warning.
8698 * commands/i386/pc/pxecmd.c (dmraid_nvidia): Likewise.
8699
5a004279 87002008-09-24 Carles Pina i Estany <carles@pina.cat>
8701
8702 * include/grub/i386/pc/console.h (GRUB_TERM_NPAGE):
8703 Changed to 0x5100.
8704 (GRUB_TERM_PPAGE): Changed to 0x4900.
8705
397093d3 87062008-09-24 Robert Millan <rmh@aybabtu.com>
8707
8708 * include/grub/powerpc/ieee1275/console.h (GRUB_CONSOLE_KEY_*): Remove
8709 macros (they were i386-pc specific).
8710 * include/grub/sparc64/ieee1275/console.h: Likewise.
8711 * include/grub/efi/console.h: Likewise.
8712
a91b6c7c 87132008-09-22 Bean <bean123ch@gmail.com>
8714
8715 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a rare case where $BITMAP is
8716 resident and in attribute list.
8717
8718 * include/grub/ntfs.h (BMP_LEN): Removed.
8719
c40fd116 87202008-09-22 Bean <bean123ch@gmail.com>
8721
81a06771 8722 * disk/ata.c (grub_atapi_open): Initialize devfnd, no need to set
c40fd116 8723 scsi->name and scsi->luns, as they will be set in grub_scsi_open.
8724
8725 * disk/scsi.c (grub_scsi_open): Don't call p->close (scsi) here when
8726 error occurs, as grub_disk_open will call grub_disk_close, which will
8727 call p->close (scsi).
8728
81a06771 87292008-09-21 Felix Zielcke <fzielcke@z-51.de>
eb73121d 8730
8731 * configure.ac (AC_INIT): Quote `GRUB' string and version number.
8732 (AC_PREREQ): Bumped to 2.59.
8733 (AC_TRY_COMPILE): Replace obsolete macro with ...
8734 (AC_COMPILE_IFELSE): ... this.
8735 * aclocal.m4 (AC_TRY_LINK): Replace obsolete macro with ...
8736 (AC_LINK_IFELSE): ... this.
8737
5dc43410 87382008-09-21 Felix Zielcke <fzielcke@z-51.de>
8739
8740 * autogen.sh: Add a call to `gendistlist.sh'.
8741
9035dce4 87422008-09-19 Christian Franke <franke@computer.org>
8743
8744 * aclocal.m4 (grub_CHECK_ENABLE_EXECUTE_STACK): New function.
8745 * configure.ac: Call grub_CHECK_ENABLE_EXECUTE_STACK.
8746 * include/grub/misc.h [NEED_ENABLE_EXECUTE_STACK]:
8747 Export __enable_execute_stack() to modules.
8748 * kern/misc.c [NEED_ENABLE_EXECUTE_STACK] (__enable_execute_stack):
8749 New function.
8750
7fd75377 87512008-09-09 Felix Zielcke <fzielcke@z-51.de>
8752
040030b3 8753 * Makefile.in (RMKFILES): Add `i386.rmk' and `x86_64-efi.rmk'.
8754 Sort the list.
8755
87562008-09-09 Felix Zielcke <fzielcke@z-51.de>
8757
8758 * util/hostdisk.c: Replace #include <grub/util/biosdisk.h> with
7fd75377 8759 #include <grub/util/hostdisk.h>.
8760
89d5ffcf 87612008-09-08 Robert Millan <rmh@aybabtu.com>
8762
8763 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Skip
8764 segments when their filesz is zero (grub_file_read() interprets
81a06771 8765 zero-size as "read until EOF", which results in memory corruption).
89d5ffcf 8766 Use `lowest_segment' rather than 0 for calculating the current
8767 segment load address.
8768
40da438f 87692008-09-08 Robert Millan <rmh@aybabtu.com>
8770
8771 * util/hostdisk.c (open_device): Replace a grub_util_info() call
8772 with grub_dprintf("hostdisk", ...), as it was so verbose that it
8773 clobbered useful information.
8774
ddbf5556 87752008-09-08 Robert Millan <rmh@aybabtu.com>
8776
8777 * include/grub/util/biosdisk.h: Move to ...
8778 * include/grub/util/hostdisk.h: ... here. Update all users.
8779 * util/biosdisk.c: Move to ...
8780 * util/hostdisk.c: ... here. Update all users.
8781
783d0f48 87822008-09-07 Robert Millan <rmh@aybabtu.com>
8783
8784 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): Remove
8785 variables.
8786 (grub_multiboot): Move `mbi' allocation upwards, so that mmap address
8787 and length can be stored directly in the `mbi->mmap_addr' and
8788 `mbi->mmap_length' struct fields.
8789
548e2ea5 87902008-09-07 Robert Millan <rmh@aybabtu.com>
8791
8792 * conf/i386.rmk: New file. Provides declaration for building
8793 `cpuid.mod'.
8794 * conf/i386-pc.rmk (pkglib_MODULES): Remove `cpuid.mod'.
8795 (cpuid_mod_SOURCES, cpuid_mod_CFLAGS, cpuid_mod_LDFLAGS): Remove
8796 variables.
8797 Include `conf/i386.mk'.
8798 * conf/i386-efi.rmk: Likewise.
8799 * conf/x86_64-efi.rmk: Likewise.
8800 * conf/i386-coreboot.rmk: Likewise.
8801 * conf/i386-ieee1275.rmk: Likewise.
8802
0ea85a37 88032008-09-07 Vesa Jääskeläinen <chaac@nic.fi>
8804
8805 Based on patch created by Colin D Bennett <colin@gibibit.com>.
8806 Adds optimization support for BGR based modes.
8807
8808 * include/grub/i386/pc/vbeblit.h (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8) Removed.
8809 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
8810 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
8811 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
8812 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
8813 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
8814 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
8815 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
8816 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
8817 (grub_video_i386_vbeblit_index_index): Likewise.
8818 (grub_video_i386_vbeblit_replace_directN): Added.
8819 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
8820 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
8821 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
8822 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
8823 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
8824 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
81a06771 8825 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
0ea85a37 8826 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
8827 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
8828 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
8829 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
8830 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
8831 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
8832
8833 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8) Removed.
8834 (grub_video_i386_vbefill_R8G8B8): Likewise.
8835 (grub_video_i386_vbefill_index): Likewise.
8836 (grub_video_i386_vbefill_direct32): Added.
8837 (grub_video_i386_vbefill_direct24): Likewise.
8838 (grub_video_i386_vbefill_direct16): Likewise.
8839 (grub_video_i386_vbefill_direct8): Likewise.
8840
81a06771 8841 * include/grub/video.h (grub_video_blit_format): Removed
0ea85a37 8842 GRUB_VIDEO_BLIT_FORMAT_R8G8B8A8, GRUB_VIDEO_BLIT_FORMAT_R8G8B8.
8843 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_RGBA_8888,
8844 GRUB_VIDEO_BLIT_FORMAT_BGRA_8888, GRUB_VIDEO_BLIT_FORMAT_RGB_888,
8845 GRUB_VIDEO_BLIT_FORMAT_BGR_888, GRUB_VIDEO_BLIT_FORMAT_RGB_565,
8846 GRUB_VIDEO_BLIT_FORMAT_BGR_565.
81a06771 8847
0ea85a37 8848 * video/video.c (grub_video_get_blit_format): Updated to use new
8849 blit formats. Added handling for 16 bit color modes.
81a06771 8850
8851 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Updated to use new
0ea85a37 8852 fillers.
8853 (common_blitter): Updated to use new blitters.
8854
8855 * video/i386/pc/vbeblit.c (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8):
8856 Removed.
8857 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
8858 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
8859 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
8860 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
8861 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
8862 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
8863 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
8864 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
8865 (grub_video_i386_vbeblit_index_index): Likewise.
8866 (grub_video_i386_vbeblit_replace_directN): Added.
8867 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
8868 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
8869 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
8870 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
8871 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
8872 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
8873 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
8874 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
8875 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
8876 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
8877 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
8878 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
8879 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
81a06771 8880
0ea85a37 8881 * video/i386/pc/vbefill.c (grub_video_i386_vbefill_R8G8B8A8): Removed.
8882 (grub_video_i386_vbefill_R8G8B8): Likewise.
8883 (grub_video_i386_vbefill_index): Likewise.
8884 (grub_video_i386_vbefill_direct32): Added.
8885 (grub_video_i386_vbefill_direct24): Likewise.
8886 (grub_video_i386_vbefill_direct16): Likewise.
8887 (grub_video_i386_vbefill_direct8): Likewise.
81a06771 8888
0ea85a37 8889 * video/readers/jpeg.c (grub_jpeg_decode_sos): Adapt to new blitter
8890 types.
81a06771 8891
0ea85a37 8892 * video/readers/tga.c (grub_video_reader_tga): Adapt to new blitter
8893 types.
81a06771 8894
0ea85a37 8895 * video/readers/png.c (grub_png_decode_image_header): Adapt to new
8896 blitter types.
81a06771 8897
0ea85a37 8898 * video/bitmap.c (grub_video_bitmap_create): Adapt to new blitter
8899 types.
8900
e8a83df6 89012008-09-06 Felix Zielcke <fzielcke@z-51.de>
8902
8903 * disk/raid.c (insert_array): Set `array->chunk_size' to 64 for
8904 RAID level 1.
8905
6bcd8ee5 89062008-09-06 Felix Zielcke <fzielcke@z-51.de>
c375ae58 8907
6bcd8ee5 8908 * fs/iso9660.c (grub_iso9660_date): New structure.
8909 (grub_iso9660_primary_voldesc): Add `grub_iso9660_date' member.
8910 (grub_iso9660_uuid): New function.
c375ae58 8911
59261157 89122008-09-05 Bean <bean123ch@gmail.com>
8913
8914 * fs/fshelp.c (grub_fshelp_find_file): Handle case insensitive names.
8915
8916 * fs/ntfs.c (list_file): Ignore names in DOS namespace, set the case
8917 insensitive bit for names in Win32 and Win32 & DOS namespace.
8918
8919 * include/grub/fshelp.h (GRUB_FSHELP_CASE_INSENSITIVE): New macro.
8920
8921 * include/grub/types.h (LONG_MAX): Likewise.
8922
58b6645a 89232008-09-04 Felix Zielcke <fzielcke@z-51.de>
8924
4ee55921 8925 * util/getroot.c: Include <config.h>.
8926 (grub_util_get_grub_dev): Rewrite to use asprintf for mdraid devices,
8927 add support for /dev/md/N devices and handle LVM double dash escaping.
8928
89292008-09-04 Felix Zielcke <fzielcke@z-51.de>
8930
8931 * config.guess: Update to latest version from config git.
8932 * config.sub: Likewise.
58b6645a 8933
9124f65d 89342008-09-03 Robert Millan <rmh@aybabtu.com>
8935
8936 * disk/scsi.c (grub_scsi_open): Remove size limit when printing
8937 `disk->total_sectors'.
8938
81a06771 89392008-09-01 Colin D Bennett <colin@gibibit.com>
a0224a4e 8940
8941 * include/grub/normal.h: Fixed incorrect comment for
8942 GRUB_COMMAND_FLAG_NO_ARG_PARSE.
8943
81a06771 89442008-09-01 Colin D Bennett <colin@gibibit.com>
f0619958 8945
8946 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Replaced constant
8947 values with defines.
8948
8949 * include/grub/i386/pc/vbe.h (GRUB_VBE_MODEATTR_SUPPORTED): Added.
8950 (GRUB_VBE_MODEATTR_RESERVED_1): Likewise.
8951 (GRUB_VBE_MODEATTR_BIOS_TTY_OUTPUT_SUPPORT): Likewise.
8952 (GRUB_VBE_MODEATTR_COLOR): Likewise.
8953 (GRUB_VBE_MODEATTR_GRAPHICS): Likewise.
8954 (GRUB_VBE_MODEATTR_VGA_COMPATIBLE): Likewise.
8955 (GRUB_VBE_MODEATTR_VGA_WINDOWED_AVAIL): Likewise.
8956 (GRUB_VBE_MODEATTR_LFB_AVAIL): Likewise.
8957 (GRUB_VBE_MODEATTR_DOUBLE_SCAN_AVAIL): Likewise.
8958 (GRUB_VBE_MODEATTR_INTERLACED_AVAIL): Likewise.
8959 (GRUB_VBE_MODEATTR_TRIPLE_BUF_AVAIL): Likewise.
8960 (GRUB_VBE_MODEATTR_STEREO_AVAIL): Likewise.
8961 (GRUB_VBE_MODEATTR_DUAL_DISPLAY_START): Likewise.
8962 (GRUB_VBE_MEMORY_MODEL_TEXT): Likewise.
8963 (GRUB_VBE_MEMORY_MODEL_CGA): Likewise.
8964 (GRUB_VBE_MEMORY_MODEL_HERCULES): Likewise.
8965 (GRUB_VBE_MEMORY_MODEL_PLANAR): Likewise.
8966 (GRUB_VBE_MEMORY_MODEL_NONCHAIN4_256): Likewise.
8967 (GRUB_VBE_MEMORY_MODEL_YUV): Likewise.
8968
93d5cbf8 89692008-08-31 Robert Millan <rmh@aybabtu.com>
8970
8971 * loader/i386/pc/multiboot.c (grub_get_multiboot_mmap_len): Fix
8972 declaration.
8973 (grub_multiboot): Fix a few warnings.
8974
21751d50 89752008-08-31 Robert Millan <rmh@aybabtu.com>
8976
8977 * loader/i386/pc/multiboot.c: Update comment not to say that
8978 boot_device support is unimplemented.
8979
e27a75c5 89802008-08-31 Robert Millan <rmh@aybabtu.com>
8981
8982 * loader/i386/pc/multiboot.c: Update comment not to say that a.out
8983 or memory map support are unimplemented.
8984
81a06771 89852008-08-31 Colin D Bennett <colin@gibibit.com>
64d2d53c 8986
8987 * util/i386/pc/grub-mkrescue.in: Support multiple overlay directories.
8988
81a06771 89892008-08-31 Colin D Bennett <colin@gibibit.com>
c08a6c18 8990
8991 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Show VBE version and
8992 total video memory in 'vbeinfo' output; show color format details for
8993 each video mode.
8994
7c5d8d95 89952008-08-30 Pavel Roskin <proski@gnu.org>
8996
8997 * util/genmoddep.c: Remove for real this time.
8998 * DISTLIST: Remove util/genmoddep.c.
8999
4cebd25a 90002008-08-30 Robert Millan <rmh@aybabtu.com>
9001
9002 * kern/i386/pc/startup.S (multiboot_header): Force 4-byte alignment
9003 as required by Multiboot spec (it was already 4-byte aligned, but
9004 only by chance).
9005
b497a269 90062008-08-29 Pavel Roskin <proski@gnu.org>
9007
e3925185 9008 * kern/powerpc/ieee1275/crt0.S: Rename to ...
9009 * kern/powerpc/ieee1275/startup.S: ... this.
9010 * conf/powerpc-ieee1275.rmk: Adjust for the above.
9011 * DISTLIST: Likewise.
9012
b497a269 9013 * kern/powerpc/ieee1275/crt0.S: Include grub/symbol.h and
9014 grub/cpu/kernel.h. Add start label for consistency with other
9015 platforms. Add grub_prefix immediately after start. Add jump
9016 to the code after grub_prefix.
9017 * include/grub/powerpc/kernel.h: Provide valid values for
9018 GRUB_KERNEL_CPU_PREFIX and GRUB_KERNEL_CPU_DATA_END.
9019
6e5a42fe 90202008-08-29 Bean <bean123ch@gmail.com>
9021
9022 * configure.ac: Change host_os to cygwin for mingw.
9023 (asprintf): New check for function.
9024
9025 * include/grub/symbol.h: Replace #ifndef __CYGWIN__ with
9026 #if ! defined (__CYGWIN__) && ! defined (__MINGW32__).
9027
9028 * include/grub/util/misc.h: #include <config.h> and <grub/types.h>,
81a06771 9029 declare asprintf if HAVE_ASPRINTF is not set, declare fseeko, ftello,
6e5a42fe 9030 sync, sleep and grub_util_get_disk_size for mingw.
9031
9032 * util/biosdisk.c (grub_util_biosdisk_open): Use grub_util_get_disk_size
9033 to get size in mingw.
9034 (open_device): Use flag O_BINARY if it's defined.
9035 (find_root_device): Add dummy code for mingw.
9036
9037 * util/grub-mkdevicemap.c (get_floppy_disk_name): Return 0 for mingw.
9038 (get_ide_disk_name): Return //./PHYSICALDRIVE%d for mingw.
9039 (get_scsi_disk_name): Return 0 for mingw.
9040
9041 * util/hostfs.c: #include <grub/util/misc.h>.
9042 (grub_hostfs_open): Use "rb" flag to open file, use
9043 grub_util_get_disk_size to get disk size for mingw.
9044
9045 * util/misc.c: #include <windows.h> and <winioctl.h> in mingw.
9046 (asprintf): New function if HAVE_ASPRINTF is not set.
9047 (sync): New function for mingw.
9048 (sleep): Likewise.
9049 (grub_util_get_disk_size): Likewise.
9050
ab3f2673 90512008-08-28 Pavel Roskin <proski@gnu.org>
9052
9053 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
9054 kern/time.c.
9055
1c282483 90562008-08-28 Robert Millan <rmh@aybabtu.com>
9057
9058 * util/biosdisk.c (find_grub_drive): Declare missing `i' variable.
9059
678e849c 90602008-08-28 Robert Millan <rmh@aybabtu.com>
9061
9062 Change find_grub_drive() syntax so it doesn't prevent it from
9063 detecting NULL names as errors.
9064
9065 * util/biosdisk.c (find_grub_drive): Move free slot search code
9066 from here ...
9067 (find_free_slot): ... to here.
9068 (read_device_map): Use find_free_slot() to search for free slots.
9069
965c75ca 90702008-08-27 Marco Gerards <marco@gnu.org>
9071
9072 * conf/common.rmk (pkglib_MODULES): Add scsi.mod.
9073 (scsi_mod_SOURCES): New variable.
9074 (scsi_mod_CFLAGS): Likewise
9075 (scsi_mod_LDFLAGS): Likewise.
9076
9077 * disk/scsi.c: New file.
9078
9079 * include/grub/scsi.h: Likewise.
9080
9081 * include/grub/scsicmd.h: Likewise.
9082
9083 * disk/ata.c: Include <grub/scsi.h>.
9084 (grub_atapi_packet): Do not use grub_ata_cmd, use registers
9085 instead.
9086 (grub_ata_iterate): Skip ATAPI devices.
9087 (grub_ata_open): Only handle ATAPI devices.
9088 (struct grub_atapi_read): Removed.
9089 (grub_atapi_readsector): Likewise.
9090 (grub_ata_read): No longer handle ATAPI devices.
9091 (grub_ata_write): Likewise.
9092 (grub_atapi_iterate): New function.
9093 (grub_atapi_read): Likewise.
9094 (grub_atapi_write): Likewise.
9095 (grub_atapi_open): Likewise.
9096 (grub_atapi_close): Likewise.
9097 (grub_atapi_dev): New variable.
9098 (GRUB_MOD_INIT(ata)): Register ATAPI as SCSI device.
9099 (GRUB_MOD_FINI(ata)): Unregister ATAPI.
9100
9101 * include/grub/disk.h (enum grub_disk_dev_id): Add
9102 `GRUB_DISK_DEVICE_SCSI_ID'.
9103
c07ae501 91042008-08-26 Robert Millan <rmh@aybabtu.com>
9105
9106 * util/biosdisk.c (grub_util_biosdisk_open, open_device)
9107 (grub_util_biosdisk_get_grub_dev): Make error messages a bit more
9108 descriptive.
9109
5ed20adc 91102008-08-23 Bean <bean123ch@gmail.com>
9111
9112 * conf/common.rmk (grub_probe_SOURCES): Add disk/mdraid_linux.c.
9113 (grub_fstest_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
9114 disk/mdraid_linux.c and disk/dmraid_nvidia.c and lib/crc.c.
9115 (pkglib_MODULES): Add raid5rec.mod, raid6rec.mod, mdraid.mod and
9116 dm_nv.mod.
9117 (raid5rec_mod_SOURCES): New macro.
9118 (raid5rec_mod_CFLAGS): Likewise.
9119 (raid5rec_mod_LDFLAGS): Likewise.
9120 (raid6rec_mod_SOURCES): Likewise.
9121 (raid6rec_mod_CFLAGS): Likewise.
9122 (raid6rec_mod_LDFLAGS): Likewise.
9123 (mdraid_mod_SOURCES): Likewise.
9124 (mdraid_mod_CFLAGS): Likewise.
9125 (mdraid_mod_LDFLAGS): Likewise.
9126 (dm_nv_mod_SOURCES): Likewise.
9127 (dm_nv_mod_CFLAGS): Likewise.
9128 (dm_nv_mod_LDFLAGS): Likewise.
9129
9130 * conf/i386-pc.rmk (grub_setup_SOURCES): Add disk/mdraid_linux.c.
9131 (grub_emu_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
9132 disk/mdraid_linux.c and disk/dmraid_nvidia.c.
9133
9134 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add disk/raid5_recover.c,
9135 disk/raid6_recover.c, disk/mdraid_linux.c and disk/dmraid_nvidia.c.
9136
9137 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
9138
9139 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
9140
9141 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
9142
9143 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
9144
9145 * disk/raid5_recover.c: New file.
9146
9147 * disk/raid6_recover.c: Likewise.
9148
9149 * disk/mdraid_linux.c: Likewise.
9150
9151 * disk/dmraid_nvidia.c: Likewise.
9152
9153 * disk/i386/pc/biosdisk.c: Set total_sectors of cdrom device to
9154 ULONG_MAX.
9155
9156 * disk/raid.c (grub_raid_open): Use the size of the smallest disk to
9157 calculate the size of raid device.
9158 (grub_raid_read): Simplify raid0 code. Support raid4, raid6 and four
9159 different layout of raid5.
9160 (grub_raid_scan_device): Remove code specific to mdraid.
9161 (grub_raid_list): New variable.
9162 (free_array): New function.
9163 (grub_raid_register): Likewise.
9164 (grub_raid_unregister): Likewise.
9165 (grub_raid_rescan): Likewise.
9166 (GRUB_MOD_INIT): Don't iterate device here.
9167 (GRUB_MOD_FINI): Use free_array to release resource.
9168
9169 * include/grub/raid.h: Remove macro and structure specific to mdraid.
9170 (grub_raid5_recover_func_t): New function variable type.
9171 (grub_raid6_recover_func_t): Likewise.
9172 (grub_raid5_recover_func): New variable.
9173 (grub_raid6_recover_func): Likewise.
9174 (grub_raid_register): New function.
9175 (grub_raid_unregister): Likewise.
9176 (grub_raid_rescan): Likewise.
9177 (grub_raid_block_xor): Likewise.
9178
9179 * util/grub-fstest.c: Add #include <grub/raid.h> and <grub/lib/crc.h>.
9180 (CMD_CRC): New macro.
9181 (part): Removed.
9182 (read_file): Handle device as well as file.
9183 (cmd_crc): New function.
9184 (fstest): Handle multiple disks.
9185 (options): Remove part, raw and long, add root and diskcount.
9186 (usage): Add crc, remove -p, -r, -l, add -r and -c.
dba3f844 9187 (main): Find the first non option entry and ignore subsequent options,
5ed20adc 9188 add handling for the new options, support multiple disks.
9189
9190 * util/grub-probe.c (probe): Add mdraid to abstraction_name.
9191
29c18915 91922008-08-23 Bean <bean123ch@gmail.com>
9193
9194 * normal/x86_64/setjmp.S (grub_longjmp): Return 1 when val = 0.
9195
9196 * genfslist.sh: Ignore kernel.mod.
9197
9198 * genpartmaplist.sh: Likewise.
9199
8415f261 92002008-08-23 Robert Millan <rmh@aybabtu.com>
9201
9202 * util/getroot.c (find_root_device): Skip anything that starts with
9203 a dot, not just directories. This avoids things like /dev/.tmp.md0.
9204
d5a7dc5b 92052008-08-22 Felix Zielcke <fzielcke@z-51.de>
81a06771 9206
d5a7dc5b 9207 * util/update-grub.in (GRUB_GFXMODE): Export variable.
9208 * util/grub.d/00_header.in: Allow the administrator to change default
9209 gfxmode via ${GRUB_GFXMODE}.
9210
380cfbb4 92112008-08-21 Felix Zielcke <fzielcke@z-51.de>
9212
9213 * fs/ntfs.c (grub_ntfs_mount): Fix a memory leak.
9214
c9baafe7 92152008-08-21 Robert Millan <rmh@aybabtu.com>
9216
9217 * loader/i386/linux.c: New file. Implements generic 32-bit Linux
9218 loader.
9219 * conf/i386-coreboot.rmk (_linux_mod_SOURCES): Replace
9220 `loader/i386/pc/linux.c' with `loader/i386/linux.c'.
9221
e290bef2 92222008-08-20 Carles Pina i Estany <carles@pina.cat>
9223
9224 * menu/normal.c (run_menu): Replace hardcoded numbers with macros
9225 (16 for GRUB_TERM_UP and 14 for GRUB_TERM_DOWN)
9226
f9dbfc96 92272008-08-19 Robert Millan <rmh@aybabtu.com>
9228
9229 * term/gfxterm.c (DEFAULT_CURSOR_COLOR): Remove.
9230 (struct grub_virtual_screen): Remove `cursor_color'.
9231 (grub_virtual_screen_setup): Remove `virtual_screen.cursor_color'
9232 initialization.
9233 (write_cursor): Use `virtual_screen.fg_color' to draw cursor.
9234
dd6bd6ab 92352008-08-18 Robert Millan <rmh@aybabtu.com>
9236
9237 Unify (identical) linux_normal.c files.
9238 * loader/i386/efi/linux_normal.c: Move from here ...
9239 * loader/linux_normal.c: ... to here. Update all users.
9240 * loader/i386/pc/linux_normal.c: Delete. Update all users.
9241 * loader/i386/ieee1275/linux_normal.c: Likewise.
9242
7f42f83e 92432008-08-18 Robert Millan <rmh@aybabtu.com>
9244
9245 * include/grub/i386/linux.h (LINUX_LOADER_ID_LILO)
9246 (LINUX_LOADER_ID_LOADLIN, LINUX_LOADER_ID_BOOTSECT)
9247 (LINUX_LOADER_ID_SYSLINUX, LINUX_LOADER_ID_ETHERBOOT)
9248 (LINUX_LOADER_ID_ELILO, LINUX_LOADER_ID_GRUB, LINUX_LOADER_ID_UBOOT)
9249 (LINUX_LOADER_ID_XEN, LINUX_LOADER_ID_GUJIN, LINUX_LOADER_ID_QEMU):
9250 New macros.
9251 (GRUB_LINUX_CL_OFFSET, GRUB_LINUX_CL_END_OFFSET): Move from here ...
9252 * loader/i386/pc/linux.c (GRUB_LINUX_CL_OFFSET)
9253 (GRUB_LINUX_CL_END_OFFSET): ... to here.
9254 * loader/i386/efi/linux.c (GRUB_EFI_CL_OFFSET): Rename to ...
9255 (GRUB_LINUX_CL_OFFSET): ... this. Update all users.
9256 (GRUB_EFI_CL_END_OFFSET): Rename to ...
9257 (GRUB_LINUX_CL_END_OFFSET): ... this. Update all users.
9258 (grub_rescue_cmd_linux): Macroify `type_of_loader' initialization.
9259 Initialize `params->video_cursor_x' and `params->video_cursor_y'
9260 portably using grub_getxy().
9261 Replace `-EFI' with `-bzImage' in boot message.
9262
38487ddb 92632008-08-17 Robert Millan <rmh@aybabtu.com>
9264
9265 * include/grub/x86_64/kernel.h: New file (<grub/i386/kernel.h> stub).
9266
deceb3ec 92672008-08-17 Robert Millan <rmh@aybabtu.com>
9268
9269 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pc/mmap.c'.
9270
9271 * include/grub/i386/pc/init.h (GRUB_MACHINE_MEMORY_AVAILABLE)
9272 (GRUB_MACHINE_MEMORY_RESERVED): New macros.
9273 (grub_machine_mmap_iterate): New function declaration.
9274 * include/grub/multiboot.h (struct grub_multiboot_mmap_entry): New
9275 structure.
9276 (GRUB_MMAP_MEMORY_AVAILABLE, GRUB_MMAP_MEMORY_RESERVED): New
9277 macros.
9278
9279 * kern/i386/pc/init.c (grub_machine_init): Replace hardcoded region
9280 type check value with `GRUB_MACHINE_MEMORY_AVAILABLE'.
9281 Move e820 parsing from here ...
9282 * kern/i386/pc/mmap.c: New file.
9283 (grub_machine_mmap_iterate): ... to here.
9284
9285 * include/grub/i386/coreboot/memory.h: Remove `<grub/err.h>'.
9286 (GRUB_LINUXBIOS_MEMORY_AVAILABLE): Rename (for consistency) to ...
9287 (GRUB_MACHINE_MEMORY_AVAILABLE): ... this. Update all users.
9288 (grub_available_iterate): Redeclare to return `void', and redeclare
9289 its hook to use grub_uint64_t as addr and size parameters, and rename
9290 to ...
9291 (grub_machine_mmap_iterate): ... this. Update all users.
9292
9293 * kern/i386/coreboot/mmap.c (grub_mmap_iterate): Simplify parser loop
9294 to make it more readable. Rename to ...
9295 (grub_machine_mmap_iterate): ... this.
9296
9297 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): New variables.
9298 (grub_get_multiboot_mmap_len, grub_fill_multiboot_mmap): New functions.
9299 (grub_multiboot): Allocate an extra region after the payload, and fill
9300 it with a Multiboot memory map. Adjust a.out loader to calculate size
9301 with the extra space.
9302 (grub_multiboot_load_elf32): Adjust elf32 loader to calculate size
9303 with the extra space.
9304
f8aa0f43 93052008-08-17 Carles Pina i Estany <carles@pina.cat>
9306
9807deb9 9307 * menu/normal.c (run_menu): Add Home and End keys in grub-menu.
f8aa0f43 9308
605f5bb6 93092008-08-17 Felix Zielcke <fzielcke@z-51.de>
9310
9311 * gendistlist.sh: Add *.y, *.tex, *.texi, grub.cfg, README, *.sc,
9312 mdate-sh to the list `find' searches for.
9313 * DISTLIST: Regenerated.
9314
210db6c6 93152008-08-16 Felix Zielcke <fzielcke@z-51.de>
9316
9317 * gendistlist.sh (EXTRA_DISTFILES): Remove gensymlist.sh,
9318 genkernsyms.sh. Add geninit.sh, geninitheader.sh, genkernsyms.sh.in,
48cdbfd4 9319 genmoddep.awk, gensymlist.sh.in.
9320 (DISTDIRS): Add bus, docs, hook, lib.
210db6c6 9321 * DISTLIST: Regenerated.
48cdbfd4 9322 * NEWS: Add cygwin support and change the `os-prober' entry a bit.
210db6c6 9323
1082b929 93242008-08-16 Robert Millan <rmh@aybabtu.com>
9325
9326 * disk/raid.c (grub_raid_init): Handle/report errors set by
9327 grub_device_iterate().
9328 * disk/lvm.c (grub_lvm_init): Likewise.
9329
42ce5170 93302008-08-15 Bean <bean123ch@gmail.com>
9331
9332 * conf/i386-pc.rmk (pkglib_MODULES): Add datetime.mod, date.mod
9333 and datehook.mod.
9334 (datetime_mod_SOURCES): New macro.
9335 (datetime_mod_CFLAGS): Likewise.
9336 (datetime_mod_LDFLAGS): Likewise.
9337 (date_mod_SOURCES): Likewise.
9338 (date_mod_CFLAGS): Likewise.
9339 (date_mod_LDFLAGS): Likewise.
9340 (datehook_mod_SOURCES): Likewise.
9341 (datehook_mod_CFLAGS): Likewise.
9342 (datehook_mod_LDFLAGS): Likewise.
9343
9344 * conf/i386-coreboot.rmk (pkglib_MODULES): Add datetime.mod, date.mod
9345 and datehook.mod.
9346 (datetime_mod_SOURCES): New macro.
9347 (datetime_mod_CFLAGS): Likewise.
9348 (datetime_mod_LDFLAGS): Likewise.
9349 (date_mod_SOURCES): Likewise.
9350 (date_mod_CFLAGS): Likewise.
9351 (date_mod_LDFLAGS): Likewise.
9352 (datehook_mod_SOURCES): Likewise.
9353 (datehook_mod_CFLAGS): Likewise.
9354 (datehook_mod_LDFLAGS): Likewise.
9355
9356 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add datetime.mod, date.mod
9357 and datehook.mod.
9358 (datetime_mod_SOURCES): New macro.
9359 (datetime_mod_CFLAGS): Likewise.
9360 (datetime_mod_LDFLAGS): Likewise.
9361 (date_mod_SOURCES): Likewise.
9362 (date_mod_CFLAGS): Likewise.
9363 (date_mod_LDFLAGS): Likewise.
9364 (datehook_mod_SOURCES): Likewise.
9365 (datehook_mod_CFLAGS): Likewise.
9366 (datehook_mod_LDFLAGS): Likewise.
9367
9368 * conf/i386-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
9369 and datehook.mod.
9370 (datetime_mod_SOURCES): New macro.
9371 (datetime_mod_CFLAGS): Likewise.
9372 (datetime_mod_LDFLAGS): Likewise.
9373 (date_mod_SOURCES): Likewise.
9374 (date_mod_CFLAGS): Likewise.
9375 (date_mod_LDFLAGS): Likewise.
9376 (datehook_mod_SOURCES): Likewise.
9377 (datehook_mod_CFLAGS): Likewise.
9378 (datehook_mod_LDFLAGS): Likewise.
9379
9380 * conf/x86_64-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
9381 and datehook.mod.
9382 (datetime_mod_SOURCES): New macro.
9383 (datetime_mod_CFLAGS): Likewise.
9384 (datetime_mod_LDFLAGS): Likewise.
9385 (date_mod_SOURCES): Likewise.
9386 (date_mod_CFLAGS): Likewise.
9387 (date_mod_LDFLAGS): Likewise.
9388 (datehook_mod_SOURCES): Likewise.
9389 (datehook_mod_CFLAGS): Likewise.
9390 (datehook_mod_LDFLAGS): Likewise.
9391
9392 * kern/env.c (grub_env_insert): Fix a bug in prevp pointer.
9393
9394 * commands/date.c: New file.
9395
9396 * hook/datehook.c: Likewise.
9397
9398 * include/grub/lib/datetime.h: Likewise.
9399
9400 * include/grub/i386/cmos.h: Likewise.
9401
9402 * lib/datetime.c: Likewise.
9403
9404 * lib/i386/datetime.c: Likewise.
9405
9406 * lib/efi/datetime.c: Likewise.
9407
0e9242da 94082008-08-14 Robert Millan <rmh@aybabtu.com>
9409
9410 * conf/common.rmk (bin_UTILITIES): Add `grub-mkelfimage'.
9411 (grub_mkelfimage_SOURCES): New variable.
9412 (util/elf/grub-mkimage.c_DEPENDENCIES): Likewise.
9413
9414 * conf/i386-coreboot.rmk (bin_UTILITIES, grub_mkimage_SOURCES)
9415 (grub_mkimage_LDFLAGS, util/elf/grub-mkimage.c_DEPENDENCIES): Remove.
9416 * conf/powerpc-ieee1275.rmk: Likewise.
9417 * conf/i386-ieee1275.rmk: Likewise.
9418
9419 * kern/ieee1275/init.c: Include `<grub/cpu/kernel.h>'.
9420 * kern/i386/coreboot/init.c: Likewise.
9421
9422 * kern/i386/ieee1275/startup.S: Replace `<grub/machine/kernel.h>'
9423 with `<grub/cpu/kernel.h>'.
9424 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Renamed
9425 to ...
9426 (GRUB_KERNEL_CPU_PREFIX, GRUB_KERNEL_CPU_DATA_END): ... this.
9427 * kern/i386/coreboot/startup.S: Likewise.
9428
9429 * include/grub/powerpc/ieee1275/kernel.h (GRUB_MOD_ALIGN)
9430 (GRUB_MOD_GAP): Remove.
9431 * include/grub/powerpc/kernel.h: New file.
9432 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX)
9433 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
9434 * include/grub/i386/kernel.h: New file.
9435 * include/grub/i386/coreboot/kernel.h (GRUB_MOD_ALIGN)
9436 (GRUB_MOD_GAP, GRUB_KERNEL_MACHINE_PREFIX)
9437 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
9438
9439 * util/ieee1275/grub-install.in (grub_mkimage): Initialize to use
9440 `grub-mkelfimage'.
9441 Use --directory when invoking grub_mkimage.
9442
9443 * util/elf/grub-mkimage.c: Include `<grub/cpu/kernel.h>'.
9444 (add_segments): Replace GRUB_KERNEL_MACHINE_DATA_END and
9445 GRUB_KERNEL_MACHINE_PREFIX with GRUB_KERNEL_CPU_DATA_END
9446 and GRUB_KERNEL_CPU_PREFIX.
9447
b86408f8 94482008-08-14 Felix Zielcke <fzielcke@z-51.de>
9449
d5e619ca 9450 * include/grub/err.h (grub_err_printf): New function prototype.
9451 * util/misc.c (grub_err_printf): New function.
9452 * kern/misc.c [! GRUB_UTIL] (grub_err_printf): New alias for
9453 grub_printf.
9454 * kern/err.c (grub_print_error): Use grub_err_printf.
b86408f8 9455
7161f0e0 94562008-08-13 Robert Millan <rmh@aybabtu.com>
9457
9458 * docs/grub.cfg: Remove `/dev/' prefix in GNU/Hurd boot entry.
9459
a1967522 94602008-08-13 Robert Millan <rmh@aybabtu.com>
9461
9462 * docs/grub.cfg: Use the native device name for the example GNU/Hurd
9463 boot entry.
9464
371458b5 94652008-08-12 Robert Millan <rmh@aybabtu.com>
9466
9467 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Move part
9468 of the relocation code from here ...
9469 (grub_multiboot): ... to here.
9470 (forward_relocator, backward_relocator): Move from here ...
9471 * kern/i386/loader.S (grub_multiboot_forward_relocator)
9472 (grub_multiboot_backward_relocator): ... to here.
9473 (grub_multiboot_real_boot): Use %edx for entry offset. Put Multiboot
9474 magic in %eax. Use %ebp for jumping (so %edx is not trashed).
9475 * include/grub/i386/loader.h (grub_multiboot_forward_relocator)
9476 (grub_multiboot_forward_relocator_end)
9477 (grub_multiboot_backward_relocator)
9478 (grub_multiboot_backward_relocator_end): New variables.
9479
05f9452b 94802008-08-12 Bean <bean123ch@gmail.com>
9481
9482 * disk/raid.c (grub_raid_read): Fix a bug in raid0 code.
9483
20024ab0 94842008-08-11 Robert Millan <rmh@aybabtu.com>
9485
9486 * kern/i386/linuxbios/startup.S: Move from here ...
9487 * kern/i386/coreboot/startup.S: ... to here.
9488
9489 * kern/i386/linuxbios/init.c: Move from here ...
9490 * kern/i386/coreboot/init.c: ... to here.
9491
9492 * kern/i386/linuxbios/table.c: Move from here ...
9493 * kern/i386/coreboot/mmap.c: ... to here.
9494
9495 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Update moved files.
9496
e352e9cd 94972008-08-11 Robert Millan <rmh@aybabtu.com>
9498
9499 * kern/device.c (grub_device_open): Do not handle grub_disk_open()
9500 errors. Leave it to the upper layer to handle them.
9501
2d05bc6a 95022008-08-09 Christian Franke <franke@computer.org>
9503
9504 * Makefile.in: Add `target_os' and `enable_grub_pe2elf'.
9505 * conf/common.rmk: Install `grub-pe2elf' only if requested.
9506 Install `grub.d/10_windows' only on Cygwin.
9507 * configure.ac: Add subst of `target_os'.
9508 Check `target_os' also before setting TARGET_OBJ2ELF.
9509 Add `--enable-grub-pe2elf'.
9510
042bd419 95112008-08-08 Robert Millan <rmh@aybabtu.com>
9512
9513 * kern/disk.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
9514 (grub_last_time): Change type to grub_uint64_t.
9515 (grub_disk_open): Migrate code from to using grub_get_time_ms().
9516 (grub_disk_close): Likewise.
9517
9518 * normal/menu.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
9519 (run_menu): Migrate code from to using grub_get_time_ms().
9520
9521 * util/misc.c (grub_get_time_ms): New function.
9522
7f280db5 95232008-08-08 Marco Gerards <marco@gnu.org>
9524
9525 * disk/ata.c (grub_ata_regget): Change return type to
9526 `grub_uint8_t'.
9527 (grub_ata_regget2): Likewise.
9528 (grub_ata_wait_status): New function.
9529 (grub_ata_wait_busy): Removed function, updated all users to use
9530 `grub_ata_wait_status'.
9531 (grub_ata_wait_drq): Likewise.
9532 (grub_ata_cmd): New function.
9533 (grub_ata_pio_read): Change return type to `grub_uint8_t'. Add
9534 error handling.
9535 (grub_ata_pio_write): Add error handling.
9536 (grub_atapi_identify): Likewise.
9537 (grub_atapi_packet): Use `grub_ata_cmd' and improve error
9538 handling.
9539 (grub_ata_identify): Use `grub_ata_cmd' and improve error
9540 handling. Actually use the detected registers. Reorder the
9541 detection logic such that it is easier to read.
9542 (grub_ata_pciinit): Do not assign the same ID to each controller.
9543 (grub_ata_setaddress): Use `grub_ata_cmd' and improve error
9544 handling.
9545 (grub_atapi_readsector): Check the result of `grub_ata_pio_read'.
9546
9547 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TIMEOUT'.
9548
1fbc5e66 95492008-08-08 Marco Gerards <marco@gnu.org>
9550
9551 * NEWS: Update.
9552
819ce6c0 95532008-08-07 Bean <bean123ch@gmail.com>
9554
9555 * include/grub/x86_64/pci.h: New file.
9556
5c41d44d 95572008-08-07 Christian Franke <franke@computer.org>
9558
9559 * kern/i386/pit.c (TIMER2_SPEAKER): New define.
9560 (TIMER2_GATE): Likewise.
9561 (grub_pit_wait): Add enable/disable of the timer2 gate
9562 bit of port 0x61. This fixes a possible infinite loop.
9563
5ebc275d 95642008-08-07 Bean <bean123ch@gmail.com>
9565
9566 * conf/x86_64-efi.rmk (kernel_mod_SOURCES): Add kern/time.c,
9567 kern/i386/tsc.c and kern/i386/pit.c.
9568
9569 * include/grub/i386/tsc.h (grub_cpu_is_cpuid_supported): Handle
9570 x86_64 platform.
9571
9572 * kern/i386/efi/init.c: Replace <grub/cpu/tsc.h> with
9573 <grub/i386/tsc.h>.
9574
9575 * kern/i386/pit.c: Replace <grub/cpu/io.h> with <grub/i386/io.h>.
9576
e383b3d0 95772008-08-07 Bean <bean123ch@gmail.com>
9578
9579 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add kern/time.c.
9580
9581 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add kern/time.c,
9582
9583 * include/grub/i386/pit.h: Use macro KERNEL_CPU_PIT_HEADER to avoid
9584 multiple inclusion. Add #include <grub/types.h>.
9585
1cbb58ac 95862008-08-06 Christian Franke <franke@computer.org>
9587
9588 * conf/common.rmk: Build and install `10_windows'.
9589 * util/grub.d/10_windows.in: New script.
9590
337f5a1e 95912008-08-06 Pavel Roskin <proski@gnu.org>
9592
9593 * kern/i386/pit.c: Include `<grub/i386/pit.h>'.
9594
057bc4ac 95952008-08-06 Robert Millan <rmh@aybabtu.com>
9596
9597 * conf/i386-coreboot.rmk (kernel_elf_ASFLAGS): New variable.
9598 * kern/i386/tsc.c: Include `<grub/i386/pit.h>'.
9599
2b99f123 96002008-08-06 Bean <bean123ch@gmail.com>
9601
9602 * fs/i386/pc/pxe.c (grub_pxe_data): New member block_size.
9603 (grub_pxefs_fs_int): Remove dummy definition.
9604 (grub_pxefs_open): Use data->block_size to store the current block
9605 size setting.
9606 (grub_pxefs_read): Use block size stored in data->block_size. As the
9607 value of grub_pxe_blksize can be changed after the file is opened.
9608
9f0234cb 96092008-08-06 Bean <bean123ch@gmail.com>
9610
9611 * fs/i386/pc/pxe.c (curr_file): new variable.
9612 (grub_pxefs_open): Simply the handling of pxe file system. Don't
9613 require the dummy internal file system anymore.
9614 (grub_pxefs_read): Removed.
9615 (grub_pxefs_close): Likewise.
9616 (grub_pxefs_fs_int): Likewise.
9617 (grub_pxefs_read_int): Renamed to grub_pxefs_read. Reinitialize tftp
9618 connection when we switch file.
9619 (grub_pxefs_close_int): Renamed to grub_pxefs_close.
9620
a55d42e0 96212008-08-06 Robert Millan <rmh@aybabtu.com>
9622
9623 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `reboot.mod' and
9624 `halt.mod'.
9625 (reboot_mod_SOURCES, reboot_mod_CFLAGS, reboot_mod_LDFLAGS)
9626 (halt_mod_SOURCES, halt_mod_CFLAGS, halt_mod_LDFLAGS): New variables.
9627
9628 * kern/i386/halt.c: New file.
9629 * kern/i386/reboot.c: Likewise.
9630 * include/grub/i386/reboot.h: Likewise.
9631 * include/grub/i386/halt.h: Likewise.
9632
9633 * commands/halt.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]:
9634 Include `<grub/cpu/halt.h>'.
9635 * commands/reboot.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]
9636 [! GRUB_MACHINE_PCBIOS]: Include `<grub/cpu/reboot.h>'.
9637
9638 * term/i386/pc/at_keyboard.c: Include `<grub/cpu/at_keyboard.h>'.
9639 (SHIFT_L, SHIFT_R, CTRL, ALT, CAPS_LOCK, KEYBOARD_REG_DATA)
9640 (KEYBOARD_REG_STATUS, KEYBOARD_COMMAND_ISREADY, KEYBOARD_COMMAND_READ)
9641 (KEYBOARD_COMMAND_WRITE, KEYBOARD_COMMAND_REBOOT)
9642 (KEYBOARD_SCANCODE_SET1, KEYBOARD_ISMAKE, KEYBOARD_ISREADY)
9643 (KEYBOARD_SCANCODE, OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): Move
9644 from here ...
9645 * include/grub/i386/at_keyboard.h: ... to here.
9646
24371d26 96472008-08-05 Robert Millan <rmh@aybabtu.com>
9648
9649 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pit.c'.
9650 * conf/i386-efi.rmk (kernel_mod_SOURCES): Likewise.
9651 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Likewise. Also add
9652 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
9653 `kern/generic/millisleep.c'.
9654
9655 * kern/i386/tsc.c (calibrate_tsc): Rewrite using grub_pit_wait()
9656 instead of grub_get_rtc().
9657 (grub_tsc_init): Initialize `tsc_boot_time'.
9658
9659 * kern/i386/linuxbios/init.c (grub_millisleep): Remove stub.
9660 (grub_machine_init): Use grub_tsc_init() rather than
9661 installing an RTC-based handler via grub_install_get_time_ms().
9662
9663 * kern/i386/pit.c: New file.
9664 * include/grub/i386/pit.h: Likewise.
9665
9e7007b3 96662008-08-05 Bean <bean123ch@gmail.com>
9667
9668 * boot/i386/pc/pxeboot.S (_start): Use drive number 0x7F for pxe.
9669
9670 * conf/i386-pc.rmk (kernel_img_HEADERS): Add machine/pxe.h.
9671 (pkglib_MODULES): Add pxe.mod and pxecmd.mod.
9672 (pxe_mod_SOURCES): New macro.
9673 (pxe_mod_CFLAGS): Likewise.
9674 (pxe_mod_LDFLAGS): Likewise.
9675 (pxecmd_mod_SOURCES): Likewise.
9676 (pxecmd_mod_CFLAGS): Likewise.
9677 (pxecmd_mod_LDFLAGS): Likewise.
9678
9679 * kern/i386/pc/startup.S (grub_pxe_scan): New function.
9680 (grub_pxe_call): Likewise.
9681
9682 * include/grub/disk.h (grub_disk_dev_id): Add GRUB_DISK_DEVICE_PXE_ID.
9683
9684 * commands/i386/pc/pxecmd.c: New file.
9685
9f0234cb 9686 * fs/i386/pc/pxe.c: Likewise.
9e7007b3 9687
9688 * include/grub/i386/pc/pxe.h: Likewise.
9689
6977d49f 96902008-08-05 Bean <bean123ch@gmail.com>
9691
9692 * util/console.c (grub_console_cur_color): New variable.
9693 (grub_console_standard_color): Likewise.
9694 (grub_console_normal_color): Likewise.
9695 (grub_console_highlight_color): Likewise.
9696 (color_map): Likewise.
9697 (use_color): Likewise.
9698 (NUM_COLORS): New macro.
9699 (grub_ncurses_setcolorstate): Handle color properly.
9700 (grub_ncurses_setcolor): Don't change color here, just remember the
9701 settings, color will be set in grub_ncurses_setcolorstate.
9702 (grub_ncurses_getcolor): New function.
9703 (grub_ncurses_init): Initialize color pairs.
9704 (grub_ncurses_term): New member grub_ncurses_getcolor.
9705
9c2ff3ee 97062008-08-05 Colin D Bennett <colin@gibibit.com>
337f5a1e 9707
9c2ff3ee 9708 High resolution timer support. Implemented for x86 CPUs using TSC.
9709 Extracted generic grub_millisleep() so it's linked in only as needed.
9710 This requires a Pentium compatible CPU; if the RDTSC instruction is
9711 not supported, then it falls back on the generic grub_get_time_ms()
9712 implementation that uses the machine's RTC.
9713
9714 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/time.c',
9715 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
9716 `kern/generic/millisleep.c'.
9717
9718 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add `kern/i386/tsc.c',
9719 `kern/generic/rtc_get_time_ms.c' and `kern/generic/millisleep.c'.
9720
9721 * conf/x86_64-efi.rml (kernel_mod_SOURCES): Add
9722 `kern/generic/millisleep.c' and `kern/generic/rtc_get_time_ms.c'.
9723
9724 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
9725
9726 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
9727 `kern/generic/millisleep.c'.
9728
9729 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
9730
9731 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Add `kern/time.c'.
9732
9733 * kern/generic/rtc_get_time_ms.c: New file.
9734
9735 * kern/generic/millisleep.c: New file.
337f5a1e 9736
9c2ff3ee 9737 * kern/misc.c: Don't include
9738 <kern/time.h> anymore.
9739 (grub_millisleep_generic): Removed.
9740
9741 * commands/sleep.c (grub_interruptible_millisleep): Uses
9742 grub_get_time_ms() instead of grub_get_rtc().
9743
9744 * include/grub/i386/tsc.h (grub_get_tsc): New file. New inline
9745 function.
9746 (grub_cpu_is_cpuid_supported): New inline function.
9747 (grub_cpu_is_tsc_supported): New inline function.
9748 (grub_tsc_init): New function prototype.
9749 (grub_tsc_get_time_ms): New function prototype.
9750
9751 * kern/i386/tsc.c (grub_get_time_ms): New file.
9752
9753 * include/grub/time.h: Include <grub/types.h.
9754 (grub_millisleep_generic): Removed.
9755 (grub_get_time_ms): New prototype.
9756 (grub_install_get_time_ms): New prototype.
9757 (grub_rtc_get_time_ms): New prototype.
9758
9759 * kern/time.c (grub_get_time_ms): New function.
9760 (grub_install_get_time_ms): New function.
9761
9762 * kern/i386/efi/init.c: Include <grub/cpu/tsc.h>. Don't include
9763 <grub/time.h> anymore.
9764 (grub_millisleep): Removed.
9765 (grub_machine_init): Call grub_tsc_init.
9766
9767 * kern/i386/linuxbios/init.c (grub_machine_init): Install the RTC
9768 get_time_ms() implementation.
9769
9770 * kern/sparc64/ieee1275/init.c (grub_millisleep): Removed.
9771 (ieee1275_get_time_ms): New function.
9772 (grub_machine_init): Install get_time_ms() implementation.
9773
9774 * kern/i386/pc/init.c: Include <grub/cpu/tsc.h>.
9775 (grub_machine_init): Call grub_tsc_init().
9776 (grub_millisleep): Removed.
bf06a93f 9777
9c2ff3ee 9778 * kern/ieee1275/init.c (grub_millisleep): Removed.
9779 (grub_machine_init): Install ieee1275_get_time_ms()
9780 implementation.
9781 (ieee1275_get_time_ms): New function.
9782 (grub_get_rtc): Now calls ieee1275_get_time_ms(), which does the
9783 real work.
9784
9ec92aaf 97852008-08-05 Marco Gerards <marco@gnu.org>
9786
9787 * disk/ata.c: Include <grub/pci.h>.
9788 (enum grub_ata_commands): Add `GRUB_ATA_CMD_EXEC_DEV_DIAGNOSTICS'.
9789 (grub_ata_initialize): Rewritten.
9790 (grub_ata_device_initialize): New function.
9791
8d23f507 97922008-08-04 Pavel Roskin <proski@gnu.org>
9793
9794 * kern/main.c: Include grub/mm.h.
9795
5e15ee3d 97962008-08-04 Robert Millan <rmh@aybabtu.com>
9797
9798 * conf/i386-coreboot.rmk (COMMON_ASFLAGS, COMMON_CFLAGS)
9799 (COMMON_LDFLAGS): Harmonize with i386-pc version (fixes a code
9800 corruption problem).
9801
a9053f8f 98022008-08-04 Robert Millan <rmh@aybabtu.com>
9803
9804 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Fix misc
9805 warnings introduced in my last commit.
9806
dd19c7d7 98072008-08-03 Robert Millan <rmh@aybabtu.com>
9808
9809 Make PCI available on all i386 architectures.
9810
9811 * include/grub/i386/pc/pci.h: Move from here ...
9812 * include/grub/i386/pci.h: ... to here.
9813
9814 * include/grub/i386/pc/pci.h: Remove.
9815 * include/grub/i386/efi/pci.h: Remove.
9816 * include/grub/x86_64/efi/pci.h: Remove.
9817
9818 * include/grub/pci.h: Replace `<grub/machine/pci.h>' with
9819 `<grub/cpu/pci.h>'.
9820
9821 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `pci' and `lspci'.
9822 (pci_mod_SOURCES, pci_mod_CFLAGS, pci_mod_LDFLAGS, lspci_mod_SOURCES)
9823 (lspci_mod_CFLAGS, lspci_mod_LDFLAGS): New variables.
9824
9825 * conf/i386-ieee1275.rmk: Likewise.
9826
e14a6184 98272008-08-03 Robert Millan <rmh@aybabtu.com>
9828
9829 * term/i386/pc/vga_text.c (CRTC_CURSOR_DISABLE): New macro.
9830 (grub_console_setcursor): Make it possible to set cursor off.
9831
52768e37 98322008-08-03 Robert Millan <rmh@aybabtu.com>
9833
9834 * util/grub.d/00_header.in: Be platform-agnostic. Probe for existence
9835 of modules instead of assuming which platform provides what.
9836 * util/update-grub.in: Likewise.
9837
2d52f57f 98382008-08-03 Robert Millan <rmh@aybabtu.com>
9839
9840 * kern/i386/pc/init.c (make_install_device): Check for `grub_prefix'
9841 instead of `grub_install_dos_part' to determine whether a drive needs
9842 to be prepended to prefix (`grub_install_dos_part' is not reliable,
825aa57a 9843 because it can be overridden when loading GRUB via Multiboot).
2d52f57f 9844
2a5cd121 98452008-08-02 Robert Millan <rmh@aybabtu.com>
9846
9847 * util/i386/pc/grub-install.in: Remove trailing slash from prefix.
9848
93808428 98492008-08-02 Robert Millan <rmh@aybabtu.com>
9850
9851 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Add a pair
9852 of informational grub_dprintf() calls.
9853
3bd0a12a 98542008-08-02 Robert Millan <rmh@aybabtu.com>
9855
9856 * disk/memdisk.c (memdisk_size): Don't initialize.
9857 (GRUB_MOD_INIT(memdisk)): Find memdisk using grub_module_iterate().
9858
9859 * include/grub/i386/pc/kernel.h
9860 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): Remove macro.
9861 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Shift.
9862 (grub_memdisk_image_size, grub_arch_memdisk_addr)
9863 (grub_arch_memdisk_size): Remove.
9864
9865 * include/grub/kernel.h (struct grub_module_header): Remove `offset'
9866 field (was only used to transfer a constant). Add `type' field to
9867 support multiple module types.
9868 (grub_module_iterate): New function.
9869
9870 * kern/device.c (grub_device_open): Do not hide error messages
9871 when grub_disk_open() fails. Use grub_print_error() instead.
9872
9873 * kern/i386/pc/init.c (grub_arch_modules_addr)
9874 (grub_arch_memdisk_size): Remove functions.
9875 (grub_arch_modules_addr): Return the module address in high memory
9876 (now that it isn't copied anymore).
9877
9878 * kern/i386/pc/startup.S (grub_memdisk_image_size): Remove variable.
9879 (codestart): Don't add grub_memdisk_image_size to %ecx in LZMA
9880 decompression routine (grub_total_module_size already includes that
9881 now). Don't copy modules back to low memory.
9882
9883 * kern/main.c: Include `<grub/mm.h>'.
9884 (grub_load_modules): Split out (and use) ...
9885 (grub_module_iterate): ... this function, which iterates through
9886 module objects and runs a hook.
9887 Comment out grub_mm_init_region() call, as it would cause non-ELF
9888 modules to be overwritten.
9889
9890 * util/i386/pc/grub-mkimage.c (generate_image): Instead of appending
9891 the memdisk image in its own region, make it part of the module list.
9892 * util/elf/grub-mkimage.c (options): Add "memdisk"|'m' option.
9893 (main): Parse --memdisk|-m option, and pass user-provided path as
9894 parameter to generate_image().
9895 (add_segments): Pass `memdisk_path' down to load_modules().
9896 (load_modules): Embed memdisk image in module section when requested.
9897 * util/i386/efi/grub-mkimage.c (make_mods_section): Initialize
9898 `header.type' instead of `header.offset'.
9899
9900 * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add `memdisk.mod'.
9901 (memdisk_mod_SOURCES, memdisk_mod_CFLAGS)
9902 (memdisk_mod_LDFLAGS): New variables.
9903 * conf/i386-coreboot.rmk: Likewise.
9904 * conf/i386-ieee1275.rmk: Likewise.
9905
a927cc73 99062008-08-02 Robert Millan <rmh@aybabtu.com>
9907
9908 * loader/i386/pc/multiboot.c (playground, forward_relocator)
9909 (backward_relocator): New variables. Used to allocate and relocate
9910 the payload, respectively.
9911 (grub_multiboot_load_elf32): Load into heap instead of requested
825aa57a 9912 address, install the appropriate relocator code in each bound of
a927cc73 9913 the payload, and set the entry point such that
9914 grub_multiboot_real_boot() will jump to one of them.
9915
9916 * kern/i386/loader.S (grub_multiboot_payload_size)
9917 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
9918 (grub_multiboot_payload_entry_offset): New variables.
9919 (grub_multiboot_real_boot): Set cpu context to what the relocator
9920 expects, and jump to the relocator instead of the payload.
9921
9922 * include/grub/i386/loader.h (grub_multiboot_payload_size)
9923 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
9924 (grub_multiboot_payload_entry_offset): Export.
9925
b15d8a0c 99262008-08-01 Bean <bean123ch@gmail.com>
9927
9928 * normal/menu_entry.c (editor_getline): Don't return the original
9929 string as result, as it will be released by lexer once it has done
9930 using it.
9931
cdfb3d22 99322008-08-01 Robert Millan <rmh@aybabtu.com>
9933
9934 * util/grub.d/10_linux.in: Use prepare_grub_to_access_device() from
9935 within menuentries, not before them.
9936 util/grub.d/10_hurd.in: Likewise.
9937
9175e93d 99382008-08-01 Bean <bean123ch@gmail.com>
9939
9940 * conf/common.rmk (pkglib_MODULES): Add bufio.mod.
9941 (bufio_mod_SOURCES): New macro.
9942 (bufio_mod_CFLAGS): Likewise.
9943 (bufio_mod_LDFLAGS): Likewise.
9944
9945 * include/grub/bufio.h: New file.
9946
9947 * io/bufio.c: Likewise.
9948
9949 * video/png.c: Replace <grub/file.h> with <grub/bufio.h>.
9950 (grub_video_reader_png): Use grub_buffile_open to open file.
9951
9952 * video/jpeg.c: Replace <grub/file.h> with <grub/bufio.h>.
9953 (grub_video_reader_jpeg): Use grub_buffile_open to open file.
9954
9955 * video/tga.c: Replace <grub/file.h> with <grub/bufio.h>.
9956 (grub_video_reader_tga): Use grub_buffile_open to open file.
9957
9958 * font/manager.c: Include <grub/bufio.h>.
9959 (add_font): Use grub_buffile_open to open file.
9960
3d8383e7 99612008-07-31 Robert Millan <rmh@aybabtu.com>
9962
9963 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): When loading
9964 ELF segments, use a macro for arbitrarily accessing any of them instead
9965 of preparing a pointer that allows access to one at a time.
9966 (grub_multiboot_load_elf64): Likewise.
9967
16e641b6 99682008-07-31 Bean <bean123ch@gmail.com>
9969
9970 * boot/i386/pc/lnxboot.S (real_code_2): Replace 0x50 with
9971 GRUB_KERNEL_MACHINE_DATA_END.
9972
59198b72 99732008-07-30 Robert Millan <rmh@aybabtu.com>
9974
9975 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_DATA_END):
9976 Increase from 0x50 to 0x60.
9977 * util/i386/pc/grub-install.in: Detect cross-disk installs, and
9978 use UUIDs to identify the root drive for them. If that's not
9979 possible, abort.
9980 * util/i386/pc/grub-setup.c (setup): Do not special-case, or even
9981 check, for cross-disk installs.
9982
ae88bca3 99832008-07-30 Robert Millan <rmh@aybabtu.com>
9984
9985 * kern/ieee1275/init.c (grub_machine_set_prefix): If `grub_prefix'
9986 is non-empty, use it to set the `prefix' environment variable instead
9987 of the usual approach.
9988 * kern/i386/linuxbios/init.c (make_install_device): Remove function.
9989 (grub_machine_set_prefix): Use `grub_prefix' to set the `prefix'
9990 environment variable instead of dummy make_install_device().
9991
9992 * kern/i386/ieee1275/startup.S: Include `<grub/machine/kernel.h>'.
9993 (start): Insert a data section, with `grub_prefix' variable.
825aa57a 9994 * kern/i386/linuxbios/startup.S: Likewise.
ae88bca3 9995
9996 * include/grub/powerpc/ieee1275/kernel.h [!ASM_FILE] (grub_prefix):
9997 New variable reference.
9998 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX):
9999 New macro. Defines offset of `grub_prefix' within startup.S (relative
10000 to `start').
10001 (GRUB_KERNEL_MACHINE_DATA_END): New macro. Defines the end of data
10002 section within startup.S (relative to `start').
10003 * include/grub/i386/coreboot/kernel.h: Likewise.
10004
10005 * util/elf/grub-mkimage.c (add_segments): Receive `prefix' parameter.
10006 Overwrite grub_prefix with its contents, at the beginning of the
10007 first segment.
10008 (main): Understand -p|--prefix.
10009
14f41dd1 100102008-07-30 Robert Millan <rmh@aybabtu.com>
10011
10012 * util/grub.d/10_hurd.in: Source ${libdir}/grub/update-grub_lib.
10013
4ca049a3 100142008-07-30 Robert Millan <rmh@aybabtu.com>
10015
10016 * term/i386/pc/vga_text.c (grub_console_cls): Use
10017 grub_console_gotoxy() to go back to beginning of the screen.
10018 Found by Patrick Georgi <patrick.georgi@coresystems.de>
10019
2921d337 100202008-07-29 Christian Franke <franke@computer.org>
10021
10022 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
10023 Add conversion of emulated mount points on Cygwin.
10024
b609876d 100252008-07-29 Christian Franke <franke@computer.org>
10026
10027 * util/update-grub.in: Add a check for admin
10028 group on Cygwin.
10029 Remove old `grub.cfg.new' before creation.
10030 Add `-f' to `mv' to handle the different filesystem
10031 semantics of Windows.
10032
e93e4679 100332008-07-29 Bean <bean123ch@gmail.com>
10034
10035 * normal/main.c (get_line): Fix buffer overflow bug.
10036
41694fd0 100372008-07-28 Robert Millan <rmh@aybabtu.com>
10038
10039 * partmap/apple.c (GRUB_APPLE_HEADER_MAGIC): New macro.
10040 (struct grub_apple_header): New struct. Describes the layout of
10041 the partmap header.
10042 (apple_partition_map_iterate): Check the header magic as well as the
10043 partition magic (which was already being checked).
10044
cfd0b4e6 100452008-07-28 Pavel Roskin <proski@gnu.org>
10046
10047 * genmk.rb: Add a warning to the beginning of the output that
10048 it's a generated file and should not be edited.
10049
93cce016 100502008-07-28 Robert Millan <rmh@aybabtu.com>
10051
10052 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
10053 with the same number are found, just use issue a warning with
10054 grub_dprintf(), as this error has been reported to be non-fatal.
c298def0 10055
cd1df915 100562008-07-27 Robert Millan <rmh@aybabtu.com>
10057
10058 * disk/ata.c (grub_ata_dumpinfo): Use grub_dprintf() for debugging
10059 information.
10060
b70a8427 100612008-07-27 Bean <bean123ch@gmail.com>
10062
10063 * fs/fat.c (GRUB_FAT_MAXFILE): New constant.
10064 (grub_fat_find_dir): Ignore case when comparing filename.
10065
8f5e379f 100662008-07-27 Bean <bean123ch@gmail.com>
10067
10068 * fs/xfs.c (grub_xfs_dir_header): Change field i8count back to
10069 smallino, as it's more descriptive, and i8count can be confused with
10070 the other field count.
10071 (grub_xfs_iterate_dir): Adjust grub_xfs_dir_entry pointer for small
10072 inode type.
10073
a85cd5a0 100742008-07-27 Bean <bean123ch@gmail.com>
10075
10076 * commands/crc.c: New file.
10077
10078 * lib/crc.c: Likewise.
10079
10080 * include/grub/lib/crc.h: Likewise.
10081
10082 * util/grub-fstest.c: grub/hexdump.h => grub/lib/hexdump.h.
10083
10084 * commands/hexdump.c: grub/hexdump.h => grub/lib/hexdump.h.
10085 (hexdump): Move this function to ...
10086
10087 * lib/hexdump.c: ... here.
10088
10089 * include/grub/hexdump.h: Renamed to ...
10090
10091 * include/grub/lib/hexdump.h: ... this.
10092
10093 * commands/loadenv.c: grub/envblk.h => grub/lib/envblk.h
10094
10095 * util/grub-editenv.c: Likewise.
10096
10097 * include/envblk.h: Renamed to ...
10098
10099 * include/lib/envblk.h: ... this.
10100
10101 * util/envblk.c: Renamed to ...
10102
10103 * lib/envblk.c: ... this.
10104
10105 * conf/common.rmk (grub_fstest_SOURCES): commands/hexdump.c =>
10106 lib/hexdump.c.
10107 (grub_editenv_SOURCES): util/envblk.c => lib/envblk.c
10108 (pkglib_MODULES): Add crc.mod.
10109 (hexdump_mod_SOURCES): Add lib/hexdump.c.
10110 (loadenv_mod_SOURCES): util/envblk.c => lib/envblk.c.
10111 (crc_mod_SOURCES): New macro.
10112 (crc_mod_CFLAGS): Likewise.
10113 (crc_mod_LDFLAGS): Likewise.
10114
10115 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add lib/hexdump.c.
10116
10117 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
10118
10119 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
10120
10121 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
10122
10123 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
10124
c298def0 101252008-07-27 Felix Zielcke <fzielcke@z-51.de>
8749e9e5 10126
10127 * commands/help.c: Include <grub/term.h>.
10128 (TERM_WIDTH): Removed. Updated all users.
10129
cc349fb3 101302008-07-27 Pavel Roskin <proski@gnu.org>
10131
10132 * util/getroot.c (find_root_device): Rephrase a comment to avoid
10133 spurious warnings about a comment within a comment.
10134
9051607e 101352008-07-25 Robert Millan <rmh@aybabtu.com>
10136
10137 * util/getroot.c (find_root_device): Skip devices that match
10138 /dev/dm-[0-9]. This lets the real device be found for any type of
10139 abstraction (LVM, EVMS, RAID..).
10140 (grub_guess_root_device): Do not traverse /dev/mapper (for LVM)
10141 and /dev/evms (for EVMS) before traversing /dev. If a /dev/dm-[0-9]
10142 device is found first, find_root_device() will now skip it.
10143
01453bfc 101442008-07-24 Pavel Roskin <proski@gnu.org>
10145
10146 * include/grub/types.h: Use __builtin_bswap32() and
10147 __builtin_bswap64() with gcc 4.3 and newer.
10148
6af9849f 101492008-07-24 Christian Franke <franke@computer.org>
10150
3a0fa256 10151 * util/i386/pc/grub-install.in: If `--debug' is specified,
10152 pass `--verbose' to grub-setup.
10153 Abort script if make_system_path_relative_to_its_root() fails.
10154
7810e747 101552008-07-24 Bean <bean123ch@gmail.com>
10156
10157 * configure.ac: Fixed a bug caused by the previous cygwin patch,
10158 variable `target_platform' should be `platform'.
10159
42290e17 101602008-07-24 Bean <bean123ch@gmail.com>
10161
51cc5193 10162 * video/reader/png.c (DEFLATE_HLIT_MAX): Change value.
42290e17 10163 (grub_png_init_fixed_block): New function.
10164 (grub_png_decode_image_data): Handle fixed huffman code compression.
10165
2a8a80e4 101662008-07-24 Bean <bean123ch@gmail.com>
10167
10168 * common.rmk (bin_UTILITIES): Add grub-pe2elf.
10169 (grub_pe2elf_SOURCES): New macro.
10170 (CLEANFILES): Add grub-pe2elf.
10171
10172 * include/grub/efi/pe32.h (GRUB_PE32_SCN_ALIGN_1BYTES): New constant.
10173 (GRUB_PE32_SCN_ALIGN_2BYTES): Likewise.
10174 (GRUB_PE32_SCN_ALIGN_4BYTES): Likewise.
10175 (GRUB_PE32_SCN_ALIGN_8BYTES): Likewise.
10176 (GRUB_PE32_SCN_ALIGN_16BYTES): Likewise.
10177 (GRUB_PE32_SCN_ALIGN_32BYTES): Likewise.
10178 (GRUB_PE32_SCN_ALIGN_64BYTES): Likewise.
10179 (GRUB_PE32_SCN_ALIGN_SHIFT): Likewise.
10180 (GRUB_PE32_SCN_ALIGN_MASK): Likewise.
10181 (GRUB_PE32_SYM_CLASS_EXTERNAL): Likewise.
10182 (GRUB_PE32_SYM_CLASS_STATIC): Likewise.
10183 (GRUB_PE32_SYM_CLASS_FILE): Likewise.
10184 (GRUB_PE32_DT_FUNCTION): Likewise.
10185 (GRUB_PE32_REL_I386_DIR32): Likewise.
10186 (GRUB_PE32_REL_I386_REL32): Likewise.
10187 (grub_pe32_symbol): New structure.
10188 (grub_pe32_reloc): Likewise.
10189
10190 * util/grub-pe2elf.c: New file.
10191
10192 * configure.ac: Set TARGET_OBJ2ELF if host os is cygwin. Don't test for
10193 start symbol in non pc platform.
10194
10195 * genmk.rb: Use TARGET_OBJ2ELF to convert native object format to elf.
10196
10197 The following patches are from Christian Franke.
10198
10199 * include/grub/dl.h: Remove .previous, gas supports this only
10200 for ELF format.
10201
10202 * include/grub/symbol.h [__CYGWIN__] (#define FUNCTION/VARIABLE):
10203 Remove .type, gas supports this only for ELF format.
10204
10205 * kern/dl.c (grub_dl_resolve_dependencies): Add check for trailing
10206 nullbytes in symbol table. This fixes an infinite loop if table is
10207 zero filled.
10208
10209 * Makefile.in: Add autoconf replacements TARGET_IMG_LDSCRIPT,
10210 TARGET_IMG_LDFLAGS and EXEEXT.
10211
10212 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Replace -Wl,-N by
10213 TARGET_IMG_LDFLAGS_AC.
10214 (grub_CHECK_STACK_ARG_PROBE): New function.
10215
10216 * conf/i386-pc.rmk: Replace -Wl,-N by TARGET_IMG_LDFLAGS.
10217
10218 * conf/i386-pc-cygwin-ld-img.sc: New linker script.
10219
10220 * configure.ac: Add check for linker script "conf/${target}-img-ld.c"
10221 to set TARGET_IMG_LD* accordingly.
10222 Add check for Cygwin to set TARGET_MOD_OBJCOPY accordingly.
10223 Add call to grub_CHECK_STACK_ARG_PROBE.
10224 Use TARGET_IMG_LDFLAGS to check start, bss_start, end symbols.
10225
10226 * genkernsyms.sh.in: Handle HAVE_ASM_USCORE case.
10227
10228 * genmk.rb: Add EXEEXT to CLEANFILES.
10229
12ccdb75 102302008-07-23 Robert Millan <rmh@aybabtu.com>
10231
10232 * Makefile.in (UNICODE_ARROWS, UNICODE_LINES): New variables (they
10233 define the codes for arrows and lines used for the menu).
10234 (ascii.pff): Generate fonts for $(UNICODE_ARROWS) and $(UNICODE_LINES)
10235 as well.
10236
10237 * util/update-grub_lib.in (font_path): Prefer ascii.pff over complete
10238 fonts, because the latter are too slow.
10239
18eeaf04 102402008-07-21 Bean <bean123ch@gmail.com>
10241
10242 * kern/i386/pc/startup.S (gate_a20_try_bios): Change test order for
10243 a20. Run keyboard test last, as it will cause macbook to halt.
10244
b095e2ad 102452008-07-18 Pavel Roskin <proski@gnu.org>
10246
10247 * kern/dl.c: Go back to using GRUB_CPU_SIZEOF_VOID_P. We cannot
10248 load foreign architecture modules correctly anyway. Keep
10249 support for loading host architecture modules, whether we
10250 compile them or not.
10251
737feb35 102522008-07-17 Pavel Roskin <proski@gnu.org>
10253
3f4ce737 10254 * configure.ac: Use -m32 or -m64 regardless of whether we had to
10255 change target_cpu. The compiler default can mismatch target_cpu
10256 in any case.
10257
4ad2d049 10258 * disk/efi/efidisk.c: Fix format warnings on x86_64.
10259 * kern/efi/efi.c: Likewise.
10260
f6130a12 10261 * aclocal.m4 (grub_PROG_TARGET_CC): New macro. Check if the
10262 target compiler is functional.
10263 * configure.ac: Call grub_PROG_TARGET_CC once all target flags
10264 are set up.
10265
58393a2d 10266 * configure.ac: Default to efi platform for x86_64-apple. Allow
10267 powerpc64 CPU, default to ieee1275 platform for it. Split CPU
10268 adjustments from the rest, only do them if target is not
10269 explicitly given. Merge other adjustments with the final sanity
10270 check. Remove an extraneous check for supported CPU. Be
10271 specific which CPU and which platform is not supported.
10272
737feb35 10273 * configure.ac: Default to pc platform for x86_64.
10274
546f966a 102752008-07-17 Robert Millan <rmh@aybabtu.com>
10276
10277 Partial LinuxBIOS -> Coreboot rename.
10278
10279 * conf/i386-linuxbios.rmk: Renamed to ...
10280 * conf/i386-coreboot.rmk: ... this.
10281 * Makefile.in (RMKFILES): s/i386-linuxbios.rmk/i386-coreboot.rmk/g.
10282 * configure.ac: Accept "coreboot" as input platform (but maintain
10283 compatibility with "linuxbios").
10284 * include/grub/i386/linuxbios: Renamed to ...
10285 * include/grub/i386/coreboot: ... this.
10286
20011694 102872008-07-17 Bean <bean123ch@gmail.com>
10288
10289 * conf/i386/efi.rmk (pkglib_MODULES): add pci.mod and lspci.mod.
c11f6d16 10290 (appleldr_mod_SOURCE): New variable.
20011694 10291 (appleldr_mod_CFLAGS): Likewise.
10292 (appleldr_mod_LDFLAGS): Likewise.
10293 (pci_mod_SOURCES): Likewise.
10294 (pci_mod_CFLAGS): Likewise.
10295 (pci_mod_LDFLAGS): Likewise.
10296 (lspci_mod_SOURCES): Likewise.
10297 (lspci_mod_CFLAGS): Likewise.
10298 (lspci_mod_LDFLAGS): Likewise.
10299
10300 * conf/x86_64-efi.rmk: New file.
10301
10302 * disk/efi/efidisk.c (grub_efidisk_read): Wrap efi calls with efi_call_N
10303 macro.
10304 (grub_efidisk_write): Likewise.
10305
10306 * include/efi/api.h (efi_call_0): New macro.
10307 (efi_call_1): Likewise.
10308 (efi_call_2): Likewise.
10309 (efi_call_3): Likewise.
10310 (efi_call_4): Likewise.
10311 (efi_call_5): Likewise.
10312 (efi_call_6): Likewise.
10313
10314 * include/grub/efi/chainloader.h (grub_chainloader_cmd): Rename to
10315 grub_rescue_cmd_chainloader.
10316
10317 * include/grub/efi/pe32.h (GRUB_PE32_MACHINE_X86_64): New macro.
10318 (grub_pe32_optional_header): Change some fields based on i386 or
10319 x86_64 platform.
10320 (GRUB_PE32_PE32_MAGIC): Likewise.
10321
10322 * include/grub/efi/uga_draw.h: New file.
10323
10324 * include/grub/elf.h (STN_ABS): New constant.
10325 (R_X86_64_NONE): Relocation constant for x86_64.
10326 (R_X86_64_64): Likewise.
10327 (R_X86_64_PC32): Likewise.
10328 (R_X86_64_GOT32): Likewise.
10329 (R_X86_64_PLT32): Likewise.
10330 (R_X86_64_COPY): Likewise.
10331 (R_X86_64_GLOB_DAT): Likewise.
10332 (R_X86_64_JUMP_SLOT): Likewise.
10333 (R_X86_64_RELATIVE): Likewise.
10334 (R_X86_64_GOTPCREL): Likewise.
10335 (R_X86_64_32): Likewise.
10336 (R_X86_64_32S): Likewise.
10337 (R_X86_64_16): Likewise.
10338 (R_X86_64_PC16): Likewise.
10339 (R_X86_64_8): Likewise.
10340 (R_X86_64_PC8): Likewise.
10341
10342 * include/grub/i386/efi/pci.h: New file.
10343
10344 * include/grub/i386/linux.h (GRUB_LINUX_EFI_SIGNATURE):
10345 Change it value based on platform.
10346 (GRUB_LINUX_EFI_SIGNATURE_0204): New constant.
10347 (GRUB_E820_RAM): Likewise.
10348 (GRUB_E820_RESERVED): Likewise.
10349 (GRUB_E820_ACPI): Likewise.
10350 (GRUB_E820_NVS): Likewise.
10351 (GRUB_E820_EXEC_CODE): Likewise.
10352 (GRUB_E820_MAX_ENTRY): Likewise.
10353 (grub_e820_mmap): New structure.
10354 (linux_kernel_header): Change the efi field according to different
10355 kernel version, also field from linux_kernel_header.
10356
10357 * include/grub/kernel.h (grub_module_info): Add padding for x86_64.
10358
10359 * include/grub/pci.h (GRUB_PCI_ADDR_SPACE_MASK): New constant.
10360 (GRUB_PCI_ADDR_SPACE_MEMORY): Likewise.
10361 (GRUB_PCI_ADDR_SPACE_IO): Likewise.
10362 (GRUB_PCI_ADDR_MEM_TYPE_MASK): Likewise.
10363 (GRUB_PCI_ADDR_MEM_TYPE_32): Likewise.
10364 (GRUB_PCI_ADDR_MEM_TYPE_1M): Likewise.
10365 (GRUB_PCI_ADDR_MEM_TYPE_64): Likewise.
10366 (GRUB_PCI_ADDR_MEM_PREFETCH): Likewise.
10367 (GRUB_PCI_ADDR_MEM_MASK): Likewise.
10368 (GRUB_PCI_ADDR_IO_MASK): Likewise.
10369
10370 * include/grub/x86_64/efi/kernel.h: New file.
10371
10372 * include/grub/x86_64/efi/loader.h: Likewise.
10373
10374 * include/grub/x86_64/efi/machine.h: Likewise.
10375
10376 * include/grub/x86_64/efi/pci.h: Likewise.
10377
10378 * include/grub/x86_64/efi/time.h: Likewise.
10379
10380 * include/grub/x86_64/linux.h: Likewise.
10381
10382 * include/grub/x86_64/setjmp.h: Likewise.
10383
10384 * include/grub/x86_64/time.h: Likewise.
10385
10386 * include/grub/x86_64/types.h: Likewise.
10387
10388 * kern/dl.c (GRUB_CPU_SIZEOF_VOID_P): Changed to
10389 GRUB_TARGET_SIZEOF_VOID_P.
10390
10391 * kern/efi/efi.c (grub_efi_locate_protocol): Wrap efi calls.
10392 (grub_efi_locate_handle): Likewise.
10393 (grub_efi_open_protocol): Likewise.
10394 (grub_efi_set_text_mode): Likewise.
10395 (grub_efi_stall): Likewise.
10396 (grub_exit): Likewise.
10397 (grub_reboot): Likewise.
10398 (grub_halt): Likewise.
10399 (grub_efi_exit_boot_services): Likewise.
10400 (grub_get_rtc): Likewise.
10401
10402 * kern/efi/mm.c (MEMORY_MAP_SIZE): Change to 0x3000 for new models.
10403 (GRUB_CPU_SIZEOF_VOID_P): Changed to GRUB_TARGET_SIZEOF_VOID_P.
10404 (grub_efi_allocate_pages): Wrap efi calls.
10405 (grub_efi_free_pages): Wrap efi calls.
10406 (grub_efi_get_memory_map): Wrap efi calls.
10407
10408 * kern/x86_64/dl.c: New file.
10409
10410 * kern/x86_64/efi/callwrap.S: Likewise.
10411
10412 * kern/x86_64/efi/startup.S: Likewise.
10413
10414 * loader/efi/appleloader.c: Likewise.
10415
10416 * loader/efi/chainloader.c (cmdline): New variable.
10417 (grub_chainloader_unload): Wrap efi calls.
10418 (grub_chainloader_boot): Likewise.
10419 (grub_rescue_cmd_chainloader): Wrap efi calls, handle
10420 command line.
10421
10422 * loader/efi/chainloader_normal.c (chainloader_command):
10423 Change grub_chainloader_cmd to grub_rescue_cmd_chainloader, pass
10424 command line.
10425
10426 * loader/i386/efi/linux.c (allocate_pages): Change allocation
10427 method.
10428 (grub_e820_add_region): New function.
10429 (grub_linux_boot): Construct e820 map from efi map, handle x86_64
10430 booting.
10431 (grub_find_video_card): New function.
10432 (grub_linux_setup_video): New function.
10433 (grub_rescue_cmd_linux): Probe for video information.
10434
10435 * normal/x86_64/setjmp.S: New file.
10436
10437 * term/efi/console.c (map_char): New function.
10438 (grub_console_putchar): Map unicode char.
10439 (grub_console_checkkey): Wrap efi calls.
10440 (grub_console_getkey): Likewise.
10441 (grub_console_getwh): Likewise.
10442 (grub_console_gotoxy): Likewise.
10443 (grub_console_cls): Likewise.
10444 (grub_console_setcolorstate): Likewise.
10445 (grub_console_setcursor): Likewise.
10446
10447 * util/i386/efi/grub-mkimage.c: Add support for x86_64.
10448
59652a20 104492008-07-16 Pavel Roskin <proski@gnu.org>
10450
ef294055 10451 * loader/i386/efi/linux.c (allocate_pages): Fix warnings in
10452 format strings.
10453
59652a20 10454 * util/i386/efi/grub-mkimage.c (get_target_address): Return a
10455 pointer, not an integer. This fixes a warning and prevents
10456 precision loss on 64-bit systems.
10457 (relocate_addresses): Remove unneeded cast.
10458
afc3b5d7 104592008-07-15 Pavel Roskin <proski@gnu.org>
10460
506b2b3e 10461 * kern/i386/ieee1275/init.c: Include grub/cache.h.
10462
62ead89c 10463 * term/ieee1275/ofconsole.c: Disable code unused on i386.
10464
c4cd51d7 10465 * kern/ieee1275/ieee1275.c (grub_ieee1275_get_integer_property):
10466 Fix comparison between signed and unsigned.
10467
0d3d8f28 10468 * include/grub/i386/ieee1275/console.h: Declare
10469 grub_console_init() and grub_console_fini().
10470
8804b286 10471 * loader/i386/ieee1275/linux.c (grub_set_bootpath): Remove.
10472 It's empty and unused.
10473
ee01cf35 10474 * fs/ext2.c (grub_ext2_read_block): Initialize blknr in the
10475 beginning to avoid warnings with some compilers.
10476
afc3b5d7 10477 * loader/ieee1275/multiboot2.c: Include grub/machine/loader.h.
10478 [__i386__] (grub_mb2_arch_boot): Avoid unnecessary cast.
10479
e4e8eaa5 104802008-07-14 Pavel Roskin <proski@gnu.org>
10481
407aceb4 10482 * kern/env.c (grub_register_variable_hook): Don't copy empty
10483 string, it leaks memory. Pass "" to grub_env_set(), it should
10484 handle constant strings.
10485
e4e8eaa5 10486 * commands/blocklist.c (grub_cmd_blocklist): Fix format warning.
10487 * commands/cmp.c (grub_cmd_cmp): Likewise.
10488 * kern/dl.c (grub_dl_flush_cache): Likewise.
10489 (grub_dl_load_core): Likewise.
10490 * kern/elf.c (grub_elf32_load_phdrs): Likewise.
10491 (grub_elf64_load_phdrs): Likewise.
10492
d4e2dad3 104932008-07-13 Pavel Roskin <proski@gnu.org>
10494
10495 * lib/LzmaEnc.c (LzmaEnc_SetProps): Fix warning about comparison
10496 between signed and unsigned.
10497 (LzmaEnc_Finish): Fix warning about an unused parameter.
10498
aa24b516 104992008-07-13 Bean <bean123ch@gmail.com>
10500
10501 * Makefile.in (enable_lzo): New rule.
10502
10503 * conf/i386-pc.rmk (grub_mkimage_SOURCES): New test with enable_lzo.
10504
10505 * configure.ac (ENABLE_LZO): New option --enable-lzo.
10506
10507 * boot/i386/pc/lnxboot.S: #include <config.h>.
10508
10509 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE): Change
fe987087 10510 its value according to the compression algorithm used, lzo or lzma.
aa24b516 10511
10512 * util/i386/pc/grub-mkimage.c (compress_kernel): Use different
10513 compression algorithm according to configure macro.
10514
10515 * kern/i386/pc/startup.S (codestart): Likewise.
10516
10517 * kern/i386/pc/lzma_decode.S: New file.
10518
10519 * include/grub/lib/LzFind.h: Likewise.
10520
10521 * include/grub/lib/LzHash.h: Likewise.
10522
10523 * include/grub/lib/LzmaDec.h: Likewise.
10524
10525 * include/grub/lib/LzmaEnc.h: Likewise.
10526
10527 * include/grub/lib/LzmaTypes.h: Likewise.
10528
10529 * lib/LzFind.c: Likewise.
10530
10531 * lib/LzmaDec.c: Likewise.
10532
10533 * lib/LzmaEnc.c: Likewise.
10534
4ae821ac 105352008-07-13 Bean <bean123ch@gmail.com>
10536
10537 * fs/ext2.c (EXT4_EXTENTS_FLAG): New macro.
10538 (grub_ext4_extent_header): New structure.
10539 (grub_ext4_extent): Likewise.
10540 (grub_ext4_extent_idx): Likewise.
10541 (grub_ext4_find_leaf): New function.
10542 (grub_ext2_read_block): Handle extents.
10543
9a745147 105442008-07-12 Robert Millan <rmh@aybabtu.com>
10545
10546 * util/i386/pc/grub-mkrescue.in: s/grub-install/grub-mkrescue/g.
10547
d49a4cf6 105482008-07-11 Robert Millan <rmh@aybabtu.com>
10549
10550 * util/grub.d/40_custom.in: New file. Example on how to add custom
10551 entries to /etc/grub.d.
10552 * conf/common.rmk (%, update-grub_SCRIPTS, CLEANFILES): Install
10553 40_custom (implicitly, by merging all the grub.d rules).
10554
947414b4 105552008-07-11 Pavel Roskin <proski@gnu.org>
10556
0059cf6f 10557 * commands/read.c (grub_getline): Fix invalid memory access.
10558 Don't add newline to the variable value.
10559
947414b4 10560 * term/i386/pc/serial.c (GRUB_SERIAL_PORT_NUM): New constant.
10561 [!GRUB_MACHINE_PCBIOS] (serial_hw_io_addr): Add COM2 and COM3.
10562 (serial_hw_get_port): Check validity of the port number.
10563 (grub_cmd_serial): Check return value of serial_hw_get_port().
10564
62a02d00 105652008-07-07 Pavel Roskin <proski@gnu.org>
10566
10567 * boot/i386/pc/diskboot.S (notification_string): Replace
10568 "Loading kernel" with just "loading". This is shorter, less
10569 confusing and saves a few bytes for possible future changes.
10570
3e5581b0 105712008-07-05 Pavel Roskin <proski@gnu.org>
10572
ea387a48 10573 * disk/ata.c (grub_ata_dumpinfo): Don't output addressing and
10574 size for ATAPI devices, they are undefined. Output sector
10575 number in decimal form.
10576
3e5581b0 10577 * disk/ata.c: Use named constants for status bits.
10578
fdecb8fd 105792008-07-04 Pavel Roskin <proski@gnu.org>
10580
bcd35b90 10581 * kern/i386/linuxbios/init.c (grub_machine_init): Cast addr to
10582 grub_addr_t before casting it to the void pointer to fix a
10583 warning. Non-addressable regions are discarded earlier.
10584 (grub_arch_modules_addr): Cast _end to grub_addr_t.
10585 * kern/i386/linuxbios/table.c: Include grub/misc.h.
10586 (check_signature): Don't shadow table_header.
10587 (grub_linuxbios_table_iterate): Cast numeric constants to
10588 grub_linuxbios_table_header_t.
10589 * include/grub/i386/linuxbios/init.h: Add noreturn attribute to
10590 grub_stop().
10591
af58ab3d 10592 * kern/ieee1275/init.c: Cast _start and _end to grub_addr_t to
10593 prevent warnings.
10594
1759aa57 10595 * include/grub/misc.h (ALIGN_UP): Avoid unnecessary cast to a
10596 pointer, which can cause warnings. Support 64-bit addresses.
10597
fdecb8fd 10598 * util/elf/grub-mkimage.c: Use GRUB_TARGET_SIZEOF_LONG instead
10599 of sizeof(long). This fixes PowerPC image generation on x86_64.
10600
8516d2a8 106012008-07-04 Robert Millan <rmh@aybabtu.com>
10602
10603 This fixes a performance issue when pc & gpt partmap iterators
10604 didn't abort iteration even after our hook found what it was
fe987087 10605 looking for (often causing expensive probes of non-existent drives).
8516d2a8 10606
10607 Some callers relied on previous buggy behaviour, since they would
34c44600 10608 raise an error when their own hooks caused early abortion of its
8516d2a8 10609 iteration.
10610
10611 * kern/device.c (grub_device_open): Improve error message.
10612 * disk/lvm.c (grub_lvm_open): Likewise.
10613 * disk/raid.c (grub_raid_open): Likewise.
10614
10615 * partmap/pc.c (pc_partition_map_iterate): Abort parent iteration
10616 when hook requests it, independently of grub_errno.
10617 (pc_partition_map_probe): Do not fail when find_func() caused
10618 early abortion of pc_partition_map_iterate().
10619
10620 * partmap/gpt.c (gpt_partition_map_iterate): Abort parent iteration
10621 when hook requests it, independently of grub_errno.
10622 (gpt_partition_map_probe): Do not fail when find_func() caused
10623 early abortion of gpt_partition_map_iterate().
10624
10625 * kern/partition.c (grub_partition_iterate): Abort parent iteration
10626 when hook requests it, independently of grub_errno. Do not fail when
10627 part_map_iterate_hook() caused early abortion of p->iterate().
10628
10629 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Do not fail
10630 when grub_partition_iterate() returned with non-zero.
10631
277d0de9 106322008-07-03 Pavel Roskin <proski@gnu.org>
10633
10634 * disk/ata.c (grub_ata_pio_write): Check status before writing,
10635 like we do in grub_ata_pio_read().
10636 (grub_ata_readwrite): Always write individual sectors. Fix the
10637 sector count for the remainder.
10638 (grub_ata_write): Enable writing to ATA devices. Correctly
10639 report error for ATAPI devices.
10640
d4c9b428 106412008-07-02 Pavel Roskin <proski@gnu.org>
10642
e43fc690 10643 * boot/i386/pc/cdboot.S: Add _start entry to fix a linker
10644 warning.
10645
f707af42 10646 * disk/ata.c (grub_ata_readwrite): Don't increment sector number
10647 for every read sector, we already increment it for the whole
10648 batch. This fixes reading more than 256 sectors at once.
10649
11e16b15 10650 * util/grub-editenv.c (cmd_info): Cast argument to long
10651 explicitly. ptrdiff_t reduces to int on i386.
10652
cbabfdd4 10653 * util/grub-editenv.c (main): Be specific which parameter is
10654 missing.
10655
b8fbce0a 10656 * disk/memdisk.c (memdisk_addr): Make a pointer to fix warnings.
10657 (memdisk): Make memdisk_orig_addr a pointer.
10658
c9c8e606 10659 * fs/reiserfs.c (grub_reiserfs_read): Fix misuse of grub_size_t
10660 for file offsets, use grub_off_t instead. Fix printf format
10661 warnings.
10662
ca62e598 10663 * fs/reiserfs.c: Remove #warning, TODO list items don't belong
10664 there. Real unexpected warnings should not drown in the noise
10665 about known problems.
10666
ce8d1766 10667 * commands/hexdump.c (grub_cmd_hexdump): Fix misuse of
10668 grub_disk_addr_t for memory addresses.
10669
00c7a56a 10670 * loader/aout.c (grub_aout_load): Cast load_addr to pointer
10671 explicitly to fix a warning.
10672
08d3ef09 10673 * util/grub-editenv.c (cmd_info): Fix warning in printf format.
10674
cb71ba20 10675 * Makefile.in (MODULE_LDFLAGS): New variable.
10676 * aclocal.m4 (grub_PROG_LD_BUILD_ID_NONE): New macro. Check if
10677 the linker accepts --build-id=none.
10678 * configure.ac: Call grub_PROG_LD_BUILD_ID_NONE. Substitute
10679 MODULE_LDFLAGS.
10680 * genmk.rb: Use MODULE_LDFLAGS when linking modules.
10681
d4c9b428 10682 * fs/xfs.c (struct grub_xfs_dir_header): Use names similar to
10683 those in Linux XFS code. Provide a way to access 64-bit parent
10684 inode.
10685 (grub_xfs_iterate_dir): Use the new names. Avoid reading past
10686 the end of struct grub_xfs_dir_header.
10687
d4156eee 106882008-07-02 Bean <bean123ch@gmail.com>
10689
10690 * include/grub/ieee1275.h (grub_ieee1275_flag): New constant
10691 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
10692 and GRUB_IEEE1275_FLAG_NO_ANSI.
10693
10694 * kern/ieee1275/cmain.c (grub_ieee1275_find_options): Set flag
10695 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
10696 and GRUB_IEEE1275_FLAG_NO_ANSI for Open Hackware.
10697
10698 * kern/ieee1275/ieee1275.c (grub_ieee1275_interpret): Return
10699 immediately if GRUB_IEEE1275_FLAG_CANNOT_INTERPRET is set.
10700
10701 * kern/ieee1275/init.c (grub_claim_heap): Claim memory directly if
10702 GRUB_IEEE1275_FLAG_FORCE_CLAIM is set.
10703
10704 * term/ieee1275/ofconsole.c (grub_ofconsole_writeesc): Don't output
10705 esc sequence on non ANSI terminal.
10706 (grub_ofconsole_gotoxy): Emulate backspace key on non ANSI terminal.
10707
10708 * util/elf/grub-mkimage.c (add_segments): Move ELF header to the
10709 beginning of file.
10710
2270f77b 107112008-07-02 Bean <bean123ch@gmail.com>
10712
10713 * conf/common.rmk (bin_UTILITIES): Add grub-editenv.
10714 (grub_editenv_SOURCES): New variable.
10715 (pkglib_MODULES): Add loadenv.mod.
10716 (loadenv_mod_SOURCES): New variable.
10717 (loadenv_mod_CFLAGS): Likewise.
10718 (loadenv_mod_LDFLAGS): Likewise.
10719
10720 * include/grub/envblk.h: New file.
10721
10722 * util/envblk.c: New file.
10723
10724 * util/grub-editenv.c: New file.
10725
10726 * commands/loadenv.c: New file.
10727
0e9e51ec 107282008-07-01 Pavel Roskin <proski@gnu.org>
10729
d89b7634 10730 * include/multiboot2.h (struct multiboot_tag_module): Use char,
10731 not unsigned char. This fixes warnings and is consistent with
10732 other tags.
10733
bf1835b1 10734 * disk/fs_uuid.c (search_fs_uuid): Correctly increment count.
10735
8222a04b 10736 * normal/parser.y: Define YYENABLE_NLS as 0 to fix warnings.
10737
6a42d99d 10738 * term/tparm.c (analyze): Always set *popcount.
10739
10b159d1 10740 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Remove useless
10741 cast to fix a warning.
10742
b8789f6c 10743 * loader/i386/pc/multiboot2.c (grub_mb2_arch_module_alloc): Use
10744 cast to suppress a warning.
10745
29d7e38a 10746 * fs/afs.c (grub_afs_read_block): Return grub_disk_addr_t, as
10747 grub_fshelp_read_file() expects.
10748
f341f669 10749 * fs/fat.c: Fix UUID calculation on big-endian systems. We
10750 write uuid as a 32-bit value in CPU byte order, so declare and
10751 use it as such.
10752
0e9e51ec 10753 * disk/raid.c: Cast grub_dprintf() arguments to unsigned long
10754 long if the format specifier expects it.
10755 * partmap/gpt.c (gpt_partition_map_iterate): Likewise.
10756 * partmap/pc.c (pc_partition_map_iterate): Likewise.
10757 * fs/ntfs.c (grub_ntfs_uuid): Cast data->uuid to unsigned long
10758 long to fix a warning.
10759 * fs/reiserfs.c (grub_reiserfs_read): Change casts in
10760 grub_dprintf() arguments to fix warnings.
10761
3aefa857 107622008-06-30 Pavel Roskin <proski@gnu.org>
10763
56c7668b 10764 * util/i386/pc/grub-setup.c (setup): Write install_dos_part and
10765 install_bsd_part immediately before core.img is embedded or
10766 modified on disk. This fixes core.img verification if core.img
10767 cannot be embedded.
10768
3aefa857 10769 * util/i386/pc/grub-setup.c (setup): Use core_path_dev, not
10770 core_path to calculate the blocklist.
10771 Patch from Javier Martín <lordhabbit@gmail.com>
10772
5444088d 107732008-06-29 Robert Millan <rmh@aybabtu.com>
10774
10775 * fs/xfs.c (GRUB_XFS_FSB_TO_BLOCK): New macro. Maps filesystem
10776 block to disk block.
10777 (grub_xfs_read_block): Use GRUB_XFS_FSB_TO_BLOCK() on result.
10778 Patch from Niels Böhm <bitbucket@arcor.de>
10779
674835c8 107802008-06-29 Robert Millan <rmh@aybabtu.com>
10781
10782 * util/update-grub_lib.in (font_path): Search for fonts in
10783 /boot/grub first, which is more likely to be readable (we aren't
10784 deciding where fonts live, just looking for them).
10785
f527dbc8 107862008-06-26 Pavel Roskin <proski@gnu.org>
10787
6c2d8df6 10788 * util/biosdisk.c (read_device_map): Don't leave dead map
10789 entries for devices failing stat() check.
10790
f527dbc8 10791 * util/i386/pc/grub-setup.c (setup): Don't reuse core_path, use
10792 core_path_dev for the core.img path on the target device.
10793
aebe3d13 107942008-06-26 Robert Millan <rmh@aybabtu.com>
10795
10796 * disk/fs_uuid.c: New file.
10797 * conf/common.rmk (pkglib_MODULES): Add `fs_uuid.mod'.
10798 (fs_uuid_mod_SOURCES, fs_uuid_mod_CFLAGS)
10799 (fs_uuid_mod_LDFLAGS): New variables.
10800 * include/grub/disk.h (grub_disk_dev_id): Add
10801 `GRUB_DISK_DEVICE_UUID_ID'.
10802 * kern/disk.c (grub_disk_dev_iterate): Allow disk devices not to
10803 implement iterate().
10804
37aaf354 108052008-06-26 Robert Millan <rmh@aybabtu.com>
10806
10807 * util/grub.d/10_linux.in: Avoid passing UUIDs to Linux when either
10808 "/dev/disk/by-uuid/${GRUB_DEVICE_UUID}" does not exist, or when a
10809 Linux image includes no initrd.
10810
25ff262a 108112008-06-21 Javier Martín <lordhabbit@gmail.com>
10812
10813 * util/i386/pc/grub-setup.c (setup): Remove literal "core.img" in a
10814 call to resolve the core image location that effectively appended the
10815 name twice.
10816
76a2bd44 108172008-06-21 Robert Millan <rmh@aybabtu.com>
10818
10819 * util/grub.d/00_header.in: Move last prepare_grub_to_access_device()
10820 call from here ...
10821
10822 * util/grub.d/10_hurd.in: ... to here ...
10823 * util/grub.d/10_linux.in: ... and here.
10824
650e1c79 108252008-06-19 Robert Millan <rmh@aybabtu.com>
10826
fe987087 10827 * kern/main.c (grub_main): Export `prefix' variable immediately
650e1c79 10828 after it has been set by grub_machine_set_prefix().
10829
6ce63911 108302008-06-19 Robert Millan <rmh@aybabtu.com>
10831
10832 * commands/search.c (search_label, search_fs_uuid, search_file): Print
10833 search result when not saving to variable, not the other way around.
10834 When saving to variable, abort iteration as soon as a match is found.
10835
73940cec 108362008-06-19 Robert Millan <rmh@aybabtu.com>
10837
10838 * util/update-grub_lib.in (prepare_grub_to_access_device): Remove
10839 check for partition that provides /boot/grub. Its logic is flawed,
10840 as it prevents prepare_grub_to_access_device() from being called
10841 multiple times.
10842
3c62a39d 108432008-06-19 Robert Millan <rmh@aybabtu.com>
10844
10845 * util/update-grub_lib.in (prepare_grub_to_access_device): Issue
10846 "insmod" command directly when abstraction modules are needed,
fe987087 10847 instead of relying on GRUB_PRELOAD_MODULES (which had no effect
3c62a39d 10848 since it had already been processed).
10849
47395a42 108502008-06-19 Pavel Roskin <proski@gnu.org>
10851
10852 * conf/i386-efi.rmk: Recompile grub-mkimage.c if Makefile has
10853 changed. This is needed in case GRUB_LIBDIR changes.
10854 * conf/i386-ieee1275.rmk: Likewise.
10855 * conf/i386-linuxbios.rmk: Likewise.
10856 * conf/i386-pc.rmk: Likewise.
10857 * conf/powerpc-ieee1275.rmk: Likewise.
10858
a145ac2d 108592008-06-18 Pavel Roskin <proski@gnu.org>
10860
10861 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Rename
10862 kernel_elf_symlist.c to symlist.c for consistency with other
10863 architectures. Update all users.
10864 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
10865
7847c51e 108662008-06-18 Robert Millan <rmh@aybabtu.com>
10867
10868 * util/i386/pc/grub-install.in: If the drive is LVM or RAID, prepend
10869 it in prefix.
10870
10871 * util/i386/pc/grub-setup.c (main): Don't handle prefix at all. Set
10872 `must_embed' to 1 when root_dev is a RAID device. When dest_dev is
10873 a RAID device, run setup() for all members independently on whether
10874 LVM abstraction is being used.
10875 (setup): Don't handle prefix at all; let grub-mkimage take care of it.
10876 If grub-mkimage has set `*install_dos_part == -2', don't override this
10877 value.
10878 Perform *install_dos_part adjustments independently on whether
10879 we're embedding or not.
10880 Clarify error message when image is too big for embedding.
10881 Remove duplicate *install_dos_part stanza.
10882
b23e5644 108832008-06-17 Robert Millan <rmh@aybabtu.com>
10884
10885 * term/ieee1275/ofconsole.c (fgcolor, bgcolor): Remove variables.
10886 (grub_ofconsole_normal_color, grub_ofconsole_highlight_color): New
10887 variables.
10888 (grub_ofconsole_setcolor, grub_ofconsole_getcolor): Load/store
10889 values in grub_ofconsole_normal_color and
10890 grub_ofconsole_highlight_color (they're not directly related to
10891 background and foreground).
10892 (grub_ofconsole_setcolorstate): Extract background and foreground
10893 from grub_ofconsole_normal_color and grub_ofconsole_highlight_color.
10894
0aac2f79 108952008-06-17 Robert Millan <rmh@aybabtu.com>
10896
10897 * util/update-grub_lib.in (prepare_grub_to_access_device): Use
10898 /boot/grub for the check in last commit, not /boot (they could be
10899 different partitions).
10900
3cca7ef3 109012008-06-16 Robert Millan <rmh@aybabtu.com>
10902
10903 * util/update-grub_lib.in (prepare_grub_to_access_device): If we were
10904 asked to setup access for the same partition that provides /boot,
10905 don't bother using UUIDs since our root already has the value we
10906 want.
10907
347396d8 109082008-06-16 Robert Millan <rmh@aybabtu.com>
10909
10910 * util/biosdisk.c (convert_system_partition_to_system_disk): Detect
10911 I2O devices.
10912 Patch from Sven Mueller <sven@debian.org>.
10913
991477f8 109142008-06-16 Robert Millan <rmh@aybabtu.com>
10915
10916 * util/update-grub.in: Check for $EUID instead of $UID.
10917 Reported by Vincent Zweije.
10918
d31a32a1 109192008-06-16 Bean <bean123ch@gmail.com>
10920
fe987087 10921 * fs/ext2.c (grub_ext2_blockgroup): Revert to pre-journal state.
d31a32a1 10922 (grub_ext2_read_block): Likewise.
10923 (grub_ext2_read_inode): Likewise.
10924 (grub_ext2_mount): Likewise.
10925 (grub_ext2_close): Likewise.
10926 (grub_ext3_get_journal): Removed.
10927
fe987087 10928 * fs/reiserfs.c (grub_reiserfs_get_item): Revert to pre-journal state.
d31a32a1 10929 (grub_reiserfs_read_symlink): Likewise.
10930 (grub_reiserfs_mount): Likewise.
10931 (grub_reiserfs_open): Likewise.
10932 (grub_reiserfs_read): Likewise.
10933 (grub_reiserfs_close): Likewise.
10934 (grub_reiserfs_get_journal): Removed.
10935
10936 * fs/fshelp.c (grub_fshelp_read): Removed.
10937 (grub_fshelp_map_block): Likewise.
10938
10939 * include/grub/fshelp.h (grub_fshelp_journal_type): Removed.
10940 (grub_fshelp_journal): Likewise.
10941 (grub_fshelp_read): Likewise.
10942 (grub_fshelp_map_block): Likewise.
10943
3540a760 109442008-06-16 Pavel Roskin <proski@gnu.org>
10945
10946 * conf/powerpc-ieee1275.rmk: Remove -msoft-float, we don't use
10947 floating point anymore.
10948 * include/grub/powerpc/libgcc.h: Leave only necessary exports.
10949
95614c84 109502008-06-15 Pavel Roskin <proski@gnu.org>
10951
10952 * commands/ls.c (grub_ls_list_files): Use integer calculations
10953 for human readable format, avoid floating point use.
10954 * kern/misc.c (grub_ftoa): Remove.
10955 (grub_vsprintf): Remove floating point support.
10956
50465dd6 109572008-06-15 Robert Millan <rmh@aybabtu.com>
10958
fe6b695a 10959 * util/grub.d/10_linux.in: Use the underlying device for loop-AES
50465dd6 10960 devices.
10961 Reported by Max Vozeler.
10962
a9207284 109632008-06-15 Robert Millan <rmh@aybabtu.com>
10964
10965 * util/i386/pc/grub-mkimage.c (generate_image): If we included a drive
10966 in our prefix, set install_{dos,bsd}_part = -2 to indicate this can be
10967 skipped later.
10968 (main): If a memdisk was requested, add "(memdisk)" drive explicitly to
10969 the beginning of the prefix.
10970
10971 * kern/i386/pc/init.c (make_install_device): Remove memdisk check.
10972 It is assumed that if we have a memdisk, grub-mkimage has set
10973 grub_prefix to include the "(memdisk)" drive in it.
10974
a7cbd45a 109752008-06-15 Robert Millan <rmh@aybabtu.com>
10976
10977 * term/i386/pc/console.c [GRUB_MACHINE_LINUXBIOS] (grub_console_init):
10978 Initialize keyboard controller after registering the terminal, so that
10979 grub_printf() can be called from grub_keyboard_controller_init().
10980
21cf716a 109812008-06-15 Robert Millan <rmh@aybabtu.com>
10982
10983 * fs/sfs.c (grub_sfs_read_extent): Fix the count of nodes in
10984 extent-btree which is written as big endian on disk.
10985 Reported by Alain Greppin <al@chilibi.org>.
10986
23a64d8e 109872008-06-14 Robert Millan <rmh@aybabtu.com>
10988
10989 * util/i386/efi/grub-install.in (modules): Remove `_chain'.
10990 * util/i386/pc/grub-install.in (modules): Likewise.
10991
d687651c 109922008-06-13 Pavel Roskin <proski@gnu.org>
10993
10994 * commands/ls.c (grub_ls_list_files): Fix format warnings.
10995
dfe9ddd4 109962008-06-13 Bean <bean123ch@gmail.com>
10997
10998 * commands/hexdump.c (grub_cmd_hexdump): Adjust offset for partition.
10999
11000 * fs/ext2.c (grub_ext3_get_journal): Fix revoke block handling.
11001
11002 * fs/fshelp.c (grub_fshelp_map_block): Don't map block 0 as it's used
11003 to indicate sparse block.
11004
16ae7781 110052008-06-12 Pavel Roskin <proski@gnu.org>
11006
e6d1a308 11007 * fs/ext2.c (grub_ext2_read_inode): Don't normalize block
11008 number, grub_fshelp_read() does it for us.
11009
16ae7781 11010 * fs/fshelp.c (grub_fshelp_read): New function. Implement
11011 linear disk read with journal translation.
11012 * fs/ext2.c: Use grub_fshelp_read() instead of grub_disk_read().
11013 * include/grub/fshelp.h: Declare grub_fshelp_read().
11014
40fd3a2b 110152008-06-09 Pavel Roskin <proski@gnu.org>
11016
11017 * fs/minix.c (grub_minix_mount): Handle error reading
11018 superblock.
11019
f5679726 110202008-06-08 Robert Millan <rmh@aybabtu.com>
11021
11022 * util/i386/pc/grub-setup.c (main): If install drive is an LVM,
11023 don't append the RAID prefix afterwards.
11024 Reported by Clint Adams.
11025
ce525529 110262008-06-08 Robert Millan <rmh@aybabtu.com>
11027
11028 Based on description from Pavel:
11029 * kern/disk.c (grub_disk_check_range): Rename to ...
11030 (grub_disk_adjust_range): ... this. Add a comment explaining the
11031 tasks performed by this function.
11032
ad4936a0 110332008-06-08 Robert Millan <rmh@aybabtu.com>
11034
11035 * include/grub/ntfs.h (struct grub_ntfs_bpb): Rename `serial_number' to
11036 `num_serial' (for consistency with other variables).
11037 (struct grub_ntfs_data): Add `uuid' member.
11038 * fs/ntfs.c (grub_ntfs_mount): Initialize `data->uuid'.
11039 (grub_ntfs_uuid): New function.
11040 (grub_ntfs_fs): Reference grub_ntfs_uuid() in `uuid' struct member.
11041
dc20b0f9 110422008-06-07 Pavel Roskin <proski@gnu.org>
11043
11044 * util/biosdisk.c (open_device): Revert last change to the
11045 function, it broke installation. The sector needs to be
11046 different dependent on which device is opened.
11047
c5e3cfba 110482008-06-06 Robert Millan <rmh@aybabtu.com>
11049
11050 Ensure GRUB_KERNEL_MACHINE_DATA_END is always consistent with the
11051 rest of GRUB, and breakage doesn't happen if its value were modified.
11052
11053 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
11054 Redefine as an offset from `GRUB_KERNEL_MACHINE_DATA_END' instead of
11055 a constant (same value).
11056 * kern/i386/pc/startup.S: Replace hardcoded `0x50' with
11057 `GRUB_KERNEL_MACHINE_DATA_END' (same value).
11058
26a1f8c4 110592008-06-06 Robert Millan <rmh@aybabtu.com>
11060
11061 * util/biosdisk.c (open_device): Do not modify sector offset when
11062 accessing a partition. kern/disk.c already handles this for us.
11063
25d6b327 110642008-06-06 Robert Millan <rmh@aybabtu.com>
11065
11066 * util/grub-emu.c (grub_machine_init): Move code in this function from
11067 here ...
11068 (main): ... to here (before grub_util_biosdisk_init() call, to prevent
11069 segfault in case grub_printf() is called).
11070
11071 * util/i386/pc/grub-install.in: Append `--device-map=${device_map}' to
11072 grub_probe. Update all users not to explicitly add it again.
11073 (grub_device): New variable; contains corresponding device for grubdir.
11074 (fs_module, partmap_module, devabstraction_module): Pass
11075 `--device ${grub_device}' to grub_probe to avoid traversing /dev
11076 every time.
11077
9ece62fb 110782008-06-05 Robert Millan <rmh@aybabtu.com>
11079
11080 * normal/misc.c (grub_normal_print_device_info): When a filesystem UUID
11081 is found, print it (same layout as with labels).
11082
1ad36d37 110832008-06-04 Robert Millan <rmh@aybabtu.com>
11084
11085 * util/biosdisk.c (get_drive): Rename to ...
11086 (find_grub_drive): ... this. Update all users.
11087
11088 (get_os_disk): Rename to ...
11089 (convert_system_partition_to_system_disk): ... this. Update all users.
11090
11091 (find_drive): Rename to ...
11092 (find_system_device): ... this. Update all users.
11093
e6a30859 110942008-06-04 Robert Millan <rmh@aybabtu.com>
11095
11096 * util/biosdisk.c (get_os_disk): Handle IDA devices.
11097 * util/grub-mkdevicemap.c (get_mmc_disk_name)
11098 (make_device_map): Likewise.
11099
00c108a4 111002008-06-01 Robert Millan <rmh@aybabtu.com>
11101
11102 * util/biosdisk.c (get_drive): Verify that `map[i].drive' is non-NULL
11103 before dereferencing it.
11104
11105 * fs/fat.c (struct grub_fat_bpb): Move fat32-specific fields into a
11106 union with fat12/fat16-specific ones. Add some new fields, including
11107 `num_serial' for both versions.
11108 (struct grub_fat_data): Add `uuid' member.
11109 (grub_fat_mount): Refer to fat32-specific fields in `bpb' by their new
11110 names. Initialize `data->uuid' using `num_serial'.
11111 (grub_fat_uuid): New function.
11112 (grub_fat_fs): Reference grub_fat_uuid() in `uuid' struct member.
11113
11114 * fs/reiserfs.c (grub_reiserfs_superblock): Add `uuid' field.
11115 (grub_reiserfs_uuid): New function.
11116 (grub_reiserfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct
11117 member.
11118
11119 * fs/xfs.c (grub_xfs_sblock): Add `uuid' field.
11120 (grub_xfs_uuid): New function.
11121 (grub_xfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct member.
11122
1385c5bb 111232008-06-01 Robert Millan <rmh@aybabtu.com>
11124
11125 * util/update-grub_lib.in (prepare_grub_to_access_device): Generate
11126 code that is backward compatible with pre-uuid search command.
11127
c682dfd7 111282008-05-31 Robert Millan <rmh@aybabtu.com>
11129
11130 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Iterate through
11131 floppies after everything else, to ensure floppy drive isn't accessed
11132 unnecessarily (patch from Bean).
11133
b7db5d47 111342008-05-31 Robert Millan <rmh@aybabtu.com>
11135
11136 * commands/search.c (search_label, search_fs_uuid, search_file): Do
11137 not print device names when we were asked to set a variable.
11138
6e037aa9 111392008-05-31 Robert Millan <rmh@aybabtu.com>
11140
11141 * term/ieee1275/ofconsole.c (grub_ofconsole_setcursor): Implement
11142 using "cursor-on" and "cursor-off" commands (understood at least by
11143 the Open Firmware flavour on OLPC).
11144
41305bc8 111452008-05-31 Michael Gorven <michael@gorven.za.net>
11146
11147 * term/terminfo.c (grub_terminfo_set_current): Correct vt100 cursor
11148 on and off sequences.
11149
69ba137e 111502008-05-31 Robert Millan <rmh@aybabtu.com>
11151
11152 * util/update-grub_lib.in: Replace `grub-probe' with `${grub_probe}'.
11153 * util/update-grub.in: Likewise.
11154
520ae21b 111552008-05-30 Pavel Roskin <proski@gnu.org>
11156
11157 * util/biosdisk.c (linux_find_partition): Simplify logic and
11158 make the code more universal. Keep special processing for
11159 devfs, but use a simple rule for all other devices. If the
11160 device ends with a number, append 'p' and the partition number.
11161 Otherwise, append only the partition number.
11162
5786569b 111632008-05-30 Robert Millan <rmh@aybabtu.com>
11164
11165 * util/update-grub.in (GRUB_DISABLE_LINUX_UUID): Export variable.
11166 * util/grub.d/10_linux.in: If GRUB_DEVICE_UUID is set, and
11167 GRUB_DISABLE_LINUX_UUID isn't true, use the filesystem UUIDs as
11168 the `root' parameter to Linux.
11169
51500452 111702008-05-30 Robert Millan <rmh@aybabtu.com>
11171
11172 * commands/search.c (options): Rename --fs_uuid to --fs-uuid.
11173 * util/update-grub_lib.in (prepare_grub_to_access_device): Replace
11174 --fs_uuid with --fs-uuid.
11175 * util/update-grub.in: Allow filesystem UUID probes to fail (since not
11176 all filesystems support them).
11177
811d3878 111782008-05-30 Robert Millan <rmh@aybabtu.com>
11179
11180 * fs/ext2.c (grub_ext2_uuid): Use `04x' instead of '02x' as
f19dbdb7 11181 grub_printf() flags, since we're printing in units of 2 bytes.
811d3878 11182
cab63c95 111832008-05-30 Robert Millan <rmh@aybabtu.com>
11184
11185 * util/grub.d/00_header.in: Remove obsolete comment referencing
11186 convert_system_path_to_grub_path().
11187 * util/update-grub.in: Likewise.
11188 * util/update-grub_lib.in (is_path_readable_by_grub): New function.
11189 (convert_system_path_to_grub_path): Add a warning message explaining
11190 that this function is deprecated. Rely on is_path_readable_by_grub()
11191 for the readability checks.
11192 (font_path): Use is_path_readable_by_grub() for the readability
11193 check rather than convert_system_path_to_grub_path().
11194
972e2f7a 111952008-05-30 Robert Millan <rmh@aybabtu.com>
11196
11197 * util/update-grub_lib.in (prepare_grub_to_access_device): New function.
11198 * util/update-grub.in: Set `GRUB_FONT_PATH' to the system path, without
11199 converting it first.
11200 * util/grub.d/00_header.in: Use prepare_grub_to_access_device() to setup
11201 grub.cfg for access to font file, and afterwards call it again to set
11202 the root device.
11203
62191274 112042008-05-30 Robert Millan <rmh@aybabtu.com>
11205
11206 * commands/search.c (options): Add --fs_uuid option.
11207 (search_fs_uuid): New function.
11208 (grub_cmd_search): Fix --set argument passing.
11209 Use search_fs_uuid() when requested via --fs_uuid.
11210 (grub_search_init): Update help message.
11211 * fs/ext2.c (struct grub_ext2_sblock): Rename `unique_id' to `uuid'
11212 and redeclare it as an array of 16-bit words.
11213 (grub_ext2_uuid): New function.
11214 (grub_ext2_fs): Reference grub_ext2_uuid() in `uuid' struct member.
11215 * include/grub/fs.h (struct grub_fs): Add `uuid' struct member.
11216 * util/update-grub.in (GRUB_DEVICE_UUID, GRUB_DEVICE_BOOT)
11217 (GRUB_DEVICE_BOOT_UUID): New variables.
11218 (GRUB_DRIVE. GRUB_DRIVE_BOOT. GRUB_DRIVE_BOOT_GRUB): Remove.
11219 * util/grub.d/00_header.in: Set root using `search --fs_uuid' command
11220 whenever possible.
11221 * util/grub.d/10_hurd.in: Avoid explicit use of root drive. Instead,
11222 just assume `root' variable has the right value.
11223 * util/grub.d/10_linux.in: Likewise.
11224 * util/grub-probe.c (probe): Probe for filesystem UUID when requested
11225 via PRINT_FS_UUID.
11226 (main): Recognise `-t fs_uuid' argument.
11227
01b73ec8 112282008-05-30 Robert Millan <rmh@aybabtu.com>
11229
11230 * util/biosdisk.c (map): Redefine structure to hold information
11231 about GRUB drive name.
fe6b695a 11232 (get_drive): Reimplement without assuming (and verifying) BIOS-like
01b73ec8 11233 drive names.
11234 (call_hook): Remove.
11235 (grub_util_biosdisk_iterate): Access drive names via `.drive' struct
11236 member. Assume drive has partitions.
11237 (grub_util_biosdisk_open): Access device names via `.device' struct
11238 member.
11239 (open_device): Likewise.
11240 (find_drive): Likewise.
11241 (read_device_map): Adjust map[] usage to match the new struct
11242 definition. Don't check for duplicates (still possible, but not cheap
11243 anymore).
11244 (grub_util_biosdisk_fini): Free malloced buffers referenced by map[].
11245 (make_device_name): Remove assumption of BIOS-like drive names.
11246
22f16596 112472008-05-30 Pavel Roskin <proski@gnu.org>
11248
11249 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Remove, as
11250 compiling execute.c doesn't need grub_script.tab.h anymore.
11251 (normal/command.c_DEPENDENCIES): Likewise.
11252 (normal/function.c_DEPENDENCIES): Likewise.
11253 * conf/i386-ieee1275.rmk: Likewise.
11254 * conf/i386-linuxbios.rmk: Likewise.
11255 * conf/i386-pc.rmk: Likewise.
11256 * conf/powerpc-ieee1275.rmk: Likewise.
11257 * conf/sparc64-ieee1275.rmk: Likewise.
11258
528ad8f2 112592008-05-29 Pavel Roskin <proski@gnu.org>
11260
d1dff95d 11261 * disk/lvm.c (grub_lvm_scan_device): Check for the buffer end
11262 when scanning metadata for volume group name.
11263
528ad8f2 11264 * include/grub/script.h: Don't include grub_script.tab.h. It's
11265 a generated file, which may only be included from the files with
11266 DEPENDENCIES rules in the makefile. Don't use typedef YYSTYPE,
11267 use union YYSTYPE, as the later allows forward declaration.
11268 * normal/lexer.c: Don't use typedef YYSTYPE, use union YYSTYPE.
11269
47248e08 112702008-05-29 Robert Millan <rmh@aybabtu.com>
11271
11272 * term/i386/pc/at_keyboard.c: Include `grub/machine/machine.h'.
11273 (OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): New macros.
11274 [GRUB_MACHINE_IEEE1275] (keyboard_map): Add OLPC scan codes
11275 (grub_console_checkkey): Add grub_dprintf() call to report unknown
11276 scan codes.
11277
ee632529 112782008-05-29 Robert Millan <rmh@aybabtu.com>
11279
11280 * term/i386/pc/at_keyboard.c (grub_console_checkkey): Add support for
11281 control key combinations.
11282
eee96e08 112832008-05-29 Robert Millan <rmh@aybabtu.com>
11284
11285 * util/powerpc/ieee1275/grub-install.in: Move from here ...
11286 * util/ieee1275/grub-install.in: ... to here.
11287 * powerpc-ieee1275.rmk (grub_install_SOURCES): Update location.
11288 * i386-ieee1275.rmk (sbin_SCRIPTS): New variable.
11289 (grub_install_SOURCES): Likewise.
11290
da9a6a94 112912008-05-29 Robert Millan <rmh@aybabtu.com>
11292
11293 * fs/affs.c: Update copyright year.
11294 * fs/ext2.c: Likewise.
11295 * fs/fshelp.c: Likewise.
11296 * fs/hfsplus.c: Likewise.
11297 * fs/ntfs.c: Likewise.
11298 * fs/xfs.c: Likewise.
11299 * include/grub/fshelp.h: Likewise.
11300 * util/grub-mkdevicemap.c: Likewise.
11301
12e65f3a 113022008-05-28 Robert Millan <rmh@aybabtu.com>
11303
11304 * util/update-grub.in: Allow chmod call to fail, since /boot/grub/
11305 might need to be fatfs to support some firmware implementations
11306 (e.g. OFW or EFI).
11307
23023641 113082008-05-28 Robert Millan <rmh@aybabtu.com>
11309
11310 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle MMC
11311 devices.
11312 * util/grub-mkdevicemap.c (get_mmc_disk_name)
11313 (make_device_map): Likewise.
11314
887d2619 113152008-05-20 Bean <bean123ch@gmail.com>
11316
11317 * fs/fshelp.c (grub_fshelp_map_block): New function.
11318 (grub_fshelp_find_file): Use 64-bit type for pos and block address.
11319 Use `>>' and `&' operator to avoid 64-bit divide and modulo.
11320
11321 * include/grub/fshelp.h (grub_fshelp_journal_type): New enum.
11322 (GRUB_FSHELP_JOURNAL_UNUSED_MAPPING): New macro.
11323 (grub_fshelp_journal): New structure.
11324 (grub_fshelp_map_block): New function prototype.
11325 (grub_fshelp_read_file): Use grub_disk_addr_t as block type.
11326 (grub_fshelp_map_block): Likewise.
11327
11328 * fs/ext2.c (EXT3_FEATURE_COMPAT_HAS_JOURNAL): New macro.
11329 (EXT3_JOURNAL_MAGIC_NUMBER): Likewise.
11330 (EXT3_JOURNAL_DESCRIPTOR_BLOCK): Likewise.
11331 (EXT3_JOURNAL_COMMIT_BLOCK): Likewise.
11332 (EXT3_JOURNAL_SUPERBLOCK_V1): Likewise.
11333 (EXT3_JOURNAL_SUPERBLOCK_V2): Likewise.
11334 (EXT3_JOURNAL_REVOKE_BLOCK): Likewise.
11335 (EXT3_JOURNAL_FLAG_ESCAPE): Likewise.
11336 (EXT3_JOURNAL_FLAG_SAME_UUID): Likewise.
11337 (EXT3_JOURNAL_FLAG_DELETED): Likewise.
11338 (EXT3_JOURNAL_FLAG_LAST_TAG): Likewise.
11339 (grub_ext2_sblock): New members for journal support.
11340 (grub_ext3_journal_header): New structure.
11341 (grub_ext3_journal_revoke_header): Likewise.
11342 (grub_ext3_journal_block_tag): Likewise.
11343 (grub_ext3_journal_sblock): Likewise.
11344 (grub_fshelp_node): New members logfile and journal.
11345 (grub_ext2_read_block): Change block type to grub_disk_addr_t. Use
11346 grub_fshelp_map_block to get real block number.
11347 (grub_ext2_blockgroup): Use grub_fshelp_map_block to get real block
11348 number.
11349 (grub_ext2_read_inode): Likewise.
11350 (grub_ext3_get_journal): New function.
11351 (grub_read_inode): Initialize journal using grub_ext3_get_journal.
11352 (grub_ext2_close): Release memory used by journal.
11353
11354 * fs/reiserfs.c (REISERFS_MAGIC_STRING): Changed to "ReIsEr".
11355 (REISERFS_MAGIC_DESC_BLOCK): New macro.
11356 (grub_reiserfs_transaction_header): Renamed to
11357 grub_reiserfs_description_block, replace field data with real_blocks.
11358 (grub_reiserfs_commit_block): New structure.
11359 (grub_reiserfs_data): New member journal.
11360 (grub_reiserfs_get_item): Use grub_fshelp_map_block to get real block
11361 number.
11362 (grub_reiserfs_read_symlink): Likewise.
11363 (grub_reiserfs_iterate_dir): Likewise.
11364 (grub_reiserfs_open): Likewise.
11365 (grub_reiserfs_read): Likewise.
11366 (grub_reiserfs_get_journal): New function.
11367 (grub_reiserfs_mount): Use "ReIsEr" as super block magic, as there are
11368 three varieties ReIsErFs, ReIsEr2Fs and ReIsEr3Fs. Initialize journal
11369 using grub_reiserfs_get_journal.
11370 (grub_reiserfs_close): Release memory used by journal.
11371
11372 * fs/affs.c (grub_affs_read_block): Change block type to
11373 grub_disk_addr_t. Use grub_divmod64 to do 64-bit division.
11374
11375 * fs/afs.c (grub_afs_read_block): Change block type to grub_disk_addr_t.
11376
11377 * fs/hfsplus.c (grub_hfsplus_read_block): Likewise.
11378
11379 * fs/ntfs.c (grub_ntfs_read_block): Likewise.
11380
11381 * fs/udf.c (grub_udf_read_block): Change block type to
11382 grub_disk_addr_t. Use type cast to avoid warning.
11383
11384 * fs/xfs.c (grub_xfs_read_block): Likewise.
11385
b7c6bed5 113862008-05-16 Christian Franke <franke@computer.org>
11387
11388 * commands/cat.c (grub_cmd_cat): Remove non-ESC keys from keyboard queue
11389 to ensure that break with ESC will always work.
11390 * commands/sleep.c (grub_interruptible_millisleep): Likewise.
11391 Remove ESC from keyboard queue.
11392
eedf167f 113932008-05-16 Christian Franke <franke@computer.org>
11394
11395 * util/biosdisk.c: [__CYGWIN__] Add includes.
11396 (grub_util_biosdisk_open): Use Linux code also for Cygwin.
11397 (get_os_disk): Move variable declarations to OS specific
11398 parts to avoid warning.
11399 [__GNU__] (get_os_disk): Fix /dev/sdXsN case.
11400 [__CYGWIN__] (get_os_disk): Add Cygwin /dev/sdXN device names.
11401 (grub_util_biosdisk_get_grub_dev): Use Linux code also for
11402 Cygwin.
11403 * util/getroot.c: [__CYGWIN__] Add includes.
11404 (strip_extra_slashes): Fix "/" case.
11405 [__CYGWIN__] (get_win32_path): New function.
11406 [__CYGWIN__] (grub_get_prefix): Add conversion to win32 path.
11407 [__CYGWIN__] (find_root_device): Disable.
11408 [__CYGWIN__] (get_bootsec_serial): New function.
11409 [__CYGWIN__] (find_cygwin_root_device): Likewise.
11410 [__linux__] (grub_guess_root_device): Add early returns to simplify
11411 structure.
11412 [__CYGWIN__] (grub_guess_root_device): Call find_cygwin_root_device.
11413 [__linux__] (grub_util_get_dev_abstraction): Enable LVM and RAID
11414 check for Linux only.
11415
a079699e 114162008-05-15 Bean <bean123ch@gmail.com>
11417
11418 * kern/i386/pc/startup.S (grub_console_getkey): Workaround for the
11419 keyboard hang problem in apple's intel mac.
11420
1cf4059a 114212008-05-09 Robert Millan <rmh@aybabtu.com>
11422
11423 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle Virtio
11424 devices.
11425 * util/grub-mkdevicemap.c (get_virtio_disk_name)
11426 (make_device_map): Likewise.
11427 Reported by Aurelien Jarno <aurel32@debian.org>
11428
ed759390 114292008-05-07 Ian Campbell <ijc@hellion.org.uk>
11430
11431 * util/biosdisk.c (get_os_disk): Recognise xvd type disks.
11432 * util/grub-mkdevicemap.c (get_xvd_disk_name): New function.
11433 (make_device_map): Output entries for xvd type disks.
11434
b56c4eaa 114352008-05-07 Robert Millan <rmh@aybabtu.com>
11436
11437 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle CCISS
11438 devices.
11439 * util/grub-mkdevicemap.c (get_cciss_disk_name)
11440 (make_device_map): Likewise.
11441 Reported by Roland Dreier <rdreier@cisco.com>
11442
7f8866ed 114432008-05-07 Robert Millan <rmh@aybabtu.com>
11444
11445 * disk/lvm.c (grub_lvm_scan_device): Detect errors in an additional
11446 grub_strstr() call. Correct a few mistakes in failure path handling.
11447
b0346e0f 114482008-05-06 Robert Millan <rmh@aybabtu.com>
11449
11450 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
11451 Do not print a trailing slash (therefore, the root directory is an
11452 empty string).
11453 (convert_system_path_to_grub_path): Do not remove trailing slash
11454 from make_system_path_relative_to_its_root() output.
11455
11456 * util/i386/pc/grub-install.in: Add trailing slash to output from
11457 make_system_path_relative_to_its_root().
11458
6cf12cbd 114592008-05-06 Robert Millan <rmh@aybabtu.com>
11460
11461 * util/grub-fstest.c (grub_refresh): Call `fflush (stdout)'. This
11462 ensures that output lines aren't intermangled with those sent to
11463 stderr (via grub_util_info()).
11464 * util/grub-probe.c (grub_refresh): Likewise.
11465 * util/i386/pc/grub-setup.c (grub_refresh): Likewise.
11466
0fbb3117 114672008-05-05 Christian Franke <franke@computer.org>
11468
11469 * util/grub-mkdevicemap.c (get_floppy_disk_name) [__CYGWIN__]:
11470 Add Cygwin device names.
11471 (get_ide_disk_name) [__CYGWIN__]: Likewise.
11472 (get_scsi_disk_name) [__CYGWIN__]: Likewise.
11473 (check_device): Return error instead of success on empty name.
11474 (make_device_map): Move label inside linux specific code to
11475 prevent compiler warning.
11476
8124cdb7 114772008-04-30 Robert Millan <rmh@aybabtu.com>
11478
11479 Based on patch from Fabian Greffrath <greffrath@leat.rub.de>
11480 * util/grub.d/10_linux.in: Add ${GRUB_CMDLINE_LINUX_DEFAULT} to the
11481 first boot option.
11482 * util/update-grub.in: Export GRUB_CMDLINE_LINUX_DEFAULT.
11483
094c01d0 114842008-04-29 Robert Millan <rmh@aybabtu.com>
11485
11486 * docs/grub.cfg: New file (example GRUB configuration).
11487
f4b1fc02 114882008-04-26 Robert Millan <rmh@aybabtu.com>
11489
329ce2a5 11490 * DISTLIST: Sort (sort -u < DISTLIST | sponge DISTLIST). Add
11491 `loader/i386/ieee1275/linux.c', `loader/i386/ieee1275/linux_normal.c'
11492 and `disk/ieee1275/nand.c'.
f4b1fc02 11493
25f16ec1 114942008-04-25 Bean <bean123ch@gmail.com>
f19dbdb7 11495
25f16ec1 11496 * Makefile.in (RMKFILES): Add missing arch i386-ieee1275 and
11497 i386-linuxbios.
11498
11499 * commands/hexdump.c (grub_cmd_hexdump): Support dumping of device,
11500 change the buffer size to 4096 for cdrom device.
11501
11502 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add _linux.mod, linux.mod
11503 and nand.mod.
11504 (_linux_mod_SOURCES): New variable.
11505 (_linux_mod_CFLAGS): Likewise.
11506 (_linux_mod_LDFLAGS): Likewise.
11507 (linux_mod_SOURCES): Likewise.
11508 (linux_mod_CFLAGS): Likewise.
11509 (linux_mod_LDFLAGS): Likewise.
11510 (nand_mod_SOURCES): Likewise.
11511 (nand_mod_CFLAGS): Likewise.
11512 (nand_mod_LDFLAGS): Likewise.
11513
11514 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Return
11515 GRUB_ERR_UNKNOWN_DEVICE instead of GRUB_ERR_BAD_DEVICE if no device
11516 type property. (nand device in olpc don't have this property)
11517
11518 * include/grub/disk.h (grub_disk_dev_id): New macro
11519 GRUB_DISK_DEVICE_NAND_ID.
11520
11521 * include/grub/i386/ieee1275/loader.h (grub_rescue_cmd_linux): New
11522 function prototype.
11523 (grub_rescue_cmd_initrd): Likewise.
11524
11525 * include/grub/i386/linux.h (GRUB_LINUX_OFW_SIGNATURE): New macro.
11526 (linux_kernel_params): Add new member ofw_signature, ofw_num_items,
11527 ofw_cif_handler and ofw_idt, adjust padding number.
f19dbdb7 11528
25f16ec1 11529 * include/grub/i386/pc/memory.h (grub_upper_mem): Export it if
11530 GRUB_MACHINE_IEEE1275 is defined.
11531
11532 * include/grub/ieee1275/ieee1275.h (grub_available_iterate):
11533 Use NESTED_FUNC_ATTR attribute on the hook parameter.
11534
11535 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Use NESTED_FUNC_ATTR
11536 on nested function heap_init.
11537 (grub_upper_mem): New variable for i386-ieee1275.
11538 (grub_get_extended_memory): New function for i386-ieee1275.
11539 (grub_machine_init): Call grub_get_extended_memory for i386-ieee1275.
11540
11541 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Use
11542 NESTED_FUNC_ATTR on the hook parameter. Don't quit if no device type
11543 property.
f19dbdb7 11544
25f16ec1 11545 * loader/i386/ieee1275/linux.c: New file.
11546
11547 * loader/i386/ieee1275/linux_normal.c: New file.
11548
11549 * disk/ieee1275/nand.c: New file.
11550
e89d61e9 115512008-04-18 Thomas Schwinge <tschwinge@gnu.org>
11552
11553 * util/i386/pc/grub-mkrescue.in (grub_mkimage): Don't overwrite correct
11554 value.
11555 * util/powerpc/ieee1275/grub-mkrescue.in (grub_mkimage): Likewise.
11556
602566f6 115572008-04-18 Robert Millan <rmh@aybabtu.com>
11558
11559 Restructures early code path on ieee1275 to unify grub_main() as
11560 the first C function that is executed in every platform.
11561
11562 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_init): New prototype.
11563 * kern/i386/ieee1275/startup.S (_start): Jump to grub_main() instead of
11564 cmain().
11565 * kern/powerpc/ieee1275/crt0.S (_start): Likewise.
11566 * kern/ieee1275/cmain.c (cmain): Rename to ...
11567 * kern/ieee1275/cmain.c (grub_ieee1275_init): ... this.
11568 * kern/ieee1275/init.c (grub_machine_init): Call grub_ieee1275_init()
11569 at the beginning.
11570
57490c2b 115712008-04-18 Robert Millan <rmh@aybabtu.com>
11572
11573 * util/update-grub.in: Fix syntax error when setting
11574 `GRUB_PRELOAD_MODULES'.
11575 Reported by Stephane Chazelas <stephane@artesyncp.com>
11576
1977517d 115772008-04-17 Lubomir Kundrak <lkundrak@redhat.com>
11578
11579 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): take only .text
11580 section into account, newer toolchains generate unique build ids
11581 * configure.ac: remove the test for --build-id=none acceptance,
e0c5dacb 11582 we want build ids to be preserved
1977517d 11583 * genmk.rb: add -R .note.gnu.build-id to objcopy, so build id
11584 far from other sections don't cause the raw binary images grow
11585 size
11586
bfb1f1a2 115872008-04-15 Robert Millan <rmh@aybabtu.com>
11588
11589 * disk/lvm.c: Update copyright year.
11590 * kern/misc.c: Likewise.
11591
01979850 115922008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
11593
11594 * disk/lvm.c (grub_lvm_scan_device): Add forgotten failure path when
f19dbdb7 11595 there is no memory left for physical volume name.
01979850 11596
0a1150e2 115972008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
11598
11599 * disk/lvm.c (grub_lvm_scan_device): Fix logical volume's physical
11600 volume name mapping to support bigger than 9 character names properly.
11601
82ead3fe 116022008-04-13 Robert Millan <rmh@aybabtu.com>
11603
11604 * disk/i386/pc/biosdisk.c (grub_biosdisk_rw): Fix CHS limit check,
11605 as per http://www.allensmith.net/Storage/HDDlimit/Int13h.htm
11606
e54a72f5 116072008-04-13 Christian Franke <franke@computer.org>
11608
11609 * util/i386/pc/grub-mkrescue.in: Add --emulation=floppy
11610 to create a floppy emulation boot CD when non emulation mode
11611 does not work.
11612 Enable Joliet CD filesystem extension.
11613
9fe86034 116142008-04-13 Robert Millan <rmh@aybabtu.com>
11615
11616 * kern/misc.c (grub_strncat): Fix off-by-one error.
11617 Reported by Zhang Huan <zhanghuan@nrchpc.ac.cn>
11618
11619 * kern/env.c (grub_env_context_close): Clear current context, not
11620 previous one.
11621 Patch from Zhang Huan <zhanghuan@nrchpc.ac.cn>
11622
11623 * kern/misc.c (grub_strcat): Minor speed optimization (same code size).
11624
7ceeee39 116252008-04-13 Robert Millan <rmh@aybabtu.com>
11626
11627 Improve robustness when handling LVM.
11628
11629 * disk/lvm.c (grub_lvm_getvalue): Return 0 when `*p' is NULL
f19dbdb7 11630 (and leave `*p' unmodified).
7ceeee39 11631 (grub_lvm_iterate): Don't assume `vg->lvs != NULL' when iterating
11632 through it.
11633 (grub_lvm_memberlist): Don't assume `lv->vg->pvs != NULL' when
11634 iterating through it.
11635 (grub_lvm_open): Don't assume `vg->lvs != NULL' when iterating
11636 through it.
fe6b695a 11637 (grub_lvm_scan_device): Check the return value (and fail gracefully
7ceeee39 11638 when due) on each grub_lvm_getvalue() or grub_strstr() call.
11639 Don't assume `vg->pvs != NULL' when iterating through it.
11640
58cd3d85 116412008-04-13 Robert Millan <rmh@aybabtu.com>
11642
11643 * gendistlist.sh (EXTRA_DISTFILES): Add `genpartmaplist.sh'.
11644 * genmk.rb (partmap): New variable.
11645 (CLEANFILES, PARTMAPFILES): Add #{partmap}.
11646 (#{partmap}): New target rule.
11647 * genpartmaplist.sh: New file.
11648 * Makefile.in (pkglib_DATA): Add partmap.lst.
11649 (partmap.lst): New target rule.
11650 * util/i386/pc/grub-mkrescue.in: Generate grub.cfg that loads needed
11651 modules (including all partition maps), instead of preloading them.
11652
78b51059 116532007-04-13 Fabian Greffrath <fabian.greffrath@web.de>
11654
11655 * util/grub.d/30_os-prober.in: New script. Use `os-prober' and
11656 `linux-boot-prober' (if installed) to detect other operating
11657 systems which are installed on the computer and add them to
11658 the boot menu.
11659 * conf/common.rmk: Build and install 30_os-prober.
11660
a91627b4 116612008-04-12 Robert Millan <rmh@aybabtu.com>
11662
11663 * kern/powerpc/ieee1275/init.c: Move from here ...
11664 * kern/ieee1275/init.c: ... to here. Update all users.
11665
11666 * kern/powerpc/ieee1275/cmain.c: Move from here ...
11667 * kern/ieee1275/cmain.c: ... to here. Update all users.
11668
11669 * kern/powerpc/ieee1275/openfw.c: Move from here ...
11670 * kern/ieee1275/openfw.c: ... to here. Update all users.
11671
11672 * loader/powerpc/ieee1275/multiboot2.c: Move from here ...
11673 * loader/ieee1275/multiboot2.c: ... to here. Update all users.
11674
322562ea 116752008-04-10 Pavel Roskin <proski@gnu.org>
11676
11677 * configure.ac: Always use "_cv_" in cache variables for
11678 compatibility with Autoconf 2.62.
11679
a02a73c5 116802008-04-07 Robert Millan <rmh@aybabtu.com>
11681
11682 Revert grub/machine/init.h addition by Pavel (since it breaks on
11683 i386-ieee1275 and others):
11684 * util/i386/pc/misc.c: Remove grub/machine/init.h.
11685 * util/powerpc/ieee1275/misc.c: Likewise.
11686
25c024b1 116872008-04-07 Robert Millan <rmh@aybabtu.com>
11688
11689 * util/grub-probe.c (probe): Improve error message.
11690
3cbd2f98 116912008-04-07 Robert Millan <rmh@aybabtu.com>
11692
11693 * util/biosdisk.c (read_device_map): Skip devices that don't exist
11694 (this prevents the presence of a bogus entry from ruining the whole
11695 thing).
11696
87a297bf 116972008-04-06 Pavel Roskin <proski@gnu.org>
11698
36747a62 11699 * util/biosdisk.c: Include grub/util/biosdisk.h.
11700 * util/grub-fstest.c (execute_command): Make static.
11701 * util/grub-mkdevicemap.c (check_device): Likewise.
11702 * util/i386/pc/misc.c: Include grub/machine/init.h.
11703 * util/powerpc/ieee1275/misc.c: Likewise.
11704 * util/lvm.c: Include grub/util/lvm.h.
11705 * util/misc.c: Include grub/kernel.h, grub/misc.h and
11706 grub/cache.h.
11707 * util/raid.c: Include grub/util/raid.h.
11708 (grub_util_getdiskname): Make static.
11709
87a297bf 11710 * util/grub-emu.c (main): Remove calls to grub_hostfs_init() and
11711 grub_hostfs_fini(), as they are called from grub_init_all() and
11712 grub_fini_all() respectively. This fixes an infinite loop in
11713 grub-fstest due to double registration of hostfs.
11714 Reported by Christian Franke <Christian.Franke@t-online.de>
11715
f6ce7629 117162008-04-05 Pavel Roskin <proski@gnu.org>
11717
11718 * bus/pci.c (grub_pci_iterate): For multifunction devices, probe
11719 all 8 functions. Otherwise, probe function 0 only.
11720
070e49e4 117212008-04-04 Pavel Roskin <proski@gnu.org>
11722
8b088a4c 11723 * commands/lspci.c (grub_lspci_iter): Print the bus number
11724 correctly.
11725
4f657021 11726 * commands/lspci.c (grub_pci_classes): Fix typos.
11727 (grub_lspci_iter): Don't print func twice. Print vendor ID
11728 before device ID, as it's normally done.
11729
070e49e4 11730 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
11731 Fix signedness warnings.
11732 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate):
11733 Likewise.
11734 * util/ieee1275/get_disk_name.c: Include config.h so that
11735 _GNU_SOURCE is defined and getline() is declared. Mark an
11736 unused argument as such. Fix a signedness warning.
11737
ba7328dc 117382008-04-02 Pavel Roskin <proski@gnu.org>
11739
26887f22 11740 * genkernsyms.sh.in: Use more robust assignments for CC and
11741 srcdir. Quote srcdir.
11742 * gensymlist.sh.in: Likewise. Assert at the compile time that
11743 the symbol table is not empty.
11744
ba7328dc 11745 * disk/raid.c (grub_raid_memberlist): Fix a signedness warning.
11746 * fs/cpio.c (grub_cpio_read): Likewise.
11747
0f582c6b 117482008-04-01 Pavel Roskin <proski@gnu.org>
11749
4b6e1995 11750 * disk/ata.c (grub_ata_open): Don't lose precision in disk->id.
11751 * disk/host.c (grub_host_open): Likewise.
11752 * disk/loopback.c (grub_loopback_open): Likewise.
11753 * disk/memdisk.c (grub_memdisk_open): Use a string pointer for
11754 disk->id as in disk/host.c, not a multi-character constant.
11755
828a2768 11756 * util/grub-fstest.c (cmd_cmp): Use fseeko(), not fseek(). The
11757 later is obsolete, potentially dangerous and sets a bad example.
11758 * util/i386/efi/grub-mkimage.c (make_header): Likewise.
11759 * util/misc.c (grub_util_get_image_size): Likewise.
11760
2bb4fb47 11761 * disk/loopback.c (options): Improve help for "--partitions".
11762
0f582c6b 11763 * normal/arg.c (grub_arg_show_help): Fix spacing of the long
11764 options to align them with the short options, e.g. "echo -e".
11765
a33224e0 117662008-03-31 Bean <bean123ch@gmail.com>
11767
11768 * video/reader/png.c (grub_png_data): New member is_16bit and
11769 image_data.
11770 (grub_png_decode_image_header): Detect 16 bit png image.
11771 (grub_png_convert_image): New function to convert 16 bit image to 8 bit.
11772 (grub_png_decode_png): Call grub_png_convert_image for 16 bit image.
11773 (grub_video_reader_png): Release memory occupied by image_data.
11774
11775 * fs/ntfs.c (find_attr): Handle non-resident attribute list larger than
11776 4096 bytes.
11777 (grub_nfs_mount): Skip the test for sector per cluster.
11778
11779 * include/grub/ntfs.h (MAX_SPC): Removed.
11780
86cb4f54 117812008-03-31 Bean <bean123ch@gmail.com>
11782
11783 * conf/common.rmk (pkgdata_MODULES): Add afs.mod.
11784 (grub_probe_SOURCES): Add fs/afs.c.
11785 (grub_fstest_SOURCES): Likewise.
11786 (afs_mod_SOURCES): New variable.
11787 (afs_mod_CFLAGS): Likewise.
11788 (afs_mod_LDFLAGS): Likewise.
11789
11790 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/afs.c.
11791 (grub_emu_SOURCES): Likewise.
11792
11793 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
11794
11795 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11796
11797 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
11798
11799 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11800
11801 * fs/afs.c: New file.
11802
17c74c21 118032008-03-30 Pavel Roskin <proski@gnu.org>
11804
4cb68e89 11805 * disk/host.c: Include grub/misc.h to fix a warning.
11806 * util/hostfs.c: Use GRUB_MOD_INIT and GRUB_MOD_FINI to fix
11807 warnings about implicit declarations.
11808
8790bb04 11809 * fs/udf.c (grub_udf_mount): Fix warning about a shadowing a
11810 variable.
11811 * include/grub/i386/loader.h: Change declaration of
11812 grub_linux_boot() to match what grub_loader_set() expects.
11813 * util/getroot.c (grub_guess_root_device): Return const char* to
11814 fix a warning.
11815 * util/grub-probe.c (probe): Fix a warning about uninitialized
11816 abstraction_name variable.
11817 * util/i386/get_disk_name.c (grub_util_get_disk_name): Mark
11818 second argument as unused to fix a warning.
11819
9a3f3296 11820 * loader/i386/pc/multiboot2.c (grub_mb2_arch_elf64_hook): Add
11821 missing grub_error() call.
11822
0ecef90d 11823 * util/update-grub_lib.in: Define datarootdir, since Autoconf
11824 2.60 and newer uses it to define datadir.
11825
0bf6d401 11826 * commands/sleep.c: Fix warning about implicit declaration.
11827 * disk/memdisk.c: Likewise.
11828 * loader/aout.c: Likewise.
11829 * loader/i386/bsd_normal.c: Likewise.
11830 * util/grub-probe.c: Likewise.
11831
7cdacf97 11832 * commands/i386/cpuid.c (has_longmode): Make static.
11833 * disk/i386/pc/biosdisk.c (cd_drive): Likewise.
11834 * include/grub/i386/bsd.h (bios_memmap_t): Remove, it's unused.
11835
17c74c21 11836 * kern/i386/pc/startup.S (real_to_prot): Use %cs prefix to load
11837 GDT. This is more robust, as %ds can change.
11838 (grub_biosdisk_rw_int13_extensions): Don't clear %ds before
11839 calling real_to_prot().
11840 (grub_biosdisk_get_diskinfo_int13_extensions): Likewise.
11841
80a3e68b 118422008-03-28 Pavel Roskin <proski@gnu.org>
11843
11844 * kern/i386/pc/startup.S: Assert that uncompressed functions
11845 don't spill beyond GRUB_KERNEL_MACHINE_RAW_SIZE.
11846 * kern/i386/pc/lzo1x.S: Remove all .align directives in the
11847 code, as they push parts of the code (error handlers) beyond
11848 GRUB_KERNEL_MACHINE_RAW_SIZE. Speed is not as important in this
11849 code as correctness and size.
11850
77bcd272 118512008-03-28 Pavel Roskin <proski@gnu.org>
11852
11853 * kern/i386/pc/startup.S
11854 (grub_biosdisk_get_diskinfo_int13_extensions): When converting
11855 data block address to the real mode, keep offset minimal. This
11856 works around a bug in AWARD BIOS on old Athlon systems, which
11857 makes CD detection hang.
11858
c5dfd43b 118592008-03-26 Pavel Roskin <proski@gnu.org>
11860
11861 * normal/color.c (grub_parse_color_name_pair): Make `name' a
11862 const.
11863 * include/grub/normal.h: Add grub_parse_color_name_pair()
11864 declaration.
11865
bf962df2 118662008-03-24 Bean <bean123ch@gmail.com>
11867
11868 * disk/i386/pc/biosdisk.c (cd_start): Removed.
11869 (cd_count): Removed.
11870 (cd_drive): New variable.
11871 (grub_biosdisk_get_drive): Don't check for (cdN) device.
11872 (grub_biosdisk_call_hook): Likewise.
11873 (grub_biosdisk_iterate): Change cdrom detection method.
11874 (grub_biosdisk_open): Replace cd_start with cd_drive.
11875 (GRUB_MOD_INIT): Use grub_biosdisk_get_cdinfo_int13_extension to
11876 detect cdrom device.
11877
11878 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_MACHINE_CDROM_START):
11879 Removed.
11880 (GRUB_BIOSDISK_MACHINE_CDROM_END): Removed.
11881 (GRUB_BIOSDISK_CDTYPE_NO_EMUL): New macro.
11882 (GRUB_BIOSDISK_CDTYPE_1_2_M): Likewise.
11883 (GRUB_BIOSDISK_CDTYPE_1_44_M): Likewise.
11884 (GRUB_BIOSDISK_CDTYPE_2_88_M): Likewise.
11885 (GRUB_BIOSDISK_CDTYPE_HARDDISK): Likewise.
11886 (GRUB_BIOSDISK_CDTYPE_MASK): Likewise.
11887 (grub_biosdisk_cdrp): New structure.
11888 (grub_biosdisk_get_cdinfo_int13_extensions): New function.
11889
11890 * include/grub/i386/pc/kernel.h (grub_boot_drive): Export this variable.
11891
11892 * kern/i386/pc/init.c (make_install_device): Don't use (cdN) as root
11893 device.
11894
11895 * kern/i386/pc/startup.S (grub_biosdisk_get_cdinfo_int13_extensions):
11896 New function.
11897
68e7fc7a 118982008-03-20 Robert Millan <rmh@aybabtu.com>
11899
11900 Remove 2 TiB limit in ata.mod.
11901 * disk/ata.c (grub_ata_device): Promote `size' to grub_uint64_t.
11902 (grub_ata_dumpinfo): Print sector count with 0x%llx.
11903 (grub_ata_identify): Interpret `&info16[100]' as a pointer to
11904 grub_uint64_t instead of grub_uint32_t.
11905
38ad2cf5 119062008-03-05 Bean <bean123ch@gmail.com>
11907
11908 * loader/i386/pc/multiboot.c (grub_multiboot_get_bootdev): New function.
11909 (grub_multiboot): Set boot device.
11910
11911 * boot/i386/pc/lnxboot.S (real_code_2): Set %dh to 0xFF.
11912
2b89344e 119132008-03-02 Bean <bean123ch@gmail.com>
11914
11915 * fs/reiserfs.c (grub_reiserfs_read_symlink): Add 0 at the end of
11916 symlink_buffer.
11917
87a95d1f 119182008-03-01 Yoshinori K. Okuji <okuji@enbug.org>
11919
11920 * DISTLIST: Added docs/fdl.texi, docs/grub.texi, docs/mdate-sh and
11921 texinfo.tex.
11922
11923 * docs/grub.texi: New file. Copied from GRUB Legacy, and slightly
11924 modified.
11925
11926 * docs/fdl.texi: New file.
f19dbdb7 11927
87a95d1f 11928 * docs/mdate-sh: New file. Copied from gnulib.
11929 * docs/texinfo.tex: Likewise.
11930
11931 * config.guess: Updated from gnulib.
11932 * install-sh: Likewise.
11933
7dc15d8e 119342008-02-28 Robert Millan <rmh@aybabtu.com>
11935
11936 * conf/i386-linuxbios.rmk (pkglib_MODULES): Add aout.mod.
11937 (aout_mod_SOURCES): New variable.
11938 (aout_mod_CFLAGS): Likewise.
11939 (aout_mod_LDFLAGS): Likewise.
11940
11941 * conf/i386-ieee1275.rmk: Likewise.
11942
b00ab696 119432008-02-28 Robert Millan <rmh@aybabtu.com>
11944
11945 * util/update-grub.in: Reorganise terminal validity check. Accept
11946 `ieee1275:console' (OLPC) and `*:gfxterm' as valid too.
11947 Based on suggestion by Franklin PIAT.
11948
79ca2d78 119492008-02-28 Fabian Greffrath <greffrath@leat.rub.de>
11950
11951 * include/grub/util/getroot.h (grub_util_check_block_device): Export new
11952 function.
11953 * util/getroot.c (grub_util_check_block_device): New function that
11954 returns the given argument if it is a block device and returns NULL else.
11955 * util/grub-probe.c (argument_is_device): New variable.
11956 (probe): Promote device_name from a variable to an argument. Receive
11957 device_name from grub_util_check_block_device() if path is NULL and from
11958 grub_guess_root_device() else. Do not free() device_name anymore.
f19dbdb7 11959 (options): Introduce new parameter '-d, --device'.
79ca2d78 11960 (main): Add description of the new parameter to the help screen.
11961 Rename path variable to argument. Set argument_is_device if the '-d'
11962 option is given. Pass argument to probe() depending on
11963 argument_is_device.
11964
0d16e571 119652008-02-24 Bean <bean123ch@gmail.com>
11966
11967 * fs/iso9660.c (GRUB_ISO9660_VOLDESC_BOOT): New macro.
11968 (GRUB_ISO9660_VOLDESC_PRIMARY): Likewise.
11969 (GRUB_ISO9660_VOLDESC_SUPP): Likewise.
11970 (GRUB_ISO9660_VOLDESC_PART): Likewise.
11971 (GRUB_ISO9660_VOLDESC_END): Likewise.
11972 (grub_iso9660_primary_voldesc): New member escape.
11973 (grub_iso9660_data): New member joliet.
11974 (grub_iso9660_convert_string): New function.
11975 (grub_iso9660_mount): Detect joliet extension.
11976 (grub_iso9660_iterate_dir): Convert filename when joliet is detected.
11977 (grub_iso9660_iso9660_label): Likewise.
11978
11979 * conf/common.rmk (pkgdata_MODULES): Add udf.mod.
11980 (grub_setup_SOURCES): Add fs/udf.c.
11981 (grub_fstest_SOURCES): Likewise.
11982 (udf_mod_SOURCES): New variable.
11983 (udf_mod_CFLAGS): Likewise.
11984 (udf_mod_LDFLAGS): Likewise.
11985
11986 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/udf.c.
11987 (grub_emu_SOURCES): Likewise.
11988
11989 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
11990
11991 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11992
11993 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
11994
11995 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11996
11997 * fs/udf.c: New file.
11998
8a594a17 119992008-02-24 Robert Millan <rmh@aybabtu.com>
12000
12001 * conf/i386-efi.rmk (normal/function.c_DEPENDENCIES)
12002 (normal/lexer.c_DEPENDENCIES): New variables.
12003 * conf/i386-ieee1275.rmk (normal/function.c_DEPENDENCIES)
12004 (normal/lexer.c_DEPENDENCIES): Likewise.
12005 * conf/i386-linuxbios.rmk (normal/function.c_DEPENDENCIES)
12006 (normal/lexer.c_DEPENDENCIES): Likewise.
12007 * conf/i386-pc.rmk (normal/function.c_DEPENDENCIES)
12008 (normal/lexer.c_DEPENDENCIES): Likewise.
12009 * conf/powerpc-ieee1275.rmk (normal/function.c_DEPENDENCIES)
12010 (normal/lexer.c_DEPENDENCIES): Likewise.
12011 * conf/sparc64-ieee1275.rmk (normal/function.c_DEPENDENCIES)
12012 (normal/lexer.c_DEPENDENCIES): Likewise.
12013
2dc33c03 120142008-02-23 Robert Millan <rmh@aybabtu.com>
12015
12016 * partmap/gpt.c (grub_gpt_magic): Add `0x' qualifier to each member,
12017 since they were intended to be in hex. This didn't break previously
12018 because of a bug in gpt_partition_map_iterate() (see below).
12019
12020 (gpt_partition_map_iterate): Replace `grub_memcmp' with `! grub_memcmp'
12021 when checking the validity of GPT header.
12022 Remove `partno', since it always provides the same information as `i'.
12023
f6f4cfb0 120242008-02-21 Yoshinori K. Okuji <okuji@enbug.org>
12025
12026 * include/grub/efi/time.h: Fix a wrong comment.
12027
79ff665f 120282008-02-19 Pavel Roskin <proski@gnu.org>
12029
12030 * kern/rescue.c (grub_enter_rescue_mode): Improve initial
12031 message.
12032
d38e24c2 120332008-02-19 Bean <bean123ch@gmail.com>
12034
12035 * conf/i386-pc.rmk (pkglib_MODULES): Add aout.mod _bsd.mod and bsd.mod.
12036 (aout_mod_SOURCES): New variable.
12037 (aout_mod_CFLAGS): Likewise.
12038 (aout_mod_LDFLAGS): Likewise.
12039 (_bsd_mod_SOURCES): New variable.
12040 (_bsd_mod_CFLAGS): Likewise.
12041 (_bsd_mod_LDFLAGS): Likewise.
12042 (bsd_mod_SOURCES): New variable.
12043 (bsd_mod_CFLAGS): Likewise.
12044 (bsd_mod_LDFLAGS): Likewise.
12045
12046 * include/grub/aout.h: New file.
12047
12048 * include/grub/i386/loader.h (grub_unix_real_boot): New function.
12049
12050 * include/grub/i386/bsd.h: New file.
12051
12052 * include/grub/i386/pc/init.h (grub_get_mmap_entry): Use EXPORT_FUNC
12053 to make it public.
12054
12055 * kern/elf.c (grub_elf32_load): Get the physical address after the hook
12056 function is called, so that it's possible to change it inside the hook.
12057 (grub_elf64_load): Likewise.
12058 (grub_elf_file): Don't close the file if elf header is not found.
12059 (grub_elf_close): Close the file if grub_elf_file fails (The new
12060 grub_elf_file won't close it).
12061 (grub_elf32_size): Use NESTED_FUNC_ATTR for nested function calcsize.
12062 (grub_elf64_size): Likewise.
12063
12064 * kern/i386/loader.S (grub_unix_real_boot): New function.
12065
12066 * loader/aout.c: New file.
12067
12068 * loader/i386/bsd.c: New file.
12069
12070 * loader/i386/bsd_normal.c: New file.
12071
12072 * loader/i386/pc/multiboot.c (grub_multiboot): Handle a.out format.
12073
12074 * loader/multiboot2.c (grub_multiboot2): Reset grub_errno so that it
fe987087 12075 can test other formats.
d38e24c2 12076
b93bdb0f 120772008-02-19 Robert Millan <rmh@aybabtu.com>
12078
12079 * partmap/gpt.c: Include `<grub/gpt_partition.h>'.
12080 (grub_gpt_partition_type_empty): Redefine with macro from
12081 `<grub/gpt_partition.h>'.
12082 (gpt_partition_map_iterate): Adjust partition type comparison.
12083
12084 Export `entry' as partmap-specific `part.data' struct.
12085 (grub_gpt_header, grub_gpt_partentry): Move from here ...
12086
12087 * include/grub/gpt_partition.h (grub_gpt_header)
12088 (grub_gpt_partentry): ... to here (new file).
12089
12090 * util/i386/pc/grub-setup.c: Include `<grub/gpt_partition.h>'.
12091
12092 (grub_gpt_partition_type_bios_boot): New const variable, defined
12093 with macro from `<grub/gpt_partition.h>'.
12094
12095 (setup): Replace `first_start' with `embed_region', which keeps
12096 track of the embed region (and is partmap-agnostic).
12097
12098 Replace find_first_partition_start() with find_usable_region(),
12099 which finds a usable region for embedding using partmap-specific
12100 knowledge (supports PC/MSDOS and GPT).
12101
12102 Fix all assumptions that the embed region start at sector 1, using
12103 `embed_region.start' from now on. Similarly, use `embed_region.end'
12104 rather than `first_start' to calculate available size.
12105
12106 In grub_util_info() message, replace "into after the MBR" with an
12107 indication of the specific sector our embed region starts at.
12108
66cb40f6 121092008-02-19 Robert Millan <rmh@aybabtu.com>
12110
12111 * DISTLIST: Replace `commands/ieee1275/halt.c' and
12112 `commands/ieee1275/reboot.c' with `commands/halt.c' and
12113 `commands/reboot.c'.
12114 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
12115 (halt_mod_SOURCES): Likewise.
12116 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
12117 (halt_mod_SOURCES): Likewise.
12118
b7202015 121192008-02-17 Christian Franke <franke@computer.org>
12120
12121 * commands/cat.c (grub_cmd_cat): Add break on GRUB_TERM_ESC key.
12122
32b0fc49 121232008-02-17 Robert Millan <rmh@aybabtu.com>
12124
12125 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
12126 set `first_start' to 0 for non-PC/MSDOS partition maps.
12127
aca63502 121282008-02-16 Robert Millan <rmh@aybabtu.com>
12129
12130 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
12131 do not assume partition map is PC/MSDOS before performing checks that
12132 are specific to that layout.
12133
0de8be86 121342008-02-13 Robert Millan <rmh@aybabtu.com>
12135
12136 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Remove
12137 `commands/i386/pc/halt.c' and `commands/i386/pc/reboot.c'.
12138 * kern/i386/linuxbios/init.c (grub_halt, grub_reboot): Remove stubs.
12139
c3db8364 121402008-02-13 Yoshinori K. Okuji <okuji@enbug.org>
12141
12142 * configure.ac: Only a cosmetic change on the handling of
12143 -fno-stack-protector.
12144
f714229e 121452008-02-12 Alexandre Boeglin <alex@boeglin.org>
12146
c3db8364 12147 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace
12148 commands/i386/pc/halt.c and reboot.c by commands/halt.c and
12149 reboot.c.
f714229e 12150 (grub_install_SOURCES): Add halt.mod and reboot.mod.
12151 (halt_mod_SOURCES): New variable.
12152 (halt_mod_CFLAGS): Likewise.
12153 (halt_mod_LDFLAGS): Likewise.
12154 (reboot_mod_SOURCES): Likewise.
12155 (reboot_mod_CFLAGS): Likewise.
12156 (reboot_mod_LDFLAGS): Likewise.
12157
c3db8364 12158 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace
12159 commands/ieee1275/halt.c and reboot.c by commands/halt.c and
12160 reboot.c.
f714229e 12161 (halt_mod_SOURCES): Likewise.
12162 (reboot_mod_SOURCES): Likewise.
12163
c3db8364 12164 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace
12165 commands/i386/pc/reboot.c by commands/reboot.c.
f714229e 12166 (reboot_mod_SOURCES): Likewise.
12167
12168 * commands/i386/pc/reboot.c: merge this file ...
12169
12170 * commands/ieee1275/reboot.c: ... and this file ...
12171
12172 * commands/reboot.c: ... to this file.
c3db8364 12173 Add some precompiler directive to include the correct header for
12174 each machine.
f714229e 12175
12176 * commands/ieee1275/halt.c: move this file ...
12177
12178 * commands/halt.c: ... to here.
c3db8364 12179 Add some precompiler directive to include the correct header for
12180 each machine.
f714229e 12181
12182 * include/grub/efi/efi.h (grub_reboot): New function declaration.
12183 (grub_halt): Likewise.
12184
12185 * kern/efi/efi.c (grub_reboot): New function.
12186 (grub_halt): Likewise.
12187
c74493e0 121882008-02-12 Robert Millan <rmh@aybabtu.com>
12189
12190 * util/getroot.c (grub_guess_root_device): Inspect /dev/evms before
12191 /dev (like it is done for /dev/mapper). This doesn't provide support
12192 for EVMS, but at least it is now easy to identify the problem when it
12193 arises.
12194
d0db4b04 121952008-02-11 Robert Millan <rmh@aybabtu.com>
12196
12197 * util/biosdisk.c (grub_util_biosdisk_open, linux_find_partition)
12198 (grub_util_biosdisk_get_grub_dev): Check open() exit status by
12199 comparing it with -1, not 0.
12200
bf748642 122012008-02-10 Robert Millan <rmh@aybabtu.com>
12202
12203 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `disk/raid.c' and
12204 `disk/lvm.c'.
12205 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
12206 * conf/i386-pc.rmk (grub_setup_SOURCES): Likewise.
12207
12208 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Move `disk/raid.c' and
12209 `disk/lvm.c' to the end of the list.
12210 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
12211 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
12212
b5db202a 122132008-02-10 Robert Millan <rmh@aybabtu.com>
12214
12215 * kern/main.c (grub_load_normal_mode): Do not reset `grub_errno'. Call
12216 grub_print_error() instead. This will let user know why we're entering
12217 rescue mode.
12218 Based on suggestions from Sam Morris.
12219
83abee31 122202008-02-10 Alexandre Boeglin <alex@boeglin.org>
12221
12222 * normal/arg.c (grub_arg_parse): If one of the args is "--", call add_arg()
12223 on remaining N args, instead of "--" arg N times.
12224
78d5a08b 122252008-02-09 Vesa Jaaskelainen <chaac@nic.fi>
12226
12227 * font/manager.c (unknown_glyph): Added variable for unknown glyph.
12228 (fill_with_default_glyph): Changed to use unknown_glyph for fill
12229 pattern for unknown glyphs.
12230
68807e5f 122312008-02-09 Robert Millan <rmh@aybabtu.com>
12232
12233 * configure.ac: Probe for `help2man'.
12234 * Makefile.in (builddir): New variable.
12235 (HELP2MAN): Likewise. Set to `true' when @HELP2MAN@ doesn't provide it,
12236 or otherwise add a few flags/options to it.
12237 (install-local): For every executable utility or script that is
12238 installed, invoke $(HELP2MAN) to install a manpage based on --help
12239 output.
12240
12241 * util/i386/pc/grub-install.in: Move down `update-grub_lib' sourcing, so
12242 that it doesn't prevent --help from working in build tree.
12243
12244 * util/i386/pc/grub-mkrescue.in (usage): Replace `grub-devel@gnu.org'
12245 with `bug-grub@gnu.org'.
12246 * util/powerpc/ieee1275/grub-mkrescue.in (usage): Likewise.
12247 * util/update-grub.in (usage): New function.
12248 Implement proper argument check, with support for --help and --version
12249 (as well as existing -y).
12250
122512008-02-09 Christian Franke <franke@computer.org>
0d9ff7f0 12252
12253 * commands/cat.c (grub_cmd_cat): Print '\r' as hex to
12254 avoid overwriting previous output.
12255 * kern/rescue.c (grub_rescue_cmd_cat): Likewise.
12256
c1962162 122572008-02-09 Robert Millan <rmh@aybabtu.com>
12258
12259 * normal/menu.c (run_menu): If timeout is set to zero, don't bother
12260 drawing the menu.
12261
3dac2e3f 122622008-02-09 Robert Millan <rmh@aybabtu.com>
12263
12264 * commands/sleep.c: New file.
12265 * conf/common.rmk (pkglib_MODULES): Add `commands/sleep.c'.
12266 (sleep_mod_SOURCES): New variable.
12267 (sleep_mod_CFLAGS): Likewise.
12268 (sleep_mod_LDFLAGS): Likewise.
12269
7a634e08 122702008-02-09 Robert Millan <rmh@aybabtu.com>
12271
12272 * disk/raid.c (grub_raid_scan_device): Add a pair of sanity checks for
12273 situations in which we can deduce the RAID size and the superblock
12274 doesn't match it.
12275
b92f0c18 122762008-02-09 Robert Millan <rmh@aybabtu.com>
12277
12278 * disk/lvm.c [GRUB_UTIL] (grub_lvm_memberlist): New function. Construct
12279 and return a grub_diskmemberlist_t composed of LVM physical volumes.
12280 [GRUB_UTIL] (grub_lvm_dev): Add `memberlist' member.
12281
12282 * disk/raid.c [GRUB_UTIL] (grub_raid_memberlist): New function. Construct
12283 and return a grub_diskmemberlist_t composed of physical array members.
12284 [GRUB_UTIL] (grub_raid_dev): Add `memberlist' member.
12285
12286 * include/grub/disk.h [GRUB_UTIL] (grub_disk_memberlist): New struct
12287 prototype.
12288 [GRUB_UTIL] (struct grub_disk_dev): Add `memberlist' function pointer.
12289 [GRUB_UTIL] (struct grub_disk_memberlist): New struct declaration.
12290 [GRUB_UTIL] (grub_disk_memberlist_t): New typedef.
12291
12292 * util/grub-probe.c (probe): Move partmap probing code from here ...
12293 (probe_partmap): ... to here.
12294 (probe): Use probe_partmap() once for the disk we're probing, and
12295 additionally, when such disk contains a memberlist() struct member,
12296 once for each disk that is contained in the structure returned by
12297 memberlist().
12298
91a4bf68 122992008-02-09 Robert Millan <rmh@aybabtu.com>
12300
12301 * util/grub-probe.c (main): When `verbosity > 1', set `debug'
12302 environment variable to 'all' in order to obtain debug output from
12303 non-util/ code.
12304 * util/i386/pc/grub-setup.c (main): Likewise.
12305
a96f9caa 123062008-02-08 Robert Millan <rmh@aybabtu.com>
12307
12308 * disk/raid.c (grub_raid_scan_device): Check for
12309 `array->device[sb.this_disk.number]' rather than for
12310 `array->device[sb.this_disk.number]->name', since the latter is not
fe6b695a 12311 guaranteed to be accessible.
a96f9caa 12312
b37a9222 123132008-02-08 Robert Millan <rmh@aybabtu.com>
12314
12315 * disk/raid.c: Update copyright.
12316 * fs/cpio.c: Likewise.
12317 * include/grub/raid.h: Likewise.
12318 * loader/i386/pc/multiboot.c: Likewise.
12319 * util/hostfs.c: Likewise.
12320
5626aee1 123212008-02-08 Robert Millan <rmh@aybabtu.com>
12322
12323 * include/grub/raid.h (struct grub_raid_array): Change type of `device'
12324 to a grub_disk_t array.
12325 * disk/raid.c (grub_raid_read): Replace `device[x].disk' accesses with
12326 `device[x]'.
12327 (grub_raid_scan_device): Replace `device[x].name' accesses with
12328 `device[x]->name'. Simplify initialization of `array->device[x]'.
12329
554f0187 123302008-02-08 Robert Millan <rmh@aybabtu.com>
12331
12332 * disk/raid.c (grub_raid_open, grub_raid_scan_device): Add a few
12333 grub_dprintf() calls.
12334 * kern/disk.c (grub_disk_read): Include grub_errmsg in out of range
12335 error message.
12336
1ec8425d 123372008-02-07 Christian Franke <franke@computer.org>
12338
12339 * util/hostfs.c (grub_hostfs_open): Use fseeko and ftello
12340 instead of fseek and ftell to support large files.
12341 (grub_hostfs_read): Likewise.
12342
f2156fda 123432008-02-07 Robert Millan <rmh@aybabtu.com>
12344
12345 Patch from Jeroen Dekkers.
12346 * disk/raid.c (grub_raid_scan_device): Reset `grub_errno' on disk
fe6b695a 12347 failure, since successfully reading all array members might not be
f2156fda 12348 required.
12349
9216e0e7 123502008-02-06 Robert Millan <rmh@aybabtu.com>
12351
12352 * util/grub-probe.c (probe): Simplify partmap probing (with the
12353 assumption that the first word up to the underscore equals to
12354 the module name).
12355
b0dfd29a 123562008-02-06 Christian Franke <franke@computer.org>
12357
12358 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_NONE
12359 (and set *ofs = 0) instead of GRUB_ERR_FILE_NOT_FOUND on
12360 last block of a cpio or tar stream.
12361 Check for "TRAILER!!!" instead of any empty data
12362 block to detect last block of a cpio stream.
12363 (grub_cpio_dir): Fix constness of variable np.
12364 (grub_cpio_open): Return GRUB_ERR_FILE_NOT_FOUND if
12365 cpio or tar trailer is detected. This fixes a crash
12366 on open of a non existing file.
12367
c32865bf 123682008-02-05 Bean <bean123ch@gmail.com>
12369
12370 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Get physical
12371 address of entry.
12372 (grub_multiboot_load_elf64): Likewise.
12373 (grub_multiboot): Initialize mbi structure.
12374
12375 * util/grub-fstest.c: Don't include unused header file script.h.
12376
fe6b695a 12377 * conf/common.rmk (grub-fstest.c_DEPENDENCIES): Move to the beginning
c32865bf 12378 of file.
12379 (grub_fstest_SOURCES): Likewise.
12380
409480b7 123812008-02-05 Robert Millan <rmh@aybabtu.com>
12382
12383 * include/grub/term.h (GRUB_TERM_LEFT, GRUB_TERM_RIGHT)
12384 (GRUB_TERM_UP, GRUB_TERM_DOWN, GRUB_TERM_HOME, GRUB_TERM_END)
12385 (GRUB_TERM_DC, GRUB_TERM_PPAGE, GRUB_TERM_NPAGE, GRUB_TERM_ESC)
12386 (GRUB_TERM_TAB, GRUB_TERM_BACKSPACE): New macros.
12387
12388 * kern/i386/pc/startup.S: Include `<grub/term.h>'.
12389 (translation_table): Replace hardcoded values with macros
12390 provided by `<grub/term.h>'.
12391
12392 * term/i386/pc/at_keyboard.c: Include `<grub/term.h>'.
12393 (keyboard_map): Correct/add a few values, with macros provided
12394 by `<grub/term.h>'.
12395 (keyboard_map_shift): Zero values that don't differ from their
12396 `keyboard_map' equivalents.
12397 (grub_console_checkkey): Optimize KEYBOARD_STATUS_CAPS_LOCK toggling.
12398 Discard the second scan code that is always sent by Caps lock.
12399 Only use `keyboard_map_shift' when it provides a non-zero value,
12400 otherwise fallback to `keyboard_map'.
12401
99fadbaa 124022008-02-04 Bean <bean123ch@gmail.com>
12403
12404 * Makefile.in (enable_grub_fstest): New variable.
12405
12406 * conf/common.rmk (grub_fstest_init.lst): New rule.
12407 (grub_fstest_init.h): Likewise.
12408 (grub_fstest_init.c): Likewise.
12409 (util/grub-fstest.c_DEPENDENCIES): New variable.
12410 (grub_fstest_SOURCES): Likewise.
12411
12412 * configure.ac (enable_grub_fstest): Check for --enable-grub-fstest.
12413
12414 * util/grub-fstest.c: New file.
12415
bf567c50 124162008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
12417
12418 Make grub-setup handle a separate root device.
f19dbdb7 12419
bf567c50 12420 * util/i386/pc/grub-setup.c (setup): Always open the root device,
12421 so that the root device can be compared with the destination
12422 device.
12423 When embedding the core image, if the root and destination devices
12424 are different, set ROOT_DRIVE to ROOT_DEV->DISK->ID. Otherwise, to
12425 0xFF.
12426 When not embedding, set ROOT_DRIVE to 0xFF.
f19dbdb7 12427
9be6b98b 124282008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
12429
12430 Add support for having a grub directory in a different drive. This
12431 is still only the data handling part.
f19dbdb7 12432
9be6b98b 12433 * kern/i386/pc/startup.S (multiboot_trampoline): Set %dh to 0xFF.
12434 (codestart): Save %dh in GRUB_ROOT_DRIVE.
12435 (grub_root_drive): New variable.
12436
12437 * kern/i386/pc/init.c (make_install_device): Use GRUB_ROOT_DRIVE
12438 instead of GRUB_BOOT_DRIVE to construct a device name. Set
12439 GRUB_ROOT_DRIVE to GRUB_BOOT_DRIVE if it is 0xFF, otherwise use it
12440 as it was.
12441
12442 * include/grub/i386/pc/kernel.h (grub_root_drive): New prototype.
12443
12444 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_ROOT_DRIVE): New
12445 macro.
12446 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Set to 0x4f.
12447
12448 * boot/i386/pc/pxeboot.S (_start): Set %dh to 0xFF. For now, this
12449 is bogus, because PXE booting does not specify any drive
12450 correctly.
12451
12452 * boot/i386/pc/lnxboot.S (reg_edx): Set the second byte to 0xFF. I
12453 am not sure if this is really correct.
12454
12455 * boot/i386/pc/cdboot.S: Set %dh to 0xFF, because the root drive
12456 is always identical to the boot drive when booting from a CD.
12457
12458 * boot/i386/pc/boot.S (MOV_MEM_TO_AL): Removed. Not needed any
12459 longer.
12460 (root_drive): New variable.
12461 (real_start): Unconditionally set %dh to ROOT_DRIVE.
12462 (setup_sectors): Push %dx right after popping it, because %dh will
12463 be modified later.
12464 (copy_buffer): Restore %dx.
12465
e0ca0677 124662008-02-03 Robert Millan <rmh@aybabtu.com>
12467
12468 * util/i386/pc/grub-mkrescue.in: Rewrite most of image generation to
12469 use `cdboot.img' for cdrom images.
12470
3b3f6629 124712008-02-03 Robert Millan <rmh@aybabtu.com>
12472
12473 * util/grub.d/00_header.in: Issue scripting commands for GRUB to
12474 only setup gfxterm when `font' command has succeeded.
12475
d42b3672 124762008-02-03 Robert Millan <rmh@aybabtu.com>
12477
12478 * loader/multiboot_loader.c [GRUB_MACHINE_LINUXBIOS]
12479 (grub_rescue_cmd_multiboot_loader)
12480 (grub_rescue_cmd_module_loader): Enable multiboot1 calls.
12481
fa370ea6 124822008-02-03 Pavel Roskin <proski@gnu.org>
12483
e0c5dacb 12484 * kern/i386/pc/startup.S (grub_chainloader_real_boot): Pop
fa370ea6 12485 %edx and %esi from stack only after grub_gate_a20() is called.
12486 grub_gate_a20() clobbers %edx.
12487
f2a76e1d 124882008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
12489
12490 * configure.ac (AC_INIT): Bumped to 1.96.
12491
12492 * DISTLIST: Added boot/i386/pc/cdboot.S, bus/pci.c,
12493 commands/lspci.c,disk/memdisk.c, include/grub/pci.h,
12494 include/grub/i386/pc/pci.h, video/readers/jpeg.c, and
12495 video/readers/png.c.
12496
90fd32d1 124972008-02-03 Bean <bean123ch@gmail.com>
9be665dd 12498
12499 * conf/i386-pc.rmk (pkglib_IMAGES): Add cdboot.img.
12500 (cdboot_img_SOURCES): New variable.
12501 (cdboot_img_ASFLAGS): New variable.
12502 (cdboot_img_LDFLAGS): New variable.
12503
12504 * boot/i386/pc/cdboot.S: New file.
12505
12506 * disk/i386/pc/biosdisk.c (cd_start): New variable.
12507 (cd_count): Likewise.
12508 (grub_biosdisk_get_drive): Add support for cd device.
12509 (grub_biosdisk_call_hook): Likewise.
12510 (grub_biosdisk_iterate): Likewise.
12511 (grub_biosdisk_open): Likewise.
12512 (GRUB_BIOSDISK_CDROM_RETRY_COUNT): New macro.
12513 (grub_biosdisk_rw): Support reading from cd device.
12514 (GRUB_MOD_INIT): Iterate cd devices.
12515
12516 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_FLAG_CDROM): New macro.
12517 (GRUB_BIOSDISK_MACHINE_CDROM_START): Likewise.
12518 (GRUB_BIOSDISK_MACHINE_CDROM_END): Likewise.
12519
12520 * kern/i386/pc/init.c (make_install_device): Check for cd device.
12521
4020aa53 125222008-02-02 Robert Millan <rmh@aybabtu.com>
12523
12524 * commands/read.c: New file.
12525 * conf/common.rmk (pkglib_MODULES): Add `commands/read.c'.
12526 (read_mod_SOURCES): New variable.
12527 (read_mod_CFLAGS): Likewise.
12528 (read_mod_LDFLAGS): Likewise.
12529
e03a1132 125302008-02-02 Robert Millan <rmh@aybabtu.com>
12531
12532 * normal/main.c (grub_normal_execute): Check for `menu->size' when
12533 determining whether menu has to be displayed.
12534
58c69220 125352008-02-02 Marco Gerards <marco@gnu.org>
12536
12537 * bus/pci.c: New file.
12538
12539 * include/grub/pci.h: Likewise.
12540
12541 * include/grub/i386/pc/pci.h: Likewise.
12542
12543 * commands/lspci.c: Likewise.
12544
12545 * conf/i386-pc.rmk (pkglib_MODULES): Add `pci.mod' and
12546 `lspci.mod'.
12547 (pci_mod_SOURCES): New variable.
12548 (pci_mod_CFLAGS): Likewise.
12549 (pci_mod_LDFLAGS): Likewise.
12550 (lspci_mod_SOURCES): Likewise.
12551 (lspci_mod_CFLAGS): Likewise.
f19dbdb7 12552 (lspci_mod_LDFLAGS): Likewise.
58c69220 12553
c004e1b4 125542008-02-02 Bean <bean123ch@gmail.com>
12555
12556 * fs/ufs.c (INODE_BLKSZ): Fix incorrect value.
12557 (grub_ufs_get_file_block): Fix indirect block calculation problem.
12558
12559 * fs/xfs.c (grub_xfs_sblock): New member log2_dirblk.
12560 (grub_xfs_btree_node): New structure.
12561 (grub_xfs_btree_root): New structure.
12562 (grub_xfs_inode): New members nblocks, extsize, nextents and btree.
12563 (GRUB_XFS_EXTENT_OFFSET): Use exts instead of inode->data.extents.
12564 (GRUB_XFS_EXTENT_BLOCK): Likewise.
12565 (GRUB_XFS_EXTENT_SIZE): Likewise.
12566 (grub_xfs_read_block): Support btree format type.
12567 (grub_xfs_iterate_dir): Use NESTED_FUNC_ATTR in call_hook.
12568 Use directory block as basic unit.
12569
12570 * fs/fshelp.c (grub_fshelp_read_file): Bug fix for sparse block.
12571
12572 * aclocal.m4 (grub_i386_CHECK_REGPARM_BUG): Define NESTED_FUNC_ATTR as
12573 __attribute__ ((__regparm__ (1))).
12574
f95562bf 125752008-02-01 Robert Millan <rmh@aybabtu.com>
12576
12577 Correct a mistake in previous commit.
12578
12579 * conf/i386-pc.rmk (normal/execute.c_DEPENDENCIES): Move to the
12580 top.
12581 (normal/command.c_DEPENDENCIES): New variable.
12582
7d31f41f 125832008-02-01 Robert Millan <rmh@aybabtu.com>
12584
12585 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Move to the
12586 top.
12587 (normal/command.c_DEPENDENCIES): New variable.
12588 (grub-emu_DEPENDENCIES, normal_mod_DEPENDENCIES): Remove variables.
12589 * conf/i386-ieee1275.rmk: Likewise.
12590 * conf/i386-linuxbios.rmk: Likewise.
12591 * conf/i386-pc.rmk: Likewise.
12592 * conf/sparc64-ieee1275.rmk: Likewise.
12593 * conf/powerpc-ieee1275.rmk: Likewise.
12594 (grub_emu_SOURCES): Add `fs/fshelp.c'.
12595
12596 * genmk.rb: Add `$(#{src}_DEPENDENCIES)' in targets that require it.
12597
60b6be74 125982008-02-01 Robert Millan <rmh@aybabtu.com>
12599
12600 * kern/disk.c (grub_disk_read, grub_disk_write): Add grub_dprintf()
12601 call at beginning of function.
12602
078522ab 126032008-01-31 Pavel Roskin <proski@gnu.org>
12604
12605 * util/powerpc/ieee1275/grub-mkrescue.in: New file.
d2c11005 12606 * conf/powerpc-ieee1275.rmk (bin_SCRIPTS): New variable.
12607 (grub_mkrescue_SOURCES): Likewise.
078522ab 12608 * DISTLIST: Add util/powerpc/ieee1275/grub-mkrescue.in.
12609
ccaa8a5f 126102008-01-30 Robert Millan <rmh@aybabtu.com>
12611
12612 * conf/i386-pc.rmk (sbin_UTILITIES): Remove `grub-probe'.
12613 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Moved from here ...
12614 * conf/common.rmk (util/grub-probe.c_DEPENDENCIES)
12615 (grub_probe_SOURCES): ... to here.
12616
12617 * conf/i386-efi.rmk (sbin_UTILITIES): Remove `grub-probe'.
12618 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Remove.
12619 * conf/i386-ieee1275.rmk: Likewise.
12620 * conf/i386-linuxbios.rmk: Likewise.
12621 * conf/powerpc-ieee1275.rmk: Likewise.
12622
ae5a9cd7 126232008-01-30 Tristan Gingold <gingold@free.fr>
12624
12625 * kern/rescue.c: Silently accept empty lines.
12626
70bc2ef2 126272008-01-29 Bean <bean123ch@gmail.com>
12628
12629 * boot/i386/pc/lnxboot.S (data_start): Code cleanup.
12630 (real_code_2): Code cleanup and change comment style.
12631 (move_memory): Avoid using 32-bit address mode.
12632
6a4d50ea 126332008-01-29 Bean <bean123ch@gmail.com>
12634
12635 * conf/i386-pc.rmk (pkglib_MODULES): Add `png.mod'.
12636 (png_mod_SOURCES): New variable.
12637 (png_mod_CFLAGS): Likewise.
12638 (png_mod_LDFLAGS): Likewise.
12639
12640 * video/readers/png.c: New file.
12641
11cc30ac 126422008-01-28 Robert Millan <rmh@aybabtu.com>
12643
12644 * include/grub/i386/linuxbios/kernel.h (GRUB_MOD_GAP): New macro.
12645 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Remove
12646 `ifndef GRUB_MOD_GAP' hack.
12647 * util/elf/grub-mkimage.c (add_segments): Likewise.
12648
3abc589f 126492008-01-27 Robert Millan <rmh@aybabtu.com>
12650
12651 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Skip
12652 `GRUB_MOD_GAP' for platforms in which it's not defined.
962ca133 12653 * util/elf/grub-mkimage.c (add_segments): Likewise.
3abc589f 12654
e1907778 126552008-01-27 Robert Millan <rmh@aybabtu.com>
12656
12657 Get grub-emu to build again (including parallel builds).
12658
12659 * conf/i386-pc.rmk (util/grub-emu.c_DEPENDENCIES): Remove variable.
12660 Split into ...
12661 (util/grub-emu.c_DEPENDENCIES): ... this, ...
12662 (normal/execute.c_DEPENDENCIES): ... this, ...
12663 (grub-emu_DEPENDENCIES): ... and this.
12664
12665 * conf/i386-efi.rmk: Likewise.
12666 * conf/i386-linuxbios.rmk: Likewise.
12667 * conf/i386-ieee1275.rmk: Likewise.
12668 * conf/powerpc-ieee1275.rmk: Likewise.
12669 (grub_emu_SOURCES): Remove duplicated `kern/file.c'.
12670
2216b101 126712008-01-27 Robert Millan <rmh@aybabtu.com>
12672
12673 * NEWS: Add a few items.
12674
f75172d9 126752008-01-27 Robert Millan <rmh@aybabtu.com>
12676
12677 Fix parallel builds with grub-emu. Based on earlier commit for
12678 grub-probe and grub-setup.
12679
12680 * conf/i386-pc.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12681 (util/grub-emu.c_DEPENDENCIES): ... this.
12682 * conf/i386-efi.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12683 (util/grub-emu.c_DEPENDENCIES): ... this.
12684 * conf/i386-linuxbios.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12685 (util/grub-emu.c_DEPENDENCIES): ... this.
12686 * conf/i386-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12687 (util/grub-emu.c_DEPENDENCIES): ... this.
12688 * conf/powerpc-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12689 (util/grub-emu.c_DEPENDENCIES): ... this.
12690
3f51de77 126912008-01-27 Pavel Roskin <proski@gnu.org>
12692
12693 * include/grub/powerpc/ieee1275/kernel.h: Introduce GRUB_MOD_GAP
12694 to create a gap between _end and the modules added to the image
12695 with grub-mkrescue. That fixes "CLAIM failed" on PowerMAC.
12696 * kern/powerpc/ieee1275/init.c: Use GRUB_MOD_GAP.
12697 * util/elf/grub-mkimage.c (add_segments): Likewise.
12698
2033f53e 126992008-01-26 Pavel Roskin <proski@gnu.org>
12700
12701 * kern/dl.c (grub_dl_load): Don't abort if prefix is not set,
12702 just return an error.
12703
22da1f6f 127042008-01-26 Bean <bean123ch@gmail.com>
12705
12706 * fs/reiserfs.c (grub_fshelp_node): New member next_offset.
12707 (grub_reiserfs_get_item): Save offset of the next item.
12708 (grub_reiserfs_iterate_dir): Use next_offset to find next item.
12709
2a9525e6 127102008-01-25 Robert Millan <rmh@aybabtu.com>
12711
12712 * conf/i386-pc.rmk (grub_setup_SOURCES, grub_emu_SOURCES): Regroup to
12713 make all filesystem sources appear together (possibly fixing omissions
12714 while at it).
12715 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
12716 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
12717 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
12718 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
12719
12720 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise. Additionally,
12721 add `kern/file.c'.
12722 * conf/i386-efi.rmk (grub_probe_SOURCES): Likewise.
12723 * conf/i386-ieee1275.rmk (grub_probe_SOURCES): Likewise.
12724 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Likewise.
12725 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Likewise.
12726
12727 * util/grub-probe.c: Include `<grub/file.h>' and `<sys/stat.h>'.
12728 (probe): Add a sanity check to make sure of our ability to read
12729 requested files when probing for filesystem type.
12730
12731 * genmk.rb: Update copyright year (2007).
12732
12733 * include/grub/fs.h (grub_fat_init, grub_fat_fini, grub_ext2_init)
12734 (grub_ext2_fini, grub_ufs_init, grub_ufs_fini, grub_minix_init)
12735 (grub_minix_fini, grub_hfs_init, grub_hfs_fini, grub_jfs_init)
12736 (grub_jfs_fini, grub_xfs_init, grub_xfs_fini, grub_affs_init)
12737 (grub_affs_fini, grub_sfs_init, grub_sfs_fini, grub_iso9660_init)
12738 : Remove function prototypes.
12739
b95f71b5 127402008-01-25 Robert Millan <rmh@aybabtu.com>
12741
12742 Revert my previous commits (based on wrong assumption of how grub_errno
12743 works).
12744
fe6b695a 12745 * kern/disk.c (grub_disk_open): Stop resetting grub_errno.
b95f71b5 12746 * kern/file.c (grub_file_open): Likewise.
12747
d08bbb49 127482008-01-24 Pavel Roskin <proski@gnu.org>
12749
12750 * include/grub/ieee1275/ieee1275.h: Introduce flag for firmwares
12751 that hang if GRUB tries to setup colors.
12752 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Don't set
12753 colors for firmwares that don't support it.
12754 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag):
12755 Recognize Open Hack'Ware, set flags to work around its
12756 limitations.
12757
605e36ed 127582008-01-24 Robert Millan <rmh@aybabtu.com>
12759
12760 * kern/file.c (grub_file_open): Do not account previous failures of
12761 unrelated functions when grub_errno is checked for.
12762 Reported by Oleg Strikov.
12763
bac332a1 127642008-01-24 Bean <bean123ch@gmail.com>
12765
12766 * fs/ufs.c (GRUB_UFS_VOLNAME_LEN): New macro.
12767 (grub_ufs_sblock): New member volume name.
12768 (grub_ufs_find_file): Fix string copy bug.
12769 (grub_ufs_label): Implement this function properly.
12770
12771 * fs/hfs.c (grub_hfs_cnid_type): New enum.
12772 (grub_hfs_iterate_records): Use the correct file number for extents
12773 and catalog file. Fix problem in next index calculation.
12774 (grub_hfs_find_node): Replace recursive function call with loop.
12775 (grub_hfs_iterate_dir): Replace recursive function call with loop.
12776
15c80c09 127772008-01-23 Robert Millan <rmh@aybabtu.com>
12778
12779 * include/grub/i386/ieee1275/loader.h: Include `<grub/types.h>',
12780 `<grub/symbol.h>' and `<grub/multiboot.h>'.
12781 (grub_multiboot2_real_boot): New function prototype.
12782
12783 * include/grub/i386/pc/memory.h: Include `<grub/machine/machine.h>'.
12784 [!GRUB_MACHINE_IEEE1275] (grub_lower_mem, grub_upper_mem): Disable.
12785
12786 * kern/i386/ieee1275/init.c (grub_os_area_addr)
12787 (grub_os_area_size, grub_lower_mem, grub_upper_mem): Remove variables.
12788
305338fd 127892008-01-23 Robert Millan <rmh@aybabtu.com>
12790
12791 * kern/mm.c (grub_mm_init_region): Replace grub_dprintf() call with
12792 #ifdef'ed out grub_printf().
12793
3ea52685 127942008-01-23 Robert Millan <rmh@aybabtu.com>
12795
12796 * term/i386/pc/at_keyboard.c (grub_keyboard_isr): #ifdef out
12797 grub_dprintf calls, since they make "debug=all" mode unusable.
12798 (grub_console_checkkey): Likewise.
12799
5882ae4b 128002008-01-23 Robert Millan <rmh@aybabtu.com>
12801
12802 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
12803 `term/i386/pc/at_keyboard.c'.
12804 (pkglib_MODULES): Add `serial.mod'.
12805 (serial_mod_SOURCES): New variable.
12806 (serial_mod_CFLAGS): Likewise.
12807 (serial_mod_LDFLAGS): Likewise.
12808
12809 * include/grub/i386/ieee1275/console.h: Add `<grub/symbol.h>'. Remove
12810 `<grub/powerpc/ieee1275/console.h>'.
12811 (grub_keyboard_controller_init): New function prototype.
12812 (grub_console_checkkey): Likewise.
12813 (grub_console_getkey): Likewise.
12814
12815 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize AT
12816 keyboard on i386.
12817
12818 * term/ieee1275/ofconsole.c (grub_ofconsole_term): On i386, use
12819 grub_ofconsole_checkkey() and grub_ofconsole_getkey() for input.
12820
06ab5303 128212008-01-23 Robert Millan <rmh@aybabtu.com>
12822
12823 * kern/i386/pc/init.c (make_install_device): When memdisk image is
12824 present, "(memdisk)/boot/grub" becomes the default prefix.
12825
12826 * util/i386/pc/grub-mkrescue.in: Switch to a minimal core.img plus
12827 a memdisk tarball with all the modules. Add --overlay=DIR option that
12828 allows users to overlay additional files into the image.
12829
dbb475a4 128302008-01-23 Robert Millan <rmh@aybabtu.com>
12831
12832 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add `machine/loader.h'
12833 and `machine/memory.h'.
12834 (pkglib_MODULES): Add `multiboot.mod' and `_multiboot.mod'.
12835 (_multiboot_mod_SOURCES): New variable.
12836 (_multiboot_mod_CFLAGS): Likewise.
12837 (_multiboot_mod_LDFLAGS): Likewise.
12838 (multiboot_mod_SOURCES): Likewise.
12839 (multiboot_mod_CFLAGS): Likewise.
12840 (multiboot_mod_LDFLAGS): Likewise.
12841
12842 * include/grub/i386/ieee1275/loader.h: New file.
12843
12844 * include/grub/i386/ieee1275/machine.h: Likewise.
12845
12846 * include/grub/i386/ieee1275/memory.h: Likewise.
12847
12848 * include/grub/i386/pc/init.h (grub_os_area_addr): Remove (redundant)
12849 variable declaration.
12850 (grub_os_area_size): Likewise.
12851
12852 * kern/i386/ieee1275/init.c (grub_os_area_addr, grub_os_area_size)
12853 (grub_lower_mem, grub_upper_mem): New variables.
12854 (grub_stop_floppy): New function (just to make
12855 grub_multiboot2_real_boot() happy).
12856
12857 * kern/i386/ieee1275/startup.S: Include `<grub/machine/memory.h>',
12858 `<grub/cpu/linux.h>', `<multiboot.h>' and `<multiboot2.h>'.
12859 (grub_stop): New function.
12860 Include `"../realmode.S"' and `"../loader.S"'.
12861
12862 * loader/multiboot_loader.c: Include `<grub/machine/machine.h>'.
12863 Replace `__i386__' #ifdefs with `GRUB_MACHINE_PCBIOS'.
12864
12865 * loader/powerpc/ieee1275/multiboot2.c (grub_mb2_arch_boot): On i386,
12866 rely on grub_multiboot2_real_boot() for final boot.
12867
25638629 128682008-01-22 Robert Millan <rmh@aybabtu.com>
12869
12870 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): When
12871 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag is set, skip any
12872 device that doesn't look like an SD card.
12873 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
12874 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag.
12875 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag): Detect
12876 OLPC laptop, and set `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' when
12877 found.
12878
9dad816d 128792008-01-22 Robert Millan <rmh@aybabtu.com>
12880
12881 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Add sanity check to
12882 avoid claiming over our own code.
12883
34842f2d 128842008-01-22 Bean <bean123ch@gmail.com>
12885
12886 * conf/i386-pc.rmk (pkglib_MODULES): Add `jpeg.mod'.
12887 (jpeg_mod_SOURCES): New variable.
12888 (jpeg_mod_CFLAGS): Likewise.
12889 (jpeg_mod_LDFLAGS): Likewise.
12890
12891 * video/readers/jpeg.c : New file.
12892
44023a28 128932008-01-22 Bean <bean123ch@gmail.com>
12894
12895 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_FILE_NOT_FOUND when
12896 there are no more items.
12897
bc2d8ac6 128982008-01-21 Robert Millan <rmh@aybabtu.com>
12899
12900 * kern/mm.c (grub_mm_init_region): Improve debug message.
12901
261bd4bc 129022008-01-21 Robert Millan <rmh@aybabtu.com>
12903
12904 * conf/i386-pc.rmk (GRUB_MEMORY_MACHINE_LINK_ADDR): New variable.
12905 (kernel_img_LDFLAGS): Use `GRUB_MEMORY_MACHINE_LINK_ADDR' as link
12906 address.
12907 (grub_mkimage_CFLAGS): Propagate `GRUB_MEMORY_MACHINE_LINK_ADDR' as
12908 a C macro.
12909 * include/grub/i386/pc/memory.h (GRUB_MEMORY_MACHINE_UPPER): New macro.
12910 Indicates start of upper memory.
12911 * util/i386/pc/grub-mkimage.c: Include `<grub/machine/memory.h>'.
12912 (generate_image): Abort when image size is big enough to corrupt
12913 upper memory.
12914
12915 * include/grub/i386/pc/vga.h: Include `<grub/machine/memory.h>'.
12916 (GRUB_MEMORY_MACHINE_VGA_ADDR): Alias for `GRUB_MEMORY_MACHINE_UPPER'.
12917 * term/i386/pc/vga.c (VGA_MEM): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
12918 instead of hardcoding 0xA0000.
12919 * video/i386/pc/vbe.c: Include `<grub/machine/vga.h>'.
12920 (grub_vbe_set_video_mode): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
12921 instead of hardcoding 0xA0000.
12922
f970b55e 129232008-01-21 Robert Millan <rmh@aybabtu.com>
12924
12925 * disk/memdisk.c (memdisk_size): New variable.
12926 (grub_memdisk_open): Replace grub_arch_memdisk_size() call with
12927 `memdisk_size'.
12928 (grub_memdisk_init): Initialize `memdisk_size'. Reallocate memdisk
12929 image to dynamic memory.
12930 (grub_memdisk_fini): Replace grub_arch_memdisk_size() call with
12931 `memdisk_size'. Free memdisk block.
12932
1a8b0526 129332008-01-21 Robert Millan <rmh@aybabtu.com>
12934
12935 Fix detection of very small filesystems (like tar).
12936
12937 * fs/reiserfs.c (grub_reiserfs_mount): When disk is too small to
12938 contain a ReiserFS, abort with GRUB_ERR_BAD_FS rather than
12939 GRUB_ERR_OUT_OF_RANGE (which made the upper layer think there's
12940 a problem with this disk).
12941
6e9b4aab 129422008-01-21 Robert Millan <rmh@aybabtu.com>
12943
12944 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Add debug message
12945 on grub_biosdisk_rw_standard() error.
12946
0d8837b2 129472008-01-21 Robert Millan <rmh@aybabtu.com>
12948
12949 * include/grub/ieee1275/ieee1275.h: Add 2008 to Copyright line for
12950 recent changes.
12951 * kern/elf.c: Likewise.
12952 * kern/ieee1275/ieee1275.c: Likewise.
12953 * kern/powerpc/ieee1275/openfw.c: Likewise.
12954 * term/ieee1275/ofconsole.c: Likewise.
12955
ffd36e34 129562008-01-21 Robert Millan <rmh@aybabtu.com>
12957
12958 * include/grub/i386/pc/kernel.h: Include `<grub/symbol.h>'.
12959
3f0093d0 12960 * include/grub/kernel.h (grub_arch_memdisk_addr)
12961 (grub_arch_memdisk_size): Moved from here ...
ffd36e34 12962
3f0093d0 12963 * include/grub/i386/pc/kernel.h (grub_arch_memdisk_addr)
12964 (grub_arch_memdisk_size): ... to here.
ffd36e34 12965
6c391b21 129662008-01-21 Robert Millan <rmh@aybabtu.com>
12967
12968 Mostly based on bugfix from Bean.
12969
12970 * kern/elf.c (grub_elf32_phdr_iterate): Use `NESTED_FUNC_ATTR'
12971 attribute with hook() parameter.
12972 (grub_elf32_load): Use `NESTED_FUNC_ATTR' with grub_elf32_load_segment()
12973 declaration.
12974 (grub_elf64_phdr_iterate): Use `NESTED_FUNC_ATTR'
12975 attribute with hook() parameter.
12976 (grub_elf64_load): Use `NESTED_FUNC_ATTR' with grub_elf64_load_segment()
12977 declaration.
12978
55a581dc 129792008-01-21 Robert Millan <rmh@aybabtu.com>
12980
12981 * conf/i386-pc.rmk (kernel_img_HEADERS): Add `machine/kernel.h'.
12982 (pkglib_MODULES): Add `memdisk.mod'.
12983 (memdisk_mod_SOURCES): New variable.
12984 (memdisk_mod_CFLAGS): Likewise.
12985 (memdisk_mod_LDFLAGS): Likewise.
12986
12987 * disk/memdisk.c: New file.
12988
12989 * include/grub/disk.h (grub_disk_dev_id): Add
12990 `GRUB_DISK_DEVICE_MEMDISK_ID'.
12991
12992 * include/grub/i386/pc/kernel.h
12993 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): New macro.
12994 (GRUB_KERNEL_MACHINE_PREFIX): Increment by 4.
12995 (grub_kernel_image_size): New variable declaration.
12996 (grub_total_module_size): Likewise.
12997 (grub_memdisk_image_size): Likewise.
12998
12999 * include/grub/i386/pc/memory.h
13000 (GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR): New macro.
13001
13002 * include/grub/kernel.h: Include `<grub/symbol.h>'.
13003 (grub_arch_memdisk_addr): New variable declaration.
13004 (grub_arch_memdisk_size): Likewise.
13005
13006 * kern/i386/pc/init.c (grub_arch_memdisk_addr): New function.
13007 (grub_arch_memdisk_size): Likewise.
13008
13009 * kern/i386/pc/startup.S (grub_memdisk_image_size): New variable.
13010 (codestart): Replace hardcoded `0x100000' with
13011 `GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR' macro.
13012
13013 * util/i386/pc/grub-mkimage.c: Include `<grub/misc.h>'.
13014 (generate_image): Add `memdisk_path' parameter. When `memdisk_path' is
13015 not NULL, append the contents of the file it refers to, at the end of
13016 the compressed kernel image. Initialize `grub_memdisk_image_size'
13017 variable (at `GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE' offset).
13018 (options): Add "memdisk"|'m' option.
13019 (main): Parse --memdisk|-m option, and pass user-provided path as
13020 parameter to generate_image().
13021
3d7f54c9 130222008-01-20 Robert Millan <rmh@aybabtu.com>
13023
13024 * kern/sparc64/ieee1275/openfw.c (grub_devalias_iterate): Copy debug
13025 grub_dprintf() calls from here ...
13026 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): ... to here.
13027
0bf74728 130282008-01-20 Robert Millan <rmh@aybabtu.com>
13029
13030 Fix detection of "real mode" when /options/real-mode? doesn't exist.
13031
13032 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_mmu): New variable
13033 declaration.
13034 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_mmu): New variable.
13035 (grub_ieee1275_find_options): If `grub_ieee1275_mmu' is 0, set
13036 `GRUB_IEEE1275_FLAG_REAL_MODE'.
fe6b695a 13037 (cmain): Initialize `grub_ieee1275_mmu' (using /chosen/mmu integer
0bf74728 13038 property).
13039 * kern/powerpc/ieee1275/openfw.c (grub_map): Rely on pre-initialized
13040 `grub_ieee1275_mmu' rather than obtaining a handler on every call.
13041
33bf70a7 130422008-01-19 Robert Millan <rmh@aybabtu.com>
13043
fe6b695a 13044 Get rid of confusing function (superseded by
33bf70a7 13045 `grub_ieee1275_get_integer_property')
13046 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_decode_int_4): Remove
13047 prototype.
13048 * kern/ieee1275/ieee1275.c (grub_ieee1275_decode_int_4): Remove
13049 function.
13050 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid use of
13051 grub_ieee1275_decode_int_4(), by obtaining integer properties directly
fe987087 13052 in native endianness from grub_ieee1275_get_integer_property().
33bf70a7 13053
e2da7d26 130542008-01-19 Robert Millan <rmh@aybabtu.com>
13055
13056 * kern/powerpc/ieee1275/openfw.c (grub_halt): Issue "power-off"
13057 command after "shut-down", since implementations differ on which
13058 the command for halt is.
13059
59f1fd8d 130602008-01-19 Robert Millan <rmh@aybabtu.com>
13061
13062 * include/grub/i386/linuxbios/console.h: Add header protection.
13063 (grub_keyboard_controller_init): New function prototype.
13064 * term/i386/pc/at_keyboard.c (KEYBOARD_COMMAND_ISREADY): New macro.
13065 (KEYBOARD_COMMAND_READ): Likewise.
13066 (KEYBOARD_COMMAND_WRITE): Likewise.
13067 (KEYBOARD_SCANCODE_SET1): Likewise.
13068 (grub_keyboard_controller_write): New function.
13069 (grub_keyboard_controller_read): Likewise.
13070 (grub_keyboard_controller_init): Likewise.
13071
13072 * term/i386/pc/console.c: Include `<grub/machine/machine.h>'.
13073 (grub_console_init): On coreboot/LinuxBIOS, call
13074 grub_keyboard_controller_init().
13075
5f5a7c15 130762008-01-19 Robert Millan <rmh@aybabtu.com>
13077
13078 PowerPC changes provided by Pavel Roskin.
13079
13080 * kern/powerpc/ieee1275/cmain.c (cmain): Don't take any arguments.
13081 * kern/powerpc/ieee1275/crt0.S: Store r5 in grub_ieee1275_entry_fn,
13082 don't rely on cmain() doing it.
13083 * kern/i386/ieee1275/startup.S (_start): Store %eax in
13084 grub_ieee1275_entry_fn, don't rely on cmain() doing it.
13085
1210e168 130862008-01-16 Robert Millan <rmh@aybabtu.com>
13087
13088 * include/grub/i386/linuxbios/memory.h
13089 (GRUB_MEMORY_MACHINE_LINUXBIOS_TABLE_ADDR): Remove macro.
13090 * kern/i386/linuxbios/table.c (grub_linuxbios_table_iterate): Do not
13091 receive `table_header' as argument. Instead, probe for it in the
13092 known memory ranges where it can be present.
13093 (grub_available_iterate): Do not pass a fixed `table_header' address
13094 to grub_linuxbios_table_iterate().
13095
3d04eab8 130962008-01-15 Robert Millan <rmh@aybabtu.com>
13097
13098 * configure.ac: Add `i386-ieee1275' to the list of supported targets.
13099 * conf/i386-ieee1275.rmk: New file.
13100 * include/grub/i386/ieee1275/console.h: Likewise.
13101 * include/grub/i386/ieee1275/ieee1275.h: Likewise.
13102 * include/grub/i386/ieee1275/kernel.h: Likewise.
13103 * include/grub/i386/ieee1275/time.h: Likewise.
13104 * kern/i386/ieee1275/init.c: Likewise.
13105 * kern/i386/ieee1275/startup.S: Likewise.
13106
d1bc1b73 131072008-01-15 Robert Millan <rmh@aybabtu.com>
13108
13109 * kern/misc.c (grub_vsprintf): Do not reset `longlongfmt' to zero
13110 when pointers are 32-bit (but still do set it to one when they are
13111 64-bit).
13112
66a65807 131132008-01-15 Robert Millan <rmh@aybabtu.com>
13114
13115 * include/grub/ieee1275/ieee1275.h
13116 (grub_ieee1275_get_integer_property): New function prototype.
13117
13118 * kern/ieee1275/ieee1275.c: Include `<grub/types.h>'.
13119 (grub_ieee1275_get_integer_property): New function. Wraps around
fe987087 13120 grub_ieee1275_get_property() to handle endianness.
66a65807 13121
13122 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Replace
13123 grub_ieee1275_get_property() with grub_ieee1275_get_integer_property()
fe6b695a 13124 where appropriate.
66a65807 13125 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Likewise.
13126 (grub_map): Likewise.
13127 * kern/sparc64/ieee1275/openfw.c (grub_map): Likewise.
13128
a83ccafd 131292008-01-15 Bean <bean123ch@gmail.com>
13130
13131 * normal/execute.c (grub_script_exec_argument_to_string): Check for undefined variable.
13132 (grub_script_execute_cmdline): Reset grub_errno.
13133
13134 * normal/main.c (read_config_file): Reset grub_errno.
13135
13136 * normal/parse.y (script_init): New.
13137 (script): Move function and menuentry here.
13138 (delimiter): New.
13139 (command): Add delimiter at the end of command.
13140 (commands): Adjust to match the new command.
13141 (commandblock): Remove grub_script_lexer_record_start.
f19dbdb7 13142 (menuentry): Add grub_script_lexer_record_start, use the new commands.
a83ccafd 13143 (if): Use the new commands.
13144
13145 * conf/common.rmk (pkgdata_MODULES): Add echo.mod.
13146
df6ecfc6 131472008-01-15 Robert Millan <rmh@aybabtu.com>
13148
13149 * normal/menu.c (run_menu): Move timeout message from here ...
13150 (print_timeout): ... to here.
13151 (run_menu): Use print_timeout() once during initial draw to print
13152 the whole message, and again in every clock tick to update only
13153 the number of seconds.
13154
87ae25eb 131552008-01-15 Robert Millan <rmh@aybabtu.com>
13156
13157 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Obtain
13158 actual size of `available' from grub_ieee1275_get_property(), and
13159 restrict parsing to that bound.
13160
47bf09a4 131612008-01-15 Christian Franke <franke@computer.org>
13162
13163 * util/grub-emu.c: Replace <argp.h> by <getopt.h>.
13164 (argp_program_version): Remove variable.
13165 (argp_program_bug_address): Likewise.
13166 (options): Convert from struct argp_option to struct option.
13167 (struct arguments): Remove.
13168 (parse_opt): Remove.
13169 (usage): New function.
13170 (main): Replace struct args members by simple variables.
13171 Replace argp_parse() by getopt_long().
13172 Add switch to evaluate options.
13173 Add missing "(...)" around root_dev in prefix string.
13174
c86f1469 131752008-01-14 Robert Millan <rmh@aybabtu.com>
13176
13177 * kern/powerpc/ieee1275/init.c (grub_exit): Reimplement as a wrapper
13178 for grub_ieee1275_exit(), in order to improve portability.
13179
e622c559 131802008-01-14 Robert Millan <rmh@aybabtu.com>
13181
13182 * util/grub.d/10_linux.in (prefix): Define.
13183 (exec_prefix): Likewise. Both definitions are later used by `libdir'.
13184
44cb1ec8 131852008-01-13 Pavel Roskin <proski@gnu.org>
13186
13187 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Don't use
13188 grub_errno if no errors have been detected.
13189
1eb8c802 131902008-01-12 Robert Millan <rmh@aybabtu.com>
13191
13192 * include/grub/util/getroot.h (grub_dev_abstraction_types): New enum.
13193 (grub_util_get_dev_abstraction): New function prototype.
13194
13195 * util/getroot.c: Include `<grub/util/getroot.h>'
13196 (grub_util_get_grub_dev): Move detection of abstraction type to ...
13197 (grub_util_get_dev_abstraction): ... here (new function).
13198
13199 * util/grub-probe.c: Convert PRINT_* to an enum. Add
13200 `PRINT_ABSTRACTION'.
13201 (probe): Probe for abstraction type when requested.
13202 (main): Understand `--target=abstraction'.
13203
13204 * util/i386/efi/grub-install.in: Add abstraction module to core
13205 image when it is found to be necessary.
13206 * util/i386/pc/grub-install.in: Likewise.
13207 * util/powerpc/ieee1275/grub-install.in: Likewise.
13208
13209 * util/update-grub_lib.in (font_path): Return system path without
13210 converting to GRUB path.
13211 * util/update-grub.in: Convert system path returned by font_path()
13212 to a GRUB path. Use `grub-probe -t abstraction' to determine what
13213 abstraction module is needed for loading fonts (if any). Export
13214 that as `GRUB_PRELOAD_MODULES'.
13215 * util/grub.d/00_header.in: Process `GRUB_PRELOAD_MODULES' (print
13216 insmod commands).
13217
52bd3de9 132182008-01-12 Yoshinori K. Okuji <okuji@enbug.org>
13219
13220 Remove some unused code from reiserfs.
f19dbdb7 13221
52bd3de9 13222 * fs/reiserfs.c (struct grub_reiserfs_key)
13223 [GRUB_REISERFS_KEYV2_BITFIELD]: Removed offset and type.
13224 (struct grub_reiserfs_node_body): Removed.
13225 (grub_reiserfs_get_key_v2_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
13226 Likewise.
13227 (grub_reiserfs_get_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
13228 Likewise.
13229 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
13230 Likewise.
13231 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
13232 Likewise.
13233 (grub_reiserfs_set_key_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
13234 Likewise.
13235 (grub_reiserfs_iterate_dir) [GRUB_REISERFS_KEYV2_BITFIELD]:
13236 Likewise.
13237 (grub_reiserfs_open) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
13238 (grub_reiserfs_read) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
13239 (grub_reiserfs_dir) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
13240
2f80039d 132412008-01-10 Robert Millan <rmh@aybabtu.com>
13242
13243 * util/update-grub_lib.in (grub_file_is_not_garbage): New function.
13244 Determines if a file is garbage left by packaging systems, etc.
13245 * util/update-grub.in: Use grub_file_is_not_garbage() as a condition
13246 for processing /etc/grub.d scripts.
13247 * util/grub.d/10_hurd.in: Fix `GRUB_DISTRIBUTOR' comparison.
13248 * util/grub.d/10_linux.in: Likewise. Use grub_file_is_not_garbage()
13249 as a condition for processing Linux images.
13250
87888032 132512008-01-10 Pavel Roskin <proski@gnu.org>
13252
13253 * include/grub/powerpc/libgcc.h (__ucmpdi2): New export. Needed
13254 to compile reiserfs.c on PowerPC.
13255
7e54fced 132562008-01-10 Robert Millan <rmh@aybabtu.com>
de9993e0 13257
13258 * kern/device.c (grub_device_iterate): Do not abort device iteration
13259 when one of the devices cannot be opened.
13260 * kern/disk.c (grub_disk_open): Do not account previous failures of
13261 unrelated functions when grub_errno is checked for.
13262
5aa541e6 132632008-01-08 Robert Millan <rmh@aybabtu.com>
13264
13265 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): For
13266 `! grub_linux_is_bzimage', change order of address comparison to make
13267 it more intuitive, and improve "too big zImage" error message.
13268
7076340d 132692008-01-08 Robert Millan <rmh@aybabtu.com>
13270
13271 * Makefile.in (uninstall): Handle `$(update-grub_SCRIPTS)' and
13272 `$(update-grub_DATA)'.
13273 (distcheck): Fix race condition when invoking `$(MAKE)' on multiple
13274 targets.
13275
9ca70333 132762008-01-07 Robert Millan <rmh@aybabtu.com>
13277
13278 * boot/i386/pc/boot.S (boot_drive_check): Add a comment indicating
13279 which instruction is modified by grub-setup during installation
13280 (since it wasn't obvious by only looking at this file).
13281
38ccf575 132822008-01-07 Robert Millan <rmh@aybabtu.com>
13283
13284 * TODO: Rewrite. Just refer to the wiki and the BTS instead of
13285 listing actual TODO items.
13286
f5db4291 132872008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
13288
868967cf 13289 * fs/reiserfs.c (grub_reiserfs_get_key_v2_type): Handle endianness
13290 correctly.
13291 (grub_reiserfs_get_key_offset): Likewise.
13292 (grub_reiserfs_set_key_offset): Likewise.
13293 (grub_reiserfs_set_key_type): Likewise.
fe6b695a 13294 (grub_reiserfs_iterate_dir): Return 1 if found, otherwise 0.
868967cf 13295
13296 (GRUB_REISERFS_KEYV2_BITFIELD): Undefined. Probably it would be
13297 better to remove the bitfield version completely.
f19dbdb7 13298
868967cf 132992008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
f19dbdb7 13300
f5db4291 13301 * fs/reiserfs.c (grub_reiserfs_iterate_dir): ENTRY_ITEM must be
13302 allocated from the heap, due to the fshelp implementation.
13303 (grub_reiserfs_dir): Free NODE, due to the same reason.
13304
492e6d9d 133052008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
13306
13307 Mostly from Vincent Pelletier:
f19dbdb7 13308
492e6d9d 13309 * fs/reiserfs.c: New file.
f19dbdb7 13310
492e6d9d 13311 * conf/common.rmk (pkglib_MODULES): Added reiserfs.mod.
13312 (reiserfs_mod_SOURCES): New variable.
13313 (reiserfs_mod_CFLAGS): Likewise.
13314 (reiserfs_mod_LDFLAGS): Likewise.
13315
13316 * DISTLIST: Added boot/i386/pc/lnxboot.S, commands/hexdump.c,
13317 disk/ata.c, fs/cpio.c, fs/ntfscomp.c, fs/reiserfs.c,
13318 include/grub/ntfs.h, include/grub/i386/pc/machine.h, and
13319 normal/color.c.
13320
9ce3e7c1 133212008-01-06 Robert Millan <rmh@aybabtu.com>
13322
13323 * normal/color.c: Remove `<grub/env.h>'.
13324
f3b58148 133252008-01-05 Jeroen Dekkers <jeroen@dekkers.cx>
13326
13327 * include/grub/normal.h: Include <grub/env.h>.
13328
7ac3bcfa 133292008-01-05 Robert Millan <rmh@aybabtu.com>
13330
13331 * util/i386/pc/grub-setup.c (usage): Replace obsolete `(hd0,0)' in
13332 usage example with `(hd0,1)'.
fb358190 13333 Reported by Samuel Thibault.
7ac3bcfa 13334
c8ee99d7 133352008-01-05 Robert Millan <rmh@aybabtu.com>
13336
13337 * kern/i386/loader.S (grub_linux_is_bzimage): New variable.
13338 (grub_linux_boot_zimage): Rename to ...
13339 (grub_linux_boot): ... this.
13340 (grub_linux_boot_bzimage): Merge with `grub_linux_boot_zimage'.
13341 (grub_linux_boot_zimage): Conditionalize zImage copy.
13342
13343 * include/grub/i386/loader.h (grub_linux_is_bzimage): Add prototype.
13344 (grub_linux_boot_bzimage): Remove prototype.
13345 (grub_linux_boot_zimage): Rename to ...
13346 (grub_linux_boot): ... this.
13347
13348 * loader/i386/pc/linux.c (big_linux): Replace with `grub_linux_is_bzimage'.
13349 (grub_linux_boot): Remove function.
13350
0ece25b1 133512008-01-05 Robert Millan <rmh@aybabtu.com>
13352
13353 * include/grub/normal.h (grub_env_write_color_normal): New prototype.
13354 (grub_env_write_color_highlight): Likewise.
13355 (grub_wait_after_message): Likewise.
13356
13357 * normal/color.c: New file.
13358
13359 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/color.c'.
13360 (normal_mod_DEPENDENCIES): Likewise.
13361
13362 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `normal/color.c'.
13363 (normal_mod_DEPENDENCIES): Likewise.
13364
13365 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add `normal/color.c'.
13366 (normal_mod_DEPENDENCIES): Likewise.
13367
13368 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `normal/color.c'.
13369 (normal_mod_DEPENDENCIES): Likewise.
13370
13371 * normal/menu_entry.c (run): Rely on grub_wait_after_message()
13372 for waiting after a message is printed.
13373 * normal/main.c (read_config_file): Likewise.
13374 (grub_normal_init): Register grub_env_write_color_normal() and
13375 grub_env_write_color_highlight() hooks. Mark `color_normal' and
13376 `color_highlight' variables as global.
13377
13378 * normal/menu.c (grub_wait_after_message): New function.
13379 (grub_color_menu_normal): New variable. Replaces ...
13380 (GRUB_COLOR_MENU_NORMAL): ... this macro.
13381 (grub_color_menu_highlight): New variable. Replaces ...
13382 (GRUB_COLOR_MENU_HIGHLIGHT): ... this macro.
13383 (draw_border): Set color state to `GRUB_TERM_COLOR_NORMAL' instead of
13384 `GRUB_TERM_COLOR_STANDARD'.
13385 (print_message): Use `grub_setcolorstate' to reload colors. Rename
13386 `normal_code' and `highlight_code' to `old_color_normal' and
13387 `old_color_highlight', respectively.
13388 (grub_menu_init_page): Update colors when drawing the menu, based on
13389 `menu_color_normal' and `menu_color_highlight' variables.
13390 (grub_menu_run): Rely on grub_wait_after_message() for waiting after
13391 a message is printed.
13392
182dd4e5 133932008-01-05 Robert Millan <rmh@aybabtu.com>
13394
13395 * kern/env.c (grub_env_context_open): Propagate hooks for global
13396 variables to new context.
13397
13398 * kern/main.c (grub_set_root_dev): Export `root' variable.
13399
ddf8f6ad 134002008-01-05 Robert Millan <rmh@aybabtu.com>
13401
13402 * util/biosdisk.c (get_os_disk): Check for devfs-style IDE and SCSI
fe6b695a 13403 discs unconditionally, since udev and others have options to provide
ddf8f6ad 13404 them.
13405
d8b43d9b 134062008-01-05 Robert Millan <rmh@aybabtu.com>
13407
13408 * normal/completion.c (iterate_dir): Skip `.' and `..' directories.
13409
2bff2de3 134102008-01-04 Christian Franke <franke@computer.org>
13411
13412 * kern/i386/pc/init.c (grub_machine_init): Fix evaluation
13413 of eisa_mmap.
13414
97eab917 134152008-01-03 Pavel Roskin <proski@gnu.org>
13416
13417 * kern/i386/linuxbios/init.c: Put "void" to all function
13418 declarations with no arguments.
13419 * kern/powerpc/ieee1275/init.c: Likewise.
13420 * term/i386/pc/at_keyboard.c: Likewise.
13421 * term/i386/pc/vga_text.c: Likewise.
13422 * util/grub-mkdevicemap.c: Likewise.
13423
b9416d00 134242008-01-02 Robert Millan <rmh@aybabtu.com>
13425
13426 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Improve error
13427 message when loaded image is out of bounds.
13428 (grub_multiboot_load_elf64): Likewise.
13429
92695df9 134302008-01-02 Pavel Roskin <proski@gnu.org>
13431
13432 * util/grub.d/10_linux.in: Try version without ".old" when
13433 looking for initrd. It's better to use initrd from the newer
13434 kernel of the same version than no initrd at all.
13435
d98d9cad 134362008-01-01 Robert Millan <rmh@aybabtu.com>
13437
13438 * util/biosdisk.c (get_os_disk): Fix check for IDE or SCSI discs.
13439
dbfdce36 134402008-01-01 Vesa Jaaskelainen <chaac@nic.fi>
13441
f19dbdb7 13442 * include/grub/video.h: Added grub_video_unmap_color and
dbfdce36 13443 grub_video_get_active_render_target.
13444 (grub_video_adapter): Added unmap_color and get_active_render_target.
13445
f19dbdb7 13446 * video/video.c: Added grub_video_unmap_color and
dbfdce36 13447 grub_video_get_active_render_target.
13448 (grub_video_get_info): Changed method to accept NULL pointer as an
13449 argument to allow detection of active video adapter.
13450
13451 * video/i386/pc/vbe.c: Renamed grub_video_vbe_unmap_color as
13452 grub_video_vbe_unmap_color_int.
13453 Added grub_video_vbe_unmap_color and
13454 grub_video_vbe_get_active_render_target.
13455 (grub_video_vbe_adapter): Added unmap_color and
13456 get_active_render_target.
13457
f19dbdb7 13458 * video/i386/pc/vbeblit.c: Replaced grub_video_vbe_unmap_color usage
dbfdce36 13459 with grub_video_vbe_unmap_color_int.
13460
13461 * term/gfxterm.c (DEFAULT_STANDARD_COLOR): Added.
13462 (DEFAULT_NORMAL_COLOR): Likewise.
13463 (DEFAULT_HIGHLIGHT_COLOR) Likewise.
13464 (DEFAULT_FG_COLOR): Removed.
13465 (DEFAULT_BG_COLOR): Likewise.
13466 (DEFAULT_CURSOR_COLOR): Changed value.
13467 (grub_virtual_screen): Added standard_color_setting,
13468 normal_color_setting, highlight_color_setting and term_color.
13469 (grub_virtual_screen): Removed fg_color_setting and bg_color_setting.
13470 (bitmap_width): Added.
13471 (bitmap_height): Likewise.
13472 (bitmap): Likewise.
13473 (set_term_color): Likewise.
13474 (grub_virtual_screen_setup): Changed to use new terminal coloring
13475 settings.
13476 (grub_gfxterm_init): Added init for bitmap.
13477 (grub_gfxterm_fini): Added destroy for bitmap.
13478 (redraw_screen_rect): Updated to use background bitmap and new
13479 terminal coloring.
13480 (scroll_up): Added optimization for case when there is no bitmap.
13481 (grub_gfxterm_cls): Fixed to use correct background color.
13482 (grub_virtual_screen_setcolorstate): Changed to use new terminal
13483 coloring.
13484 (grub_virtual_screen_setcolor): Likewise.
13485 (grub_virtual_screen_getcolor): Added.
13486 (grub_gfxterm_background_image_cmd): Likewise.
13487 (grub_video_term): Added setcolor and getcolor.
13488 (MOD_INIT): Added registration of background_image command.
13489 (MOD_TERM): Added unregistration for background_image command.
13490
c3c20931 134912007-12-30 Pavel Roskin <proski@gnu.org>
13492
13493 * loader/multiboot_loader.c: Fix multiboot command
13494 unregistration. Fix all typos in the word "multiboot".
13495
df266716 134962007-12-29 Pavel Roskin <proski@gnu.org>
94239199 13497
13498 * util/grub.d/10_linux.in: Refactor search for initrd. Add
13499 support for initrd names used in Fedora.
13500
fc6e896c 135012007-12-26 Bean <bean123ch@gmail.com>
13502
13503 * conf/common.rmk (pkgdata_MODULES): Add cpio.mod.
13504 (cpio_mod_SOURCES): New variable.
13505 (cpio_mod_CFLAGS): Likewise.
13506 (cpio_mod_LDFLAGS): Likewise.
13507
13508 * fs/cpio.c: New file.
13509
13510 * conf/i386-pc.rmk (grub_emu_SOURCES): Add cpio.c.
13511
13512 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
13513
13514 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
13515
13516 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
13517
533110ad 135182007-12-25 Robert Millan <rmh@aybabtu.com>
13519
13520 * include/grub/term.h (struct grub_term): Add `getcolor' function.
13521 (grub_getcolor): New function.
13522
13523 * kern/term.c (grub_getcolor): New function.
13524 * normal/menu.c (GRUB_COLOR_MENU_NORMAL): New macro.
13525 (GRUB_COLOR_MENU_HIGHLIGHT): New macro.
13526 (print_entry): Set normal and highlight colors to
13527 `GRUB_COLOR_MENU_NORMAL' and `GRUB_COLOR_MENU_HIGHLIGHT',
13528 respectively, before printing and restore them to old
13529 values afterwards.
13530 (grub_menu_init_page): Likewise. Fill an additional colored space
13531 that would otherwise be left blank.
13532
13533 * term/efi/console.c (grub_console_getcolor): New function.
13534 (struct grub_console_term.getcolor): New variable.
13535 * term/i386/pc/console.c (grub_console_getcolor): New function.
13536 (struct grub_console_term.getcolor): New variable.
13537 * term/ieee1275/ofconsole.c (grub_ofconsole_getcolor): New function.
13538 (struct grub_console_term.getcolor): New variable.
13539
13540 * term/i386/pc/serial.c (grub_serial_setcolor): Remove function.
13541 (struct grub_console_term.setcolor): Remove variable.
13542 * term/i386/pc/vesafb.c (grub_virtual_screen_setcolor): Remove function.
13543 (struct grub_console_term.setcolor): Remove variable.
13544 * term/i386/pc/vga.c (grub_vga_setcolor): Remove function.
13545 (struct grub_console_term.setcolor): Remove variable.
13546 * term/gfxterm.c (grub_virtual_screen_setcolor): Remove function.
13547 (struct grub_console_term.setcolor): Remove variable.
13548
4931827f 135492007-12-25 Robert Millan <rmh@aybabtu.com>
13550
13551 * configure.ac: Search for possible unifont.hex locations, and
13552 define UNIFONT_HEX if found.
13553
13554 * Makefile.in (UNIFONT_HEX): Define variable.
13555 (DATA): Rename to ...
13556 (PKGLIB): ... this. Update all users.
13557 (PKGDATA): New variable.
13558 (pkgdata_IMAGES): Rename to ...
13559 (pkglib_IMAGES): ... this. Update all users.
13560 (pkgdata_MODULES): Rename to ...
13561 (pkglib_MODULES): ... this. Update all users.
13562 (pkgdata_PROGRAMS): Rename to ...
13563 (pkglib_PROGRAMS): ... this. Update all users.
13564 (pkgdata_DATA): Rename to ...
13565 (pkglib_DATA): ... this. Update all users.
13566 (CLEANFILES): Redefine to `$(pkglib_DATA) $(pkgdata_DATA)'.
13567 (unicode.pff, ascii.pff): New rules.
13568 (all-local): Add `$(PKGDATA)' dependency.
13569 (install-local): Process `$(PKGDATA)'.
13570
13571 * util/update-grub_lib.in (font_path): Search for *.pff files in
13572 a few more locations, including `${pkgdata}'.
13573
57e57e31 135742007-12-23 Robert Millan <rmh@aybabtu.com>
13575
13576 Patch from Bean <bean123ch@gmail.com>:
13577 * disk/loopback.c (grub_loopback_read): Add missing bit shift to
13578 `size'.
13579
4bc72aa9 135802007-12-21 Bean <bean123ch@gmail.com>
13581
13582 * conf/common.rmk (pkgdata_MODULES): Add ntfscomp.mod.
13583 (ntfscomp_mod_SOURCES): New variable.
13584 (ntfscomp_mod_CFLAGS): Likewise.
13585 (ntfscomp_mod_LDFLAGS): Likewise.
13586
13587 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfscomp.c.
13588 (grub_probe_SOURCES): Likewise.
13589 (grub_emu_SOURCES): Likewise.
13590
13591 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
13592 (grub_emu_SOURCES): Likewise.
13593
13594 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
13595 (grub_emu_SOURCES): Likewise.
13596
13597 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
13598 (grub_emu_SOURCES): Likewise.
13599
13600 * fs/ntfs.c (grub_ntfscomp_func): New variable.
13601 (read_run_list): Renamed to grub_ntfs_read_run_list.
13602 (decomp_nextvcn): Moved to ntfscomp.c.
13603 (decomp_getch): Likewise.
13604 (decomp_get16): Likewise.
13605 (decomp_block): Likewise.
13606 (read_block): Likewise.
13607 (read_data): Partially moved to ntfscomp.c.
13608 (fixup): Change unsigned to grub_uint16_t.
13609 (read_mft): Change unsigned long to grub_uint32_t.
13610 (read_attr): Likewise.
13611 (read_data): Likewise.
13612 (read_run_data): Likewise.
13613 (read_run_list): Likewise.
13614 (read_mft): Likewise.
13615
13616 * fs/ntfscomp.c: New file.
13617
13618 * include/grub/ntfs.h: New file.
13619
af680a87 136202007-12-16 Robert Millan <rmh@aybabtu.com>
13621
13622 * util/grub-mkdevicemap.c (make_device_map): Iterate up to 20 for
13623 IDE disk check, since Linux is known to support 20 IDE disks.
13624 Reported by Colin Watson.
13625
84be7599 136262007-12-15 Bean <bean123ch@gmail.com>
13627
13628 * conf/i386-pc.rmk (pkgdata_IMAGES): Add lnxboot.img.
13629 (lnxboot_img_SOURCES): New variable.
13630 (lnxboot_img_ASFLAGS): Likewise.
13631 (lnxboot_img_LDFLAGS): Likewise.
13632
13633 * boot/i386/pc/lnxboot.S: New file.
13634
6af9db01 136352007-11-24 Pavel Roskin <proski@gnu.org>
13636
13637 * configure.ac: Test if '--build-id=none' is supported by the
13638 linker. If yes, add it to TARGET_LDFLAGS. Build ID causes
13639 objcopy to generate incorrect binary files (binutils
13640 2.17.50.0.18-1 as shipped by Fedora 8).
13641 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Use LDFLAGS when
13642 linking, so that build ID doesn't break the test.
13643
7361cfe6 136442007-11-24 Pavel Roskin <proski@gnu.org>
13645
13646 * include/grub/i386/time.h: use "void" in the argument list
13647 of grub_cpu_idle().
13648 * include/grub/powerpc/time.h: Likewise.
13649 * include/grub/sparc64/time.h: Likewise.
13650
1593e10c 136512007-11-18 Christian Franke <franke@computer.org>
13652
13653 * util/console.c (grub_ncurses_getkey): Change curses KEY_* mapping,
13654 now return control chars instead of GRUB_CONSOLE_KEY_* constants.
13655 This fixes the problem that function keys did not work in grub-emu.
13656
3b8db1a8 136572007-11-18 Christian Franke <franke@computer.org>
13658
13659 * disk/host.c (grub_host_open): Remove attribute unused from
13660 name parameter. Add check for "host". This fixes the problem
13661 that grub-emu does not find partitions.
13662
2e29408d 136632007-11-18 Christian Franke <franke@computer.org>
13664
13665 * util/hostfs.c (is_dir): New function.
13666 (grub_hostfs_dir): Handle missing dirent.d_type case.
13667 (grub_hostfs_read): Add missing fseek().
13668 (grub_hostfs_label): Clear label pointer. This fixes a crash
13669 of grub-emu on "ls (host)".
13670
398cd047 136712007-11-18 Christian Franke <franke@computer.org>
13672
13673 * include/grub/i386/pc/init.h (struct grub_machine_mmap_entry):
13674 Add attribute packed, gcc 3.4.4 on Cygwin aligns this
13675 to 64 bit boundary by default.
13676
c405c391 136772007-11-18 Bean <bean123ch@gmail.com>
13678
13679 * conf/common.rmk (pkgdata_MODULES): Add hexdump.mod.
13680 (hexdump_mod_SOURCES): New variable.
13681 (hexdump_mod_CFLAGS): Likewise.
13682 (hexdump_mod_LDFLAGS): Likewise.
f19dbdb7 13683
c405c391 13684 * conf/i386-pc.rmk (grub_emu_SOURCES): Add command/hexdump.c.
13685
13686 * conf/i386-efi.rmk (grub_emu_SOURCES): Add command/hexdump.c.
13687
13688 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add command/hexdump.c.
13689
13690 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add command/hexdump.c.
13691
13692 * include/grub/hexdump.h: New file.
13693
13694 * commands/hexdump.c: New file.
13695
5cced7fd 136962007-11-10 Robert Millan <rmh@aybabtu.com>
13697
13698 * commands/i386/pc/play.c (beep_off): Switch order of arguments
13699 in grub_outb() calls.
13700 (beep_on): Likewise.
13701
8b714eb0 137022007-11-10 Christian Franke <franke@computer.org>
13703
13704 * normal/menu.c (run_menu): Check for empty menu to avoid crash.
13705 (grub_menu_run): Likewise.
13706
ce0f1839 137072007-11-10 Robert Millan <rmh@aybabtu.com>
13708
13709 * include/grub/i386/efi/machine.h: New file.
13710 * include/grub/i386/linuxbios/machine.h: Likewise.
13711 * include/grub/i386/pc/machine.h: Likewise.
13712 * include/grub/powerpc/ieee1275/machine.h: Likewise.
13713 * include/grub/sparc64/ieee1275/machine.h: Likewise.
13714
13715 * term/i386/pc/serial.c: Include <grub/machine/machine.h>.
13716 (serial_hw_io_addr): New variable.
13717 (serial_hw_get_port): Obtain port address from `serial_hw_io_addr'
13718 instead of `(unsigned short *) 0x400'.
13719
270c237d 137202007-11-10 Bean <bean123ch@gmail.com>
13721
13722 * fs/ntfs.c (read_block): Fix a bug caused by adjacent blocks.
13723
a87783bf 137242007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
13725
13726 * conf/i386-pc.rmk (pkgdata_MODULES): Added vga.mod.
13727 (vga_mod_SOURCES): Added.
13728 (vga_mod_CFLAGS): Likewise.
13729 (vga_mod_LDFLAGS): Likewise.
13730
13731 * term/i386/pc/vga.c (get_map_mask): Switch order of arguments in
13732 grub_outb() calls.
13733 (set_map_mask): Likewise.
13734 (set_read_map): Likewise.
13735 (set_read_address): Likewise.
13736 (vga_font): Removed variable.
13737 (get_vga_glyph): Removed function.
13738 (invalidate_char): Likewise.
13739 (write_char): Changed to use grub_font_get_glyph() for font
13740 information.
13741 (grub_vga_putchar): Likewise.
13742 (grub_vga_getcharwidth): Likewise.
13743
6433b448 137442007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
13745
13746 * conf/i386-pc.rmk (boot_img_LDFLAGS): Use COMMON_LDFLAGS for target
13747 flags.
13748 (pxeboot_img_LDFLAGS): Likewise.
13749 (diskboot_img_LDFLAGS): Likewise.
13750 (kernel_img_LDFLAGS): Likewise.
13751
49178511 137522007-11-06 Robert Millan <rmh@aybabtu.com>
13753
13754 * term/i386/pc/serial.c (serial_hw_put): Switch order of arguments
13755 in grub_outb() calls.
13756 (serial_hw_init): Likewise.
13757
53b052de 137582007-11-05 Robert Millan <rmh@aybabtu.com>
13759
13760 * util/update-grub.in: Allow files in ${update_grub_dir} to contain
13761 spaces. Skip non-regular files.
13762
5ab33bba 137632007-11-05 Robert Millan <rmh@aybabtu.com>
13764
13765 * kern/disk.c (grub_disk_firmware_fini)
13766 (grub_disk_firmware_is_tainted): New variables.
13767
13768 * include/grub/disk.h (grub_disk_firmware_fini)
13769 (grub_disk_firmware_is_tainted): Likewise.
13770
13771 * disk/i386/pc/biosdisk.c (GRUB_MOD_FINI(biosdisk)): Moved from here ...
13772 (grub_disk_biosdisk_fini): ... to here.
13773 (GRUB_MOD_FINI(biosdisk)): Implement using grub_disk_biosdisk_fini().
13774 (GRUB_MOD_INIT(biosdisk)): Abort when `grub_disk_firmware_is_tainted'
13775 is set. Register grub_disk_biosdisk_fini() in
13776 `grub_disk_firmware_fini'.
13777
13778 * disk/ata.c: Remove `<grub/machine/biosdisk.h>'.
13779 (GRUB_MOD_INIT(ata)): Remove grub_biosdisk_fini() call.
13780 Use `grub_disk_firmware_is_tainted' and `grub_disk_firmware_fini'
13781 to finish existing firmware disk interface.
13782
13783 * conf/i386-linuxbios.rmk (pkgdata_MODULES): Add `ata.mod'.
13784 (ata_mod_SOURCES): New variable.
13785 (ata_mod_CFLAGS): Likewise.
13786 (ata_mod_LDFLAGS): Likewise.
13787
0149ab7c 137882007-11-05 Robert Millan <rmh@aybabtu.com>
13789
13790 * disk/ata.c: Remove `<grub/machine/time.h>'. Include `<grub/time.h>'.
13791 (grub_ata_wait): Reimplement using grub_millisleep().
13792
13793 * include/grub/misc.h (grub_div_roundup): Fix parenthesization.
13794 * include/grub/i386/time.h (grub_cpu_idle): Disable `hlt' instruction.
13795
be7ac41e 137962007-11-03 Marco Gerards <marco@gnu.org>
13797
13798 * term/i386/pc/vga_text.c: Include <grub/cpu/io.h>.
13799 (CRTC_ADDR_PORT): New macro.
13800 (CRTC_DATA_PORT): Likewise.
13801 (CRTC_CURSOR): Likewise.
13802 (CRTC_CURSOR_ADDR_HIGH): Likewise.
13803 (CRTC_CURSOR_ADDR_LOW): Likewise.
13804 (update_cursor): New function.
13805 (grub_console_real_putchar): Call `update_cursor'.
13806 (grub_console_gotoxy): Likewise.
13807 (grub_console_cls): Set the default color when clearing the
13808 screen.
13809 (grub_console_setcursor): Implemented.
13810
bb06ab2e 138112007-11-03 Marco Gerards <marco@gnu.org>
13812
13813 * disk/ata.c (grub_ata_pio_read): Don't wait for the command to
13814 become activate.
13815 (grub_ata_pio_write): Likewise.
13816
13817 (grub_atapi_identify): Wait after issuing an ATA command.
13818 (grub_atapi_packet): Likewise.
13819 (grub_ata_identify): Likewise.
13820 (grub_ata_readwrite): Likewise.
13821
cf8f780b 138222007-11-03 Marco Gerards <marco@gnu.org>
13823
13824 * disk/ata.c (grub_ata_pio_read): Detect and return the error code.
13825 (grub_ata_pio_write): Likewise.
13826 (grub_ata_readwrite): Use `grub_error', instead of
13827 returning `grub_errno'.
13828
ed649e54 138292007-11-03 Marco Gerards <marco@gnu.org>
13830
13831 * disk/ata.c (grub_ata_readwrite): Call grub_ata_pio_read and
13832 grub_ata_pio_write once for every single sector, instead of for
13833 multiple sectors.
13834
ca25d8f0 138352007-10-31 Robert Millan <rmh@aybabtu.com>
13836
13837 * configure.ac: Add `i386-linuxbios' to the list of supported targets.
13838
13839 * conf/i386-linuxbios.rmk: New file.
13840
13841 * kern/i386/pc/hardware.c: Likewise.
13842 * term/i386/pc/at_keyboard.c: Likewise.
13843 * term/i386/pc/vga_text.c: Likewise.
13844
13845 * include/grub/i386/linuxbios/boot.h: Likewise.
13846 * include/grub/i386/linuxbios/console.h: Likewise.
13847 * include/grub/i386/linuxbios/init.h: Likewise.
13848 * include/grub/i386/linuxbios/kernel.h: Likewise.
13849 * include/grub/i386/linuxbios/loader.h: Likewise.
13850 * include/grub/i386/linuxbios/memory.h: Likewise.
13851 * include/grub/i386/linuxbios/serial.h: Likewise.
13852 * include/grub/i386/linuxbios/time.h: Likewise.
13853
13854 * kern/i386/linuxbios/init.c: Likewise.
13855 * kern/i386/linuxbios/startup.S: Likewise.
13856 * kern/i386/linuxbios/table.c: Likewise.
13857
e911ecc1 138582007-10-31 Marco Gerards <marco@gnu.org>
13859
13860 * conf/i386-pc.rmk (pkgdata_MODULES): Add `ata.mod'.
13861 (ata_mod_SOURCES): New variable.
13862 (ata_mod_CFLAGS): Likewise.
13863 (ata_mod_LDFLAGS): Likewise.
13864
13865 * disk/ata.c: New file.
13866
13867 * include/grub/disk.h (grub_disk_dev_id): Add
13868 `GRUB_DISK_DEV_ATA_ID'.
f19dbdb7 13869
7f66d0e0 138702007-10-31 Robert Millan <rmh@aybabtu.com>
13871
13872 * include/grub/i386/pc/init.h (grub_lower_mem): Moved from here ...
13873 * include/grub/i386/pc/memory.h (grub_lower_mem): ... to here.
13874
13875 * include/grub/i386/pc/init.h (grub_upper_mem): Moved from here ...
13876 * include/grub/i386/pc/memory.h (grub_upper_mem): ... to here.
13877
13878 * include/grub/i386/pc/memory.h: Include `<grub/symbol.h>' and
13879 `<grub/types.h>'.
13880
13881 * loader/i386/pc/multiboot.c: Include `<grub/machine/memory.h>'.
13882
5cd7dd46 138832007-10-27 Robert Millan <rmh@aybabtu.com>
13884
3236ca65 13885 * include/grub/types.h (ULONG_MAX): Define macro.
5cd7dd46 13886
2ebfc90f 138872007-10-22 Robert Millan <rmh@aybabtu.com>
13888
13889 * kern/i386/pc/startup.S: Remove `"kern/i386/realmode.S"'. Include
13890 `"../realmode.S"'.
13891 Remove `"kern/i386/loader.S"'. Include `"../loader.S"'.
13892
73fcb0f3 138932007-10-22 Robert Millan <rmh@aybabtu.com>
13894
13895 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove `disk/i386/pc/biosdisk.c'.
13896 (pkgdata_MODULES): Add `biosdisk.mod'.
13897 (biosdisk_mod_SOURCES, biosdisk_mod_CFLAGS, biosdisk_mod_LDFLAGS): New
13898 variables.
13899
13900 * disk/i386/pc/biosdisk.c: Include `<grub/dl.h>'.
13901 (grub_biosdisk_init): Replace with ...
13902 (GRUB_MOD_INIT(biosdisk)): ... this.
13903 (grub_biosdisk_fini): Replace with ...
13904 (GRUB_MOD_FINI(biosdisk)): ... this.
13905
13906 * kern/i386/pc/init.c: Remove `<grub/machine/biosdisk.h>'.
13907 (grub_machine_init): Remove call to grub_biosdisk_init().
13908 (grub_machine_fini): Remove call to grub_machine_fini().
13909
13910 * util/i386/pc/grub-install.in (modules): Add `biosdisk'.
13911
3381d274 139122007-10-22 Robert Millan <rmh@aybabtu.com>
13913
13914 * include/grub/time.h: New file.
13915 * include/grub/i386/time.h: Likewise.
13916 * include/grub/powerpc/time.h: Likewise.
13917 * include/grub/sparc64/time.h: Likewise.
13918
13919 * include/grub/i386/pc/time.h (KERNEL_TIME_HEADER): Rename all
13920 instances to ...
13921 (KERNEL_MACHINE_TIME_HEADER): ... this.
13922 * include/grub/powerpc/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
13923 instances to ...
13924 (KERNEL_MACHINE_TIME_HEADER): ... this.
13925 * include/grub/sparc64/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
13926 instances to ...
13927 (KERNEL_MACHINE_TIME_HEADER): ... this.
13928
13929 * kern/i386/efi/init.c: Include `<grub/time.h>'.
13930 (grub_millisleep): New function.
13931 * kern/i386/pc/init.c: Include `<grub/time.h>'.
13932 (grub_millisleep): New function.
13933 * kern/powerpc/ieee1275/init.c: Include `<grub/time.h>'.
13934 Remove `grub/machine/time.h' include.
13935 (grub_millisleep): New function.
13936 * kern/sparc64/ieee1275/init.c: Include `<grub/time.h>'.
13937 Remove `grub/machine/time.h' include.
13938 (grub_millisleep): New function.
13939
13940 * include/grub/misc.h (grub_div_roundup): New function.
13941
13942 * kern/misc.c: Include `<grub/time.h>'.
13943 (grub_millisleep_generic): New function.
13944
13945 * conf/i386-efi.rmk (kernel_mod_HEADERS): Remove `i386/efi/time.h'.
13946 Add `time.h'.
13947 * conf/i386-pc.rmk (kernel_img_HEADERS): Remove `machine/time.h'.
13948 Add `time.h'.
13949 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Remove
13950 `machine/time.h'. Add `time.h'.
13951 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
13952
a39a0312 139532007-10-21 Robert Millan <rmh@aybabtu.com>
13954
13955 * include/grub/misc.h (grub_max): New function.
13956
2aad70e2 139572007-10-21 Robert Millan <rmh@aybabtu.com>
13958
13959 * util/misc.c (grub_util_info): Call fflush() before returning.
13960
54b71c4b 139612007-10-20 Robert Millan <rmh@aybabtu.com>
13962
13963 * genmk.rb (Image): Copy `extra_flags' from here ...
13964 (PModule): ... to here. Use it in `#{obj}: #{src}' rule.
13965
13966 * commands/i386/cpuid.c (grub_cmd_cpuid): Add __attribute__ ((unused))
13967 to `argc' and `args' arguments.
13968
a979f513 139692007-10-17 Robert Millan <rmh@aybabtu.com>
13970
13971 * kern/i386/loader.S: New file.
13972
13973 * kern/i386/pc/startup.S (grub_linux_prot_size): Moved from here ...
13974 * kern/i386/loader.S (grub_linux_prot_size)... to here.
13975 * kern/i386/pc/startup.S (grub_linux_tmp_addr): Moved from here ...
13976 * kern/i386/loader.S (grub_linux_tmp_addr)... to here.
13977 * kern/i386/pc/startup.S (grub_linux_real_addr): Moved from here ...
13978 * kern/i386/loader.S (grub_linux_real_addr)... to here.
13979 * kern/i386/pc/startup.S (grub_linux_boot_zimage): Moved from here ...
13980 * kern/i386/loader.S (grub_linux_boot_zimage)... to here.
13981 * kern/i386/pc/startup.S (grub_linux_boot_bzimage): Moved from here ...
13982 * kern/i386/loader.S (grub_linux_boot_bzimage)... to here.
13983 * kern/i386/pc/startup.S (grub_multiboot_real_boot): Moved from here ...
13984 * kern/i386/loader.S (grub_multiboot_real_boot)... to here.
13985 * kern/i386/pc/startup.S (grub_multiboot2_real_boot): Moved from here ...
13986 * kern/i386/loader.S (grub_multiboot2_real_boot)... to here.
13987
13988 * kern/i386/realmode.S: New file.
13989
13990 * kern/i386/pc/startup.S (protstack): Moved from here ...
13991 * kern/i386/realmode.S (protstack)... to here.
13992 * kern/i386/pc/startup.S (gdt): Moved from here ...
13993 * kern/i386/realmode.S (gdt)... to here.
13994 * kern/i386/pc/startup.S (prot_to_real): Moved from here ...
13995 * kern/i386/realmode.S (prot_to_real)... to here.
13996
13997 * kern/i386/pc/startup.S: Include `kern/i386/loader.S' and
13998 `kern/i386/realmode.S'.
13999
825fc8fd 140002007-10-17 Robert Millan <rmh@aybabtu.com>
14001
14002 * include/grub/i386/loader.h: New file.
14003
14004 * include/grub/i386/pc/loader.h (grub_linux_prot_size)
14005 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
14006 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
14007 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
14008 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): Moved from here ...
14009 * include/grub/i386/loader.h (grub_linux_prot_size)
14010 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
14011 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
14012 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
14013 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): ... to here.
14014
14015 * include/grub/i386/pc/loader.h: Include `grub/cpu/loader.h'.
14016
e179b2f4 140172007-10-15 Robert Millan <rmh@aybabtu.com>
14018
14019 * normal/misc.c (grub_normal_print_device_info): Do not probe for
14020 filesystem when dev->disk is unset.
14021 Do probe for filesystem even when dev->disk->has_partitions is set.
14022 In case a filesystem is found, always report it.
14023 In case it isn't, if dev->disk->has_partitions is set, report that
14024 a partition table was found instead of reporting that no filesystem
14025 could be identified.
14026
5db82af6 140272007-10-12 Robert Millan <rmh@aybabtu.com>
14028
14029 * conf/powerpc-ieee1275.rmk (grub_mkimage_SOURCES): Replace reference
14030 to util/powerpc/ieee1275/grub-mkimage.c with util/elf/grub-mkimage.c.
14031
68f6ac74 14032 * include/grub/types.h (grub_host_to_target16): New macro.
14033 (grub_host_to_target32): Likewise.
14034 (grub_host_to_target64): Likewise.
14035 (grub_target_to_host16): Likewise.
14036 (grub_target_to_host32): Likewise.
14037 (grub_target_to_host64): Likewise.
5db82af6 14038
14039 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
14040 Renamed from to ...
14041 (GRUB_MOD_ALIGN): ...this. Update all users.
14042
68f6ac74 14043 * util/elf/grub-mkimage.c (load_note): Replace grub_cpu_to_be32 with
14044 grub_host_to_target32.
14045 Replace grub_be_to_cpu32 with grub_target_to_host32.
14046 (load_modules): Likewise.
14047 (add_segments): Replace grub_be_to_cpu16 with grub_target_to_host16.
14048 Replace grub_be_to_cpu32 with grub_target_to_host32.
14049 Replace grub_cpu_to_be16 with grub_host_to_target16.
14050 Replace grub_cpu_to_be32 grub_host_to_target32.
5db82af6 14051
3cf497cc 140522007-10-12 Robert Millan <rmh@aybabtu.com>
14053
14054 * util/powerpc/ieee1275/grub-mkimage.c: Moved to ...
14055 * util/elf/grub-mkimage.c: ... here.
14056
14057 * DISTLIST: Add `util/elf/grub-mkimage.c'. Remove
14058 `util/powerpc/ieee1275/grub-mkimage.c'.
14059
c8cc3692 140602007-10-07 Robert Millan <rmh@aybabtu.com>
adbc4c9d 14061
c8cc3692 14062 * kern/powerpc/ieee1275/init.c: Rename HEAP_LIMIT to HEAP_MAX_ADDR,
14063 and make it easier to figure out.
14064 Add HEAP_MIN_SIZE and HEAP_MAX_ADDR definitions.
14065 (grub_claim_heap): Use HEAP_MAX_ADDR rather than taking a parameter.
14066 Do not avoid claiming a region above HEAP_MAX_ADDR if that would
14067 leave us with less than HEAP_MIN_SIZE total heap.
14068 Avoid our total amount of heap to surpass HEAP_MAX_SIZE.
adbc4c9d 14069
5c58b791 140702007-10-03 Robert Millan <rmh@aybabtu.com>
14071
14072 * include/grub/i386/io.h: New file.
14073 * commands/i386/pc/play.c (inb): Removed.
14074 (outb): Removed.
14075 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
14076 with grub_outb().
afcd2ef8 14077 * term/i386/pc/serial.c (inb): Removed.
14078 (outb): Removed.
14079 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
14080 with grub_outb().
14081 * term/i386/pc/vga.c (inb): Removed.
14082 (outb): Removed.
14083 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
14084 with grub_outb().
5c58b791 14085
1a477ed6 140862007-10-02 Robert Millan <rmh@aybabtu.com>
14087
14088 * conf/i386-efi.rmk (grub_emu_SOURCES): Add util/hostfs.c.
14089 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
14090 Reported by Marcin Kurek.
14091
6b5d80fa 140922007-09-07 Robert Millan <rmh@aybabtu.com>
14093
14094 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_test_flag): Detect
14095 SmartFirmware version updates (as released by Sven Luther), and avoid
14096 setting GRUB_IEEE1275_FLAG_NO_PARTITION_0 or
14097 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS unless the running version is
14098 known broken.
14099
5618afbf 141002007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
14101
14102 From Hitoshi Ozeki:
14103 * kern/i386/pc/init.c (compact_mem_regions): Decrease NUM_REGIONS
14104 when merging two regions.
14105
6139dcd9 141062007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
14107
508e39ee 14108 * kern/rescue.c (grub_enter_rescue_mode): Free ARGS.
14109 * normal/completion.c (grub_normal_do_completion): Likewise.
14110 Reported by Hitoshi Ozeki.
14111
141122007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
f19dbdb7 14113
6139dcd9 14114 Do not use devices at boot in chainloading.
f19dbdb7 14115
6139dcd9 14116 * loader/i386/pc/chainloader.c (boot_drive): New variable.
14117 (boot_part_addr): Likewise.
14118 (grub_chainloader_boot): Simply call grub_chainloader_real_boot
14119 with BOOT_DRIVE and BOOT_PART_ADDR.
14120 (grub_chainloader_cmd): Set BOOT_DRIVE and BOOT_PART_ADDR.
14121 Reported by Hitoshi Ozeki <h-ozeki@ck2.so-net.ne.jp>.
14122
38da6516 141232007-08-29 Robert Millan <rmh@aybabtu.com>
14124
14125 Patch from Simon Peter <dn.tlp@gmx.net>:
14126 * genmk.rb (Utility): Append $(#{src}_DEPENDENCIES) to #{obj} targets.
14127 * conf/i386-pc.rmk: Replace grub-probe_DEPENDENCIES with
14128 util/grub-probe.c_DEPENDENCIES. Replace grub-setup_DEPENDENCIES with
14129 util/i386/pc/grub-setup.c_DEPENDENCIES.
14130 * conf/i386-efi.rmk: Replace grub-probe_DEPENDENCIES with
14131 util/grub-probe.c_DEPENDENCIES.
14132 * conf/powerpc-ieee1275.rmk: Likewise.
14133
29d0928c 141342007-08-28 Robert Millan <rmh@aybabtu.com>
14135
14136 * util/i386/get_disk_name.c: New. Implement grub_util_get_disk_name()
14137 to tell grub-mkdevicemap how to name devices.
14138 * util/ieee1275/get_disk_name.c: Likewise (using "ofpathname -a"
14139 feature).
14140
14141 * conf/i386-efi.rmk (grub_mkdevicemap_SOURCES): Add
14142 util/i386/get_disk_name.c.
14143 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Likewise.
14144 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Add
14145 util/ieee1275/get_disk_name.c.
14146
14147 * include/grub/util/misc.h: grub_util_get_disk_name() declaration.
14148
14149 * DISTLIST: Add util/i386/get_disk_name.c and
14150 util/ieee1275/get_disk_name.c.
14151
14152 * util/grub-mkdevicemap.c: Replace device naming logic with
14153 grub_util_get_disk_name() calls.
14154
5a0d3cca 141552007-08-20 Robert Millan <rmh@aybabtu.com>
14156
14157 * normal/menu.c (run_menu): Refer to seconds as "s" not "seconds"
14158 (so that it works for both plural and singular quantities).
14159
8b72db2f 141602007-08-05 Robert Millan <rmh@aybabtu.com>
14161
14162 * util/grub.d/10_linux.in (test_gt): Strip out vmlinu[xz]- prefix
14163 so that [xz] isn't taken into account when determining order.
14164
352466bf 141652007-08-02 Marco Gerards <marco@gnu.org>
14166
14167 * DISTLIST: Add `disk/host.c', `fs/ntfs.c', `include/multiboot.h',
14168 `include/multiboot2.h', `include/grub/elfload.h',
14169 `include/multiboot.h', `include/grub/multiboot.h',
14170 `include/grub/multiboot_loader.h', `include/grub/multiboot2.h',
14171 `include/grub/i386/pc/biosdisk.h', `include/grub/util/biosdisk.h',
14172 `kern/elf.c', `loader/multiboot_loader.c',
14173 `loader/multiboot_loader_normal.c', `loader/multiboot2.c',
14174 `loader/i386/pc/multiboot2.c',
14175 `loader/powerpc/ieee1275/multiboot2.c', `util/hostfs.c' and
14176 `util/i386/pc/grub-mkrescue.in'. Remove
14177 `include/grub/biosdisk.h', `include/grub/i386/pc/multiboot.h',
14178 `include/grub/i386/pc/util/biosdisk.h' and
14179 `include/grub/powerpc/ieee1275/multiboot.h'.
14180
8f096014 141812007-08-02 Bean <bean123ch@gmail.com>
14182
14183 * conf/common.rmk (pkgdata_MODULES): Add ntfs.mod.
14184 (ntfs_mod_SOURCES): New variable.
14185 (ntfs_mod_CFLAGS): Likewise.
14186 (ntfs_mod_LDFLAGS): Likewise.
14187
14188 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfs.c.
14189 (grub_probe_SOURCES): Likewise.
14190 (grub_emu_SOURCES): Likewise.
14191
14192 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
14193 (grub_emu_SOURCES): Likewise.
14194
14195 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
14196 (grub_emu_SOURCES): Likewise.
f19dbdb7 14197
8f096014 14198 * conf/misc.c (grub_utf16_to_utf8): Fix unicode conversion bug.
14199
14200 * fs/ntfs.c: New file.
14201
9959f7db 142022007-08-02 Bean <bean123ch@gmail.com>
14203
14204 * disk.h (grub_disk): Use NESTED_FUNC_ATTR.
14205
14206 * file.h (grub_file): Likewise.
14207
14208 * fshelp.h (grub_fshelp_read_file): Likewise.
14209
14210 * util/i386/pc/grub-setup.c (setup): Likewise.
14211 (save_first_sector): Likewise.
14212 (save_blocklists): Likewise.
f19dbdb7 14213
9959f7db 14214 * fs/affs.c (grub_affs_read_file): Likewise.
14215
14216 * fs/ext2.c (grub_ext2_read_file): Likewise.
14217
14218 * fs/fat.c (grub_fat_read_data): Likewise.
14219
14220 * fs/fshelp.c (grub_fshelp_read_file): Likewise.
14221
14222 * fs/hfs.c (grub_hfs_read_file): Likewise.
14223
14224 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
14225
14226 * fs/jfs.c (grub_jfs_read_file): Likewise.
14227
14228 * fs/minix.c (grub_minix_read_file): Likewise.
14229
14230 * fs/sfs.c (grub_sfs_read_file): Likewise.
14231
14232 * fs/ufs.c (grub_ufs_read_file): Likewise.
f19dbdb7 14233
9959f7db 14234 * fs/xfs.c (grub_xfs_read_file): Likewise.
14235
14236 * command/blocklist.c (read_blocklist): Likewise.
14237 (print_blocklist): Likewise.
14238
0a203f83 142392007-08-02 Marco Gerards <marco@gnu.org>
14240
14241 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/host.c' and
14242 `util/hostfs.c'.
14243
14244 * disk/host.c: New file.
14245
14246 * util/hostfs.c: Likewise.
14247
14248 * fs/hfsplus.c (grub_hfsplus_mount): When reading out of disk,
14249 return `GRUB_ERR_BAD_FS'.
14250 * fs/sfs.c (grub_sfs_mount): Likewise.
14251 * fs/xfs.c (grub_xfs_mount): Likewise.
14252
14253 * include/grub/disk.h (enum grub_disk_dev_id): Add
14254 `GRUB_DISK_DEVICE_HOST_ID'.
14255
14256 * util/grub-emu.c (main): Initialize and de-initialize hostfs.
14257
e5dfe777 142582007-07-24 Jerone Young <jerone@gmail.com>
14259
f19dbdb7 14260 * conf/i386-pc.rmk: Add Multiboot loader and multiboot 2 to multiboot
e5dfe777 14261 modules for compilation.
14262 * conf/powerpc-ieee1275.rmk: Likewise.
14263
14264 * include/multiboot.h: Move multiboot definitions to one file. Rename
14265 many definitions to not get grub specific.
14266 * include/multiboot2.h: Create header with multiboot 2 definitions.
14267 * include/grub/multiboot.h: Header for grub specific function
14268 prototypes and definitions.
14269 * include/grub/multiboot2.h: Likewise.
14270 * include/grub/multiboot_loader.h: Likewise.
14271 * include/grub/i386/pc/multiboot.h: Removed.
14272 * include/grub/powerpc/ieee1275/multiboot.h: Removed.
14273
14274 * loader/multiboot_loader.c: Created to act as a proxy for multiboot 1
14275 and 2 to allow for one multiboot and module commands.
14276 * loader/multiboot2.c: Add multiboot2 functionality.
14277 * loader/i386/pc/multiboot.c: Modify for new multiboot header location
14278 and definition names.
14279 * loader/i386/pc/multiboot2.c: Created to add i386 specific multiboot
14280 2 functions.
14281 * loader/powerpc/ieee1275/multiboot2.c: Created to add powerpc
14282 ieee1275 specific multiboot2 code.
14283
14284 * kern/i386/pc/startup.S: Change headers and definition names for
14285 multiboot. Add function grub_multiboot2_real_boot for multiboot 2.
14286
daf0f0ba 142872007-07-22 Robert Millan <rmh@aybabtu.com>
14288
14289 * geninitheader.sh: Process file specified in first parameter rather
14290 than hardcoding grub_modules_init.lst.
fe6b695a 14291 * geninit.sh: Likewise. Also, construct header name dynamically rather
daf0f0ba 14292 than hardcoding grub_modules_init.h.
14293
14294 * conf/common.rmk: Rename grub_modules_init.[ch] files associated with
14295 grub-emu to grub_emu_init.[ch]. Add rules to build analogous
14296 grub_probe_init.[ch] and grub_setup_init.[ch].
14297
14298 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Replace
14299 grub_modules_init.h with grub_emu_init.h.
14300 (grub_probe_DEPENDENCIES, grub_probe_SOURCES): Add new
14301 grub_probe_init.[ch] files.
14302 * conf/i386-efi.rmk: Likewise.
14303 * conf/i386-pc.rmk: Likewise.
14304 (grub_setup_DEPENDENCIES, grub_setup_SOURCES): Add new
14305 grub_setup_init.[ch] files.
14306
14307 * util/grub-emu.c: Replace grub_modules_init.h with grub_emu_init.h.
14308 * util/grub-probe.c: Include grub_probe_init.h. Use grub_init_all()
14309 to initialize modules rather than a list of hardcoded functions.
14310 * util/i386/pc/grub-setup.c: Include grub_setup_init.h. Use
14311 grub_init_all() to initialize modules rather than a list of hardcoded
14312 functions.
14313
54cdc1cc 143142007-07-22 Robert Millan <rmh@aybabtu.com>
14315
14316 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set
14317 GRUB_IEEE1275_FLAG_NO_PARTITION_0 flag when running on SmartFirmware.
14318
ad0686cc 143192007-07-22 Robert Millan <rmh@aybabtu.com>
14320
14321 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
14322 GRUB_IEEE1275_FLAG_BROKEN_OUTPUT flag.
14323 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set this
14324 flag when running on SmartFirmware.
14325 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid running
14326 "output-device output" command when GRUB_IEEE1275_FLAG_BROKEN_OUTPUT
14327 was set.
14328
14329 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
14330 Increase partno when GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS flag is set,
14331 rather than decreasing it.
14332
14333 * util/i386/pc/grub-setup.c (setup): When embedding is required, but
14334 there's not enough space to do it, fail in the same way as when it
14335 can't be done because there are no partitions.
14336
14337 * util/powerpc/ieee1275/grub-install.in: Improve error message shown
14338 when nvsetenv failed.
14339
969c02ec 143402007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
14341
14342 * conf/i386-pc.rmk (CLEANFILES): Removed for grub-mkrescue,
14343 because this rule is automatically generated.
14344 (grub-mkrescue): Removed for the same reason as above.
14345
5a79f472 143462007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
14347
14348 Migrate to GNU General Public License Version 3.
f19dbdb7 14349
5a79f472 14350 * COPYING: Replaced with the plain text version of GPLv3.
14351
14352 * config.guess: Updated from gnulib.
14353 * config.sub: Likewise.
14354
14355 * geninit.sh: Output a GPLv3 copyright notice.
14356 * geninitheader.sh: Likewise.
14357 * genmodsrc.sh: Likewise.
14358 * gensymlist.sh.in: Likewise.
14359
14360 * boot/i386/pc/boot.S: Upgraded to GPLv3.
14361 * boot/i386/pc/diskboot.S: Likewise.
14362 * boot/i386/pc/pxeboot.S: Likewise.
14363 * commands/blocklist.c: Likewise.
14364 * commands/boot.c: Likewise.
14365 * commands/cat.c: Likewise.
14366 * commands/cmp.c: Likewise.
14367 * commands/configfile.c: Likewise.
14368 * commands/echo.c: Likewise.
14369 * commands/help.c: Likewise.
14370 * commands/ls.c: Likewise.
14371 * commands/search.c: Likewise.
14372 * commands/terminal.c: Likewise.
14373 * commands/test.c: Likewise.
14374 * commands/videotest.c: Likewise.
14375 * commands/i386/cpuid.c: Likewise.
14376 * commands/i386/pc/halt.c: Likewise.
14377 * commands/i386/pc/play.c: Likewise.
14378 * commands/i386/pc/reboot.c: Likewise.
14379 * commands/i386/pc/vbeinfo.c: Likewise.
14380 * commands/i386/pc/vbetest.c: Likewise.
14381 * commands/ieee1275/halt.c: Likewise.
14382 * commands/ieee1275/reboot.c: Likewise.
14383 * commands/ieee1275/suspend.c: Likewise.
14384 * disk/loopback.c: Likewise.
14385 * disk/lvm.c: Likewise.
14386 * disk/raid.c: Likewise.
14387 * disk/efi/efidisk.c: Likewise.
14388 * disk/i386/pc/biosdisk.c: Likewise.
14389 * disk/ieee1275/ofdisk.c: Likewise.
14390 * font/manager.c: Likewise.
14391 * fs/affs.c: Likewise.
14392 * fs/ext2.c: Likewise.
14393 * fs/fat.c: Likewise.
14394 * fs/fshelp.c: Likewise.
14395 * fs/hfs.c: Likewise.
14396 * fs/hfsplus.c: Likewise.
14397 * fs/iso9660.c: Likewise.
14398 * fs/jfs.c: Likewise.
14399 * fs/minix.c: Likewise.
14400 * fs/sfs.c: Likewise.
14401 * fs/ufs.c: Likewise.
14402 * fs/xfs.c: Likewise.
14403 * hello/hello.c: Likewise.
14404 * include/grub/acorn_filecore.h: Likewise.
14405 * include/grub/arg.h: Likewise.
14406 * include/grub/bitmap.h: Likewise.
14407 * include/grub/boot.h: Likewise.
14408 * include/grub/cache.h: Likewise.
14409 * include/grub/device.h: Likewise.
14410 * include/grub/disk.h: Likewise.
14411 * include/grub/dl.h: Likewise.
14412 * include/grub/elfload.h: Likewise.
14413 * include/grub/env.h: Likewise.
14414 * include/grub/err.h: Likewise.
14415 * include/grub/file.h: Likewise.
14416 * include/grub/font.h: Likewise.
14417 * include/grub/fs.h: Likewise.
14418 * include/grub/fshelp.h: Likewise.
14419 * include/grub/gzio.h: Likewise.
14420 * include/grub/hfs.h: Likewise.
14421 * include/grub/kernel.h: Likewise.
14422 * include/grub/loader.h: Likewise.
14423 * include/grub/lvm.h: Likewise.
14424 * include/grub/misc.h: Likewise.
14425 * include/grub/mm.h: Likewise.
14426 * include/grub/net.h: Likewise.
14427 * include/grub/normal.h: Likewise.
14428 * include/grub/parser.h: Likewise.
14429 * include/grub/partition.h: Likewise.
14430 * include/grub/pc_partition.h: Likewise.
14431 * include/grub/raid.h: Likewise.
14432 * include/grub/rescue.h: Likewise.
14433 * include/grub/script.h: Likewise.
14434 * include/grub/setjmp.h: Likewise.
14435 * include/grub/symbol.h: Likewise.
14436 * include/grub/term.h: Likewise.
14437 * include/grub/terminfo.h: Likewise.
14438 * include/grub/tparm.h: Likewise.
14439 * include/grub/types.h: Likewise.
14440 * include/grub/video.h: Likewise.
14441 * include/grub/efi/api.h: Likewise.
14442 * include/grub/efi/chainloader.h: Likewise.
14443 * include/grub/efi/console.h: Likewise.
14444 * include/grub/efi/console_control.h: Likewise.
14445 * include/grub/efi/disk.h: Likewise.
14446 * include/grub/efi/efi.h: Likewise.
14447 * include/grub/efi/pe32.h: Likewise.
14448 * include/grub/efi/time.h: Likewise.
14449 * include/grub/i386/linux.h: Likewise.
14450 * include/grub/i386/setjmp.h: Likewise.
14451 * include/grub/i386/types.h: Likewise.
14452 * include/grub/i386/efi/kernel.h: Likewise.
14453 * include/grub/i386/efi/loader.h: Likewise.
14454 * include/grub/i386/efi/time.h: Likewise.
14455 * include/grub/i386/pc/biosdisk.h: Likewise.
14456 * include/grub/i386/pc/boot.h: Likewise.
14457 * include/grub/i386/pc/chainloader.h: Likewise.
14458 * include/grub/i386/pc/console.h: Likewise.
14459 * include/grub/i386/pc/init.h: Likewise.
14460 * include/grub/i386/pc/kernel.h: Likewise.
14461 * include/grub/i386/pc/loader.h: Likewise.
14462 * include/grub/i386/pc/memory.h: Likewise.
14463 * include/grub/i386/pc/multiboot.h: Likewise.
14464 * include/grub/i386/pc/serial.h: Likewise.
14465 * include/grub/i386/pc/time.h: Likewise.
14466 * include/grub/i386/pc/vbe.h: Likewise.
14467 * include/grub/i386/pc/vbeblit.h: Likewise.
14468 * include/grub/i386/pc/vbefill.h: Likewise.
14469 * include/grub/i386/pc/vbeutil.h: Likewise.
14470 * include/grub/i386/pc/vga.h: Likewise.
14471 * include/grub/ieee1275/ieee1275.h: Likewise.
14472 * include/grub/ieee1275/ofdisk.h: Likewise.
14473 * include/grub/powerpc/libgcc.h: Likewise.
14474 * include/grub/powerpc/setjmp.h: Likewise.
14475 * include/grub/powerpc/types.h: Likewise.
14476 * include/grub/powerpc/ieee1275/biosdisk.h: Likewise.
14477 * include/grub/powerpc/ieee1275/console.h: Likewise.
14478 * include/grub/powerpc/ieee1275/ieee1275.h: Likewise.
14479 * include/grub/powerpc/ieee1275/kernel.h: Likewise.
14480 * include/grub/powerpc/ieee1275/loader.h: Likewise.
14481 * include/grub/powerpc/ieee1275/multiboot.h: Likewise.
14482 * include/grub/powerpc/ieee1275/time.h: Likewise.
14483 * include/grub/powerpc/ieee1275/util/biosdisk.h: Likewise.
14484 * include/grub/sparc64/libgcc.h: Likewise.
14485 * include/grub/sparc64/setjmp.h: Likewise.
14486 * include/grub/sparc64/types.h: Likewise.
14487 * include/grub/sparc64/ieee1275/console.h: Likewise.
14488 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
14489 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
14490 * include/grub/sparc64/ieee1275/time.h: Likewise.
14491 * include/grub/util/biosdisk.h: Likewise.
14492 * include/grub/util/getroot.h: Likewise.
14493 * include/grub/util/lvm.h: Likewise.
14494 * include/grub/util/misc.h: Likewise.
14495 * include/grub/util/raid.h: Likewise.
14496 * include/grub/util/resolve.h: Likewise.
14497 * io/gzio.c: Likewise.
14498 * kern/device.c: Likewise.
14499 * kern/disk.c: Likewise.
14500 * kern/dl.c: Likewise.
14501 * kern/elf.c: Likewise.
14502 * kern/env.c: Likewise.
14503 * kern/err.c: Likewise.
14504 * kern/file.c: Likewise.
14505 * kern/fs.c: Likewise.
14506 * kern/loader.c: Likewise.
14507 * kern/main.c: Likewise.
14508 * kern/misc.c: Likewise.
14509 * kern/mm.c: Likewise.
14510 * kern/parser.c: Likewise.
14511 * kern/partition.c: Likewise.
14512 * kern/rescue.c: Likewise.
14513 * kern/term.c: Likewise.
14514 * kern/efi/efi.c: Likewise.
14515 * kern/efi/init.c: Likewise.
14516 * kern/efi/mm.c: Likewise.
14517 * kern/i386/dl.c: Likewise.
14518 * kern/i386/efi/init.c: Likewise.
14519 * kern/i386/efi/startup.S: Likewise.
14520 * kern/i386/pc/init.c: Likewise.
14521 * kern/i386/pc/lzo1x.S: Likewise.
14522 * kern/i386/pc/startup.S: Likewise.
14523 * kern/ieee1275/ieee1275.c: Likewise.
14524 * kern/powerpc/cache.S: Likewise.
14525 * kern/powerpc/dl.c: Likewise.
14526 * kern/powerpc/ieee1275/cmain.c: Likewise.
14527 * kern/powerpc/ieee1275/crt0.S: Likewise.
14528 * kern/powerpc/ieee1275/init.c: Likewise.
14529 * kern/powerpc/ieee1275/openfw.c: Likewise.
14530 * kern/sparc64/cache.S: Likewise.
14531 * kern/sparc64/dl.c: Likewise.
14532 * kern/sparc64/ieee1275/init.c: Likewise.
14533 * kern/sparc64/ieee1275/openfw.c: Likewise.
14534 * loader/efi/chainloader.c: Likewise.
14535 * loader/efi/chainloader_normal.c: Likewise.
14536 * loader/i386/efi/linux.c: Likewise.
14537 * loader/i386/efi/linux_normal.c: Likewise.
14538 * loader/i386/pc/chainloader.c: Likewise.
14539 * loader/i386/pc/chainloader_normal.c: Likewise.
14540 * loader/i386/pc/linux.c: Likewise.
14541 * loader/i386/pc/linux_normal.c: Likewise.
14542 * loader/i386/pc/multiboot.c: Likewise.
14543 * loader/i386/pc/multiboot_normal.c: Likewise.
14544 * loader/powerpc/ieee1275/linux.c: Likewise.
14545 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
14546 * normal/arg.c: Likewise.
14547 * normal/cmdline.c: Likewise.
14548 * normal/command.c: Likewise.
14549 * normal/completion.c: Likewise.
14550 * normal/execute.c: Likewise.
14551 * normal/function.c: Likewise.
14552 * normal/lexer.c: Likewise.
14553 * normal/main.c: Likewise.
14554 * normal/menu.c: Likewise.
14555 * normal/menu_entry.c: Likewise.
14556 * normal/misc.c: Likewise.
14557 * normal/parser.y: Likewise.
14558 * normal/script.c: Likewise.
14559 * normal/i386/setjmp.S: Likewise.
14560 * normal/powerpc/setjmp.S: Likewise.
14561 * normal/sparc64/setjmp.S: Likewise.
14562 * partmap/acorn.c: Likewise.
14563 * partmap/amiga.c: Likewise.
14564 * partmap/apple.c: Likewise.
14565 * partmap/gpt.c: Likewise.
14566 * partmap/pc.c: Likewise.
14567 * partmap/sun.c: Likewise.
14568 * term/gfxterm.c: Likewise.
14569 * term/terminfo.c: Likewise.
14570 * term/efi/console.c: Likewise.
14571 * term/i386/pc/console.c: Likewise.
14572 * term/i386/pc/serial.c: Likewise.
14573 * term/i386/pc/vesafb.c: Likewise.
14574 * term/i386/pc/vga.c: Likewise.
14575 * term/ieee1275/ofconsole.c: Likewise.
14576 * util/biosdisk.c: Likewise.
14577 * util/console.c: Likewise.
14578 * util/genmoddep.c: Likewise.
14579 * util/getroot.c: Likewise.
14580 * util/grub-emu.c: Likewise.
14581 * util/grub-mkdevicemap.c: Likewise.
14582 * util/grub-probe.c: Likewise.
14583 * util/lvm.c: Likewise.
14584 * util/misc.c: Likewise.
14585 * util/raid.c: Likewise.
14586 * util/resolve.c: Likewise.
14587 * util/update-grub.in: Likewise.
14588 * util/update-grub_lib.in: Likewise.
14589 * util/grub.d/00_header.in: Likewise.
14590 * util/grub.d/10_hurd.in: Likewise.
14591 * util/grub.d/10_linux.in: Likewise.
14592 * util/i386/efi/grub-install.in: Likewise.
14593 * util/i386/efi/grub-mkimage.c: Likewise.
14594 * util/i386/pc/grub-install.in: Likewise.
14595 * util/i386/pc/grub-mkimage.c: Likewise.
14596 * util/i386/pc/grub-mkrescue.in: Likewise.
14597 * util/i386/pc/grub-setup.c: Likewise.
14598 * util/i386/pc/misc.c: Likewise.
14599 * util/powerpc/ieee1275/grub-install.in: Likewise.
14600 * util/powerpc/ieee1275/grub-mkimage.c: Likewise.
14601 * util/powerpc/ieee1275/misc.c: Likewise.
14602 * video/bitmap.c: Likewise.
14603 * video/video.c: Likewise.
14604 * video/i386/pc/vbe.c: Likewise.
14605 * video/i386/pc/vbeblit.c: Likewise.
14606 * video/i386/pc/vbefill.c: Likewise.
14607 * video/i386/pc/vbeutil.c: Likewise.
14608 * video/readers/tga.c: Likewise.
14609
3572d015 146102007-07-02 Robert Millan <rmh@aybabtu.com>
14611
14612 * conf/i386-efi.rmk: Replace obsolete reference to
14613 util/i386/pc/biosdisk.c with util/biosdisk.c, and util/i386/pc/getroot.c
14614 with util/getroot.c.
14615 * conf/powerpc-ieee1275.rmk: Likewise.
14616 * conf/sparc64-ieee1275.rmk: Likewise.
14617
14618 * util/grub-emu.c (main): Fix unchecked pointer handling.
14619
2c2a681b 146202007-07-02 Robert Millan <rmh@aybabtu.com>
14621
14622 * util/i386/efi/grub-install.in: Allow `grub_probe --target=partmap'
14623 invocation to fail, in order to support partition-less media.
14624
14625 * util/i386/pc/grub-install.in: Likewise.
14626
14627 * util/powerpc/ieee1275/grub-install.in: Use grub-probe to determine
14628 which fs or partmap modules are needed (akin to its sister scripts).
14629
14630 Also use grub-probe to get rid of unportable /proc/mounts check.
14631
14632 Print the same informational message that the other scripts do, before
fe6b695a 14633 exiting.
2c2a681b 14634
6193defe 146352007-06-23 Robert Millan <rmh@aybabtu.com>
14636
fe6b695a 14637 * util/update-grub_lib.in (font_path): New function. Determine whether
6193defe 14638 a font file can be found and, if so, echo the GRUB path to it.
14639
14640 * util/update-grub.in: Handle multiple terminals depending on user
14641 input, platform availability and font file presence. Propagate
14642 variables of our findings to /etc/grub.d/ children.
14643
14644 * util/grub.d/00_header.in: Handle multiple terminals, based on
14645 environment setup by update-grub.
14646
eface1dc 146472007-06-23 Robert Millan <rmh@aybabtu.com>
14648
ba50d28f 14649 * conf/i386-pc.rmk (pkgdata_MODULES): Add serial.mod.
eface1dc 14650
bf697e28 146512007-06-21 Robert Millan <rmh@aybabtu.com>
14652
14653 * include/grub/i386/pc/kernel.h: Define GRUB_KERNEL_MACHINE_DATA_END to
14654 indicate end of data section in kernel image.
14655 * include/grub/i386/efi/kernel.h: Define GRUB_KERNEL_MACHINE_PREFIX and
14656 GRUB_KERNEL_MACHINE_DATA_END.
14657
14658 * kern/i386/pc/startup.S: Do not initialize grub_prefix, only reserve
14659 space for it.
14660 * kern/i386/efi/startup.S: Likewise.
14661
14662 * util/i386/pc/grub-mkimage.c: Initialize grub_prefix to /boot/grub
14663 during image generation. Implement --prefix option to override this
14664 patch.
14665 * util/i386/efi/grub-mkimage.c: Likewise.
14666
14667 * util/update-grub_lib.in (convert_system_path_to_grub_path): Split
14668 code to make path relative to its root into a separate function.
14669
14670 * util/i386/pc/grub-install.in: Use newly provided
14671 make_system_path_relative_to_its_root() to convert ${grubdir}, then
14672 pass the result to grub-install --prefix.
14673
baa574b4 146742007-06-13 Robert Millan <rmh@aybabtu.com>
14675
14676 * include/grub/util/misc.h: Define DEFAULT_DIRECTORY and
14677 DEFAULT_DEVICE_MAP.
14678 * util/grub-emu.c: Use above definitions from misc.h instead of
14679 defining them.
14680 * util/grub-mkdevicemap.c: Likewise.
14681 * util/i386/pc/grub-setup.c: Likewise.
14682 * util/grub-probe.c: Likewise.
14683 (probe): Abort with grub_util_error() when either
14684 grub_guess_root_device or grub_util_get_grub_dev fails.
14685
0215dcbf 146862007-06-12 Robert Millan <rmh@aybabtu.com>
14687
14688 * normal/command.c (grub_command_execute): Use NULL rather than 0 for
14689 "pager" assignment.
14690 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Likewise for
14691 "pcdata".
14692 * util/grub-probe.c (probe): Likewise for "drive_name".
14693
8af2ab7b 146942007-06-11 Robert Millan <rmh@aybabtu.com>
14695
14696 * util/i386/pc/grub-mkrescue.in: Pad both floppy images with zeroes,
14697 not just the cdrom one.
14698
59d31694 146992007-06-11 Robert Millan <rmh@aybabtu.com>
14700
14701 * util/i386/pc/grub-mkrescue.in: Add "set -e".
14702 Add --pkglibdir=DIR option to override pkglibdir.
14703 Mention --image-type=TYPE in help output.
14704 Fix --grub-mkimage (it was a no-op).
fe6b695a 14705 Abort gracefully when no parameter is given.
59d31694 14706
7ee367e4 147072007-06-11 Robert Millan <rmh@aybabtu.com>
14708
14709 * util/i386/pc/grub-mkrescue.in: New file.
14710 * conf/i386-pc.rmk: Add its build declarations. Put it in bin_SCRIPTS.
14711 * Makefile.in: Handle bin_SCRIPTS.
14712
29b0ed46 147132007-06-10 Vesa Jaaskelainen <chaac@nic.fi>
14714
14715 * term/gfxterm.c (grub_gfxterm_init): Added support for specifying
14716 list of video modes.
14717
c0f90770 147182007-06-06 Robert Millan <rmh@aybabtu.com>
14719
14720 * util/update-grub_lib.in (convert_system_path_to_grub_path): Abort if
14721 file doesn't exist, or if it is in a filesystem grub can't read.
14722
14723 * util/update-grub.in: Set fallback for GRUB_FS check to "unknown". Do
14724 not abort if GRUB_DRIVE could not be defined. Rearrange generated
14725 header comment to fit in 80 columns when the variables are resolved.
14726
14727 * util/grub.d/00_header.in: Only set root variable when GRUB_DRIVE
14728 could be identified by update-grub. Remove redundant check for
fe6b695a 14729 unifont.pff existence (since convert_system_path_to_grub_path now
c0f90770 14730 handles that).
14731
fb36dc26 147322007-06-04 Robert Millan <rmh@aybabtu.com>
14733
14734 * conf/i386-efi.rmk (grub_probe_SOURCES): Add partmap/apple.c.
14735
14736 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise.
14737
14738 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add partmap/pc.c.
14739
0c68c93e 147402007-06-04 Robert Millan <rmh@aybabtu.com>
14741
14742 * conf/powerpc-ieee1275.rmk: Enable grub-mkdevicemap and grub-probe.
14743
14744 * include/grub/partition.h: Declare grub_apple_partition_map_init and
14745 grub_apple_partition_map_fini.
14746
14747 * util/biosdisk.c
14748 (grub_util_biosdisk_open): Replace BLKGETSIZE with BLKGETSIZE64 (needed
14749 to access >2 TiB disks).
14750
14751 Print disk->total_sectors with %llu instead of %lu, since this
14752 variable is always 64-bit (prevents wrong disk size from being displayed
14753 on either >2 TiB disk or big-endian CPU).
14754
14755 (grub_util_biosdisk_get_grub_dev): Convert gpt_partition_map handling
14756 into a generic case that supports all (sane) partition maps.
14757
14758 Stop using grub_cpu_to_le32() on dos_part / bsd_part since it actually
14759 breaks big-endian.
14760
14761 * util/grub-probe.c: Call grub_apple_partition_map_init() before probe()
14762 and grub_apple_partition_map_fini() after that.
14763
0f23eb74 147642007-06-01 Robert Millan <rmh@aybabtu.com>
14765
14766 * util/update-grub.in: Export GRUB_CMDLINE_LINUX.
14767
14768 * util/grub.d/00_header.in: Only enable gfxterm when
14769 convert_system_path_to_grub_path() succeeds.
14770
42c71976 147712007-05-20 Robert Millan <rmh@aybabtu.com>
14772
14773 * util/update-grub_lib.in: New file.
14774 * DISTLIST: Add update-grub_lib.in.
14775 * conf/common.rmk: Generate update-grub_lib and install it in
14776 $(lib_DATA).
14777 * Makefile.in: Add install routine for $(lib_DATA).
14778
14779 * util/grub.d/00_header.in: Use convert_system_path_to_grub_path()
14780 function provided by update-grub_lib to support arbitrary paths of
14781 unifont.pff.
14782 * util/update-grub.in: Use convert_system_path_to_grub_path() to
14783 initialize GRUB_DRIVE_BOOT and GRUB_DRIVE_BOOT_GRUB variables.
14784
5beb2291 147852007-05-19 Robert Millan <rmh@aybabtu.com>
14786
14787 * commands/i386/cpuid.c: New module.
14788 * DISTLIST: Add it.
14789 * conf/i386-efi.rmk: Enable cpuid.mod.
14790 * conf/i386-pc.rmk: Likewise.
14791
7262eca1 147922007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
14793
14794 * kern/disk.c (grub_disk_read): Check return value of
14795 grub_realloc().
14796
260ba823 147972007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
14798
14799 * util/getroot.c (grub_util_get_grub_dev): Support partitionable
14800 arrays.
14801 * disk/raid.c (grub_raid_open): Likewise.
14802
1ecb6cf2 148032007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
14804
14805 * util/biosdisk.c (linux_find_partition): Allocate real_dev on the
14806 stack instead of on the heap.
14807
14808 * kern/disk.c (grub_disk_read): Make sure tmp_buf is big enough
14809 before doing a read on it.
14810
14811 * configure.ac: Only use -fno-stack-protector for the target
14812 environment.
f19dbdb7 14813
21c8cbb1 148142007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
14815
14816 * video/i386/pc/vbe.c (grub_video_vbe_create_render_target): Add
14817 __attribute_ ((unused)) to mode_type argument.
14818
14819 * util/getroot.c (grub_guess_root_device): Fix #endif.
f19dbdb7 14820
21c8cbb1 14821 * kern/misc.c (memcmp): Fix prototype.
14822
14823 * include/grub/partition.h [GRUB_UTIL]
14824 (grub_gpt_partition_map_init): Add prototype.
14825 (grub_gpt_partition_map_fini): Likewise.
14826
14827 * fs/jfs.c (struct grub_jfs_inode): Put __attribute__ ((packed)
14828 at the right place.
14829
14830 * fs/fat.c (grub_fat_mount): Replace ~0UL with ~0U.
14831 (grub_fat_read_data): Likewise.
14832 (grub_fat_find_dir): Likewise.
14833
14834 * font/manager.c (find_glyph): Make table a const.
14835 (grub_font_get_glyph): Remove bitmap from if statement.
f19dbdb7 14836
849d55d3 148372007-05-16 Jeroen Dekkers <jeroen@dekkers.cx>
14838
14839 * util/getroot.c (grub_guess_root_device): Remove RAID and LVM
14840 code, first search for device in /dev/mapper, then in /dev.
14841 (grub_util_get_grub_dev): New function.
14842 * include/grub/util/getroot.h (grub_util_get_grub_dev): Add
14843 prototype.
14844 * util/grub-probe.c (probe): Remove check for RAID, call
14845 grub_util_get_grub_dev() instead of
14846 grub_util_biosdisk_get_grub_dev().
14847 * util/grub-emu.c (main): Call grub_util_get_grub_dev() instead of
14848 grub_util_biosdisk_get_grub_dev().
14849 * util/i386/pc/grub-setup.c (main): Likewise.
14850
8fff7c2f 148512007-05-16 Robert Millan <rmh@aybabtu.com>
14852
14853 * DISTLIST: Update for the latest changes.
14854 * conf/i386-pc.rmk: Use the new paths for util/getroot.c,
14855 util/grub-mkdevicemap.c, util/grub-probe.c and util/biosdisk.c.
14856 * util/grub-emu.c: Replace grub/i386/pc/util/biosdisk.h with
14857 grub/util/biosdisk.h.
14858 * util/i386/pc/grub-setup.c: Replace grub/machine/util/biosdisk.h with
14859 grub/util/biosdisk.h.
14860
48e12b52 148612007-05-16 Robert Millan <rmh@aybabtu.com>
14862
14863 * util/grub.d/00_header.in: Set default gfxmode to `640x480'.
14864
46b9d128 148652007-05-16 Robert Millan <rmh@aybabtu.com>
14866
14867 * util/i386/efi/grub-install.in: New.
14868 * conf/i386-efi.rmk: Enable grub-mkdevicemap, grub-probe and the
14869 newly added grub-install.
14870 * util/biosdisk.c: Remove unnecessary grub/machine/biosdisk.h
14871 include.
14872 * util/getroot.c: Replace grub/i386/pc/util/biosdisk.h with
14873 grub/util/biosdisk.h.
14874 * util/grub-probe.c: Replace grub/machine/util/biosdisk.h with
14875 grub/util/biosdisk.h.
14876
2d1a40a9 148772007-05-16 Robert Millan <rmh@aybabtu.com>
14878
14879 * include/grub/i386/pc/util/biosdisk.h: Moved to ...
14880 * include/grub/util/biosdisk.h: ... here.
14881 * util/i386/pc/biosdisk.c: Moved to ...
14882 * util/biosdisk.c: ... here.
14883 * util/i386/pc/getroot.c: Moved to ...
14884 * util/getroot.c: ... here.
14885 * util/i386/pc/grub-mkdevicemap.c: Moved to ...
14886 * util/grub-mkdevicemap.c: ... here.
14887 * util/i386/pc/grub-probe.c: Moved to ...
14888 * util/grub-probe.c: ... here.
14889
9e26e3bc 148902007-05-15 Robert Millan <rmh@aybabtu.com>
14891
14892 * util/update-grub.in: Remove duplicated line in grub.cfg header
14893 message.
14894
57f96397 148952007-05-13 Robert Millan <rmh@aybabtu.com>
14896
14897 * util/update-grub.in: Fix a few assumptions about the devices holding
14898 /, /boot and /boot/grub being the same.
14899 * util/grub.d/00_header.in: Likewise.
14900 * util/grub.d/10_hurd.in: Likewise.
14901 * util/grub.d/10_linux.in: Likewise.
14902
14903 * util/grub.d/10_linux.in: Implement Linux image sorting with arbitrary
14904 patterns. Use that to define the `.old' suffix as older than `'.
14905
14906 * util/grub.d/00_header.in: Set default gfxmode to `800x600x16'.
14907
14908 * util/update-grub.in: Add a reference to ${sysconfdir}/default/grub in
14909 the grub.cfg header message.
14910
2e610d62 149112007-05-11 Robert Millan <rmh@aybabtu.com>
14912
14913 * util/update-grub.in: Create device.map if it doesn't already exist,
14914 before attempting to run grub-probe.
14915 Check for grub-probe and grub-mkdevicemap with the same code
14916 grub-install is using.
14917 Remove test mode.
14918
3f6a10ef 149192007-05-09 Jeroen Dekkers <jeroen@dekkers.cx>
14920
14921 * Makefile.in: Add the datarootdir autoconf variable.
14922
02e7b75e 149232007-05-09 Robert Millan <rmh@aybabtu.com>
14924
14925 * util/i386/pc/grub-probe.c (probe): When detecting partition map,
f19dbdb7 14926 fail gracefully if dev->disk->partition == NULL.
02e7b75e 14927
75f396cc 149282007-05-07 Robert Millan <rmh@aybabtu.com>
14929
14930 * util/i386/pc/grub-probe.c: Add `grub-probe -t partmap' parameter to
14931 determine partition map module.
14932 * util/i386/pc/grub-install.in: Use this feature to decide which
14933 partition module to load, instead of hardcoding pc and gpt.
14934
da65cb36 149352007-05-07 Robert Millan <rmh@aybabtu.com>
14936
14937 * Makefile.in: Fix assumption that $(srcdir) has a trailing slash when
14938 source directory differs from build directory.
14939
b57d6a91 149402007-05-05 Robert Millan <rmh@aybabtu.com>
14941
14942 * util/powerpc/ieee1275/grub-install.in: Fix syntax error in pkglibdir
14943 initialisation.
14944
509d00f1 149452007-05-05 Robert Millan <rmh@aybabtu.com>
14946
14947 * util/update-grub.in: Create ${grub_prefix} if it doesn't exist.
14948
c48f23ef 149492007-05-05 Robert Millan <rmh@aybabtu.com>
14950
14951 * util/grub.d/10_linux.in: Allow the administrator to insert Linux
14952 command-line arguments via ${GRUB_CMDLINE_LINUX}.
14953
20b97658 149542007-05-05 Robert Millan <rmh@aybabtu.com>
14955
14956 * conf/i386-pc.rmk (grub_setup_SOURCES): Add partmap/gpt.c.
14957 (grub_probe_SOURCES): Likewise.
14958 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): Detect
14959 GPT and initialize dos_part and bsd_part accordingly.
14960 * util/i386/pc/grub-setup.c (setup): Ditto for install_dos_part and
14961 install_bsd_part.
14962 (main): Activate gpt module for use during partition identification,
14963 and deactivate it afterwards.
14964 * util/i386/pc/grub-install.in: Add gpt module to core.img.
14965 * util/i386/pc/grub-probe.c (main): Activate gpt module for use during
14966 partition identification, and deactivate it afterwards.
14967
99123174 149682007-05-05 Robert Millan <rmh@aybabtu.com>
14969
14970 * term/i386/pc/console.c (grub_console_fini): Call
14971 grub_term_set_current() before grub_term_unregister().
14972
ebd97f6e 149732007-05-04 Robert Millan <rmh@aybabtu.com>
14974
14975 * DISTLIST: Add util/update-grub.in, util/grub.d/00_header.in,
14976 util/grub.d/10_hurd.in, util/grub.d/10_linux.in and util/grub.d/README.
14977 * Makefile.in: Build update-grub_SCRIPTS. Install update-grub_SCRIPTS
14978 and update-grub_DATA.
14979 * conf/common.rmk: Build and install update-grub components.
14980 * conf/common.mk: Regenerate.
14981 * util/update-grub.in: New. Core of update-grub.
14982 * util/grub.d/00_header.in: New. Generates grub.cfg header.
14983 * util/grub.d/10_hurd.in: New. Generates boot entries for the Hurd.
14984 * util/grub.d/10_linux.in: New. Generates boot entries for Linux.
14985 * util/grub.d/README: New. Document grub.d directory layout.
14986
b06a264d 149872007-05-01 Robert Millan <rmh@aybabtu.com>
14988
14989 * util/grub-emu.c: Move initialization functions
14990 grub_util_biosdisk_init() and grub_init_all() before
14991 grub_util_biosdisk_get_grub_dev(), which relies on them.
14992
41f0050e 149932007-04-19 Robert Millan <rmh@aybabtu.com>
14994
14995 * util/powerpc/ieee1275/grub-install.in: Initialize ${bindir}, since
14996 it is used later.
14997
04582bb3 149982007-04-18 Jerone Young <jerone@gmail.com>
14999
f19dbdb7 15000 * kernel/elf.c: Add missing parenthesis for conditional statement
04582bb3 15001 stanza.
15002
08db4632 150032007-04-10 Jerone Young <jerone@gmail.com>
49892fdf 15004
08db4632 15005 * util/i386/pc/getroot.c: Update so that if root device is /dev/root ,
15006 continue on and look for device node with real device name.
15007
801b76be 150082007-04-10 Jerone Young <jerone@gmail.com>
f19dbdb7 15009
fe6b695a 15010 * configure.ac: Add argument for autoconf to use transformation
1d543c3e 15011 ability.
15012 * Makefile.in: Add autoconf package transformation code.
15013 * util/i386/pc/grub-install.in: Likewise.
15014 * util/powerpc/ieee1275/grub-install.in: Likewise.
15015
6795c4e1 150162007-03-19 Yoshinori K. Okuji <okuji@enbug.org>
15017
15018 * fs/ext2.c (EXT2_GOOD_OLD_REVISION): New macro.
15019 (EXT2_GOOD_OLD_INODE_SIZE): Likewise.
15020 (EXT2_REVISION): Likewise.
15021 (EXT2_INODE_SIZE): Likewise.
15022 (struct grub_ext2_block_group): Added a missing member
15023 "used_dirs".
15024 (grub_ext2_read_inode): Divide by the inode size in a superblock
15025 instead of 128 to obtain INODES_PER_BLOCK.
15026 Use the macro EXT2_INODE_SIZE instead of directly using
15027 SBLOCK->INODE_SIZE.
15028
d70af616 150292007-03-18 Yoshinori K. Okuji <okuji@enbug.org>
15030
15031 * fs/ext2.c (grub_ext2_read_inode): Use the inode size in a
15032 superblock instead of the structure size to compute an
15033 offset. This fixes the problem that GRUB could not read a
15034 filesystem when inode size is different from 128-byte.
15035
3b801603 150362007-03-05 Marco Gerards <marco@gnu.org>
15037
15038 * normal/main.c (read_config_file): When "menu" is not set, create
15039 an initial context.
15040
4785bfe4 150412007-02-21 Hollis Blanchard <hollis@penguinppc.org>
15042
15043 * kern/powerpc/ieee1275/init.c (HEAP_SIZE): Removed.
15044 (HEAP_LIMIT): New macro.
15045 (grub_claim_heap): Claim memory up to `heaplimit'.
15046
a0cbb023 150472007-02-21 Hollis Blanchard <hollis@penguinppc.org>
15048
15049 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Link at 64KB.
15050 * kern/powerpc/ieee1275/init.c (_end): Add declaration.
15051 (_start): Likewise.
15052 (grub_arch_modules_addr): Return address after `_end'.
15053 * util/powerpc/ieee1275/grub-mkimage.c: Include grub/misc.h.
15054 (load_modules): Use new parameter as `p_paddr' and `p_vaddr'.
15055 (add_segments): Calculate `_end' from phdr size and location.
15056 (ALIGN_UP): Moved to ...
15057 * include/grub/misc.h: here.
15058 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
15059 New macro.
15060 (GRUB_IEEE1275_MODULE_BASE): Removed.
15061
fd7d8eba 150622007-02-20 Hollis Blanchard <hollis@penguinppc.org>
15063
15064 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Correct
15065 loop boundary.
15066
9b09e6fc 150672007-02-20 Hollis Blanchard <hollis@penguinppc.org>
15068
15069 * include/grub/elfload.h (grub_elf32_load_hook_t): Return grub_err_t.
15070 All users updated.
15071 (grub_elf64_load_hook_t): Likewise.
15072 * kern/elf.c: Call `grub_error_push' before `grub_error'. Improve
15073 debug output.
15074
3ce27299 150752007-02-20 Hollis Blanchard <hollis@penguinppc.org>
15076
15077 * kern/mm.c: Update copyright.
15078 (grub_mm_debug): Correct syntax error.
15079 (grub_mm_dump_free): New function.
15080 (grub_debug_free): Call `grub_free'.
15081 * include/grub/mm.h: Update copyright.
15082 (grub_mm_dump_free): Add declaration.
15083
077d5fee 150842007-02-12 Hollis Blanchard <hollis@penguinppc.org>
15085
15086 * include/grub/ieee1275/ieee1275.h: Update copyright.
15087 * kern/powerpc/ieee1275/init.c: Likewise.
15088 * kern/powerpc/ieee1275/openfw.c: Likewise.
15089
15090 * loader/powerpc/ieee1275/linux.c: Likewise.
15091 * include/grub/elfload.h: Likewise.
15092 * kern/elf.c: Likewise.
15093 (grub_elf32_load): Pass `base' and `size' parameters. Update all
15094 callers.
15095 (grub_elf64_load): Likewise.
15096 (grub_elf32_load_segment): Move to a nested function.
15097 (grub_elf64_load_segment): Likewise.
15098
dc946850 150992007-02-12 Hollis Blanchard <hollis@penguinppc.org>
15100
15101 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): New
15102 prototype.
15103 * kern/powerpc/ieee1275/init.c (grub_heap_start): Removed.
15104 (grub_heap_len): Likewise.
15105 (HEAP_SIZE): New macro.
15106 (grub_claim_heap): New function.
15107 (grub_machine_init): Don't claim heap directly. Call
15108 `grub_claim_heap'.
15109 * kern/powerpc/ieee1275/openfw.c: Include alloca.h.
15110 (grub_available_iterate): New function.
15111
baa2a121 151122007-02-03 Thomas Schwinge <tschwinge@gnu.org>
15113
15114 * aclocal.m4 (grub_CHECK_STACK_PROTECTOR): New definition.
15115 * configure.ac: Use it for testing the HOST and TARGET compilers.
15116
4fe9862e 151172006-12-13 Thomas Schwinge <tschwinge@gnu.org>
15118
15119 * Makefile.in (enable_grub_emu): New variable.
15120 * configure.ac (--enable-grub-emu): New option.
15121 Do the checks for (n)curses only if `--enable-grub-emu' is requested.
15122 * conf/i386-efi.rmk (sbin_UTILITIES): Add `grub-emu' only if requested.
15123 * conf/i386-pc.rmk: Likewise.
15124 * conf/powerpc-ieee1275.rmk: Likewise.
15125 * conf/sparc64-ieee1275.rmk (bin_UTILITIES): Likewise.
15126
a8aa5762 151272006-12-12 Marco Gerards <marco@gnu.org>
15128
15129 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_MENU'.
15130
15131 * kern/env.c (grub_env_unset): Don't free the member `value' when
15132 the type is GRUB_ENV_VAR_DATA, in this case it's a user defined
15133 pointer.
15134
15135 * normal/main.c (current_menu): Removed.
15136 (free_menu): Unset the `menu' environment variable.
15137 (grub_normal_menu_addentry): Make use of the environment variable
15138 `menu', instead of using the global `current_menu'. Allocate
15139 memory for the sourcecode of this entry.
15140 (read_config_file): New argument `nested', changed all callers.
15141 Only in the case of a new context, initialize a new menu. Set the
15142 `menu' environment variable.
15143 (grub_normal_execute): Don't set and unset the environment
15144 variable `menu' here anymore. Only free the menu when leaving the
15145 context.
15146
15147 * util/i386/pc/biosdisk.c (linux_find_partition): Fixed a memory
15148 leak.
15149
957b3a3e 151502006-12-11 Marco Gerards <marco@gnu.org>
15151
15152 * normal/menu_entry.c (run): Fix off by one bug so the last line
15153 is executed. Move the loader check to outside the loop.
15154
ef875714 151552006-12-08 Hollis Blanchard <hollis@penguinppc.org>
15156
15157 * kern/powerpc/ieee1275/cmain.c (cmain): Mark r3 and r4 as `UNUSED'.
15158
4e739985 151592006-11-25 Yoshinori K. Okuji <okuji@enbug.org>
15160
15161 * util/i386/pc/grub-mkimage.c (generate_image): Fix the offset of
15162 the number of sectors. Reported by Andrey Shuvikov
15163 <mr_hyro@yahoo.com>.
f19dbdb7 15164
790707f2 151652006-11-11 Jeroen Dekkers <jeroen@dekkers.cx>
15166
15167 * kern/disk.c (grub_disk_read): When there is a read error, always
15168 try to read only the necessary data.
f19dbdb7 15169
790707f2 15170 * conf/i386-pc.rmk (grub_probe_SOURCES): Add disk/lvm.c and
15171 disk/raid.c.
15172 * include/grub/disk.h [GRUB_UTIL] (grub_raid_init): New
15173 prototype.
15174 [GRUB_UTIL] (grub_raid_fini): Likewise.
15175 [GRUB_UTIL] (grub_lvm_init): Likewise.
f19dbdb7 15176 [GRUB_UTIL] (grub_lvm_fini): Likewise.
790707f2 15177 * util/i386/pc/grub-probe.c (probe): Check whether DEVICE_NAME is
15178 RAID device and copy DEVICE_NAME to DRIVE_NAME in that case.
15179 (main): Call grub_raid_init(), grub_lvm_init(), grub_lvm_fini()
15180 and grub_raid_fini().
f19dbdb7 15181
03e58196 151822006-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
15183
15184 * include/grub/types.h (__unused): Rename to UNUSED.
15185 * kern/elf.c (grub_elf32_size): Use UNUSED instead of __unused.
15186 (grub_elf64_size): Likewise.
f19dbdb7 15187
ae4f23bf 151882006-11-03 Hollis Blanchard <hollis@penguinppc.org>
15189
15190 * kern/elf.c (grub_elf_file): Call grub_file_seek. Call
15191 grub_error_push and grub_error_pop in the error-handling path.
15192 (grub_elf32_load_segment): Only call grub_file_read with non-zero
15193 length.
15194
2166cc83 151952006-11-03 Hollis Blanchard <hollis@penguinppc.org>
15196
15197 * conf/i386-efi.rmk (grub_emu_SOURCES): Add kern/elf.c.
15198 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
15199 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
15200 (kernel_elf_SOURCES): Likewise.
15201 * conf/i386-efi.rmk (kernel_mod_HEADERS): Add elfload.h and cache.h.
15202 * conf/i386-pc.rmk (kernel_mod_HEADERS): Likewise.
15203 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
15204 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
15205 * conf/common.rmk (pkgdata_MODULES): Add elf.mod.
15206 (elf_mod_SOURCES): New variable.
15207 (elf_mod_CFLAGS): Likewise.
15208 (elf_mod_LDFLAGS): Likewise.
15209 * include/grub/types.h (__unused): New macro.
15210 * include/grub/elfload.h: New file.
15211 * kern/elf.c: Likewise.
15212 * loader/powerpc/ieee1275/linux.c: Include elfload.h.
15213 (ELF32_LOADMASK): New macro.
15214 (ELF64_LOADMASK): Likewise.
15215 (vmlinux): Removed.
15216 (grub_linux_load32): New function.
15217 (grub_linux_load64): Likewise.
15218 (grub_rescue_cmd_linux): Call grub_linux_load32 or grub_linux_load64.
15219 Use grub_elf_t instead of grub_file_t.
15220
a09d5aa5 152212006-11-02 Hollis Blanchard <hollis@penguinppc.org>
15222
15223 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): Add
15224 `catch_result' to struct set_color_args.
15225
d976fc51 152262006-10-28 Yoshinori K. Okuji <okuji@enbug.org>
15227
15228 * normal/menu.c: Include grub/script.h.
15229 * normal/menu_entry.c: Likewise.
15230 * include/grub/normal.h: Do not include grub/script.h.
15231
67507549 152322006-10-27 Hollis Blanchard <hollis@penguinppc.org>
15233
15234 * kern/disk.c (grub_disk_read): Correct debug printf formatting.
15235
69203a99 152362006-10-27 Hollis Blanchard <hollis@penguinppc.org>
15237
15238 * kern/disk.c (grub_disk_open): Print debug messages when opening a
15239 disk.
15240 (grub_disk_close): Print debug messages when closing a disk.
15241 (grub_disk_read): Print debug messages when disk read fails.
15242 * kern/fs.c (grub_fs_probe): Print debug messages when detecting
15243 filesystem type.
15244 * kern/partition.c: Include misc.h.
15245 (grub_partition_iterate): Print debug messages when detecting
15246 partition type.
15247
e2b8278c 152482006-10-27 Hollis Blanchard <hollis@penguinppc.org>
15249
15250 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Return error if `status'
15251 is negative.
15252 * kern/ieee1275/ieee1275.c (IEEE1275_IHANDLE_INVALID): Change to 0.
15253
97b2f2ff 152542006-10-26 Hollis Blanchard <hollis@penguinppc.org>
15255
15256 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
15257 Reverse GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS test.
15258
6555d655 152592006-10-25 Jeroen Dekkers <jeroen@dekkers.cx>
15260
15261 * disk/lvm.c (grub_lvm_scan_device): Malloc sizeof(*lv) bytes
15262 instead of sizeof(lv). Patch by Michael Guntsche.
15263
4d42b77f 152642006-10-18 Jeroen Dekkers <jeroen@dekkers.cx>
15265
15266 * disk/lvm.c: Rename VGS to VG_LIST.
15267 (grub_lvm_iterate): Change VGS->LV to VG-LV.
15268 (grub_lvm_open): Likewise.
15269 Thanks to Michael Guntsche for finding this bug.
15270
5d74d927 152712006-10-15 Yoshinori K. Okuji <okuji@enbug.org>
15272
15273 * configure.ac (AC_INIT): Bumped to 1.95.
15274
a1bb27e4 152752006-10-14 Robert Millan <rmh@aybabtu.com>
15276
15277 * util/i386/pc/getroot.c (grub_guess_root_device): Don't compare os_dev
15278 with "/dev/.static/dev/md".
15279
e0994b8b 152802006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
15281
15282 * util/i386/pc/grub-probe.c (probe): Print DEVICE_NAME instead of
15283 DRIVE_NAME when grub_util_biosdisk_get_grub_dev fails. Open
15284 DRIVE_NAME instead of DEVICE_NAME. Make sure that DEVICE_NAME and
15285 DRIVE_NAME are always freed.
15286
15287 * util/i386/pc/biosdisk.c (make_device_name): Add one into
15288 DOS_PART, as a DOS partition is counted from one instead of zero
15289 now. Reported by Robert Millan.
15290
ddd5cee9 152912006-10-14 Robert Millan <rmh@aybabtu.com>
15292
15293 * util/i386/pc/getroot.c (grub_guess_root_device): Stop using
15294 grub_util_biosdisk_get_grub_dev to convert system device to GRUB device.
15295 * util/grub-emu.c (main): Use grub_util_biosdisk_get_grub_dev with the
15296 string returned by grub_guess_root_device.
15297 * util/i386/pc/grub-setup.c: Likewise.
15298 * util/i386/pc/grub-probefs.c: Likewise.
15299
15300 * util/i386/pc/grub-probefs.c: Rename to ...
15301 * util/i386/pc/grub-probe.c: ... this.
15302 * DISTLIST: Remove grub-probefs, add grub-probe.
15303 * conf/i386-efi.rmk: Likewise.
15304 * conf/i386-pc.rmk: Likewise.
15305 * util/i386/pc/grub-install.in: Likewise.
15306
15307 * util/i386/pc/grub-probe.c: Add --target=(fs|device|drive) option to
15308 choose which information we want to print.
15309
2b002173 153102006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
15311
15312 * DISTLIST: Added commands/echo.c, disk/lvm.c, disk/raid.c,
15313 include/grub/bitmap.h, include/grub/lvm.h, include/grub/raid.h,
15314 include/grub/i386/pc/vbeutil.h, include/grub/util/lvm.h,
15315 include/grub/util/raid.h, util/lvm.c, util/raid.c, video/bitmap.c,
15316 video/readers/tga.c and video/i386/pc/vbeutil.c.
15317
153182006-10-14 Jeroen Dekkers <jeroen@dekkers.cx>
15319
15320 Added support for RAID and LVM.
f19dbdb7 15321
2b002173 15322 * disk/lvm.c: New file.
15323 * disk/raid.c: Likewise.
15324 * include/grub/lvm.h: Likewise.
f19dbdb7 15325 * include/grub/raid.h: Likewise.
2b002173 15326 * include/grub/util/lvm.h: Likewise.
15327 * include/grub/util/raid.h: Likewise.
15328 * util/lvm.c: Likewise.
15329 * util/raid.c: Likewise.
15330
15331 * include/grub/disk.h (grub_disk_dev_id): Add
15332 GRUB_DISK_DEVICE_RAID_ID and GRUB_DISK_DEVICE_LVM_ID.
15333 (grub_disk_get_size): New prototype.
15334 * kern/disk.c (grub_disk_open): Check whether grub_partition_probe()
15335 returns a partition.
15336 (grub_disk_get_size): New function.
f19dbdb7 15337
2b002173 15338 * kern/i386/pc/init.c (make_install_device): Copy the prefix
15339 verbatim if grub_install_dos_part is -2.
15340
15341 * util/i386/pc/getroot.c (grub_guess_root_device): Support RAID
15342 and LVM devices.
15343
15344 * util/i386/pc/grub-setup.c (setup): New argument
15345 MUST_EMBED. Force embedding of GRUB when the argument is
15346 true. Close FILE before returning.
15347 (main): Add support for RAID and LVM.
f19dbdb7 15348
2b002173 15349 * conf/common.rmk: Add RAID and LVM modules.
15350 * conf/i386-pc.rmk (grub_setup_SOURCES): Add util/raid.c and
15351 util/lvm.c.
15352 (grub_emu_SOURCES): Add disk/raid.c and disk/lvm.c.
15353
15354 * kern/misc.c (grub_strstr): New function.
15355 * include/grub/misc.h (grub_strstr): New prototype.
15356
050548d0 153572006-10-10 Tristan Gingold <tristan.gingold@bull.net>
15358
15359 * include/grub/efi/api.h (GRUB_EFI_ERROR_CODE): Long constant.
15360
da849d2d 153612006-10-05 Tristan Gingold <tristan.gingold@bull.net>
15362
15363 * kern/misc.c (grub_strtoull): Guess the base only if not
15364 specified.
15365
97b2f2ff 153662006-10-01 Hollis Blanchard <hollis@penguinppc.org>
4f0acd39 15367
15368 * kern/powerpc/ieee1275/cmain.c (cmain): Remove incomplete Old World
15369 PowerMac support.
15370
97b2f2ff 153712006-10-01 Hollis Blanchard <hollis@penguinppc.org>
fba51f48 15372
15373 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Cast `size' to long.
15374
15375 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_next_property):
15376 Remove `flags' argument. All callers changed.
15377 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_ROOT): Removed.
15378 (IEEE1275_IHANDLE_INVALID): New variable.
15379 (IEEE1275_CELL_INVALID): New variable.
15380 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
15381 grub_ieee1275_get_property_length, grub_ieee1275_instance_to_package,
15382 grub_ieee1275_package_to_path, grub_ieee1275_instance_to_path,
15383 grub_ieee1275_peer, grub_ieee1275_child, grub_ieee1275_open,
15384 grub_ieee1275_claim, grub_ieee1275_set_property): Error-check return
15385 codes from Open Firmware. All callers updated.
15386 (grub_ieee1275_next_property): Directly return Open Firmware return
15387 code.
15388 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
15389 Standardize error checking from `grub_ieee1275_get_property'.
15390 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Rename
15391 `devalias' to `aliases'. Correct comments. Consolidate error paths.
15392
97b2f2ff 153932006-10-01 Hollis Blanchard <hollis@penguinppc.org>
cc6d3df3 15394
15395 * kern/ieee1275/ieee1275.c (grub_ieee1275_instance_to_path): Rename
15396 `instance_to_package_args' to `instance_to_path_args'.
15397
15398 * kern/powerpc/ieee1275/init.c (grub_machine_init): Use
15399 `grub_ieee1275_chosen'.
15400
15401 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Call
15402 `grub_ieee1275_interpret'.
15403
97b2f2ff 154042006-09-25 Hollis Blanchard <hollis@penguinppc.org>
02bb8acc 15405
15406 * util/powerpc/ieee1275/grub-mkimage.c: Include config.h.
15407
97b2f2ff 154082006-09-25 Hollis Blanchard <hollis@penguinppc.org>
663b72f0 15409
15410 * include/grub/powerpc/libgcc.h (__floatdisf): New prototype.
15411 (__cmpdi): Likewise.
15412
15413 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Pass 0 as
15414 `flags' to `grub_ieee1275_next_property'. Change `pathlen' to type
15415 `grub_ssize_t'.
15416
02bb8acc 15417 * kern/powerpc/ieee1275/cmain.c: Include grub/misc.h.
663b72f0 15418
15419 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Change `actual'
15420 to type `grub_ssize_t'.
15421 (grub_rescue_cmd_linux): Cast -1 to `grub_off_t'.
15422
7f9a8531 154232006-09-22 Marco Gerards <marco@gnu.org>
15424
15425 * normal/script.c (grub_script_create_cmdmenu): Skip leading
15426 newlines.
15427
b5ef1102 154282006-09-22 Marco Gerards <marco@gnu.org>
15429
15430 * commands/echo.c: New file.
15431
15432 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/echo.c'.
15433
15434 * conf/common.rmk (echo_mod_SOURCES): New variable.
15435 (echo_mod_CFLAGS): Likewise.
15436 (echo_mod_LDFLAGS): Likewise.
15437
2cff3677 154382006-09-22 Marco Gerards <marco@gnu.org>
15439
15440 * normal/main.c (get_line): Malloc memory instead of using
15441 preallocated memory. Removed the arguments `cmdline' and
15442 `max_len'. Updated all callers.
15443
6ba4688b 154442006-09-22 Marco Gerards <marco@gnu.org>
15445
15446 * conf/i386-efi.rmk (grub_emu_DEPENDENCIES): New variable.
15447 (normal_mod_DEPENDENCIES): Likewise.
15448
15449 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Likewise.
15450 (normal_mod_DEPENDENCIES): Likewise.
15451
15452 * conf/sparc64-ieee1275.rmk (normal_mod_DEPENDENCIES): Likewise.
15453
e02ac02c 154542006-09-22 Johan Rydberg <jrydberg@gnu.org>
15455
15456 * genmk.rb: Add DEPENDENCIES variables to modules, utilities, and
15457 programs.
15458 * conf/i386-pc.rmk (grub_emu_DEPENDENCIES): Declare.
15459 (normal_mod_DEPENDENCIES): Likewise.
15460 * conf/i386-pc.mk: Regenerate.
15461 * conf/i386-efi.mk: Likewise
15462 * conf/common.mk: Likewise.
15463 * conf/powerpc-ieee1275.mk: Likewise.
15464 * conf/sparc64-ieee1275.mk: Likewise.
f19dbdb7 15465
8d252e44 154662006-09-22 Robert Millan <rmh@aybabtu.com>
15467
15468 Sync with i386 version.
15469 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Remove grub-emu, add grub-mkimage.
15470 * conf/powerpc-ieee1275.rmk (sbin_UTILITIES): Remove grub-mkimage, add grub-emu.
15471
209bf7ac 154722006-09-21 Robert Millan <rmh@aybabtu.com>
15473
15474 Import from GRUB Legacy (lib/device.c):
15475 * util/i386/pc/grub-mkdevicemap.c (get_i2o_disk_name): New function.
15476 (init_device_map) [__linux__]: Add support for I2O devices.
15477
6b146090 154782006-09-14 Marco Gerards <marco@gnu.org>
15479
15480 * conf/i386-pc.rmk (COMMON_LDFLAGS): Use `-m32' instead of
15481 `-melf_i386'.
15482
e38600a8 154832006-09-14 Robert Millan <rmh@aybabtu.com>
2952da5d 15484
15485 * util/i386/pc/grub-install.in: Skip menu.lst when removing
15486 /boot/grub/*.lst.
78fa1790 15487
2952da5d 15488 * util/i386/pc/getroot.c: Don't recurse into dotdirs (e.g. ".static").
6b146090 15489
2952da5d 15490 * util/i386/pc/grub-mkdevicemap.c: Make sure the floppy device exists
15491 before adding it to device.map.
15492
01b82a64 154932006-08-15 Johan Rydberg <jrydberg@gnu.org>
15494
fe6b695a 15495 * genmk.rb: Let GCC generate dependencies the first time it
01b82a64 15496 compiles a file; using the -MD option.
15497 * conf/common.mk: Regenerate.
15498 * conf/i386-pc.mk: Likewise.
15499 * conf/i386-efi.mk: Likewise.
15500 * conf/powerpc-ieee1275.mk: Likewise.
15501 * conf/sparc64-ieee1275.mk: Likewise.
f19dbdb7 15502
1064790d 155032006-08-04 Yoshinori K. Okuji <okuji@enbug.org>
15504
15505 Move the prototypes of grub_setjmp and grub_longjmp to
15506 cpu/setjmp.h, so that each architecture may specify different
15507 attributes.
f19dbdb7 15508
1064790d 15509 * include/grub/i386/setjmp.h (grub_setjmp): New prototype.
15510 (grub_longjmp): Likewise.
15511 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise..
15512 (grub_longjmp): Likewise.
15513 * include/grub/sparc64/setjmp.h (grub_setjmp): Likewise..
15514 (grub_longjmp): Likewise.
15515
15516 * include/grub/setjmp.h [!GRUB_UTIL] (grub_setjmp): Removed.
15517 [!GRUB_UTIL] (grub_longjmp): Removed.
15518
29dda3ed 155192006-08-01 Pelletier Vincent <subdino2004@yahoo.fr>
15520
15521 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): IEEE1275
15522 "color!" method does not return any value.
15523
ad2a06ed 155242006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
15525
15526 * include/grub/bitmap.h: New file.
15527
15528 * include/grub/i386/pc/vbeutil.h: Likewise.
15529
15530 * video/bitmap.c: Likewise.
15531
15532 * video/readers/tga.c: Likewise.
15533
15534 * video/i386/pc/vbeutil.c: Likewise.
15535
15536 * commands/videotest.c: Code cleanup and updated to reflect to new
15537 video API.
15538
15539 * term/gfxterm.c: Likewise.
15540
15541 * video/video.c: Likewise.
15542
15543 * conf/i386-pc.rmk (pkgdata_MODULES): Added tga.mod and bitmap.mod.
15544 (vbe_mod_SOURCES): Added video/i386/pc/vbeutil.c.
15545 (bitmap_mod_SOURCES): New entry.
15546 (bitmap_mod_CFLAGS): Likewise.
15547 (bitmap_mod_LDFLAGS): Likewise.
15548 (tga_mod_SOURCES): Likewise.
15549 (tga_mod_CFLAGS): Likewise.
15550 (tga_mod_LDFLAGS): Likewise.
15551
15552 * include/grub/video.h (grub_video_blit_operators): New enum type.
15553 (grub_video_render_target): Changed as forward declaration and moved
15554 actual definition to be video driver specific.
15555 (grub_video_adapter.blit_bitmap): Added blitting operator.
15556 (grub_video_adapter.blit_render_target): Likewise.
15557 (grub_video_blit_bitmap): Likewise.
15558 (grub_video_blit_render_target): Likewise.
15559
15560 * include/grub/i386/pc/vbe.h (grub_video_render_target): Added
15561 driver specific render target definition.
15562 (grub_video_vbe_map_rgba): Added driver internal helper.
15563 (grub_video_vbe_unmap_color): Updated to use
15564 grub_video_i386_vbeblit_info.
15565 (grub_video_vbe_get_video_ptr): Likewise.
15566
15567 * include/grub/i386/pc/vbeblit.h
15568 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8): Updated to use
15569 grub_video_i386_vbeblit_info.
15570 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
15571 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
15572 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
15573 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
15574 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
15575 (grub_video_i386_vbeblit_index_index): Likewise.
15576 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): New blitter function.
15577 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
15578 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
15579 (grub_video_i386_vbeblit_blend): Added generic blitter for blend
15580 operator.
15581 (grub_video_i386_vbeblit_replace): Added generic blitter for replace
15582 operator.
15583
15584 * video/i386/pc/vbeblit.c: Updated to reflect changes on
15585 include/grub/i386/pc/vbeblit.h.
15586
15587 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8):
15588 Updated to use grub_video_i386_vbeblit_info.
15589 (grub_video_i386_vbefill_R8G8B8): Likewise.
15590 (grub_video_i386_vbefill_index): Likewise.
15591 (grub_video_i386_vbefill): Added generic filler.
15592
15593 * video/i386/pc/vbefill.c: Updated to reflect changes on
15594 include/grub/i386/pc/vbefill.h.
15595
15596 * video/i386/pc/vbe.c (grub_video_vbe_get_video_ptr): Updated to use
15597 grub_video_i386_vbeblit_info.
15598 (grub_video_vbe_unmap_color): Likewise.
15599 (grub_video_vbe_blit_glyph): Likewise.
15600 (grub_video_vbe_scroll): Likewise.
15601 (grub_video_vbe_draw_pixel): Removed function.
15602 (grub_video_vbe_get_pixel): Likewise.
15603 (grub_video_vbe_fill_rect): Moved all blitters to vbefill.c and
15604 updated code to use it.
15605 (common_blitter): Added common blitter for render target and bitmap.
15606 (grub_video_vbe_blit_bitmap): Updated to use common_blitter.
15607 (grub_video_vbe_blit_render_target): Likewise.
15608
bc8c036d 156092006-07-30 Johan Rydberg <jrydberg@gnu.org>
15610
15611 * kern/efi/efi.c (grub_efi_set_text_mode): Assume console already
15612 is in text mode if there is no console control protocol instance
15613 available.
15614
684a8eff 156152006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
15616
15617 * include/grub/video.h: Code cleanup.
15618
15619 * include/grub/i386/pc/vbe.h: Likewise.
15620
15621 * video/i386/pc/vbe.c: Likewise.
15622
15623 * video/i386/pc/vbeblit.c: Likewise.
15624
15625 * video/i386/pc/vbefill.c: Likewise.
15626
15627 * video/video.c: Likewise. Also added more comments.
15628
5915059b 156292006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
15630
15631 * disk/i386/pc/biosdisk.c (struct grub_biosdisk_drp): Moved to ...
15632 (struct grub_biosdisk_dap): Likewise.
15633
15634 * include/grub/i386/pc/biosdisk.h: ... to here. Also corrected
15635 linkage settings for all functions.
15636
90ce5d56 156372006-07-12 Marco Gerards <marco@gnu.org>
15638
15639 * configure.ac (--enable-mm-debug): Fix typo.
15640
15641 * genkernsyms.sh.in: Use proper quoting for `CC'.
15642
43e7f879 156432006-07-02 Jeroen Dekkers <jeroen@dekkers.cx>
15644
15645 * conf/i386-pc.rmk (COMMON_ASFLAGS): Add "-m32".
15646 (normal_mod_ASFLAGS): Remove "-m32".
15647
4889bdec 156482006-06-14 Yoshinori K. Okuji <okuji@enbug.org>
15649
15650 * util/misc.c: Include config.h.
15651 [!HAVE_MEMALIGN]: Do not include malloc.h.
15652 (grub_memalign): Use posix_memalign, if present. Then, use
15653 memalign, if present. Otherwise, emit an error.
15654
15655 * util/grub-emu.c: Do not include malloc.h.
15656
15657 * include/grub/util/misc.h: Include unistd.h. This is required for
15658 FreeBSD, because off_t is defined in unistd.h. Reported by Harley
15659 D. Eades III <hde@foobar-qux.org>.
15660
15661 * configure.ac (AC_GNU_SOURCE): Added.
15662 (AC_CHECK_FUNCS): Check posix_memalign and memalign for the host
15663 type.
15664
fd39d4da 156652006-06-09 Yoshinori K. Okuji <okuji@enbug.org>
15666
15667 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Make sure that
15668 ADDR_MAX does not exceed GRUB_LINUX_INITRD_MAX_ADDRESS.
15669
b786f3b5 156702006-06-07 Jeroen Dekkers <jeroen@dekkers.cx>
15671
15672 * include/grub/types.h (grub_host_addr_t): Rename to
15673 grub_target_addr_t.
15674 (grub_host_off_t): Rename to grub_target_off_t.
15675 (grub_host_size_t): Rename to grub_target_size_t.
15676 (grub_host_ssize_t): Rename to grub_target_ssize_t.
15677 Refer to GRUB_TARGET_SIZEOF_VOID_P to define those variables.
15678
15679 * include/grub/kernel.h (struct grub_module_header): Change type
15680 of OFFSET to grub_target_off_t and type of SIZE to grub_target_size_t.
15681 (grub_module_info): Likewise.
f19dbdb7 15682
051988bb 156832006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
15684
15685 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): The conditional
15686 of checking LINUX_MEM_SIZE was reverse. Reported by Jesus
15687 Velazquez <jesus.velazquez@gmail.com>.
15688
deae281b 156892006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
15690
15691 Count partitions from 1 instead of 0 in the string representation
15692 of partitions. Still use 0-based internally.
f19dbdb7 15693
deae281b 15694 * partmap/sun.c (grub_sun_is_valid): A cosmetic change.
15695 (sun_partition_map_iterate): Use grub_partition_t instead of
15696 struct grub_partition *. Cast DESC->START_CYLINDER to
15697 grub_uint64_t after converting the endian.
15698 (sun_partition_map_probe): Subtract 1 for PARTNUM.
15699 (sun_partition_map_get_name): Add 1 to P->INDEX.
15700
15701 * partmap/pc.c (grub_partition_parse): Subtract 1 for
15702 PCDATA->DOS_PART.
15703 (pc_partition_map_get_name): Add 1 into PCDATA->DOS_PART.
15704
15705 * partmap/gpt.c (gpt_partition_map_iterate): Initialize PARTNO to
15706 zero instead of one.
15707 (gpt_partition_map_probe): Subtract 1 for PARTNUM.
15708 (gpt_partition_map_get_name): Add 1 into P->INDEX.
15709
15710 * partmap/apple.c (apple_partition_map_iterate): Change the type
15711 of POS to unsigned.
15712 (apple_partition_map_probe): Subtract 1 for PARTNUM.
15713 (apple_partition_map_get_name): Add 1 into P->INDEX.
15714
15715 * partmap/amiga.c (amiga_partition_map_iterate): Change the type
15716 of POS to unsigned.
15717 (amiga_partition_map_iterate): Cast NEXT to grub_off_t to
15718 calculate the offset of a partition.
15719 (amiga_partition_map_probe): Subtract 1 for PARTNUM.
15720 (amiga_partition_map_get_name): Add 1 into P->INDEX.
15721
15722 * partmap/acorn.c (acorn_partition_map_find): Change the type of
15723 SECTOR to grub_disk_addr_t.
15724 (acorn_partition_map_iterate): Likewise.
15725 (acorn_partition_map_probe): Subtract 1 for PARTNUM.
15726 Change the type of SECTOR to grub_disk_addr_t. Declare P on the
15727 top.
15728 (acorn_partition_map_get_name): Add 1 into P->INDEX.
15729
15730 * kern/i386/pc/init.c (make_install_device): Add 1 into
15731 GRUB_INSTALL_DOS_PART.
15732
15733 * fs/iso9660.c (grub_iso9660_mount): Fixed a reversed
15734 conditional.
15735
524a1e6a 157362006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
15737
15738 Clean up the code to support 64-bit addressing in disks and
15739 files. This change is not enough for filesystems yet.
f19dbdb7 15740
524a1e6a 15741 * util/i386/pc/grub-setup.c (struct boot_blocklist): Change the
15742 type of "start" to grub_uint64_t.
15743 (setup): Change the types of KERNEL_SECTOR and FIRST_SECTOR to
15744 grub_disk_addr_t * and grub_disk_addr_t. Fix the format string in
15745 save_first_sector and save_blocklists. Use grub_le_to_cpu64 to
15746 convert addresses.
15747
15748 * util/i386/pc/biosdisk.c (open_device): Change the type of SECTOR
15749 to grub_disk_addr_t.
15750
15751 * partmap/gpt.c (gpt_partition_map_iterate): Fix the format
15752 string.
15753
15754 * partmap/pc.c (pc_partition_map_iterate): Likewise.
15755
15756 * partmap/amiga.c (amiga_partition_map_iterate): Cast RDSK.MAGIC
15757 to char *.
15758
15759 * normal/script.c (grub_script_parse): Remove unused MEMFREE.
15760
15761 * normal/parser.y (YYLTYPE_IS_TRIVIAL): New macro.
15762
15763 * normal/lexer.c (grub_script_yyerror): Specify unused to LEX.
15764
15765 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf64): Cast -1
15766 to grub_off_t, to detect an error from grub_file_seek.
15767 (grub_multiboot_load_elf32): Likewise.
15768
15769 * kern/misc.c (grub_strtoul): Use grub_strtoull. Return the
15770 maximum unsigned long value when an overflow is detected.
15771 (grub_strtoull): New function.
15772 (grub_divmod64): Likewise.
15773 (grub_lltoa): use grub_divmod64.
15774
15775 * kern/fs.c (struct grub_fs_block): Change the type of "offset" to
15776 grub_disk_addr_t.
15777 (grub_fs_blocklist_open): Increase P if P is not NULL to advance
15778 the pointer to next character. Use grub_strtoull instead of
15779 grub_strtoul.
15780 (grub_fs_blocklist_read): Change the types of SECTOR, OFFSET and
15781 SIZE to grub_disk_addr_t, grub_off_t and grub_size_t,
15782 respectively.
15783
fe6b695a 15784 * kern/file.c (grub_file_read): Prevent an overflow of LEN, as the
524a1e6a 15785 return value is signed.
15786 (grub_file_seek): Change the type of OLD to grub_off_t. Do not
15787 test if OFFSET is less than zero, as OFFSET is unsigned now.
15788
15789 * kern/disk.c (struct grub_disk_cache): Change the type of
15790 "sector" to grub_disk_addr_t.
15791 (grub_disk_cache_get_index): Change the type of SECTOR to
15792 grub_disk_addr_t. Calculate the hash with SECTOR casted to
15793 unsigned after shifting.
15794 (grub_disk_cache_invalidate): Change the type of SECTOR to
15795 grub_disk_addr_t.
15796 (grub_disk_cache_unlock): Likewise.
15797 (grub_disk_cache_store): Likewise.
15798 (grub_disk_check_range): Change the types of SECTOR, OFFSET, SIZE,
15799 START and LEN to grub_disk_addr_t *, grub_off_t *, grub_size_t,
15800 grub_disk_addr_t and grub_uint64_t, respectively.
15801 (grub_disk_read): Use an unsigned variable REAL_OFFSET for the
15802 body, as the value of OFFSET is tweaked by
15803 grub_disk_check_range. Change the types of START_SECTOR, LEN and
15804 POS to grub_disk_addr_t, grub_size_t and grub_size_t,
15805 respectively.
15806 (grub_disk_write): Use an unsigned variable REAL_OFFSET for the
15807 body, as the value of OFFSET is tweaked by
15808 grub_disk_check_range. Change the types of LEN and N to
15809 grub_size_t.
15810
15811 * io/gzio.c (struct grub_gzio): Change the types of "data_offset"
15812 and "saved_offset" to grub_off_t.
15813 (test_header): Cast BUF to char *.
15814 (get_byte): Cast GZIO->DATA_OFFSET to grub_off_t. Cast GZIO->INBUF
15815 to char *.
15816 (grub_gzio_read): Change the types of OFFSET and SIZE to
15817 grub_off_t and grub_size_t, respectively.
15818
15819 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_FORCE_LBA):
15820 Removed.
15821 (GRUB_BOOT_MACHINE_BOOT_DRIVE): Changed to 0x4c.
15822 (GRUB_BOOT_MACHINE_KERNEL_ADDRESS): Changed to 0x40.
15823 (GRUB_BOOT_MACHINE_KERNEL_SEGMENT): Changed to 0x42.
15824 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Changed to 0x4e.
15825 (GRUB_BOOT_MACHINE_LIST_SIZE): Increased to 12.
15826
15827 * include/grub/types.h (grub_off_t): Unconditionally set to
15828 grub_uint64_t.
15829 (grub_disk_addr_t): Changed to grub_uint64_t.
15830
15831 * include/grub/partition.h (struct grub_partition): Change the
15832 types of "start", "len" and "offset" to grub_disk_addr_t,
15833 grub_uint64_t and grub_disk_addr_t, respectively.
15834 (grub_partition_get_start): Return grub_disk_addr_t.
15835 (grub_partition_get_len): Return grub_uint64_t.
15836
15837 * include/grub/misc.h (grub_strtoull): New prototype.
15838 (grub_divmod64): Likewise.
15839
15840 * include/grub/fshelp.h (grub_fshelp_read_file): Change the types
15841 of SECTOR, LEN and FILESIZE to grub_disk_addr_t, grub_size_t and
15842 grub_off_t, respectively.
15843 All callers and references changed.
15844
15845 * include/grub/fs.h (struct grub_fs): Change the type of LEN to
15846 grub_size_t in "read".
15847 All callers and references changed.
15848
15849 * include/grub/file.h (struct grub_file): Change the types of
15850 "offset" and "size" to grub_off_t and grub_off_t,
15851 respectively. Change the type of SECTOR to grub_disk_addr_t in
15852 "read_hook".
15853 (grub_file_read): Change the type of LEN to grub_size_t.
15854 (grub_file_seek): Return grub_off_t. Change the type of OFFSET to
15855 grub_off_t.
15856 (grub_file_size): Return grub_off_t.
15857 (grub_file_tell): Likewise.
15858 All callers and references changed.
15859
15860 * include/grub/disk.h (struct grub_disk_dev): Change the types of
15861 SECTOR and SIZE to grub_disk_addr_t and grub_size_t in "read" and
15862 "write".
15863 (struct grub_disk): Change the type of "total_sectors" to
15864 grub_uint64_t. Change the type of SECTOR to grub_disk_addr_t in
f19dbdb7 15865 "read_hook".
524a1e6a 15866 (grub_disk_read): Change the types of SECTOR, OFFSET and SIZE to
15867 grub_disk_addr_t, grub_off_t and grub_size_t, respectively.
15868 (grub_disk_write): Likewise.
15869 All callers and references changed.
15870
15871 * fs/iso9660.c (grub_iso9660_susp_iterate): Cast parameters to
15872 char * for grub_strncmp to silence gcc.
15873 (grub_iso9660_mount): Likewise.
15874 (grub_iso9660_mount): Likewise.
15875 (grub_iso9660_read_symlink): Likewise. Also, remove the nonsense
15876 return statement.
15877 (grub_iso9660_iterate_dir): Likewise.
15878 (grub_iso9660_label): Cast DATA->VOLDESC.VOLNAME to char *.
15879
15880 * fs/hfs.c (grub_hfs_read_file): Change the types of SECTOR and
15881 LEN to grub_disk_addr_t and grub_size_t, respectively.
15882
15883 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
15884
15885 * fs/jfs.c (grub_jfs_read_file): Likewise.
15886
15887 * fs/minix.c (grub_jfs_read_file): Likewise.
15888
15889 * fs/sfs.c (grub_jfs_read_file): Likewise.
15890
15891 * fs/ufs.c (grub_jfs_read_file): Likewise.
15892
15893 * fs/xfs.c (grub_jfs_read_file): Likewise.
15894
15895 * fs/fat.c (grub_fat_read_data): Change the types of SECTOR, LEN
15896 and SIZE to grub_disk_addr_t, grub_size_t and grub_size_t,
15897 respectively.
15898
15899 * fs/ext2.c (grub_ext2_read_block): When an error happens, set
15900 BLKNR to -1 instead of returning GRUB_ERRNO.
15901 (grub_ext2_read_file): Change the types of SECTOR and
15902 LEN to grub_disk_addr_t and grub_size_t, respectively.
15903
15904 * fs/affs.c (grub_affs_read_file): Change the types of SECTOR and
15905 LEN to grub_disk_addr_t and grub_size_t, respectively.
15906
15907 * font/manager.c (grub_font_get_glyph): Cast BITMAP to char * for
15908 grub_file_read.
15909
15910 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Fix the format
15911 string. Do not cast SECTOR explicitly.
15912
15913 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): Change the type of
15914 TOTAL_SECTORS to grub_uint64_t. Do not mask DRP->TOTAL_SECTORS.
15915 (grub_biosdisk_rw): Change the types of SECTOR and SIZE to
15916 grub_disk_addr_t and grub_size_t, respectively. If the sector is
15917 over 2TB and LBA mode is not supported, raise an error.
15918 (get_safe_sectors): New function.
15919 (grub_biosdisk_read): Use get_safe_sectors.
15920 (grub_biosdisk_write): Likewise.
15921
15922 * disk/efi/efidisk.c (grub_efidisk_read): Fix the format string.
15923 (grub_efidisk_write): Likewise.
15924
15925 * disk/loopback.c (delete_loopback): Cosmetic changes.
15926 (grub_cmd_loopback): Likewise. Also, test NEWDEV->FILENAME
15927 correctly.
15928 (grub_loopback_open): Likewise.
15929 (grub_loopback_read): Likewise. Also, change the type of POS to
15930 grub_off_t, and fix the usage of grub_memset.
15931
15932 * commands/i386/pc/play.c: Include grub/machine/time.h.
15933
15934 * commands/ls.c (grub_ls_list_files): Use "llu" instead of "d" to
15935 print FILE->SIZE.
15936
15937 * commands/configfile.c: Include grub/env.h.
15938
15939 * commands/cmp.c (grub_cmd_cmp): Do not use ERR, but use
15940 GRUB_ERRNO directly instead. Change the type of POS to
15941 grub_off_t. Follow the coding standard.
15942
15943 * commands/blocklist.c: Include grub/partition.h.
15944 (grub_cmd_blocklist): Return an error if the underlying device is
15945 not a disk. Take the starting sector of a partition into account,
15946 if a partition is used.
15947
15948 * boot/i386/pc/diskboot.S (bootloop): Adapted to the new offset of
15949 a length field.
15950 (lba_mode): Support 64-bit addresses.
15951 (chs_mode): Likewise.
15952 (copy_buffer): Adapted to the new offsets of a length field and a
15953 segment field.
15954 (blocklist_default_start): Allocate 64-bit space.
15955
15956 * boot/i386/pc/boot.S (force_lba): Removed.
15957 (boot_drive): Moved to under KERNEL_SECTOR.
fe987087 15958 (kernel_sector): Moved to under KERNEL_SEGMENT. Allocate 64-bit
524a1e6a 15959 space.
15960 (real_start): Set %si earlier. Remove code for FORCE_LBA, since it
15961 is useless.
15962 (lba_mode): Refactored to support a 64-bit address. More size
15963 optimization.
15964 (setup_sectors): Likewise.
15965
53af98ad 159662006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
15967
15968 * DISTLIST: Added include/grub/i386/linux.h. Removed
15969 include/grub/i386/pc/linux.h
15970
15971 * configure.ac (AC_INIT): Bumped to 1.94.
15972
15973 * config.guess: Updated from gnulib.
15974 * config.sub: Likewise.
15975 * install-sh: Likewise.
15976 * mkinstalldirs: Likewise.
15977
b4c1940a 159782006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
15979
15980 * conf/common.rmk (grub_modules_init.lst): Depended on
15981 grub_emu_SOURCES, excluding grub_emu_init.c, instead of
15982 MODSRCFILES.
15983
15984 * genmk.rb (PModule::rule): Reverted the previous change.
15985
cfca1cfd 159862006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
15987
15988 * conf/common.rmk (grub_modules_init.lst): Depends on
15989 $(MODSRCFILES). Grep only the files in $(MODSRCFILES). Make sure
15990 that the target does not exist before producing.
15991 (grub_modules_init.h): Remove the target before generating.
15992 (grub_emu_init.c): Likewise.
15993
15994 * genmk.rb (PModule::rule): Add source files into MODSRCFILES.
15995
aa6d7826 159962006-05-31 Jeroen Dekkers <jeroen@dekkers.cx>
15997
15998 * configure.ac: Don't set host_m32 for x86_64. Also reset LIBS
15999 for the target-specific tests. Make sure that we also have the
16000 up-to-date target variables for those tests.
16001
26c607b9 160022006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
16003
16004 * genmk.rb (Image::rule): Prefix CFLAGS or ASFLAGS with TARGET_.
16005 (PModule::rule): Likewise.
16006
0162321a 160072006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
16008
16009 * genmk.rb (Image::rule): Set FLAG to CFLAGS or ASFLAGS instead of
16010 TARGET_CFLAGS or TARGET_ASFLAGS. There is no reason why
16011 target-specific flags should be prefixed.
16012 (PModule::rule): Likewise.
16013
6c826348 160142006-05-30 Yoshinori K. Okuji <okuji@enbug.org>
16015
16016 * configure.ac (CMP): Check if cmp is available explicitly.
16017
b977bf01 160182006-05-29 Yoshinori K. Okuji <okuji@enbug.org>
16019
16020 * util/powerpc/ieee1275/grub-install.in (host_cpu): Removed.
16021 (target_cpu): New variable.
16022 (pkglibdir): Use target_cpu instead of host_cpu.
f19dbdb7 16023
b977bf01 16024 * util/i386/pc/grub-install.in (host_cpu): Removed.
16025 (target_cpu): New variable.
16026 (pkglibdir): Use target_cpu instead of host_cpu.
16027
16028 * util/genmoddep.c: Removed.
f19dbdb7 16029
b977bf01 16030 * kern/efi/mm.c (filter_memory_map): Use GRUB_CPU_SIZEOF_VOID_P
16031 instead of GRUB_HOST_SIZEOF_VOID_P.
16032 * kern/dl.c: Likewise.
16033
16034 * include/grub/i386/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed to
16035 ...
16036 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
16037 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
16038 (GRUB_TARGET_SIZEOF_LONG): ... this.
16039 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
16040 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
16041 * include/grub/powerpc/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
16042 to ...
16043 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
16044 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
16045 (GRUB_TARGET_SIZEOF_LONG): ... this.
16046 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
16047 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
16048 * include/grub/sparc64/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
16049 to ...
16050 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
16051 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
16052 (GRUB_TARGET_SIZEOF_LONG): ... this.
16053 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
16054 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
16055
16056 * include/grub/types.h [!GRUB_UTIL] (GRUB_CPU_SIZEOF_VOID_P): Use
16057 GRUB_TARGET_SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P.
16058 [!GRUB_UTIL] (GRUB_CPU_SIZEOF_LONG): Use GRUB_TARGET_SIZEOF_LONG
16059 instead of GRUB_HOST_SIZEOF_LONG.
16060 [!GRUB_UTIL]: Refer to GRUB_TARGET_WORDS_BIGENDIAN instead of
16061 GRUB_HOST_WORDS_BIGENDIAN to define or undefine
16062 GRUB_CPU_WORDS_BIGENDIAN.
16063 Refer to SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P to
16064 define grub_host_addr_t, grub_host_off_t, grub_host_size_t and
16065 grub_host_ssize_t.
16066
16067 * conf/i386-efi.rmk (noinst_UTILITIES): Removed.
16068 (genmoddep_SOURCES): Likewise.
16069 * conf/i386-pc.rmk (noinst_UTILITIES): Likewise.
16070 (genmoddep_SOURCES): Likewise.
16071 * conf/conf/powerpc-ieee1275.rmk (noinst_UTILITIES): Likewise.
16072 (genmoddep_SOURCES): Likewise.
16073 * conf/conf/conf/sparc64-ieee1275.rmk (noinst_UTILITIES):
16074 Likewise.
16075 (genmoddep_SOURCES): Likewise.
16076
16077 * genmoddep.awk: New file.
16078
16079 * genmk.rb (Image::rule): Use TARGET_CC, TARGET_CPPFLAGS,
16080 TARGET_CFLAGS, TARGET_ASFLAGS and TARGET_LDFLAGS instead of CC,
16081 CPPFLAGS, CFLAGS, ASFLAGS and LDFLAGS, respectively.
16082 (PModule::rule): Likewise.
16083 (Program::rule): Likewise.
16084 (Utility::rule): Use CC, CPPFLAGS, CFLAGS and LDFLAGS instead of
16085 BUILD_CC, BUILD_CPPFLAGS, BUILD_CFLAGS and BUILD_LDFLAGS,
16086 respectively.
16087
16088 * configure.ac: Rewritten intensively to use host and target
16089 instead of build and host, respectively.
16090
16091 * Makefile.in (pkglibdir): Use target_cpu instead of host_cpu.
16092 (host_cpu): Removed.
16093 (target_cpu): New variable.
16094 (CPPFLAGS): Added @CPPFLAGS@ and -DGRUB_LIBDIR=\"$(pkglibdir)\".
16095 (BUILD_CC): Removed.
16096 (BUILD_CFLAGS): Likewise.
16097 (BUILD_CPPFLAGS): Likewise.
16098 (TARGET_CC): New variable.
16099 (TARGET_CFLAGS): Likewise.
16100 (TARGET_CPPFLAGS): Likewise.
16101 (TARGET_LDFLAGS): Likewise.
16102 (AWK): Likewise.
16103 (include): Use target_cpu instead of host_cpu.
16104 (moddep.lst:): Use genmoddep.awk instead of genmoddep.
f19dbdb7 16105
b977bf01 16106 * DISTLIST: Added genmoddep.awk. Removed util/genmoddep.c.
16107
f09771a1 161082006-05-29 Vesa Jaaskelainen <chaac@nic.fi>
16109
16110 * include/grub/script.h (grub_script_cmdif): Renamed field 'bool' to
16111 'exec_to_evaluate'. Renamed field 'true' to 'exec_on_true'. Renamed
16112 field 'false' to 'exec_on_false'.
16113 (grub_script_create_cmdif): Renamed argument names to reflect above
16114 changes.
16115
16116 * normal/execute.c (grub_script_execute_cmdif): Likewise.
16117
16118 * normal/script.c (grub_script_create_cmdif): Likewise.
16119
118f4fb3 161202006-05-28 Yoshinori K. Okuji <okuji@enbug.org>
16121
16122 * fs/hfsplus.c (grub_hfsplus_btree_recoffset): Moved to near the
16123 top.
16124 (grub_hfsplus_btree_recptr): Likewise.
16125 (grub_hfsplus_find_block): Do not take RETRY any longer. Use
16126 FILEBLOCK both to pass a block number and store next block
16127 number.
16128 (grub_hfsplus_read_block): Rewritten heavily to support an extent
16129 overflow file correctly. Specify errors appropriately, because
16130 fshelp expects that GRUB_ERRNO is set when fails. Reuse
16131 grub_hfsplus_btree_recptr to get the pointer to a found key.
16132 (grub_hfsplus_btree_search): Return 1 instead of 0 when no match
16133 is found.
16134
16135 * conf/i386-efi.rmk (pkgdata_MODULES): Added _linux.mod and
16136 linux.mod.
16137 (_linux_mod_SOURCES): New variable.
16138 (_linux_mod_CFLAGS): Likewise.
16139 (_linux_mod_LDFLAGS): Likewise.
16140 (linux_mod_SOURCES): Likewise.
16141 (linux_mod_CFLAGS): Likewise.
16142 (linux_mod_LDFLAGS): Likewise.
16143
16144 * DISTLIST: Added loader/i386/efi/linux.c,
16145 loader/i386/efi/linux_normal.c and
16146 include/grub/i386/efi/loader.h.
16147
16148 * loader/i386/efi/linux.c: New file.
16149 * loader/i386/efi/linux_normal.c: Likewise.
16150 * include/grub/i386/efi/loader.h: Likewise.
16151
89a7d726 161522006-05-27 Yoshinori K. Okuji <okuji@enbug.org>
16153
16154 * commands/blocklist.c: New file.
16155
16156 * DISTLIST: Added commands/blocklist.c.
16157
16158 * term/efi/console.c (grub_console_highlight_color): Use a lighter
43b553ad 16159 color for the background, and a darker color for the foreground.
89a7d726 16160 (grub_console_checkkey): Return READ_KEY.
16161 (grub_console_cls): Set the background to
16162 GRUB_EFI_BACKGROUND_BLACK temporarily to clean out the screen.
16163
16164 * kern/efi/efi.c (grub_efi_exit_boot_services): New function.
16165
16166 * include/grub/i386/linux.h (struct linux_kernel_params): Fixed
16167 the size of "padding5", "hd0_drive_info" and "hd1_drive_info".
16168
16169 * include/grub/efi/efi.h (grub_efi_exit_boot_services): New
16170 prototype.
16171
16172 * include/grub/efi/api.h (GRUB_EFI_TEXT_ATTR): Do not shift
16173 BG. The spec is wrong again.
16174
16175 * include/grub/normal.h [GRUB_UTIL] (grub_blocklist_init): New
16176 prototype.
16177 [GRUB_UTIL] (grub_blocklist_fini): Likewise.
16178
16179 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
16180 commands/blocklist.c.
16181 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
f19dbdb7 16182
89a7d726 16183 * conf/common.rmk (pkgdata_MODULES): Added blocklist.mod.
16184 (blocklist_mod_SOURCES): New variable.
16185 (blocklist_mod_CFLAGS): Likewise.
16186 (blocklist_mod_LDFLAGS): Likewise.
16187
75c8f258 161882006-05-20 Yoshinori K. Okuji <okuji@enbug.org>
16189
16190 * boot/i386/pc/boot.S (real_start): Set %si earlier to eliminate
16191 duplication.
16192 (lba_mode): Use %eax more intensively to reduce the code size.
16193
da2eb181 161942006-05-20 Marco Gerards <marco@gnu.org>
16195
16196 * normal/lexer.c (grub_script_yylex): Don't filter out newlines.
16197
16198 * normal/parser.y (commandblock): Defined as <cmd>. A subroutine
16199 for `menuentry'.
16200 (script): Accept leading newlines.
16201 (newlines): New rule to describe 0 or more newlines.
16202 (commands): Accept `command' with trailing newline. Fixed the
16203 order in which arguments were passed to `grub_script_add_cmd'.
16204 Accept commands separated by newlines.
16205 (function): Changed to accept newlines.
16206 (menuentry) Rewritten.
16207
16208 * normal/script.c (grub_script_create_cmdmenu): Add new entries in
16209 front of the list, instead of to the end.
16210
577b4050 162112006-05-19 Yoshinori K. Okuji <okuji@enbug.org>
16212
16213 * util/i386/pc/grub-install.in (bindir): New variable.
16214 (grub_mkimage): Use BINDIR instead of SBINDIR. Reported by Lee
16215 Shaver <lbgwjl@gmail.com>.
16216
0d6e1189 162172006-05-14 Yoshinori K. Okuji <okuji@enbug.org>
16218
16219 * kern/i386/pc/startup.S: Include grub/cpu/linux.h instead of
16220 grub/machine/linux.h
16221 * loader/i386/pc/linux.c: Likewise.
16222
16223 * include/grub/i386/pc/linux.h: Moved to ...
16224 * include/grub/i386/linux.h: ... here.
16225
16226 * include/grub/i386/linux.h (struct linux_kernel_params): New
16227 struct.
f19dbdb7 16228
31b86e9f 162292006-05-09 Vesa Jaaskelainen <chaac@nic.fi>
16230
16231 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Corrected bounds
16232 checking.
16233 (grub_video_vbe_blit_glyph): Likewise.
16234 (grub_video_vbe_blit_bitmap): Likewise.
16235 (grub_video_vbe_blit_render_target): Likewise.
16236
83b984de 162372006-05-09 Yoshinori K. Okuji <okuji@enbug.org>
16238
16239 * configure.ac (--with-platform): Properly quote the square
16240 brackets.
16241
5f0413bd 162422006-05-08 Marco Gerards <marco@gnu.org>
16243
16244 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Renamed from
16245 this...
16246 (kernel_elf_HEADERS): ...to this. Updated all users.
16247 (grubof_symlist.c): Renamed from this...
16248 (kernel_elf_symlist.c): ...to this. Updated all users.
16249 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
16250 (grubof_SOURCES): Renamed from this...
16251 (kernel_elf_SOURCES): ...to this.
16252 (grubof_HEADERS): Renamed from this...
16253 (kernel_elf_HEADERS): ...to this.
16254 (grubof_CFLAGS): Renamed from this...
16255 (kernel_elf_CFLAGS): ...to this.
16256 (grubof_ASFLAGS): Renamed from this...
16257 (kernel_elf_ASFLAGS): ...to this.
16258 (grubof_LDFLAGS): Renamed from this...
16259 (kernel_elf_LDFLAGS): ...to this.
16260
16261 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Renamed from
16262 this...
16263 (kernel_elf_HEADERS): ...to this. Updated all users.
16264 (grubof_symlist.c): Renamed from this...
16265 (kernel_elf_symlist.c): ...to this. Updated all users.
16266 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
16267 (grubof_SOURCES): Renamed from this...
16268 (kernel_elf_SOURCES): ...to this.
16269 (grubof_HEADERS): Renamed from this...
16270 (kernel_elf_HEADERS): ...to this.
16271 (grubof_CFLAGS): Renamed from this...
16272 (kernel_elf_CFLAGS): ...to this.
16273 (grubof_ASFLAGS): Renamed from this...
16274 (kernel_elf_ASFLAGS): ...to this.
16275 (grubof_LDFLAGS): Renamed from this...
16276 (kernel_elf_LDFLAGS): ...to this.
16277
16278 * util/powerpc/ieee1275/grub-mkimage.c (add_segments): Use
16279 `kernel.elf' instead of `grubof'.
16280
05568c2e 162812006-05-08 Yoshinori K. Okuji <okuji@enbug.org>
16282
16283 Add --with-platform to configure. Use pkglibdir instead of
16284 pkgdatadir. This is reported by Roger Leigh.
16285
16286 * util/powerpc/ieee1275/grub-install.in (datadir): Removed.
16287 (host_vendor): Likewise.
16288 (host_os): Likewise.
16289 (pkgdatadir): Likewise.
16290 (platform): New variable.
16291 (pkglibdir): Likewise.
16292 Use PKGLIBDIR instead of PKGDATADIR.
f19dbdb7 16293
05568c2e 16294 * util/i386/pc/grub-install.in (datadir): Removed.
16295 (host_vendor): Likewise.
16296 (host_os): Likewise.
16297 (pkgdatadir): Likewise.
16298 (platform): New variable.
16299 (pkglibdir): Likewise.
16300 Use PKGLIBDIR instead of PKGDATADIR.
16301
16302 * util/powerpc/ieee1275/grub-mkimage.c (usage): Use GRUB_LIBDIR
16303 instead of GRUB_DATADIR.
16304 (main): Likewise.
16305 * util/i386/pc/grub-mkimage.c (usage): Likewise.
16306 (main): Likewise.
16307 * util/i386/efi/grub-mkimage.c (usage): Likewise.
16308 (main): Likewise.
16309
16310 * configure.ac (--with-platform): New option.
16311 Use PLATFORM instead of HOST_VENDOR to specify a platform.
16312
16313 * Makefile.in: Include a makefile based on PLATFORM instead of
16314 HOST_VENDOR.
16315 (pkgdatadir): Not appended by the machine type.
16316 (pkglibdir): Appended by the machine type.
16317 (host_vendor): Removed.
16318 (platform): New variable.
16319 (BUILD_CPPFLAGS): Specify GRUB_LIBDIR instead of GRUB_DATADIR.
16320 (install-local): Use PKGLIBDIR instead of PKGDATADIR.
16321 (uninstall): Likewise.
16322
4e93851c 163232006-05-07 Yoshinori K. Okuji <okuji@enbug.org>
16324
16325 Use the environment context in the menu. Remove the commands
16326 "default" and "timeout", and use variables instead.
f19dbdb7 16327
4e93851c 16328 * normal/menu.c: Include grub/env.h.
16329 (print_entry): Cast TITLE to silence gcc.
16330 (get_timeout): New function.
16331 (set_timeout): Likewise.
16332 (get_entry_number): Likewise.
16333 (run_menu): Use a default entry, a fallback entry and a timeout
16334 in the environment variables "default", "fallback" and
16335 "timeout". Also, tweak the default entry if it is not within the
16336 current menu entries.
16337 (grub_menu_run): Use a fallback entry in the environment variable
16338 "fallback".
16339
16340 * normal/main.c (read_config_file): Do not initialize
16341 NEWMENU->DEFAULT_ENTRY, NEWMENU->FALLBACK_ENTRY or
16342 NEWMENU->TIMEOUT.
16343 (grub_normal_execute): Use a data slot to store the menu.
16344
16345 * include/grub/normal.h (struct grub_menu): Removed default_entry,
16346 fallback_entry and timeout.
16347 (struct grub_menu_list): Removed.
16348 (grub_menu_list_t): Likewise.
16349 (struct grub_context): Likewise.
16350 (grub_context_t): Likewise.
16351 (grub_context_get): Likewise.
16352 (grub_context_get_current_menu): Likewise.
16353 (grub_context_push_menu): Likewise.
16354 (grub_context_pop_menu): Likewise.
16355 (grub_default_init): Likewise.
16356 (grub_default_fini): Likewise.
16357 (grub_timeout_init): Likewise.
16358 (grub_timeout_fini): Likewise.
16359
16360 * conf/sparc64-ieee1275.rmk (pkgdata_MODULES): Removed default.mod
16361 and timeout.mod.
16362 (normal_mod_SOURCES): Removed normal/context.c.
16363
16364 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Removed
16365 commands/default.c, commands/timeout.c and normal/context.c.
16366 (normal_mod_SOURCES): Removed normal/context.c.
16367
16368 * conf/i386-pc.rmk (grub_emu_SOURCES): Removed commands/default.c,
16369 commands/timeout.c and normal/context.c.
16370 (normal_mod_SOURCES): Removed normal/context.c.
16371
16372 * conf/i386-efi.rmk (grub_emu_SOURCES): Removed
16373 commands/default.c, commands/timeout.c and normal/context.c.
16374 (normal_mod_SOURCES): Removed normal/context.c.
16375
16376 * conf/common.rmk (pkgdata_MODULES): Removed default.mod and
16377 timeout.mod.
16378 (default_mod_SOURCES): Removed.
16379 (default_mod_CFLAGS): Likewise.
16380 (default_mod_LDFLAGS): Likewise.
16381 (timeout_mod_SOURCES): Removed.
16382 (timeout_mod_CFLAGS): Likewise.
16383 (timeout_mod_LDFLAGS): Likewise.
16384
16385 * DISTLIST: Removed commands/default.c, commands/timeout.c and
16386 normal/context.c.
16387
16388 * commands/default.c: Removed.
16389 * commands/timeout.c: Likewise.
16390 * normal/context.c: Likewise.
16391
1eb9cc1d 163922006-05-07 Vesa Jaaskelainen <chaac@nic.fi>
16393
16394 * kern/i386/pc/startup.S (grub_exit): Added missing .code32 tag.
16395
385bd9c1 163962006-05-02 Yoshinori K. Okuji <okuji@enbug.org>
16397
16398 * kern/env.c (struct grub_env_context): Removed "sorted". Renamed
16399 "next" to "prev" for readability.
16400 (struct grub_env_sorted_var): New struct.
16401 (grub_env_context): Renamed to ...
16402 (initial_context): ... this.
16403 (grub_env_var_context): Renamed to ...
16404 (current_context): ... this.
16405 (grub_env_find): Look only at CURRENT_CONTEXT.
16406 (grub_env_context_open): Rewritten to copy exported variables from
16407 previous context.
16408 (grub_env_context_close): Rewritten according to the new
16409 scheme. Also, add an assertion to prevent the initial context from
16410 removed.
16411 (grub_env_insert): Removed the code for the sorted list.
16412 (grub_env_remove): Likewise.
16413 (grub_env_export): Simply mark the variable with
16414 GRUB_ENV_VAR_GLOBAL.
16415 (grub_env_set): A cosmetic change for naming consistency.
16416 (grub_env_get): Likewise.
16417 (grub_env_unset): Likewise.
16418 (grub_env_iterate): Rewritten to sort variables within this
16419 function.
16420 (grub_register_variable_hook): Fixed for naming consistency. Call
16421 grub_env_find again, only if NAME is not found at the first time.
16422 (mangle_data_slot_name): New function.
16423 (grub_env_set_data_slot): Likewise.
16424 (grub_env_get_data_slot): Likewise.
16425 (grub_env_unset_data_slot): Likewise.
16426
16427 * include/grub/env.h (grub_env_var_type): New enum.
16428 (GRUB_ENV_VAR_LOCAL): New constant.
16429 (GRUB_ENV_VAR_GLOBAL): Likewise.
16430 (GRUB_ENV_VAR_DATA): Likewise.
16431 (struct grub_env_var): Removed "sort_next" and "sort_prevp". Added
16432 "type".
16433 (grub_env_set): Replace VAR with NAME for consistency.
16434 (grub_register_variable_hook): Likewise.
16435 (grub_env_export): Specify the name of the argument.
16436 (grub_env_set_data_slot): New prototype.
16437 (grub_env_get_data_slot): Likewise.
16438 (grub_env_unset_data_slot): Likewise.
16439
7f362539 164402006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
16441
16442 Extend the loader so that GRUB can accept a loader which comes
16443 back to GRUB when a loaded image exits. Also, this change adds
16444 support for a chainloader on EFI.
f19dbdb7 16445
7f362539 16446 * term/efi/console.c: Include grub/misc.h.
16447 (grub_console_checkkey): Display a scan code on the top for
16448 debugging. This will be removed once the EFI port gets stable.
16449 Correct the scan code mapping.
16450
16451 * kern/efi/mm.c (sort_memory_map): Sort in a descending order to
16452 allocate memory from larger regions, in order to reduce the number
16453 of allocated regions. Otherwise, the MacOSX loader panics.
16454 (filter_memory_map): Avoid less than 1MB for compatibility with
16455 other loaders.
16456 (add_memory_regions): Allocate from the tail of a region, if
16457 possible, to avoid allocating a region near to 1MB, for the MacOSX
16458 loader.
16459
16460 * kern/efi/init.c (grub_efi_set_prefix): Specify
16461 GRUB_EFI_IMAGE_HANDLE to grub_efi_get_loaded_image.
16462
16463 * kern/efi/efi.c (grub_efi_get_loaded_image): Accept a new
16464 argument IMAGE_HANDLE and specify it to get a loaded image.
16465 (grub_arch_modules_addr): Specify GRUB_EFI_IMAGE_HANDLE to
16466 grub_efi_get_loaded_image.
fe6b695a 16467 (grub_efi_get_filename): Divide the length by the size of
7f362539 16468 grub_efi_char16_t.
16469 (grub_efi_get_device_path): New function.
16470 (grub_efi_print_device_path): Print End Device Path nodes. Divide
16471 the length by the size of grub_efi_char16_t for a file path device
16472 path node.
16473
16474 * kern/loader.c (grub_loader_noreturn): New variable.
16475 (grub_loader_set): Accept a new argument NORETURN. Set
16476 GRUB_LOADER_NORETURN to NORETURN.
16477 All callers changed.
16478 (grub_loader_boot): If GRUB_LOADER_NORETURN is false, do not call
16479 grub_machine_fini.
16480
16481 * include/grub/efi/efi.h (grub_efi_get_device_path): New
16482 prototype.
16483 (grub_efi_get_loaded_image): Take an argument to specify an image
16484 handle.
16485
16486 * include/grub/loader.h (grub_loader_set): Added one more argument
16487 NORETURN.
16488
16489 * disk/efi/efidisk.c (make_devices): Use grub_efi_get_device_path
16490 instead of grub_efi_open_protocol.
16491 (grub_efidisk_get_device_name): Likewise.
16492 (grub_efidisk_close): Print a newline.
16493 (grub_efidisk_get_device_handle): Fixed to use
16494 GRUB_EFI_DEVICE_PATH_SUBTYPE instead of
16495 GRUB_EFI_DEVICE_PATH_TYPE.
16496
16497 * disk/efi/efidisk.c (device_path_guid): Moved to ...
16498 * kern/efi/efi.c (device_path_guid): ... here.
16499
16500 * conf/i386-efi.rmk (pkgdata_MODULES): Added _chain.mod and
16501 chain.mod.
16502 (kernel_mod_HEADERS): Added efi/disk.h.
16503 (_chain_mod_SOURCES): New variable.
16504 (_chain_mod_CFLAGS): Likewise.
16505 (_chain_mod_LDFLAGS): Likewise.
16506 (chain_mod_SOURCES): Likewise.
16507 (chain_mod_CFLAGS): Likewise.
16508 (chain_mod_LDFLAGS): Likewise.
16509
16510 * DISTLIST: Added include/grub/efi/chainloader.h,
16511 loader/efi/chainloader.c and loader/efi/chainloader_normal.c.
16512
16513 * include/grub/efi/chainloader.h: New file.
16514 * loader/efi/chainloader.c: Likewise.
16515 * loader/efi/chainloader_normal.c: Likewise.
16516
c0111d6e 165172006-04-30 Marco Gerards <marco@gnu.org>
16518
16519 * commands/configfile.c (grub_cmd_source): New function.
16520 (GRUB_MOD_INIT): Register the commands `source' and `.'.
16521 (GRUB_MOD_FINI): De-register the commands `source' and `.'.
16522
df5341da 165232006-04-30 Marco Gerards <marco@gnu.org>
16524
16525 * normal/execute.c (grub_script_execute_cmd): Change the return
16526 type to `grub_err_t'. Correctly return the error.
16527 (grub_script_execute_cmdline): In case a command line is not a
16528 command or a function, try to interpret it as an assignment.
16529
f85934bd 165302006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
16531
16532 * fs/hfsplus.c (grub_hfsplus_read_block): Fixed a memory leak.
16533 (grub_hfsplus_iterate_dir): Reordered to skip unknown nodes. Also,
16534 skip a node whose name is obviously invalid as UTF-16,
16535 i.e. contains a NUL character. Stop the iteration when the last
16536 directory entry is found. Instead of using the return value of
16537 grub_hfsplus_btree_iterate_node, store the value in RET and use
16538 it, because the iterator can be stopped by the last directory
16539 entry.
16540
8f8a2cf8 165412006-04-30 Marco Gerards <marco@gnu.org>
16542
16543 * include/grub/env.h (grub_env_export): New prototype. Reported
16544 by Jan C. Kleinsorge <jan.kleinsorge@udo.edu>.
16545
a27e84ce 165462006-04-30 Marco Gerards <marco@gnu.org>
16547
16548 * fs/hfsplus.c (grub_hfsplus_iterate_dir): Correctly calculate the
16549 size of the extents in a catalog file record.
16550
eaef0553 165512006-04-29 Marco Gerards <marco@gnu.org>
16552
16553 * commands/configfile.c (grub_cmd_configfile): Execute the
16554 configfile within its own context.
16555
16556 * include/grub/env.h (grub_env_context_open): New prototype.
16557 (grub_env_context_close): Likewise.
16558
16559 * kern/env.c (grub_env): Removed.
16560 (grub_env_sorted): Likewise.
16561 (grub_env_context): New variable.
16562 (grub_env_var_context): Likewise.
16563 (grub_env_find): Search both the active context and the global
16564 context.
16565 (grub_env_context_open): New function.
16566 (grub_env_context_close): Likewise.
16567 (grub_env_insert): Likewise.
16568 (grub_env_remove): Likewise.
16569 (grub_env_export): Likewise.
16570 (grub_env_set): Changed to use helper functions to avoid code
16571 duplication.
16572 (grub_env_iterate): Rewritten so both the current context and the
16573 global context are being used.
16574
16575 * normal/command.c (export_command): New function.
16576 (grub_command_init): Register the `export' function.
16577
7b455f4d 165782006-04-26 Yoshinori K. Okuji <okuji@enbug.org>
16579
16580 * util/i386/pc/grub-mkimage.c (compress_kernel): Cast arguments
16581 explicitly to suppress gcc's warnings.
16582 * fs/fat.c (grub_fat_find_dir): Likewise.
16583 (grub_fat_label): Likewise.
16584 * fs/xfs.c (grub_xfs_read_inode): Likewise.
16585 (grub_xfs_mount): Likewise.
16586 (grub_xfs_label): Likewise.
16587 * fs/affs.c (grub_affs_mount): Likewise.
16588 (grub_affs_label): Likewise.
16589 (grub_affs_iterate_dir): Likewise.
16590 * fs/sfs.c (grub_sfs_mount): Likewise.
16591 (grub_sfs_iterate_dir): Likewise.
16592 * fs/ufs.c (grub_ufs_lookup_symlink): Likewise.
16593 * fs/hfs.c (grub_hfs_mount): Likewise.
16594 (grub_hfs_cmp_catkeys): Likewise.
16595 (grub_hfs_find_dir): Likewise.
16596 (grub_hfs_dir): Likewise.
16597 (grub_hfs_label): Likewise.
16598 * fs/jfs.c (grub_jfs_mount): Likewise.
16599 (grub_jfs_opendir): Likewise.
16600 (grub_jfs_getent): Likewise.
16601 (grub_jfs_lookup_symlink): Likewise.
16602 (grub_jfs_label): Likewise.
16603 * fs/hfsplus.c (grub_hfsplus_cmp_catkey): Likewise.
16604 (grub_hfsplus_iterate_dir): Likewise.
16605 (grub_hfsplus_btree_iterate_node): Made static.
16606
16607 * util/grub-emu.c (prefix): New variable.
16608 (grub_machine_set_prefix): New function.
16609 (main): Do not set the environment variable "prefix" here. Only
16610 set PREFIX, which is used later by grub_machine_set_prefix.
16611
16612 * include/grub/video.h: Do not include grub/symbol.h.
16613 (grub_video_register): Not exported. This symbol is not defined in
16614 the kernel.
16615 (grub_video_unregister): Likewise.
16616 (grub_video_iterate): Likewise.
16617 (grub_video_setup): Likewise.
16618 (grub_video_restore): Likewise.
16619 (grub_video_get_info): Likewise.
16620 (grub_video_get_blit_format): Likewise.
16621 (grub_video_set_palette): Likewise.
16622 (grub_video_get_palette): Likewise.
16623 (grub_video_set_viewport): Likewise.
16624 (grub_video_get_viewport): Likewise.
16625 (grub_video_map_color): Likewise.
16626 (grub_video_map_rgb): Likewise.
16627 (grub_video_map_rgba): Likewise.
16628 (grub_video_fill_rect): Likewise.
16629 (grub_video_blit_glyph): Likewise.
16630 (grub_video_blit_bitmap): Likewise.
16631 (grub_video_blit_render_target): Likewise.
16632 (grub_video_scroll): Likewise.
16633 (grub_video_swap_buffers): Likewise.
16634 (grub_video_create_render_target): Likewise.
16635 (grub_video_delete_render_target): Likewise.
16636 (grub_video_set_active_render_target): Likewise.
16637
16638 * include/grub/symbol.h [GRUB_SYMBOL_GENERATOR] (EXPORT_FUNC):
16639 Undefined.
16640 [GRUB_SYMBOL_GENERATOR] (EXPORT_VAR): Likewise.
16641
16642 * conf/sparc64-ieee1275.rmk (grubof_symlist.c): Depended on
16643 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
16644 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
16645 instead of $(srcdir)/genkernsyms.sh.
16646
16647 * conf/powerpc-ieee1275.rmk (grubof_symlist.c): Depended on
16648 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
16649 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
16650 instead of $(srcdir)/genkernsyms.sh.
16651
16652 * conf/i386-pc.rmk (symlist.c): Depended on config.h. Use
16653 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
16654 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
16655 instead of $(srcdir)/genkernsyms.sh.
16656
16657 * conf/i386-efi.rmk (symlist.c): Depended on config.h. Use
16658 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
16659 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
16660 instead of $(srcdir)/genkernsyms.sh.
16661
16662 * configure.ac (AC_CONFIG_FILES): Added gensymlist.sh and
16663 genkernsyms.sh.
16664
16665 * Makefile.in (DISTCLEANFILES): Added gensymlist.sh and
16666 genkernsyms.sh.
16667 (gensymlist.sh): New target.
16668 (genkernsyms.sh): Likewise.
16669
16670 * DISTLIST: Removed genkernsyms.sh and gensymlist.sh. Added
16671 genkernsyms.sh.in and gensymlist.sh.in.
16672
16673 * genkernsyms.sh: Removed.
16674 * gensymlist.sh: Likewise.
f19dbdb7 16675
7b455f4d 16676 * genkernsyms.sh.in: New file.
16677 * gensymlist.sh.in: Likewise.
16678
1885bb27 166792006-04-25 Hollis Blanchard <hollis@penguinppc.org>
16680
16681 * kern/powerpc/ieee1275/init.c (grub_machine_set_prefix): Do not
16682 clobber "prefix", since we may have already set it manually.
16683
71538dff 166842006-04-25 Hollis Blanchard <hollis@penguinppc.org>
16685
16686 * kern/misc.c (abort): New alias for grub_abort.
16687
2965c7cc 166882006-04-25 Yoshinori K. Okuji <okuji@enbug.org>
16689
16690 A new machine-specific function "grub_machine_set_prefix" is
16691 defined. This is called after loading modules, so that a prefix
16692 initialization can use modules. Also, this change adds an
16693 intensive debugging feature for the memory manager via the
16694 configure option "--enable-mm-debug".
f19dbdb7 16695
2965c7cc 16696 * partmap/gpt.c (gpt_partition_map_iterate): Add one more into
16697 PART.LEN.
16698
16699 * kern/sparc64/ieee1275/init.c (abort): Removed.
16700 (grub_stop): Likewise.
16701 (grub_exit): New function.
16702 (grub_set_prefix): Renamed to ...
16703 (grub_machine_set_prefix): ... this.
16704 (grub_machine_init): Do not call grub_set_prefix.
16705
16706 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Renamed to ...
16707 (grub_machine_set_prefix): ... this.
16708 (grub_machine_init): Do not call grub_set_prefix.
16709
16710 * kern/i386/pc/init.c (grub_machine_set_prefix): New function.
16711 (grub_machine_init): Do not set the prefix here.
16712
16713 * kern/i386/efi/init.c (grub_machine_set_prefix): New function.
16714
16715 * kern/efi/init.c: Include grub/mm.h.
16716 (grub_efi_set_prefix): New function.
16717
16718 * kern/efi/efi.c (grub_exit): Call grub_efi_fini.
16719 (grub_efi_get_filename): New function.
16720 (grub_print_device_path): Renamed to ...
16721 (grub_efi_print_device_path): ... this.
16722
16723 * kern/mm.c [MM_DEBUG] (grub_malloc): Undefined.
16724 [MM_DEBUG] (grub_realloc): Likewise.
16725 [MM_DEBUG] (grub_free): Likewise.
16726 [MM_DEBUG] (grub_memalign): Likewise.
16727 [MM_DEBUG] (grub_mm_debug): New variable.
16728 [MM_DEBUG] (grub_debug_malloc): New function.
16729 [MM_DEBUG] (grub_debug_free): New function.
16730 [MM_DEBUG] (grub_debug_realloc): New function.
16731 [MM_DEBUG] (grub_debug_memalign): New function.
16732
16733 * kern/misc.c (grub_abort): Print a newline to distinguish
16734 the message.
16735
16736 * kern/main.c (grub_main): Call grub_machine_set_prefix and
16737 grub_set_root_dev after loading modules. This is necessary when
16738 setting a prefix depends on modules.
16739
16740 * include/grub/efi/efi.h (grub_print_device_path): Renamed to ...
16741 (grub_efi_print_device_path): ... this.
16742 (grub_efi_get_filename): New prototype.
16743 (grub_efi_set_prefix): Likewise.
16744
16745 * include/grub/efi/disk.h: Include grub/efi/api.h, grub/symbol.h
16746 and grub/disk.h.
16747 (grub_efidisk_get_device_handle): New prototype.
16748 (grub_efidisk_get_device_name): Likewise.
16749
16750 * include/grub/mm.h: Include config.h.
16751 (MM_DEBUG): Removed.
16752 [MM_DEBUG && !GRUB_UTIL] (grub_mm_debug): New prototype.
16753 [MM_DEBUG && !GRUB_UTIL] (grub_malloc): New macro.
16754 [MM_DEBUG && !GRUB_UTIL] (grub_realloc): Likewise.
16755 [MM_DEBUG && !GRUB_UTIL] (grub_memalign): Likewise.
16756 [MM_DEBUG && !GRUB_UTIL] (grub_free): Likewise.
16757 [MM_DEBUG && !GRUB_UTIL] (grub_debug_malloc): New prototype.
16758 [MM_DEBUG && !GRUB_UTIL] (grub_debug_realloc): New prototype.
16759 [MM_DEBUG && !GRUB_UTIL] (grub_debug_memalign): New prototype.
16760 [MM_DEBUG && !GRUB_UTIL] (grub_debug_free): New prototype.
16761
16762 * include/grub/kernel.h (grub_machine_set_prefix): New prototype.
16763
16764 * disk/efi/efidisk.c: Include grub/partition.h.
16765 (iterate_child_devices): New function.
16766 (add_device): First, compare only last device path nodes, so that
16767 devices are sorted by the types.
16768 (grub_efidisk_get_device_handle): New function.
16769 (grub_efidisk_get_device_name): Likewise.
16770
16771 * configure.ac (--enable-mm-debug): New option to enable the
16772 memory manager debugging feature. This makes the binary much
16773 bigger, so is disabled by default.
16774
9cacaa17 167752006-04-23 Yoshinori K. Okuji <okuji@enbug.org>
16776
16777 Use grub_abort instead of grub_stop, and grub_exit must be
16778 define in each architecture now. Also, this change adds support
16779 for EFI disks.
f19dbdb7 16780
9cacaa17 16781 * util/i386/pc/grub-probefs.c: Include grub/term.h.
16782 (grub_getkey): New function.
16783 (grub_term_get_current): Likewise.
16784
16785 * util/i386/pc/grub-setup.c: Include grub/term.h.
16786 (grub_getkey): New function.
16787 (grub_term_get_current): Likewise.
16788
16789 * util/misc.c (grub_stop): Renamed to ...
16790 (grub_exit): ... this.
16791
16792 * kern/powerpc/ieee1275/init.c (abort): Renamed to ...
16793 (grub_exit): ... this.
16794 (grub_machine_init): Use grub_abort instead of abort.
16795 (grub_stop): Removed.
16796
16797 * kern/powerpc/ieee1275/cmain.c (cmain): Use grub_abort instead of
16798 abort.
16799
16800 * kern/i386/pc/startup.S (grub_exit): New function.
16801 (cold_reboot): New label.
16802
16803 * kern/efi/init.c: Include grub/efi/disk.h and grub/env.h.
16804 (grub_efi_init): Call grub_efidisk_init.
16805 (grub_efi_fini): Call grub_efidisk_fini.
16806
16807 * kern/efi/efi.c: Include grub/mm.h.
16808 (grub_efi_console_control_guid): Renamed to ...
16809 (console_control_guid): ... this.
16810 (grub_efi_loaded_image_guid): Renamed to ...
16811 (loaded_image_guid): ... this.
16812 (grub_efi_locate_handle): New function.
16813 (grub_efi_open_protocol): Likewise.
16814 (grub_efi_set_text_mode): Use CONSOLE_CONTROL_GUID instead of
16815 GRUB_EFI_CONSOLE_CONTROL_GUID.
16816 (grub_efi_exit): Removed.
16817 (grub_stop): Likewise.
16818 (grub_efi_get_loaded_image): Use grub_efi_open_protocol.
16819 (grub_exit): New function.
16820 (grub_print_device_path): Likewise.
16821
16822 * kern/rescue.c (grub_rescue_cmd_exit): New function.
16823 (grub_enter_rescue_mode): Register "exit".
16824
16825 * kern/misc.c (grub_real_dprintf): A cosmetic change.
16826 (grub_abort): New function.
16827
16828 * kern/err.c (grub_fatal): Use grub_abort instead of grub_stop.
16829
16830 * include/grub/sparc64/ieee1275/kernel.h (abort): Removed.
16831
16832 * include/grub/powerpc/ieee1275/kernel.h (abort): Removed.
16833
16834 * include/grub/efi/efi.h (grub_efi_exit): Removed.
16835 (grub_print_device_path): New prototype.
16836 (grub_efi_locate_handle): Likewise.
16837 (grub_efi_open_protocol): Likewise.
16838
16839 * include/grub/efi/disk.h (grub_efidisk_fini): New file.
16840 * disk/efi/efidisk.c: Likewise.
16841
16842 * DISTLIST: Added disk/efi/efidisk.c and include/grub/efi/disk.h.
16843
16844 * include/grub/efi/console_control.h
16845 (GRUB_EFI_CONSOLE_CONTROL_GUID): Use an array for the last 8 bytes.
16846
16847 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): Specify the
16848 last 8 bytes as an array.
16849 (GRUB_EFI_DISK_IO_GUID): New macro.
16850 (GRUB_EFI_BLOCK_IO_GUID): Likewise.
16851 (GRUB_EFI_DEVICE_PATH_GUID): Likewise.
16852 (grub_efi_ipv6_address_t): Change the type to grub_uint16_t from
16853 grub_uint8_t.
16854 (struct grub_efi_guid): Use an array to specify the last 8 bytes.
16855 (struct grub_efi_device_path): Rename the member "sub_type" to
16856 "subtype".
16857 (GRUB_EFI_DEVICE_PATH_TYPE): New macro.
16858 (GRUB_EFI_DEVICE_PATH_SUBTYPE): Likewise.
16859 (GRUB_EFI_DEVICE_PATH_LENGTH): Likewise.
16860 (GRUB_EFI_END_DEVICE_PATH_TYPE): Likewise.
16861 (GRUB_EFI_END_ENTIRE_DEVICE_PATH_SUBTYPE): Likewise.
16862 (GRUB_EFI_END_THIS_DEVICE_PATH_SUBTYPE): Likewise.
16863 (GRUB_EFI_END_ENTIRE_DEVICE_PATH): Likewise.
16864 (GRUB_EFI_NEXT_DEVICE_PATH): Likewise.
16865 (GRUB_EFI_HARDWARE_DEVICE_PATH_TYPE): Likewise.
16866 (GRUB_EFI_PCI_DEVICE_PATH_SUBTYPE): Likewise.
16867 (struct grub_efi_pci_device_path): New structure.
16868 (grub_efi_pci_device_path_t): New type.
16869 (GRUB_EFI_PCCARD_DEVICE_PATH_SUBTYPE): New macro.
16870 (struct grub_efi_pccard_device_path): New structure.
16871 (grub_efi_pccard_device_path_t): New type.
16872 (GRUB_EFI_MEMORY_MAPPED_DEVICE_PATH_SUBTYPE): New macro.
16873 (struct grub_efi_memory_mapped_device_path): New structure.
16874 (grub_efi_memory_mapped_device_path_t): New type.
16875 (GRUB_EFI_VENDOR_DEVICE_PATH_SUBTYPE): New macro.
16876 (struct grub_efi_vendor_device_path): New structure.
16877 (grub_efi_vendor_device_path_t): New type.
16878 (GRUB_EFI_CONTROLLER_DEVICE_PATH_SUBTYPE): New macro.
16879 (struct grub_efi_controller_device_path): New structure.
16880 (grub_efi_controller_device_path_t): New type.
16881 (GRUB_EFI_ACPI_DEVICE_PATH_TYPE): New macro.
16882 (GRUB_EFI_ACPI_DEVICE_PATH_SUBTYPE): Likewise.
16883 (struct grub_efi_acpi_device_path): New structure.
16884 (grub_efi_acpi_device_path_t): New type.
16885 (GRUB_EFI_EXPANDED_ACPI_DEVICE_PATH_SUBTYPE): New macro.
16886 (struct grub_efi_expanded_acpi_device_path): New structure.
16887 (grub_efi_expanded_acpi_device_path_t): New type.
16888 (GRUB_EFI_EXPANDED_ACPI_HIDSTR): New macro.
16889 (GRUB_EFI_EXPANDED_ACPI_UIDSTR): Likewise.
16890 (GRUB_EFI_EXPANDED_ACPI_CIDSTR): Likewise.
16891 (GRUB_EFI_MESSAGING_DEVICE_PATH_TYPE): Likewise.
16892 (GRUB_EFI_ATAPI_DEVICE_PATH_SUBTYPE): Likewise.
16893 (struct grub_efi_atapi_device_path): New structure.
16894 (grub_efi_atapi_device_path_t): New type.
16895 (GRUB_EFI_FIBRE_CHANNEL_DEVICE_PATH_SUBTYPE): New macro.
16896 (struct grub_efi_fibre_channel_device_path): New structure.
16897 (grub_efi_fibre_channel_device_path_t): New type.
16898 (GRUB_EFI_1394_DEVICE_PATH_SUBTYPE): New macro.
16899 (struct grub_efi_1394_device_path): New structure.
16900 (grub_efi_1394_device_path_t): New type.
16901 (GRUB_EFI_USB_DEVICE_PATH_SUBTYPE): New macro.
16902 (struct grub_efi_usb_device_path): New structure.
16903 (grub_efi_usb_device_path_t): New type.
16904 (GRUB_EFI_USB_CLASS_DEVICE_PATH_SUBTYPE): New macro.
16905 (struct grub_efi_usb_class_device_path): New structure.
16906 (grub_efi_usb_class_device_path_t): New type.
16907 (GRUB_EFI_I2O_DEVICE_PATH_SUBTYPE): New macro.
16908 (struct grub_efi_i2o_device_path): New structure.
16909 (grub_efi_i2o_device_path_t): New type.
16910 (GRUB_EFI_MAC_ADDRESS_DEVICE_PATH_SUBTYPE): New macro.
16911 (struct grub_efi_mac_address_device_path): New structure.
16912 (grub_efi_mac_address_device_path_t): New type.
16913 (GRUB_EFI_IPV4_DEVICE_PATH_SUBTYPE): New macro.
16914 (struct grub_efi_ipv4_device_path): New structure.
16915 (grub_efi_ipv4_device_path_t): New type.
16916 (GRUB_EFI_IPV6_DEVICE_PATH_SUBTYPE): New macro.
16917 (struct grub_efi_ipv6_device_path): New structure.
16918 (grub_efi_ipv6_device_path_t): New type.
16919 (GRUB_EFI_INFINIBAND_DEVICE_PATH_SUBTYPE): New macro.
16920 (struct grub_efi_infiniband_device_path): New structure.
16921 (grub_efi_infiniband_device_path_t): New type.
16922 (GRUB_EFI_UART_DEVICE_PATH_SUBTYPE): New macro.
16923 (struct grub_efi_uart_device_path): New structure.
16924 (grub_efi_uart_device_path_t): New type.
16925 (GRUB_EFI_VENDOR_MESSAGING_DEVICE_PATH_SUBTYPE): New macro.
16926 (struct grub_efi_vendor_messaging_device_path): New structure.
16927 (grub_efi_vendor_messaging_device_path_t): New type.
16928 (GRUB_EFI_MEDIA_DEVICE_PATH_TYPE): New macro.
16929 (GRUB_EFI_HARD_DRIVE_DEVICE_PATH_SUBTYPE): Likewise.
16930 (struct grub_efi_hard_drive_device_path): New structure.
16931 (grub_efi_hard_drive_device_path_t): New type.
16932 (GRUB_EFI_CDROM_DEVICE_PATH_SUBTYPE): New macro.
16933 (struct grub_efi_cdrom_device_path): New structure.
16934 (grub_efi_cdrom_device_path_t): New type.
16935 (GRUB_EFI_VENDOR_MEDIA_DEVICE_PATH_SUBTYPE): New macro.
16936 (struct grub_efi_vendor_media_device_path): New structure.
16937 (grub_efi_vendor_media_device_path_t): New type.
16938 (GRUB_EFI_FILE_PATH_DEVICE_PATH_SUBTYPE): New macro.
16939 (struct grub_efi_file_path_device_path): New structure.
16940 (grub_efi_file_path_device_path_t): New type.
16941 (GRUB_EFI_PROTOCOL_DEVICE_PATH_SUBTYPE): New macro.
16942 (struct grub_efi_protocol_device_path): New structure.
16943 (grub_efi_protocol_device_path_t): New type.
16944 (GRUB_EFI_BIOS_DEVICE_PATH_TYPE): New macro.
16945 (GRUB_EFI_BIOS_DEVICE_PATH_SUBTYPE): Likewise.
16946 (struct grub_efi_bios_device_path): New structure.
16947 (grub_efi_bios_device_path_t): New type.
16948 (struct grub_efi_disk_io): New structure.
16949 (grub_efi_disk_io_t): New type.
16950 (struct grub_efi_block_io_media): New structure.
16951 (grub_efi_block_io_media_t): New type.
16952 (struct grub_efi_block_io): New structure.
16953 (grub_efi_block_io_t): New type.
16954
16955 * include/grub/misc.h (grub_stop): Removed.
16956 (grub_exit): New prototype.
16957 (grub_abort): Likewise.
16958
16959 * include/grub/disk.h (enum grub_disk_dev_id): Added
16960 GRUB_DISK_DEVICE_EFIDISK_ID.
16961
16962 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added
16963 disk/efi/efidisk.c.
16964 (kernel_syms.lst): Remove the target if an error occurs.
16965
49986a9f 169662006-04-22 Yoshinori K. Okuji <okuji@enbug.org>
16967
16968 * kern/misc.c (grub_lltoa): Rewritten the decimal conversion part,
16969 as it was simply too buggy.
16970
970d3b8a 169712006-04-21 Yoshinori K. Okuji <okuji@enbug.org>
16972
16973 * kern/misc.c (grub_lltoa): New function.
16974 (grub_vsprintf): Added support for the long long suffix,
16975 i.e. "ll".
16976
ff04ec24 169772006-04-20 Hollis Blanchard <hollis@penguinppc.org>
16978
16979 * Makefile.in (LDFLAGS): Add variable.
16980 (LD): Remove variable.
16981 * configure.ac: Add -m32 to LDFLAGS.
16982 * genmk.rb (PModule#rule): Use $(CC) instead of $(LD).
16983 * conf/powerpc-ieee1275.rmk (COMMON_LDFLAGS): Add variable.
16984 (grubof_LDFLAGS): Use $(COMMON_LDFLAGS).
16985 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS, normal_mod_LDFLAGS,
16986 suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS): New
16987 variables.
16988 * conf/sparc64-ieee1275.rmk (COMMON_LDFLAGS): Add -nostdlib.
16989 * conf/i386-pc.rmk (COMMON_LDFLAGS): Add -nostdlib.
16990 * conf/i386-efi.rmk (COMMON_LDFLAGS): Add -nostdlib.
16991
37e5e1a4 169922006-04-20 Vesa Jaaskelainen <chaac@nic.fi>
16993
16994 * term/gfxterm.c (grub_gfxterm_getcharwidth): Fixed character
16995 length for unknown glyph.
16996
c352d8dd 169972006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
16998
2eab1c0d 16999 Add support for pre-loaded modules into the EFI port.
f19dbdb7 17000
2eab1c0d 17001 * util/i386/efi/grub-mkimage.c (make_mods_section): Rewritten
17002 completely. Accept one more argument DIR. The caller has changed.
17003
17004 * kern/i386/efi/init.c (grub_arch_modules_addr): Removed.
17005
17006 * kern/efi/efi.c: Include grub/efi/pe32.h and grub/kernel.h.
17007 (grub_efi_loaded_image_guid): New variable.
17008 (grub_efi_get_loaded_image): New function.
17009 (grub_arch_modules_addr): Likewise.
17010
17011 * include/grub/efi/efi.h (grub_efi_get_loaded_image): New
17012 prototype.
17013
17014 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): New macro.
17015 (struct grub_efi_loaded_image): New structure.
17016 (grub_efi_loaded_image_t): New type.
17017
170182006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
f19dbdb7 17019
c352d8dd 17020 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Compare the file
17021 size with GRUB_OS_AREA_SIZE as grub_size_t instead of
17022 grub_ssize_t. Reported by Jeff Chua <jeff84@silk.corp.fedex.com>.
17023
6d01d6b4 170242006-04-19 Roger Leigh <rleigh@whinlatter.ukfsn.org>
17025
17026 * DISTLIST: Added `util/powerpc/ieee1275/grub-install.in'.
17027
976a4ea0 170282006-04-19 Yoshinori K. Okuji <okuji@enbug.org>
17029
17030 * DISTLIST: Added include/grub/efi/console.h,
17031 include/grub/efi/time.h, include/grub/i386/efi/kernel.h,
17032 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
17033
17034 * include/grub/efi/console.h: New file.
17035 * include/grub/efi/time.h: Likewise.
17036 * include/grub/i386/efi/kernel.h: Likewise.
17037 * kern/efi/init.c: Likewise.
17038 * kern/efi/mm.c: Likewise.
17039 * term/efi/console.c: Likewise.
f19dbdb7 17040
976a4ea0 17041 * kern/i386/efi/init.c: Do not include grub/machine/time.h.
17042 (grub_stop): Removed.
17043 (grub_get_rtc): Likewise.
17044 (grub_machine_init): Simply call grub_efi_init.
17045 (grub_machine_fini): Call grub_efi_fini.
17046
17047 * kern/efi/efi.c: Include grub/machine/time.h and grub/term.h.
17048 (grub_efi_output_string): Removed.
17049 (grub_efi_stall): New function.
17050 (grub_stop): Likewise.
17051 (grub_get_rtc): Likewise.
17052
17053 * include/grub/efi/efi.h (grub_efi_output_string): Removed.
17054 (grub_efi_stall): New prototype.
17055 (grub_efi_allocate_pages): Likewise.
17056 (grub_efi_free_pages): Likewise.
17057 (grub_efi_get_memory_map): Likewise.
17058 (grub_efi_mm_init): Likewise.
17059 (grub_efi_mm_fini): Likewise.
17060 (grub_efi_init): Likewise.
17061 (grub_efi_fini): Likewise.
17062
17063 * include/grub/i386/efi/time.h: Do not include
17064 grub/symbol.h. Include grub/efi/time.h.
17065 (GRUB_TICKS_PER_SECOND): Removed.
17066 (grub_get_rtc): Likewise.
17067
17068 * include/grub/efi/api.h (struct grub_efi_memory_descriptor):
17069 Added padding. The EFI spec is buggy.
17070 (GRUB_EFI_BLACK): New macro.
17071 (GRUB_EFI_BLUE): Likewise.
17072 (GRUB_EFI_GREEN): Likewise.
17073 (GRUB_EFI_CYAN): Likewise.
17074 (GRUB_EFI_RED): Likewise.
17075 (GRUB_EFI_MAGENTA): Likewise.
17076 (GRUB_EFI_BROWN): Likewise.
17077 (GRUB_EFI_LIGHTGRAY): Likewise.
17078 (GRUB_EFI_BRIGHT): Likewise.
17079 (GRUB_EFI_DARKGRAY): Likewise.
17080 (GRUB_EFI_LIGHTBLUE): Likewise.
17081 (GRUB_EFI_LIGHTGREEN): Likewise.
17082 (GRUB_EFI_LIGHTCYAN): Likewise.
17083 (GRUB_EFI_LIGHTRED): Likewise.
17084 (GRUB_EFI_LIGHTMAGENTA): Likewise.
17085 (GRUB_EFI_YELLOW): Likewise.
17086 (GRUB_EFI_WHITE): Likewise.
17087 (GRUB_EFI_BACKGROUND_BLACK): Likewise.
17088 (GRUB_EFI_BACKGROUND_BLUE): Likewise.
17089 (GRUB_EFI_BACKGROUND_GREEN): Likewise.
17090 (GRUB_EFI_BACKGROUND_CYAN): Likewise.
17091 (GRUB_EFI_BACKGROUND_RED): Likewise.
17092 (GRUB_EFI_BACKGROUND_MAGENTA): Likewise.
17093 (GRUB_EFI_BACKGROUND_BROWN): Likewise.
17094 (GRUB_EFI_BACKGROUND_LIGHTGRAY): Likewise.
17095 (GRUB_EFI_TEXT_ATTR): Likewise.
17096
17097 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added kern/efi/efi.c,
17098 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
17099 (kernel_mod_HEADERS): Added efi/time.h.
17100
83709125 171012006-04-18 Yoshinori K. Okuji <okuji@enbug.org>
17102
17103 * DISTLIST: Added conf/i386-efi.mk, conf/i386-efi.rmk,
17104 include/grub/efi/api.h, include/grub/efi/console_control.h,
17105 include/grub/efi/efi.h, include/grub/efi/pe32.h,
17106 include/grub/i386/efi/time.h, kern/efi/efi.c,
17107 kern/i386/efi/init.c, kern/i386/efi/startup.S,
17108 and util/i386/efi/grub-mkimage.c.
17109
17110 * Makefile.in (RMKFILES): Added i386-efi.rmk.
17111
17112 * genmk.rb (PModule#rule): Do not export symbols if
17113 #{prefix}_EXPORTS is set to "no".
17114
17115 * conf/i386-efi.mk: New file.
17116 * conf/i386-efi.rmk: Likewise.
17117 * include/grub/efi/api.h: Likewise.
17118 * include/grub/efi/console_control.h: Likewise.
17119 * include/grub/efi/efi.h: Likewise.
17120 * include/grub/efi/pe32.h: Likewise.
17121 * include/grub/i386/efi/time.h: Likewise.
17122 * kern/efi/efi.c: Likewise.
17123 * kern/i386/efi/init.c: Likewise.
17124 * kern/i386/efi/startup.S: Likewise.
17125 * util/i386/efi/grub-mkimage.c: Likewise.
17126
171272006-04-17 Marco Gerards <marco@gnu.org>
bfa2bd9e 17128
17129 * include/grub/script.h: Include <grub/parser.h> and
17130 "grub_script.tab.h".
17131 (struct grub_lexer_param): New struct.
17132 (struct grub_parser_param): Likewise.
17133 (grub_script_create_arglist): Pass the state in an argument.
17134 (grub_script_add_arglist): Likewise.
17135 (grub_script_create_cmdline): Likewise.
17136 (grub_script_create_cmdblock): Likewise.
17137 (grub_script_create_cmdif): Likewise.
17138 (grub_script_create_cmdmenu): Likewise.
17139 (grub_script_add_cmd): Likewise.
17140 (grub_script_arg_add): Likewise.
17141 (grub_script_lexer_ref): Likewise.
17142 (grub_script_lexer_deref): Likewise.
17143 (grub_script_lexer_record_start): Likewise.
17144 (grub_script_lexer_record_stop): Likewise.
17145 (grub_script_mem_record): Likewise.
17146 (grub_script_mem_record_stop): Likewise.
17147 (grub_script_malloc): Likewise.
17148 (grub_script_yylex): Likewise.
17149 (grub_script_yyparse): Likewise.
17150 (grub_script_yyerror): Likewise.
17151 (grub_script_yylex): Likewise.
17152 (grub_script_lexer_init): Return the state.
17153
17154 * normal/lexer.c (grub_script_lexer_state): Removed variable.
17155 (grub_script_lexer_done): Likewise.
17156 (grub_script_lexer_getline): Likewise.
17157 (grub_script_lexer_refs): Likewise.
17158 (script): Likewise.
17159 (newscript): Likewise.
17160 (record): Likewise.
17161 (recording): Likewise.
17162 (recordpos): Likewise.
17163 (recordlen): Likewise.
17164 (grub_script_lexer_init): Return the state instead of setting
17165 global variables.
17166 (grub_script_lexer_ref): Use the newly added argument for state
17167 instead of globals.
17168 (grub_script_lexer_deref): Likewise.
17169 (grub_script_lexer_record_start): Likewise.
17170 (grub_script_lexer_record_stop): Likewise.
17171 (recordchar): Likewise.
17172 (nextchar): Likewise.
17173 (grub_script_yylex2): Likewise.
17174 (grub_script_yylex): Likewise.
17175 (grub_script_yyerror): Likewise.
17176
17177 * normal/parser.y (func_mem): Removed variable.
17178 (menu_entry): Likewise.
17179 (err): Likewise.
17180 (%lex-param): New parser option.
17181 (%parse-param): Likewise.
17182 (script): Always return the AST.
17183 (argument): Pass the state around.
17184 (arguments): Likewise.
17185 (grubcmd): Likewise.
17186 (commands): Likewise.
17187 (function): Likewise.
17188 (menuentry): Likewise.
17189 (if_statement): Likewise.
17190 (if): Likewise.
17191
17192 * normal/script.c (grub_script_memused): Removed variable.
17193 (grub_script_parsed): Likewise.
17194 (grub_script_malloc): Added a state argument. Use that instead of
17195 global variables.
17196 (grub_script_mem_record): Likewise.
17197 (grub_script_mem_record_stop): Likewise.
17198 (grub_script_arg_add): Likewise.
17199 (grub_script_add_arglist): Likewise.
17200 (grub_script_create_cmdline): Likewise.
17201 (grub_script_create_cmdif): Likewise.
17202 (grub_script_create_cmdmenu): Likewise.
17203 (grub_script_add_cmd): Likewise.
17204 (grub_script_parse): Setup the state before calling the parser.
f19dbdb7 17205
e2a8c904 172062006-04-16 Marco Gerards <marco@gnu.org>
6de2ee99 17207
17208 * normal/command.c (grub_command_init): Remove the title command.
17209
17210 * normal/lexer.c (grub_script_yylex): Renamed from this...
17211 (grub_script_yylex2): ... to this.
17212 (grub_script_yylex): New function. Temporary
17213 introduced to filter some tokens.
17214 (grub_script_yyerror): Print a newline.
17215
17216 * normal/main.c (read_config_file): Output information about the
17217 lines that contain errors. Wait for a key after all lines have
17218 been processed. Don't return an empty menu.
17219
17220 * normal/parser.y (func_mem): Don't initialize.
17221 (menu_entry): Likewise.
17222 (err): New variable.
17223 (script): Don't return anything when an error was encountered.
17224 (ws, returns): Removed rules.
17225 (argument): Disabled concatenated variable support.
17226 (arguments): Remove explicit separators.
17227 (grubcmd): Likewise.
17228 (function): Likewise.
17229 (menuentry): Likewise.
17230 (if): Likewise.
17231 (commands): Likewise. Add error handling.
17232
17233 * normal/script.c (grub_script_create_cmdline): If
17234 `grub_script_parsed' is 0, assume the parser encountered an error.
17235
c9a86192 172362006-04-02 Yoshinori K. Okuji <okuji@enbug.org>
17237
17238 * configure.ac: Add support for EFI. Fix the typo
17239 BUILD_LDDFLAGS. Restore the LDFLAGS after testing.
17240
70f3b243 172412006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
17242
17243 * util/unifont2pff.rb: Removed unnecessary byte ordering. Now
17244 foreign multibyte characters should be shown correctly.
17245
65f201ad 172462006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
17247
17248 * normal/main.c (grub_normal_menu_addentry): Fixed menu size
17249 calculation.
17250 (read_config_file): Made it to close file before returning.
17251
b4b93674 172522006-03-31 Vesa Jaaskelainen <chaac@nic.fi>
17253
17254 * DISTLIST: Added include/grub/i386/pc/vbeblit.h,
17255 include/grub/i386/pc/vbefill.h, video/i386/pc/vbeblit.c,
17256 video/i386/pc/vbefill.c.
17257
17258 * conf/i386-pc.rmk (vbe_mod_SOURCES): Added video/i386/pc/vbeblit.c,
17259 video/i386/pc/vbefill.c.
17260
17261 * include/grub/video.h (grub_video_blit_format): New enum.
17262 (grub_video_mode_info): Added new member blit_format.
17263 (grub_video_get_blit_format): New function prototype.
17264
17265 * include/grub/i386/pc/vbe.h (grub_video_vbe_get_video_ptr): New
17266 function prototype.
17267 (grub_video_vbe_map_rgb): Likewise.
17268 (grub_video_vbe_unmap_color): Likewise.
17269
17270 * include/grub/i386/pc/vbeblit.h: New file.
17271
17272 * include/grub/i386/pc/vbefill.h: New file.
17273
17274 * video/video.c (grub_video_get_blit_format): New function.
17275 (grub_video_vbe_get_video_ptr): Re-declared as non-static.
17276 (grub_video_vbe_map_rgb): Likewise.
17277 (grub_video_vbe_unmap_color): Likewise.
17278
17279 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Changed to use more
17280 optimized fills.
17281 (grub_video_vbe_blit_render_target): Changed to use more optimized
17282 blits.
17283 (grub_video_vbe_setup): Added detection for optimized settings.
17284 (grub_video_vbe_create_render_target): Likewise.
17285
17286 * video/i386/pc/vbeblit.c: New file.
17287
17288 * video/i386/pc/vbefill.c: New file.
17289
c2379b9c 172902006-03-30 Vesa Jaaskelainen <chaac@nic.fi>
17291
17292 * font/manager.c (grub_font_get_glyph): Removed font fixup from
17293 here...
17294
17295 * util/unifont2pff.rb: ... and moved it to here. Improved argument
17296 parsing to support both hex and dec ranges. If filename was missing
17297 show usage information.
17298
bd0d7896 172992006-03-14 Vesa Jaaskelainen <chaac@nic.fi>
17300
17301 * DISTLIST: Added include/grub/video.h, term/gfxterm.c,
17302 video/video.c, commands/videotest.c. Removed term/i386/pc/vesafb.c.
17303
17304 * conf/i386-pc.rmk (pkgdata_MODULES): Added video.mod,
17305 gfxterm.mod, videotest.mod. Removed vga.mod, vesafb.mod.
17306 (video_mod_SOURCES): Added.
17307 (video_mod_CFLAGS): Likewise.
17308 (video_mod_LDFLAGS): Likewise.
17309 (gfxterm_mod_SOURCES): Likewise.
17310 (gfxterm_mod_CFLAGS): Likewise.
17311 (gfxterm_mod_LDFLAGS): Likewise.
17312 (videotest_mod_SOURCES): Likewise.
17313 (videotest_mod_CFLAGS): Likewise.
17314 (videotest_mod_LDFLAGS): Likewise.
17315 (vesafb_mod_SOURCES): Removed.
17316 (vesafb_mod_CFLAGS): Likewise.
17317 (vesafb_mod_LDFLAGS): Likewise.
17318 (vga_mod_SOURCES): Likewise.
17319 (vga_mod_CFLAGS): Likewise.
17320 (vga_mod_LDFLAGS): Likewise.
17321
17322 * commands/videotest.c: New file.
17323
17324 * font/manager.c (fill_with_default_glyph): Modified to use
17325 grub_font_glyph.
17326 (grub_font_get_glyph): Likewise.
17327 (fontmanager): Renamed from this...
17328 (font_manager): ... to this.
17329
17330 * include/grub/font.h (grub_font_glyph): Added new structure.
17331 (grub_font_get_glyph): Modified to use grub_font_glyph.
17332
17333 * include/grub/misc.h (grub_abs): Added as inline function.
17334
17335 * include/grub/video.h: New file.
17336
17337 * include/grub/i386/pc/vbe.h (GRUB_VBE_STATUS_OK): New macro.
17338 (GRUB_VBE_MEMORY_MODEL_PACKED_PIXEL): Likewise.
17339 (GRUB_VBE_MEMORY_MODEL_DIRECT_COLOR): Likewise.
17340 (grub_vbe_get_controller_info): Renamed from this...
17341 (grub_vbe_bios_get_controller_info): ... to this.
17342 (grub_vbe_get_mode_info): Renamed from this...
17343 (grub_vbe_bios_get_mode_info): ... to this.
17344 (grub_vbe_set_mode): Renamed from this...
17345 (grub_vbe_bios_set_mode): ... to this.
17346 (grub_vbe_get_mode): Renamed from this...
17347 (grub_vbe_bios_get_mode): ... to this.
17348 (grub_vbe_set_memory_window): Renamed from this...
17349 (grub_vbe_bios_set_memory_window): ... to this.
17350 (grub_vbe_get_memory_window): Renamed from this...
17351 (grub_vbe_bios_get_memory_window): ... to this.
17352 (grub_vbe_set_scanline_length): Renamed from this...
17353 (grub_vbe_set_scanline_length): ... to this.
17354 (grub_vbe_get_scanline_length): Renamed from this...
17355 (grub_vbe_bios_get_scanline_length): ... to this.
17356 (grub_vbe_set_display_start): Renamed from this...
17357 (grub_vbe_bios_set_display_start): ... to this.
17358 (grub_vbe_get_display_start): Renamed from this...
17359 (grub_vbe_bios_get_display_start): ... to this.
17360 (grub_vbe_set_palette_data): Renamed from this...
17361 (grub_vbe_bios_set_palette_data): ... to this.
17362 (grub_vbe_set_pixel_rgb): Removed.
17363 (grub_vbe_set_pixel_index): Likewise.
17364
17365 * kern/i386/pc/startup.S (grub_vbe_get_controller_info): Renamed
17366 from this...
17367 (grub_vbe_bios_get_controller_info): ... to this.
17368 (grub_vbe_get_mode_info): Renamed from this...
17369 (grub_vbe_bios_get_mode_info): ... to this.
17370 (grub_vbe_set_mode): Renamed from this...
17371 (grub_vbe_bios_set_mode): ... to this.
17372 (grub_vbe_get_mode): Renamed from this...
17373 (grub_vbe_bios_get_mode): ... to this.
17374 (grub_vbe_set_memory_window): Renamed from this...
17375 (grub_vbe_bios_set_memory_window): ... to this.
17376 (grub_vbe_get_memory_window): Renamed from this...
17377 (grub_vbe_bios_get_memory_window): ... to this.
17378 (grub_vbe_set_scanline_length): Renamed from this...
17379 (grub_vbe_set_scanline_length): ... to this.
17380 (grub_vbe_get_scanline_length): Renamed from this...
17381 (grub_vbe_bios_get_scanline_length): ... to this.
17382 (grub_vbe_set_display_start): Renamed from this...
17383 (grub_vbe_bios_set_display_start): ... to this.
17384 (grub_vbe_get_display_start): Renamed from this...
17385 (grub_vbe_bios_get_display_start): ... to this.
17386 (grub_vbe_set_palette_data): Renamed from this...
17387 (grub_vbe_bios_set_palette_data): ... to this.
17388 (grub_vbe_bios_get_controller_info): Fixed problem with registers
17389 getting corrupted after calling it. Added more pushes and pops.
17390 (grub_vbe_bios_set_mode): Likewise.
17391 (grub_vbe_bios_get_mode): Likewise.
17392 (grub_vbe_bios_get_memory_window): Likewise.
17393 (grub_vbe_bios_set_scanline_length): Likewise.
17394 (grub_vbe_bios_get_scanline_length): Likewise.
17395 (grub_vbe_bios_get_display_start): Likewise.
17396 (grub_vbe_bios_set_palette_data): Likewise.
17397
17398 * normal/cmdline.c (cl_set_pos): Refresh the screen.
17399 (cl_insert): Likewise.
17400 (cl_delete): Likewise.
17401
17402 * term/gfxterm.c: New file.
17403
17404 * term/i386/pc/vesafb.c: Removed file.
17405
17406 * video/video.c: New file.
17407
17408 * video/i386/pc/vbe.c (real2pm): Added new function.
17409 (grub_video_vbe_draw_pixel): Likewise.
17410 (grub_video_vbe_get_video_ptr): Likewise.
17411 (grub_video_vbe_get_pixel): Likewise
17412 (grub_video_vbe_init): Likewise.
17413 (grub_video_vbe_fini): Likewise.
17414 (grub_video_vbe_setup): Likewise.
17415 (grub_video_vbe_get_info): Likewise.
17416 (grub_video_vbe_set_palette): Likewise.
17417 (grub_video_vbe_get_palette): Likewise.
17418 (grub_video_vbe_set_viewport): Likewise.
17419 (grub_video_vbe_get_viewport): Likewise.
17420 (grub_video_vbe_map_color): Likewise.
17421 (grub_video_vbe_map_rgb): Likewise.
17422 (grub_video_vbe_map_rgba): Likewise.
17423 (grub_video_vbe_unmap_color): Likewise.
17424 (grub_video_vbe_fill_rect): Likewise.
17425 (grub_video_vbe_blit_glyph): Likewise.
17426 (grub_video_vbe_blit_bitmap): Likewise.
17427 (grub_video_vbe_blit_render_target): Likewise.
17428 (grub_video_vbe_scroll): Likewise.
17429 (grub_video_vbe_swap_buffers): Likewise.
17430 (grub_video_vbe_create_render_target): Likewise.
17431 (grub_video_vbe_delete_render_target): Likewise.
17432 (grub_video_vbe_set_active_render_target): Likewise.
17433 (grub_vbe_set_pixel_rgb): Remove function.
17434 (grub_vbe_set_pixel_index): Likewise.
17435 (index_color_mode): Remove static variable.
17436 (active_mode): Likewise.
17437 (framebuffer): Likewise.
17438 (bytes_per_scan_line): Likewise.
17439 (grub_video_vbe_adapter): Added new static variable.
17440 (framebuffer): Likewise.
17441 (render_target): Likewise.
17442 (initial_mode): Likewise.
17443 (mode_in_use): Likewise.
17444 (mode_list): Likewise.
17445
5f97350b 174462006-03-10 Marco Gerards <marco@gnu.org>
17447
17448 * configure.ac (AC_INIT): Bumped to 1.93.
17449
17450 * DISTLIST: Added `include/grub/hfs.h'.
17451
a3c5c6f8 174522006-02-01 Yoshinori K. Okuji <okuji@enbug.org>
17453
17454 * boot/i386/pc/boot.S (general_error): Before looping, try INT
17455 18H, which might help the BIOS falling back to next boot media.
17456
6de53d26 174572006-01-25 Yoshinori K. Okuji <okuji@enbug.org>
17458
17459 * util/i386/pc/grub-install.in: Escape a backslash. Reported by
17460 Poe Chen <poe.poechen@gmail.com>.
17461
77c4a393 174622006-01-17 Marco Gerards <marco@gnu.org>
17463
17464 * include/grub/normal.h: Include <grub/script.h>.
17465 (grub_command_list): Removed struct.
17466 (grub_command_list_t): Removed type.
17467 (grub_menu_entry): Remove members `num' and `command_list'. Add
17468 members `commands' and `sourcecode'.
17469 * include/grub/script.h: Add inclusion guards.
17470 (grub_script_cmd_menuentry): New struct.
17471 (grub_script_execute_menuentry): New prototype.
17472 (grub_script_lexer_record_start): Likewise.
17473 (grub_script_lexer_record_stop): Likewise.
17474 * normal/execute.c (grub_script_execute_menuentry): New function.
17475 * normal/lexer.c (record, recording, recordpos, recordlen): New
17476 variables.
17477 (grub_script_lexer_record_start): New function.
17478 (grub_script_lexer_record_stop): Likewise.
17479 (recordchar): Likewise.
17480 (nextchar): Likewise.
17481 (grub_script_yylex): Use `nextchar' to fetch new characters. Use
17482 2048 as the buffer size. Add the tokens `menuentry' and `@'.
17483 * normal/main.c: Include <grub/parser.h> and <grub/script.h>
17484 (current_menu): New variable.
17485 (free_menu): Mainly rewritten.
17486 (grub_normal_menu_addentry): New function.
17487 (read_config_file): Rewritten.
17488 * normal/menu.c (run_menu_entry): Mainly rewritten.
fe987087 17489 * normal/menu_entry.c (make_screen): Rewritten the code to insert
77c4a393 17490 the menu entry.
17491 (run): Mainly rewritten.
17492 * normal/parser.y (menu_entry): New variable.
17493 (GRUB_PARSER_TOKEN_MENUENTRY): New token.
17494 (menuentry): New rule.
17495 (command): Add `menuentry'.
17496 (if_statement): Allow additional returns before `fi'.
17497 * normal/script.c (grub_script_create_cmdmenu): New function.
17498
144f1f98 174992006-01-03 Marco Gerards <marco@gnu.org>
17500
17501 * INSTALL: GNU Bison is required.
17502 * configure.ac: Rewritten the test to detect Bison.
17503 * Makefile.in (YACC): New variable. Reported by Xun Sun
17504 <xun.sun.cn@gmail.com>.
17505
af4b2d89 175062006-01-03 Marco Gerards <marco@gnu.org>
17507
17508 * fs/hfsplus.c (grub_hfsplus_read_block): Convert the offset of
17509 the HFS+ filesystem to filesystem blocks.
17510 (grub_hfsplus_iterate_dir): Cast the `fileinfo' assignment so a
17511 GCC warning is silenced.
17512
15643b71 175132006-01-03 Marco Gerards <marco@gnu.org>
17514
17515 * partmap/apple.c (apple_partition_map_iterate): Convert the data
17516 read from disk from big endian to host byte order.
17517
00905879 175182006-01-03 Hollis Blanchard <hollis@penguinppc.org>
17519
17520 * fs/hfs.c: Include <grub/hfs.h>. Added reference to the official
17521 documentation.
17522 (GRUB_HFS_EMBED_HFSPLUS_SIG): New macro.
17523 (grub_hfs_mount): Grammar fix in error. Make sure this is not an
17524 embedded HFS+ filesystem.
17525 (GRUB_HFS_MAGIC, grub_hfs_extent, grub_hfs_datarecord_t)
17526 (grub_hfs_sblock): Move from here...
17527 * include/grub/hfs.h: To here... New file.
17528 * fs/hfsplus.c: Include <grub/hfs.h>. Added reference to the official
17529 documentation.
17530 (GRUB_HFSPLUS_MAGIC, GRUB_HFSPLUSX_MAGIC, GRUB_HFSPLUS_SBLOCK):
17531 New macros.
17532 (grub_hfsplus_volheader): Change type of member `magic' to
17533 `grub_uint16_t'.
17534 (grub_hfsplus_data): Add new member `embedded_offset'.
17535 (grub_hfsplus_read_block): Add the HFS+ wrapper offset to the
17536 returned block.
17537 (grub_hfsplus_mount): Read the HFS+ wrapper if it exists.
17538 Calculate the offset.
17539
8899bc3e 175402005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
17541
17542 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRP_ADDR):
17543 Removed.
17544 (GRUB_BOOT_MACHINE_DRP_SIZE): Likewise.
17545
ae8c0277 175462005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
17547
17548 * kern/env.c (grub_env_set): Check if ENV->VALUE instead of
17549 ENV->NAME is NULL after allocating ENV->VALUE.
17550
07084456 175512005-12-25 Marco Gerards <marco@gnu.org>
17552
17553 * kern/env.c (grub_env_set): Rewritten the error handling code.
17554
4750f5f1 175552005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
17556
17557 * geninit.sh: Made more robust, and more portable.
17558
50214199 175592005-12-25 Marco Gerards <marco@gnu.org>
17560
17561 Add support for Apple HFS+ filesystems.
f19dbdb7 17562
50214199 17563 * fs/hfsplus.c: New file.
17564
17565 * DISTLIST: Added `fs/hfsplus.c'.
17566
17567 * conf/common.rmk (pkgdata_MODULES): Add `hfsplus.mod'.
17568 (hfsplus_mod_SOURCES): New variable.
17569 (hfsplus_mod_CFLAGS): Likewise.
17570 (hfsplus_mod_LDFLAGS): Likewise.
17571 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/hfsplus.c'.
17572 (grub_setup_SOURCES): Likewise.
17573 (grub_mkdevicemap_SOURCES): Likewise.
17574 (grub_emu_SOURCES): Likewise.
17575 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
17576
17577 * fs/fshelp.c (grub_fshelp_log2blksize): New function.
17578
17579 * include/grub/fshelp.h (grub_fshelp_log2blksize): new prototype.
17580
befaed6c 175812005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
17582
17583 * DISTLIST: Added geninitheader.sh, geninit.sh, commands/test.c,
17584 commands/i386/pc/play.c, conf/common.mk, conf/common.rmk,
17585 include/grub/parser.h, include/grub/script.h, kern/parser.c,
17586 kern/sparc64/cache.S, normal/execute.c, normal/function.c,
17587 normal/lexer.c, normal/parser.y, normal/script.c, and
17588 partmap/gpt.c.
17589 Removed kern/sparc64/cache.c.
17590
17591 * conf/common.rmk (DISTCLEANFILES): Added grub_script.tab.c,
17592 grub_script.tab.h, grub_modules_init.lst, grub_modules_init.h,
17593 grub_emu_init.c.
17594
17595 * configure.ac (AC_INIT): Bumped to 1.92.
17596
6a124103 175972005-12-24 Vesa Jaaskelainen <chaac@nic.fi>
17598
17599 * kern/err.c (grub_error_push): Added new function to support error
17600 stacks.
17601 (grub_error_pop): Likewise.
17602 (grub_error_stack_items): New local variable to support error stacks.
17603 (grub_error_stack_pos): Likewise.
17604 (grub_error_stack_assert): Likewise.
17605 (GRUB_ERROR_STACK_SIZE): Added new define to configure maximum error
17606 stack depth.
17607 (grub_print_error): Added support to print errors from error stack.
17608
17609 * include/grub/err.h (grub_error_push): Added function prototype.
17610 (grub_error_pop): Likewise.
17611
be973c1b 176122005-12-09 Hollis Blanchard <hollis@penguinppc.org>
17613
17614 * configure.ac: Accept `powerpc64' as host_cpu.
17615 (amd64): Rename to `biarch32'.
17616
17617 * kern/powerpc/cache.S (grub_arch_sync_caches): Handle
17618 non-cacheline-aligned addresses.
17619
17620 * kern/dl.c (grub_dl_load_core): Add grub_dprintf messages.
17621 (grub_dl_flush_cache): Likewise. Only call `grub_arch_sync_caches'
17622 if `size' is non-zero.
17623
b04216ab 176242005-12-03 Marco Gerards <mgerards@xs4all.nl>
17625
17626 * conf/common.rmk (grub_modules_init.lst): Use `-printf "%P\n"'
17627 and `cd' to make sure the filename is not prefixed with a
17628 directory name.
17629 (pkgdata_MODULES): Add `gpt.mod'.
17630 (gpt_mod_SOURCES): New variable.
17631 (gpt_mod_CFLAGS): Likewise.
17632 (gpt_mod_LDFLAGS): Likewise.
17633
17634 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/gpt.c'.
17635
17636 * include/grub/pc_partition.h (GRUB_PC_PARTITION_TYPE_GPT_DISK):
17637 New macro.
17638
17639 * partmap/gpt.c: New file.
17640
17641 * partmap/pc.c (pc_partition_map_iterate): Don't continue when a
17642 GPT partition map is detected.
17643
41730ed9 176442005-12-03 Vincent Pelletier <subdino2004@yahoo.fr>
17645
17646 * commands/i386/pc/play.c: New file.
17647 * conf/i386-pc.rmk (pkgdata_MODULES): Added play.mod.
17648 (play_mod_SOURCES, play_mod_CFLAGS, play_mod_LDFLAGS): New
17649 macros.
f19dbdb7 17650
95dc3643 176512005-11-27 Marco Gerards <mgerards@xs4all.nl>
17652
17653 * include/grub/dl.h (GRUB_MOD_INIT): Use `__attribute__
17654 ((unused))' to silence gcc warning.
17655
1569ec51 176562005-11-26 Hollis Blanchard <hollis@penguinppc.org>
17657
17658 * configure.ac: Correct `AC_PROG_YACC' test.
17659
9abde152 176602005-11-22 Hollis Blanchard <hollis@penguinppc.org>
17661
17662 * util/powerpc/ieee1275/grub-install.in: Run the mount point
17663 check before installing files.
17664
44b83271 176652005-11-22 Mike Small <smallm@panix.com>
17666
17667 * util/powerpc/ieee1275/grub-install.in (grubdir): Fixed partition
17668 number regex so multidigit numbers are recognized correctly.
17669
176702005-11-22 Mike Small <smallm@panix.com>
17671
17672 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Add a
17673 debugging message before attempting to claim memory.
17674 (grub_rescue_cmd_initrd): Add a claim debugging message and try
17675 multiple addresses in case of failure.
17676
9c12956b 176772005-11-22 Hollis Blanchard <hollis@penguinppc.org>
17678
17679 * term/tparm.c (get_space): Remove empty `if' statement.
17680
17681 * fs/ufs.c (grub_ufs_find_file): Remove `grub_le_to_cpu32'.
17682
17683 * kern/parser.c (check_varstate): Rename `state' to 's'.
17684
aeaf81d9 176852005-11-22 Hollis Blanchard <hollis@penguinppc.org>
17686
17687 * partmap/acorn.c: Change `unsigned' to `unsigned int'. Move all
17688 variable definitions to the beginning of each function. Sort stack
17689 variables by size.
17690 (find): Rename to `acorn_partition_map_find'. Cast `grub_disk_read'
17691 `buf' argument to `char *'.
17692
79bbb63f 176932005-11-22 Hollis Blanchard <hollis@penguinppc.org>
17694
17695 * conf/powerpc-ieee1275.rmk: Include conf/common.mk.
17696 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
fe6b695a 17697 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
79bbb63f 17698 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
17699 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
17700 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
17701 configfile.mod, search.mod, gzio.mod and test.mod.
17702 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
17703 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
17704 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
17705 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
17706 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
17707 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
17708 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
17709 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
17710 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
17711 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
17712 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
17713 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
17714 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
17715 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
17716 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
17717 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
17718 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
17719 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
17720 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
17721 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
17722 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
17723 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
17724 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Removed.
17725
17726 * conf/common.mk (grub_modules_init.lst): Use `find' instead of
17727 `grep --include'.
17728 (pkgdata_MODULES): Add test.mod.
17729
233b1628 177302005-11-18 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17731
17732 * genmk.rb: Fixed list rules moved to Makefile.in. Recognise
17733 appending to variables with "+=".
17734 (PModule): Use full pathname to generate *.lst filenames.
17735
17736 * Makefile.in: Fixed list rules moved from genmk.rb.
17737 (.DELETE_ON_ERROR): New special target.
17738 (RMKFILES): Add common.rmk and sparc64-ieee1275.rmk.
17739
17740 * conf/i386-pc.rmk: Include conf/common.mk.
17741 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
fe6b695a 17742 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
233b1628 17743 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
17744 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
17745 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
17746 configfile.mod, search.mod, gzio.mod and test.mod.
17747 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
17748 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
17749 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
17750 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
17751 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
17752 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
17753 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
17754 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
17755 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
17756 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
17757 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
17758 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
17759 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
17760 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
17761 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
17762 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
17763 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
17764 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
17765 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
17766 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
17767 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
17768 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
17769 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Move from
17770 here...
17771 * conf/common.rmk: ... to here. New file.
17772
17773 * conf/common.mk: New file.
17774
16f820c8 177752005-11-18 Yoshinori K. Okuji <okuji@enbug.org>
17776
17777 * conf/powerpc-ieee1275.rmk (grub_script.tab.h): Unified to ...
17778 (grub_script.tab.c): ... here.
17779
17780 * conf/sparc64-ieee1275.rmk (grub_script.tab.h): Unified to ...
17781 (grub_script.tab.c): ... here.
17782
17783 * conf/i386-pc.rmk (grub_script.tab.h): Unified to ...
17784 (grub_script.tab.c): ... here.
17785
17786 * normal/command.c (grub_command_find): Fixed a memory leak of
17787 MODULE_NAME. Reported by Mike Small <smallm@panix.com>.
17788
63ba1554 177892005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17790
17791 * include/grub/symbol.h: (FUNCTION): Use double quotes instead of
17792 "@" which marks the start of a comment on ARM.
17793 (VARIABLE): Likewise.
17794
7f67dc13 177952005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17796
79bbb63f 17797 Add support for Linux/ADFS partition tables.
7f67dc13 17798
17799 * partmap/acorn.c: New file.
17800
17801 * include/grub/acorn_filecore.h: Likewise.
17802
17803 * DISTLIST: Added `partmap/acorn.c' and
17804 `include/grub/acorn_filecore.h'.
f19dbdb7 17805
7f67dc13 17806 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
17807 `partmap/acorn.c'.
17808 (pkgdata_MODULES): Add `acorn.mod'.
17809 (acorn_mod_SOURCES): New variable.
17810 (acorn_mod_CFLAGS): Likewise.
17811
17812 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
17813 `partmap/acorn.c'.
17814 (pkgdata_MODULES): Add `acorn.mod'.
17815 (acorn_mod_SOURCES): New variable.
17816 (acorn_mod_CFLAGS): Likewise.
17817
17818 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/acorn.c'.
17819 (pkgdata_MODULES): Add `acorn.mod'.
17820 (acorn_mod_SOURCES): New variable.
17821 (acorn_mod_CFLAGS): Likewise.
17822 (acorn_mod_LDFLAGS): Likewise.
17823
17824 * include/types.h (grub_disk_addr_t): New typedef.
17825
6d099807 178262005-11-13 Marco Gerards <mgerards@xs4all.nl>
17827
17828 * geninit.sh: New file.
17829
17830 * geninitheader.sh: Likewise.
17831
17832 * commands/boot.c (grub_boot_init, grub_boot_fini): Removed.
17833 * commands/cat.c (grub_cat_init, grub_cat_fini): Likewise.
17834 * commands/cmp.c (grub_cmp_init, grub_cmp_fini): Likewise.
17835 * commands/configfile.c (grub_configfile_init)
17836 (grub_configfile_fini): Likewise.
17837 * commands/default.c (grub_default_init, grub_default_fini):
17838 Likewise.
17839 * commands/help.c (grub_help_init, grub_help_fini): Likewise.
17840 * commands/ls.c (grub_ls_init, grub_ls_fini): Likewise.
17841 * commands/search.c (grub_search_init, grub_search_fini): Likewise.
17842 * commands/terminal.c (grub_terminal_init, grub_terminal_fini):
17843 Likewise.
17844 * commands/test.c (grub_test_init, grub_test_fini): Likewise.
17845 * commands/timeout.c (grub_timeout_init, grub_timeout_fini):
17846 Likewise.
17847 * commands/i386/pc/halt.c (grub_halt_init, grub_halt_fini): Likewise.
fe6b695a 17848 * commands/ieee1275/halt.c (grub_halt_init, grub_halt_fini):
6d099807 17849 Likewise.
17850 * commands/i386/pc/reboot.c (grub_reboot_init, grub_reboot_fini):
17851 Likewise.
fe6b695a 17852 * commands/ieee1275/reboot.c (grub_reboot_init, grub_reboot_fini):
6d099807 17853 Likewise.
17854 * disk/loopback.c (grub_loop_init, grub_loop_fini): Likewise.
17855 * fs/affs.c (grub_affs_init, grub_affs_fini): Likewise.
17856 * fs/ext2.c (grub_ext2_init, grub_ext2_fini): Likewise.
17857 * fs/fat.c (grub_fat_init, grub_fat_fini): Likewise.
17858 * fs/hfs.c (grub_hfs_init, grub_hfs_fini): Likewise.
17859 * fs/iso9660.c (grub_iso9660_init, grub_iso9660_fini): Likewise.
17860 * fs/jfs.c (grub_jfs_init, grub_jfs_fini): Likewise.
17861 * fs/minix.c (grub_minix_init, grub_minix_fini): Likewise.
17862 * fs/sfs.c (grub_sfs_init, grub_sfs_fini): Likewise.
17863 * fs/ufs.c (grub_ufs_init, grub_ufs_fini): Likewise.
17864 * fs/xfs.c (grub_xfs_init, grub_xfs_fini): Likewise.
17865 * normal/main.c (grub_normal_init, grub_normal_fini): Likewise.
17866 * partmap/amiga.c (grub_amiga_partition_map_init)
17867 (grub_amiga_partition_map_fini): Likewise.
17868 * partmap/apple.c (grub_apple_partition_map_init)
17869 (grub_apple_partition_map_fini): Likewise.
17870 * partmap/pc.c (grub_pc_partition_map_init)
17871 (grub_pc_partition_map_fini): Likewise.
17872 * partmap/sun.c (grub_sun_partition_map_init,
17873 grub_sun_partition_map_fini): Likewise.
17874 * term/terminfo.c (grub_terminal_init, grub_terminal_fini):
17875 Likewise.
17876
17877 * util/grub-emu.c: Include <grub_modules_init.h>.
17878 (main): Don't initialize and de-initialize any modules directly,
17879 use `grub_init_all' and `grub_fini_all' instead.
17880
17881 * term/i386/pc/vesafb.c (grub_vesafb_init): Renamed to
17882 `grub_vesafb_mod_init'.
17883 (grub_vesafb_fini): Renamed to `grub_vesafb_mod_fini'. Updated
17884 all users.
17885 * term/i386/pc/vga.c (grub_vga_init): Renamed to
17886 `grub_vga_mod_init'. Updated all users.
17887 (grub_vga_fini): Renamed to `grub_vga_mod_fini'.
f19dbdb7 17888
6d099807 17889 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `grub_emu_init.c'.
17890 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c): New
17891 rules.
17892
17893 * include/grub/dl.h (GRUB_MOD_INIT): Add argument `name'.
17894 Generate a function to initialize the module in utilities.
17895 Updated all callers.
17896 (GRUB_MOD_FINI): Add argument `name'. Generate a function to
17897 initialize the module in utilities. Updated all callers.
17898
9046bcf0 178992005-11-09 Hollis Blanchard <hollis@penguinppc.org>
17900
17901 * term/ieee1275/ofconsole.c (grub_ofconsole_cls): Use both the ANSI
17902 escape sequence and a literal ^L to clear the screen.
17903
17904 * commands/ieee1275/suspend.c (grub_cmd_suspend): Clear the screen
17905 when returning from Open Firmware.
17906
d13ea639 179072005-11-09 Hollis Blanchard <hollis@penguinppc.org>
17908
17909 * term/ieee1275/ofconsole.c (grub_ofconsole_width): New variable.
17910 (grub_ofconsole_height): Likewise.
17911 (grub_ofconsole_putchar): If `grub_curr_x' exceeds console width,
17912 manually insert a '\n'.
17913 (grub_ofconsole_getwh): Set and return `grub_ofconsole_width' and
17914 `grub_ofconsole_height'. Return early if these are already set.
17915
a8fcf206 179162005-11-07 Vincent Pelletier <subdino2004@yahoo.fr>
17917
17918 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
17919 `commands/test.c', `fs/affs.c', `fs/sfs.c', `fs/xfs.c',
17920 `normal/execute.c', `normal/lexer.c', `io/gzio.c',
17921 `kern/parser.c', `grub_script.tab.c', `normal/function.c'
17922 and `normal/script.c'.
17923 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
17924 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
17925 (test_mod_SOURCES): New variable.
17926 (test_mod_CFLAGS): Likewise.
17927 (test_mod_LDFLAGS): Likewise.
17928 (pkgdata_MODULES): Add `test.mod'.
17929 (grub_script.tab.c): New rule.
17930 (grub_script.tab.h): Likewise.
17931
b6b32745 179322005-11-07 Marco Gerards <mgerards@xs4all.nl>
17933
17934 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
17935 `commands/test.c', `normal/execute.c', `normal/lexer.c',
17936 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
17937 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
17938 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
17939 (test_mod_SOURCES): New variable.
17940 (test_mod_CFLAGS): Likewise.
17941 (pkgdata_MODULES): Add `test.mod'.
17942 (grub_script.tab.c): New rule.
17943 (grub_script.tab.h): Likewise.
17944
daac212a 179452005-11-06 Marco Gerards <mgerards@xs4all.nl>
17946
17947 Add initial scripting support.
17948
17949 * commands/test.c: New file.
17950 * include/grub/script.h: Likewise.
17951 * normal/execute.c: Likewise.
17952 * normal/function.c: Likewise.
17953 * normal/lexer.c: Likewise.
17954 * normal/parser.y: Likewise.
17955 * normal/script.c: Likewise.
17956
17957 * configure.ac: Add `AC_PROG_YACC' test.
f19dbdb7 17958
daac212a 17959 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/test.c',
17960 `normal/execute.c', `normal/lexer.c', `grub_script.tab.c',
17961 `normal/function.c' and `normal/script.c'.
17962 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
17963 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
b6b32745 17964 (test_mod_SOURCES, test_mod_CFLAGS, test_mod_LDFLAGS): New
17965 variables.
daac212a 17966 (pkgdata_MODULES): Add `test.mod'.
17967 (grub_script.tab.c): New rule.
17968 (grub_script.tab.h): Likewise.
17969
17970 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TEST_FAILURE'.
17971
17972 * include/grub/normal.h (grub_test_init): New prototype.
17973 (grub_test_fini): Likewise.
f19dbdb7 17974
daac212a 17975 * normal/command.c: Include <grub/script.h>.
17976 (grub_command_execute): Rewritten.
f19dbdb7 17977
daac212a 17978 * util/grub-emu.c (main): Call `grub_test_init' and
17979 `grub_test_fini'.
17980
77500b2b 179812005-11-03 Hollis Blanchard <hollis@penguinppc.org>
17982
17983 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Initialize `msecs'
17984 to 0.
17985 * term/ieee1275/ofconsole.c (grub_ofconsole_checkkey): Return -1 if
17986 there are no pending characters.
17987
e45deb9e 179882005-11-03 Hollis Blanchard <hollis@penguinppc.org>
17989
17990 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_get_devname): Use
17991 `grub_strndup' to drop device arguments. Replace unnecessary
17992 `grub_strndup' with `grub_strdup'.
17993
4ce32619 179942005-11-03 Hollis Blanchard <hollis@penguinppc.org>
17995
17996 * kern/term.c (grub_cls): Do not call grub_cur_term->cls() if the
17997 `debug' environment variable has been set.
17998
179992005-11-02 Hollis Blanchard <hollis@penguinppc.org>
f19dbdb7 18000
4ce32619 18001 * Makefile.in (install-local): Use $(DATA).
18002 (uninstall): Likewise.
18003 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Move grub-mkimage...
18004 (sbin_UTILITIES): ... to here.
18005 (sbin_SCRIPTS): New variable.
18006 (grub_install_SOURCES): New variable.
18007 * util/powerpc/ieee1275/grub-install.in: New file.
18008 * util/powerpc/ieee1275/grub-mkimage.c (kernel_path): Remove
18009 variable.
18010 (add_segments): Call `grub_util_get_path'.
18011
25fe6f03 180122005-10-28 Yoshinori K. Okuji <okuji@enbug.org>
18013
18014 From Timothy Baldwin:
18015 * commands/ls.c (grub_ls_list_files): Close FILE with
18016 grub_file_close.
18017 * kern/misc.c (grub_vsprintf): Terminate the string S with NUL.
18018
04ccf3ec 180192005-10-24 Marco Gerards <mgerards@xs4all.nl>
18020
18021 * include/grub/parser.h: New file.
18022
18023 * kern/parser.c: Likewise.
18024
18025 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/parser.c'.
18026 (grub_setup_SOURCES): Likewise.
18027 (grub_probefs_SOURCES): Likewise.
18028 (grub_emu_SOURCES): Likewise.
18029 (kernel_img_HEADERS): Add `parser.h'.
18030
18031 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
18032 (grub_emu_SOURCES): Add `kern/parser.c'.
18033 (grubof_SOURCES): Likewise.
18034
18035 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
18036 (grubof_SOURCES): Add `kern/parser.c'.
18037
18038 * include/grub/misc.h (grub_split_cmdline): Removed prototype.
18039
18040 * kern/misc.c (grub_split_cmdline): Removed function.
18041
18042 * kern/rescue.c: Include <grub/parser.h>.
18043 (grub_enter_rescue_mode): Use `grub_parser_split_cmdline' instead
18044 of `grub_split_cmdline'.
18045
18046 * normal/command.c: Include <grub/parser.h>.
18047 (grub_command_execute): Use `grub_parser_split_cmdline' instead
18048 of `grub_split_cmdline'.
18049
18050 * normal/completion.c: Include <grub/parser.h>.
18051 (cmdline_state): New variable.
18052 (iterate_dir): End the filename with a quote depending on the
18053 command line state.
18054 (get_state): new function.
18055 (grub_normal_do_completion): Use `grub_parser_split_cmdline' to
18056 split the arguments and determine the current argument. When the
18057 argument string is not quoted, escape all spaces.
18058
6d8f4b0e 180592005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
18060
18061 * normal/sparc64/setjmp.S: New file.
18062
15cf03ed 180632005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
18064
18065 * include/grub/sparc64/libgcc.h: New file.
18066 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Remove -Av9.
18067 (normal_mod_SOURCES): Use normal/sparc64/setjmp.S instead of
18068 normal/sparc64/setjmp.c.
18069
03e8661a 180702005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
18071
18072 * kern/sparc64/dl.c: Rewritten for SPARCV9 ELF.
18073 * kern/sparc64/cache.S: New file.
18074 * kern/sparc64/cache.c: Removed.
18075 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Add -Av9.
18076 (COMMON_CFLAGS): Add -mno-app-regs. Remove -mcpu=v9 and
18077 -mtune=ultrasparc.
18078 (COMMON_LDFLAGS): Add -melf64_sparc.
18079 (grubof_HEADERS): Add sparc64/libgcc.h and machine/kernel.h.
18080 (grubof_SOURCES): Use cache.S instead of cache.c.
18081 (grubof_LDFLAGS): Add -mno-app-regs. Replace "-Xlinker
18082 --oformat -Xlinker elf64-sparc" by "-Bstatic,-melf64_sparc".
18083 (pkgdata_MODULES): Uncomment. Leave linux.mod and _linux.mod
18084 commented though.
18085 (normal_mod_SOURCES): Add normal/completion.c and normal/misc.c.
18086 (_linux_mod_SOURCES, _linux_mod_CFLAGS, linux_mod_SOURCES)
18087 (linux_mod_CFLAGS): Commented out.
18088 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS): New macro, commented
18089 out because module isn't built.
18090 (fshelp_mod_LDFLAGS, fat_mod_LDFLAGS, ext2_mod_LDFLAGS)
18091 (ufs_mod_LDFLAGS, minix_mod_LDFLAGS, hfs_mod_LDFLAGS)
18092 (jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS, normal_mod_LDFLAGS)
18093 (hello_mod_LDFLAGS, boot_mod_LDFLAGS, terminal_mod_LDFLAGS)
18094 (ls_mod_LDFLAGS, cmp_mod_LDFLAGS, cat_mod_LDFLAGS)
18095 (font_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
18096 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
18097 (suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS)
18098 (help_mod_LDFLAGS, default_mod_LDFLAGS, timeout_mod_LDFLAGS)
18099 (configfile_mod_LDFLAGS, search_mod_LDFLAGS, xfs_mod_SOURCES)
18100 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
18101 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
18102 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, gzio_mod_SOURCES)
18103 (gzio_mod_CFLAGS, gzio_mod_LDFLAGS): New macro.
18104
34eeec8a 181052005-10-20 Yoshinori K. Okuji <okuji@enbug.org>
18106
18107 * util/i386/pc/grub-probefs.c (main): Call grub_xfs_init and
18108 grub_xfs_fini. Do not call grub_hfs_init or grub_hfs_fini any
18109 longer, because HFS should not be used on PC.
18110
708367a3 181112005-10-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
18112
18113 * io/gzio.c (grub_gzio_read): Use OFFSET instead of FILE->OFFSET
18114 consistently within the loop.
18115
6fa1251a 181162005-10-15 Marco Gerards <mgerards@xs4all.nl>
18117
18118 * fs/xfs.c (grub_xfs_iterate_dir): Detect an error if part of a
18119 directory can not be read.
18120
4801580b 181212005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
18122
18123 * configure.ac (AC_INIT): Increase the version number to 1.91.
18124
18125 * DISTLIST: Added include/grub/terminfo.h, include/grub/tparm.h,
18126 include/grub/i386/pc/serial.h, term/terminfo.c, term/tparm.c and
18127 term/i386/pc/serial.c.
18128
219ad426 181292005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
18130
18131 * kern/file.c (grub_file_seek): Seeking to an offset equal to a
18132 file size must be permitted.
18133
18134 * kern/i386/pc/startup.S (multiboot_trampoline): Fix a mistake
18135 between %ah and %al.
18136
688e5699 181372005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
18138
18139 * fs/xfs.c (grub_xfs_iterate_dir): Change the type of BLK to
18140 grub_uint64_t.
18141 Call the hook with a NUL-terminated filename.
18142 (grub_xfs_mount): Use grub_be_to_cpu32 instead of
18143 grub_cpu_to_be32.
18144
18145 * kern/term.c (cursor_state): New variable.
18146 (grub_term_set_current): Reset the cursor state on a new
18147 terminal.
18148 (grub_setcursor): Rewritten to use CURSOR_STATE.
18149 (grub_getcursor): New function.
18150
18151 * include/grub/term.h (grub_getcursor): New prototype.
18152
18153 * io/gzio.c (test_header): Align BUF for accessing it as 32-bit
18154 integers on ARM. Reported by Timothy Baldwin
18155 <T.E.Baldwin99@members.leeds.ac.uk>.
18156
bb34586c 181572005-10-11 Marco Gerards <mgerards@xs4all.nl>
18158
18159 * fs/sfs.c (grub_sfs_open): Don't free `data->label' if it is not
18160 allocated.
18161 (grub_sfs_dir): Likewise.
18162
9a909877 181632005-10-09 Marco Gerards <mgerards@xs4all.nl>
18164
18165 Add support for the SFS filesystem.
18166
18167 * fs/sfs.c: New file.
18168
18169 * DISTLIST: Added `fs/sfs.c'.
18170
18171 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/sfs.c'.
18172 (grub_probefs_SOURCES): Likewise.
18173 (grub_emu_SOURCES): Likewise.
18174 (pkgdata_MODULES): Add `sfs.mod'.
18175 (sfs_mod_SOURCES): New variable.
18176 (sfs_mod_CFLAGS): Likewise.
18177 (sfs_mod_LDFLAGS): Likewise.
18178
18179 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/sfs.c'.
18180 (pkgdata_MODULES): Add `sfs.mod'.
18181 (sfs_mod_SOURCES): New variable.
18182 (sfs_mod_CFLAGS): Likewise.
18183
18184 * util/grub-emu.c (main): Call `grub_sfs_init' and
18185 `grub_sfs_fini'.
18186
18187 * include/grub/fs.h (grub_sfs_init): New prototype.
18188 (grub_sfs_fini): Likewise.
18189
57bdbde3 181902005-10-07 Marco Gerards <mgerards@xs4all.nl>
18191
18192 Add support for the AFFS filesystem.
18193
18194 * fs/affs.c: New file.
18195
18196 * DISTLIST: Added `fs/affs.c'.
18197
18198 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/affs.c'.
18199 (grub_probefs_SOURCES): Likewise.
18200 (grub_emu_SOURCES): Likewise.
18201 (pkgdata_MODULES): Add `affs.mod'.
18202 (affs_mod_SOURCES): New variable.
18203 (affs_mod_CFLAGS): Likewise.
18204 (affs_mod_LDFLAGS): Likewise.
18205
18206 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/affs.c'.
18207 (pkgdata_MODULES): Add `affs.mod'.
18208 (affs_mod_SOURCES): New variable.
18209 (affs_mod_CFLAGS): Likewise.
18210
18211 * util/grub-emu.c (main): Call `grub_affs_init' and
18212 `grub_affs_fini'.
18213
18214 * include/grub/fs.h (grub_affs_init): New prototype.
18215 (grub_affs_fini): Likewise.
18216
047b67e0 182172005-10-01 Marco Gerards <mgerards@xs4all.nl>
18218
18219 * fs/xfs.c (grub_xfs_iterate_dir): Add parentheses.
18220
59b8208a 182212005-10-01 Marco Gerards <mgerards@xs4all.nl>
18222
18223 * configure.ac: Accept `x86_64' as host_cpu. In that case add
18224 `-m32' to CFLAGS.
18225
18226 * genmk.rb (class PModule): Always use `$(#{prefix}_LDFLAGS)' when
18227 linking.
f19dbdb7 18228
59b8208a 18229 * conf/i386-pc.rmk (COMMON_CFLAGS): Add `-m32'.
18230 (COMMON_LDFLAGS): New variable.
18231 (kernel_img_LDFLAGS): Include `COMMON_FLAGS'.
18232 (_chain_mod_LDFLAGS, fshelp_mod_LDFLAGS, fat_mod_LDFLAGS)
18233 (ext2_mod_LDFLAGS, ufs_mod_LDFLAGS, minix_mod_LDFLAGS)
18234 (hfs_mod_LDFLAGS, jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS)
18235 (xfs_mod_LDFLAGS, _linux_mod_LDFLAGS, linux_mod_LDFLAGS)
18236 (normal_mod_LDFLAGS, hello_mod_LDFLAGS, boot_mod_LDFLAGS)
18237 (terminal_mod_LDFLAGS, ls_mod_LDFLAGS, cmp_mod_LDFLAGS)
18238 (cat_mod_LDFLAGS, help_mod_LDFLAGS, reboot_mod_LDFLAGS)
18239 (halt_mod_LDFLAGS, vga_mod_LDFLAGS, font_mod_LDFLAGS)
18240 (terminfo_mod_LDFLAGS, serial_mod_LDFLAGS, _multiboot_mod_LDFLAGS)
18241 (multiboot_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
18242 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
18243 (default_mod_LDFLAGS, timeout_mod_LDFLAGS, configfile_mod_LDFLAGS)
18244 (vbe_mod_LDFLAGS, vesafb_mod_LDFLAGS, vbeinfo_mod_LDFLAGS)
18245 (vbetest_mod_LDFLAGS, search_mod_LDFLAGS, gzio_mod_LDFLAGS): New
18246 variables.
18247 (normal_mod_ASFLAGS): Add `-m32'.
18248
18249 * include/grub/types.h (grub_host_addr_t, grub_host_off_t)
18250 (grub_host_size_t, grub_host_ssize_t): New types.
18251 (grub_addr_t, grub_off_t, grub_size_t, grub_ssize_t): Make type
fe6b695a 18252 dependent of `GRUB_CPU_SIZEOF_VOID_P' instead on
59b8208a 18253 `GRUB_HOST_SIZEOF_VOID_P'.
18254
18255 * include/grub/kernel.h (struct grub_module_header): Type of
18256 member offset changed to `grub_host_off_t'. Type of member size
18257 changed to `grub_host_size_t'.
18258 (struct grub_module_info): Type of member offset changed to
18259 `grub_host_off_t'. Type of member size changed to
18260 `grub_host_size_t'.
18261
b4093103 182622005-09-29 Yoshinori K. Okuji <okuji@enbug.org>
18263
18264 Make GRUB's kernel compliant to Multiboot Specification.
f19dbdb7 18265
b4093103 18266 * kern/i386/pc/startup.S (multiboot_header): New label.
18267 (multiboot_entry): Likewise.
18268 (multiboot_trampoline): Likewise.
18269
18270 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
18271 Increased to 0x4A0.
18272
18273 * fs/xfs.c (grub_xfs_iterate_dir): Fix a syntax error. You may not
18274 put parentheses after a question mark.
18275 [!GRUB_UTIL] (my_mod): New variable.
18276
18277 * util/grub-emu.c (main): Call grub_xfs_init and grub_xfs_fini.
18278
b2499b29 182792005-09-28 Marco Gerards <mgerards@xs4all.nl>
18280
18281 Adds support for the XFS filesystem. Btrees are not supported
18282 yet.
18283
18284 * fs/xfs.c: New file.
18285
18286 * DISTLIST: Added `fs/xfs.c'.
18287
18288 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/xfs.c'.
18289 (grub_probefs_SOURCES): Likewise.
18290 (grub_emu_SOURCES): Likewise.
18291 (pkgdata_MODULES): Add `xfs.mod'.
18292 (xfs_mod_SOURCES): New variable.
18293 (xfs_mod_CFLAGS): Likewise.
18294
18295 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/xfs.c'.
18296 (pkgdata_MODULES): Add `xfs.mod'.
18297 (xfs_mod_SOURCES): New variable.
18298 (xfs_mod_CFLAGS): Likewise.
18299
18300 * util/grub-emu.c (main): Call `grub_xfs_init' and
18301 `grub_xfs_fini'.
18302
18303 * include/grub/fs.h (grub_xfs_init): New prototype.
18304 (grub_xfs_fini): Likewise.
18305
f19dbdb7 18306
83d37a62 183072005-09-18 Vesa Jaaskelainen <chaac@nic.fi>
18308
18309 * video/i386/pc/vbe.c (grub_vbe_set_video_mode): In indexed
18310 color modes, allow greater than 16 colors to be configured as
18311 a default palette.
18312
47d2d65e 183132005-09-03 Yoshinori K. Okuji <okuji@enbug.org>
18314
18315 * normal/completion.c (complete_arguments): Add the qualifier
18316 const into OPTIONS.
18317
18318 From Omniflux <omniflux+lists@omniflux.com>:
18319 * include/grub/terminfo.h: New file.
18320 * include/grub/tparm.h: Likewise.
18321 * include/grub/i386/pc/serial.h: Likewise.
18322 * term/terminfo.c: Likewise.
18323 * term/tparm.c: Likewise.
18324 * term/i386/pc/serial.c: Likewise.
18325 * conf/i386-pc.rmk (pkgdata_MODULES): Added terminfo.mod and
18326 serial.mod.
18327 (terminfo_mod_SOURCES): New variable.
18328 (terminfo_mod_CFLAGS): Likewise.
18329 (serial_mod_SOURCES): Likewise.
18330 (serial_mod_CFLAGS): Likewise.
18331
48b671ff 183322005-08-31 Yoshinori K. Okuji <okuji@enbug.org>
18333
18334 * DISTLIST: Replaced boot/powerpc/ieee1275/crt0.S and
18335 boot/powerpc/ieee1275/cmain.c with kern/powerpc/ieee1275/crt0.S
18336 and kern/powerpc/ieee1275/cmain.c, respectively.
18337
18338 * boot/powerpc/ieee1275/crt0.S: Moved to ...
18339 * kern/powerpc/ieee1275/crt0.S: ... here.
18340
18341 * boot/powerpc/ieee1275/cmain.c: Moved to ...
18342 * kern/powerpc/ieee1275/cmain.c: ... here.
f19dbdb7 18343
48b671ff 18344 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Use
18345 kern/powerpc/ieee1275/crt0.S and kern/powerpc/ieee1275/cmain.c
18346 instead of boot/powerpc/ieee1275/crt0.S and
18347 boot/powerpc/ieee1275/cmain.c, respectively.
18348
18349 * boot/i386/pc/boot.S (lba_mode): Do not store the total number of
18350 sectors. It was not used anyway.
18351
09fc77a7 183522005-08-30 Hollis Blanchard <hollis@penguinppc.org>
18353
18354 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): Fix
18355 `unused parameter' warning.
18356
003789c7 183572005-08-30 Hollis Blanchard <hollis@penguinppc.org>
18358
18359 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): New
18360 function.
18361 (grub_ofconsole_term): Specify grub_ofconsole_getcharwidth as
18362 getcharwidth.
18363
67f44c86 183642005-08-28 Marco Gerards <metgerards@student.han.nl>
18365
18366 * include/grub/normal.h (enum grub_completion_type): Added
18367 `GRUB_COMPLETION_TYPE_ARGUMENT'.
18368
18369 * normal/cmdline.c (print_completion): Handle
18370 the `GRUB_COMPLETION_TYPE_ARGUMENT' type.
18371 * normal/menu_entry.c (store_completion): Likewise.
18372
18373 * normal/completion.c (complete_arguments): New function.
18374 (grub_normal_do_completion): Call `complete_arguments' when the
18375 current words start with a dash.
18376
0b5abe02 183772005-08-27 Marco Gerards <metgerards@student.han.nl>
18378
18379 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Fix typo (use
18380 `gzio.mod' instead of `io.mod').
18381
d9864ee1 183822005-08-22 Yoshinori K. Okuji <okuji@enbug.org>
18383
18384 * gendistlist.sh (EXTRA_DISTFILES): Added genfslist.sh.
18385 (DISTDIRS): Added io and video.
18386 Rewrite the search routine to make an output consistently.
18387
18388 * DISTLIST: Added conf/sparc64-ieee1275.mk,
18389 conf/sparc64-ieee1275.rmk, include/grub/gzio.h,
18390 include/grub/ieee1275/ieee1275.h, include/grub/ieee1275/ofdisk.h,
18391 io/gzio.c, kern/sparc64/cache.c, kern/sparc64/dl.c,
18392 kern/sparc64/ieee1275/init.c, kern/sparc64/ieee1275/openfw.c and
18393 util/powerpc/ieee1275/misc.c.
f19dbdb7 18394
d9864ee1 18395 * include/grub/gzio.h: New file.
18396 * io/gzio.c: Likewise.
f19dbdb7 18397
d9864ee1 18398 * kern/file.c (grub_file_close): Call grub_device_close only if
18399 FILE->DEVICE is not NULL.
18400
18401 * include/grub/mm.h [!NULL] (NULL): New macro.
18402
18403 * include/grub/err.h (GRUB_ERR_BAD_GZIP_DATA): New constant.
18404
18405 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added io/gzip.c.
18406 (pkgdata_MODULES): Added gzio.mod.
18407 (gzio_mod_SOURCES): New variable.
18408 (gzio_mod_CFLAGS): Likewise.
18409
18410 * conf/i386-pc.rmk (grub_emu_SOURCES): Added io/gzip.c.
18411 (pkgdata_MODULES): Added gzio.mod.
18412 (gzio_mod_SOURCES): New variable.
18413 (gzio_mod_CFLAGS): Likewise.
18414
18415 * commands/cat.c: Include grub/gzio.h.
18416 (grub_cmd_cat): Use grub_gzfile_open instead of
18417 grub_file_open.
f19dbdb7 18418
d9864ee1 18419 * commands/cmp.c: Include grub/gzio.h.
18420 (grub_cmd_cmp): Use grub_gzfile_open instead of
18421 grub_file_open.
18422
18423 * loader/i386/pc/multiboot.c: Include grub/gzio.h.
18424 (grub_rescue_cmd_multiboot): Use grub_gzfile_open instead of
18425 grub_file_open.
18426 (grub_rescue_cmd_module): Likewise.
18427
fa46f4b5 184282005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
18429
18430 * conf/sparc64-ieee1275.rmk (grubof_SOURCES): The first file must be
18431 kern/sparc64/ieee1275/init.c because it contains _start.
18432 * conf/sparc64-ieee1275.mk: Generated from conf/sparc64-ieee1275.rmk.
18433
e9211b5d 184342005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
18435
18436 * configure.ac: Add support for sparc64 host with ieee1275
18437 firmware.
18438 * configure: Generated from configure.ac.
18439 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Use grub_ssize_t
18440 instead of int.
18441 (grub_ofdisk_read): Likewise.
18442 (grub_ofdisk_open): Use %p to print pointer values, and cast the
18443 pointers as (void *) to remove a warning.
18444 (grub_ofdisk_close): Likewise.
18445 (grub_ofdisk_read): Likewise.
18446 * kern/ieee1275/ieee1275.c (grub_ieee1275_exit): This never
18447 returns, so make it return void to remove a warning.
18448 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_exit):
18449 Corresponding prototype change.
18450 * kern/mm.c (grub_mm_init_region): Use %p to print pointer
18451 values, and cast the pointers as (void *) to remove a warning.
18452 (grub_mm_dump): Likewise.
18453 * conf/sparc64-ieee1275.mk: New file.
18454 * conf/sparc64-ieee1275.rmk: Likewise.
18455 * include/grub/sparc64/setjmp.h: Likewise.
18456 * include/grub/sparc64/types.h: Likewise.
18457 * include/grub/sparc64/ieee1275/console.h: Likewise.
18458 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
18459 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
18460 * include/grub/sparc64/ieee1275/time.h: Likewise.
18461 * kern/sparc64/cache.c: Likewise.
18462 * kern/sparc64/dl.c: Likewise.
18463 * kern/sparc64/ieee1275/init.c: Likewise.
18464 * kern/sparc64/ieee1275/openfw.c: Likewise.
18465
385c6a92 184662005-08-21 Yoshinori K. Okuji <okuji@enbug.org>
18467
18468 * util/console.c (grub_ncurses_putchar): If C is greater than
18469 0x7f, set C to a question mark.
18470 (grub_ncurses_getcharwidth): New function.
18471 (grub_ncurses_term): Specify grub_ncurses_getcharwidth as
18472 getcharwidth.
18473
18474 * normal/menu.c (print_entry): Made aware of Unicode. First,
18475 convert TITLE to UCS-4, and predict the cursor position by
18476 grub_getcharwidth.
18477
18478 * include/grub/misc.h (grub_utf8_to_ucs4): Specify the qualifier
18479 const to SRC.
18480 * kern/misc.c (grub_utf16_to_utf8): Likewise.
18481
16ccb8b1 184822005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
18483
18484 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Specify
18485 the boot file by the option BOOT_IMAGE. Use grub_stpcpy instead of
18486 grub_strcat.
18487
18488 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Specify the boot
18489 file by the option BOOT_IMAGE. Use grub_stpcpy instead of
18490 grub_strcpy and grub_strlen. Take it into account that a space
18491 character is inserted as a delimiter.
18492
6a85ce79 184932005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
18494
18495 * partmap/pc.c (pc_partition_map_iterate): Include the value of an
fe6b695a 18496 invalid magic in the error.
6a85ce79 18497
18498 * commands/search.c: New file.
f19dbdb7 18499
6a85ce79 18500 * util/grub-emu.c (main): Call grub_search_init and
18501 grub_search_fini.
18502
18503 * kern/rescue.c (grub_rescue_print_disks): Removed.
18504 (grub_rescue_print_devices): New function.
18505 (grub_rescue_cmd_ls): Use grub_device_iterate with
18506 grub_rescue_print_devices instead of grub_disk_dev_iterate with
18507 grub_rescue_print_disks.
18508
18509 * kern/partition.c (grub_partition_iterate): Return the result of
18510 PARTMAP->ITERATE instead of GRUB_ERRNO.
18511
18512 * kern/device.c: Include grub/partition.h.
18513 (grub_device_iterate): New function.
18514
18515 * include/grub/partition.h (grub_partition_iterate): Return int
18516 instead of grub_err_t.
18517
18518 * include/grub/normal.h [GRUB_UTIL] (grub_search_init): New
18519 prototype.
18520 [GRUB_UTIL] (grub_search_fini): Likewise.
18521
18522 * include/grub/device.h (grub_device_iterate): New prototype.
18523
18524 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
18525 commands/search.c.
18526 (pkgdata_MODULES): Added search.mod.
18527 (search_mod_SOURCES): New variable.
18528 (search_mod_CFLAGS): Likewise.
18529
18530 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/search.c.
18531 (pkgdata_MODULES): Added search.mod.
18532 (search_mod_SOURCES): New variable.
18533 (search_mod_CFLAGS): Likewise.
18534
18535 * commands/ls.c (grub_ls_list_disks): Renamed to ...
18536 (grub_ls_list_devices): ... this, and use grub_device_iterate.
18537 All callers changed.
18538
18539 * DISTLIST: Added commands/search.c.
18540
ef095434 185412005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
18542
18543 * kern/term.c (grub_putchar): Use grub_utf8_to_ucs4 for the
18544 conversion.
18545 (grub_getcharwidth): New function.
18546
18547 * kern/misc.c (grub_utf8_to_ucs4): New function.
18548
18549 * include/grub/term.h (struct grub_term): Added a new member
18550 "getcharwidth".
18551 (grub_getcharwidth): New prototype.
18552
18553 * include/grub/misc.h (grub_utf8_to_ucs4): New prototype.
18554
18555 * term/i386/pc/console.c (map_char): New function. Segregated from
18556 grub_console_putchar.
18557 (grub_console_putchar): Use map_char.
18558 (grub_console_getcharwidth): New function.
18559 (grub_console_term): Specified grub_console_getcharwidth as
18560 getcharwidth.
18561
18562 * term/i386/pc/vga.c (grub_vga_getcharwidth): New function.
18563 (grub_vga_term): Specified grub_vga_getcharwidth as getcharwidth.
18564
18565 * term/i386/pc/vesafb.c (grub_virtual_screen_setup): Return
18566 GRUB_ERRNO.
18567 (grub_vesafb_init): Do not use RC. Instead, use GRUB_ERRNO. Rely
18568 on grub_strtoul completely.
18569 (write_char): Declare local variables in the beginning of the
18570 function.
18571 (grub_vesafb_getcharwidth): New function.
18572 (grub_vesafb_term): Specified grub_vesafb_getcharwidth as
18573 getcharwidth.
18574
1f0a95e4 185752005-08-19 Yoshinori K. Okuji <okuji@enbug.org>
18576
18577 * DISTLIST: Replace commands/i386/pc/vbe_list_modes.c and
18578 commands/i386/pc/vbe_test.c with commands/i386/pc/vbeinfo.c and
18579 commands/i386/pc/vbetest.c.
18580
18581 * video/i386/pc/vbe.c (grub_vbe_probe): If INFOBLOCK is not NULL,
18582 call grub_vbe_get_controller_info again, because the returned
18583 information is volatile.
18584 (grub_vbe_set_video_mode): Mostly rewritten.
18585 (grub_vbe_get_video_mode): Use grub_vbe_probe and use
18586 grub_vbe_status_t correctly.
18587 (grub_vbe_get_video_mode_info): Likewise.
18588 (grub_vbe_set_pixel_rgb): Use a switch statement rather than
18589 several if statements.
18590
18591 * commands/i386/pc/vbe_list_modes.c: Renamed to ...
18592 * commands/i386/pc/vbeinfo.c: ... this.
18593
18594 * commands/i386/pc/vbe_test.c: Renamed to ...
18595 * commands/i386/pc/vbetest.c: ... this.
18596
18597 * commands/i386/pc/vbeinfo.c (grub_cmd_vbe_list_modes): Renamed to
18598 ...
18599 (grub_cmd_vbeinfo): ... this. Save video modes before
18600 iterating. Skip a video mode, if it is not available, not enough
18601 information is given or it is monochrome. Show the memory
18602 model. Leave the interpretation of MODEVAR to grub_strtoul
18603 completely.
18604 (GRUB_MOD_INIT): Rename vbe_list_modes to vbeinfo.
18605 (GRUB_MOD_FINI): Likewise.
18606
18607 * commands/i386/pc/vbetest.c (grub_cmd_vbe_test): Renamed to ...
18608 (grub_cmd_vbetest): ... this. Don't print unnecessarily. Use
18609 grub_err_t instead of grub_uint32_t. Don't use SPTR. Remove a
18610 duplicated grub_env_get. Leave the interpretation of MODEVAR to
18611 grub_strtoul completely.
18612 (real2pm): Removed.
18613 (GRUB_MOD_INIT): Rename vbe_test to vbetest.
18614 (GRUB_MOD_FINI): Likewise.
18615
18616 * normal/misc.c: Include grub/mm.h.
18617
18618 * conf/i386-pc.rmk (pkgdata_MODULES): Replaced vbe_test.mod and
18619 vbe_list_modes with vbetest.mod and vbeinfo.mod.
18620 (vbe_list_modes_mod_SOURCES): Removed.
18621 (vbe_list_modes_mod_CFLAGS): Likewise.
18622 (vbe_test_mod_SOURCES): Likewise.
18623 (vbe_test_mod_CFLAGS): Likewise.
18624 (vbeinfo_mod_SOURCES): New variable.
18625 (vbeinfo_mod_CFLAGS): Likewise.
18626 (vbetest_mod_SOURCES): Likewise.
18627 (vbetest_mod_CFLAGS): Likewise.
18628
992ffbbe 186292005-08-18 Yoshinori K. Okuji <okuji@enbug.org>
18630
18631 * normal/misc.c: New file.
18632
18633 * DISTLIST: Added normal/misc.c.
f19dbdb7 18634
992ffbbe 18635 * partmap/amiga.c (amiga_partition_map_iterate): Add an argument
18636 DISK to HOOK. Call HOOK with DISK.
18637 * partmap/apple.c (apple_partition_map_iterate): Likewise.
18638 * partmap/pc.c (pc_partition_map_iterate): Likewise.
18639 * partmap/sun.c (sun_partition_map_iterate): Likewise.
18640
18641 * normal/menu_entry.c (struct screen): Added a new member
18642 "completion_shown".
18643 (completion_buffer): New global variable.
18644 (make_screen): Set SCREEN->COMPLETION_SHOWN to zero.
18645 (store_completion): New function.
18646 (complete): Likewise.
18647 (clear_completions): Likewise.
18648 (grub_menu_entry_run): If SCREEN->COMPLETION_SHOWN is non-zero,
18649 call clear_completions and reset SCREEN->COMPLETION_SHOWN. If C is
18650 a tab, call complete.
18651
18652 * normal/completion.c (disk_dev): Removed.
18653 (print_simple_completion): Likewise.
18654 (print_partition_completion): Likewise.
18655 (print_func): New global variable.
18656 (add_completion): Do not take the arguments WHAT or PRINT any
18657 longer. Added a new argument TYPE. Instead of printing directly,
18658 call PRINT_FUNC if not NULL.
18659 All callers changed.
18660 (complete_device): Use a local variable DEV instead of
18661 DISK_DEV. Do not move CURRENT_WORD to the end of a device name.
18662 (grub_normal_do_completion): Take a new argument HOOK. Do not
18663 initialize DISK_DEV. Initialize PRINT_FUNC to HOOK. If RET is an
18664 empty string, return NULL instead.
18665 All callers changed.
18666
18667 * normal/cmdline.c (print_completion): New function.
18668
18669 * kern/partition.c (grub_partition_iterate): Add an argument DISK
18670 to HOOK.
18671 All callers changed.
18672
18673 * kern/disk.c (grub_print_partinfo): Removed.
18674
18675 * include/grub/partition.h (struct grub_partition_map): Add a new
18676 argument DISK into HOOK of ITERATE.
18677 (grub_partition_iterate): Add a new argument DISK to HOOK.
18678
18679 * include/grub/normal.h (enum grub_completion_type): New enum.
18680 (grub_completion_type_t): New type.
18681 (GRUB_COMPLETION_TYPE_COMMAND): New constant.
18682 (GRUB_COMPLETION_TYPE_DEVICE): Likewise.
18683 (GRUB_COMPLETION_TYPE_PARTITION): Likewise.
18684 (GRUB_COMPLETION_TYPE_FILE): Likewise.
18685 (grub_normal_do_completion): Added a new argument HOOK.
18686 (grub_normal_print_device_info): New prototype.
18687
18688 * include/grub/disk.h (grub_print_partinfo): Removed.
18689
18690 * conf/i386-pc.rmk (grub_emu_SOURCES): Added normal/misc.c.
18691 (normal_mod_SOURCES): Likewise.
18692 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
18693 (normal_mod_SOURCES): Likewise.
18694
18695 * commands/ls.c (grub_ls_list_disks): Use
18696 grub_normal_print_device_info instead of grub_print_partinfo. Free
18697 PNAME.
18698 (grub_ls_list_files): Use grub_normal_print_device_info instead of
18699 duplicating the code.
18700
0bd41162 187012005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
18702
18703 * commands/i386/pc/vbe_list_modes.c: Update source formatting to
f19dbdb7 18704 follow GCS more precisely.
18705 * commands/i386/pc/vbe_test.c: Likewise.
18706 * include/grub/i386/pc/vbe.h: Likewise.
18707 * term/i386/pc/vesafb.c: Likewise.
18708 * video/i386/pc/vbe.c: Likewise.
0bd41162 18709
6323696a 187102005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
18711
18712 * DISTLIST: Added term/i386/pc/vesafb.c
18713 DISTLIST: Added video/i386/pc/vbe.c
18714 DISTLIST: Added commands/i386/pc/vbe_list_modes.c.
18715 DISTLIST: Added commands/i386/pc/vbe_test.c.
18716 * commands/i386/pc/vbe_list_modes.c: New file.
18717 * commands/i386/pc/vbe_test.c: Likewise.
18718 * term/i386/pc/vesafb.c: Likewise.
18719 * video/i386/pc/vbe.c: Likewise.
18720 * include/grub/i386/pc/vbe.h (GRUB_VBE_DEFAULT_VIDEO_MODE): Added define.
18721 (grub_vbe_probe) Added prototype.
18722 (grub_vbe_set_video_mode) Likewise.
18723 (grub_vbe_get_video_mode) Likewise.
18724 (grub_vbe_get_video_mode_info) Likewise.
18725 (grub_vbe_set_pixel_rgb) Likewise.
18726 (grub_vbe_set_pixel_index) Likewise.
18727 * conf/i386-pc.rmk (pkgdata_MODULES): Added vbe.mod.
18728 (pkgdata_MODULES): Added vesafb.mod.
18729 (pkgdata_MODULES): Added vbe_list_modes.mod.
18730 (pkgdata_MODULES): Added vbe_test.mod.
18731 (vbe_mod_SOURCES): Added.
18732 (vbe_mod_CFLAGS): Likewise.
18733 (vesafb_mod_SOURCES): Likewise.
18734 (vesafb_mod_CFLAGS): Likewise.
18735 (vbe_list_modes_mod_SOURCES): Likewise.
18736 (vbe_list_modes_mod_CFLAGS): Likewise.
18737 (vbe_test_mod_SOURCES): Likewise.
18738 (vbe_test_mod_CFLAGS): Likewise.
18739
0a74e62f 187402005-08-14 Yoshinori K. Okuji <okuji@enbug.org>
18741
0a74e62f 18742 * normal/command.c (grub_command_execute): If INTERACTIVE is
18743 false and GRUB_COMMAND_FLAG_NO_ECHO is not specified, print
18744 CMDLINE. Disable the pager if INTERACTIVE is true.
18745 All callers are changed.
18746
18747 * normal/main.c (grub_normal_execute): Read command.lst and fs.lst
18748 before reading a config file.
18749 * normal/main.c (read_config_file): Even if a command is not
18750 found, register it if it is within an entry.
18751
18752 * util/grub-emu.c: Include sys/types.h and unistd.h.
18753 (options): Added --hold.
18754 (struct arguments): Added a new member "hold".
18755 (parse_opt): If KEY is 'H', set ARGS->HOLD to ARG or -1 if ARG is
18756 missing.
18757 (main): Initialize ARGS.HOLD to zero. Wait until ARGS.HOLD is
18758 cleared by a debugger, if it is not zero.
18759
18760 * include/grub/normal.h (grub_command_execute): Add an argument
18761 INTERACTIVE.
18762
e51f85ae 187632005-08-14 Vesa Jaaskelainen <chaac@nic.fi>
18764
18765 * DISTLIST: Added include/grub/i386/pc/vbe.h.
18766
e9c6f39b 187672005-08-13 Yoshinori K. Okuji <okuji@enbug.org>
18768
18769 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Replace the test
18770 program with another one, because the old one didn't detect a bug
18771 in gcc-3.4. Always use regparm 2, because the new test is still
18772 not enough for gcc-4.0. Someone must investigate a simple test
18773 case which detects a bug in gcc-4.0.
18774
8de3495c 187752005-08-12 Yoshinori K. Okuji <okuji@enbug.org>
18776
18777 * DISTLIST: Added normal/completion.c.
18778
18779 * normal/completion.c: New file.
f19dbdb7 18780
8de3495c 18781 * term/i386/pc/console.c (grub_console_getwh): New function.
18782 (grub_console_term): Assign grub_console_getwh to getwh.
18783
18784 * normal/cmdline.c (grub_tab_complete): Removed. Now the same
18785 function is defined in normal/completion.c as
18786 grub_normal_do_completion.
18787 (grub_cmdline_get): Use grub_normal_do_completion instead of
18788 grub_tab_complete.
18789
18790 * kern/partition.c (grub_partition_map_iterate): Return 1 if HOOK
18791 returns non-zero, otherwise return 0.
18792 (grub_partition_iterate): First, probe the partition map. Then,
18793 call ITERATE only for this partition map.
18794
18795 * kern/misc.c (grub_strncmp): Rewritten.
18796
18797 * kern/disk.c (grub_disk_dev_iterate): Return 1 if P->ITERATE
18798 returns non-zero. Otherwise return 0.
18799
18800 * include/grub/partition.h (grub_partition_map_iterate): Return
18801 int instead of void.
18802
18803 * include/grub/normal.h (grub_normal_do_completion): New prototype.
18804
18805 * include/grub/misc.h (grub_strncmp): Change the type of N to
18806 grub_size_t.
18807
18808 * include/grub/disk.h (grub_disk_dev_iterate): Return int instead
18809 of void.
18810
18811 * normal/menu.c (draw_border): Cast GRUB_TERM_BORDER_WIDTH to
fe6b695a 18812 unsigned explicitly before comparing it with I.
8de3495c 18813
18814 * kern/main.c (grub_env_write_root): Add the attribute unused into
18815 VAR.
18816
18817 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
18818 normal/completion.c.
18819 (normal_mod_SOURCES): Likewise.
18820 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
18821 (normal_mod_SOURCES): Likewise.
18822
18823 * normal/command.c (grub_iterate_commands): If ITERATE returns
18824 non-zero, return one immediately.
18825
e85e144b 188262005-08-09 Vesa Jaaskelainen <chaac@nic.fi>
18827
18828 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vbe.h.
18829 * kern/i386/pc/startup.S: Updated Global Descriptor table's
18830 descriptions.
18831 (grub_vbe_get_controller_info): New function.
18832 (grub_vbe_get_mode_info): Likewise.
18833 (grub_vbe_set_mode): Likewise.
18834 (grub_vbe_get_mode): Likewise.
18835 (grub_vbe_set_memory_window): Likewise.
18836 (grub_vbe_get_memory_window): Likewise.
18837 (grub_vbe_set_scanline_length): Likewise.
18838 (grub_vbe_get_scanline_length): Likewise.
18839 (grub_vbe_set_display_start): Likewise.
18840 (grub_vbe_get_display_start): Likewise.
18841 (grub_vbe_set_palette_data): Likewise.
18842 * include/grub/i386/pc/vbe.h: New file.
18843
c46153d2 188442005-08-08 Hollis Blanchard <hollis@penguinppc.org>
18845
18846 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
18847 kern/ieee1275/of.c with kern/ieee1275/ieee1275.c.
18848 * DISTLIST: Likewise.
18849 * kern/ieee1275/of.c: Moved to ...
18850 * kern/ieee1275/ieee1275.c: ... here.
18851
0cb90c45 188522005-08-08 Hollis Blanchard <hollis@penguinppc.org>
18853
18854 * term/ieee1275/ofconsole.c: Include <grub/mm.h>.
18855 (grub_ofconsole_getwh): Cast -1 to type grub_ieee1275_ihandle_t.
18856 Pass 0 as `end' parameter to grub_strtoul().
18857
a19fb360 188582005-08-08 Hollis Blanchard <hollis@penguinppc.org>
18859
18860 * include/grub/powerpc/ieee1275/console.h: Do not include
18861 <grub/types.h>. Do not include <grub/symbol.h>. Remove ASM_FILE
18862 ifdef.
18863 (grub_console_cur_color): Remove i386-specific prototype.
18864 (grub_console_real_putchar): Likewise.
18865 (grub_console_checkkey): Likewise.
18866 (grub_console_getkey): Likewise.
18867 (grub_console_getxy): Likewise.
18868 (grub_console_gotoxy): Likewise.
18869 (grub_console_cls): Likewise.
18870 (grub_console_setcursor): Likewise.
18871 * kern/powerpc/ieee1275/init.c: Don't include <grub/console.h>.
18872 Include <grub/machine/console.h>.
18873 * term/ieee1275/ofconsole.c: Likewise.
18874
4ac9bd04 188752005-08-08 Yoshinori K. Okuji <okuji@enbug.org>
18876
18877 * Makefile.in (LIBLZO): New variable.
18878
18879 * configure.ac: Check for LZO version 2.
18880
18881 * util/i386/pc/grub-mkimage.c [HAVE_LZO_LZO1X_H]: Include
18882 lzo/lzo1x.h instead of lzo1x.h.
18883
18884 * conf/i386-pc.rmk (grub_mkimage_LDFLAGS): Use $(LIBLZO) instead
18885 of -llzo.
18886
18887 * util/i386/pc/grub-setup.c (main): Do not free PREFIX
18888 twice. Reported by Vladimir Serbinenko <phcoder@gmail.com>.
18889
18890 * partmap/pc.c (pc_partition_map_probe): Restore P->DATA after
18891 copying the data from PARTITION to P.
18892
f4917dfd 188932005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
18894
18895 * kern/rescue.c (grub_rescue_cmd_rmmod): If the reference count is
18896 negative, unload the module.
18897
18898 * util/i386/pc/grub-setup.c (setup): The name of the PC partition
18899 map is "pc_partition_map" but not "pc".
18900 (usage): Fix the description. The options are --boot-image and
18901 --core-image but not --boot-file or --core-file.
18902 (main): If not specified explicitly, make BOOT_FILE and CORE_FILE
18903 based on DEFAULT_BOOT_FILE and DEFAULT_CORE_FILE with DIR or
18904 DEFAULT_DIRECTORY.
18905
18906 * util/i386/pc/grub-install.in: Do not specify --boot-file or
18907 --core-file. Specify INSTALL_DEVICE as an argument.
18908
18909 * util/console.c: Include config.h.
18910 [HAVE_NCURSeS_CURSES_H]: Include ncurses/curses.h.
18911 [HAVE_NCURSES_H]: Include ncurses.h.
18912 [HAVE_CURSES_H]: Include curses.h.
18913 [!A_NORMAL] (A_NORMAL): Defined as zero.
18914 [!A_STANDOUT] (A_STANDOUT): Likewise.
18915
18916 * conf/i386-pc.rmk (grub_emu_LDFLAGS): Use $(LIBCURSES) instead of
18917 -lncurses.
18918 * conf/powerpc-ieee1275.rmk (grub_emu_LDFLAGS): Likewise.
18919
18920 * configure.ac: Check for curses libraries and headers.
18921
18922 * Makefile.in (LIBCURSES): New variable.
18923
18924 * genmk.rb (Script::rule): Set the executable bits.
18925
18926 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): The
18927 name of the PC partition map is "pc_partition_map" but not "pc".
18928
0e143073 189292005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
18930
18931 * util/i386/pc/grub-install.in (grub_probefs): New variable.
18932 (modules): Likewise.
18933 (usage): Added descriptions for --modules and --grub-probefs.
18934 Handle --modules and --grub-probefs. Save the arguments in MODULES
18935 and GRUB_PROBEFS, respectively.
18936 Auto-detect a filesystem module against GRUBDIR. If the result is
18937 empty and modules are not specified explicitly, abort the
18938 installation. Add the result to MODULES.
18939
18940 * DISTLIST: Removed boot/powerpc/ieee1275/ieee1275.c,
18941 disk/powerpc/ieee1275/ofdisk.c,
18942 include/grub/powerpc/ieee1275/init.h and
18943 term/powerpc/ieee1275/ofconsole.c.
18944 Added disk/ieee1275/ofdisk.c, kern/ieee1275/of.c and
18945 term/ieee1275/ofconsole.c.
18946
18947 * include/grub/powerpc/ieee1275/console.h: Resurrected.
18948
18949 * COPYING: Upgraded to the latest version. Only the address of the
18950 FSF office has changed.
f19dbdb7 18951
efd6e6d5 189522005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
18953
18954 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
18955 kern/ieee1275.c with kern/ieee1275/of.c.
18956
18957 * kern/ieee1275.c: Moved to ...
18958 * kern/ieee1275/of.c: ... here.
18959
8ceafda2 189602005-08-06 Yoshinori K. Okuji <okuji@enbug.org>
18961
18962 * conf/i386-pc.rmk (kernel_img_HEADERS): Reordered for
fe6b695a 18963 readability.
8ceafda2 18964
18965 * config.guess: Updated to the latest version from gnulib.
18966 * config.sub: Likewise.
18967 * install.sh: Likewise.
18968 * mkinstalldirs: Likewise.
18969
18970 * include/grub/console.h: Removed. This file is arch-specific. Do
18971 not put this in include/grub.
18972
18973 * include/grub/i386/pc/console.h: Resurrected.
18974
18975 * util/console.c: Include grub/machine/console.h instead of
18976 grub/console.h.
18977 * util/grub-emu.c: Likewise.
18978
267f6cd9 189792005-08-04 Marco Gerards <metgerards@student.han.nl>
18980
18981 * kern/term.c (grub_putcode): Use `grub_getwh' instead of
18982 hardcoded value.
f19dbdb7 18983
267f6cd9 18984 From Vincent Pelletier <subdino2004@yahoo.fr>
18985 * include/grub/term.h (GRUB_TERM_WIDTH, GRUB_TERM_HEIGHT):
18986 Redefined to use grub_getwh.
18987 (grub_term): New member named getwh.
18988 (grub_getwh): New prototype.
18989 * kern/term.c (grub_getwh): New function.
18990 * term/i386/pc/console.c (grub_console_getwh): New function.
18991 (grub_console_term): New member `getwh'.
18992 * term/i386/pc/vga.c (grub_vga_getwh): New function.
18993 (grub_vga_term): New member `getwh'.
0b5abe02 18994 * term/ieee1275/ofconsole.c (grub_ofconsole_readkey): Use
267f6cd9 18995 grub_ssize_t.
18996 (grub_ofconsole_getw): New function.
18997 (grub_ofconsole_init): Use grub_ssize_t and unsigned char.
18998 (grub_ofconsole_term): New field named getwh and new initial
18999 value.
19000
3be7266d 190012005-08-03 Hollis Blanchard <hollis@penguinppc.org>
19002
19003 * include/grub/powerpc/ieee1275/ieee1275.h: Move ...
19004 * include/grub/ieee1275/ieee1275.h: ... to here. All users updated.
19005 Move `abort', `grub_reboot', and `grub_halt' prototypes ...
19006 * include/grub/powerpc/ieee1275/kernel.h: ... to here.
19007 * commands/ieee1275/halt.c: Include <grub/machine/kernel.h> instead
19008 of <grub/machine/ieee1275.h>.
19009 * commands/ieee1275/reboot.c: Likewise.
19010 * boot/powerpc/ieee1275/ieee1275.c: Move ...
19011 * kern/ieee1275.c: ... to here. All users updated. Change all
19012 parameter structs to use new type `grub_ieee1275_cell_t'.
19013 * term/powerpc/ieee1275/ofconsole.c: Move ...
19014 * term/ieee1275/ofconsole.c: ... to here. All users updated.
19015 * disk/powerpc/ieee1275/ofdisk.c: Move ...
19016 * disk/ieee1275/ofdisk.c: ... to here. All users updated.
19017 * boot/powerpc/ieee1275/cmain.c: Change `grub_ieee1275_entry_fn' type
19018 to return int.
19019 * include/grub/i386/pc/console.h: Move to include/grub/console.h.
19020 Remove unused prototypes. All users updated.
19021 * include/grub/powerpc/ieee1275/console.h: Removed.
19022 * include/grub/powerpc/ieee1275/ieee1275.h: Define
19023 `grub_ieee1275_cell_t'.
19024 * kern/powerpc/ieee1275/openfw.c: Include <grub/machine/kernel.h>.
19025 Cast comparisons with -1 to the correct type.
19026 * loader/powerpc/ieee1275/linux.c (kernel_entry_t): Change parameter
19027 type to match `grub_ieee1275_entry_fn'.
19028
8b5f3938 190292005-08-01 Yoshinori K. Okuji <okuji@enbug.org>
19030
19031 * DISTLIST: Added util/i386/pc/grub-probefs.c.
19032
19033 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-probefs.
19034 (grub_setup_SOURCES): Removed partmap/amiga.c, partmap/apple.c and
19035 partmap/sun.c.
19036 (grub_probefs_SOURCES): New variable.
19037
19038 * util/i386/pc/grub-probefs.c: New file.
19039
19040 * util/i386/pc/grub-setup.c (main): Call
19041 grub_pc_partition_map_init, grub_ufs_init, grub_minix_init,
19042 grub_hfs_init and grub_jfs_init to initialize the system. Call
19043 grub_ufs_fini, grub_minix_fini, grub_hfs_fini, grub_jfs_init and
19044 grub_pc_partition_map_fini to finish the system.
19045
ea409713 190462005-07-31 Yoshinori K. Okuji <okuji@enbug.org>
19047
19048 * loader/i386/pc/multiboot.c (grub_multiboot_is_elf32): New
19049 function.
19050 (grub_multiboot_load_elf32): Likewise.
19051 (grub_multiboot_is_elf64): Likewise.
19052 (grub_multiboot_load_elf64): Likewise.
19053 (grub_multiboot_load_elf): Likewise.
19054 (grub_rescue_cmd_multiboot): Call grub_multiboot_load_elf to load
19055 an ELF32 or ELF64 file.
19056 This is based on a patch from Ruslan Nikolaev <nruslan@mail.com>.
19057
19058 From Serbinenko Vladimir <serbinenko.vova@list.ru>:
19059 * kern/disk.c (grub_print_partinfo): Check if FS->LABEL is not
19060 NULL before calling FS->LABEL.
19061 * fs/fat.c (grub_fat_dir): Initialize DIRNAME to NULL.
19062 * commands/ls.c (grub_ls_list_files): Show labels, if possible.
19063 (grub_ls_list_disks): Check if FS and FS->LABEL are not NULL
19064 before calling FS->LABEL.
19065
141a288b 190662005-07-26 Yoshinori K. Okuji <okuji@enbug.org>
19067
19068 * util/i386/pc/grub-install.in (datadir): New variable.
19069 (libdir): Removed.
19070 (pkgdatadir): New variable.
19071 (pkglibdir): Removed.
19072
0d5f8a54 190732005-07-24 Yoshinori K. Okuji <okuji@enbug.org>
19074
19075 * DISTLIST: Added util/i386/pc/grub-install.in.
19076
19077 * util/i386/pc/grub-install.in: New file.
19078
19079 * conf/i386-pc.rmk (sbin_SCRIPTS): New variable.
19080 (grub_install_SOURCES): Likewise.
19081
19082 * genmk.rb: Added support for scripts.
19083 (Script): New class.
19084 (scripts): New variable.
19085
19086 * Makefile.in (install-local): Install sbin_SCRIPTS by
19087 INSTALL_SCRIPT.
19088 (uninstall): Remove sbin_SCRIPTS.
19089
19090 * util/i386/pc/grub-setup.c (main): If the argument is not a GRUB
19091 device, try to get a GRUB device by
19092 grub_util_biosdisk_get_grub_dev.
19093 Free DEST_DEV.
19094
19095 * util/i386/pc/grub-mkdevicemap.c (usage): Remove a duplicated
19096 description for --device-map.
19097
5f968e1e 190982005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
19099
19100 Change the semantics of variable hooks. They now return strings
19101 instead of error values.
f19dbdb7 19102
5f968e1e 19103 * util/i386/pc/grub-setup.c: Include grub/env.h.
19104 (setup): Use grub_device_set_root instead of grub_env_set.
19105
19106 * kern/rescue.c (grub_rescue_cmd_root): Use grub_env_set and
19107 grub_env_get instead of grub_device_set_root and
19108 grub_device_get_root, respectively.
19109
19110 * kern/main.c (grub_env_write_root): New function.
19111 (grub_set_root_dev): Register grub_env_write_hook for "root". Use
19112 grub_env_set instead of grub_device_set_root.
19113
19114 * kern/env.c (HASHSZ): Reduced to 13, because GRUB does not need
19115 many variables.
19116 (grub_env_set): Set ENV->VALUE to the result of ENV->WRITE_HOOK
19117 rather than calling ENV->WRITE_HOOK afterwards.
19118 (grub_env_get): Return the result of ENV->READ_HOOK rather than
19119 passing a pointer of a pointer.
19120 (grub_register_variable_hook): Change the types of "read_hook" and
19121 "write_hook" to grub_env_read_hook_t and grub_env_write_hook_t,
19122 respectively.
19123 Allocate the default empty string on the heap, because this string
19124 may be freed later.
19125
19126 * kern/device.c: Include grub/env.h.
19127 (grub_device_set_root): Removed.
19128 (grub_device_get_root): Likewise.
19129 (grub_device_open): Use grub_env_get instead of
19130 grub_device_get_root.
19131
19132 * include/grub/env.h (grub_env_read_hook_t): New type.
19133 (grub_env_write_hook_t): Likewise.
19134 (grub_env_var): Change the types of "read_hook" and "write_hook"
19135 to grub_env_read_hook_t and grub_env_write_hook_t, respectively.
19136 (grub_register_variable_hook): Likewise.
19137
19138 * include/grub/device.h (grub_device_set_root): Removed.
19139 (grub_device_set_root): Likewise.
19140
19141 * fs/fat.c (grub_fat_dir): Make a copy of PATH in DIRNAME, and
19142 make sure that DIRNAME terminates with '/', so that
19143 grub_fat_find_dir will fail if PATH is not a directory.
19144
19145 * commands/ls.c (grub_ls_list_files): Remove the qualifier const
19146 from DIRNAME.
19147 Use the qualifier auto for print_files and print_files_long.
19148 If FS->DIR sets GRUB_ERRNO to GRUB_ERR_BAD_FILE_TYPE, try DIRNAME
19149 as a regular file.
19150 Put a newline only if there is no error.
19151 (grub_cmd_ls): Remove grub_ls_print_files, because this is not
19152 used.
19153
896f0afd 191542005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
19155
19156 * kern/partition.c (grub_partition_probe): Initialize PART to
19157 NULL. Otherwise, when no partition map is registered, this returns
19158 a garbage.
19159
b28b81b2 191602005-07-19 Yoshinori K. Okuji <okuji@enbug.org>
19161
19162 * partmap/apple.c (apple_partition_map_iterate): Check if POS
19163 equals GRUB_DISK_SECTOR_SIZE to see if the partition table is
19164 valid.
19165
5f3607e0 191662005-07-18 Yoshinori K. Okuji <okuji@enbug.org>
19167
19168 * commands/ls.c (grub_ls_list_disks): Print the filesystem
19169 information on each device, if it does not have partitions. Print
19170 "Device" instead of "Disk", because this function is not specific
19171 to disk devices.
19172
19173 * normal/main.c (grub_rescue_cmd_normal): Make the variable CONFIG
19174 static to ensure that it is put on the memory rather than a
19175 register.
19176
502c87e8 191772005-07-17 Yoshinori Okuji <okuji@enbug.org>
19178
19179 * commands/cat.c (GRUB_MOD_INIT): Use better documentation.
19180 (grub_cat_init): Likewise.
19181 * loader/i386/pc/chainloader_normal.c (GRUB_MOD_INIT): Likewise.
19182 (options): Likewise.
19183 * commands/configfile.c (GRUB_MOD_INIT): Likewise.
19184 (grub_configfile_init): Likewise.
19185 * font/manager.c (GRUB_MOD_INIT): Likewise.
19186 * commands/help.c (GRUB_MOD_INIT): Likewise.
19187 (grub_help_init): Likewise.
19188 * normal/command.c (grub_command_init): Likewise.
19189 * loader/i386/pc/linux_normal.c (GRUB_MOD_INIT): Likewise.
19190 * disk/loopback.c (grub_loop_init): Likewise.
19191 (GRUB_MOD_INIT): Likewise.
19192 * commands/ls.c (grub_ls_init): Likewise.
19193 (GRUB_MOD_INIT): Likewise.
19194 (options): Likewise.
19195 * commands/boot.c (grub_boot_init): Likewise.
19196 (GRUB_MOD_INIT): Likewise.
19197 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Likewise.
19198 * commands/i386/pc/reboot.c (grub_reboot_init): Likewise.
19199 (GRUB_MOD_INIT): Likewise.
19200 * commands/cmp.c (grub_cmp_init): Likewise.
19201 (GRUB_MOD_INIT): Likewise.
19202
19203 * normal/arg.c: Use <> instead of "" to include header files.
19204 (SHORT_ARG_HELP): New macro.
19205 (SHORT_ARG_USAGE): Likewise.
19206 (help_options): Specify SHORT_ARG_HELP and SHORT_ARG_USAGE instead
19207 of 'h' and 'u' for help and usage, respectively. Use more GNU-like
19208 descriptions.
19209 (find_short): Check if C is 'h' or 'u' explicitly.
19210 (grub_arg_show_help): Use space characters instead of tabs. Treat
19211 SHORT_ARG_HELP and SHORT_ARG_USAGE exceptionally so that -h and -u
19212 are shown with --help and --usage only if they are not used for
19213 the command itself.
19214 (parse_option): Use SHORT_ARG_HELP and SHORT_ARG_USAGE instead of
19215 'h' and 'u'.
19216
19217 * include/grub/arg.h (struct grub_arg_option): Add the qualifier
19218 const into "longarg". Change the type of "shortarg" to int.
19219
f806d18e 192202005-07-17 Yoshinori Okuji <okuji@enbug.org>
19221
19222 * boot/i386/pc/boot.S (boot_drive_check): New label.
19223
19224 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRIVE_CHECK): New
19225 macro.
19226
19227 * util/i386/pc/grub-setup.c (setup): Added a workaround for BIOSes
19228 which do not pass a boot drive correctly. Copied from GRUB Legacy.
19229
e293232b 192302005-07-17 Yoshinori Okuji <okuji@enbug.org>
19231
19232 * kern/i386/pc/startup.S (gate_a20_try_system_control_port_a):
19233 When turning off Gate A20, skip the check and return immediately,
19234 because this is not fatal usually.
19235
ebedfd00 192362005-07-17 Yoshinori Okuji <okuji@enbug.org>
19237
19238 * conf/i386-pc.rmk (pxeboot_img_LDFLAGS): The text address should
19239 be 0x7C00 instead of 0x8000.
19240
19241 * boot/i386/pc/pxeboot.S: Rewritten.
19242
19243 * kern/i386/pc/startup.S (gate_a20_try_bios): No need to specify
19244 EXT_C.
19245 (gate_a20_check_state): Read a byte from 0x108000. Invert the
19246 result.
19247
654fc59f 192482005-07-16 Yoshinori K. Okuji <okuji@enbug.org>
19249
19250 * kern/i386/pc/startup.S (grub_gate_a20): Rewritten for
19251 robustness. This routine now supports a BIOS call and System
19252 Control Port A to modify the gate A20.
19253
19254 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
19255 Increased to 0x440.
19256
09f9923f 192572005-07-12 Hollis Blanchard <hollis@penguinppc.org>
19258
19259 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): dprintf the
19260 device path and resulting ihandle.
19261 (grub_ofdisk_close): dprintf the ihandle being closed.
19262 (grub_ofdisk_read): dprintf function parameters.
19263 * kern/mm.c (grub_mm_init_region): Likewise.
19264 * loader/powerpc/ieee1275/linux.c: Remove extra whitespace.
19265 (grub_linux_boot): dprintf the Linux entry point, initrd address and
19266 size, and boot arguments.
19267 (grub_rescue_cmd_linux): dprintf each ELF segment's address and size
19268 before loading into memory.
19269 (grub_rescue_cmd_initrd): dprintf the initrd's address and size
19270 before loading into memory.
19271
7ef504d8 192722005-07-12 Yoshinori K. Okuji <okuji@enbug.org>
19273
19274 * kern/mm.c: Added much documentation.
19275 (GRUB_MM_ALIGN_LOG2): When GRUB_CPU_SIZEOF_VOID_P is
19276 8, set to 5 instead of 8.
19277
e0f050c2 192782005-07-10 Yoshinori Okuji <okuji@enbug.org>
19279
19280 * DISTLIST: Added util/i386/pc/grub-mkimage.c.
19281
19282 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-mkdevicemap.
19283 (grub_mkdevicemap_SOURCES): New variable.
19284
19285 * util/i386/pc/grub-mkdevicemap.c: New file. Mostly copied from
19286 lib/device.c of GRUB Legacy.
19287
7224189a 192882005-07-10 Yoshinori Okuji <okuji@enbug.org>
19289
19290 * commands/ls.c (grub_ls_list_files): Check if *PATH is NUL
19291 instead of PATH is NULL.
19292
68c864eb 192932005-07-09 Vincent Pelletier <subdino2004@yahoo.fr>
19294
19295 * commands/cmp.c (BUFFER_SIZE): New macro.
19296 (grub_cmd_cmp): Close the right file at the right time. Compare
19297 only data just read. Don't report files of different size as
19298 identical. Dynamically allocate buffers. Move variable
19299 declarations at the beginning of function.
19300
e6f3e614 193012005-07-09 Yoshinori Okuji <okuji@enbug.org>
19302
19303 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): The return value was
19304 reverse.
19305
f8f1559a 193062004-07-04 Vincent Pelletier <subdino2004@yahoo.fr>
19307
19308 * normal/cmdline.c (grub_cmdline_get): Don't fallback on ctrl-d
19309 when backspace is pressed at beginning of line.
19310
39c9d41d 193112005-07-03 Yoshinori Okuji <okuji@enbug.org>
19312
19313 * DISTLIST: Added genfslist.sh.
19314
19315 * normal/main.c (fs_module_list): New variable.
19316 (autoload_fs_module): New function.
19317 (read_fs_list): Likewise.
19318 (grub_normal_execute): Call read_fs_list.
19319
19320 * kern/fs.c (grub_fs_autoload_hook): New variable.
19321 (grub_fs_probe): Added support for auto-loading.
19322
19323 * include/grub/normal.h (struct grub_fs_module_list): New struct.
19324 (grub_fs_module_list_t): New type.
19325
19326 * include/grub/fs.h (grub_fs_autoload_hook_t): New type.
19327 (grub_fs_autoload_hook): New prototype.
19328
19329 * genfslist.sh: New file.
f19dbdb7 19330
39c9d41d 19331 * genmk.rb: Added a rule to generate a filesystem list.
19332
121c1d83 193332005-06-30 Marco Gerards <metgerards@student.han.nl>
19334
19335 * configure.ac: Fix the test for cross-compiling.
19336
19337 * genmk.rb (Program): Use `$(CC)' instead of `$(BUILD_CC)'. Don't
19338 define GRUB_UTIL anymore.
19339
19340 * util/powerpc/ieee1275/grub-mkimage.c (load_note): Endian fixes
19341 so this function works on other systems than just big endian.
19342 (load_modules): Likewise.
19343 (add_segments): Likewise.
19344
e75d76e1 193452005-06-23 Hollis Blanchard <hollis@penguinppc.org>
19346
19347 * kern/misc.c (grub_vsprintf): Add `longfmt'. If format string
19348 contains `l' modifier, get a long from va_arg().
19349
50b5a0a7 193502005-06-23 Yoshinori K. Okuji <okuji@enbug.org>
19351
19352 * kern/mm.c (grub_free): If the next free block which is being
19353 merged is the first free block, set the first block to the block
19354 being freed.
19355 Reported by Vincent Guffens <guffens@inma.ucl.ac.be>.
19356
89371b20 193572005-05-08 Hollis Blanchard <hollis@penguinppc.org>
19358
19359 * boot/powerpc/ieee1275/cmain.c (cmain): Initialize
19360 `grub_ieee1275_chosen'.
19361
168d6e58 193622005-05-08 Hollis Blanchard <hollis@penguinppc.org>
19363
19364 * boot/powerpc/ieee1275/cmain.c (module_info): Remove definition.
19365 (grub_ieee1275_chosen): New variable.
19366 (cmain): Initialize and use `grub_ieee1275_chosen' instead of
19367 `chosen'.
19368 * boot/powerpc/ieee1275/crt0.S (init_stack): Remove stack space.
19369 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
19370 Rename first argument to `phandle' for consistency.
19371 (grub_ieee1275_get_property_length): Likewise.
19372 (grub_ieee1275_next_property): Likewise. Change type of first argument
19373 to grub_ieee1275_phandle_t.
19374 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_entry_fn):
19375 Move export next to declaration.
19376 (grub_ieee1275_chosen): New variable.
19377 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MODULE_BASE):
19378 Correct cosmetic typo.
19379 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Use
19380 `grub_ieee1275_chosen'.
19381 * kern/powerpc/ieee1275/openfw.c (grub_map): Likewise.
19382 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Likewise.
19383 (grub_rescue_cmd_linux): Set `initrd_addr' to 0.
19384 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_refresh): Use
19385 `grub_ieee1275_chosen'.
19386
ca5baa3f 193872005-05-10 Hollis Blanchard <hollis@penguinppc.org>
19388
19389 * boot/powerpc/ieee1275/cmain.c (cmain): Remove code to parse
19390 /chosen/bootargs.
19391 * kern/powerpc/ieee1275/init.c (grub_machine_init): Parse
19392 /chosen/bootargs as "variable=value" pairs.
19393
708b345f 193942005-05-08 Vincent Pelletier <subdino2004@yahoo.fr>
19395
19396 * include/grub/misc.h (grub_dprintf): New macro.
19397 (grub_real_dprintf): New prototype.
19398 (grub_strword): Likewise.
19399 (grub_iswordseparator): Likewise.
19400 * kern/misc.c (grub_real_dprintf): New function.
19401 (grub_strword): Likewise.
19402 (grub_iswordseparator): Likewise.
19403
f4c5e67c 194042005-04-30 Hollis Blanchard <hollis@penguinppc.org>
19405
19406 * boot/powerpc/ieee1275/cmain.c: Don't include grub/machine/init.h.
19407 (roundup): Remove macro.
19408 (grub_ieee1275_flags): Make static.
19409 (grub_ieee1275_realmode): Remove.
19410 (grub_ieee1275_test_flag): New function.
19411 (grub_ieee1275_set_flag): Likewise.
19412 (find_options): Rename to `grub_ieee1275_find_options'; update
19413 callers. Set GRUB_IEEE1275_FLAG_REAL_MODE and
19414 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS.
19415 (cmain): New prototype.
19416 (cmain): Use `grub_ieee1275_set_flag' instead of accessing
19417 `grub_ieee1275_flags' directly.
19418 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Remove
19419 machine/biosdisk.h.
19420 * disk/powerpc/ieee1275/ofdisk.c: Include grub/machine/ofdisk.h.
19421 Don't include grub/machine/init.h.
19422 (grub_ofdisk_open): Call `grub_ieee1275_test_flag'.
19423 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
19424 Remove prototype.
19425 (grub_ieee1275_realmode): Likewise.
19426 (grub_ieee1275_flag): New enum.
19427 (grub_ieee1275_test_flag): New prototype.
19428 (grub_ieee1275_set_flag): New prototype.
19429 * include/grub/powerpc/ieee1275/init.h: Remove file.
19430 * include/grub/powerpc/ieee1275/ofdisk.h: New file.
19431 * kern/powerpc/ieee1275/init.c: Don't include grub/machine/init.h.
19432 Include grub/machine/console.h. Include grub/machine/ofdisk.h.
19433 (grub_machine_fini): Don't call `grub_ieee1275_release'. Remove
19434 comment.
19435 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Call
19436 `grub_ieee1275_test_flag'.
19437 (grub_ieee1275_encode_devname): Likewise.
19438
ed16607e 194392005-04-21 Hollis Blanchard <hollis@penguinppc.org>
19440
19441 * include/grub/powerpc/ieee1275/ieee1275.h
19442 (grub_ieee1275_encode_devname): New prototype.
19443 (grub_ieee1275_get_filename): Likewise.
19444 * kern/powerpc/ieee1275/init.c (grub_translate_ieee175_path): New
19445 function.
19446 (grub_set_prefix): Likewise.
19447 (grub_machine_init): Call grub_set_prefix.
19448 * kern/powerpc/ieee1275/openfw.c: Fix typos.
19449 (grub_parse_type): New enum.
19450 (grub_ieee1275_get_devargs): New function.
19451 (grub_ieee1275_get_devname): Likewise.
19452 (grub_ieee1275_parse_args): Likewise.
19453 (grub_ieee1275_get_filename): Likewise.
19454 (grub_ieee1275_encode_devname): Likewise.
19455
be369920 194562005-03-30 Marco Gerards <metgerards@student.han.nl>
19457
19458 * kern/powerpc/ieee1275/init.c (grub_machine_fini): Don't call
19459 `grub_loader_unset'.
19460
a5ce3a4a 194612005-03-26 Hollis Blanchard <hollis@penguinppc.org>
19462
19463 * commands/ieee1275/halt.c (grub_cmd_halt): Call grub_halt
19464 instead of grub_ieee1275_interpret.
19465 (grub_halt_init): New function.
19466 (grub_halt_fini): Likewise.
19467 (GRUB_MOD_INIT): Correct message grammar.
19468 * commands/ieee1275/reboot.c (grub_cmd_reboot): Call grub_reboot
19469 instead of grub_ieee1275_interpret.
19470 (grub_reboot_init): New function.
19471 (grub_reboot_fini): Likewise.
19472 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace
19473 commands/i386/pc/halt.c, commands/i386/pc/reboot.c, and
19474 util/i386/pc/misc.c with commands/ieee1275/halt.c,
19475 commands/ieee1275/reboot.c, and util/powerpc/ieee1275/misc.c.
19476 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_fini): New
19477 function.
19478 * include/grub/powerpc/ieee1275/console.h (grub_console_fini):
19479 Add prototype.
19480 * include/grub/powerpc/ieee1275/ieee1275.h (grub_reboot): Add
19481 prototype.
19482 (grub_halt): Likewise.
19483 * include/grub/powerpc/ieee1275/init.h: Remove inaccurate comment.
19484 (cmain): Remove __attribute__((unused)).
19485 * kern/powerpc/ieee1275/init.c (grub_heap_start): New variable.
19486 (grub_heap_len): Likewise.
19487 (grub_machine_fini): New function.
19488 * kern/powerpc/ieee1275/openfw.c (grub_reboot): New function.
19489 (grub_halt): Likewise.
19490 * term/powerpc/ieee1275/ofconsole.c (grub_console_fini): New
19491 function.
19492 * util/powerpc/ieee1275/misc.c: New file.
19493
0058f771 194942005-03-19 Yoshinori K. Okuji <okuji@enbug.org>
19495
19496 * DISTLIST: New file.
19497 * gendistlist.sh: Likewise.
f19dbdb7 19498
0058f771 19499 * Makefile.in (COMMON_DISTFILES): Removed.
19500 (BOOT_DISTFILES): Likewise.
19501 (CONF_DISTFILES): Likewise.
19502 (DISK_DISTFILES): Likewise.
19503 (FS_DISTFILES): Likewise.
19504 (INCLUDE_DISTFILES): Likewise.
19505 (KERN_DISTFILES): Likewise.
19506 (LOADER_DISTFILES): Likewise.
19507 (TERM_DISTFILES): Likewise.
19508 (UTIL_DISTFILES): Likewise.
19509 (DISTFILES): Likewise.
19510 (uninstall): Uninstall files in $(pkgdata_DATA).
19511 (DISTLIST): New target.
19512 (distdir): Use the contents of the file DISTLIST to get a list of
19513 distributed files.
19514
46b3b8a5 195152005-03-18 Yoshinori K. Okuji <okuji@enbug.org>
19516
19517 * fs/fat.c (grub_fat_mount): Ignore the 3rd bit of a media
19518 descriptor. This is ported from GRUB Legacy.
19519
19520 * gencmdlist.sh: Added an extra semicolon to make it work with
19521 old sed versions. Reported by Robert Bihlmeyer
19522 <robbe@orcus.priv.at>.
19523
5822ff87 195242005-03-08 Yoshinori Okuji <okuji@enbug.org>
19525
19526 Automatic loading of commands is supported.
f19dbdb7 19527
5822ff87 19528 * normal/main.c (read_command_list): New function.
19529 (grub_normal_execute): Call read_command_list.
19530
19531 * normal/command.c (grub_register_command): Return zero or CMD.
19532 Allocate CMD->NAME from the heap.
19533 Initialize CMD->MODULE_NAME to zero.
19534 Find the same name as well. If the same command is found and it is
19535 a dummy command, overwrite members. If it is not a dummy command,
19536 return zero.
19537 (grub_unregister_command): Free Q->NAME and Q->MODULE_NAME.
19538 (grub_command_find): If a dummy command is found, load a module
19539 and retry to find a command only once.
19540
19541 * normal/cmdline.c (grub_tab_complete): Call grub_command_find to
19542 make sure that each command is loaded.
19543
19544 * include/grub/normal.h (GRUB_COMMAND_FLAG_NOT_LOADED): New
19545 macro.
19546 (struct grub_command): Remove const from the member `name'.
19547 Add a new member `module_name'.
19548 (grub_register_command): Return grub_command_t.
19549
19550 * commands/help.c (grub_cmd_help): Call grub_command_find to make
19551 sure that each command is loaded.
19552
19553 * genmk.rb (PModule::rule): Specify a module name without the
19554 suffix ".mod" to gencmdlist.sh.
19555
7b1f4b57 195562005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
19557
19558 * gencmdlist.sh: New file.
f19dbdb7 19559
7b1f4b57 19560 * genmk.rb (PModule::rule): Generate a rule for a command list.
19561 Clean command.lst.
19562 Generate command.lst from $(COMMANDFILES).
19563
19564 * Makefile.in (COMMON_DISTFILES): Added gencmdlist.sh.
19565 (DATA): Added $(pkgdata_DATA).
19566 (install-local): Install files in $(pkgdata_DATA).
19567
062aaf39 195682005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
19569
19570 * term/i386/pc/vga.c (debug_command): Removed.
19571 (GRUB_MOD_INIT): Do not register the command "debug".
19572
19573 From Hollis Blanchard:
19574 * commands/configfile.c: New file.
19575 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
19576 commands/configfile.c.
19577 (pkgdata_MODULES): Added configfile.mod.
19578 (configfile_mod_SOURCES): New variable.
19579 (configfile_mod_CFLAGS): Likewise.
19580 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
19581 commands/configfile.c.
19582 (pkgdata_MODULES): Added configfile.mod.
19583 (configfile_mod_SOURCES): New variable.
19584 (configfile_mod_CFLAGS): Likewise.
19585 * util/grub-emu.c (main): Call grub_configfile_init and
19586 grub_configfile_fini.
19587 * include/grub/normal.h [GRUB_UTIL] (grub_configfile_init): New
19588 prototype.
19589 [GRUB_UTIL] (grub_configfile_fini): Likewise.
f19dbdb7 19590
cee01aa6 195912005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
19592
19593 * normal/arg.c (grub_arg_show_help): Do not show the bug report
19594 address.
19595
19596 * commands/help.c (grub_cmd_help): Do not print newlines after
19597 the last command in print_command_help.
19598
93f3a1d8 195992005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
19600
19601 * commands/default.h: New file.
19602 * commands/timeout.h: Likewise.
19603 * normal/context.c: Likewise.
f19dbdb7 19604
93f3a1d8 19605 * util/misc.c: Do not include sys/times.h.
19606 Include sys/time.h and grub/machine/time.h.
19607 (grub_get_rtc): Rewritten with gettimeofday.
19608
19609 * util/grub-emu.c (main): Call grub_default_init and
19610 grub_timeout_init before grub_normal_init, and call
19611 grub_timeout_fini and grub_default_fini after grub_main.
19612
19613 * util/console.c (grub_ncurses_checkkey): Return the read
19614 character or -1.
19615
19616 * normal/menu.c (run_menu): Set MENU->TIMEOUT to -1 once it
19617 timeouts.
19618
19619 * normal/main.c (read_config_file): Push MENU. If this fails,
19620 print an error and wait for a user input.
19621 Print an error only if GRUB_ERRNO is not GRUB_ERR_NONE.
19622 If a menu is empty or an error occurs, pop MENU.
19623 (grub_normal_execute): Pop and free MENU after grub_menu_run
19624 returns.
19625
19626 * kern/loader.c (grub_loader_boot): Call grub_machine_fini.
19627
19628 * include/grub/powerpc/ieee1275/time.h [GRUB_UTIL]: Do not
19629 include time.h.
19630 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
19631 without GRUB_UTIL.
19632 * include/grub/i386/pc/time.h [GRUB_UTIL]: Do not include
19633 time.h.
19634 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
19635 without GRUB_UTIL.
19636
19637 * include/grub/normal.h (struct grub_menu_list): New struct.
19638 (grub_menu_list_t): New type.
19639 (struct grub_context): New struct.
19640 (grub_context_t): New type.
19641 (grub_register_command): Got rid of EXPORT_FUNC.
19642 (grub_unregister_command): Likewise.
19643 (grub_context_get): New prototype.
19644 (grub_context_get_current_menu): Likewise.
19645 (grub_context_push_menu): Likewise.
19646 (grub_context_pop_menu): Likewise.
19647 [GRUB_UTIL] (grub_default_init): Likewise.
19648 [GRUB_UTIL] (grub_default_fini): Likewise.
19649 [GRUB_UTIL] (grub_timeout_init): Likewise.
19650 [GRUB_UTIL] (grub_timeout_fini): Likewise.
19651
19652 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/default.c,
19653 commands/timeout.c and normal/context.c.
19654 (pkgdata_MODULES): Added default.mod and timeout.mod.
19655 (normal_mod_SOURCES): Added normal/context.c.
19656 (default_mod_SOURCES): New variable.
19657 (default_mod_CFLAGS): Likewise.
19658 (timeout_mod_SOURCES): Likewise.
19659 (timeout_mod_CFLAGS): Likewise.
19660 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Copied from
19661 conf/i386-pc.rmk.
19662 (pkgdata_MODULES): Added default.mod and timeout.mod.
19663 (normal_mod_SOURCES): Added normal/context.c.
19664 (default_mod_SOURCES): New variable.
19665 (default_mod_CFLAGS): Likewise.
19666 (timeout_mod_SOURCES): Likewise.
19667 (timeout_mod_CFLAGS): Likewise.
19668
19669 * Makefile.in (all-local): Added $(MKFILES).
19670
4ed2e1dd 196712005-02-21 Vincent Pelletier <subdino2004@yahoo.fr>
19672
19673 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `partmap/sun.c'.
19674 (grub_emu_SOURCES): Likewise.
19675 (pkgdata_MODULES): Add `sun.mod'.
19676 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
19677 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
19678 `partmap/sun.c'.
19679 (pkgdata_MODULES): Add `sun.mod'.
19680 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
19681 * include/grub/partition.h (grub_sun_partition_map_init): New
19682 prototype.
19683 (grub_sun_partition_map_fini): Likewise.
19684 * partmap/sun.c: New file.
19685 * util/grub-emu.c (main): Initialize and de-initialize the sun
19686 partitionmap support.
19687
4d4e372e 196882005-02-19 Yoshinori K. Okuji <okuji@enbug.org>
19689
19690 This implements an Emacs-like menu entry editor.
f19dbdb7 19691
4d4e372e 19692 * normal/menu_entry.c: New file.
f19dbdb7 19693
4d4e372e 19694 * util/console.c (grub_ncurses_putchar): Translate some Unicode
19695 characters to ASCII.
19696 (saved_char): New variable.
19697 (grub_ncurses_checkkey): Rewritten completely.
19698 (grub_ncurses_getkey): Likewise.
19699 (grub_ncurses_init): Call raw instead of cbreak.
19700
19701 * normal/menu.c (print_entry): Do not put a space.
19702 (init_page): Renamed to ...
19703 (grub_menu_init_page): ... this. All callers changed.
19704 (edit_menu_entry): Removed.
19705 (run_menu): Call grub_menu_entry_run instead of edit_menu_entry.
19706
19707 * normal/cmdline.c (grub_cmdline_run): Call grub_setcursor.
19708
19709 * kern/misc.c (grub_vprintf): Call grub_refresh.
19710
19711 * normal/menu.c (DISP_LEFT): Renamed to ...
19712 * include/grub/term.h (GRUB_TERM_DISP_LEFT): ... this.
19713 * normal/menu.c (DISP_UP): Renamed to ...
19714 * include/grub/term.h (GRUB_TERM_DISP_UP): ... this.
19715 * normal/menu.c (DISP_RIGHT): Renamed to ...
19716 * include/grub/term.h (GRUB_TERM_DISP_RIGHT): ... this.
19717 * normal/menu.c (DISP_DOWN): Renamed to ...
19718 * include/grub/term.h (GRUB_TERM_DISP_DOWN): ... this.
19719 * normal/menu.c (DISP_HLINE): Renamed to ...
19720 * include/grub/term.h (GRUB_TERM_DISP_HLINE): ... this.
19721 * normal/menu.c (DISP_VLINE): Renamed to ...
19722 * include/grub/term.h (GRUB_TERM_DISP_VLINE): ... this.
19723 * normal/menu.c (DISP_UL): Renamed to ...
19724 * include/grub/term.h (GRUB_TERM_DISP_UL): ... this.
19725 * normal/menu.c (DISP_UR): Renamed to ...
19726 * include/grub/term.h (GRUB_TERM_DISP_UR): ... this.
19727 * normal/menu.c (DISP_LL): Renamed to ...
19728 * include/grub/term.h (GRUB_TERM_DISP_LL): ... this.
19729 * normal/menu.c (DISP_LR): Renamed to ...
19730 * include/grub/term.h (GRUB_TERM_DISP_LR): ... this.
19731 * normal/menu.c (TERM_WIDTH): Renamed to ...
19732 * include/grub/term.h (GRUB_TERM_WIDTH): ... this.
19733 * normal/menu.c (TERM_HEIGHT): Renamed to ...
19734 * include/grub/term.h (GRUB_TERM_HEIGHT): ... this.
19735 * normal/menu.c (TERM_INFO_HEIGHT): Renamed to ...
19736 * include/grub/term.h (GRUB_TERM_INFO_HEIGHT): ... this.
19737 * normal/menu.c (TERM_MARGIN): Renamed to ...
19738 * include/grub/term.h (GRUB_TERM_MARGIN): ... this.
19739 * normal/menu.c (TERM_SCROLL_WIDTH): Renamed to ...
19740 * include/grub/term.h (GRUB_TERM_SCROLL_WIDTH): ... this.
19741 * normal/menu.c (TERM_TOP_BORDER_Y): Renamed to ...
19742 * include/grub/term.h (GRUB_TERM_TOP_BORDER_Y): ... this.
19743 * normal/menu.c (TERM_LEFT_BORDER_X): Renamed to ...
19744 * include/grub/term.h (GRUB_TERM_LEFT_BORDER_X): ... this.
19745 * normal/menu.c (TERM_BORDER_WIDTH): Renamed to ...
19746 * include/grub/term.h (GRUB_TERM_BORDER_WIDTH): ... this.
19747 * normal/menu.c (TERM_MESSAGE_HEIGHT): Renamed to ...
19748 * include/grub/term.h (GRUB_TERM_MESSAGE_HEIGHT): ... this.
19749 * normal/menu.c (TERM_BORDER_HEIGHT): Renamed to ...
19750 * include/grub/term.h (GRUB_TERM_BORDER_HEIGHT): ... this.
19751 * normal/menu.c (TERM_NUM_ENTRIES): Renamed to ...
19752 * include/grub/term.h (GRUB_TERM_NUM_ENTRIES): ... this.
19753 * normal/menu.c (TERM_FIRST_ENTRY_Y): Renamed to ...
19754 * include/grub/term.h (GRUB_TERM_FIRST_ENTRY_Y): ... this.
19755 * normal/menu.c (TERM_ENTRY_WIDTH): Renamed to ...
19756 * include/grub/term.h (GRUB_TERM_ENTRY_WIDTH): ... this.
19757 * normal/menu.c (TERM_CURSOR_X): Renamed to ...
19758 * include/grub/term.h (GRUB_TERM_CURSOR_X): ... this.
19759 All callers changed.
19760
19761 * include/grub/normal.h: New prototype.
19762
19763 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
19764 normal/menu_entry.c.
19765 (normal_mod_SOURCES): Likewise.
19766 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
19767 (normal_mod_SOURCES): Likewise.
19768
e6b92c8a 197692005-02-15 Yoshinori K. Okuji <okuji@enbug.org>
19770
19771 * include/grub/normal.h (grub_halt_init): New prototype.
19772 (grub_halt_fini): Likewise.
19773 (grub_reboot_init): Likewise.
19774 (grub_reboot_fini): Likewise.
19775
19776 * util/grub-emu.c: Include signal.h.
19777 (main_env): New global variable.
19778 (grub_machine_init): Ignore SIGINT. Otherwise grub-emu cannot
19779 catch C-c.
19780 (grub_machine_fini): New function.
19781 (main): Call grub_halt_init and grub_reboot_init before
19782 grub_main, and grub_reboot_fini and grub_halt_fini after it.
19783 Call setjmp with MAIN_ENV to go back afterwards.
19784 Call grub_machine_fini right before return.
19785
19786 * include/grub/util/misc.h: Include setjmp.h.
19787 (main_env): New prototype.
19788
19789 * include/grub/kernel.h (grub_machine_fini): New prototype.
19790 * include/grub/i386/pc/biosdisk.h (grub_biosdisk_fini): Likewise.
19791 * include/grub/i386/pc/console.h (grub_console_fini): Likewise.
19792
19793 * disk/i386/pc/biosdisk.c (grub_biosdisk_fini): New function.
19794 * kern/i386/pc/init.c (grub_machine_fini): Likewise.
19795 * term/i386/pc/console.c (grub_console_fini): Likewise.
f19dbdb7 19796
e6b92c8a 19797 * util/i386/pc/misc.c: New file.
f19dbdb7 19798
e6b92c8a 19799 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
19800 util/i386/pc/misc.c, commands/i386/pc/halt.c and
19801 commands/i386/pc/reboot.c.
19802
c642636f 198032005-02-14 Guillem Jover <guillem@hadrons.org>
19804
19805 * include/grub/dl.h (grub_dl_check_header): New prototype.
19806 (grub_arch_dl_check_header): Change return type to grub_err_t,
19807 remove size parameter and export function. Update all callers.
19808 * kern/dl.c (grub_dl_check_header): New function.
19809 (grub_dl_load_core): Use `grub_dl_check_header' instead of
19810 `grub_arch_dl_check_header'. Check ELF type. Check if sections
19811 are inside the core.
19812 * kern/i386/dl.c (grub_arch_dl_check_header): Remove arch
19813 independent ELF header checks.
19814 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
19815 * loader/i386/pc/multiboot.c (grub_rescue_cmd_multiboot): Use
19816 `grub_dl_check_header' instead of explicit checks. Check for the
19817 ELF type.
19818 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Use
19819 `grub_dl_check_header' instead of explicit checks. Remove arch
19820 specific ELF header checks.
19821
e6b92c8a 19822 * util/grub-emu.c (grub_arch_dl_check_header): Remove the
19823 argument SIZE.
19824
5eabe94b 198252005-02-13 Hollis Blanchard <hollis@penguinppc.org>
19826
19827 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add ls.mod.
19828 * include/grub/powerpc/libgcc.h (__mulsf3): New prototype.
19829
1b14a681 198302005-02-12 Hollis Blanchard <hollis@penguinppc.org>
19831
19832 * kern/partition.c (grub_partition_probe): Clear `grub_errno' and
f19dbdb7 19833 return 0 if `grub_errno' is GRUB_ERR_BAD_PART_TABLE.
1b14a681 19834 (part_map_iterate): Clear `grub_errno' and return 0 if
f19dbdb7 19835 `partmap->iterate' returns GRUB_ERR_BAD_PART_TABLE.
1b14a681 19836 * partmap/amiga.c (amiga_partition_map_iterate): Return
19837 GRUB_ERR_BAD_PART_TABLE if no partition map magic is found.
19838 * partmap/apple.c (apple_partition_map_iterate): Likewise.
19839
aca108aa 198402005-02-01 Guillem Jover <guillem@hadrons.org>
19841
19842 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Fix module
19843 help info.
19844
c9f9c556 198452005-01-31 Marco Gerards <metgerards@student.han.nl>
19846
19847 * include/grub/powerpc/ieee1275/loader.h (grub_load_linux):
19848 Removed prototype.
19849 (grub_rescue_cmd_linux): New prototype.
19850 (grub_rescue_cmd_initrd): Likewise.
19851 * powerpc/ieee1275/linux.c (grub_linux_boot): Remove struct
19852 `bi_rec'.
19853 (grub_linux_release_mem): Release the memory for the initrd.
19854 (grub_load_linux): Renamed from this...
19855 (grub_rescue_cmd_linux): ...To this. Changed all callers.
19856 Changed `entry' not to be static. Loop over memory regions to
19857 find another one when the default fails.
19858 (grub_rescue_cmd_initrd): New function.
19859 (grub_linux_init): Remove function.
19860 (grub_linux_fini): Likewise.
19861 (GRUB_MOD_INIT): Register `initrd'.
19862 (GRUB_MOD_FINI): Unregister `initrd'.
19863 * powerpc/ieee1275/linux_normal.c (grub_linux_normal_init):
19864 Function removed.
19865 (grub_linux_normal_fini): Likewise.
19866 (GRUB_MOD_INIT): Register `initrd'.
19867 (GRUB_MOD_FINI): Unregister `initrd'.
19868
990cf3aa 198692005-01-31 Marco Gerards <metgerards@student.han.nl>
19870
19871 * commands/help.c: New file.
19872 * normal/arg.c (show_help): Renamed to...
19873 (grub_arg_show_help): ... this.
19874 * commands/i386/pc/halt.c: New file.
19875 * commands/i386/pc/reboot.c: Likewise.
19876 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/help.c'.
19877 (pkgdata_MODULES): Add `reboot.mod', `halt.mod' and `help.mod'.
19878 (help_mod_SOURCES, help_mod_CFLAGS, reboot_mod_SOURCES)
19879 (reboot_mod_CFLAGS, halt_mod_SOURCES, halt_mod_CFLAGS): New
19880 variables.
19881 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
19882 `commands/help.c'.
19883 (pkgdata_MODULES): Add `help.mod'.
19884 (help_mod_SOURCES, help_mod_CFLAGS): New variables.
19885 * grub/i386/pc/init.h (grub_reboot): New prototype.
19886 (grub_halt): Likewise.
19887 * include/grub/normal.h (grub_arg_show_help): New prototype.
19888 (grub_help_init): Likewise.
19889 (grub_help_fini): Likewise.
19890 * util/grub-emu.c (main): Initialize and deinitialize the help
19891 command.
19892
19893 * normal/cmdline.c (grub_cmdline_get): Doc fix.
19894
19895 * normal/command.c (grub_command_init): Fixed the description of
19896 the `set' and `unset' commands.
19897
198982005-01-31 Marco Gerards <metgerards@student.han.nl>
0f79cdc1 19899
19900 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_interpret): New
19901 function.
19902 * commands/ieee1275/halt.c: New file.
19903 * commands/ieee1275/reboot.c: Likewise.
19904 * commands/ieee1275/suspend.c (grub_cmd_suspend): Use
19905 `__attribute__ ((unused))'. Some GCS related fixed.
19906 (grub_suspend_init) [GRUB_UTIL]: Function removed.
19907 (grub_suspend_fini): Likewise.
19908 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add `reboot.mod'
19909 and `halt.mod'.
19910 (reboot_mod_SOURCES, reboot_mod_CFLAGS, halt_mod_SOURCES)
19911 (halt_mod_CFLAGS): New variables.
19912 * include/grub/powerpc/ieee1275/ieee1275.h
19913 (grub_ieee1275_interpret): New prototype.
19914
1ab09cc7 199152005-01-29 Yoshinori K. Okuji <okuji@enbug.org>
19916
19917 * include/grub/misc.h (memmove): New prototype.
19918 (memcpy): Likewise.
19919
8b8cbdb2 199202005-01-22 Hollis Blanchard <hollis@penguinppc.org>
19921
19922 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Don't initialize
19923 `devpath' to 0. Use `name' instead of `devpath' with `grub_strndup'.
19924
e3741a27 199252005-01-22 Marco Gerards <metgerards@student.han.nl>
19926
19927 * kern/misc.c (grub_strndup): Function rewritten.
19928
776bd780 199292005-01-22 Vincent Pelletier <subdino2004@yahoo.fr>
19930
19931 * normal/menu.c (TERM_WIDTH): Macro redefined.
19932 (TERM_TOP_BORDER_Y): Likewise.
19933 (draw_border): Replaced while-loop by a for-loop. Make the number
19934 of lines consistent with the number of lines displayed in
19935 print_entries. Added a margin below the rectangle.
19936 (print_entry): Make the entry fit in the rectangle.
19937 (print_entries): Display the scroll arrows next to the right
19938 border.
19939
78026bce 199402005-01-21 Marco Gerards <metgerards@student.han.nl>
19941
19942 * fs/minix.c (grub_minix_find_file): Reserve more space for
19943 `fpath' so the \0 can be stored. Use `grub_strcpy' instead of
19944 `grub_strncpy' to copy `path' into it.
19945
67bbaf0f 199462005-01-21 Marco Gerards <metgerards@student.han.nl>
19947
19948 Add the loopback device, a device via which files can be accessed
19949 as devices.
f19dbdb7 19950
67bbaf0f 19951 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/loopback.c'.
19952 (pkgdata_MODULES): Add loopback.mod.
19953 (loopback_mod_SOURCES): New variable.
19954 (loopback_mod_CFLAGS): Likewise.
19955 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
19956 `disk/loopback.c'.
19957 (pkgdata_MODULES): Add loopback.mod.
19958 (loopback_mod_SOURCES): New variable.
19959 (loopback_mod_CFLAGS): Likewise.
19960 * disk/loopback.c: new file.
19961 * include/grub/normal.h (grub_loop_init): New prototype.
19962 (grub_loop_fini): New prototype.
19963 * util/grub-emu.c (main): Initialize and de-initialize loopback
19964 support.
19965 * include/grub/disk.h (grub_disk_dev_id): Add
19966 `GRUB_DISK_DEVICE_LOOPBACK_ID'.
19967
6f1c18bd 199682005-01-20 Hollis Blanchard <hollis@penguinppc.org>
19969
19970 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_enter): New
19971 function.
19972 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add suspend.mod.
19973 (suspend_mod_SOURCES): New variable.
19974 (suspend_mod_CFLAGS): Likewise.
19975 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_enter):
19976 New prototype.
19977 * commands/ieee1275/suspend.c: New file.
19978
b38551da 199792005-01-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
19980
19981 * include/grub/dl.h (GRUB_MOD_INIT): Changed `__attribute__
f19dbdb7 19982 ((unused))' to `__attribute__ ((used))'.
b38551da 19983 (GRUB_MOD_FINI): Likewise.
19984 * kern/dl.c (grub_dl_load_file): Fix null pointer dereference.
19985 * genmk.rb (PModule): Assign space to common symbols when linking
19986 modules.
19987
777aff39 199882005-01-20 Marco Gerards <metgerards@student.han.nl>
19989
19990 * include/grub/mm.h (grub_mm_init_region): Change the type of the
19991 `unsigned' arguments to `grub_size_t'.
19992 (grub_malloc): Likewise.
19993 (grub_realloc): Likewise.
19994 (grub_memalign): Likewise.
19995 * kern/i386/dl.c (grub_arch_dl_check_header): Likewise.
19996 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
19997 * util/misc.c (grub_malloc): Likewise.
19998 (grub_realloc): Likewise.
19999 * kern/mm.c (get_header_from_pointer): Change the casts to
20000 `unsigned' into a cast to `grub_size_t'.
20001
20002 * fs/fshelp.c (grub_fshelp_find_file): The `oldnode' should always
20003 point to `currnode' when `currnode' is changed.
20004
20005 * util/grub-emu.c (main): Initialize `progname'. Reported by Nico
20006 Schottelius <nico-linux@schottelius.org>.
20007
d0ff18e1 200082005-01-09 Hollis Blanchard <hollis@penguinppc.org>
20009
20010 * util/powerpc/ieee1275/grub-mkimage.c: Include <string.h>.
20011 (note_path): Remove variable.
20012 (GRUB_IEEE1275_NOTE_NAME): New macro.
20013 (GRUB_IEEE1275_NOTE_TYPE): Likewise.
20014 (grub_ieee1275_note_hdr): New structure.
20015 (grub_ieee1275_note_desc): Likewise.
20016 (grub_ieee1275_note): Likewise.
20017 (load_note): Remove `dir' argument. All callers updated. Remove
20018 `note_img' and `path'. Do not load a file from `note_path'.
20019 Initialize a struct grub_ieee1275_note and write that to `out'.
20020 Use GRUB_IEEE1275_MODULE_BASE instead of MODULE_BASE.
20021
4ca7004c 200222005-01-05 Marco Gerards <metgerards@student.han.nl>
20023
20024 * util/misc.c (grub_util_read_image): Revert last change. It
20025 called `grub_util_read_at', which seeks from the beginning of the
20026 file.
20027
0b412211 200282005-01-04 Hollis Blanchard <hollis@penguinppc.org>
20029
20030 * TODO: Add note about endianness in grub-mkimage.
20031 * boot/powerpc/ieee1275/crt0.S (note): Remove unused .note
20032 section.
20033 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Add grub-mkimage.
20034 (grub_mkimage_SOURCES): New target.
20035 * include/grub/kernel.h (grub_start_addr): Remove variable.
20036 (grub_end_addr): Likewise.
20037 (grub_total_module_size): Likewise.
20038 (grub_kernel_image_size): Likewise.
20039 (GRUB_MODULE_MAGIC): New constant.
20040 (grub_module_info): New structure.
20041 (grub_arch_modules_addr): New prototype.
20042 (grub_get_end_addr): Remove prototype.
20043 * include/grub/i386/pc/kernel.h (grub_end_addr): New prototype.
20044 * include/grub/powerpc/ieee1275/kernel.h: New file.
20045 * include/grub/util/misc.h (grub_util_get_fp_size): New
20046 prototype.
20047 (grub_util_read_at): Likewise.
20048 (grub_util_write_image_at): Likewise.
20049 * kern/main.c (grub_get_end_addr): Remove function.
20050 (grub_load_modules): Call grub_arch_modules_addr instead of using
20051 grub_end_addr. Look for a grub_module_info struct in memory. Use
20052 the grub_module_info fields instead of calling grub_get_end_addr
20053 as loop conditions. Move grub_add_unused_region code here.
20054 (grub_add_unused_region): Remove function.
20055 * kern/i386/pc/init.c: Include grub/cache.h.
20056 (grub_machine_init): Remove call to grub_get_end_addr. Remove
20057 one call to add_mem_region.
20058 (grub_arch_modules_addr): New function.
20059 * kern/powerpc/ieee1275/init.c (grub_end_addr): Remove variable.
20060 (grub_total_module_size): Likewise.
20061 Include grub/machine/kernel.h.
20062 (grub_arch_modules_addr): New function.
20063 * util/grub-emu.c (grub_end_addr): Remove variable.
20064 (grub_total_module_size): Likewise.
20065 (grub_arch_modules_addr): New function.
20066 * util/misc.c: Include unistd.h.
20067 (grub_util_get_fp_size): New function.
20068 (grub_util_read_at): Likewise.
20069 (grub_util_write_image_at): Likewise.
20070 (grub_util_read_image): Call grub_util_read_at.
20071 (grub_util_write_image): Call grub_util_write_image_at.
20072 * util/i386/pc/grub-mkimage.c (generate_image): Allocate
20073 additional memory in kernel_img for a struct grub_module_info.
20074 Fill in that grub_module_info.
20075 * util/powerpc/ieee1275/grub-mkimage.c: New file.
20076
458786f8 200772005-01-03 Hollis Blanchard <hollis@penguinppc.org>
20078
20079 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_milliseconds):
20080 New function.
20081 * include/grub/powerpc/ieee1275/ieee1275.h
20082 (grub_ieee1275_milliseconds): New prototype.
20083 * include/grub/powerpc/ieee1275/time.h (GRUB_TICKS_PER_SECOND):
20084 Change to 1000.
20085 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Call
20086 grub_ieee1275_milliseconds.
20087
ac507d1b 200882005-01-03 Hollis Blanchard <hollis@penguinppc.org>
20089
20090 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_realmode): New
20091 variable.
20092 (find_options): New function.
20093 (cmain): Call find_options.
20094 * include/grub/powerpc/ieee1275/ieee1275.h
20095 (grub_ieee1275_realmode): New extern variable.
20096 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Only call
20097 grub_map if grub_ieee1275_realmode is false.
20098
6b8fd1c4 200992004-12-29 Marco Gerards <metgerards@student.han.nl>
20100
20101 * normal/cmdline.c (grub_cmdline_get): Redone logic so no empty
20102 lines are inserted and make it work like readline. Reported by
20103 Vincent Pelletier <subdino2004@yahoo.fr>.
20104
8514a1e0 201052004-12-28 Marco Gerards <metgerards@student.han.nl>
20106
20107 * boot/powerpc/ieee1275/crt0.S (_start): Don't set up the stack.
20108
20109 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCE): Remove
20110 `kern/powerpc/cache.S'.
20111
924b6140 201122004-12-27 Marco Gerards <metgerards@student.han.nl>
20113
20114 * genmk.rb: Handle the `Program' class in the main loop. Written
20115 by Johan Rydberg <jrydberg@gnu.org>.
20116 (Program): New class.
20117 (programs): New variable.
20118 * boot/powerpc/ieee1275/cmain.c: Include <grub/machine/ieee1275.h>
20119 instead of "grub/machine/ieee1275.h". Include <grub/kernel.h>
20120 instead of "grub/kernel.h". Include <grub/machine/init.h>.
20121 (help_arch): Function removed.
20122 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add
20123 `powerpc/libgcc.h' and `loader.h'.
20124 (pkgdata_PROGRAMS): New variable.
20125 (sbin_UTILITIES): Variable removed.
20126 (grub_emu_SOURCES): Added kern/powerpc/cache.S.
20127 (grubof_SOURCES): Variable re-defined so it only includes the
20128 core functionality.
20129 (grubof_CFLAGS): Remove `-DGRUBOF'.
20130 (pkgdata_MODULES, fshelp_mod_SOURCES, fshelp_mod_CFLAGS,
20131 (fat_mod_SOURCES, fat_mod_CFLAGS, ext2_mod_SOURCES)
20132 (ext2_mod_CFLAGS, ufs_mod_SOURCES, ufs_mod_CFLAGS)
20133 (minix_mod_SOURCES, minix_mod_CFLAGS, hfs_mod_SOURCES)
20134 (hfs_mod_CFLAGS, jfs_mod_SOURCES, jfs_mod_CFLAGS)
20135 (iso9660_mod_SOURCES, iso9660_mod_CFLAGS, _linux_mod_SOURCES)
20136 (_linux_mod_CFLAGS, linux_mod_SOURCES, linux_mod_CFLAGS)
20137 (normal_mod_SOURCES, normal_mod_CFLAGS, normal_mod_ASFLAGS)
20138 (hello_mod_SOURCES, hello_mod_CFLAGS, boot_mod_SOURCES)
20139 (boot_mod_CFLAGS, terminal_mod_SOURCES, terminal_mod_CFLAGS)
20140 (ls_mod_SOURCES, ls_mod_CFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
20141 (cat_mod_SOURCES, cat_mod_CFLAGS, font_mod_SOURCES)
20142 (font_mod_CFLAGS, amiga_mod_SOURCES, amiga_mod_CFLAGS)
20143 (apple_mod_SOURCES, apple_mod_CFLAGS, pc_mod_SOURCES)
20144 (pc_mod_CFLAGS): New variables.
20145 * disk/powerpc/ieee1275/ofdisk.c: Include <grub/machine/init.h>.
20146 (grub_ofdisk_iterate): Add a prototype for `dev_iterate'.
20147 * include/grub/dl.h (grub_arch_dl_sync_caches): New prototype.
20148 * include/grub/loader.h (grub_os_area_addr, grub_os_area_size):
20149 Moved from here...
20150 * include/grub/i386/pc/init.h (grub_os_area_addr)
20151 (rub_os_area_size): ... to here.
20152 * include/grub/powerpc/ieee1275/ieee1275.h
20153 (grub_ieee1275_entry_fn): Export symbol.
20154 * include/grub/powerpc/ieee1275/init.h: New file.
20155 * include/grub/powerpc/libgcc.h: Likewise.
20156 * include/grub/cache.h: Likewise.
20157 * kern/powerpc/cache.S: Likewise. Written by Hollis Blanchard
20158 <hollis@penguinppc.org>.
20159 * kern/dl.c: Include <grub/cache.h>.
20160 (grub_dl_flush_cache): New function.
20161 (grub_dl_load_core): Call `grub_dl_flush_cache' to flush the cache
20162 for this module.
20163 * kern/powerpc/ieee1275/init.c (grub_ofdisk_init)
20164 (grub_console_init): Removed prototypes.
20165 (grub_machine_init): Don't initialize the modules anymore.
20166 * kern/powerpc/ieee1275/openfw.c (grub_map): Make the function
20167 static.
20168 * include/grub/powerpc/types.h (GRUB_HOST_WORDS_LITTLEENDIAN):
20169 Macro undef removed.
20170 (GRUB_HOST_WORDS_BIGENDIAN): New macro.
20171 * kern/powerpc/dl.c (grub_arch_dl_relocate_symbols): Add
20172 relocation `R_PPC_REL32'. Return an error when the relocation is
20173 unknown.
20174 * Makefile.in (DATA): Add `$(pkgdata_PROGRAMS)'.
20175 * kern/i386/pc/init.c (grub_arch_sync_caches): New function.
20176 * util/misc.c (grub_arch_sync_caches): Likewise.
20177
e4b47e0c 201782004-12-19 Marco Gerards <metgerards@student.han.nl>
20179
20180 * conf/powerpc-ieee1275.rmk (MOSTLYCLEANFILES): Remove
20181 `symlist.c', add `grubof_symlist.c'.
20182 (symlist.c): Variable removed.
20183 (grubof_HEADERS): Variable added.
20184 (grubof_symlist.c): New target.
20185 (kernel_syms.lst): Use `grubof_HEADERS' instead of
20186 `kernel_img_HEADERS'.
20187 (grubof_SOURCES): Add `kern/powerpc/dl.c' and `grubof_symlist.c'.
20188 * kern/powerpc/dl.c: New file.
20189 * kern/powerpc/ieee1275/init.c (grub_arch_dl_check_header):
20190 Function removed.
20191 (grub_arch_dl_relocate_symbols): Likewise.
20192 (grub_register_exported_symbols): Likewise.
20193
4ceb3636 201942004-12-13 Marco Gerards <metgerards@student.han.nl>
20195
20196 * fs/ext2.c (grub_ext2_open): Don't use data after freeing it.
20197 (grub_ext2_dir): Likewise. Don't return in case of an error, jump
20198 to fail instead. Reported by Vincent Pelletier
20199 <subdino2004@yahoo.fr>.
20200
20201 * fs/fshelp.c (grub_fshelp_find_file): Don't free `oldnode' when
20202 it is not allocated. Reported by Vincent Pelletier
20203 <subdino2004@yahoo.fr>.
20204
20205 * normal/cmdline.c (grub_tab_complete): Add a blank line to the
20206 output so the output looks better.
f19dbdb7 20207
3f1578fe 202082004-12-04 Marco Gerards <metgerards@student.han.nl>
20209
20210 Modulize the partition map support and add support for the amiga
20211 partition map.
f19dbdb7 20212
3f1578fe 20213 * commands/ls.c: Include <grub/partition.h> instead of
20214 <grub/machine/partition.h>.
20215 * kern/disk.c: Likewise.
20216 * kern/rescue.c: Likewise.
20217 * loader/i386/pc/chainloader.c: Likewise.
20218 * normal/cmdline.c: Likewise.
20219 * kern/powerpc/ieee1275/init.c: Likewise.
20220 (grub_machine_init): Call `grub_pc_partition_map_init',
20221 `grub_amiga_partition_map_init' and
20222 `grub_apple_partition_map_init'.
20223 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove
20224 `disk/i386/pc/partition.c'. Add `kern/partition.c'.
20225 (kernel_img_HEADERS): Remove `machine/partition.h'. Add
20226 `partition.h' and `pc_partition.h'.
20227 (grub_setup_SOURCES): Remove
20228 `disk/i386/pc/partition.c'. Add `kern/partition.c',
20229 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
20230 (grub_emu_SOURCES): Likewise.
20231 (pkgdata_MODULES): Add `amiga.mod', `apple.mod' and `pc.mod'.
20232 (amiga_mod_SOURCES, amiga_mod_CFLAGS, apple_mod_SOURCES)
20233 (apple_mod_CFLAGS, pc_mod_SOURCES, pc_mod_CFLAGS): New variables.
20234 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
20235 `disk/powerpc/ieee1275/partition.c'. Add `kern/partition.c',
20236 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
20237 (grubof_SOURCES): Likewise.
20238 * disk/i386/pc/partition.c: File removed.
20239 * disk/powerpc/ieee1275/partition.c: Likewise.
20240 * include/grub/powerpc/ieee1275/partition.h: Likewise.
20241 * include/grub/i386/pc/partition.h: Likewise.
20242 * kern/partition.c: New file.
20243 * partmap/amiga.c: Likewise.
20244 * partmap/apple.c: Likewise.
20245 * partmap/pc.c: Likewise.
20246 * include/grub/partition.h: Likewise..
20247 * include/grub/pc_partition.h: Likewise.
20248 * util/grub-emu.c: Include <grub/partition.h> instead of
20249 <grub/machine/partition.h>.
20250 (main): Call `grub_pc_partition_map_init',
20251 `grub_amiga_partition_map_init' and
20252 `grub_apple_partition_map_init' and deinitialize afterwards.
20253 * util/i386/pc/biosdisk.c: Include `#include
20254 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
20255 `<grub/machine/partition.h>'.
20256 * util/i386/pc/grub-setup.c: Likewise.
20257 * util/i386/pc/biosdisk.c: Likewise.
20258 (grub_util_biosdisk_get_grub_dev): Only access the PC specific
20259 partition information in case of a PC partition.
20260 * util/i386/pc/grub-setup.c: Include `#include
20261 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
20262 `<grub/machine/partition.h>'.
20263 (setup): Only access the PC specific partition information in case
20264 of a PC partition.
20265
0ef4ced9 202662004-11-17 Hollis Blanchard <hollis@penguinppc.org>
f19dbdb7 20267
0ef4ced9 20268 * kern/powerpc/ieee1275/init.c (grub_setjmp): Remove function.
20269 (grub_longjmp): Likewise.
20270 * include/grub/powerpc/setjmp.h (grub_jmp_buf): Set array size to
20271 20.
20272 * normal/powerpc/setjmp.S: New file.
20273 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
20274 `normal/powerpc/setjmp.S'.
20275 (grubof_CFLAGS): Add `-DGRUBOF'.
20276 * include/grub/setjmp.h [GRUB_UTIL]: Changed condition to
20277 [GRUB_UTIL && !GRUBOF].
f19dbdb7 20278
19950e29 202792004-11-16 Marco Gerards <metgerards@student.han.nl>
20280
20281 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Skip any
20282 property named `name'. Correctly handle the error returned by
20283 `grub_ieee1275_finddevice' if a device can not be opened.
20284
a2fea427 202852004-11-02 Hollis Blanchard <hollis@penguinppc.org>
20286
20287 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_readkey): Test
20288 `actual' for negativity.
20289 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
20290 kern/fshelp.c.
20291
41ea0ea3 202922004-11-01 Marco Gerards <metgerards@student.han.nl>
20293
20294 * term/i386/pc/vga.c (VGA_HEIGHT): Changed to 350.
20295 (PAGE_OFFSET): New macro.
20296 (CRTC_ADDR_PORT): Likewise.
20297 (CRTC_DATA_PORT): Likewise.
20298 (START_ADDR_HIGH_REGISTER): Likewise.
20299 (START_ADDR_LOW_REGISTER): Likewise.
20300 (GRAPHICS_ADDR_PORT): Likewise.
20301 (GRAPHICS_DATA_PORT): Likewise.
20302 (READ_MAP_REGISTER): Likewise.
20303 (INPUT_STATUS1_REGISTER): Likewise.
20304 (INPUT_STATUS1_VERTR_BIT): Likewise.
20305 (page): New variable.
20306 (wait_vretrace): New function.
20307 (set_read_map): Likewise.
20308 (set_start_address): Likewise.
20309 (grub_vga_init): Use mode 0x10 instead of mode 0x12. Switch to
20310 the right page.
20311 (check_vga_mem): Take the page into account.
20312 (write_char): Likewise.
20313 (write_cursor): Likewise.
20314 (scroll_up): Likewise. Copy the page to the page that is not
20315 shown and switch between both pages.
20316 (grub_vga_putchar): Fix off by one error.
20317 (grub_vga_cls): Wait for the vertical retrace. Take the page into
20318 account.
20319
ad0bd20b 203202004-11-01 Marco Gerards <metgerards@student.han.nl>
20321
20322 Add support for iso9660 (including rockridge).
f19dbdb7 20323
ad0bd20b 20324 * conf/i386-pc.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
20325 (iso9660_mod_SOURCES): New variable.
20326 (iso9660_mod_CFLAGS): Likewise.
20327 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
20328 * include/grub/fs.h (grub_iso9660_init): New prototype.
20329 * util/grub-emu.c (main): Call `grub_iso9660_init'.
20330 * fs/iso9660.c: New file.
20331
20332 * include/grub/misc.h (grub_strncat): New prototype.
20333 * kern/misc.c (grub_strncat): New function.
f19dbdb7 20334
ad0bd20b 20335 * fs/hfs.c (grub_hfs_mount): Translate the error
20336 `GRUB_ERR_OUT_OF_RANGE' to `GRUB_ERR_BAD_FS'.
20337 * fs/jfs.c (grub_jfs_mount): Likewise.
20338 * fs/ufs.c (grub_ufs_mount): Likewise.
20339
a5477a59 203402004-10-28 Hollis Blanchard <hollis@penguinppc.org>
20341
20342 * boot/powerpc/ieee1275/cmain.c (cmain): Remove asm statements
20343 which initialized BAT registers.
20344 * boot/powerpc/ieee1275/ieee1275.c (IEEE1275_CALL_ENTRY_FN,
20345 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
20346 Move from here...
20347 * include/grub/powerpc/ieee1275/ieee1275.h (IEEE1275_CALL_ENTRY_FN,
20348 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
20349 ... to here.
20350 * kern/powerpc/ieee1275/openfw.c (grub_map): New function.
20351 (grub_mapclaim): Likewise.
20352 * loader/powerpc/ieee1275/linux.c (grub_load_linux): Use
20353 grub_mapclaim instead of grub_ieee1275_claim. Assign linux_addr by
20354 hand.
20355
9304c1f8 203562004-10-19 Hollis Blanchard <hollis@penguinppc.org>
20357
20358 * conf/powerpc-ieee1275.rmk (COMMON_ASFLAGS): Remove -fno-builtin.
20359 (COMMON_CFLAGS): Remove -fno-builtin and -D__ASSEMBLY__. Add
20360 -ffreestanding and -msoft-float.
20361
86f4ae25 203622004-10-15 Hollis Blanchard <hollis@penguinppc.org>
20363
20364 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Do not
20365 append ":0" to devpath if the GRUB_IEEE1275_NO_PARTITION_0 flag is
20366 set in grub_ieee1275_flags.
20367
38912228 203682004-10-14 Hollis Blanchard <hollis@penguinppc.org>
20369
20370 * include/grub/powerpc/ieee1275/ieee1275.h (abort): Add function
20371 prototype.
20372 * kern/powerpc/ieee1275/init.c (grub_machine_init): Call
20373 grub_console_init first.
20374 Change the memory range used for grub_ieee1275_claim and
20375 grub_mm_init_region.
20376 Print an error message if the claim fails.
20377 Include <grub/misc.h>.
20378
d1923dc8 203792004-10-13 Hollis Blanchard <hollis@penguinppc.org>
20380
20381 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_iterate):
20382 Call grub_children_iterate for device nodes of type `scsi',
20383 `ide', or `ata'.
20384 (grub_ofdisk_open): Remove manual device alias resolution.
20385 Fix memory leak when device cannot be opened.
f19dbdb7 20386 * include/grub/powerpc/ieee1275/ieee1275.h
d1923dc8 20387 (grub_children_iterate): New prototype.
20388 * kern/powerpc/ieee1275/openfw.c (grub_children_iterate):
20389 New function.
20390 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
20391 Return -1 if args.size was -1.
20392
4512e4f3 203932004-10-11 Hollis Blanchard <hollis@penguinppc.org>
20394
20395 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_flags): New global.
20396 (cmain): Accept 3 parameters. Test for 0xdeadbeef, indicating Old
20397 World Macintosh. If Old Wold, set flag in grub_ieee1275_flags; claim
20398 Open Firmware's memory for it; claim memory from _start to _end.
20399 * boot/powerpc/ieee1275/crt0.S (__bss_start): New extern.
20400 (_end): New extern.
20401 (_start): Zero BSS from __bss_start to _end.
20402 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
20403 New extern.
20404 (GRUB_IEEE1275_NO_PARTITION_0): New #define.
20405
4d61feb0 204062004-10-11 Hollis Blanchard <hollis@penguinppc.org>
20407
ad0bd20b 20408 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): Return
20409 -1 if args.base was -1.
4d61feb0 20410
026fa2f9 204112004-10-08 Hollis Blanchard <hollis@penguinppc.org>
20412
20413 * term/powerpc/ieee1275/ieee1275.c (grub_ofconsole_cls): Use an ANSI
20414 escape sequence instead of a literal ^L. Also call
20415 grub_ofconsole_gotoxy.
20416
9f2220ef 204172004-10-03 Hollis Blanchard <hollis@penguinppc.org>
20418
20419 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): change
20420 void * arguments to grub_addr_t. All callers updated. Also make
20421 the `result' argument optional.
20422 (grub_ieee1275_release): change void * arguments to grub_addr_t.
20423 All callers updated.
20424
8a572cd7 204252004-09-22 Hollis Blanchard <hollis@penguinppc.org>
20426
20427 * commands/ls.c (grub_ls_list_files): Use the string following the
20428 initial ')', if present, as the filesystem path.
20429 * kern/rescue.c (grub_rescue_cmd_ls): Likewise.
20430
20431 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): List crt0.S first.
20432
18aa81f2 204332004-09-18 Yoshinori K. Okuji <okuji@enbug.org>
20434
20435 Make the source code of the menu interface more readable.
f19dbdb7 20436
18aa81f2 20437 * normal/menu.c: Include grub/mm.h.
20438 (TERM_WIDTH): New macro.
20439 (TERM_HEIGHT): Likewise.
20440 (TERM_INFO_HEIGHT): Likewise.
20441 (TERM_MARGIN): Likewise.
20442 (TERM_SCROLL_WIDTH): Likewise.
20443 (TERM_TOP_BORDER_Y): Likewise.
20444 (TERM_LEFT_BORDER_X): Likewise.
20445 (TERM_BORDER_WIDTH): Likewise.
20446 (TERM_MESSAGE_HEIGHT): Likewise.
20447 (TERM_BORDER_HEIGHT): Likewise.
20448 (TERM_NUM_ENTRIES): Likewise.
20449 (TERM_FIRST_ENTRY_Y): Likewise.
20450 (TERM_ENTRY_WIDTH): Likewise.
20451 (TERM_CURSOR_X): Likewise.
20452 (draw_border): Use macros instead of magic numbers.
20453 (print_entry): Likewise.
20454 (print_entries): Likewise.
20455 (run_menu): Likewise. Also, handle the key 'e'.
20456 (run_menu_entry): Ignore empty command lines.
20457 (print_message): Added a new argument EDIT. If EDIT is true,
20458 print a different message.
20459 (init_page): Likewise.
20460 (edit_menu_entry): New function. Not implemented yet.
20461
b47efe30 204622004-09-17 Marco Gerards <metgerards@student.han.nl>
20463
20464 Add `linux.mod' and `multiboot.mod' so linux and multiboot kernels
20465 can be loaded from normal mode.
f19dbdb7 20466
b47efe30 20467 * conf/i386-pc.rmk (pkgdata_MODULES): Add `linux.mod' and
20468 `multiboot.mod'.
20469 (linux_mod_SOURCES, linux_mod_CFLAGS, multiboot_mod_SOURCES)
20470 (multiboot_mod_CFLAGS): New variables.
20471 * loader/i386/pc/linux_normal.c: New file.
f19dbdb7 20472 * loader/i386/pc/multiboot_normal.c: Likewise.
20473
b47efe30 20474 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Don't use the
20475 attribute `unused'.
f19dbdb7 20476
b47efe30 20477 * fs/ext2.c (grub_ext2_iterate_dir): Fix typos in inode type. Use
20478 `fdiro' to read the mode information from instead of `diro'.
20479
20480 * fs/fshelp.c (grub_fshelp_find_file): Set type to foundtype after
20481 looking up a symlink.
20482
20483 * include/grub/normal.h (GRUB_COMMAND_FLAG_NO_ARG_PARSE): New
20484 macro.
20485 * normal/command.c (grub_command_execute): Don't parse the
20486 arguments when `GRUB_COMMAND_FLAG_NO_ARG_PARSE' is set in the
20487 flags of the command.
20488
20489 * normal/menu.c (grub_menu_run): Fix typo.
20490
da75ac71 204912004-09-14 Hollis Blanchard <hollis@penguinppc.org>
20492
20493 * kern/powerpc/ieee1275/init.c (abort): Trap into Open Firmware.
20494
20495 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_gotoxy): Use
20496 `y + 1' instead of `y - 1'.
20497
20498 * conf/powerpc-ieee1275.rmk (grubof_LDFLAGS): Add `-N' and `-S'.
f19dbdb7 20499
062b24c2 205002004-09-14 Yoshinori K. Okuji <okuji@enbug.org>
20501
20502 From Hollis Blanchard <hollis@penguinppc.org>:
20503 * kern/misc.c (memmove): New alias for grub_memmove.
20504 (memcmp): New alias for grub_memcmp.
20505 (memset): New alias for grub_memset.
f19dbdb7 20506 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
062b24c2 20507 Change "int handle" to "grub_ieee1275_phandle_t handle".
f19dbdb7 20508 * include/grub/powerpc/ieee1275/ieee1275.h
062b24c2 20509 (grub_ieee1275_get_property): Likewise.
f19dbdb7 20510
8ddad845 205112004-09-12 Tomas Ebenlendr <ebik@ucw.cz>
20512
20513 Added normal mode command `chainloader' as module chain.mod, which
20514 depends on normal.mod and _chain.mod.
f19dbdb7 20515
8ddad845 20516 * conf/i386-pc.rmk (pkgdata_MODULES): Add `chain.mod'.
20517 (chain_mod_SOURCES, chain_mod_CFLAGS): Variables added.
20518 * include/grub/i386/pc/loader.h (grub_rescue_cmd_chainloader):
20519 Deleted prototype.
20520 * loader/i386/pc/chainloader.c (grub_rescue_cmd_chainloader): All
20521 but arguments parsing moved to ...
20522 (grub_chainloader_cmd): ... here. New function.
20523 * include/grub/i386/pc/chainloader.h: New file.
20524 * loader/i386/pc/chainloader_normal.c: Likewise.
20525
2c1f4ce3 205262004-09-11 Marco Gerards <metgerards@student.han.nl>
20527
20528 * conf/i386-pc.rmk (kernel_img_SOURCES): Added kern/fshelp.c.
20529 (grub_mkimage_LDFLAGS): Likewise.
20530 (grub_emu_SOURCES): Likewise.
20531 (kernel_img_HEADERS): Added fshelp.h.
20532 * fs/ext2.c: Include <grub/fshelp.h>.
20533 (FILETYPE_REG): New macro.
20534 (FILETYPE_INO_REG): Likewise.
20535 (grub_ext_sblock): Renamed to `grub_ext2_sblock'.
20536 Changed all users.
20537 (ext2_block_group): Renamed to `grub_ext2_block_group'. Changed
20538 all users.
20539 (grub_fshelp_node): New struct.
20540 (grub_ext2_data): Added member `diropen'. Changed member `inode'
20541 to a pointer.
20542 (grub_ext2_get_file_block): Removed function.
20543 (grub_ext2_read_block): New function.
20544 (grub_ext2_read_file): Replaced parameter `data' by `node'.
20545 This function was written.
20546 (grub_ext2_mount): Read the root inode. Create a diropen struct.
20547 (grub_ext2_find_file): Removed function.
20548 (grub_ext2_read_symlink): New function.
20549 (grub_ext2_iterate_dir): Likewise.
20550 (grub_ext2_open): Rewritten.
20551 (grub_ext2_dir): Rewritten.
20552 * include/grub/fshelp.h: New file.
20553 * fs/fshelp.c: Likewise.
20554
3c52136a 205552004-09-10 Yoshinori K. Okuji <okuji@enbug.org>
20556
20557 * normal/menu.c: Include grub/loader.h and grub/machine/time.h.
20558 (print_message): Add a missing newline.
20559 (run_menu): Added timeout support.
20560 (run_menu_entry): New local function.
20561 (grub_menu_run): Added support for booting.
20562
20563 * kern/loader.c (grub_loader_is_loaded): New function.
20564
20565 * include/grub/powerpc/ieee1275/time.h: Include grub/symbol.h.
20566 (grub_get_rtc): Exported.
20567
20568 * include/grub/i386/pc/time.h: Include grub/symbol.h.
20569 (grub_get_rtc): Exported.
20570
20571 * include/grub/normal.h (struct grub_command_list): Remove
20572 constant from the member `command'.
20573
20574 * include/grub/loader.h (grub_loader_is_loaded): Declared.
20575
20576 * include/grub/err.h (GRUB_ERR_INVALID_COMMAND): New constant.
20577
20578 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/time.h.
20579
aa033560 205802004-08-28 Marco Gerards <metgerards@student.han.nl>
20581
20582 Add support for the JFS filesystem.
20583
20584 * fs/jfs.c: New file.
20585 * include/grub/fs.h (grub_jfs_init): New prototype.
20586 (grub_jfs_fini): New prototype.
20587 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/jfs.c.
20588 (grub_emu_SOURCES): Likewise.
20589 (pkgdata_MODULES): Add jfs.mod.
20590 (jfs_mod_SOURCES): New variable.
20591 (jfs_mod_CFLAGS): Likewise.
20592 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs.jfs.c.
20593 (grubof_SOURCES): Likewise.
20594 * util/grub-emu.c (main): Initialize and deinitialize JFS support.
20595
20596 * fs/fat.c (grub_fat_find_dir): Convert the filename little
20597 endian to the host endian.
20598 (grub_fat_utf16_to_utf8): Move function from there...
20599 * kern/misc.c (grub_utf16_to_utf8): ...to here. Do not convert
fe987087 20600 the endianness of the source string anymore.
aa033560 20601 * include/grub/misc.h (grub_utf16_to_utf8): New prototype.
20602
94bc45af 206032004-08-24 Marco Gerards <metgerards@student.han.nl>
20604
20605 * commands/boot.c (grub_boot_init) [GRUB_UTIL]: Make conditional.
20606 (grub_boot_fini) [GRUB_UTIL]: Likewise.
20607 (GRUB_MOD_INIT) [!GRUB_UTIL]: Likewise.
20608 (GRUB_MOD_FINI) [!GRUB_UTIL]: Likewise.
f19dbdb7 20609
94bc45af 20610 * fs/hfs.c (grub_hfs_find_node): Add a prototype for `node_found'.
20611 (grub_hfs_iterate_dir): Make the function static. Add prototypes
20612 for `node_found' and `it_dir'.
20613 (grub_hfs_dir): Add prototype for `dir_hook'.
20614
20615 * fs/minix.c (grub_minix_get_file_block): Add prototype for
20616 `grub_get_indir'. Rename `indir' in two blocks to `indir16'
20617 and `indir32' to silence a gcc warning.
20618
20619 * include/grub/fs.h (grub_hfs_init): New prototype.
20620 (grub_hfs_fini): Likewise.
f19dbdb7 20621
20622
97543f08 206232004-08-21 Yoshinori K. Okuji <okuji@enbug.org>
20624
20625 Each disk device has its own id now. This is useful to make use
20626 of multiple disk devices.
f19dbdb7 20627
97543f08 20628 * include/grub/disk.h (grub_disk_dev_id): New enum.
20629 (GRUB_DISK_DEVICE_BIOSDISK_ID): New constant.
20630 (GRUB_DISK_DEVICE_OFDISK_ID): Likewise.
20631
20632 * disk/i386/pc/biosdisk.c (grub_biosdisk_dev): Specify
20633 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
20634
20635 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_dev): Specify
20636 GRUB_DISK_DEVICE_OFDISK_ID as an id.
20637
20638 * util/i386/pc/biosdisk.c (grub_util_biosdisk_dev): Specify
20639 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
20640
20641 * include/grub/disk.h (struct grub_disk_dev): Added a new member
20642 "id" which is used by the cache manager.
20643
20644 * normal/main.c (grub_normal_init_page): Use "GNU GRUB" instead
20645 of just "GRUB".
20646
64372eb4 206472004-08-18 Marco Gerards <metgerards@student.han.nl>
20648
20649 * fs/hfs.c: New file.
20650 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/hfs.c.
20651 (grub_emu_SOURCES): Likewise.
20652 (pkgdata_MODULES): Add hfs.mod.
20653 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/hfs.c.
20654 (grubof_SOURCES): Likewise.
20655 * util/grub-emu.c (main): Initialize and deinitialize HFS support.
20656
20657 * include/grub/misc.h (grub_strncasecmp): Add prototype.
20658 * kern/misc.c (grub_strncasecmp): Add function.
20659
cc61b58f 206602004-08-14 Marco Gerards <metgerards@student.han.nl>
20661
20662 * include/grub/arg.h (GRUB_ARG_OPTION_OPTIONAL): Surround macro
20663 with parentheses.
20664
20665 * fs/ext2.c (FILETYPE_UNKNOWN): New macro.
20666 (grub_ext2_dir): In case the directory entry type is unknown, read
20667 it from the inode.
20668
0ef123f6 206692004-08-02 Peter Bruin <pjbruin@dds.nl>
20670
20671 * loader/powerpc/ieee1275/linux.c (grub_linux_init): Pass
20672 grub_load_linux instead of grub_rescue_cmd_linux as second
20673 argument of grub_rescue_register_command.
20674
20675 * Makefile.in (RMKFILES): Add conf/powerpc-ieee1275.rmk.
20676
a447c5df 206772004-07-27 Marco Gerards <metgerards@student.han.nl>
20678
20679 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_release): New
20680 function.
20681 * commands/boot.c: Remove the check for `GRUB_UTIL'.
20682 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
20683 `loader/powerpc/ieee1275/linux.c',
20684 `loader/powerpc/ieee1275/linux_normal.c' and `commands/boot.c'.
20685 * include/grub/powerpc/ieee1275/ieee1275.h
20686 (grub_ieee1275_release): New prototype.
20687 * include/grub/powerpc/ieee1275/loader.h: Rewritten.
20688 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize
20689 normal, boot, linux and linux_normal.
20690 * loader/powerpc/ieee1275/linux.c: New file.
20691 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
20692
5a9e3546 206932004-07-12 Marco Gerards <metgerards@student.han.nl>
20694
20695 * normal/arg.c (grub_arg_parse): Correct error handling after
20696 reallocating the argumentlist (check if `argl' is not null instead
20697 of checking if `args' is not null).
20698 * kern/mm.c (grub_realloc): Return the same pointer when using the
20699 same region, instead of returning the header address.
20700
e15199cb 207012004-07-11 Marco Gerards <metgerards@student.han.nl>
20702
20703 * disk/powerpc/ieee1275/partition.c (grub_partition_iterate): Skip
20704 one block instead of two when looking for the initial partition.
20705 (grub_partition_probe): Initialize the local variable `p' with 0.
20706 Use base 10 for the grub_strtoul call.
20707 * kern/misc.c (grub_strncpy): Fix off by one bug. Eliminated the
20708 need for one local variable.
20709 (grub_strtoul): Don't add the new value to `num', instead of that
20710 just assign it.
20711
020616c2 207122004-07-11 Marco Gerards <metgerards@student.han.nl>
20713
20714 * conf/i386-pc.rmk (pkgdata_IMAGE): Add pxeboot.img.
20715 (pxeboot_img_SOURCES): New variable.
20716 (pxeboot_img_ASFLAGS): Likewise.
20717 (pxeboot_img_LDFLAGS): Likewise.
20718 * boot/i386/pc/pxeboot.S: New file. Based on pxeloader.S from
20719 GRUB Legacy and boot.S. Adopted for GRUB 2 by lode leroy
20720 <lode_leroy@hotmail.com>.
20721
6c51eb64 207222004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
20723
20724 * kern/rescue.c (grub_enter_rescue_mode): Don't continue when
20725 there was no input.
20726
cfb12aff 207272004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
20728
20729 * normal/cmdline.c (grub_set_history): Fix off by one bug. Fixed
20730 the history buffer logic.
20731
6eabba74 207322004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
20733
20734 * fs/ext2.c (FILETYPE_INO_MASK, FILETYPE_INO_DIRECTORY)
20735 (FILETYPE_INO_SYMLINK): New macros.
20736 (grub_ext2_find_file): Check if the node is a directory using the
20737 inode stat information instead of using the filetype in the
20738 dirent. Exclude the first character of an absolute symlink.
20739 (grub_ext2_dir): Mask out the filetype part of the mode member of
20740 the inode.
20741
66e19ef8 207422004-05-24 Marco Gerards <metgerards@student.han.nl>
20743
20744 Add support for UFS version 1 and 2. Add support for the minix
20745 filesystem version 1 and 2, both the variants with 14 and 30 long
20746 filenames.
f19dbdb7 20747
66e19ef8 20748 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ufs.c and
20749 fs/minix.c.
20750 (grub_emu_SOURCES): Likewise.
20751 (pkgdata_MODULES): Add ufs.mod and minix.mod.
20752 (ufs_mod_SOURCES): New variable.
20753 (ufs_mod_CFLAGS): Likewise.
20754 (minix_mod_SOURCES): Likewise.
20755 (minix_mod_CFLAGS): Likewise.
20756 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/ufs.c and
20757 fs/minix.c.
20758 (grubof_SOURCES): Likewise.
20759 * fs/ufs.c: New file.
20760 * fs/minix.c: New file.
20761 * include/grub/fs.h (grub_ufs_init): New prototype.
20762 (grub_ufs_fini): Likewise.
20763 (grub_minix_init): Likewise.
20764 (grub_minix_fini): Likewise.
20765 * util/grub-emu.c (main): Initialize and deinitialize UFS and
20766 minix fs.
20767
cc2e748a 207682004-04-30 Jeroen Dekkers <jeroen@dekkers.cx>
20769
20770 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add normal/arg.c,
20771 commands/ls.c, commands/terminal.c, commands/boot.c,
20772 commands/cmp.c and commands/cat.c.
20773 (grubof_LDFLAGS): Add -nostdlib -static-libgcc -lgcc.
20774
20775 * kern/powerpc/ieee1275/init.c: Include "grub/env.h" instead of
20776 "env.h"
20777
4b13b216 207782004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
20779
20780 All symbols prefixed with PUPA_ and pupa_ are renamed to GRUB_
20781 and grub_, respectively. Because the conversion is trivial and
20782 mechanical, I omit the details here. Please refer to the CVS
20783 if you need more information.
20784
6a142551 207852004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
20786
20787 * include/pupa: Renamed to ...
20788 * include/grub: ... this.
20789 * util/i386/pc/pupa-mkimage.c: Renamed to ...
20790 * util/i386/pc/grub-mkimage.c: ... this.
20791 * util/i386/pc/pupa-setup.c: Renamed to ...
20792 * util/i386/pc/grub-setup.c: ... this.
20793 * util/pupa-emu.c: Renamed to ...
20794 * util/grub-emu.c: ... this.
20795
e56cdf21 207962004-03-29 Marco Gerards <metgerards@student.han.nl>
20797
20798 Add support for the newworld apple macintosh (PPC). This has been
20799 tested on the powerbook 2000 only. It only adds support for
20800 generic ieee1275 functions, console and disk support. This should
20801 be easy to port to other architectures with support for Open
20802 Firmware.
f19dbdb7 20803
e56cdf21 20804 * configure.ac: Accept the powerpc as host_cpu. In the case of
20805 the powerpc cpu set the host_vendor to ieee1275. Make sure the i386
20806 specific tests are only executed while building for the i386.
20807 Inverse test for crosscompile.
20808 * genmk.rb (Utility): Allow assembler files.
20809 * normal/cmdline.c (pupa_tab_complete): Reset pupa_errno.
20810 * conf/powerpc-ieee1275.rmk: New file.
20811 * disk/powerpc/ieee1275/ofdisk.c: Likewise.
20812 * disk/powerpc/ieee1275/partition.c: Likewise.
20813 * include/pupa/powerpc/ieee1275/biosdisk.h: Likewise.
20814 * include/pupa/powerpc/ieee1275/console.h: Likewise.
20815 * include/pupa/powerpc/ieee1275/partition.h: Likewise.
20816 * include/pupa/powerpc/ieee1275/time.h: Likewise.
20817 * include/pupa/powerpc/ieee1275/util/biosdisk.h: Likewise.
20818 * include/pupa/powerpc/ieee1275/multiboot.h: Likewise.
20819 * include/pupa/powerpc/ieee1275/loader.h
20820 * include/pupa/powerpc/setjmp.h: Likewise.
20821 * include/pupa/powerpc/types.h: Likewise.
20822 * kern/powerpc/ieee1275/init.c: Likewise.
20823 * kern/powerpc/ieee1275/openfw.c: Likewise.
20824 * term/powerpc/ieee1275/ofconsole.c: Likewise.
20825
20826 These files were written by Johan Rydberg
20827 (jrydberg@night.trouble.net) and I only modified them slightly.
f19dbdb7 20828
e56cdf21 20829 * boot/powerpc/ieee1275/cmain.c: New file.
20830 * boot/powerpc/ieee1275/crt0.S: Likewise.
20831 * boot/powerpc/ieee1275/ieee1275.c: Likewise.
20832 * include/pupa/powerpc/ieee1275/ieee1275.h: Likewise.
20833
8c8cc205 208342004-03-14 Jeroen Dekkers <jeroen@dekkers.cx>
20835
20836 * Makefile.in: Update copyright.
20837 * genmodsrc.sh: Likewise.
20838 * gensymlist.sh: Likewise.
20839 * term/i386/pc/vga.c: Indent correctly.
20840
20841 * util/i386/pc/pupa-mkimage.c (usage): Use PACKAGE_BUGREPORT as
20842 bugreporting address.
20843 * util/i386/pc/pupa-setup.c (usage): Likewise,
20844 (main): Call pupa_ext2_init and pupa_ext2_fini.
20845
f19dbdb7 20846 * fs/fat.c (log2): Renamed to ...
8c8cc205 20847 (fat_log2): ... this.
20848 All callers changed.
20849 * kern/misc.c (memcpy): Alias to pupa_memmove.
20850 * loader/i386/pc/multiboot.c (pupa_rescue_cmd_multiboot): Fix
20851 lvalue cast.
20852 * util/console.c (pupa_ncurses_fini): Return 0.
20853
20854 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open)[__linux__]:
20855 Move fail label here.
20856 [__GNU__]: Don't warn when using stat.
20857 (open_device)[!__linux__]: Check if FD < 0 instead of !FD.
20858 (pupa_util_biosdisk_get_pupa_dev)[__GNU__]: Change type of N to
20859 long int. Use strtol instead of strtoul.
f19dbdb7 20860
db1771cf 208612004-03-14 Marco Gerards <metgerards@student.han.nl>
20862
20863 * commands/boot.c: New file.
20864 * commands/cat.c: Likewise.
20865 * commands/cmp.c: Likewise.
20866 * commands/ls.c: Likewise.
20867 * commands/terminal.c: Likewise.
20868 * normal/command.c: Include <pupa/env.h> and <pupa/dl.h>.
20869 (pupa_register_command): Changed interface to match the new
20870 argument parser.
20871 (pupa_command_execute): Changed (almost rewritten) so it uses
20872 pupa_split_command. Added support for setting variables using the
20873 syntax `foo=bar'.
20874 (rescue_command): Changed to work with the new argument parser.
20875 (terminal_command): Moved from here to commands/terminal.c.
20876 (set_command): New function.
20877 (unset_command): New function.
20878 (insmod_command): New function.
20879 (rmmod_command): New function.
20880 (lsmod_command): New function.
20881 (pupa_command_init): Don't initialize the command terminal
20882 anymore. Initialize the commands set, unset, insmod, rmmod and
20883 lsmod.
20884 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/env.c.
20885 (kernel_img_HEADERS): Add arg.h and env.h.
20886 (pupa_mkimage_LDFLAGS): Add kern/env.c.
20887 (pupa_emu_SOURCES): Add kern/env.c, commands/ls.c,
20888 commands/terminal.c commands/boot.c commands/cmp.c commands/cat.c,
20889 normal/arg.c.
20890 (pkgdata_MODULES): Add ls.mod, boot.mod, cmp.mod, cat.mod and
20891 terminal.mod.
20892 (normal_mod_SOURCES): Add normal/arg.c and normal/arg.c.
20893 (boot_mod_SOURCES): New variable.
20894 (terminal_mod_SOURCES): Likewise.
20895 (ls_mod_SOURCES): Likewise.
20896 (cmp_mod_SOURCES): Likewise.
20897 (cat_mod_SOURCES): Likewise.
20898
20899 * normal/arg.c: New file.
20900 * kern/env.c: Likewise.
20901 * include/pupa/arg.h: Likewise.
20902 * include/pupa/env.h: Likewise.
20903 * font/manager.c (font_command): Changed to match argument parsing
20904 interface changes.
20905 (PUPA_MOD_INIT): Likewise.
20906 * hello/hello.c (pupa_cmd_hello): Likewise.
20907 (PUPA_MOD_INIT): Likewise.
20908 * include/pupa/disk.h: Include <pupa/device.h>.
20909 (pupa_print_partinfo): New prototype.
20910 * include/pupa/dl.h (pupa_dl_set_prefix): Prototype removed.
20911 (pupa_dl_get_prefix): Likewise.
20912 * include/pupa/misc.h: Include <pupa/err.h>.
20913 (pupa_isgraph): New prototype.
20914 (pupa_isdigit): Likewise.
20915 (pupa_split_cmdline): Likewise.
20916 * include/pupa/normal.h: Include <pupa/arg.h>.
20917 (pupa_command): Changed the prototype of the member `func' to
20918 match the argument parsing interface. Added member `options'.
20919 (pupa_register_command): Updated to match function.
20920 (pupa_arg_parse): New prototype.
20921 (pupa_hello_init) [PUPA_UTIL]: New prototype.
20922 (pupa_hello_fini) [PUPA_UTIL]: Likewise.
20923 (pupa_ls_init) [PUPA_UTIL]: Likewise.
20924 (pupa_ls_fini) [PUPA_UTIL]: Likewise.
20925 (pupa_cat_init) [PUPA_UTIL]: Likewise.
20926 (pupa_cat_fini) [PUPA_UTIL]: Likewise.
20927 (pupa_boot_init) [PUPA_UTIL]: Likewise.
20928 (pupa_boot_fini) [PUPA_UTIL]: Likewise.
20929 (pupa_cmp_init) [PUPA_UTIL]: Likewise.
20930 (pupa_cmp_fini) [PUPA_UTIL]: Likewise.
20931 (pupa_terminal_init) [PUPA_UTIL]: Likewise.
20932 (pupa_terminal_fini) [PUPA_UTIL]: Likewise.
20933 * kern/disk.c: Include <pupa/file.h>.
20934 (pupa_print_partinfo): New function.
20935 * kern/dl.c: Include <pupa/env.h>.
20936 (pupa_dl_dir): Variable removed.
20937 (pupa_dl_load): Use the environment variable `prefix' instead of
20938 the variable pupa_dl_dir.
20939 (pupa_dl_set_prefix): Function removed.
20940 (pupa_dl_get_prefix): Likewise.
20941 * kern/i386/pc/init.c: Include <pupa/env.h>.
20942 (pupa_machine_init): Use the environment variable `prefix' instead of
20943 using pupa_dl_set_prefix to set the prefix.
20944 * kern/main.c: Include <pupa/env.h>.
20945 (pupa_set_root_dev): Use the environment variable `prefix' instead of
20946 using pupa_dl_get_prefix to get the prefix.
20947 * kern/misc.c: Include <pupa/env.h>.
20948 (pupa_isdigit): New function.
20949 (pupa_isgraph): Likewise.
20950 (pupa_ftoa): Likewise.
20951 (pupa_vsprintf): Added support for printing values of the type
20952 `double'. Make it possible to format variable output when using
20953 formatting like `%1.2%f'.
20954 (pupa_split_cmdline): New function.
20955 * kern/rescue.c: Include <pupa/env.h>.
20956 (next_word): Removed function.
20957 (pupa_rescue_cmd_prefix): Likewise.
20958 (pupa_rescue_cmd_set): New function.
20959 (pupa_rescue_cmd_unset): New function.
20960 (pupa_enter_rescue_mode): Use the `pupa_split_cmdline' function to
20961 split the command line instead of splitting it here. Added
20962 support for setting variables using the syntax `foo=bar'. Don't
20963 initialize the prefix command anymore. Initialized the set and
20964 unset commands.
20965 * normal/cmdline.c: Include <pupa/env.h>.
20966 (pupa_tab_complete): Added prototypes for print_simple_completion,
20967 print_partition_completion, add_completion, iterate_commands,
20968 iterate_dev, iterate_part and iterate_dir. Moved code to print
20969 partition information from here to kern/disk.c.
fe6b695a 20970 (pupa_cmdline_run): Don't check if the function exists anymore.
db1771cf 20971 * normal/main.c: Include <pupa/env.h>.
20972 (pupa_rescue_cmd_normal): Use the environment variable `prefix'
20973 instead of using pupa_dl_get_prefix to get the prefix.
20974 * term/i386/pc/vga.c: Include <pupa/arg.h>.
20975 (check_vga_mem): Cast pointers to `void *' to silence a gcc
20976 warning.
20977 (pupa_vga_putchar) [! DEBUG_VGA]: Removed for this case.
20978 (pupa_vga_setcolor): Declare unused variables with `__attribute__
20979 ((unused))' to silence a gcc warning.
20980 (pupa_vga_setcolor): Likewise.
20981 (debug_command): Changed to match argument parsing
20982 interface changes.
20983 * util/pupa-emu.c: Include <pupa/env.h>.
20984 (options): Added 0's for unused fields to silence a gcc warning.
20985 (argp): Likewise.
20986 (main): Use the environment variable `prefix' instead of using
20987 pupa_dl_set_prefix to set the prefix. Initialize the commands ls,
20988 boot, cmp, cat and terminal. Finish the commands boot, cmp, cat
20989 and terminal.
20990
20991 * util/i386/pc/getroot.c: Include <pupa/i386/pc/util/biosdisk.h>.
20992 * util/misc.c: Include <malloc.h>.
20993 (pupa_malloc): Rewritten so errors are correctly reported.
20994 (pupa_realloc): Likewise.
20995 (pupa_memalign): Likewise.
20996 (pupa_mm_init_region): Declare unused variables with
20997 `__attribute__ ((unused))' to silence a gcc warning.
20998 * normal/i386/setjmp.S: Remove tab at the end of the file to
20999 silence a gcc warning.
21000 * loader/i386/pc/linux.c (pupa_rescue_cmd_initrd): Declare unused
21001 variables with `__attribute__ ((unused))' to silence a gcc
21002 warning.
21003 * loader/i386/pc/multiboot.c (pupa_multiboot_unload): Make the
21004 local variable i unsigned to silence a gcc warning.
21005
21006 * kern/term.c: Include <pupa/misc.h>.
21007 (pupa_more_lines): New variable.
21008 (pupa_more): Likewise.
21009 (pupa_putcode): When the pager is active pause at the end of every
21010 screen.
21011 (pupa_set_more): New function.
21012 * include/pupa/term.h (pupa_set_more): New prototype.
21013
21014
3b1139cb 210152004-03-07 Yoshinori K. Okuji <okuji@enbug.org>
21016
21017 Now this project is GRUB 2 rather than PUPA. The location of
21018 the CVS repository was moved to GRUB's.
f19dbdb7 21019
3b1139cb 21020 * configure.ac: Use bug-grub as the reporting address.
21021 Use GRUB instead of PUPA.
21022 Change the version number to 1.90.
21023
8367695c 210242004-02-24 Yoshinori K. Okuji <okuji@enbug.org>
21025
21026 * genkernsyms.sh: Updated copyright information.
21027 * genmk.rb: Likewise.
21028 * genmodsrc.sh: Likewise.
21029 * gensymlist.sh: Likewise.
21030 * boot/i386/pc/boot.S: Likewise.
21031 * boot/i386/pc/diskboot.S: Likewise.
21032 * disk/i386/pc/biosdisk.c: Likewise.
21033 * disk/i386/pc/partition.c: Likewise.
21034 * font/manager.c: Likewise.
21035 * fs/ext2.c: Likewise.
21036 * fs/fat.c: Likewise.
21037 * include/pupa/boot.h: Likewise.
21038 * include/pupa/device.h: Likewise.
21039 * include/pupa/disk.h: Likewise.
21040 * include/pupa/dl.h: Likewise.
21041 * include/pupa/elf.h: Likewise.
21042 * include/pupa/err.h: Likewise.
21043 * include/pupa/file.h: Likewise.
21044 * include/pupa/font.h: Likewise.
21045 * include/pupa/fs.h: Likewise.
21046 * include/pupa/kernel.h: Likewise.
21047 * include/pupa/loader.h: Likewise.
21048 * include/pupa/misc.h: Likewise.
21049 * include/pupa/mm.h: Likewise.
21050 * include/pupa/net.h: Likewise.
21051 * include/pupa/normal.h: Likewise.
21052 * include/pupa/rescue.h: Likewise.
21053 * include/pupa/setjmp.h: Likewise.
21054 * include/pupa/symbol.h: Likewise.
21055 * include/pupa/term.h: Likewise.
21056 * include/pupa/types.h: Likewise.
21057 * include/pupa/i386/setjmp.h: Likewise.
21058 * include/pupa/i386/types.h: Likewise.
21059 * include/pupa/i386/pc/biosdisk.h: Likewise.
21060 * include/pupa/i386/pc/boot.h: Likewise.
21061 * include/pupa/i386/pc/console.h: Likewise.
21062 * include/pupa/i386/pc/init.h: Likewise.
21063 * include/pupa/i386/pc/kernel.h: Likewise.
21064 * include/pupa/i386/pc/linux.h: Likewise.
21065 * include/pupa/i386/pc/loader.h: Likewise.
21066 * include/pupa/i386/pc/memory.h: Likewise.
21067 * include/pupa/i386/pc/multiboot.h: Likewise.
21068 * include/pupa/i386/pc/partition.h: Likewise.
21069 * include/pupa/i386/pc/time.h: Likewise.
21070 * include/pupa/i386/pc/vga.h: Likewise.
21071 * include/pupa/i386/pc/util/biosdisk.h: Likewise.
21072 * include/pupa/util/getroot.h: Likewise.
21073 * include/pupa/util/misc.h: Likewise.
21074 * include/pupa/util/resolve.h: Likewise.
21075 * kern/device.c: Likewise.
21076 * kern/disk.c: Likewise.
21077 * kern/dl.c: Likewise.
21078 * kern/err.c: Likewise.
21079 * kern/file.c: Likewise.
21080 * kern/fs.c: Likewise.
21081 * kern/loader.c: Likewise.
21082 * kern/main.c: Likewise.
21083 * kern/misc.c: Likewise.
21084 * kern/mm.c: Likewise.
21085 * kern/rescue.c: Likewise.
21086 * kern/term.c: Likewise.
21087 * kern/i386/dl.c: Likewise.
21088 * kern/i386/pc/init.c: Likewise.
21089 * kern/i386/pc/lzo1x.S: Likewise.
21090 * kern/i386/pc/startup.S: Likewise.
21091 * loader/i386/pc/chainloader.c: Likewise.
21092 * loader/i386/pc/linux.c: Likewise.
21093 * loader/i386/pc/multiboot.c: Likewise.
21094 * normal/cmdline.c: Likewise.
21095 * normal/command.c: Likewise.
21096 * normal/main.c: Likewise.
21097 * normal/menu.c: Likewise.
21098 * normal/i386/setjmp.S: Likewise.
21099 * term/i386/pc/console.c: Likewise.
21100 * term/i386/pc/vga.c: Likewise.
21101 * util/console.c: Likewise.
21102 * util/genmoddep.c: Likewise.
21103 * util/misc.c: Likewise.
21104 * util/pupa-emu.c: Likewise.
21105 * util/resolve.c: Likewise.
21106 * util/unifont2pff.rb: Likewise.
21107 * util/i386/pc/biosdisk.c: Likewise.
21108 * util/i386/pc/getroot.c: Likewise.
21109 * util/i386/pc/pupa-mkimage.c: Likewise.
21110 * util/i386/pc/pupa-setup.c: Likewise.
21111
e6eced71 211122004-02-15 Jeroen Dekkers <jeroen@dekkers.cx>
21113
21114 * fs/ext2.c (pupa_ext2_read_file): Correct the value of BLOCKEND
21115 when it is EXT2_BLOCK_SIZE (data). New argument READ_HOOK, all
21116 callers changed. Set DATA->DISK->READ_HOOK to READ_HOOK before
21117 reading and reset it after reading.
21118 (pupa_ext2_close): Return PUPA_ERR_NONE.
21119
21120 * include/pupa/i386/pc/linux.h (PUPA_LINUX_INITRD_MAX_ADDRESS):
21121 Correct value.
21122 (struct linux_kernel_header): Add kernel_version and
21123 initrd_addr_max.
21124 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Check whether
21125 pupa_file_read succeeds.
21126 (pupa_rescue_cmd_initrd): Implement.
21127
5aded270 211282003-12-03 Marco Gerards <metgerards@student.han.nl>
21129
21130 * fs/ext2.c (pupa_ext2_label): New function.
21131 (pupa_ext2_fs): Added label.
21132 * fs/fat.c (pupa_fat_label): New function.
21133 (pupa_fat_fs): Added label.
21134 * include/pupa/fs.h (struct pupa_fs): Added prototype label.
21135
21136 * kern/misc.c (pupa_strndup): New function.
21137 * include/pupa/misc.h (pupa_strndup): New prototype.
21138
21139 * include/pupa/normal.h: Include <pupa/err.h>.
21140 (pupa_set_history): New prototype.
21141 (pupa_iterate_commands): New prototype.
21142 * normal/cmdline.c: Include <pupa/machine/partition.h>,
21143 <pupa/disk.h>, <pupa/file.h>.
21144 (hist_size): New variable.
21145 (hist_lines): Likewise.
21146 (hist_end): Likewise.
21147 (hist_used): Likewise.
21148 (pupa_set_history): New function.
21149 (pupa_history_get): Likewise.
21150 (pupa_history_add): Likewise.
21151 (pupa_history_replace): Likewise.
21152 (pupa_tab_complete): Likewise.
21153 (pupa_cmdline_run): Added tab completion and history buffer. Tab
21154 completion shows partitionnames while completing partitions, this
21155 feature was suggested by Jeff Bailey.
21156 * normal/command.c (pupa_iterate_commands): New function.
21157 * normal/main.c (PUPA_DEFAULT_HISTORY_SIZE): New macro.
21158 (pupa_normal_init): Initialize history buffer.
21159 (PUPA_MOD_INIT): Likewise.
21160 (pupa_normal_fini): Free the history buffer.
21161 (PUPA_MOD_FINI): Likewise.
21162
21163 * util/console.c (pupa_ncurses_getkey): Accept 127 as backspace
21164 key.
21165
21166 * aclocal.m4 (pupa_I386_CHECK_REGPARM_BUG): New DEFUN.
21167 * configure.ac [i386]: Check for regparam bug.
21168 (NESTED_FUNC_ATTR) [! i386]: Defined.
21169
1f7315a3 211702003-11-17 Marco Gerards <metgerards@student.han.nl>
21171
21172 * conf/i386-pc.rmk (sbin_UTILITIES): Added pupa-emu.
21173 (pupa_setup_SOURCES): Added util/i386/pc/getroot.c.
21174 (pupa_emu_SOURCES): New variable.
21175 (pupa_emu_LDFLAGS): Likewise.
21176 * include/pupa/fs.h (pupa_ext2_init) [PUPA_UTIL]: New prototype.
21177 (pupa_ext2_fini) [PUPA_UTIL]: Likewise.
21178 * include/pupa/normal.h (pupa_normal_init) [PUPA_UTIL]: Likewise.
21179 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
21180 * include/pupa/setjmp.h [PUPA_UTIL]: Include <setjmp.h>.
21181 (pupa_jmp_buf): New typedef.
21182 (pupa_setjmp) [PUPA_UTIL]: New macro.
21183 (pupa_longjmp) [PUPA_UTIL]: Likewise.
21184 * include/pupa/term.h (struct pupa_term): New member `refresh'.
21185 (pupa_refresh): New prototype.
21186 * include/pupa/util/getroot.h: New file.
21187 * kern/misc.c (pupa_vsprintf): Refresh the screen after updating
21188 it.
21189 * kern/rescue.c (pupa_rescue_get_command_line): Likewise.
21190 (pupa_rescue_cmd_cat): Likewise.
21191 (pupa_rescue_cmd_ls): Likewise.
21192 (pupa_rescue_cmd_testload): Likewise.
21193 (pupa_rescue_cmd_lsmod): Likewise.
21194 * normal/cmdline.c (pupa_cmdline_get): Likewise.
21195 * normal/menu.c (run_menu): Likewise.
21196 * kern/term.c (pupa_cls): Likewise.
21197 (pupa_refresh): New function.
21198 * normal/normal.c (pupa_normal_init) [PUPA_UTIL]: New function.
21199 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
21200 * util/console.c: New file.
f19dbdb7 21201
1f7315a3 21202 * util/i386/pc/getroot.c: New file.
21203 * util/i386/pc/pupa-setup.c: Include <pupa/util/getroot.h>.
21204 (pupa_putchar): New function.
21205 (pupa_refresh): Likewise.
21206 (xgetcwd): Function moved to ...
21207 (strip_extra_slashes): Likewise.
21208 (get_prefix): Likewise.
f19dbdb7 21209 * util/i386/pc/getroot.c: ... here.
1f7315a3 21210 (find_root_device): Function moved and renamed to...
21211 * util/i386/pc/getroot.c (pupa_find_root_device): ... here.
21212 Changed all callers.
21213 * util/i386/pc/pupa-setup.c (guess_root_device): Function moved
21214 and renamed to...
21215 * util/i386/pc/getroot.c (pupa_guess_root_device): ... here.
21216 Changed all callers.
21217 * util/misc.c (pupa_memalign): New function.
21218 (pupa_mm_init_region): Likewise.
21219 (pupa_register_exported_symbols): Likewise.
21220 (pupa_putchar): Function removed.
21221 * util/pupa-emu.c: New file.
21222
9a5c1ade 212232003-11-16 Jeroen Dekkers <jeroen@dekkers.cx>
21224
21225 * conf/i386-pc.rmk (pkgdata_MODULES): Add _multiboot.mod.
21226 (_multiboot_mod_SOURCES): New variable.
21227 (_multiboot_mod_CFLAGS): Likewise.
21228 * loader/i386/pc/multiboot.c: New file.
21229 * include/pupa/i386/pc/multiboot.h: Likewise.
21230 * kern/i386/pc/startup.S: Include pupa/machine/multiboot.h.
21231 (pupa_multiboot_real_boot): New function.
21232 * include/pupa/i386/pc/loader.h: Include pupa/machine/multiboot.h.
21233 (pupa_multiboot_real_boot): New prototype.
21234 (pupa_rescue_cmd_multiboot): Likewise
21235 (pupa_rescue_cmd_module): Likewise.
21236
21237 * kern/loader.c (pupa_loader_set): Continue when
21238 pupa_loader_unload_func() fails.
21239 (pupa_loader_unset): New function.
21240 * include/pupa/loader.h (pupa_loader_unset): New prototype.
21241
21242 * kern/misc.c (pupa_stpcpy): New function.
21243 * include/pupa/misc.h (pupa_stpcpy): New prototype.
21244
8e72a9c0 212452003-11-12 Marco Gerards <metgerards@student.han.nl>
21246
21247 * disk/i386/pc/biosdisk.c (pupa_biosdisk_open): Correctly check
21248 for available extensions.
21249
21250 * include/pupa/i386/pc/time.h: New file.
21251 * kern/disk.c: Include <pupa/machine/time.h>.
21252 (PUPA_CACHE_TIMEOUT): New macro.
21253 (pupa_last_time): New variable.
21254 (pupa_disk_open): Flush the cache when there was a timeout.
21255 (pupa_disk_close): Reset the timer.
21256 * kern/i386/pc/startup.S (pupa_get_rtc): Renamed from
21257 pupa_currticks.
21258 * util/misc.c: Include <sys/times.h>
21259 (pupa_get_rtc): New function.
21260
c4adbd32 212612003-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
21262
21263 * fs/ext2.c (struct pupa_ext2_inode): Declare struct datablocks
21264 as blocks.
21265 (pupa_ext2_get_file_block): Use blocks member.
21266
21267 * fs/ext2.c (pupa_ext2_read_file): Only set skipfirst for the
21268 first block. Return -1 instead of pupa_errno on error.
21269
bfd30f06 212702003-10-27 Marco Gerards <metgerards@student.han.nl>
21271
21272 * README: In the pupa-mkimage example use _chain instead of chain
21273 and ext2 instead of fat.
21274 * TODO: Replace ext2fs with jfs as an example. Add an item for
21275 adding journal playback for ext2fs.
21276 * conf/i386-pc.rmk (pupa_setup_SOURCES): Added fs/ext2.c.
21277 (pkgdata_MODULES): Added ext2.mod.
21278 (ext2_mod_SOURCES): New variable.
21279 (ext2_mod_CFLAGS): Likewise.
21280 * include/pupa/err.h (pupa_err_t): Added PUPA_ERR_SYMLINK_LOOP.
21281 * include/pupa/misc.h (pupa_strncpy): New prototype.
21282 (pupa_strcat): Likewise.
21283 (pupa_strncmp): Likewise.
21284 * kern/misc.c (pupa_strcat): Enable function.
21285 (pupa_strncpy): New function.
21286 (pupa_strncmp): Likewise.
21287 * fs/ext2.c: New file.
f19dbdb7 21288
bfd30f06 21289 * kern/disk.c (pupa_disk_read): Set pupa_errno to PUPA_ERR_NONE
21290 when the read failed before retrying.
21291 * util/i386/pc/biosdisk.c (_LARGEFILE_SOURCE): Removed.
21292 (_FILE_OFFSET_BITS): Likewise.
21293 * configure.ac: Added AC_SYS_LARGEFILE.
21294
98d15063 212952003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
21296
21297 * genmk.rb (PModule#rule): Make sure to get only symbol names
21298 from the output of nm.
21299 Reported by Robert Millan <zeratul2@wanadoo.es>.
21300
18d9c7cd 213012003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
21302
21303 I forgot to check in these changes for a long time. This adds
21304 incomplete support for VGA console, and this is still very
21305 buggy. Also, a lot of consideration is required for I18N,
21306 UNICODE, and VGA font issues. Therefore, assume that this is
21307 such that "better than nothing".
f19dbdb7 21308
18d9c7cd 21309 * font/manager.c: New file.
21310 * include/pupa/font.h: Likewise.
21311 * include/pupa/i386/pc/vga.h: Likewise.
21312 * term/i386/pc/vga.c: Likewise.
21313 * util/unifont2pff.rb: Likewise.
21314
21315 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vga.h.
21316 (pkgdata_MODULES): Added vga.mod and font.mod.
21317 (vga_mod_SOURCES): New variables.
21318 (vga_mod_CFLAGS): Likewise.
21319 (font_mod_SOURCES): Likewise.
21320 (font_mod_CFLAGS): Likewise.
21321
21322 * include/pupa/err.h (PUPA_ERR_BAD_FONT): New constant.
21323
21324 * include/pupa/term.h: Include pupa/err.h.
f19dbdb7 21325 (struct pupa_term): Added init and fini.
18d9c7cd 21326 Changed the argument of putchar to pupa_uint32_t.
21327
21328 * include/pupa/i386/pc/console.h: Include pupa/symbol.h.
21329 (pupa_console_real_putchar): New prototype.
21330 (pupa_console_putchar): Removed.
21331 (pupa_console_checkkey): Exported.
21332 (pupa_console_getkey): Likewise.
21333
21334 * kern/misc.c (pupa_vsprintf): Add support for UNICODE
21335 characters.
21336
21337 * kern/term.c (pupa_term_set_current): Rewritten.
21338 (pupa_putchar): Likewise.
21339 (pupa_putcode): New function.
21340
21341 * kern/i386/pc/startup.S (pupa_console_putchar): Renamed to ...
21342 (pupa_console_real_putchar): ... this.
21343 (pupa_vga_set_mode): New function.
21344 (pupa_vga_get_font): Likewise.
21345
21346 * normal/command.c: Include pupa/term.h.
21347 (terminal_command): New function.
21348 (pupa_command_init): Register the command "terminal".
21349
21350 * normal/menu.c (DISP_LEFT): Changed to a UNICODE value.
21351 (DISP_UP): Likewise.
21352 (DISP_RIGHT): Likewise.
21353 (DISP_DOWN): Likewise.
21354 (DISP_HLINE): Likewise.
21355 (DISP_VLINE): Likewise.
21356 (DISP_UL): Likewise.
21357 (DISP_UR): Likewise.
21358 (DISP_LL): Likewise.
21359 (DISP_LR): Likewise.
21360
21361 * term/i386/pc/console.c (pupa_console_putchar): New function.
f19dbdb7 21362
977329f5 213632003-02-08 NIIBE Yutaka <gniibe@m17n.org>
21364
21365 * util/resolve.c (pupa_util_resolve_dependencies): BUG
21366 FIX. Reverse the path_list.
21367
21368 * include/pupa/normal.h: Export pupa_register_command and
21369 pupa_unregister_command.
21370
21371 * hello/hello.c (pupa_cmd_hello): New module.
21372 * conf/i386-pc.rmk: Added hello.mod.
21373
1f5ab428 213742003-01-31 Yoshinori K. Okuji <okuji@enbug.org>
21375
21376 * kern/i386/pc/lzo1x.S: New file.
f19dbdb7 21377
1f5ab428 21378 * util/i386/pc/pupa-mkimage.c: Include lzo1x.h.
21379 (compress_kernel): New variable.
21380 (generate_image): Heavily modified to support compressing a
21381 large part of the core image.
21382
21383 * util/misc.c (pupa_util_read_image): Fix a file descriptor
21384 leak.
21385 (pupa_util_load_image): New function.
21386
21387 * kern/i386/pc/startup.S: Include pupa/machine/kernel.h.
21388 (pupa_compressed_size): New variable.
21389 (codestart): Enable Gate A20 here.
21390 Decompress the compressed part of the core image.
21391 Rearrange the code to put functions and variables which are
21392 required for initialization in the non-compressed part.
21393 Include lzo1x.S.
21394
21395 * kern/i386/pc/init.c (pupa_machine_init): Don't enable Gate A20
21396 here.
21397
21398 * include/pupa/util/misc.h (pupa_util_write_image): Declared.
21399
f19dbdb7 21400 * include/pupa/i386/pc/kernel.h
1f5ab428 21401 (PUPA_KERNEL_MACHINE_COMPRESSED_SIZE): New macro.
21402 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): Increased by 4.
21403 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
21404 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
21405 (PUPA_KERNEL_MACHINE_RAW_SIZE): New macro.
21406
21407 * conf/i386-pc.rmk (pupa_mkimage_LDFLAGS): New variable.
21408
21409 * genmk.rb (Image#rule): Put LDFLAGS at the end of a line.
21410 (Utility#rule): Likewise.
21411
21412 * configure.ac: Check if LZO is available.
21413
ce5bf700 214142003-01-20 Yoshinori K. Okuji <okuji@enbug.org>
21415
21416 * include/pupa/normal.h: New file.
21417 * include/pupa/setjmp.h: Likewise.
21418 * include/pupa/i386/setjmp.h: Likewise.
21419 * normal/cmdline.c: Likewise.
21420 * normal/command.c: Likewise.
21421 * normal/main.c: Likewise.
21422 * normal/menu.c: Likewise.
21423 * normal/i386/setjmp.S: Likewise.
f19dbdb7 21424
ce5bf700 21425 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Made global.
21426 (pupa_rescue_cmd_initrd): Likewise.
21427
21428 * loader/i386/pc/chainloader.c (pupa_rescue_cmd_chainloader):
21429 Likewise.
21430
21431 * kern/i386/pc/startup.S (translation_table): New variable.
21432 (translate_keycode): New function.
21433 (pupa_console_getkey): Call translate_keycode.
21434
21435 * kern/rescue.c (attempt_normal_mode): New function.
21436 (pupa_enter_rescue_mode): Attempt to execute the normal mode. If
21437 it failed, print a message.
21438
21439 * kern/mm.c (pupa_real_malloc): Print more information when a
21440 free magic is broken.
21441 (pupa_free): If the first free header is not free actually, set
21442 it to P.
21443
21444 * kern/main.c (pupa_load_normal_mode): Just load the module
21445 "normal".
21446 (pupa_main): Don't print the message
21447 "Entering into rescue mode..." here.
21448
21449 * include/pupa/i386/pc/loader.h (pupa_rescue_cmd_initrd):
21450 Declared.
21451 (pupa_rescue_cmd_initrd): Likewise.
21452 (pupa_rescue_cmd_initrd): Likewise.
21453
21454 * include/pupa/symbol.h (FUNCTION): Specify the type.
21455 (VARIABLE): Likewise.
21456
21457 * include/pupa/err.h (pupa_err_t): Added
21458 PUPA_ERR_UNKNOWN_COMMAND.
21459
21460 * include/pupa/dl.h (pupa_dl_set_prefix): Exported.
21461 (pupa_dl_get_prefix): Likewise.
21462
21463 * conf/i386-pc.rmk (pkgdata_MODULES): Added normal.mod.
21464 Added _chain.mod and _linux.mod instead of chain.mod and
21465 linux.mod.
21466 (chain_mod_SOURCES): Renamed to ...
21467 (_chain_mod_SOURCES): ... this.
21468 (chain_mod_CFLAGS): Renamed to ...
21469 (_chain_mod_CFLAGS): ... this.
21470 (linux_mod_SOURCES): Renamed to ...
21471 (_linux_mod_SOURCES): ... this.
21472 (linux_mod_CFLAGS): Renamed to ...
21473 (_linux_mod_CFLAGS): ... this.
21474 (normal_mod_SOURCES): New variable.
21475 (normal_mod_CFLAGS): Likewise.
21476 (normal_mod_ASFLAGS): Likewise.
21477
214782003-01-18 Yoshinori K. Okuji <okuji@enbug.org>
21479
21480 * kern/rescue.c (pupa_rescue_cmd_rmmod): Call pupa_dl_unload, if
21481 possible.
21482
fe6b695a 21483 * kern/dl.c (pupa_dl_ref): Refer depending modules
ce5bf700 21484 recursively.
21485 (pupa_dl_unref): Unrefer depending modules recursively.
21486 Don't call pupa_dl_unload implicitly, because PUPA can crash if
21487 a module is unloaded before one depending on that module is
21488 unloaded.
21489 (pupa_dl_unload): Unload depending modules explicitly,
21490 if possible.
21491
c04da074 214922003-01-17 Yoshinori K. Okuji <okuji@enbug.org>
21493
21494 * include/pupa/i386/pc/linux.h: New file.
21495 * loader/i386/pc/linux.c: Likewise.
f19dbdb7 21496
c04da074 21497 * loader/i386/pc/chainloader.c (pupa_chainloader_boot_sector):
21498 Removed.
21499 (pupa_chainloader_unload): Return PUPA_ERR_NONE.
21500 (pupa_rescue_cmd_chainloader): Read the image to 0x7C00 instead
21501 of PUPA_CHAINLOADER_BOOT_SECTOR.
21502
21503 * kern/i386/pc/startup.S: Include pupa/machine/linux.h.
21504 (pupa_linux_prot_size): New variable.
21505 (pupa_linux_tmp_addr): Likewise.
21506 (pupa_linux_real_addr): Likewise.
21507 (pupa_linux_boot_zimage): New function.
21508 (pupa_linux_boot_bzimage): Likewise.
21509
21510 * kern/i386/pc/init.c (struct mem_region): New structure.
21511 (MAX_REGIONS): New macro.
21512 (mem_regions): New variable.
21513 (num_regions): Likewise.
21514 (pupa_os_area_addr): Likewise.
21515 (pupa_os_area_size): Likewise.
21516 (pupa_lower_mem): Likewise.
21517 (pupa_upper_mem): Likewise.
21518 (add_mem_region): New function.
21519 (compact_mem_regions): Likewise.
21520 (pupa_machine_init): Set PUPA_LOWER_MEM and PUPA_UPPER_MEM to
21521 the size of the conventional memory and that of so-called upper
21522 memory (before the first memory hole).
21523 Instead of adding each found region to free memory, use
21524 add_mem_region and add them after removing overlaps.
21525 Also, add only 1/4 of the upper memory to free memory. The rest
21526 is used for loading OS images. Maybe this is ad hoc, but this
21527 makes it much easier to relocate OS images when booting.
21528
21529 * kern/rescue.c (pupa_rescue_cmd_module): Removed.
21530 (pupa_enter_rescue_mode): Don't register initrd and module.
21531
21532 * kern/mm.c: Include pupa/dl.h.
21533
21534 * kern/main.c: Include pupa/file.h and pupa/device.h.
21535
21536 * kern/loader.c (pupa_loader_load_module_func): Removed.
21537 (pupa_loader_load_module): Likewise.
21538
21539 * kern/dl.c (pupa_dl_load): Use the suffix ``.mod'' instead of
21540 ``.o''.
21541
21542 * include/pupa/i386/pc/loader.h (pupa_linux_prot_size): Declared.
21543 (pupa_linux_tmp_addr): Likewise.
21544 (pupa_linux_real_addr): Likewise.
21545 (pupa_linux_boot_zimage): Likewise.
21546 (pupa_linux_boot_bzimage): Likewise.
21547
21548 * include/pupa/i386/pc/init.h (pupa_lower_mem): Declared.
21549 (pupa_upper_mem): Likewise.
21550 (pupa_gate_a20): Don't export, because turning off Gate A20 in a
21551 module is too dangerous.
21552
21553 * include/pupa/loader.h (pupa_os_area_addr): Declared.
21554 (pupa_os_area_size): Likewise.
21555 (pupa_loader_set): Remove the first argument. Loader doesn't
21556 manage modules or initrd any longer.
21557 (pupa_loader_load_module): Removed.
21558
21559 * conf/i386-pc.rmk (pkgdata_MODULES): Added linux.mod.
21560 (linux_mod_SOURCES): New variable.
21561 (linux_mod_CFLAGS): Likewise.
21562
a13f9237 215632003-01-07 Yoshinori K. Okuji <okuji@enbug.org>
21564
21565 * util/i386/pc/pupa-setup.c (setup): Convert the endianness of
21566 the length of a blocklist correctly.
21567
21568 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open) [__linux__]:
21569 Use ioctl only if the OS file is a block device.
21570 (pupa_util_biosdisk_open): Don't use ST.ST_BLOCKS, because it is
21571 not very useful for normal files.
21572
21573 * kern/main.c (pupa_set_root_dev): New function.
21574 (pupa_load_normal_mode): Likewise.
21575 (pupa_main): Call those above.
21576
21577 * include/pupa/types.h (pupa_swap_bytes16): Cast the result to
21578 pupa_uint16_t.
21579
21580 * include/pupa/kernel.h (pupa_enter_normal_mode): Removed.
21581
a5ffe966 215822003-01-06 Yoshinori K. Okuji <okuji@enbug.org>
21583
21584 * util/i386/pc/pupa-setup.c: Include pupa/machine/kernel.h.
21585 (setup): Configure the installed partition information and the
21586 dl prefix.
21587
21588 * loader/i386/pc/chainloader.c (my_mod): New variable.
21589 (pupa_chainloader_unload): New function.
21590 (pupa_rescue_cmd_chainloader): Refer itself.
21591 (PUPA_MOD_INIT): Save its own module in MY_MOD.
21592
21593 * kern/i386/pc/startup.S (install_partition): Removed.
21594 (version_string): Likewise.
21595 (config_file): Likewise.
21596 (pupa_install_dos_part): New variable.
21597 (pupa_install_bsd_part): Likewise.
21598 (pupa_prefix): Likewise.
21599 (pupa_chainloader_real_boot): Call pupa_dl_unload_all.
21600
21601 * kern/i386/pc/init.c: Include pupa/machine/kernel.h, pupa/dl.h
21602 and pupa/misc.h.
21603 (make_install_device): New function.
21604 (pupa_machine_init): Set the dl prefix.
21605
21606 * kern/rescue.c: Include pupa/rescue.h and pupa/dl.h.
21607 (buf): Renamed to ...
21608 (linebuf): ... this.
21609 (pupa_rescue_cmd_prefix): New function.
21610 (pupa_rescue_cmd_insmod): Likewise.
21611 (pupa_rescue_cmd_rmmod): Likewise.
21612 (pupa_rescue_cmd_lsmod): Likewise.
21613 (pupa_enter_rescue_mode): Register new commands: prefix, insmod,
21614 rmmod and lsmod.
21615
21616 * kern/mm.c (pupa_memalign): If failed even after invalidating
21617 disk caches, unload unneeded modules and retry.
21618
21619 * kern/misc.c (pupa_memmove): New function.
21620 (pupa_memcpy): Removed.
21621 (pupa_strcpy): New function.
21622 (pupa_itoa): Made static.
21623
21624 * kern/dl.c (pupa_dl_iterate): New function.
21625 (pupa_dl_ref): Likewise.
21626 (pupa_dl_unref): Likewise.
21627 (pupa_dl_unload): Return if succeeded or not.
21628 (pupa_dl_unload_unneeded): New function.
21629 (pupa_dl_unload_all): Likewise.
21630 (pupa_dl_init): Renamed to ...
21631 (pupa_dl_set_prefix): ... this.
21632 (pupa_dl_get_prefix): New function.
21633
21634 * include/pupa/i386/pc/kernel.h: Include pupa/types.h.
21635 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): New macro.
21636 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
21637 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
21638 (pupa_install_dos_part): Declared.
21639 (pupa_install_bsd_part): Likewise.
21640 (pupa_prefix): Likewise.
21641 (pupa_boot_drive): Likewise.
21642
21643 * include/pupa/types.h: Fix a typo.
21644
21645 * include/pupa/misc.h (pupa_memcpy): New macro. Just an alias to
21646 pupa_memmove.
21647 (pupa_memmove): Declared.
21648 (pupa_strcpy): Likewise.
21649
21650 * include/pupa/dl.h (PUPA_MOD_INIT): Change the prototype. Now
21651 pupa_mod_init takes one argument, its own module.
21652 (pupa_dl_unload_unneeded): Declared.
21653 (pupa_dl_unload_all): Likewise.
21654 (pupa_dl_ref): Likewise.
21655 (pupa_dl_unref): Likewise.
21656 (pupa_dl_iterate): Likewise.
21657 (pupa_dl_init): Renamed to ...
21658 (pupa_dl_set_prefix): ... this.
21659 (pupa_dl_get_prefix): Declared.
21660
21661 * fs/fat.c [!PUPA_UTIL] (my_mod): New variable.
f19dbdb7 21662 (pupa_fat_dir) [!PUPA_UTIL]: Prevent the fat module from being
a5ffe966 21663 unloaded.
21664 (pupa_fat_open) [!PUPA_UTIL]: Refer itself if succeeded.
21665 (pupa_fat_close) [!PUPA_UTIL]: Unrefer itself.
21666
21667 * configure.ac (tmp_CFLAGS): Added -Wshadow, -Wpointer-arith,
21668 -Wmissing-prototypes, -Wundef and -Wstrict-prototypes.
21669
012d7999 216702003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
21671
21672 * util/i386/pc/pupa-setup.c (setup): Define the internal
21673 function find_first_partition_start at the top level, because GCC
21674 3.0.x cannot compile internal functions in deeper scopes
21675 correctly.
21676 (find_root_device): Use lstat instead of stat.
21677 Don't follow symbolic links.
21678 Fix the path-constructing code.
21679
21680 * util/i386/pc/biosdisk.c [__linux__] (BLKFLSBUF): New macro.
21681 (pupa_util_biosdisk_open) [__linux__]: Get the size of a device
21682 by a BLKGETSIZE ioctl first, because block devices don't fill
21683 the member st_mode of the structure stat on Linux.
21684 [__linux__] (linux_find_partition): Use a temporary buffer
21685 REAL_DEV for the working space. Copy it to DEV before returning.
21686 (open_device) [__linux__]: Call ioctl with BLKFLSBUF to make the
21687 buffer cache consistent.
21688 (get_os_disk) [__linux__]: Use the length 5 instead of 4 for
21689 strncmp. The previous value was merely wrong.
21690 (pupa_util_biosdisk_get_pupa_dev): Use stat instead of lstat.
21691
21692 * fs/fat.c (pupa_fat_read_data): Shift 4 instead of 12 when the
21693 FAT size is 12. The previous value was merely wrong.
21694
21695 * kern/main.c (pupa_main): Don't split the starting message from
21696 newlines.
21697
21698 * kern/term.c (pupa_putchar): Put CR after LF instead of before
21699 LF, because BIOS goes crazy about character attributes in this
21700 case.
21701
1cc73a62 217022003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
21703
21704 * include/i386/pc/util/biosdisk.h: New file.
21705 * util/i386/pc/biosdisk.c: Likewise.
21706 * util/i386/pc/pupa-setup.c: Likewise.
f19dbdb7 21707
1cc73a62 21708 * Makefile.in (INCLUDE_DISTFILES): Added
21709 include/pupa/i386/pc/util/biosdisk.h.
21710 (UTIL_DISTFILES): Added biosdisk.c and pupa-setup.c under the
21711 directory util/i386/pc.
21712 (install-local): Added a rule for sbin_UTILITIES.
21713 (uninstall): Likewise.
21714
21715 * util/i386/pc/pupa-mkimage.c (usage): Fix a typo in the doc.
21716
21717 * util/misc.c (xrealloc): New function.
21718 (pupa_malloc): Likewise.
21719 (pupa_free): Likewise.
21720 (pupa_realloc): Likewise.
21721 (pupa_stop): Likewise.
21722 (pupa_putchar): Likewise.
21723
21724 * kern/disk.c (pupa_disk_read): Prevent L from underflowing.
21725
21726 * include/pupa/util/misc.h (xrealloc): Declared.
21727
21728 * include/pupa/i386/pc/boot.h (PUPA_BOOT_MACHINE_BPB_START): New
21729 macro.
21730 (PUPA_BOOT_MACHINE_BPBEND): Renamed to ...
21731 (PUPA_BOOT_MACHINE_BPB_END): ... this.
21732
21733 * include/pupa/fs.h [PUPA_UTIL] (pupa_fat_init): Declared.
21734 [PUPA_UTIL] (pupa_fat_fini): Likewise.
21735
21736 * fs/fat.c [PUPA_UTIL] (pupa_fat_init): Defined. Maybe a better
21737 way should be implemented.
21738 [PUPA_UTIL] (pupa_fat_fini): Likewise.
21739
21740 * disk/i386/pc/biosdisk.c (pupa_biosdisk_call_hook): Increase
21741 the size of NAME for safety.
21742 (pupa_biosdisk_iterate): Search hard disks to 0x90 instead of
21743 0x88.
21744
21745 * conf/i386-pc.rmk (sbin_UTILITIES): New variable.
21746 (pupa_setup_SOURCES): Likewise.
21747
21748 * genmk.rb (Utility#rule): Add $(BUILD_CFLAGS) into the rules.
21749
08b70fe8 217502002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
21751
21752 * kern/i386/pc/startup.S (push_get_mmap_entry): Revert to a
21753 bunch of pushl's from pusha, because this destroys the return
21754 value.
21755
62ddcc8f 217562002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
21757
21758 Use -mrtd and -mregparm=3 to reduce the generated code sizes.
21759 This means that any missing prototypes could be fatal. Also, you
21760 must take care when writing assembly code. See the comments at
21761 the beginning of startup.S, for more details.
f19dbdb7 21762
62ddcc8f 21763 * kern/i386/pc/startup.S (pupa_halt): Modified for the new
21764 compilation mechanism.
21765 (pupa_chainloader_real_boot): Likewise.
21766 (pupa_biosdisk_rw_int13_extensions): Likewise.
21767 (pupa_biosdisk_rw_standard): Likewise.
21768 (pupa_biosdisk_check_int13_extensions): Likewise.
21769 (pupa_biosdisk_get_diskinfo_int13_extensions): Likewise.
21770 (pupa_biosdisk_get_diskinfo_standard): Likewise.
21771 (pupa_get_memsize): Likewise.
21772 (pupa_get_mmap_entry): Likewise.
21773 (pupa_console_putchar): Likewise.
21774 (pupa_console_setcursor): Likewise.
21775 (pupa_getrtsecs): Use pushl instead of push.
21776
21777 * kern/i386/pc/init.c (pupa_machine_init): Use the scratch
21778 memory instead of the stack for a mmap entry, because some
21779 BIOSes may ignore the maximum size and overflow.
21780
21781 * conf/i386-pc.rmk (COMMON_CFLAGS): Added -mrtd and -mregparm=3.
21782
21783 * genmk.rb (PModule#rule): Compile automatically generated
21784 sources with module-specific CFLAGS as well as other sources.
21785
9962ed99 217862002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
21787
21788 * configure.ac: Check ld.
21789 Replace CFLAGS and CPPFLAGS with BUILD_CFLAGS and BUILD_CPPFLAGS
21790 respectively, before checking endianness and sizes.
21791
21792 * Makefile.in (LD): New variable.
f19dbdb7 21793
abdfc3c5 217942002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
21795
21796 * Makefile.in (BUILD_CC): CC -> BUILD_CC.
21797
6a161fa9 217982002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
21799
21800 * Changelog: New file.
21801