]> git.proxmox.com Git - grub2.git/blame - ChangeLog
2009-11-26 Felix Zielcke <fzielcke@z-51.de>
[grub2.git] / ChangeLog
CommitLineData
e30dd392
FZ
12009-11-26 Felix Zielcke <fzielcke@z-51.de>
2
3 * conf/i386-efi.rmk (grub_mkimage_SOURCES): Add `gnulib/progname.c'.
4 * conf/x86_64-efi.rmk (grub_mkimage_SOURCES): Likewise.
5
7656de4f
RM
62009-11-26 Robert Millan <rmh.grub@aybabtu.com>
7
8 * conf/i386-coreboot.rmk: Cleanup stale filenames from my previous
9 commit.
10 * conf/i386-efi.rmk: Likewise.
11 * conf/i386-ieee1275.rmk: Likewise.
12 * conf/powerpc-ieee1275.rmk: Likewise.
13 * conf/sparc64-ieee1275.rmk: Likewise.
14 * conf/x86_64-efi.rmk: Likewise.
15
db77c4d4
FZ
162009-11-26 Felix Zielcke <fzielcke@z-51.de>
17
18 * conf/any-emu.rmk (grub_emu_SOURCES): Add `gnulib/progname.c'.
19
a755bb04
FZ
202009-11-26 Felix Zielcke <fzielcke@z-51.de>
21
22 * conf/any-emu.rmk (grub_mkfont_SOURCES): Add `gnulib/progname.c'.
23
8a4c07fd
RM
242009-11-26 Robert Millan <rmh.grub@aybabtu.com>
25
26 * conf/common.rmk (sbin_UTILITIES): Add `grub-mkdevicemap'.
27 (grub_mkdevicemap_SOURCES): New variable.
28 (grub_probe_SOURCES, grub_fstest_SOURCES, grub_mkfont_SOURCES)
29 (grub_mkrelpath_SOURCES, grub_editenv_SOURCES)
30 (grub_pe2elf_SOURCES): Add `gnulib/progname.c'.
31 * conf/i386-coreboot.rmk (sbin_UTILITIES): Remove `grub-mkdevicemap'.
32 (grub_mkdevicemap_SOURCES): Remove.
33 * conf/i386-efi.rmk: Likewise.
34 * conf/i386-ieee1275.rmk: Likewise.
35 * conf/i386-pc.rmk: Likewise.
36 * conf/powerpc-ieee1275.rmk: Likewise.
37 * conf/sparc64-ieee1275.rmk: Likewise.
38 * conf/x86_64-efi.rmk: Likewise.
39 * util/elf/grub-mkimage.c: Include `<grub/i18n.h>' and `"progname.h"'.
40 (usage): Fix strings to use `program_name'.
41 (main): Initialize gettext.
42 * util/grub-editenv.c: Likewise.
43 * util/grub-emu.c: Likewise.
44 * util/grub-fstest.c: Likewise.
45 * util/grub-mkdevicemap.c: Likewise.
46 * util/grub-mkfont.c: Likewise.
47 * util/grub-mkrelpath.c: Likewise.
48 * util/grub-pe2elf.c: Likewise.
49 * util/grub-probe.c: Likewise.
50 * util/sparc64/ieee1275/grub-mkimage.c: Likewise.
51 * util/sparc64/ieee1275/grub-ofpathname.c: Likewise.
52 * util/sparc64/ieee1275/grub-setup.c: Likewise.
53
54 * util/misc.c: Include `"progname.h"'.
55 (progname): Remove variable.
56 (grub_util_warn, grub_util_info, grub_util_error): Use `program_name'.
57
6f61ed55
FZ
582009-11-25 Felix Zielcke <fzielcke@z-51.de>
59
60 * util/grub.d/10_linux.in (linux_entry): Quote the arguments to
61 printf and print a newline after the menuentry header line.
62 * util/grub.d/10_kfreebsd.in (kfreebsd_entry): Likewise.
63
f022876b
FZ
642009-11-25 Felix Zielcke <fzielcke@z-51.de>
65
66 autoconf >= 2.60 support $(localedir).
67
68 * INSTALL: Note that autoconf 2.60 is required.
69 * configure.ac (AC_PREREQ): Bump to 2.60.
70 * util/grub.d/10_kfreebsd.in (TEXTDOMAINDIR): Set to lowercased @localedir@.
71 * util/grub.d/10_linux.in (TEXTDOMAINDIR): Likewise.
72
6717926e
YB
732009-11-25 Yves Blusseau <yves.blusseau@zetam.org>
74
75 * configure.ac: move the call to AM_GNU_GETTEXT to avoid warnings when
76 aclocal is run.
77
08806a54
RM
782009-11-25 Robert Millan <rmh.grub@aybabtu.com>
79
80 * normal/main.c (grub_normal_read_line): Fix off-by-one
81 buffer overflow.
82
13b33fba
RM
832009-11-25 Robert Millan <rmh.grub@aybabtu.com>
84
85 * normal/main.c (grub_normal_execute): Replace "parser.sh" with
86 "parser.grub" in grub_command_execute() call.
87
4a8572e9
CPE
882009-11-24 Carles Pina i Estany <carles@pina.cat>
89
90 * conf/i386-coreboot.rmk (kernel_img_HEADERS): Add i18n.h.
91 * conf/i386-efi.rmk: Likewise.
92 * conf/i386-ieee1275.rmk: Likewise.
93 * conf/i386-pc.rmk: Likewise.
94 * conf/powerpc-ieee1275.rmk: Likewise.
95 * conf/sparc64-ieee1275.rmk: Likewise.
96 * conf/x86_64-efi.rmk: Likewise.
97 * gettext/gettex.c: Include <grub/i18n.h>.
98 * include/grub/misc.h (grub_gettext_dummy, grub_gettext): Move from
99 here ...
100 * include/grub/i18n.h: ... to here
101 * include/grub/i18n.h: ... to here.
102 * kern/misc.c: Include <grub/i18n.h>
103 (grub_gettext_dummy): Move above user.
104
bee48093
FZ
1052009-11-24 Felix Zielcke <fzielcke@z-51.de>
106
107 * util/Makefile.in (install-local): Convert a `for' into a normal
108 shell expansion.
109
a031e91c
RM
1102009-11-24 Robert Millan <rmh.grub@aybabtu.com>
111
112 * autogen.sh: Add automake call.
113 * config.guess: Remove.
114 * config.sub: Likewise.
115 * install-sh: Likewise.
116
26bec39d
FZ
1172009-11-24 Felix Zielcke <fzielcke@z-51.de>
118
119 * util/Makefile.in (install-local): Fix the use of $lang shell variable.
120
8e2532fd
FZ
1212009-11-24 Felix Zielcke <fzielcke@z-51.de>
122
123 * util/Makefile.in (install-local): Convert a make `$(foreach)'
124 function to a normal shell `for'.
125
fefa1b7d
FZ
1262009-11-24 Felix Zielcke <fzielcke@z-51.de>
127
128 * conf/i386-coreboot.rmk (grub_mkimage_SOURCES): Add `gnulib/progname.c'.
129
4501250b
FZ
1302009-11-24 Felix Zielcke <fzielcke@z-51.de>
131
132 * util/grub-mkrelpath.c: New file.
133 * conf/common.rmk (bin_UTILITIES): Add grub-mkrelpath.
134 (grub_mkrelpath_SOURCES): New variable.
135 * include/grub/util/misc.h: New function prototype.
136 * util/misc.c (make_system_path_relative_to_its_root): New function.
137
138 * util/grub-mkconfig_lib.in (bindir): New variable.
139 (grub_mkrelpath): Likewise.
140 (make_system_path_relative_to_its_root): Use grub-mkrelpath.
141
142 * util/probe.c (probe): Make the file path relative to its root.
143 Change a info message to use the GRUB path. Enable again the
144 check if we can read the file with GRUB facilities.
145
146 * util/i386/pc/grub-setup.c (setup): Make core.img path relative
147 to its root.
148
11d9778b
FZ
1492009-11-24 Felix Zielcke <fzielcke@z-51.de>
150
151 * Makefile.in: Don't include GRUB_CONTRIB makefiles with emu
152 platform.
153
4465287d
FZ
1542009-11-24 Felix Zielcke <fzielcke@z-51.de>
155
156 * util/getroot.c (grub_util_get_dev_abstraction): Properly use
157 strncmp().
158
62b47f22
FZ
1592009-11-24 Felix Zielcke <fzielcke@z-51.de>
160
161 * util/getroot.c (grub_util_is_dmraid): New function.
162 (grub_util_get_dev_abstraction): Treat dmraid and multipath
163 devices as normal ones, not as LVM.
164
1eafb9b9 1652009-11-23 Carles Pina i Estany <carles@pina.cat>
c3ea6bd4
CPE
166
167 * conf/common.rmk: Add grub-gettext_lib target and updates
168 lib_DATA and CLEANFILES. Adds gettext.mod SOURCES, CFLAGS,
169 LDFLAGS.
170 * gettext/gettext.c: New file. (Reads mo files).
171 * include/grub/file.h (grub_file_pread): New prototype.
172 * include/grub/i18n.h (_): New prototype.
173 * include/grub/misc.h (grub_gettext_dummy, grub_gettext): New
174 prototypes.
175 * kern/misc.c (grub_gettext_dummy): New function.
176 * normal/menu_text.c: Include <grub/i18n.h>.
177 * normal/menu_text.c (print_timeout): Gettexttize string.
178 * normal/menu_text.c (print_message): Gettexttize string.
c3ea6bd4
CPE
179 * util/grub.d/00_header.in: Define locale_dir and lang. insmod
180 gettext module and defines locale_dir and lang in grub.cfg.
181 * NEWS: Add gettext support.
182
0fdb2568
RM
1832009-11-23 Robert Millan <rmh.grub@aybabtu.com>
184
185 * util/hostdisk.c: Include `<grub/i18n.h>'.
186 (find_grub_drive): Use ARRAY_SIZE for map size calculation.
187 (make_device_name): Rewrite using asprintf.
188 (convert_system_partition_to_system_disk): Replace 0 with NULL.
189 (find_system_device): If a device is not found, generate one just
190 by reusing the OS path name.
191 (read_device_map): Make it permissible for device.map not to exist.
192
f515aa62
RM
1932009-11-23 Robert Millan <rmh.grub@aybabtu.com>
194
195 * script/sh/execute.c: Move from here ...
196 * script/execute.c: ... to here. Update all users.
197 * script/sh/function.c: Move from here ...
198 * script/function.c: ... to here. Update all users.
199 * script/sh/lexer.c: Move from here ...
200 * script/lexer.c: ... to here. Update all users.
201 * script/sh/main.c: Move from here ...
202 * script/main.c: ... to here. Update all users.
203 * script/sh/parser.y: Move from here ...
204 * script/parser.y: ... to here. Update all users.
205 * script/sh/script.c: Move from here ...
206 * script/script.c: ... to here. Update all users.
207
f84b481b
RM
2082009-11-23 Robert Millan <rmh.grub@aybabtu.com>
209
210 * configure.ac: Detect all `emu' platforms. Define
211 GRUB_MACHINE_* macros in TARGET_CFLAGS. Remove
212 --enable-grub-emu logic. Disable include/grub/machine
213 symlink on `emu' platforms.
214
215 * genkernsyms.sh.in: Use @TARGET_CFLAGS@ during symbol generation.
216 * gensymlist.sh.in: Likewise.
217
218 * include/grub/i386/coreboot/machine.h: Remove file.
219 * include/grub/i386/efi/machine.h: Likewise.
220 * include/grub/i386/ieee1275/machine.h: Likewise.
221 * include/grub/i386/pc/machine.h: Likewise.
222 * include/grub/i386/qemu/machine.h: Likewise.
223 * include/grub/powerpc/ieee1275/machine.h: Likewise.
224 * include/grub/sparc64/ieee1275/machine.h: Likewise.
225 * include/grub/x86_64/efi/machine.h: Likewise.
226
227 * commands/acpi.c: Remove `<grub/machine/machine.h>'.
228 * commands/halt.c: Likewise.
229 * commands/reboot.c: Likewise.
230 * include/grub/autoefi.h: Likewise.
231 * include/grub/i386/at_keyboard.h: Likewise.
232 * include/grub/i386/kernel.h: Likewise.
233 * include/grub/i386/loader.h: Likewise.
234 * include/grub/i386/pc/memory.h: Likewise.
235 * kern/dl.c: Likewise.
236 * kern/i386/coreboot/init.c: Likewise.
237 * loader/i386/bsd.c: Likewise.
238 * loader/i386/linux.c: Likewise.
239 * loader/multiboot_loader.c: Likewise.
240 * term/i386/pc/serial.c: Likewise.
241 * term/usb_keyboard.c: Likewise.
242
243 * include/grub/time.h [!GRUB_MACHINE_EMU]: Remove
244 `<grub/machine/machine.h>'
245 [!GRUB_MACHINE_EMU] (GRUB_TICKS_PER_SECOND): New macro.
246 * util/misc.c: Remove `<grub/machine/machine.h>' and
247 `<grub/machine/time.h>'.
248
249 * Makefile.in (enable_grub_emu): Remove variable.
250 Include $(srcdir)/conf/any-emu.mk for the `emu' platform.
251
252 * conf/any-emu.rmk: New file.
253 * conf/common.rmk (grub_emu_init.lst, grub_emu_init.h)
254 (grub_emu_init.c): Move from here ...
255 * conf/any-emu.rmk: ... to here.
256
257 * conf/i386-coreboot.rmk (sbin_UTILITIES): Remove `grub-emu'.
258 (grub_emu_SOURCES, grub_emu_LDFLAGS): Move from here ...
259 * conf/any-emu.rmk: ... to here.
260
4efeab03
RM
2612009-11-23 Robert Millan <rmh.grub@aybabtu.com>
262
263 * include/grub/parser.h (grub_parser_register): Document need
264 of `name' parameter.
265 * normal/main.c (grub_normal_read_line): Simplify prompt string.
266 * script/sh/main.c (grub_sh_parser, GRUB_MOD_INIT(sh)): Rename
267 "sh" to "grub".
268
ea1dd8bf
RM
2692009-11-23 Robert Millan <rmh.grub@aybabtu.com>
270
271 * Makefile.in ($(srcdir)/po/$(PACKAGE).pot): Pass --keyword=N_ to
272 `$(XGETTEXT)'.
273 * include/grub/i18n.h (N_): New macro.
274 * util/mkisofs/mkisofs.h: Likewise.
275 * util/mkisofs/mkisofs.c (ld_options): Wrap all translatable strings
276 around N_().
277 (usage): Use gettext() to translate help strings when printing them.
278
0c140626
RM
2792009-11-23 Robert Millan <rmh.grub@aybabtu.com>
280
281 Based on patch from Bean
282 (http://lists.gnu.org/archive/html/grub-devel/2009-08/msg00384.html)
283
284 * video/efi_fb.c: New file.
285 * conf/i386-efi.rmk (pkglib_MODULES): Add `efi_fb.mod'.
286 (efi_fb_mod_SOURCES, efi_fb_mod_CFLAGS, efi_fb_mod_LDFLAGS): New
287 variables.
288 * conf/x86_64-efi.rmk: Likewise.
289
87d58298
RM
2902009-11-22 Robert Millan <rmh.grub@aybabtu.com>
291
292 * util/i386/pc/grub-mkimage.c: Ungettextize grub_util_info() strings.
293 * util/i386/pc/grub-setup.c: Likewise.
294
994cc3a3
ST
2952009-11-21 Samuel Thibault <samuel.thibault@ens-lyon.org>
296
297 * util/getroot.c [__GNU__]: Include <hurd.h>, <hurd/lookup.h>, and
298 <hurd/fs.h>
299 [__GNU__] (grub_guess_root_device): Call file_name_lookup and
300 file_get_storage_info to implement grub_guess_root_device.
301
26a61d6a
FZ
3022009-11-21 Felix Zielcke <fzielcke@z-51.de>
303
304 * Makefile.in (target): Use make's builtin $(shell) function
305 instead of calling directly $(SHELL) to create the locale directories,
306 inside the $(foreach) function.
307
74ff1dd5
FZ
3082009-11-21 Felix Zielcke <fzielcke@z-51.de>
309
310 * util/grub-mkrescue.in: Print an error and usage if output option
311 has not been given.
312
0b787d0e
FZ
3132009-11-21 Felix Zielcke <fzielcke@z-51.de>
314
315 Patch from Loïc Minier <loic.minier@ubuntu.com>.
316 * util/grub.d/30_os-prober.in: Cope with Linux entries where
317 root and /boot are on different devices.
318
1164b270
RM
3192009-11-21 Robert Millan <rmh.grub@aybabtu.com>
320
321 Fix build for srcdir != objdir.
322
323 * Makefile.in (po/$(PACKAGE).pot): Rename to ...
324 ($(srcdir)/po/$(PACKAGE).pot): ... this. Run $(XGETTEXT) from
325 $(srcdir).
326 ($(foreach lang, $(LINGUAS), po/$(lang).po)): Rename to ...
327 ($(foreach lang, $(LINGUAS), $(srcdir)/po/$(lang).po): ... this. Use $^
328 reference for input.
329
13774a2f
RM
3302009-11-21 Robert Millan <rmh.grub@aybabtu.com>
331
332 * util/grub-mkrescue.in: Use source directory direcly (without copiing
333 or hardlinking it). Remove -J option, Joliet is not compatible with
334 multiple source directories.
335
efda854e
RM
3362009-11-21 Carles Pina i Estany <carles@pina.cat>
3372009-11-21 Robert Millan <rmh.grub@aybabtu.com>
338
339 * util/grub-mkrescue.in: Recognize `--override-directory' option.
340 (process_input_dir): New function. Process an arbitrary input
341 directory.
342 Misc adjustments to support both "override mode" and system-wide mode.
343
6c09890c
FZ
3442009-11-20 Felix Zielcke <fzielcke@z-51.de>
345
346 * configure.ac (UNIFONT_BDF): Rename to ...
347 (FONT_SOURCE): ... this. Update all users.
348
a797824f
FZ
3492009-11-20 Felix Zielcke <fzielcke@z-51.de>
350
351 * configure.ac: Add `/usr/share/fonts/X11/misc/unifont.pcf.gz'
352 to the list of unifont files to look for.
353
cd4f42b0
RM
3542009-11-19 Robert Millan <rmh.grub@aybabtu.com>
355
356 Patch from Joe Auricchio <jauricchio@gmail.com>
357 * commands/minicmd.c (grub_mini_cmd_clear): New function.
358 (GRUB_MOD_INIT(minicmd)): Register grub_mini_cmd_clear().
359 (GRUB_MOD_FINI(minicmd)): Unregister grub_mini_cmd_clear().
360
393c783d
FZ
3612009-11-19 Felix Zielcke <fzielcke@z-51.de>
362
363 * Makefile.in (install-local): Add a missing backslash.
364
b2f1e327
FZ
3652009-11-19 Felix Zielcke <fzielcke@z-51.de>
366
367 * include/grub/x86_64/io.h: New file.
368
f577f7a0
RM
3692009-11-19 Robert Millan <rmh.grub@aybabtu.com>
370
371 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `gnulib/progname.c'.
372 * util/i386/pc/grub-setup.c: Include `<grub/i18n.h>'.
373 Include `"progname.h"'.
374 (main): Initialize gettext.
375 * util/i386/pc/grub-setup.c: Gettexttize.
376 * util/i386/pc/grub-mkimage.c: Likewise.
377
378 * Makefile.in (po/*.po): Redefine as ...
379 ($(foreach lang, $(LINGUAS), po/$(lang).po)): ... this.
380
c37943b6
RM
3812009-11-19 Robert Millan <rmh.grub@aybabtu.com>
382
383 * conf/common.rmk (grub_mkisofs_SOURCES): Add `gnulib/progname.c'.
384 * util/mkisofs/mkisofs.c: Include `"progname.h"'.
385 (program_name): Remove.
386 (main): Initialize gettext support.
6323f705
RM
387 * util/mkisofs/mkisofs.h: Include `<locale.h>'.
388 Include `<libintl.h>'.
389 (_): New macro.
c37943b6
RM
390
391 * util/mkisofs/eltorito.c: Gettexttize.
392 * util/mkisofs/joliet.c: Likewise.
393 * util/mkisofs/mkisofs.c: Likewise.
c37943b6
RM
394 * util/mkisofs/multi.c: Likewise.
395 * util/mkisofs/rock.c: Likewise.
396 * util/mkisofs/tree.c: Likewise.
397 * util/mkisofs/write.c: Likewise.
398
5ce77c6e
RM
3992009-11-18 Robert Millan <rmh.grub@aybabtu.com>
400
401 * util/mkisofs/eltorito.c: Fix minor mistake in license text.
402 * util/mkisofs/iso9660.h: Likewise.
403 * util/mkisofs/joliet.c: Likewise.
404 * util/mkisofs/mkisofs.c: Likewise.
405 * util/mkisofs/mkisofs.h: Likewise.
406 * util/mkisofs/rock.c: Likewise.
407 * util/mkisofs/tree.c: Likewise.
408 * util/mkisofs/write.c: Likewise.
409
410 * util/mkisofs/eltorito.c (rcsid): Remove.
411 * util/mkisofs/hash.c: Likewise.
412 * util/mkisofs/joliet.c: Likewise.
413 * util/mkisofs/name.c: Likewise.
414 * util/mkisofs/rock.c: Likewise.
415 * util/mkisofs/tree.c: Likewise.
416 * util/mkisofs/write.c: Likewise.
417
1dabbc77
RM
4182009-11-18 Robert Millan <rmh.grub@aybabtu.com>
419
420 * util/mkisofs/match.c: Rewrite from scratch, using a linked list
421 instead of static allocation.
422 * util/mkisofs/match.h: Likewise.
423
633877cb
RM
4242009-11-18 Robert Millan <rmh.grub@aybabtu.com>
425
633877cb
RM
426 * Makefile.in (po/$(PACKAGE).pot): Process `po/POTFILES-shell' for
427 translatable Shell files.
428
af1c0c85
RM
4292009-11-18 Robert Millan <rmh.grub@aybabtu.com>
430
431 * Makefile.in ($(srcdir)/aclocal.m4): New target.
432
769ae37b
RM
4332009-11-17 Robert Millan <rmh.grub@aybabtu.com>
434
435 * INSTALL: Document Automake is needed for bootstrap.
769ae37b
RM
436 * util/grub.d/10_kfreebsd.in (bindir): New variable.
437 Add gettext initialization.
438 (kfreebsd_entry): Make menuentry output translatable.
439
4402009-11-17 Robert Millan <rmh.grub@aybabtu.com>
441
442 * Makefile.in (XGETTEXT, MSGMERGE, MSGFMT): New variables.
443 (po/$(PACKAGE).pot): Replace `xgettext' with `$(XGETTEXT)'.
444 (po/*.po): Replace `msgmerge' with `$(MSGMERGE)'.
445 (po/%.mo): Replace `msgfmt' with `$(MSGFMT)'.
446 (LINGUAS): Auto-generate using `po/LINGUAS'.
769ae37b
RM
447
4482009-11-17 Robert Millan <rmh.grub@aybabtu.com>
449
450 * configure.ac: Call AM_GNU_GETTEXT() (defines localedir, among
451 other things).
452 * Makefile.in (CPPFLAGS): Add `-DLOCALEDIR=\"$(localedir)\"'.
453 * util/i386/pc/grub-mkimage.c (main): Issue setlocale() and
454 bindtextdomain() calls for gettext initialization.
455
4562009-11-17 Robert Millan <rmh.grub@aybabtu.com>
457
458 * gnulib/progname.c: New file (imported from Gnulib).
459 * gnulib/progname.h: Likewise.
460 * conf/i386-pc.rmk (grub_mkimage_SOURCES): Add `gnulib/progname.c'.
461 * util/i386/pc/grub-mkimage.c: Include `"progname.h"'.
462 (usage): Replace `progname' with `program_name'.
463 (main): Use set_program_name() for program name initialization.
464
4652009-11-17 Robert Millan <rmh.grub@aybabtu.com>
466
467 * conf/common.rmk (grub_mkisofs_CFLAGS): Move `-I$(srcdir)/gnulib'
468 from here ...
469 * Makefile.in (CPPFLAGS): ... to here.
470
4712009-11-16 Robert Millan <rmh.grub@aybabtu.com>
472
473 * aclocal.m4: Move from here ...
474 * acinclude.m4: ... to here.
475 * autogen.sh: Add call to `aclocal'.
476 * configure.ac: Add AM_INIT_AUTOMAKE() after AC_INIT() call.
477
4782009-11-16 Robert Millan <rmh.grub@aybabtu.com>
479
480 * Makefile.in (CLEANFILES): Add `po/*.mo'.
481 (LINGUAS): New variable.
482 (all-local): Add `$(foreach lang, $(LINGUAS), po/$(lang).mo)'.
483 (install-local): Install MO files.
484 (po/$(PACKAGE).pot, po/*.po, po/%.mo): New rules.
485 * include/grub/i18n.h: New file.
769ae37b
RM
486 * util/grub.d/10_linux.in (bindir): New variable.
487 Add gettext initialization.
488 (linux_entry): Make menuentry output translatable.
489 * util/i386/pc/grub-mkimage.c: Include `<grub/i18n.h>'.
490 (usage): Make --help output translatable.
491 (main): Initialize gettext.
492
02c0a6ad
RM
4932009-11-17 Robert Millan <rmh.grub@aybabtu.com>
494
495 * import_gcry.py: New file (written by Vladimir with minor
496 adjustments).
497 * autogen.sh: Use import_gcry.py to auto-generate GRUB-ified
498 ciphers.
499 * INSTALL: Document that Python is required for bootstrap.
500
5012009-11-17 Robert Millan <rmh.grub@aybabtu.com>
502
503 Import ciphers from libgcrypt 1.4.4.
504
505 * lib/libgcrypt/cipher/ChangeLog
506 * lib/libgcrypt/cipher/ac.c
507 * lib/libgcrypt/cipher/arcfour.c
508 * lib/libgcrypt/cipher/bithelp.h
509 * lib/libgcrypt/cipher/blowfish.c
510 * lib/libgcrypt/cipher/camellia-glue.c
511 * lib/libgcrypt/cipher/camellia.c
512 * lib/libgcrypt/cipher/camellia.h
513 * lib/libgcrypt/cipher/cast5.c
514 * lib/libgcrypt/cipher/cipher.c
515 * lib/libgcrypt/cipher/crc.c
516 * lib/libgcrypt/cipher/des.c
517 * lib/libgcrypt/cipher/dsa.c
518 * lib/libgcrypt/cipher/ecc.c
519 * lib/libgcrypt/cipher/elgamal.c
520 * lib/libgcrypt/cipher/hash-common.c
521 * lib/libgcrypt/cipher/hash-common.h
522 * lib/libgcrypt/cipher/hmac-tests.c
523 * lib/libgcrypt/cipher/md.c
524 * lib/libgcrypt/cipher/md4.c
525 * lib/libgcrypt/cipher/md5.c
526 * lib/libgcrypt/cipher/primegen.c
527 * lib/libgcrypt/cipher/pubkey.c
528 * lib/libgcrypt/cipher/rfc2268.c
529 * lib/libgcrypt/cipher/rijndael-tables.h
530 * lib/libgcrypt/cipher/rijndael.c
531 * lib/libgcrypt/cipher/rmd.h
532 * lib/libgcrypt/cipher/rmd160.c
533 * lib/libgcrypt/cipher/rsa.c
534 * lib/libgcrypt/cipher/seed.c
535 * lib/libgcrypt/cipher/serpent.c
536 * lib/libgcrypt/cipher/sha1.c
537 * lib/libgcrypt/cipher/sha256.c
538 * lib/libgcrypt/cipher/sha512.c
539 * lib/libgcrypt/cipher/tiger.c
540 * lib/libgcrypt/cipher/twofish.c
541 * lib/libgcrypt/cipher/whirlpool.c
542
af2f93ac
RM
5432009-11-16 Robert Millan <rmh.grub@aybabtu.com>
544
545 Fix build for systems without error().
546
547 * gnulib/error.c: New file (imported from Gnulib).
548 * gnulib/error.h: Likewise.
549 * conf/common.rmk (grub_mkisofs_SOURCES): Add `gnulib/error.c'.
550 * util/mkisofs/mkisofs.c (program_name): Remove `static' qualifier
551 (this variable is now used by error()).
552
73fb3dd5
FZ
5532009-11-16 Felix Zielcke <fzielcke@z-51.de>
554
814f5e96
FZ
555 * util/mkisofs/name.c (iso9660_file_length): Use isascii macro
556 instead of relying that char is signed.
73fb3dd5 557
a691ca33
VS
5582009-11-16 Vladimir Serbinenko <phcoder@gmail.com>
559
560 * fs/i386/pc/pxe.c (grub_pxefs_open): Correctly handle PXE choosing
561 blocksize different from specified.
562 (grub_pxefs_read): Likewise.
563
2af8f0f4
FZ
5642009-11-16 Felix Zielcke <fzielcke@z-51.de>
565
566 Enable ata.mod on x86_64-efi, i386-efi and i386-ieee1275.
567
568 * disk/ata.c (grub_ata_dumpinfo): Add a cast.
569 (grub_ata_readwrite): Likewise. Update 2 format strings.
570 (grub_atapi_read): Likewise.
571
572 * conf/i386-coreboot.rmk (pkglib_MODULES): Move `ata.mod' from here ...
573 * conf/i386.rmk (pkglib_MODULES): ... to here ...
574 * conf/x86_64-efi.rmk (pkglib_MODULES): ... and here.
575 * conf/i386-coreboot.rmk (ata_mod_SOURCES, ata_mod_CFLAGS)
576 (ata_mod_LDFLAGS): Move from here ...
577 * conf/i386.rmk: ... to here ...
578 * conf/x86_64-efi.rmk: ... and here.
579 * conf/i386-pc.rmk (pkglib_MODULES): Remove `ata.mod'
580 (ata_mod_SOURCES, ata_mod_CFLAGS, ata_mod_LDFLAGS): Remove.
581
83bdecaf
RM
5822009-11-16 Robert Millan <rmh.grub@aybabtu.com>
583
584 Relicense multiboot.h, with RMS' blessing.
585
586 * include/multiboot.h: Change to X11 license.
587
fd6fd3d7
RM
5882009-11-15 Robert Millan <rmh.grub@aybabtu.com>
589
590 Support --version in grub-mkisofs.
591
592 * util/mkisofs/mkisofs.c (rcsid): Remove variable.
593 (OPTION_VERSION): New macro.
594 (ld_options): Recognize --version.
595 (usage): Move `program_name' from here ...
596 (program_name): ... to here. Add `static' qualifier.
597 (main): Recognize `OPTION_VERSION'.
598
16a88c49
FZ
5992009-11-15 Felix Zielcke <fzielcke@z-51.de>
600
601 * Makefile.in (TARGET_CPPFLAGS): Replace `-isystem=$(srcdir)/include'
602 with `-nostdinc -isystem $(shell $(TARGET_CC) -print-file-name=include)'.
603
a4158476
RM
6042009-11-14 Robert Millan <rmh.grub@aybabtu.com>
605
606 Fix help2man generation for mkisofs.
607
608 * util/mkisofs/mkisofs.c (ld_options): Recognize --help.
609 (usage): Send output to stdout (rather than stderr).
610
fc2208b0
RM
6112009-11-14 Robert Millan <rmh.grub@aybabtu.com>
612
613 * conf/i386-coreboot.rmk (grub_mkrescue_SOURCES): Replace
614 `util/i386/coreboot/grub-mkrescue.in' with `util/grub-mkrescue.in'.
615 * conf/i386-pc.rmk (grub_mkrescue_SOURCES): Replace
616 `util/i386/pc/grub-mkrescue.in' with `util/grub-mkrescue.in'.
617 (bin_SCRIPTS): Add `grub-mkfloppy'.
618 (grub_mkfloppy_SOURCES): New variable.
619
620 * util/grub-mkrescue.in: New file.
621 * util/i386/pc/grub-mkfloppy.in: New file.
622
623 * util/i386/coreboot/grub-mkrescue.in: Remove.
624 * util/i386/pc/grub-mkrescue.in: Remove.
625
8d0edf4a
RM
6262009-11-13 Robert Millan <rmh.grub@aybabtu.com>
627
628 * include/grub/multiboot.h (struct grub_multiboot_header): Move
629 from here ...
630 * include/multiboot.h (struct multiboot_header): ... to here. Update
631 all users.
632 * include/grub/multiboot.h (struct grub_multiboot_info): Move
633 from here ...
634 * include/multiboot.h (struct multiboot_info): ... to here. Update
635 all users.
636 * include/grub/multiboot.h (struct grub_multiboot_mmap_entry): Move
637 from here ...
638 * include/multiboot.h (struct multiboot_mmap_entry): ... to here.
639 Update all users.
640 * include/grub/multiboot.h (struct grub_mod_list): Move
641 from here ...
642 * include/multiboot.h (struct multiboot_mod_list): ... to here.
643 Update all users.
644
a73f5969
RM
6452009-11-13 Robert Millan <rmh.grub@aybabtu.com>
646
647 * include/multiboot2.h (multiboot_word): Rename from this ...
648 (multiboot2_word): ... to this. Update all users.
649 (multiboot_header): Rename from this ...
650 (multiboot2_header): ... to this. Update all users.
651 (multiboot_tag_header): Rename from this ...
652 (multiboot2_tag_header): ... to this. Update all users.
653 (multiboot_tag_start): Rename from this ...
654 (multiboot2_tag_start): ... to this. Update all users.
655 (multiboot_tag_name): Rename from this ...
656 (multiboot2_tag_name): ... to this. Update all users.
657 (multiboot_tag_module): Rename from this ...
658 (multiboot2_tag_module): ... to this. Update all users.
659 (multiboot_tag_memory): Rename from this ...
660 (multiboot2_tag_memory): ... to this. Update all users.
661 (multiboot_tag_unused): Rename from this ...
662 (multiboot2_tag_unused): ... to this. Update all users.
663 (multiboot_tag_end): Rename from this ...
664 (multiboot2_tag_end): ... to this. Update all users.
665
1c8927f0
RM
6662009-11-13 Robert Millan <rmh.grub@aybabtu.com>
667
668 Disable Multiboot2 in i386-ieee1275. It didn't actually work, and on
669 this platform we should support Multiboot1 first.
670
671 * conf/i386-ieee1275.rmk (pkglib_MODULES): Remove `multiboot.mod'.
672 (multiboot_mod_SOURCES, multiboot_mod_CFLAGS)
673 (multiboot_mod_LDFLAGS, multiboot_mod_ASFLAGS): Remove.
674
6e1e0d89
RM
6752009-11-12 Robert Millan <rmh.grub@aybabtu.com>
676
677 * util/mkisofs/eltorito.c (init_boot_catalog): Handle return code
678 of write calls (converting them to fwrite() if they aren't already).
679 (get_torito_desc): Likewise.
680 * util/mkisofs/rock.c (generate_rock_ridge_attributes): Likewise.
681
7f2b34d8
RM
6822009-11-12 Robert Millan <rmh.grub@aybabtu.com>
683
684 * util/i386/pc/grub-install.in: Move from here ...
685 * util/grub-install.in: ... to here. Update all users.
686
c0ef3311
CW
6872009-11-11 Colin Watson <cjwatson@ubuntu.com>
688
689 * util/powerpc/ieee1275/grub-mkrescue.in: Fix --version output.
690
e1f240ff
RM
6912009-11-11 Robert Millan <rmh.grub@aybabtu.com>
692
693 Support for El Torito without floppy emulation.
694
695 * util/mkisofs/eltorito.c: Include `<errno.h>'.
696 (init_boot_catalog): Improve error handling.
697 (get_torito_desc): Don't use floppy emulation unless requested by
698 user. Patch boot information table when requested via
699 `-boot-info-table'.
700 * util/mkisofs/iso9660.h (struct eltorito_boot_info): New struct.
701 * util/mkisofs/mkisofs.c (use_eltorito_emul_floppy)
702 (use_boot_info_table): New variables.
703 (OPTION_BOOT_INFO_TABLE, OPTION_NO_EMUL_BOOT)
704 (OPTION_ELTORITO_EMUL_FLOPPY): New macros.
705 (ld_options): Handle `-boot-info-table', `-no-emul-boot' and
706 `--eltorito-emul-floppy'.
707 (main): Handle `OPTION_BOOT_INFO_TABLE', `OPTION_NO_EMUL_BOOT'
708 and `OPTION_ELTORITO_EMUL_FLOPPY'.
709 * util/mkisofs/mkisofs.h (use_eltorito_emul_floppy)
710 (use_boot_info_table, get_731): New prototypes.
711 * util/mkisofs/write.c (get_731): New function.
712
af7d4de5
FZ
7132009-11-11 Felix Zielcke <fzielcke@z-51.de>
714
715 Fix the generation of the man page.
716
717 * util/pc/i386/grub-install.in: Source
718 `${libdir}/grub/grub-mkconfig_lib' after options have been parsed.
719
2c55dbc0
RM
7202009-11-11 Robert Millan <rmh.grub@aybabtu.com>
721
722 Large file support for grub-mkisofs.
723
724 * conf/common.rmk (grub_mkisofs_CFLAGS): Add `-D_FILE_OFFSET_BITS=64'.
725 * util/mkisofs/mkisofs.c (next_extent, last_extent)
726 (session_start): Upgrade type to `uint64_t'. Update all users.
727 * util/mkisofs/mkisofs.h: Include `<stdint.h>'.
728 (struct directory_entry): Upgrade type of `starting_block' and
729 `size' to `uint64_t'. Update all users.
730 (struct deferred): Remove unused structure.
731 (xfwrite): Upgrade type of `count' and `size' to `uint64_t'.
732 Update all users.
733 * util/mkisofs/tree.c (stat_filter, lstat_filter): Return -1 when
734 file is larger than `UINT32_MAX'.
735 * util/mkisofs/write.c (xfwrite): Upgrade type of `count' and
736 `size' to `uint64_t'. Update all users. Fix handling of fwrite()
737 return value.
738 (struct deferred_write): Upgrade type of `extent' and `size' to
739 `uint64_t'. Update all users.
740 (last_extent_written): Upgrade type to `uint64_t'. Update all
741 users.
742 (write_one_file): Upgrade type of `count' and `size' to `uint64_t'.
743 Update all users. Upgrade type of `remain' to `int64_t' and
744 `use' to `size_t'. Use error() to handle fread() errors.
745 (write_files): Rely on write_one_file() rather than calling
746 xfwrite() directly.
747
6a9cead5
FZ
7482009-11-09 Felix Zielcke <fzielcke@z-51.de>
749
750 * util/mkisofs/mkisofs.c (ld_options): Fix a spelling mistake.
751
4825d790
RM
7522009-11-09 Robert Millan <rmh.grub@aybabtu.com>
753
754 * util/mkisofs/fnmatch.c: Remove.
755 * util/mkisofs/getopt1.c: Likewise.
756 * util/mkisofs/getopt.c: Likewise.
757 * conf/common.rmk (grub_mkisofs_SOURCES): Replace
758 `util/mkisofs/fnmatch.c', `util/mkisofs/getopt1.c' and
759 `util/mkisofs/getopt.c' with `gnulib/fnmatch.c',
760 `gnulib/getopt1.c' and `gnulib/getopt.c'.
761 (grub_mkisofs_CFLAGS): Add `-I$(srcdir)/gnulib'.
762
763 * configure.ac: Detect `mingw32msvc' host_os.
764 Check for lstat(), getuid() and getgid().
765
766 * util/mkisofs/joliet.c: Include `<stdint.h>'. Replace all
767 instances of `u_char' with `uint8_t'.
768
769 * util/mkisofs/mkisofs.h: Include `<sys/stat.h>'.
770 [!HAVE_GETUID] (getuid): New function (stub).
771 [!HAVE_GETGID] (getgid): Likewise.
772 [!HAVE_LSTAT] (lstat): Likewise.
773 [!S_IROTH] (S_IROTH): New macro (dummy).
774 [!S_IRGRP] (S_IRGRP): Likewise.
775
84b860d8
RM
7762009-11-09 Robert Millan <rmh.grub@aybabtu.com>
777
778 * gnulib/fnmatch_loop.c (EXT): Fix warning (signed and unsigned type in
779 conditional expression).
780
66e9b712
RM
7812009-11-09 Robert Millan <rmh.grub@aybabtu.com>
782
783 Import from Gnulib.
784
785 * gnulib/fnmatch.c: New file.
786 * gnulib/fnmatch.h: Likewise.
787 * gnulib/fnmatch_loop.c: Likewise.
788 * gnulib/getopt.c: Likewise.
789 * gnulib/getopt.h: Likewise.
790 * gnulib/getopt1.c: Likewise.
791 * gnulib/getopt_int.h: Likewise.
792 * gnulib/gettext.h: Likewise.
793
34f4a5b0
RM
7942009-11-09 Robert Millan <rmh.grub@aybabtu.com>
795
796 * normal/dyncmd.c (read_command_list): Replace `0' with `NULL'.
797 * normal/handler.c (read_handler_list): Likewise.
798
ac451143
RM
7992009-11-09 Robert Millan <rmh.grub@aybabtu.com>
800
801 Misc cleanup.
802
803 * kern/command.c (grub_register_command_prio): Use
804 grub_zalloc() instead of explicitly zeroing data.
805 * kern/list.c: Include `<grub/mm.h>'.
806 (grub_named_list_find): Replace `0' with `NULL'.
807 * normal/autofs.c (struct grub_fs_module_list): Remove ad-hoc type.
808 (fs_module_list): Change type to `grub_named_list_t'. Update all
809 users.
810 * normal/dyncmd.c (read_command_list): Add space between function
811 call and parenthesis.
812 * normal/handler.c (read_handler_list): Likewise.
813
4089b167
RM
8142009-11-09 Robert Millan <rmh.grub@aybabtu.com>
815
816 * normal/auth.c (punishment_delay): Moved from here ...
817 (grub_auth_strcmp): ... to here (inside function).
818
325f5037
RM
8192009-11-09 Robert Millan <rmh.grub@aybabtu.com>
820
821 * include/grub/list.h (struct grub_named_list): Remove `const'
822 qualifier from `name'.
823 (struct grub_prio_list): Likewise.
824
7aea29a3
RM
8252009-11-09 Robert Millan <rmh.grub@aybabtu.com>
826
827 * normal/auth.c: Include `<grub/time.h>'.
828 (grub_auth_strcmp): Replace `strcmp' with `grub_strcmp'.
829
3fd6f044
RM
8302009-11-09 Robert Millan <rmh.grub@aybabtu.com>
831
832 * normal/auth.c (punishment_delay): New variable.
833 (grub_auth_strcmp): Rewrite using grub_get_time_ms ().
834 (grub_auth_check_authentication): Punish failed login attempts with
835 an incremental (2^N) delay.
836
a4cd68e4
RM
8372009-11-09 Robert Millan <rmh.grub@aybabtu.com>
838
839 * conf/common.rmk (grub_mkisofs_CFLAGS): Prefix include
840 path with $(srcdir).
841
7ad12f43
VS
8422009-11-09 Vladimir Serbinenko <phcoder@gmail.com>
843
844 * normal/auth.c (grub_auth_strcmp): Fixed incorrect variable usage.
845
c1129f03
RM
8462009-11-09 Robert Millan <rmh.grub@aybabtu.com>
847
848 * util/i386/coreboot/grub-mkrescue.in: New file.
849 * conf/i386-coreboot.rmk (bin_SCRIPTS, grub_mkrescue_SOURCES): New
850 variables.
851
852 * conf/common.rmk (bin_UTILITIES): Add `grub-mkisofs'.
853 (grub_mkisofs_SOURCES, grub_mkisofs_CFLAGS): New variables.
854 * configure.ac: Add header and function checks to satisfy grub-mkisofs
855 requirements.
856 * util/mkisofs/defaults.h: New file.
857 * util/mkisofs/eltorito.c: Likewise.
858 * util/mkisofs/exclude.h: Likewise.
859 * util/mkisofs/fnmatch.c: Likewise.
860 * util/mkisofs/getopt.c: Likewise.
861 * util/mkisofs/getopt1.c: Likewise.
862 * util/mkisofs/hash.c: Likewise.
863 * util/mkisofs/include/fctldefs.h: Likewise.
864 * util/mkisofs/include/mconfig.h: Likewise.
865 * util/mkisofs/include/prototyp.h: Likewise.
866 * util/mkisofs/include/statdefs.h: Likewise.
867 * util/mkisofs/iso9660.h: Likewise.
868 * util/mkisofs/joliet.c: Likewise.
869 * util/mkisofs/match.c: Likewise.
870 * util/mkisofs/match.h: Likewise.
871 * util/mkisofs/mkisofs.c: Likewise.
872 * util/mkisofs/mkisofs.h: Likewise.
873 * util/mkisofs/multi.c: Likewise.
874 * util/mkisofs/name.c: Likewise.
875 * util/mkisofs/rock.c: Likewise.
876 * util/mkisofs/tree.c: Likewise.
877 * util/mkisofs/write.c: Likewise.
878
ec8bb77d
VS
8792009-11-09 Vladimir Serbinenko <phcoder@gmail.com>
880
881 * normal/auth.c (grub_auth_strcmp): Fix bug which resulted in function
882 being insecure.
883
3716b12c
RM
8842009-11-08 Robert Millan <rmh.grub@aybabtu.com>
885
886 * util/i386/pc/grub-mkrescue.in: Fix miss-identification as
887 `grub-mkimage' (and use $0 when possible).
888
b97b7b91
RM
8892009-11-08 Robert Millan <rmh.grub@aybabtu.com>
890
891 * kern/i386/multiboot_mmap.c (grub_machine_mmap_init): Improve
892 error message for excessively large memory map.
893
04114812
RM
8942009-11-08 Robert Millan <rmh.grub@aybabtu.com>
895
896 * autogen.sh: Use `sh gendistlist.sh' to avoid reliing on
897 executable bit.
898
e4eb2373
RM
8992009-11-08 Robert Millan <rmh.grub@aybabtu.com>
900
901 * kern/i386/multiboot_mmap.c (grub_machine_mmap_init): Improve error
902 message for coreboot users.
903
c926e1d5 9042009-11-07 Robert Millan <rmh.grub@aybabtu.com>
905
906 Fix build with GNU gold.
907
908 * conf/i386-pc.rmk (boot_img_LDFLAGS, pxeboot_img_LDFLAGS)
909 (diskboot_img_LDFLAGS, lnxboot_img_LDFLAGS)
910 (cdboot_img_LDFLAGS): Prepend `0x' qualifier to hexadecimal
911 link addresses.
912 * aclocal.m4: Likewise.
913
86e5b1db 9142009-11-04 Felix Zielcke <fzielcke@z-51.de>
915
916 * configure.ac (AC_PREREQ): Bump to 2.59d.
917 * INSTALL: Make it more clear when Autoconf and Ruby are
918 needed and when to run `./autogen.sh'.
919
246cd78f 9202009-11-03 Samuel Thibault <samuel.thibault@ens-lyon.org>
921
922 * util/grub.d/30_os-prober.in: Restore default behavior for unsupported
923 OSes.
924
4f9dfb37 9252009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
926
927 * util/grub.d/30_os-prober.in: Add GNU/Hurd support
928
b82bd5e1 9292009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
930
931 * util/grub.d/10_hurd.in: Drop /dev/ prefix from root device path before
932 giving it to GNU Mach.
933
ff1a9bca 9342009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
935
936 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): Subtract 1 from
937 GNU partition number to get internal GRUB partition number.
938
61697d9c 9392009-11-02 Samuel Thibault <samuel.thibault@ens-lyon.org>
940
941 * util/grub.d/10_hurd.in: Call prepare_grub_to_access_device
942 ${GRUB_DEVICE_BOOT} before loading /boot kernel.
943
a50569e1 9442009-11-01 Robert Millan <rmh.grub@aybabtu.com>
945
946 Based on patch from BVK Chaitanya <bvk.groups@gmail.com>
947 * kern/misc.c (grub_strchr, grub_strrchr): Fix to handle c == '\0'
948 case.
949
5b153867 9502009-11-01 Felix Zielcke <fzielcke@z-51.de>
951
952 * Makefile.in (TARGET_CPPFLAGS): Add `-I$(srcdir)/include'.
953
d9e2cd70 9542009-10-30 Robert Millan <rmh.grub@aybabtu.com>
955
956 Fix build problem.
957
958 * Makefile.in (TARGET_CPPFLAGS): Replace `-nostdinc' with
959 `-isystem=$(srcdir)/include'.
960
805111a4 9612009-10-30 Robert Millan <rmh.grub@aybabtu.com>
962
963 * util/i386/pc/grub-install.in: Remove hint that device.map should be
964 checked (grub-install doesn't currently rely on it).
965
fa6e945f 9662009-10-29 Robert Millan <rmh.grub@aybabtu.com>
967
968 Revert SVN r2660.
969
970 * conf/common.rmk (script/sh/lexer.c_DEPENDENCIES): Moved from here ...
971 * conf/i386-coreboot.rmk (script/sh/lexer.c_DEPENDENCIES): ... to here.
972 * conf/i386-efi.rmk (script/sh/lexer.c_DEPENDENCIES): ... and here.
973 * conf/i386-ieee1275.rmk: Likewise.
974 * conf/i386-pc.rmk: Likewise.
975 * conf/powerpc-ieee1275.rmk: Likewise.
976 * conf/sparc64-ieee1275.rmk: Likewise.
977 * conf/x86_64-efi.rmk: Likewise.
978
cee15086 9792009-10-28 Robert Millan <rmh.grub@aybabtu.com>
980
981 * Makefile.in (TARGET_CPPFLAGS): Add `-nostdinc'.
982
95b9239e 9832009-10-28 Robert Millan <rmh.grub@aybabtu.com>
984
985 * include/grub/misc.h: Stop checking for APPLE_CC.
986
2ed19dfd 9872009-10-28 Robert Millan <rmh.grub@aybabtu.com>
988
989 * kern/i386/coreboot/init.c (grub_exit): Reimplement in a way that
990 doesn't cause an infinite call loop.
991
fdcdde19 9922009-10-28 Felix Zielcke <fzielcke@z-51.de>
993
994 * commands/acpi.c (grub_cmd_acpi): Fix the out of memory error
995 strings.
996
cefabfe1 9972009-10-26 Robert Millan <rmh.grub@aybabtu.com>
998
999 * autogen.sh: Support addition of external modules via `GRUB_CONTRIB'
1000 variable.
1001 * Makefile.in: Likewise.
1002
ed96ab6d 10032009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1004
1005 * gendistlist.sh: Simplify .svn check. Skip .bzr as well.
1006
0579b753 10072009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1008
1009 * Makefile.in (RMKFILES): Rewrite using $(wildcard).
1010
478df409 10112009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1012
1013 * disk/scsi.c: Remove `<grub/machine/kernel.h>' (not needed).
1014
083d1679 10152009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1016
1017 * gensymlist.sh.in (COMPILE_TIME_ASSERT): Copy macro declaration
1018 from here ...
1019 * include/grub/misc.h (COMPILE_TIME_ASSERT): ... to here.
1020
5947ae32 10212009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1022
1023 * Makefile.in (docs/grub.info): Use make syntax to ignore errors
1024 in $(MAKEINFO) invocation. This makes it clear in output that
1025 errors are being ignored.
1026
94180ff6 10272009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1028
1029 * conf/i386-coreboot.rmk (script/sh/lexer.c_DEPENDENCIES): Moved
1030 from here ...
1031 * conf/common.rmk (script/sh/lexer.c_DEPENDENCIES): ... to here.
1032 * conf/i386-efi.rmk (script/sh/lexer.c_DEPENDENCIES): Remove.
1033 * conf/i386-ieee1275.rmk: Likewise.
1034 * conf/i386-pc.rmk: Likewise.
1035 * conf/powerpc-ieee1275.rmk: Likewise.
1036 * conf/sparc64-ieee1275.rmk: Likewise.
1037 * conf/x86_64-efi.rmk: Likewise.
1038
9031b03a 10392009-10-26 Colin Watson <cjwatson@ubuntu.com>
1040
1041 * util/grub-editenv.c (main): If only a command is given, use
1042 DEFAULT_DIRECTORY "/" GRUB_ENVBLK_DEFCFG as a default file name.
1043 (usage): FILENAME is now optional and has a default.
1044
e4f6809b 10452009-10-26 Colin Watson <cjwatson@ubuntu.com>
1046
1047 Improve grub-mkconfig performance when there are several menu
1048 entries on a single filesystem.
1049
1050 * util/grub.d/10_linux.in (linux_entry): Cache the output of
1051 prepare_grub_to_access_device.
1052 * util/grub.d/10_kfreebsd.in (kfreebsd_entry): Likewise.
1053 * util/grub.d/30_os-prober.in: Likewise.
1054
67937d4d 10552009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1056
1057 * util/grub.d/10_freebsd.in: Remove.
1058 * util/grub.d/10_kfreebsd.in: New file (based on 10_linux.in).
1059 * configure.ac: Set host_kernel=kfreebsd for FreeBSD and GNU/kFreeBSD.
1060
ee3756cc 10612009-10-26 Robert Millan <rmh.grub@aybabtu.com>
1062
5c35048e 1063 * docs/grub.cfg: Fix example usage of *BSD loaders.
ee3756cc 1064
4dea1c6f 10652009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1066
1067 * util/i386/pc/grub-setup.c (setup): Add missing parameter to
1068 grub_util_error() call.
1069
042484d7 10702009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1071
1072 * include/grub/fs.h [GRUB_UTIL] (struct grub_fs): Add
1073 `reserved_first_sector' member.
1074 * fs/ext2.c [GRUB_UTIL] (grub_ext2_fs): Initialize
1075 `reserved_first_sector' to 1.
1076 * fs/fat.c [GRUB_UTIL] (grub_fat_fs): Likewise.
1077 * fs/ntfs.c [GRUB_UTIL] (grub_ntfs_fs): Likewise.
1078 * fs/hfsplus.c [GRUB_UTIL] (grub_hfsplus_fs): Likewise.
1079 * util/i386/pc/grub-setup.c (setup): Add safety check that probes for
1080 filesystems which begin at first sector.
1081 (options): New option --skip-fs-probe.
1082 (main): Handle --skip-fs-probe and pass it to setup().
1083
d64448a7 10842009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1085
1086 * include/grub/misc.h: Fix wrong evaluation of APPLE_CC.
1087 (memset): Fix function prototype.
1088
508d42ec 10892009-10-25 Robert Millan <rmh.grub@aybabtu.com>
10902009-10-25 Vasily Averin <vvs@parallels.com>
1091
1092 * fs/ext2.c (grub_ext2_iterate_dir): Avoid infinite loop when
1093 `dirent.direntlen == 0'.
1094
b240e30c 10952009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1096
1097 * fs/cpio.c [MODE_USTAR]: Initialize `tar' module instead of
1098 `cpio'.
1099 [! MODE_USTAR]: Initialize `cpio' module instead of `tar'.
1100
346e7fbe 11012009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1102
1103 * configure.ac: Check for `__ashldi3', `__ashrdi3', `__lshrdi3',
1104 `__trampoline_setup' and `__ucmpdi2'.
1105 * include/grub/powerpc/libgcc.h: Only export symbols for functions
1106 that libgcc provides.
1107
cdb308b0 11082009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1109
1110 * include/grub/powerpc/libgcc.h (memset): Remove function prototype.
1111 * include/grub/sparc64/libgcc.h (memset): Likewise.
1112 * include/grub/misc.h (memset, memcmp): New function prototypes.
1113
fb26abc2 11142009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1115
1116 * fs/cpio.c [MODE_USTAR]: Finish `tar' module instead of
1117 `cpio'.
1118 [! MODE_USTAR]: Finish `cpio' module instead of `tar'.
1119
f6693890 11202009-10-25 Robert Millan <rmh.grub@aybabtu.com>
1121
1122 Patch from Samuel Thibault <samuel.thibault@ens-lyon.org>
1123 * docs/grub.cfg: Compensate for recent change in multiboot
1124 loader (since 2009-08-14 it won't pass filename to payload).
1125 * util/grub.d/10_hurd.in: Likewise.
1126
0933cdc0 11272009-10-21 Felix Zielcke <fzielcke@z-51.de>
1128
1129 * config.guess: Update to latest version from config git
1130 repository.
1131 * config.sub: Likewise.
1132
3b2fe8c2 11332009-10-20 Robert Millan <rmh.grub@aybabtu.com>
1134
1135 Fix build on sparc64.
1136
1137 * configure.ac: Perform checks for libgcc symbols before
1138 adding `-nostdlib' to LDFLAGS.
1139
46695a62 11402009-10-16 Vladimir Serbinenko <phcoder@gmail.com>
1141
1142 Let user specify OpenBSD root device.
1143
1144 * loader/i386/bsd.c (openbsd_root): New variable.
1145 (openbsd_opts): New option 'root'.
1146 (OPENBSD_ROOT_ARG): New macro.
1147 (grub_openbsd_boot): Use 'openbsd_root'.
1148 (grub_cmd_openbsd): Fill 'openbsd_root'.
1149
d2b6b7fc 11502009-10-16 Robert Millan <rmh.grub@aybabtu.com>
1151
1152 * NEWS: Misc adjustments.
1153
421bd7ac 11542009-10-16 Vladimir Serbinenko <phcoder@gmail.com>
1155
1156 * NEWS: Mentioned XNU, ACPI, gptsync, password and parttool.
1157
f1d29d87 11582009-10-16 Robert Millan <rmh.grub@aybabtu.com>
1159
1160 * configure.ac: Bump version to 1.97.
1161
6f3cd880 11622009-10-16 Colin Watson <cjwatson@ubuntu.com>
1163
1164 * configure.ac (TARGET_CFLAGS): Add -mno-mmx -mno-sse -mno-sse2
1165 -mno-3dnow on x86 architectures. Some toolchains enable these
1166 features by default, but they rely on registers that aren't enabled
1167 in GRUB. Thanks to Vladimir Serbinenko for the suggestion.
1168
035f7122 11692009-10-15 Robert Millan <rmh.grub@aybabtu.com>
1170
1171 Make entry text a bit more readable.
1172
1173 * util/grub.d/10_linux.in: Add `with' before `Linux'.
1174
44998e58 11752009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
1176
1177 * loader/i386/pc/xnu.c (grub_xnu_set_video): Fix loading splash image.
1178
cd2851b3 11792009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
1180
1181 * commands/xnu_uuid.c (grub_cmd_xnu_uuid): Remove duplicated bitwise
1182 operations.
1183
c6f3b249 11842009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
1185
1186 * configure.ac: Add missing dollar.
1187
6b5886ba 11882009-10-15 Vladimir Serbinenko <phcoder@gmail.com>
1189
1190 Revert 2009-06-10 Pavel Roskin <proski@gnu.org>
1191
1192 * configure.ac: Put checks for __bswapsi2 and __bswapdi2.
1193 * include/grub/powerpc/libgcc.h: Don't use weak attribute for all
1194 exports.
1195 * include/grub/sparc64/libgcc.h: Likewise. Use
1196 preprocessor conditionals.
1197
e9d66f6d 11982009-10-14 Robert Millan <rmh.grub@aybabtu.com>
1199
1200 * conf/common.rmk (grub-dumpbios): Remove rule.
1201 (sbin_SCRIPTS, CLEANFILES): Remove `grub-dumpbios'.
1202 * util/grub-dumpbios.in: Remove file.
1203
9155bc17 12042009-10-14 Robert Millan <rmh.grub@aybabtu.com>
1205
1206 Refer to kernel of FreeBSD "kFreeBSD" to avoid confusion between
1207 the Operating System (FreeBSD) and its kernel (kernel of FreeBSD).
1208
1209 * loader/i386/bsd.c (grub_freebsd_boot): Read kernel environment
1210 from "kFreeBSD" namespace (rather than "FreeBSD"). Update all
1211 users.
1212
1213 (GRUB_MOD_INIT (bsd)): Rename "freebsd" command to "kfreebsd",
1214 "openbsd" to "kopenbsd", "netbsd" to "knetbsd", "freebsd_loadenv"
1215 to "kfreebsd_loadenv", "freebsd_module" to "kfreebsd_module",
1216 and "freebsd_module_elf" to "kfreebsd_module_elf". Update all
1217 users.
1218
bf7f7a18 12192009-10-12 Robert Millan <rmh.grub@aybabtu.com>
1220
1221 * term/tparm.c: Switch to GPLv3.
1222
86564c26 12232009-10-09 Robert Millan <rmh.grub@aybabtu.com>
1224
1225 * include/grub/i386/cpuid.h: Add header protection.
1226
5c936493 12272009-10-09 Robert Millan <rmh.grub@aybabtu.com>
1228
1229 Fail gracefuly when attempting to load 64-bit kFreeBSD on IA32 CPU.
1230
1231 * include/grub/i386/cpuid.h: New file.
1232 * commands/i386/cpuid.c: Include `<grub/i386/cpuid.h>'.
1233 (has_longmode): Rename to ...
1234 (grub_cpuid_has_longmode): ... this. Update all users. Remove
1235 `static' attribute.
1236 * loader/i386/bsd.c: Include `<grub/i386/cpuid.h>'.
1237 (grub_bsd_load_elf): Fail if load of 64-bit kernel was requested
1238 on a CPU that doesn't implement AMD64 instruction set.
1239
186e7cf2 12402009-10-06 Colin Watson <cjwatson@ubuntu.com>
1241
1242 * Makefile.in (docs/stamp-vti): Depend on configure.ac as well, so
1243 that version.texi is rebuilt on version number changes.
1244
83b65c4a 12452009-10-06 Colin Watson <cjwatson@ubuntu.com>
1246
1247 * Makefile.in: Don't set info_INFOS unless makeinfo was found.
1248 Fixes bug #27602.
1249
d244281c 12502009-10-06 Colin Watson <cjwatson@ubuntu.com>
1251
1252 * util/i386/pc/grub-install.in: Source
1253 ${libdir}/grub/grub-mkconfig_lib before option processing, in order
1254 that the --grub-probe option will work.
1255 * util/sparc64/ieee1275/grub-install.in: Likewise.
1256
da25306d 12572009-10-05 Robert Millan <rmh.grub@aybabtu.com>
1258
1259 * configure.ac: Bump version to 1.97~beta4.
1260
e8ee83c0 12612009-10-03 Robert Millan <rmh.grub@aybabtu.com>
1262
1263 Resync grub-mkdevicemap in x86_64-efi.
1264
1265 * conf/x86_64-efi.rmk (sbin_UTILITIES): Enable `grub-mkdevicemap'.
1266 (grub_mkdevicemap_SOURCES): Add missing `util/deviceiter.c' and
1267 `util/devicemap.c'.
1268
50dcabcf 12692009-10-01 Colin Watson <cjwatson@ubuntu.com>
1270
1271 * util/grub-editenv.c (create_envblk_file): Write new block with a
1272 .new suffix and then rename it into place, to ensure atomic
1273 creation.
1274
0e51c3a7 12752009-09-28 Robert Millan <rmh.grub@aybabtu.com>
1276
1277 Do not automatically install headers.
1278
1279 * Makefile.in (include_DATA): Remove. Update all users.
1280
31299a95 12812009-09-26 Robert Millan <rmh.grub@aybabtu.com>
1282
1283 * conf/common.rmk (pkglib_MODULES): Remove `lua.mod'.
1284 (lua_mod_SOURCES, lua_mod_CFLAGS, lua_mod_LDFLAGS): Remove.
1285
1286 * util/osdetect.lua: Remove.
1287 * script/lua/lauxlib.c: Likewise.
1288 * script/lua/ldebug.c: Likewise.
1289 * script/lua/grub_main.c: Likewise.
1290 * script/lua/lauxlib.h: Likewise.
1291 * script/lua/ldebug.h: Likewise.
1292 * script/lua/ltablib.c: Likewise.
1293 * script/lua/liolib.c: Likewise.
1294 * script/lua/lstrlib.c: Likewise.
1295 * script/lua/lualib.h: Likewise.
1296 * script/lua/ldo.c: Likewise.
1297 * script/lua/ldump.c: Likewise.
1298 * script/lua/ldo.h: Likewise.
1299 * script/lua/loslib.c: Likewise.
1300 * script/lua/lundump.c: Likewise.
1301 * script/lua/grub_lib.c: Likewise.
1302 * script/lua/ldblib.c: Likewise.
1303 * script/lua/lundump.h: Likewise.
1304 * script/lua/lmem.c: Likewise.
1305 * script/lua/grub_lib.h: Likewise.
1306 * script/lua/lmathlib.c: Likewise.
1307 * script/lua/lstate.c: Likewise.
1308 * script/lua/ltm.c: Likewise.
1309 * script/lua/lvm.c: Likewise.
1310 * script/lua/lmem.h: Likewise.
1311 * script/lua/lstate.h: Likewise.
1312 * script/lua/ltm.h: Likewise.
1313 * script/lua/ltable.c: Likewise.
1314 * script/lua/lvm.h: Likewise.
1315 * script/lua/llex.c: Likewise.
1316 * script/lua/lgc.c: Likewise.
1317 * script/lua/grub_lua.h: Likewise.
1318 * script/lua/loadlib.c: Likewise.
1319 * script/lua/lfunc.c: Likewise.
1320 * script/lua/lopcodes.c: Likewise.
1321 * script/lua/lparser.c: Likewise.
1322 * script/lua/ltable.h: Likewise.
1323 * script/lua/llex.h: Likewise.
1324 * script/lua/lgc.h: Likewise.
1325 * script/lua/lfunc.h: Likewise.
1326 * script/lua/lbaselib.c: Likewise.
1327 * script/lua/lopcodes.h: Likewise.
1328 * script/lua/lparser.h: Likewise.
1329 * script/lua/lzio.c: Likewise.
1330 * script/lua/linit.c: Likewise.
1331 * script/lua/lobject.c: Likewise.
1332 * script/lua/llimits.h: Likewise.
1333 * script/lua/lstring.c: Likewise.
1334 * script/lua/lzio.h: Likewise.
1335 * script/lua/lapi.c: Likewise.
1336 * script/lua/lcode.c: Likewise.
1337 * script/lua/lua.h: Likewise.
1338 * script/lua/lobject.h: Likewise.
1339 * script/lua/lstring.h: Likewise.
1340 * script/lua/lapi.h: Likewise.
1341 * script/lua/lcode.h: Likewise.
1342 * script/lua/luaconf.h: Likewise.
1343
cb8a2c38 13442009-09-26 Colin Watson <cjwatson@ubuntu.com>
1345
1346 * docs/grub.texi (Command-line and menu entry commands): Document
1347 date and echo commands.
1348
6b9b6276 13492009-09-24 Pavel Roskin <proski@gnu.org>
1350
1351 * include/grub/kernel.h (struct grub_module_header): Remove
1352 `grub_module_header_types'. Make `type' unsigned. Make `size'
1353 32-bit on all platforms.
1354 * util/elf/grub-mkimage.c (load_modules): Treat `type' as an
1355 8-bit field. Use grub_host_to_target32() for `size'.
1356 * util/i386/efi/grub-mkimage.c (make_mods_section): Likewise.
1357 * util/i386/pc/grub-mkimage.c (generate_image): Likewise.
1358 * util/sparc64/ieee1275/grub-mkimage.c (generate_image): Likewise.
1359
4e5a02a7 13602009-09-24 Robert Millan <rmh.grub@aybabtu.com>
1361
1362 Fix "lost keypress" bug in at_keyboard.
1363
1364 * term/i386/pc/at_keyboard.c (grub_at_keyboard_checkkey): New function.
1365 Checks for readyness of input buffer (without flushing it).
1366 (grub_at_keyboard_term): Use grub_at_keyboard_checkkey() rather
1367 than grub_at_keyboard_getkey_noblock() for `checkkey' struct member.
1368
c6dcedf6 13692009-09-24 Robert Millan <rmh.grub@aybabtu.com>
1370
1371 * util/i386/pc/grub-mkimage.c (generate_image): Enclose BIOS-specific
1372 size check within GRUB_MACHINE_PCBIOS section.
1373
74c958b1 13742009-09-24 Robert Millan <rmh.grub@aybabtu.com>
1375
1376 * include/grub/i386/at_keyboard.h (KEYBOARD_ISREADY): Negate
1377 return value.
1378 * term/i386/pc/at_keyboard.c (grub_keyboard_getkey): Negate
1379 KEYBOARD_ISREADY check.
1380 (grub_at_keyboard_checkkey): Rename to ...
1381 (grub_at_keyboard_getkey_noblock): ... this. Update all users.
1382 Remove gratuitous cast.
1383
ff420223 13842009-09-23 Colin Watson <cjwatson@ubuntu.com>
1385
1386 * configure.ac: Call AC_PROG_MKDIR_P.
1387 * Makefile.in (docs/stamp-vti): Create docs directory. Create
1388 version.texi in $(builddir) rather than $(srcdir).
1389 (docs/grub.info): Create docs directory. Prepend $(builddir)/docs
1390 to makeinfo's @include search path.
1391
d96875df 13922009-09-23 Felix Zielcke <fzielcke@z-51.de>
1393
1394 * util/grub-mkconfig_lib.in (grub_file_is_not_garbage): Cope with `*.dpkg-*'
1395
9b3f8365 13962009-09-23 Felix Zielcke <fzielcke@z-51.de>
1397
1398 * util/grub-mkconfig_lib.in (grub_file_is_not_garbage): Add support
1399 for `*.dpkg-new'.
1400
c44c90db 14012009-09-21 Colin Watson <cjwatson@ubuntu.com>
1402
1403 Build info documentation. Some code borrowed from Automake.
1404
1405 * configure.ac: Check for makeinfo.
1406 * Makefile.in (MAKEINFO, INFOS, info_INFOS): New variables.
1407 (MAINTAINER_CLEANFILES): Add $(INFOS), docs/stamp-vti, and
1408 docs/version.texi.
1409 (MOSTLYCLEANFILES): Add vti.tmp.
1410 (docs/version.texi, docs/stamp-vti): Update automatically.
1411 (docs/grub.info): Build info documentation. Use --force and ignore
1412 errors for now.
1413 (all-local): Add $(INFOS).
1414 (install-local): Install info files.
1415 (uninstall): Uninstall info files.
1416 * docs/version.texi: Remove from revision control. This file is
1417 automatically generated on build now.
1418 * gendistlist.sh: Add `*.info'.
1419
e0b37bb5 14202009-09-21 Felix Zielcke <fzielcke@z-51.de>
1421
1422 * kern/term.c: Fix indentation.
1423
5a78865b 14242009-09-21 Felix Zielcke <fzielcke@z-51.de>
1425
1426 * util/hostdisk.c: Fix a comment.
1427
dace7e8a 14282009-09-20 Robert Millan <rmh.grub@aybabtu.com>
1429
1430 Fix regression introduced in r2539.
1431
1432 * term/usb_keyboard.c (USB_HID_DEVICE_TO_HOST): Change from 0x61
1433 to 0xA1.
1434
a83d079b 14352009-09-19 Colin Watson <cjwatson@ubuntu.com>
1436
1437 * util/grub.d/30_os-prober.in: Don't throw away stderr from
4cbbccec 1438 os-prober. Under normal operation, it does not print anything to
1439 stderr; if it does, we need to debug it, and throwing away stderr
1440 makes that excessively difficult.
a83d079b 1441
be94a509 14422009-09-16 Vladimir Serbinenko <phcoder@gmail.com>
1443
1444 * mmap/mmap.c (grub_cmd_badram): Fix off-by-one error.
1445
63f745e8 14462009-09-16 Robert Millan <rmh.grub@aybabtu.com>
1447
1448 * aclocal.m4 (AC_LANG_PROGRAM): New macro. Overrides stock
1449 AC_LANG_PROGRAM from autoconf.
1450 (grub_ASM_USCORE, grub_PROG_OBJCOPY_ABSOLUTE): Add missing
1451 prototypes (fixes warning).
1452
1453 * configure.ac: Add `-Werror' to TARGET_CFLAGS unless
1454 `--disable-werror' was used.
1455
bbb2a70f 14562009-09-16 Robert Millan <rmh.grub@aybabtu.com>
1457
1458 * partmap/msdos.c (pc_partition_map_iterate): Fix possible use of
1459 uninitialized `lastaddr'.
1460
77c24f1d 14612009-09-15 Vladimir Serbinenko <phcoder@gmail.com>
1462
0f0b8c87 1463 * partmap/msdos.c (pc_partition_map_iterate): Detect and break loops.
77c24f1d 1464
07197f23 14652009-09-14 Colin Watson <cjwatson@ubuntu.com>
1466
1467 * commands/test.c (get_fileinfo): Return immediately if
1468 grub_fs_probe fails.
1469
dabf1798 14702009-09-14 José Martínez <xosemp@gmail.com>
1471
1472 * commands/acpi.c (grub_cmd_acpi): Fix loading ACPI tables from file.
1473
d52109a7 14742009-09-14 Colin Watson <cjwatson@ubuntu.com>
1475
1476 * util/grub.d/30_os-prober.in: Cope with Windows 7 in os-prober
1477 output.
1478
56532179 14792009-09-13 Robert Millan <rmh.grub@aybabtu.com>
1480
1481 * configure.ac: Remove --enable-grub-pe2elf. Only build
1482 grub-pe2elf when needed by the build system itself.
1483 * conf/common.rmk: Remove $(enable_grub_pe2elf) check.
1484
8ef070f5 14852009-09-12 Robert Millan <rmh.grub@aybabtu.com>
1486
1487 * configure.ac: Bump version to 1.97~beta3.
1488 * docs/version.texi: Likewise.
1489
61229557 14902009-09-12 Robert Millan <rmh.grub@aybabtu.com>
1491
1492 * video/i386/pc/vbe.c (grub_vbe_get_video_mode_info): Move packed
1493 mode special handling (grub_vbe_bios_set_dac_palette_width() call)
1494 from here ...
1495 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS]
1496 (grub_linux_setup_video): ... to here (with some adjustments).
1497
5c9f8d84 14982009-09-12 Robert Millan <rmh.grub@aybabtu.com>
1499
1500 Fix memory corruption issue (spotted by Colin Watson).
1501
1502 * kern/i386/pc/startup.S (grub_vbe_bios_getset_dac_palette): Fix bug
1503 causing returned size to be stored in an incorrect memory location.
1504 Fix use of uninitialized value when storing the returned size.
1505
e8f5d6e9 15062009-09-12 Yves Blusseau <blusseau@zetam.org>
1507
1508 Change clean rules to properly remove files
1509
1510 * genmk.rb: add new clean rules
1511 * Makefile.in (clean): add the new targets
1512 (mostlyclean): likewise
1513
cda2a409 15142009-09-11 Colin Watson <cjwatson@ubuntu.com>
1515
1516 * include/grub/ntfs.h (struct grub_fshelp_node): Change `size'
1517 to grub_uint64_t.
1518 * fs/ntfs.c (init_file): Understand 64-bit sizes for
1519 non-resident files.
1520
86695375 15212009-09-11 Colin Watson <cjwatson@ubuntu.com>
1522
1523 * configure.ac: Don't look for help2man when cross-compiling. Fixes
1524 part of bug #27349.
1525
8aa1541a 15262009-09-10 Felix Zielcke <fzielcke@z-51.de>
1527
1528 * util/grub-mkconfig.in: Make the created config mode 400 and
1529 print a warning if it fails.
1530
48d9bb0a 15312009-09-10 Robert Millan <rmh.grub@aybabtu.com>
1532
1533 * util/grub.d/40_custom.in: Ask user to type custom entries below
1534 comment, rather than below 'exec tail' line.
1535
3b0521be 15362009-09-10 Colin Watson <cjwatson@ubuntu.com>
1537
1538 * util/grub.d/40_custom.in: Make sure that the explanatory text is
1539 visible in grub.cfg.
1540
50051d55 15412009-09-10 Colin Watson <cjwatson@ubuntu.com>
1542
1543 * util/grub.d/40_custom.in: Make it a little clearer how to use this
1544 file.
1545
c0d34387 15462009-09-10 Felix Zielcke <fzielcke@z-51.de>
1547
1548 * docs/grub.cfg: Add an example menu entry for memtest86+.
1549
80a608f3 15502009-09-09 Felix Zielcke <fzielcke@z-51.de>
1551
a2094832 1552 * config.guess: Update to latest version from config git.
80a608f3 1553 * config.sub: Likewise.
1554
99423078 15552009-09-08 Colin Watson <cjwatson@ubuntu.com>
1556
1557 * script/sh/execute.c (grub_script_execute_cmdline): Set "?" in
1558 unknown-command case. Fixes bug #27320.
1559
44454e4c 15602009-09-08 Felix Zielcke <fzielcke@z-51.de>
1561
1562 * kern/rescue_parser.c (grub_rescue_parse_line): Only suggest to try
1563 `help' if the command exists.
1564
e30d87ad 15652009-09-06 Robert Millan <rmh.grub@aybabtu.com>
1566
1567 * INSTALL: Require GCC 4.1.3 or later.
1568
9a86f1ec 15692009-09-06 Yves Blusseau <blusseau@zetam.org>
1570
1571 * Makefile.in (RMKFILES): add i386-qemu.rmk
1572 (MAINTAINER_CLEANFILES): add $(srcdir)/DISTLIST $(srcdir)/config.h.in
1573 $(srcdir)/stamp-h.in
1574
7f26d466 15752009-09-05 Robert Millan <rmh.grub@aybabtu.com>
1576
1577 * util/grub-probe.c (probe): Comment out buggy codepath, which
1578 was unexpectedly enabled by Colin Watson's 2009-09-02 fix. This
1579 should be re-enabled after 1.97.
1580
3a613259 15812009-09-05 Felix Zielcke <fzielcke@z-51.de>
1582
1583 * gendistlist.sh: Add `grub-dumpdevtree' and `*.lua' to the list
1584 find searches for.
1585
197f76c7 15862009-09-04 Vladimir Serbinenko <phcoder@gmail.com>
1587
1588 * loader/i386/xnu.c (grub_cpu_xnu_fill_devicetree): Remove
1589 unnecessary calls to grub_error.
1590
70ba68ce 15912009-09-04 Colin Watson <cjwatson@ubuntu.com>
1592
1593 * NEWS: Mention `keystatus' and Unicode fonts.
1594
4ff0d7a4 15952009-09-04 Robert Millan <rmh.grub@aybabtu.com>
1596
1597 * configure.ac: Bump version to 1.97~beta2.
1598 * docs/version.texi: Likewise.
1599
77c55a87 16002009-09-03 Colin Watson <cjwatson@ubuntu.com>
1601
1602 * configure.ac: By default, GCC 4.4 generates .eh_frame sections
1603 containing unwind information in some cases where it previously did
1604 not. Use -fno-dwarf2-cfi-asm if available to restore the old
1605 behaviour. See http://patchwork.kernel.org/patch/8555/ for related
1606 discussion.
1607
f79572cd 16082009-09-02 Yves BLUSSEAU <blusseau@zetam.org>
1609
1610 Embedding loadenv module into grub-emu
1611
1612 * conf/i386-pc.rmk (grub_emu_SOURCES): add lib/envblk.c and
1613 commands/loadenv.c
1614 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise
1615 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise
1616 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise
1617 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise
1618 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise
1619 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise
1620
93a81088 16212009-09-03 Magnus Granberg <zorry@ume.nu>
1622
1623 * aclocal.m4: Add grub_CHECK_PIE. It check if the compiler
1624 include -fPIE in the default specs.
1625 * configure.ac: Check if pie_possible is yes and add -fno-PIE
1626 to TARGET_CFLAGS.
1627
160034b2 16282009-09-03 Felix Zielcke <fzielcke@z-51.de>
1629
1630 * INSTALL: Note that GNU Bison 2.3 or later is required.
1631
087c07c4 16322009-09-03 Colin Watson <cjwatson@ubuntu.com>
1633
1634 * kern/i386/pc/startup.S: Fix typo.
1635
cbf978c0 16362009-09-02 Vladimir Serbinenko <phcoder@gmail.com>
1637
1638 * efiemu/loadcore.c (SUFFIX (grub_efiemu_loadcore_load)): Fix style
1639 according to GCS.
1640
16412009-09-02 Colin Watson <cjwatson@ubuntu.com>
f0910644 1642
1643 * docs/grub.texi (Naming convention): Describe one-based partition
1644 numbering.
1645 (Device syntax): Likewise.
1646 (File name syntax): Likewise.
1647 (Block list syntax): Likewise.
1648 (Making a GRUB bootable CD-ROM): Talk about grub.cfg rather than
1649 menu.lst.
1650 (File name syntax): Likewise.
1651 (Command-line and menu entry commands): Document acpi, blocklist,
1652 crc, export, insmod, keystatus, ls, set, and unset commands.
1653
f3e8cdfd 16542009-09-02 Colin Watson <cjwatson@ubuntu.com>
1655
1656 * commands/keystatus.c (GRUB_MOD_INIT (keystatus)): Adjust summary
1657 to avoid implying that only one of --shift, --ctrl, or --alt may be
1658 used.
1659
c0bc232b 16602009-09-02 Colin Watson <cjwatson@ubuntu.com>
1661
1662 * util/grub-probe.c (probe): Test st.st_mode using S_ISREG macro
1663 rather than comparing against S_IFREG, which will almost never work.
1664
aa0f752d 16652009-09-01 Vladimir Serbinenko <phcoder@gmail.com>
1666
1667 * commands/loadenv.c (check_blocklists): Fix off-by-one error.
1668 (write_blocklists): Likewise.
1669
ecb3166a 16702009-09-01 Colin Watson <cjwatson@ubuntu.com>
1671
1672 * script/lua/grub_lua.h (fputs): Supply a format string as the first
1673 argument to grub_printf.
1674
c403a125 16752009-09-01 Felix Zielcke <fzielcke@z-51.de>
31aba781 1676
1677 * genmk.rb: Add quotes around $(TARGET_OBJ2ELF) to cope with
c403a125 1678 non GNU test.
31aba781 1679
b5e7312c 16802009-08-30 Vladimir Serbinenko <phcoder@gmail.com>
1681
1682 * kern/file.c (grub_file_read): Spelling fix
1683
fe00f472 16842009-08-30 Vladimir Serbinenko <phcoder@gmail.com>
1685
1686 * loader/i386/bsdXX.c (SUFFIX (grub_freebsd_load_elfmodule)): Fix
1687 loading of headers in some cases.
1688
cc55302e 16892009-08-30 Robert Millan <rmh.grub@aybabtu.com>
1690
1691 * configure.ac: Bump version to 1.97~beta1.
1692 * docs/version.texi: Likewise.
1693
5c90cdd2 16942009-08-29 Vladimir Serbinenko <phcoder@gmail.com>
64bf71d0 1695
1696 * include/grub/i386/xnu.h: Add license header.
1697 include grub/err.h explicitly.
1698
c90edae4 16992009-08-29 Robert Millan <rmh.grub@aybabtu.com>
1700
1701 * util/grub.d/10_freebsd.in: Detect `ufs1' and `ufs2' and map them
1702 to `ufs' in the vfs.root.mountfrom kernel parameter.
1703
d8888b5c 17042009-08-29 Robert Millan <rmh.grub@aybabtu.com>
1705
1706 * term/i386/pc/serial.c: Include `<grub/machine/memory.h>'.
1707
1708 [GRUB_MACHINE_PCBIOS] (serial_hw_io_addr): Macroify initialization
1709 value (0x0400 -> GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR).
1710
1711 [! GRUB_MACHINE_PCBIOS] (GRUB_SERIAL_PORT_NUM): Calculate using
1712 `ARRAY_SIZE' macro.
1713
6f07b921 17142009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
1715
1716 * kern/file.c (grub_file_read): Check offset.
1717 * fs/hfs.c (grub_hfs_read_file): Remove unnecessary offset check.
1718 * fs/jfs.c (grub_jfs_read_file): Likewise.
1719 * fs/ntfs.c (grub_ntfs_read): Likewise.
1720 * fs/reiserfs.c (grub_reiserfs_read): Likewise.
1721 * fs/minix.c (grub_minix_read_file): Correct offset check.
1722 * fs/ufs.c (grub_ufs_read_file): Likewise.
1723
b4f34077 17242009-08-28 Colin Watson <cjwatson@ubuntu.com>
1725
1726 * term/i386/pc/console.c (bios_data_area): Cast
1727 GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR explicitly.
1728
e7c69859 17292009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
1730
1731 1-bit optimised blitters.
1732
1733 * include/grub/fbblit.h (grub_video_fbblit_replace_32bit_1bit): New
1734 prototype.
1735 (grub_video_fbblit_replace_24bit_1bit): Likewise.
1736 (grub_video_fbblit_replace_16bit_1bit): Likewise.
1737 (grub_video_fbblit_replace_8bit_1bit): Likewise.
1738 (grub_video_fbblit_blend_XXXA8888_1bit): Likewise.
1739 (grub_video_fbblit_blend_XXX888_1bit): Likewise.
1740 (grub_video_fbblit_blend_XXX565_1bit): Likewise.
1741 * video/fb/fbblit.c (grub_video_fbblit_replace_32bit_1bit): New
1742 function.
1743 (grub_video_fbblit_replace_24bit_1bit): Likewise.
1744 (grub_video_fbblit_replace_16bit_1bit): Likewise.
1745 (grub_video_fbblit_replace_8bit_1bit): Likewise.
1746 (grub_video_fbblit_blend_XXXA8888_1bit): Likewise.
1747 (grub_video_fbblit_blend_XXX888_1bit): Likewise.
1748 (grub_video_fbblit_blend_XXX565_1bit): Likewise.
1749 * video/fb/video_fb.c (common_blitter): Use 1-bit optimised blitters
1750 when possible.
1751 * video/video.c (grub_video_get_blit_format): Return
1752 GRUB_VIDEO_BLIT_FORMAT_1BIT_PACKED if bpp = 1.
1753
a57da43f 17542009-08-28 Colin Watson <cjwatson@ubuntu.com>
1755
1756 * normal/cmdline.c (grub_cmdline_get): Supply a format string as
1757 the first argument to grub_printf.
1758
4cbe67e5 17592009-08-28 Colin Watson <cjwatson@ubuntu.com>
17602009-08-28 Robert Millan <rmh.grub@aybabtu.com>
1761
1762 Add `getkeystatus' terminal method. Add a new `keystatus' command
1763 to query it.
1764
1765 * include/grub/term.h (GRUB_TERM_STATUS_SHIFT,
1766 GRUB_TERM_STATUS_CTRL, GRUB_TERM_STATUS_ALT): Definitions for
1767 modifier key bitmasks.
1768 (struct grub_term_input): Add `getkeystatus' member.
1769 (grub_getkeystatus): Add prototype.
1770 * kern/term.c (grub_getkeystatus): New function.
1771
1772 * include/grub/i386/pc/memory.h
1773 (GRUB_MEMORY_MACHINE_BIOS_DATA_AREA_ADDR): New macro.
1774 (struct grub_machine_bios_data_area): Define necessary parts of BIOS
1775 Data Area layout.
1776 * term/i386/pc/console.c (grub_console_getkeystatus): New function.
1777 (grub_console_term_input): Set `getkeystatus' member.
1778 * term/usb_keyboard.c (grub_usb_hid): Macroify HID protocol
1779 constants.
1780 (grub_usb_keyboard_getreport): Likewise.
1781 (grub_usb_keyboard_checkkey): Likewise.
1782 (grub_usb_keyboard_getkeystatus): New function.
1783 (grub_usb_keyboard_term): Set `getkeystatus' member.
1784
1785 * commands/keystatus.c: New file.
1786 * conf/common.rmk (pkglib_MODULES): Add keystatus.mod.
1787 (keystatus_mod_SOURCES): New variable.
1788 (keystatus_mod_CFLAGS): Likewise.
1789 (keystatus_mod_LDFLAGS): Likewise.
1790 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add
1791 commands/keystatus.c.
1792 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
1793 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1794 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
1795 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1796 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1797 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
4cbe67e5 1798
6e2a9085 17992009-08-28 Vladimir Serbinenko <phcoder@gmail.com>
1800
1801 Split befs.mod and afs.mod into *_be.mod and *.mod
1802
1803 * conf/common.rmk (grub_probe_SOURCES): Add afs_be.c and befs_be.c.
1804 (grub_fstest_SOURCES): Likewise.
1805 (pkglib_MODULES): Add afs_be.mod and befs_be.mod.
1806 (afs_be_mod_SOURCES): New variable.
1807 (afs_be_mod_CFLAGS): Likewise.
1808 (afs_be_mod_LDFLAGS): Likewise.
1809 (befs_be_mod_SOURCES): Likewise.
1810 (befs_be_mod_CFLAGS): Likewise.
1811 (befs_be_mod_LDFLAGS): Likewise.
1812 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add afs_be.c and befs_be.c.
1813 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
1814 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1815 * conf/i386-pc.rmk (grub_setup_SOURCES): Likewise.
1816 (grub_emu_SOURCES): Likewise.
1817 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1818 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1819 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
1820 * fs/afs_be.c: New file.
1821 * fs/befs_be.c: New file.
1822 * fs/afs.c (GRUB_AFS_FSNAME_SUFFIX): New definition.
1823 (GRUB_AFS_FSNAME): Use GRUB_AFS_FSNAME_SUFFIX.
1824 (U16): Replaced with ...
1825 (grub_afs_to_cpu16): ...this. All users updated.
1826 (U32): Replaced with ...
1827 (grub_afs_to_cpu32): ...this. All users updated.
1828 (U64): Replaced with ...
1829 (grub_afs_to_cpu64): ...this. All users updated.
1830 (GRUB_AFS_BO_LITTLE_ENDIAN): Remove.
1831 (GRUB_AFS_BO_BIG_ENDIAN): Likewise.
ad8ea1f4 1832 (grub_afs_validate_sblock): Check only one endianness.
6e2a9085 1833 (GRUB_MOD_INIT (befs)) [MODE_BIGENDIAN && MODE_BFS]: Rename to ..
1834 (GRUB_MOD_INIT (befs_be)) [MODE_BIGENDIAN && MODE_BFS]: ... this.
1835 (GRUB_MOD_INIT (afs)) [MODE_BIGENDIAN && !MODE_BFS]: Rename to ..
1836 (GRUB_MOD_INIT (afs_be)) [MODE_BIGENDIAN && !MODE_BFS]: ... this.
1837 (GRUB_MOD_FINI (befs)) [MODE_BIGENDIAN && MODE_BFS]: Rename to ..
1838 (GRUB_MOD_FINI (befs_be)) [MODE_BIGENDIAN && MODE_BFS]: ... this.
1839 (GRUB_MOD_FINI (afs)) [MODE_BIGENDIAN && !MODE_BFS]: Rename to ..
1840 (GRUB_MOD_FINI (afs_be)) [MODE_BIGENDIAN && !MODE_BFS]: ... this.
1841
32a71655 18422009-08-26 Bean <bean123ch@gmail.com>
1843
1844 * fs/xfs.c (GRUB_XFS_INO_INOINAG): Replace 1L with 1LL to support
1845 64-bit number.
1846 (GRUB_XFS_FSB_TO_BLOCK): Likewise.
1847 (grub_xfs_inode_block): Change return type to grub_uint64_t.
1848 (grub_xfs_read_inode): Change type of block to grub_uint64_t.
1849
552bf6c5 18502009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1851
1852 NetBSD memory map support.
1853
1854 * include/grub/i386/bsd.h (NETBSD_BTINFO_MEMMAP): New definition.
1855 (grub_netbsd_btinfo_mmap_header): New structure.
1856 (grub_netbsd_btinfo_mmap_entry): Likewise.
1857 * loader/i386/bsd.c (grub_netbsd_boot): Pass memory map.
1858
1ae2078c 18592009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1860
1861 Enable bsd.mod on coreboot.
1862
1863 * conf/i386-coreboot.rmk (pkglib_MODULES): Add bsd.mod.
1864 (bsd_mod_SOURCES): New variable.
1865 (bsd_mod_CFLAGS): Likewise.
1866 (bsd_mod_LDFLAGS): Likewise.
1867 (bsd_mod_ASFLAGS): Likewise.
1868 * loader/i386/bsd.c [!GRUB_MACHINE_PCBIOS]: Fix includes.
1869 (grub_bsd_get_device) [!GRUB_MACHINE_PCBIOS]: Set *biosdev to 0xff.
1870
beefc598 18712009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1872
1873 Cleanup NetBSD root support.
1874
1875 * loader/i386/bsd.c (grub_netbsd_boot): Remove call to
1876 grub_bsd_get_device.
1877 Fix typo.
1878
3b76e68b 18792009-08-25 Felix Zielcke <fzielcke@z-51.de>
1880
1881 * util/grub.d/00_header.in: Move check for the video backend of
1882 gfxterm from here ...
1883 * util/grub-mkconfig.in: ... to here. Enable gfxterm if there's
1884 a suitable video backend.
1885
aea664ea 18862009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1887
1888 Fix breakage in grub-setup.
1889
1890 * util/i386/pc/grub-setup.c (setup): Use "part_msdos" instead of
1891 "msdos_partition_map".
1892
ff747d50 18932009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1894
1895 Fix breakage in normal/auth.c.
1896
1897 * normal/auth.c (grub_iswordseparator): New function.
1898
e7e1f93f 18992009-08-25 Vladimir Serbinenko <phcoder@gmail.com>
1900
1901 Authentication support.
1902
1903 * commands/password.c: New file.
1904 * conf/common.rmk (pkglib_MODULES): Add password.mod.
1905 (password_mod_SOURCES): New variable.
1906 (password_mod_CFLAGS): Likewise.
1907 (password_mod_LDFLAGS): Likewise.
1908 (normal_mod_SOURCES): Add normal/auth.c.
1909 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add commands/password.c and
1910 normal/auth.c.
1911 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
1912 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1913 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
1914 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1915 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
1916 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
1917 * include/grub/auth.h: New file.
1918 * include/grub/err.h (grub_err_t): New enum value
1919 GRUB_ERR_ACCESS_DENIED.
1920 * include/grub/menu.h (grub_menu_entry): New fields 'restricted' and
1921 'users'.
1922 * include/grub/normal.h (grub_cmdline_get): New argument 'history'.
1923 * normal/cmdline.c (grub_cmdline_get): New argument 'history'. All
1924 users updated.
1925 * normal/auth.c: New file.
1926 * normal/main.c (grub_normal_add_menu_entry): Handle --users option.
1927 (grub_cmdline_run): Don't allow to go to command line without
1928 authentication.
1929 * normal/menu.c (grub_menu_execute_entry): Handle restricted entries.
1930 * normal/menu_entry.c (grub_menu_entry_run): Don't allow editing
1931 menuentry without superuser rights.
1932 * normal/menu_viewer.c (grub_menu_viewer_show_menu): Don't exit if
1933 user isn't a superuser.
1934
70f1161d 19352009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1936
1937 Save space by inlining misc.c functions.
1938
1939 * kern/misc.c (grub_iswordseparator): Made static.
1940 * kern/misc.c (grub_strcat): Moved from here ...
1941 * include/grub/misc.h (grub_strcat): ... here. Inlined.
1942 * kern/misc.c (grub_strncat): Moved from here ...
1943 * include/grub/misc.h (grub_strncat): ... here. Inlined.
1944 * kern/misc.c (grub_strcasecmp): Moved from here ...
1945 * include/grub/misc.h (grub_strcasecmp): ... here. Inlined.
1946 * kern/misc.c (grub_strncasecmp): Moved from here ...
1947 * include/grub/misc.h (grub_strncasecmp): ... here. Inlined.
1948 * kern/misc.c (grub_isalpha): Moved from here ...
1949 * include/grub/misc.h (grub_isalpha): ... here. Inlined.
1950 * kern/misc.c (grub_isdigit): Moved from here ...
1951 * include/grub/misc.h (grub_isdigit): ... here. Inlined.
1952 * kern/misc.c (grub_isgraph): Moved from here ...
1953 * include/grub/misc.h (grub_isgraph): ... here. Inlined.
1954 * kern/misc.c (grub_tolower): Moved from here ...
1955 * include/grub/misc.h (grub_tolower): ... here. Inlined.
1956
48e40bff 19572009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1958
1959 * script/sh/function.c (grub_script_function_find): Cut error message
1960 not to flood terminal.
1961 * script/sh/lexer.c (grub_script_yylex): Remove command line length
1962 limit.
1963 * script/sh/script.c (grub_script_arg_add): Duplicate string.
1964
c385bfc3 19652009-08-24 Colin Watson <cjwatson@ubuntu.com>
1966
1967 * term/usb_keyboard.c (grub_usb_keyboard_getreport): Make
1968 `report' grub_uint8_t *.
1969 (grub_usb_keyboard_checkkey): Make `data' elements grub_uint8_t.
1970 Use a 50-millisecond timeout rather than just repeating
1971 grub_usb_keyboard_getreport 50 times.
1972 (grub_usb_keyboard_getkey): Make `data' elements grub_uint8_t.
1973
2d21e3e8 19742009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1975
1976 Rename *_partition_map to part_*
1977
1978 * partmap/acorn.c (grub_acorn_partition_map): Set name to 'part_acorn'.
1979 * partmap/amiga.c (grub_amiga_partition_map): Set name to 'part_amiga'.
1980 * partmap/apple.c (grub_apple_partition_map): Set name to 'part_apple'.
1981 * partmap/gpt.c (grub_gpt_partition_map): Set name to 'part_gpt'.
1982 All users updated.
1983 * partmap/msdos.c (grub_msdos_partition_map): Set name to 'part_msdos'.
1984 All users updated.
1985 * partmap/sun.c (grub_sun_partition_map): Set name to 'part_sun'.
1986 * util/grub-probe.c (probe_partmap): Don't transform partition name
1987 to get module name.
1988
dd103c4e 19892009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
1990
1991 Fix OpenBSD and NetBSD support.
1992
1993 * include/grub/i386/bsd.h (GRUB_BSD_TEMP_BUFFER): Change to resolve
1994 memory address conflict.
1995 (OPENBSD_MMAP_ACPI): New definition.
1996 (OPENBSD_MMAP_NVS): Likewise.
1997 * loader/i386/bsd.c (grub_openbsd_boot): Support OPENBSD_MMAP_ACPI
1998 and OPENBSD_MMAP_NVS.
1999 Add memory map terminator
2000 Explicit cast when calling grub_unix_real_boot.
ad8ea1f4 2001 (grub_netbsd_boot): Explicit cast when calling grub_unix_real_boot.
dd103c4e 2002
16c84d74 20032009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
2004
2005 Let user specify NetBSD root device.
2006
2007 * loader/i386/bsd.c (netbsd_root): New variable.
2008 (netbsd_opts): New option 'root'.
2009 (NETBSD_ROOT_ARG): New macro.
2010 (grub_netbsd_boot): Use 'netbsd_root'.
2011 (grub_bsd_unload): Free 'netbsd_root'.
2012 (grub_cmd_netbsd): Fill 'netbsd_root'.
2013
adb29902 20142009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
2015
2016 Support for 64-bit NetBSD.
2017
2018 * loader/i386/bsd.c (grub_bsd_load_elf): Apply correct mask to entry
2019 point when booting non-FreeBSD.
2020
f5ae9f74 20212009-08-24 Vladimir Serbinenko <phcoder@gmail.com>
2022
2023 Support --no-smp and --no-acpi for NetBSD.
2024
2025 * include/grub/i386/bsd.h (NETBSD_AB_NOSMP): New definition.
2026 (NETBSD_AB_NOACPI): Likewise.
2027 * loader/i386/bsd.c (netbsd_opts): New entries no-smp and no-acpi.
2028 (netbsd_flags): Add NETBSD_AB_NOSMP, NETBSD_AB_NOACPI.
2029
de74f136 20302009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
2031
2032 * fs/hfsplus.c (grub_hfsplus_mount): Don't ignore grub_hfsplus_read_file
2033 errors.
2034 (grub_hfsplus_btree_iterate_node): Don't ignore grub_hfsplus_read_file
2035 errors. Call grub_error when needed.
2036
e9a925da 20372009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
2038
2039 * commands/search.c (search_fs): Try searching without autoload first.
2040 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Load
2041 filesystem module explicitly for faster booting.
2042
5174302b 20432009-08-23 Colin Watson <cjwatson@ubuntu.com>
2044
2045 * util/grub-mkconfig.in: Export GRUB_DISABLE_OS_PROBER.
2046
c8c80635 20472009-08-23 Colin Watson <cjwatson@ubuntu.com>
2048
2049 * util/grub.d/30_os-prober.in: Disable os-prober if
2050 `GRUB_DISABLE_OS_PROBER' was set to true.
2051
71acf5e5 20522009-08-23 Robert Millan <rmh.grub@aybabtu.com>
2053
2054 * partmap/pc.c: Rename to ...
2055 * partmap/msdos.c: ... this. Update all users.
2056 (grub_pc_partition_map): Rename to ...
2057 (grub_msdos_partition_map): ... this. Update all users.
2058
2059 * parttool/pcpart.c: Rename to ...
2060 * parttool/msdospart.c: ... this. Update all users.
2061
2062 * include/grub/pc_partition.h: Rename to ...
2063 * include/grub/msdos_partition.h: ... this. Update all users.
2064 (grub_pc_partition_bsd_entry): Rename to ...
2065 (grub_msdos_partition_bsd_entry): ... this. Update all users.
2066 (grub_pc_partition_disk_label): Rename to ...
2067 (grub_msdos_partition_disk_label): ... this. Update all users.
2068 (grub_pc_partition_entry): Rename to ...
2069 (grub_msdos_partition_entry): ... this. Update all users.
2070 (grub_pc_partition_mbr): Rename to ...
2071 (grub_msdos_partition_mbr): ... this. Update all users.
2072 (grub_pc_partition): Rename to ...
2073 (grub_msdos_partition): ... this. Update all users.
2074 (grub_pc_partition_is_empty): Rename to ...
2075 (grub_msdos_partition_is_empty): ... this. Update all users.
2076 (grub_pc_partition_is_extended): Rename to ...
2077 (grub_msdos_partition_is_extended): ... this. Update all users.
2078 (grub_pc_partition_is_bsd): Rename to ...
2079 (grub_msdos_partition_is_bsd): ... this. Update all users.
2080
2081 * conf/common.rmk (amiga_mod_SOURCES, amiga_mod_CFLAGS)
2082 (amiga_mod_LDFLAGS, apple_mod_SOURCES, apple_mod_CFLAGS)
2083 (apple_mod_LDFLAGS, msdos_mod_SOURCES, msdos_mod_CFLAGS)
2084 (msdos_mod_LDFLAGS, sun_mod_SOURCES, sun_mod_CFLAGS)
2085 (sun_mod_LDFLAGS, acorn_mod_SOURCES, acorn_mod_CFLAGS)
2086 (acorn_mod_LDFLAGS, gpt_mod_SOURCES, gpt_mod_CFLAGS)
2087 (gpt_mod_LDFLAGS): Rename to ...
2088 (part_amiga_mod_SOURCES, part_amiga_mod_CFLAGS, part_amiga_mod_LDFLAGS)
2089 (part_apple_mod_SOURCES, part_apple_mod_CFLAGS, part_apple_mod_LDFLAGS)
2090 (part_msdos_mod_SOURCES, part_msdos_mod_CFLAGS, part_msdos_mod_LDFLAGS)
2091 (part_sun_mod_SOURCES, part_sun_mod_CFLAGS, part_sun_mod_LDFLAGS)
2092 (part_acorn_mod_SOURCES, part_acorn_mod_CFLAGS, part_acorn_mod_LDFLAGS)
2093 (part_gpt_mod_SOURCES, part_gpt_mod_CFLAGS)
2094 (part_gpt_mod_LDFLAGS): ... this.
2095 (pkglib_MODULES): Prefix partition modules with `part_'. Rename
2096 `pcpart.mod' to `msdospart.mod'.
2097 (pcpart_mod_SOURCES, pcpart_mod_CFLAGS, pcpart_mod_LDFLAGS): Rename
2098 to ...
2099 (msdospart_mod_SOURCES, msdospart_mod_CFLAGS)
2100 (msdospart_mod_LDFLAGS): ... this.
2101
c11fded5 21022009-08-23 Vladimir Serbinenko <phcoder@gmail.com>
2103
2104 * loader/i386/bsd.c (freebsd_opts): Rewritten to use extcmd.
2105 (openbsd_opts): Likewise.
2106 (netbsd_opts): Likewise.
2107 (freebsd_flags): Added 0 terminator.
2108 (openbsd_flags): Likewise.
2109 (netbsd_flags): Likewise.
2110 (grub_bsd_parse_flags): Rewritten to use extcmd. All users updated.
2111 (grub_cmd_freebsd): Transformed into extended command.
2112 (grub_cmd_openbsd): Likewise.
2113 (grub_cmd_netbsd): Likewise.
2114 (cmd_freebsd): Changed type to grub_extcmd_t.
2115 (cmd_openbsd): Likewise.
2116 (cmd_netbsd): Likewise.
2117 (GRUB_MOD_INIT (bsd)): Register grub_cmd_freebsd, grub_cmd_netbsd and
2118 grub_cmd_openbsd as extended commands.
2119 (GRUB_MOD_FINI (bsd)): Use grub_unregister_extcmd for cmd_freebsd,
2120 cmd_netbsd and cmd_openbsd
2121
11d1c769 21222009-08-22 Vladimir Serbinenko <phcoder@gmail.com>
2123
2124 * commands/xnu_uuid.c (transform): Use grub_memcpy instead of memcpy.
2125
7a9094e5 21262009-08-21 Pavel Roskin <proski@gnu.org>
2127
5496c37e 2128 * Makefile.in (install-local): When checking if a file is in the
2129 build directory, use "test -e" to detect symlinks.
2130
7a9094e5 2131 * Makefile.in (install-local): Remove all files in
2132 $(DESTDIR)$(pkglibdir) before installing new files there.
2133
e53cea11 21342009-08-18 Felix Zielcke <fzielcke@z-51.de>
2135
2136 * util/powerpc/ieee1275/grub-mkrescue.in (grub_mkimage): Use
2137 grub-mkelfimage.
2138
9aced544 21392009-08-18 Felix Zielcke <fzielcke@z-51.de>
2140
2141 * util/grub-mkconfig.in: Don't use gfxterm by default if not
2142 explicitly specified by the user.
2143
b7da6bab 21442009-08-18 Pavel Roskin <proski@gnu.org>
2145
2146 * include/grub/fbfill.h (struct grub_video_fbrender_target): Use
2147 grub_uint8_t pointer for data.
2148 * include/grub/fbutil.h (struct grub_video_fbblit_info):
2149 Likewise.
2150 * video/fb/fbutil.c: Remove unnecessary casts.
2151
19f1b335 21522009-08-17 Michal Suchanek <hramrach@centrum.cz>
2153
2154 VBE cleanup.
2155
2156 * video/i386/pc/vbe.c (vbe_mode_in_use): Removed (duplicate).
2157 (grub_vbe_set_video_mode): Save active mode info
2158 only after setting the mode.
2159 (grub_video_vbe_setup): Call 'grub_vbe_set_video_mode' with NULL as
2160 second argument.
2161
2f467aa9 21622009-08-17 Michal Suchanek <hramrach@centrum.cz>
2163
2164 Rename variables for clarity.
2165
2166 * video/i386/pc/vbe.c (active_mode_info): Renamed to ...
2167 (active_vbe_mode_info): ... this. All users updated.
2168 (framebuffer): Rename 'active_mode' to 'active_vbe_mode'.
2169 All users updated.
2170 (initial_mode): Rename to ...
2171 (initial_vbe_mode): ... this. All users updated.
2172 (mode_in_use): Rename to ..
2173 (vbe_mode_in_use): ... this. All users updated.
2174 (mode_list): Rename to ..
2175 (vbe_mode_list): ... this. All users updated.
2176 (grub_vbe_set_video_mode): Rename 'mode' to 'vbe_mode', 'mode_info' to
2177 'vbe_mode_info' and 'old_mode' to 'old_vbe_mode'.
2178 (grub_video_vbe_init): Rename 'rm_mode_list' to 'rm_vbe_mode_list' and
2179 'mode_list_size' to 'vbe_mode_list_size'.
2180 (grub_video_vbe_setup): Rename 'mode_info' to 'vbe_mode_info',
2181 'best_mode_info' to 'best_vbe_mode_info' and
2182 'best_mode' to 'best_vbe_mode'
2183
6025fcd7 21842009-08-17 Michal Suchanek <hramrach@centrum.cz>
2185
2186 Remove duplicate grub_video_fb_get_video_ptr.
2187
2188 * include/grub/fbutil.h (get_data_ptr): Rename to ...
2189 (grub_video_fb_get_video_ptr): ... this.
2190 * include/grub/video_fb.h (grub_video_fb_get_video_ptr): Removed.
2191 * video/fb/fbutil.c: Add comment about addressing.
2192 (get_data_ptr): Rename to ...
2193 (grub_video_fb_get_video_ptr): ... this. All users updated.
2194 * video/fb/video_fb.c (grub_video_fb_get_video_ptr): Remove.
2195
cc8c6faf 21962009-08-17 Robert Millan <rmh.grub@aybabtu.com>
2197
2198 * fs/fat.c (grub_fat_read_data): Remove `#if 0' braces around the
2199 grub_dprintf() that was just added.
2200
08aa61f0 22012009-08-17 Robert Millan <rmh.grub@aybabtu.com>
2202
2203 * loader/i386/linux.c (GRUB_ASSUME_LINUX_HAS_FB_SUPPORT)
2204 (DEFAULT_VIDEO_MODE): Remove macros.
2205 (grub_linux_boot): Remove assumption that Linux has FB support,
2206 and use "text" as default video mode.
2207
7cef4f75 22082009-08-15 Vladimir Serbinenko <phcoder@gmail.com>
2209
2210 * fs/affs.c (grub_affs_read_symlink): Change leftover grub_printf into
2211 grub_dprintf.
2212 * fs/fat.c (grub_fat_read_data): Likewise.
2213
e1f39873 22142009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2215
2216 * loader/i386/multiboot.c (grub_multiboot): Don't pass filename to
2217 payload.
2218 (grub_module): Likewise.
2219
c166d79e 22202009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2221
2222 * loader/i386/multiboot.c (grub_multiboot_unload): Don't free mbi and
2223 mbi->cmdline but free playground.
2224
c60cee8e 22252009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2226
2227 Handle group offset on UFS1.
2228
2229 * fs/ufs.c (grub_ufs_sblock): New field 'cylg_mask'.
2230 (grub_ufs_read_inode) [!MODE_UFS2]: handle cylg_offset and cylg_mask.
2231
c0d8b5d4 22322009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2233
2234 Split ufs.mod into ufs1.mod and ufs2.mod.
2235
2236 * conf/common.rmk (grub_probe_SOURCES): Add fs/ufs2.c.
2237 (grub_fstest_SOURCES): Likewise.
2238 (pkglib_MODULES): Remove ufs.mod. Add ufs1.mod and ufs2.mod.
2239 (ufs_mod_SOURCES): Remove.
2240 (ufs_mod_CFLAGS): Likewise.
2241 (ufs_mod_LDFLAGS): Likewise.
2242 (ufs1_mod_SOURCES): New variable.
2243 (ufs1_mod_CFLAGS): Likewise.
2244 (ufs1_mod_LDFLAGS): Likewise.
25fbd77a 2245 (ufs2_mod_SOURCES): New variable.
2246 (ufs2_mod_CFLAGS): Likewise.
2247 (ufs2_mod_LDFLAGS): Likewise.
c0d8b5d4 2248 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add fs/ufs2.c.
2249 * conf/i386-efi.rmk (util/i386/efi/grub-mkimage.c_DEPENDENCIES):
2250 Likewise.
2251 (grub_emu_SOURCES): Likewise.
2252 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2253 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
2254 (grub_setup_SOURCES): Likewise.
2255 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2256 * conf/sparc64.rmk (grub_emu_SOURCES): Likewise.
2257 (grub_setup_SOURCES): Likewise.
2258 * conf/x86_64-efi.rmk (util/i386/efi/grub-mkimage.c_DEPENDENCIES):
2259 Likewise.
2260 * fs/ufs2.c: New file.
2261 * fs/ufs.c: Separate UFS1 from UFS2 by using preprocessor.
2262
d3539132 22632009-08-14 Vladimir Serbinenko <phcoder@gmail.com>
2264
2265 Framebuffer split.
2266
2267 * commands/i386/pc/vbetest.c (grub_cmd_vbetest): Restore video
2268 subsystem at the end.
2269 * conf/common.rmk (pkglib_MODULES): Add video_fb.mod.
2270 (video_fb_mod_SOURCES): New variable.
2271 (video_fb_mod_CFLAGS): Likewise.
2272 (video_fb_mod_LDFLAGS): Likewise.
2273 * conf/i386-pc.rmk (vbe_mod_SOURCES): Remove video/i386/pc/vbeblit.c,
2274 video/i386/pc/vbefill.c and video/i386/pc/vbeutil.c.
2275 * video/i386/pc/vbeblit.c: Moved from here ...
2276 * video/fb/fbblit.c: ..here. Replaced 'vbe' with 'fb'.
2277 * video/i386/pc/vbefill.c: Moved from here ...
2278 * video/fb/fbfill.c: ..here. Replaced 'vbe' with 'fb'.
2279 * video/i386/pc/vbeutil.c: Moved from here ...
2280 * video/fb/fbutil.c: ..here. Replaced 'vbe' with 'fb'.
2281 * include/grub/i386/pc/vbeblit.h: Moved from here ...
2282 * include/grub/fbblit.h: ... here. Replaced 'vbe' with 'fb'.
2283 * include/grub/i386/pc/vbefill.h: Moved from here ...
2284 * include/grub/fbfill.h: ... here. Replaced 'vbe' with 'fb'.
2285 * include/grub/i386/pc/vbeutil.h: Moved from here ...
2286 * include/grub/fbutil.h: ... here. Replaced 'vbe' with 'fb'.
2287 * include/grub/i386/pc/vbe.h: Moved framebuffer part ...
2288 * include/grub/video_fb.h: ... here. Replaced 'vbe' with 'fb'.
2289 * include/grub/video.h (GRUB_VIDEO_RENDER_TARGET_FRONT_BUFFER): Removed.
2290 (GRUB_VIDEO_RENDER_TARGET_BACK_BUFFER): Likewise.
2291 (grub_video_adapter): Added 'get_info_and_fini'.
2292 (grub_video_get_info_and_fini): New prototype.
2293 (grub_video_set_mode): make modestring const char *.
2294 * loader/i386/linux.c (grub_linux_setup_video): Use
2295 grub_video_get_info_and_fini.
2296 (grub_linux_boot): Move modesetting just before booting.
2297 * loader/i386/pc/xnu.c (grub_xnu_set_video): Use
2298 grub_video_get_info_and_fini.
2299 * video/i386/pc/vbe.c: Moved framebuffer part ...
2300 * video/fb/video_fb.c: ... here. Replaced 'vbe' with 'fb'.
2301 * video/i386/pc/vbe.c (grub_vbe_set_video_mode): Use
2302 grub_video_fbstd_colors and grub_video_fb_set_palette.
2303 (grub_video_vbe_init): Clear 'framebuffer' variable and use
2304 grub_video_fb_init.
2305 (grub_video_vbe_fini): Use grub_video_fb_fini.
2306 (grub_video_vbe_setup): Use framebuffer.render_target instead of
2307 render_target and use grub_video_fb_set_active_render_target and
2308 grub_video_fb_set_palette.
2309 (grub_video_vbe_set_palette): Use grub_video_fb_set_palette.
2310 (grub_video_vbe_set_viewport): Use grub_video_fb_set_viewport.
2311 (grub_video_vbe_adapter): Use framebuffer.
2312 * video/video.c (grub_video_get_info_and_fini): New function.
2313 (grub_video_set_mode): Make modestring const char *.
2314 (GRUB_MOD_INIT(video_video)): Don't set variables to 0 since these
2315 values are already initialised.
2316
d404ee56 23172009-08-14 Pavel Roskin <proski@gnu.org>
2318
2319 * boot/i386/pc/cdboot.S: Use LOCAL for local labels. Eliminate
2320 ABS and APPLE_CC.
2321 * boot/i386/pc/diskboot.S: Likewise.
2322 * boot/i386/pc/lnxboot.S: Likewise. Hardcode the number of code
2323 sectors allow compilation on MacOSX.
2324 * conf/i386-pc.rmk: Enable unconditional compilation of
2325 lnxboot.img.
2326
9a10df16 23272009-08-13 Colin Watson <cjwatson@ubuntu.com>
2328
2329 * util/grub-mkconfig.in: Export GRUB_HIDDEN_TIMEOUT.
2330 * util/grub.d/00_header.in: Enter interruptible sleep if
2331 GRUB_HIDDEN_TIMEOUT is set.
2332
be3c9ca7 23332009-08-13 Yves Blusseau <blusseau@zetam.org>
2334
2335 * include/grub/symbol.h: Add the LOCAL macro.
2336 * boot/i386/pc/boot.S: Use the LOCAL macro for all labels
2337 starting with "L_".
2338
1f9e557e 23392009-08-13 Pavel Roskin <proski@gnu.org>
2340
9ca62843 2341 * boot/i386/pc/boot.S: Remove ABS macro, it's not required by
2342 any modern compilers we support.
2343
1f9e557e 2344 * boot/i386/pc/boot.S: Remove all code dependent on APPLE_CC.
2345 Use local labels starting with "L_" so that Apple assembler
2346 knows they are local.
2347
81623db6 23482009-08-10 Robert Millan <rmh.grub@aybabtu.com>
2349
2350 * include/grub/i386/bsd.h (KERNEL_TYPE_NONE, KERNEL_TYPE_FREEBSD)
2351 (KERNEL_TYPE_OPENBSD, KERNEL_TYPE_NETBSD): Convert to ...
2352 (bsd_kernel_types): ... this enum.
2353
2354 * loader/i386/bsd.c (grub_cmd_freebsd_loadenv, grub_cmd_freebsd_module)
2355 (grub_cmd_freebsd_module_elf): Abort with "You need to load the
2356 kernel first." when `kernel_type' is set to KERNEL_TYPE_NONE.
2357
2358 (grub_bsd_load_aout, grub_bsd_load, grub_cmd_freebsd_loadenv)
2359 (grub_cmd_freebsd_module, grub_cmd_freebsd_module_elf)
2360 (GRUB_MOD_INIT (bsd)): Fix capitalization in a few error
2361 messages.
2362
f5d35e7a 23632009-08-08 Robert Millan <rmh.grub@aybabtu.com>
2364
2365 * util/grub-dumpdevtree: Moved from here ...
2366 * util/i386/efi/grub-dumpdevtree: ... to here.
2367 (hexify): New function. Converts a string to its hex version.
2368 Generate hex versions of "efi" and "device-properties" by calling
2369 hexify() on the ASCII strings rather than by hardcoding numbers.
2370
d1e1d527 23712009-08-08 Robert Millan <rmh.grub@aybabtu.com>
2372
2373 * fs/jfs.c: Update copyright year.
2374
1ebbe064 23752009-08-08 Felix Zielcke <fzielcke@z-51.de>
2376
2377 * util/grub.d/00_header.in: Fix a comment.
2378 * util/grub.d/10_linux.in: Likewise.
2379 * util/grub.d/10_windows.in: Likewise.
2380 * util/grub.d/10_hurd.in: Likewise.
2381
a78c8d24 23822009-08-08 Felix Zielcke <fzielcke@z-51.de>
2383
2384 * util/grub-mkconfig.in: Allow the user to specify the used font
2385 with GRUB_FONT.
2386
29a6b9e8 23872009-08-08 Pavel Roskin <proski@gnu.org>
2388
b5f16cc4 2389 * include/grub/powerpc/libgcc.h: Export __ashrdi3() if
2390 available, xfs.mod needs it now.
2391
2f5cb827 2392 * util/grub-mkconfig_lib.in (version_test_numeric): Don't use
2393 the "g" modifier in sed when the intention is to strip something
2394 once. This fixes comparison of kernels with multiple dashes.
2395
29a6b9e8 2396 * util/grub-mkconfig.in: Define datarootdir, datadir may depend
2397 on it. Add missing space before closing bracket. Fix
2398 misleading formatting.
2399
892a3d98 24002009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2401
2402 * docs/grub.texi: Major overhaul. Remove all sections that are
2403 specific to GRUB Legacy, or mostly composed of Legacy-specific
2404 information.
2405
ed94253f 24062009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2407
2408 * docs/version.texi: New file. Provides version information for
2409 grub.texi.
2410
126d6628 24112009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2412
2413 * docs/grub.texi: Update CVS information to SVN.
2414 Replace outdated "GRUB 2 will include" phrase with "GRUB 2 includes".
2415
998b5aa9 24162009-08-07 Felix Zielcke <fzielcke@z-51.de>
2417
2418 * util/grub-mkconfig.in: Remove a wrong `fi'.
2419
818e094a 24202009-08-07 Felix Zielcke <fzielcke@z-51.de>
2421
2422 * fs/uuid.c (grub_jfs_superblock): New fields unused2 and uuid.
2423 (grub_jfs_uuid): New function.
2424 (grub_jfs_fs): Set uuid field to grub_jfs_uuid.
2425
b969c52f 24262009-08-07 Felix Zielcke <fzielcke@z-51.de>
2427
2428 * util/grub-mkconfig_lib.in (font_path): Move the functionality
2429 of it to ...
2430 * util/grub-mkconfig.in: ... here. Prefer unicode.pf2 and
2431 unifont.pf2 over ascii.pf2. Export LANG=C in case ascii.pf2 gets used.
2432
7a4894cc 24332009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2434
2435 * util/grub.d/10_linux.in (test_numeric): Moved from here ...
2436 * util/grub-mkconfig_lib.in (version_test_numeric): ... to here.
2437 Update all users.
2438
2439 * util/grub.d/10_linux.in (test_gt): Strip any basename prefix,
2440 not just "vmlinu[zx]".
2441 Moved from here ...
2442 * util/grub-mkconfig_lib.in (version_test_gt): ... to here. Update
2443 all users.
2444
2445 * util/grub.d/10_linux.in (find_latest): Moved from here ...
2446 * util/grub-mkconfig_lib.in (version_find_latest): ... to here. Update
2447 all users.
2448
4e2171f8 24492009-08-07 Robert Millan <rmh.grub@aybabtu.com>
2450
2451 * util/grub.d/10_freebsd.in: Use an absolute device path for
2452 `vfs.root.mountfrom'. Set `vfs.root.mountfrom.options=rw'.
2453
6dcfcb32 24542009-08-06 Felix Zielcke <fzielcke@z-51.de>
2455
2456 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Fix
2457 handling of multiple abstraction modules.
2458
f56a8756 24592009-08-04 Robert Millan <rmh.grub@aybabtu.com>
2460
2461 Fix a bug resulting in black screen when loading Linux using a
2462 packed video mode.
2463
2464 * kern/i386/pc/startup.S (grub_vbe_bios_getset_dac_palette_width): New
2465 function.
2466
2467 * include/grub/i386/pc/vbe.h (GRUB_VBE_CAPABILITY_DACWIDTH): New macro.
2468 (grub_vbe_bios_getset_dac_palette_width): New function.
2469 (grub_vbe_bios_get_dac_palette_width)
2470 (grub_vbe_bios_set_dac_palette_width): New macros (act as wrappers for
2471 grub_vbe_bios_getset_dac_palette_width()).
2472
2473 * video/i386/pc/vbe.c (grub_vbe_probe): Use `GRUB_VBE_STATUS_OK' to
2474 check for return status.
2475 (grub_vbe_get_video_mode_info): When getting information for a packed
2476 mode (<= 8 bpp), obtain DAC palette width using
2477 grub_vbe_bios_getset_dac_palette_width(), and use that for initializing
2478 {red,green,blue}_mark_size.
2479
222671b2 24802009-08-04 Felix Zielcke <fzielcke@z-51.de>
2481
ecb1a6d9 2482 * commands/search.c (options): Fix help output to match actual code.
222671b2 2483
f84114f5 24842009-08-02 Vladimir Serbinenko <phcoder@gmail.com>
2485
2486 * commands/hexdump.c (grub_cmd_hexdump): Use grub_disk_read instead
2487 of homegrown code.
2488
bd288a20 24892009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
e768b770 2490
2491 * util/hostfs.c (grub_hostfs_dir): Don't use DT_DIR: It doesn't work
2492 on XFS or ReiserFS.
2493
8aab5e25 24942009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
2495
2496 Support Apple partition map with sector size different from 512 bytes.
2497
2498 * partmap/apple.c (grub_apple_header): New field 'blocksize'.
2499 (apple_partition_map_iterate): Respect 'aheader.blocksize'
2500 and 'apart.partmap_size'.
2501
6ad6258a 25022009-08-01 Vladimir Serbinenko <phcoder@gmail.com>
25032009-08-01 Robert Millan <rmh.grub@aybabtu.com>
2504
2505 Fix cpuid command.
2506
2507 * commands/i386/cpuid.c (options): New variable.
2508 (grub_cmd_cpuid): Return real error.
2509 (GRUB_MOD_INIT(cpuid)): Declare options.
2510
67459bc6 25112009-07-31 Vladimir Serbinenko <phcoder@gmail.com>
2512
2513 * partmap/pc.c (pc_partition_map_iterate): Check that boot flags are
2514 valid.
2515
fbc6ab54 25162009-07-31 Bean <bean123ch@gmail.com>
2517
2518 * fs/xfs.c (grub_xfs_sblock): Change unused5 field to log2_sect and
2519 log2_inode.
2520 (grub_fshelp_node): Move inode field to the end.
2521 (grub_xfs_data): Remove inode field.
2522 (grub_xfs_inode_block): Calculate inode size using sblock.
2523 (grub_xfs_inode_offset): Likewise.
2524 (grub_xfs_read_inode): Calculate inode size using sblock.
2525 (grub_xfs_read_block): Replace XFS_INODE_EXTENTS with nrec.
2526 (grub_xfs_iterate_dir): Calculate inode size using sblock.
2527 (grub_xfs_mount): Use grub_zalloc instead of grub_malloc. Realloc data
2528 to match inode size.
2529 (grub_xfs_dir): goto mount_fail when mount fails, as data->diropen is
2530 not accessible when data is null.
2531 (grub_xfs_open): Likewise.
2532
f45d6cfc 25332009-07-31 Bean <bean123ch@gmail.com>
2534
2535 * disk/lvm.c (grub_lvm_scan_device): Ignore extra copy of metadata.
2536 Don't change pv->disk if it's already set.
2537
2538 * disk/raid.c (grub_raid_scan_device): Merge this function into ...
2539 (grub_raid_register): ... here.
2540 (grub_raid_rescan): Removed.
2541
2542 * include/grub/raid.h (grub_raid_rescan): Removed.
2543
2544 * util/grub-fstest.c: Remove include file <grub/raid.h>.
2545 (fstest): Replace grub_raid_rescan with module fini function followed
2546 by init function.
2547
2548 * util/grub-probe.c: Add include file <grub/raid.h>.
2549 (probe_raid_level): New function.
2550 (probe): Detect abstraction by walking the disk device, support two
2551 level of abstraction (LVM on RAID) when detecting partition map.
2552
24443b5a 25532009-07-31 Pavel Roskin <proski@gnu.org>
2554
2555 * disk/raid5_recover.c (grub_raid5_recover): Revert conversion
2556 to grub_zalloc(), it was erroneous.
2557 Reported by Bean <bean123ch@gmail.com>
2558
a275d9e7 25592009-07-30 Vladimir Serbinenko <phcoder@gmail.com>
2560
2561 * util/i386/pc/grub-setup.c (setup): Check that no partition is in
ad8ea1f4 2562 embedding zone, not only the first one.
a275d9e7 2563
56c5a47f 25642009-07-29 Joe Auricchio <jauricchio@gmail.com>
2565
2566 * term/gfxterm.c (clear_char): New function.
2567 (grub_virtual_screen_setup): Use clear_char.
2568 (scroll_up): Likewise.
2569 (grub_virtual_screen_cls): Likewise.
2570
67bb323a 25712009-07-29 Felix Zielcke <fzielcke@z-51.de>
2572
2573 * util/deviceiter.c (get_acceleraid_disk_name): New static
2574 function.
2575 (grub_util_iterate_devices): Handle Accelraid devices.
2576 * util/hostdisk.c (convert_system_partition_to_system_disk): Likewise.
2577
388a7c75 25782009-07-28 Robert Millan <rmh.grub@aybabtu.com>
2579
2580 * loader/i386/linux.c (grub_cmd_linux): Use ',' rather than ';' as
2581 separator for the suggested gfxpayload string (';' collides with the
2582 parser and needs escaping).
2583
3bb7abcf 25842009-07-28 Vladimir Serbinenko <phcoder@gmail.com>
2585
2586 * loader/i386/multiboot_helper.S (grub_multiboot_backward_relocator):
2587 Clear direction flag before jumping to OS.
2588 (grub_multiboot2_real_boot): Likewise.
2589
2ddd36d7 25902009-07-28 Felix Zielcke <fzielcke@z-51.de>
2591
2592 * util/i386/pc/grub-install: Fix parsing of --disk-module
2593 option.
2594
c521b62b 25952009-07-28 Felix Zielcke <fzielcke@z-51.de>
2596
2597 * util/i386/pc/grub-setup.c (setup): Fix 2 incorrect checks
2598 when embedding.
2599
880e0a0c 26002009-07-26 Felix Zielcke <fzielcke@z-51.de>
2601
2602 * util/grub-mkconfig.in (package_version): New variable.
2603 Use it do display the version.
2604
2366e356 26052009-07-25 Felix Zielcke <fzielcke@z-51.de>
2606
2607 * kern/file.c (grub_file_open): Revert to previous check with
2608 grub_errno.
2609
7ad8c80e 26102009-07-25 Vladimir Serbinenko <phcoder@gmail.com>
2611
2612 * commands/probe.c (GRUB_MOD_INIT (probe)): Remove "[--target=target]"
2613 from help line. It's out of sync with code.
2614
72b9658b 26152009-07-25 Vladimir Serbinenko <phcoder@gmail.com>
2616
2617 * kern/parser.c (grub_parser_execute): Fix a bug causing truncated
2618 entries on failed boot.
2619
77435277 26202009-07-25 Felix Zielcke <fzielcke@z-51.de>
2621
2622 * kern/file.c (grub_file_open): Fix an error check.
2623
fcaa8b21 26242009-07-24 Vladimir Serbinenko <phcoder@gmail.com>
2625
35d16c74 2626 * util/i386/pc/grub-setup.c (setup): Fix segmentation fault when
2627 partition map couldn't be identified.
fcaa8b21 2628
48904cd1 26292009-07-23 Pavel Roskin <proski@gnu.org>
2630
ef3c317f 2631 * commands/xnu_uuid.c (transform): Use GRUB_CPU_WORDS_BIGENDIAN
2632 instead of WORDS_BIGENDIAN. Use grub_le_to_cpu32(), so that the
2633 case of little endian words becomes just an optimization.
2634 Respect const modifier.
ad8ea1f4 2635 (md5_final): Use code that doesn't depend on endianness.
ef3c317f 2636
48904cd1 2637 * include/grub/misc.h (ALIGN_UP): Cast align to the type of addr
2638 to avoid loss of upper bits if align is unsigned and shorter
2639 than addr.
2640
260c9a89 26412009-07-21 Vladimir Serbinenko <phcoder@gmail.com>
2642
2643 UUID support for UFS
2644
2645 * fs/ufs.c (grub_ufs_sblock): Add uuidhi and uuidlow.
2646 (grub_ufs_uuid): New function.
2647 (grub_ufs_fs): add .uuid
2648
f76ce889 26492009-07-21 Pavel Roskin <proski@gnu.org>
2650
2651 * kern/dl.c (grub_dl_check_header): Make static.
2652
6a6cbcaf 26532009-07-21 Felix Zielcke <fzielcke@z-51.de>
2654
2655 * util/grub.d/30_os-prober.in: Remove unused CHAINROOT. Don't
2656 add drivemap for Vista. It breaks Windows 7.
2657
cffcddb2 26582009-07-21 Vladimir Serbinenko <phcoder@gmail.com>
2659
2660 * fs/ufs.c (grub_ufs_sblock): Fix offset of mtime2 which was off by
2661 128 bytes
2662
1ef44b80 26632009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
2664
2665 Add BFS support
2666
2667 * conf/common.rmk (grub_probe_SOURCES): Add fs/befs.c.
2668 (grub_fstest_SOURCES): Likewise.
2669 (pkglib_MODULES): Add befs.mod.
2670 (befs_mod_SOURCES): New variable.
2671 (befs_mod_CFLAGS): Likewise.
2672 (befs_mod_LDFLAGS): Likewise.
2673 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
2674 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
2675 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2676 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
2677 (grub_setup_SOURCES): Likewise.
2678 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2679 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
2680 (grub_setup_SOURCES): Likewise.
2681 * fs/befs.c: New file.
2682 * fs/afs.c (GRUB_AFS_FSNAME): New declaration.
2683 (GRUB_AFS_SBLOCK_SECTOR): Likewise.
2684 (GRUB_AFS_SBLOCK_MAGIC1) [MODE_BFS]: New conditional declaration.
2685 (GRUB_AFS_BTREE_MAGIC) [MODE_BFS]: Likewise
2686 (B_KEY_INDEX_ALIGN): New declaration.
2687 (B_KEY_INDEX_OFFSET): Use B_KEY_INDEX_ALIGN.
2688 (grub_afs_bnode) [MODE_BFS]: Make key_count and key_size 16-bit
2689 (grub_afs_btree) [MODE_BFS]: New conditional declaration.
2690 (grub_afs_sblock) [MODE_BFS]: Remove link_count.
2691 (grub_afs_validate_sblock) [MODE_BFS]: Support BFS
2692 (grub_afs_mount) [MODE_BFS]: Likewise.
2693 (grub_afs_dir) [MODE_BFS]: Divide mtime by 65536 and not 1000000.
2694 (grub_afs_fs): Use GRUB_AFS_FSNAME
2695 (GRUB_MOD_INIT (afs)) [MODE_BFS]: Rename to ...
2696 (GRUB_MOD_INIT (befs)) [MODE_BFS]: ... this
2697 (GRUB_MOD_FINI (afs)) [MODE_BFS]: Rename to ...
2698 (GRUB_MOD_FINI (befs)) [MODE_BFS]: ... this
2699
4f253044 27002009-07-19 Yves BLUSSEAU <yves.grub-devel@zetam.org>
2701
2702 * util/getroot.c (find_root_device): Add support for MacOSX.
2703 * util/hostdisk.c: Likewise.
2704
57a55913 27052009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
2706
2707 * font/font.c (find_glyph): Check whether a font is present to avoid
2708 segmentation fault.
75421ca9 2709
27102009-07-20 Joe Auricchio <jauricchio@gmail.com>
04c7c429 2711
2712 * term/gfxterm.c (grub_virtual_screen_setup): Clear virtual_screen.
2713
e98cd0c2 27142009-07-20 Pavel Roskin <proski@gnu.org>
2715
2716 * configure.ac: Trim excessively wordy excuses.
2717
1d2d169a 27182009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
2719
2720 Add symlink, mtime and label support to AtheFS.
2721
2722 * fs/afs.c (grub_afs_sblock): Declare `name' as char.
2723 (grub_afs_iterate_dir): Handle symlinks.
2724 (grub_afs_open): Use grub_afs_read_symlink.
2725 (grub_afs_dir): Likewise.
2726 Pass mtime.
2727 (grub_afs_label): New function.
2728 (grub_afs_fs): Add grub_afs_label.
2729 (grub_afs_read_symlink): New function.
2730
186f3189 27312009-07-20 Vladimir Serbinenko <phcoder@gmail.com>
2732
2733 Fix AtheFS support.
2734
2735 * fs/afs.c: Fix comments style.
2736 (grub_afs_blockrun): Declare as packed.
2737 (grub_afs_datastream): Likewise.
2738 (grub_afs_bnode): Likewise.
2739 (grub_afs_btree): Likewise.
2740 (grub_afs_sblock): Likewise.
2741 Declare `name' as char.
2742 (grub_afs_inode): Declare as packed.
2743 Change void *vnode to grub_uint32_t unused.
2744 (grub_afs_iterate_dir): Check that key_size is positive.
2745 (grub_afs_mount): Don't read superblock twice.
75421ca9 2746 (grub_afs_dir): Don't free node in case of error,
186f3189 2747 grub_fshelp_find_file already handles this.
2748 (grub_afs_open): Likewise.
2749
5680109e 27502009-07-19 Pavel Roskin <proski@gnu.org>
2751
2752 * Makefile.in: Remove LIBLZO and enable_lzo.
2753 * conf/i386-pc.rmk: Remove lzo support.
2754 * configure.ac: Remove checks for lzo, don't define ENABLE_LZMA.
2755 * include/grub/i386/pc/kernel.h: Define ENABLE_LZMA. Remove lzo
2756 support.
2757 * kern/i386/pc/lzo1x.S: Remove.
2758 * kern/i386/pc/startup.S: Remove lzo support.
2759 * util/i386/pc/grub-mkimage.c: Likewise.
2760
ac70fa32 27612009-07-19 Vladimir Serbinenko <phcoder@gmail.com>
2762
2763 * disk/usbms.c (grub_usbms_transfer): Fix double semicolon.
2764 * fs/xfs.c (grub_xfs_dir): Likewise.
2765 * fs/afs.c (grub_afs_dir): Likewise.
2766 * fs/iso9660.c (grub_iso9660_iterate_dir): Likewise.
2767 (grub_iso9660_open): Likewise.
2768 * fs/jfs.c (grub_jfs_open): Likewise.
2769 * fs/ext2.c (grub_ext2_dir): Likewise.
2770 * include/grub/macho.h (grub_macho_fat_arch): Likewise.
2771 * script/sh/lexer.c (grub_script_yylex): Likewise.
75421ca9 2772
eab58da2 27732009-07-16 Pavel Roskin <proski@gnu.org>
2774
d2838156 2775 * configure.ac: Never add "-c" to CFLAGS.
2776
55c70904 2777 * configure.ac: Fix incorrect comparison for grub_cv_cc_efiemu.
2778
43e6200c 2779 * configure.ac: Fix wrong use of grub_cv_cc_no_red_zone where
2780 grub_cv_cc_efiemu should be used.
2781
ce7a733d 2782 * configure.ac: Typo fixes.
2783
eab58da2 2784 * kern/mm.c (grub_zalloc): New function.
2785 (grub_debug_zalloc): Likewise.
2786 * include/grub/mm.h: Declare grub_zalloc() and
2787 grub_debug_zalloc().
2788 * util/misc.c (grub_zalloc): New function.
2789 * bus/usb/uhci.c (grub_uhci_pci_iter): Use grub_zalloc()
2790 instead of grub_malloc(), remove unneeded initializations.
2791 * bus/usb/usbhub.c (grub_usb_hub_add_dev): Likewise.
2792 * commands/extcmd.c (grub_extcmd_dispatcher): Likewise.
2793 * commands/parttool.c (grub_cmd_parttool): Likewise.
2794 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): Likewise.
2795 * disk/raid5_recover.c (grub_raid5_recover): Likewise.
2796 * disk/raid6_recover.c (grub_raid6_recover): Likewise.
2797 * disk/usbms.c (grub_usbms_finddevs): Likewise.
2798 * efiemu/mm.c (grub_efiemu_request_memalign): Likewise.
2799 * efiemu/pnvram.c (grub_efiemu_pnvram): Likewise.
2800 (grub_cmd_efiemu_pnvram): Likewise.
2801 * fs/i386/pc/pxe.c (grub_pxefs_open): Likewise.
2802 * fs/iso9660.c (grub_iso9660_mount): Likewise.
2803 (grub_iso9660_iterate_dir): Likewise.
2804 * fs/jfs.c (grub_jfs_opendir): Likewise.
2805 * fs/ntfs.c (list_file): Likewise.
2806 (grub_ntfs_mount): Likewise.
2807 * kern/disk.c (grub_disk_open): Likewise.
2808 * kern/dl.c (grub_dl_load_core): Likewise.
2809 * kern/elf.c (grub_elf_file): Likewise.
2810 * kern/env.c (grub_env_context_open): Likewise.
2811 (grub_env_set): Likewise.
2812 (grub_env_set_data_slot): Likewise.
2813 * kern/file.c (grub_file_open): Likewise.
2814 * kern/fs.c (grub_fs_blocklist_open): Likewise.
2815 * loader/i386/multiboot.c (grub_module): Likewise.
2816 * loader/xnu.c (grub_xnu_create_key): Likewise.
2817 (grub_xnu_create_value): Likewise.
2818 * normal/main.c (grub_normal_add_menu_entry): Likewise.
2819 (read_config_file): Likewise.
2820 * normal/menu_entry.c (make_screen): Likewise.
2821 * partmap/sun.c (sun_partition_map_iterate): Likewise.
2822 * script/sh/lexer.c (grub_script_lexer_init): Likewise.
2823 * script/sh/script.c (grub_script_parse): Likewise.
2824 * video/bitmap.c (grub_video_bitmap_create): Likewise.
2825 * video/readers/jpeg.c (grub_video_reader_jpeg): Likewise.
2826 * video/readers/png.c (grub_png_output_byte): Likewise.
2827 (grub_video_reader_png): Likewise.
2828
830afef7 28292009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
5ce5507f 2830
2831 Enable all targets that can be built by default
2832
830afef7 2833 * configure.ac: enable efiemu runtime, grub-emu, grub-emu-usb,
5ce5507f 2834 grub-mkfont and grub-fstest if they can be built
2835
ee293aee 28362009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
2837
2838 Fix hang and segmentation fault in grub-emu-usb
2839
2840 * disk/scsi.c (grub_scsi_open): return err and not grub_errno
2841 * util/usb.c (grub_libusb_devices): likewise
2842 (grub_libusb_init): rename to ...
2843 (GRUB_MOD_INIT (libusb)):...this
2844 (grub_libusb_fini): rename to ..
2845 (GRUB_MOD_FINI (libusb)):...this
2846 * disk/usbms.c (grub_usbms_transfer): fix retry logic
2847 * include/grub/disk.h (grub_raid_init): removed, it's useless
2848 (grub_raid_fini): likewise
2849 (grub_lvm_init): likewise
2850 (grub_lvm_fini): likewise
2851 * util/grub-emu.c (main): don't call grub_libusb_init, it's done
2852 by grub_init_all
2853
94414221 28542009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
2855
2856 Fix libusb
2857
2858 * Makefile.in (LIBUSB): new macro
2859 * genmk.rb (Utility/print_tail): new method
2860 (Utility/rule): use intermediary variable #{prefix}_OBJECTS
2861 (top level): call util.print_tail at the end.
2862
59ade63d 28632009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
2864
2865 Make FreeBSD accept zpool.cache
2866
2867 * loader/i386/bsd.c (grub_freebsd_add_meta_module): spoof filename if
2868 type is /boot/zfs/zpool.cache
2869
a58da8c7 28702009-07-16 Vladimir Serbinenko <phcoder@gmail.com>
2871
2872 Fix 64-bit efiemu
2873
2874 * include/grub/efiemu/efiemu.h (grub_efiemu_configuration_table64_t):
2875 correct wrong typedef
2876 * efiemu/prepare.c (SUFFIX (grub_efiemu_prepare)): minor style fixes
2877
20591577 28782009-07-15 Pavel Roskin <proski@gnu.org>
2879
560ca572 2880 * include/grub/disk.h (struct grub_disk_dev): Use enum for id.
2881 * kern/disk.c (struct grub_disk_cache): Likewise.
2882
e8e8e4fd 2883 * commands/probe.c (options): Typo fix.
2884
fde24e10 2885 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_BPB_END):
2886 Increase to 0x5a to accommodate FAT32. Adjust other offsets
2887 accordingly.
2888 Original patch by Yves Blusseau <yves.grub-devel@zetam.org>
2889
379c54c1 2890 * boot/i386/pc/boot.S (general_error_string): Add DOS newline at
2891 the end of "Error" to make the message more readable.
2892
7bd8f5bf 2893 * boot/i386/pc/boot.S (kernel_segment): Remove.
2894 (copy_buffer): Use GRUB_BOOT_MACHINE_KERNEL_ADDR in segment 0
2895 for destination.
2896
40b132c5 2897 * boot/i386/pc/boot.S (boot_version): Remove.
2898 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_VER_MAJ):
2899 Remove.
2900
20591577 2901 * include/grub/i386/pc/boot.h: Sort all offsets.
2902 (GRUB_BOOT_MACHINE_KERNEL_ADDRESS): Remove, it's unused.
2903 (GRUB_BOOT_MACHINE_KERNEL_SEGMENT): Likewise.
2904 * boot/i386/pc/boot.S: Assert location of every offset listed in
2905 include/grub/i386/pc/boot.h.
2906
2df32b2c 29072009-07-13 Pavel Roskin <proski@gnu.org>
2908
44b5d879 2909 * include/grub/i386/coreboot/machine.h: Rename
2910 GRUB_MACHINE_LINUXBIOS to GRUB_MACHINE_COREBOOT.
2911 * loader/multiboot_loader.c (grub_cmd_multiboot_loader): Allow
2912 multiboot 1 for GRUB_MACHINE_COREBOOT and GRUB_MACHINE_QEMU.
2913
17dc3751 2914 * kern/dl.c: Force native word size to suppress warnings when
2915 compiling grub-emu.
2916
2df32b2c 2917 * kern/device.c (grub_device_iterate): Change struct part_ent to
2918 hold the name, not a pointer to it. Use one grub_malloc() per
2919 partition, not two. Free partition_name if grub_malloc() fails.
2920 Set ents to NULL only before grub_partition_iterate() is called.
2921
75c59f59 29222009-07-11 Bean <bean123ch@gmail.com>
2923
2924 * kern/ieee1275/openfw.c (grub_children_iterate): Fix size of
2925 childname.
2926
0ae1bf88 29272009-07-10 Bean <bean123ch@gmail.com>
29282009-07-10 Robert Millan <rmh.grub@aybabtu.com>
2929
2930 * kern/ieee1275/openfw.c (grub_children_iterate)
2931 (grub_devalias_iterate): Fix size evaluation for property or path
2932 strings, which was broken since r2132.
2933
8279cade 29342009-07-07 Pavel Roskin <proski@gnu.org>
2935
7d8a52d3 2936 * commands/search.c (search_file): Merge into ...
2937 (search_fs): ... this. Accept search type as argument.
2938 (grub_cmd_search): Pass search type to search_fs().
2939
25f9a05a 2940 * include/grub/util/console.h: New file.
2941 * util/console.c: Use it instead of grub/machine/console.h.
2942 * util/grub-emu.c: Likewise.
2943
8279cade 2944 * lib/arg.c (find_long_option): Remove.
2945 (find_long): Add `len' argument, make `s' const char *.
2946 (grub_arg_parse): Parse long options in place, not in a
2947 temporary buffer.
2948
4a11b60f 29492009-07-06 Pavel Roskin <proski@gnu.org>
2950
99f68041 2951 * commands/search.c (search_fs): Fix potential NULL pointer
2952 dereference.
2953
4a11b60f 2954 * commands/search.c (search_fs): Replace QUID macro with quid_fn
2955 function pointer.
2956
e110f4de 29572009-07-06 Daniel Mierswa <impulze@impulze.org>
2958
2959 * commands/search.c (search_fs): Use grub_strcasecmp() for UUID
2960 comparison.
2961
46eeb6a2 29622009-07-05 Pavel Roskin <proski@gnu.org>
2963
bab74958 2964 * include/grub/i386/linux.h (struct linux_kernel_params):
2965 Restore padding3, it's still needed.
2966
46eeb6a2 2967 * util/grub.d/10_freebsd.in: Fix spelling of `device.hints' on
2968 FreeBSD.
2969 * util/osdetect.lua: Likewise.
2970
b4a1dc79 29712009-07-05 Bean <bean123ch@gmail.com>
2972
2973 * conf/common.rmk (lua_mode_SOURCES): Add script/lua/lstrlib.c.
2974
2975 * script/lua/grub_lib.c (grub_lua_run): Check input parameter.
2976 (grub_lua_getenv): Likewise.
2977 (grub_lua_setenv): Likewise.
2978 (save_errno): New function.
2979 (push_result): Likewise.
2980 (grub_lua_enum_device): Likewise.
2981 (grub_lua_enum_file): Likewise.
2982 (grub_lua_file_open): Likewise.
2983 (grub_lua_file_close): Likewise.
2984 (grub_lua_file_seek): Likewise.
2985 (grub_lua_file_read): Likewise.
2986 (grub_lua_file_getline): Likewise.
2987 (grub_lua_file_getsize): Likewise.
2988 (grub_lua_file_getpos): Likewise.
2989 (grub_lua_file_eof): Likewise.
2990 (grub_lua_file_exist): Likewise.
2991 (grub_lua_add_menu): Likewise.
2992
2993 * script/lua/grub_lua.h (isupper): New inline function.
2994 (islower): Likewise.
2995 (ispunct): Likewise.
2996 (isxdigit): Likewise.
2997 (strcspn): Change to normal function.
2998 (strpbkr): New function declaration.
2999 (memchr): Likewise.
3000
3001 * script/lua/grub_main.c (scan_str): New function.
3002 (strcspn): Likewise.
3003 (strpbrk): Likewise.
3004 (memchr): Likewise.
3005
3006 * script/lua/linit.c (lualibs): Enable the string library.
3007
3008 * util/osdetect.lua: New file.
3009
2da92295 30102009-07-04 Robert Millan <rmh.grub@aybabtu.com>
3011
3012 * include/grub/i386/linux.h (struct linux_kernel_params): Add
3013 `capabilities' member.
3014
b2582ec9 30152009-07-02 Pavel Roskin <proski@gnu.org>
3016
3017 * genparttoollist.sh: Add missing newline at the end.
3018
32622956 30192009-07-01 Pavel Roskin <proski@gnu.org>
3020
87a7339e 3021 * kern/x86_64/efi/callwrap.S: Add missing newline at the end.
3022
d23af54e 3023 * util/hostdisk.c (open_device): Remove `const' from
3024 `sysctl_size', as sysctlbyname() can change it (in this case it
3025 doesn't actually happen).
3026
c94b18a9 3027 * include/grub/types.h: Define GRUB_LONG_MAX and GRUB_LONG_MIN
3028 using signed long int constants.
3029
c6cd3ef0 3030 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): Make `p'
3031 constant to avoid a warning on FreeBSD.
3032
0df63420 3033 * util/hostdisk.c (device_is_wholedisk): Compile only on systems
3034 where it's needed.
3035
999577f1 3036 * Makefile.in: Install include/grub/machine symlink.
3037
6f41557f 3038 * Makefile.in: When installing symlinks, use "cp -fR", which
3039 works on FreeBSD and MacOSX.
3040 From Yves Blusseau <cl7m42e02@sneakemail.com>
3041
c8d22988 3042 * kern/dl.c (grub_dl_resolve_symbol): Make static.
3043 * include/grub/dl.h: Remove grub_dl_resolve_symbol().
3044
1b96e952 3045 * util/misc.c: Move grub_reboot() and grub_halt() ...
3046 * util/grub-emu.c: ... here. Make main_env static.
3047 * include/grub/util/misc.h: Remove main_env.
3048
2ef0084d 3049 * kern/mm.c: Use correct format to print size_t.
3050
32622956 3051 * include/grub/elf.h: Define Elf_Sword and Elf_Xword.
3052 * kern/i386/dl.c: Use ELF symbols without "32" or "64".
3053 * kern/powerpc/dl.c: Likewise.
3054 * kern/sparc64/dl.c: Likewise.
3055 * kern/x86_64/dl.c: Likewise.
3056
3f7f0cd0 30572009-07-01 Robert Millan <rmh.grub@aybabtu.com>
3058
3059 Fix grub-emu build on sparc64-ieee1275.
3060
75421ca9 3061 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Synchronize with ...
3f7f0cd0 3062 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): ... this.
3063
211d06b5 30642009-07-01 Robert Millan <rmh.grub@aybabtu.com>
3065
3066 * util/misc.c: Include `<setjmp.h>' and `<grub/machine/machine.h>'.
3067 (grub_reboot, grub_halt): New functions.
3068
3069 * util/i386/pc/misc.c: Delete. Update all users.
3070 * util/sparc64/ieee1275/misc.c: Likewise.
3071 * util/powerpc/ieee1275/misc.c: Likewise.
3072
aaf53e3c 30732009-07-01 Robert Millan <rmh.grub@aybabtu.com>
3074
3075 * conf/i386.rmk (setjmp_mod_SOURCES)
3076 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): Move to ...
3077 * conf/common.rmk (setjmp_mod_SOURCES)
3078 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): ... here, and modify
3079 to use $(target_cpu).
3080 * conf/x86_64-efi.rmk (setjmp_mod_SOURCES)
3081 (setjmp_mod_ASFLAGS, setjmp_mod_LDFLAGS): Remove.
3082 * conf/powerpc-ieee1275.rmk: Likewise.
3083 * conf/sparc64-ieee1275.rmk: Likewise.
3084
3085 * conf/i386-pc.rmk (kernel_img_SOURCES): Use
3086 $(target_cpu) for kern/$(target_cpu)/dl.c.
3087 * conf/i386-efi.rmk: Likewise.
3088 * conf/i386-ieee1275.rmk: Likewise.
3089 * conf/x86_64-efi.rmk: Likewise.
3090 * conf/i386-coreboot.rmk: Likewise.
3091 * conf/powerpc-ieee1275.rmk (kernel_img_SOURCES): Use
3092 $(target_cpu) for kern/$(target_cpu)/dl.c and for
3093 kern/$(target_cpu)/cache.S.
3094 * conf/sparc64-ieee1275.rmk: Likewise.
3095
a337130b 30962009-07-01 Robert Millan <rmh.grub@aybabtu.com>
3097
3098 * include/grub/i386/linux.h (linux_kernel_params): Change `mmap_size'
3099 type to `grub_uint8_t', and adjust `padding9' accordingly.
3100
c6fe4d53 31012009-06-29 Robert Millan <rmh.grub@aybabtu.com>
3102
b09db61d 3103 * include/grub/i386/linux.h (GRUB_VIDEO_TYPE_TEXT): New macro.
3104
c6fe4d53 3105 * loader/i386/linux.c [__i386__] (grub_linux_boot): Simplify inline
3106 assembly in final jump, using register constraints.
3107
b09db61d 3108 (grub_linux_boot): For text mode, initialize `have_vga' using
3109 GRUB_VIDEO_TYPE_TEXT rather than 0 (this changes its value to 1).
3110
3111 Initialize `video_cursor_x' and `video_cursor_y' as late as possible,
3112 right before the final jump.
3113
3114 Set `video_mode' to 0x3.
3115
3116 Document initialization of `video_page', `video_mode' and
3117 `video_ega_bx'.
3118
28333ad0 31192009-06-29 Robert Millan <rmh.grub@aybabtu.com>
3120
3121 * include/grub/i386/linux.h (GRUB_LINUX_FLAG_QUIET): New macro.
3122 * loader/i386/linux.c (grub_cmd_linux): Recognize "quiet" option,
75421ca9 3123 and set GRUB_LINUX_FLAG_QUIET appropriately.
28333ad0 3124
02164e1b 31252009-06-29 Robert Millan <rmh.grub@aybabtu.com>
3126
3127 Fix build on Debian / sparc.
3128
3129 * configure.ac: Recognize `sparc' target_cpu (as sparc64).
3130
18b6c557 31312009-06-28 Pavel Roskin <proski@gnu.org>
3132
85f2aab6 3133 * kern/i386/qemu/mmap.c (grub_machine_mmap_iterate): Use cast to
3134 fix a warning.
3135
18b6c557 3136 * util/grub.d/10_linux.in: Match SUSE style initrd names.
3137
ad760f81 31382009-06-27 Robert Millan <rmh.grub@aybabtu.com>
3139
3140 * loader/i386/linux.c (grub_linux_boot): Fix uninitialized use of
3141 `err'.
3142
87a4623b 31432009-06-27 Robert Millan <rmh.grub@aybabtu.com>
3144
3145 Revert r2338.
3146
3147 * loader/i386/linux.c (grub_cmd_linux): Don't call grub_error when
3148 file can't be opened. grub_file_open() is already supposed to set
75421ca9 3149 grub_errno / grub_errmsg appropriately.
87a4623b 3150 * loader/i386/pc/linux.c (grub_cmd_linux): Likewise.
3151
8231fb77 31522009-06-27 Pavel Roskin <proski@gnu.org>
31532009-06-27 Robert Millan <rmh.grub@aybabtu.com>
3154
3155 * include/grub/dl.h: Include grub/elf.h.
3156 (struct grub_dl): Add symtab field.
3157 * kern/dl.c [GRUB_MACHINE_QEMU]: Define
3158 GRUB_MODULES_MACHINE_READONLY.
3159 (grub_dl_resolve_symbols): Populate mod->symtab, making a copy
3160 of the header for read-only modules.
3161 (grub_dl_unload): Free mod->symtab for read-only modules.
3162 * kern/i386/dl.c: Use mod->symtab.
3163 * kern/powerpc/dl.c: Likewise.
3164 * kern/sparc64/dl.c: Likewise.
3165 * kern/x86_64/dl.c: Likewise.
3166
3167 * conf/i386-qemu.rmk: New file.
3168 * kern/i386/qemu/startup.S: Likewise.
3169 * kern/i386/qemu/mmap.c: Likewise.
3170 * boot/i386/qemu/boot.S: Likewise.
3171 * include/grub/i386/qemu/time.h: Likewise.
3172 * include/grub/i386/qemu/serial.h: Likewise.
3173 * include/grub/i386/qemu/kernel.h: Likewise.
3174 * include/grub/i386/qemu/console.h: Likewise.
3175 * include/grub/i386/qemu/boot.h: Likewise.
3176 * include/grub/i386/qemu/init.h: Likewise.
3177 * include/grub/i386/qemu/machine.h: Likewise.
3178 * include/grub/i386/qemu/loader.h: Likewise.
3179 * include/grub/i386/qemu/memory.h: Likewise.
3180
3181 * conf/i386-coreboot.rmk (GRUB_BOOT_MACHINE_LINK_ADDR)
3182 (GRUB_KERNEL_MACHINE_LINK_ADDR): New variables.
3183 [qemu] (pkglib_IMAGES): Add `boot.img'.
3184 [qemu] (boot_img_SOURCES, boot_img_ASFLAGS, boot_img_LDFLAGS)
3185 [qemu] (boot_img_FORMAT): New variables.
3186 [qemu] (bin_UTILITIES): Add `grub-mkimage'.
3187 [qemu] (grub_mkimage_SOURCES, grub_mkimage_CFLAGS): New variables.
3188 [qemu] (kernel_img_SOURCES, kernel_img_HEADERS, kernel_img_CFLAGS)
3189 [qemu] (kernel_img_ASFLAGS, kernel_img_LDFLAGS)
3190 [qemu] (kernel_img_FORMAT): New variables.
3191
3192 * configure.ac: Recognise `i386-qemu'.
3193
3194 * util/i386/pc/grub-mkimage.c (compress_kernel): Add dummy variant
3195 (for no compression).
3196 [GRUB_MACHINE_QEMU] (generate_image): Misc adjustments to produce
3197 a valid i386 ROM image. Make `GRUB_KERNEL_MACHINE_COMPRESSED_SIZE',
3198 `GRUB_KERNEL_MACHINE_INSTALL_DOS_PART' and
3199 `GRUB_KERNEL_MACHINE_INSTALL_BSD_PART' optional features (with
3200 ifdefs).
3201
97fe384e 32022009-06-27 Pavel Roskin <proski@gnu.org>
3203
3204 * efiemu/prepare.c: Eliminate TYPE macro, it makes code hard to
3205 read.
3206 * efiemu/prepare32.c: Likewise.
3207 * efiemu/prepare64.c: Likewise.
3208
c402ab17 32092009-06-26 Pavel Roskin <proski@gnu.org>
3210
3211 * include/grub/types.h: Define GRUB_TARGET_WORDSIZE.
3212 * include/grub/elf.h: Define symbols without "32" or "64" based
3213 on GRUB_TARGET_WORDSIZE.
3214 * include/grub/multiboot2.h: Use GRUB_TARGET_WORDSIZE.
3215 * efiemu/loadcore32.c: Redefine GRUB_TARGET_WORDSIZE, remove own
3216 ELF definitions.
3217 * efiemu/loadcore64.c: Likewise.
3218 * loader/i386/bsd32.c: Likewise.
3219 * loader/i386/bsd64.c: Likewise.
3220 * kern/dl.c: Remove own ELF definitions.
3221 * util/i386/efi/grub-mkimage.c: Likewise.
3222
9bbdfd4d 32232009-06-23 Robert Millan <rmh.grub@aybabtu.com>
3224
3225 * kern/i386/pc/startup.S (real_to_prot): Access `gdtdesc' using
3226 segment 0x0 unconditionally, because the reference generated by
3227 GAS is an absolute address.
3228
a42ce6e9 32292009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3230
3231 * include/grub/i386/kernel.h: Include `<grub/machine/machine.h>'.
3232 [! GRUB_MACHINE_IEEE1275]: Set `GRUB_MOD_ALIGN' to 0x1.
3233
c952cf92 32342009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3235
3236 * commands/search.c (grub_cmd_search): Macroify hardcoded args[]
3237 indexes. Check for -f explicitly.
cc3752ad 3238 (search_file): Improve error message.
3239 (GRUB_MOD_INIT(search)): Add missing `-n' to help output.
c952cf92 3240
132a0a59 32412009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3242
3243 * conf/i386-pc.rmk (GRUB_MEMORY_MACHINE_LINK_ADDR): Rename to ...
3244 (GRUB_KERNEL_MACHINE_LINK_ADDR): ... this. Update all users.
3245
387a140c 32462009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3247
3248 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/misc.S'.
3249 * conf/i386-ieee1275.rmk: Likewise.
3250 * conf/i386-coreboot.rmk: Likewise.
3251
3252 * kern/i386/pc/startup.S (grub_stop): Remove function.
3253 * kern/i386/ieee1275/startup.S: Likewise.
3254 * kern/i386/coreboot/startup.S: Likewise.
3255 * kern/i386/misc.S (grub_stop): New function.
3256
41da9665 32572009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3258
3259 * kern/i386/pc/startup.S (real_to_prot): Move from here ...
3260 * kern/i386/realmode.S (real_to_prot): ... to here.
3261
bf337234 32622009-06-22 Robert Millan <rmh.grub@aybabtu.com>
3263
3264 * conf/i386-ieee1275.rmk (pkglib_PROGRAMS): Replace `kernel.elf'
3265 with `kernel.img'.
3266 (kernel_elf_SOURCES): Rename to ...
3267 (kernel_img_SOURCES): ... this.
3268 (kernel_elf_HEADERS): Rename to ...
3269 (kernel_img_HEADERS): ... this. Update all users.
3270 (kernel_elf_ASFLAGS): Rename to ...
3271 (kernel_img_ASFLAGS): ... this.
3272 (kernel_elf_CFLAGS): Rename to ...
3273 (kernel_img_CFLAGS): ... this.
3274 (kernel_elf_LDFLAGS): Rename to ...
3275 (kernel_img_LDFLAGS): ... this.
3276 * conf/i386-coreboot.rmk: Likewise.
3277 * conf/powerpc-ieee1275.rmk: Likewise.
3278
3279 * util/elf/grub-mkimage.c (add_segments): Replace "kernel.elf"
3280 with "kernel.img".
3281
f52196ff 32822009-06-21 Pavel Roskin <proski@gnu.org>
3283
c3cee413 3284 * loader/powerpc/ieee1275/linux.c (offset_phdr): Fix prototypes
3285 to match nested functions.
3286 * loader/sparc64/ieee1275/linux.c: Likewise.
3287
f52196ff 3288 * conf/i386-ieee1275.rmk: Define kernel_elf_ASFLAGS.
3289
58750afc 32902009-06-21 Robert Millan <rmh.grub@aybabtu.com>
3291
3292 * configure.ac: Enable `END_SYMBOL' / `BSS_START_SYMBOL' test on
3293 all i386 platforms.
3294
15355c7d 32952009-06-21 Robert Millan <rmh.grub@aybabtu.com>
3296
3297 Fix asm file handling on ELF, and remove workarounds.
3298
3299 * genmk.rb (class Programs): Detect assembly files, and set ASFLAGS
75421ca9 3300 and -DASM_FILE=1 appropriately (copied from `class Images' stanza).
15355c7d 3301 * kern/i386/ieee1275/startup.S (ASM_FILE): Remove macro.
3302 * kern/i386/coreboot/startup.S (ASM_FILE): Likewise.
3303
3f3ec72b 33042009-06-21 Vladimir Serbinenko <phcoder@gmail.com>
3305
3306 Load BSD ELF modules
3307
3308 * conf/i386-pc.rmk (bsd_mod_SOURCES): Add loader/i386/bsd32.c
3309 and loader/i386/bsd64.c
3310 * include/grub/i386/bsd.h (FREEBSD_MODTYPE_MODULE): Remove
3311 (FREEBSD_MODTYPE_ELF_MODULE): New definition
3312 (FREEBSD_MODTYPE_ELF_MODULE_OBJ): Likewise
3313 (grub_freebsd_load_elfmodule32): New declaration
3314 (grub_freebsd_load_elfmoduleobj64): Likewise
3315 (grub_freebsd_load_elf_meta32): Likewise
3316 (grub_freebsd_load_elf_meta64): Likewise
3317 (grub_freebsd_add_meta): Likewise
3318 (grub_freebsd_add_meta_module): Likewise
3319 * loader/i386/bsd.c (grub_freebsd_add_meta): Make global
3320 (grub_freebsd_add_meta_module): Likewise and move module-specific
3321 parts to grub_cmd_freebsd and grub_cmd_freebsd_module
3322 (grub_cmd_freebsd): Add elf-kernel specific parts
3323 based on grub_freebsd_add_meta_module
3324 (grub_cmd_freebsd_module): Add type parsing moved from
3325 grub_freebsd_add_meta_module
3326 (grub_cmd_freebsd_module_elf): New function
3327 (cmd_freebsd_module_elf): New variable
3328 (GRUB_MOD_INIT): Register freebsd_module_elf
3329 * loader/i386/bsd32.c: New file
3330 * loader/i386/bsd64.c: Likewise
3331 * loader/i386/bsdXX.c: Likewise
3332 * kern/elf.c (grub_elf32_load): Let hook decide which pheaders to load
3333 (grub_elf64_load): Likewise
3334 * include/grub/elfload.h (grub_elf32_load_hook_t): New parameter do_load
3335 All users updated
3336 (grub_elf64_load_hook_t): Likewise
3337
0db15301 33382009-06-21 Colin Watson <cjwatson@ubuntu.com>
3339
3340 * util/grub-mkconfig.in (GRUB_DISABLE_LINUX_RECOVERY): Export
3341 variable.
3342 * util/grub.d/10_linux.in: If GRUB_DISABLE_LINUX_RECOVERY is true,
3343 don't write a menu entry for recovery mode.
3344
546796c1 33452009-06-20 Robert Millan <rmh.grub@aybabtu.com>
3346
3347 * util/i386/pc/grub-mkimage.c (main): Oops, free `output' only
3348 after it's no longer needed.
3349
cd7310d5 33502009-06-20 Robert Millan <rmh.grub@aybabtu.com>
3351
3352 * include/grub/i386/loader.h (grub_linux_prot_size)
3353 (grub_linux_tmp_addr, grub_linux_real_addr)
3354 (grub_linux_is_bzimage, grub_linux16_boot): Declare only on
3355 GRUB_MACHINE_PCBIOS.
3356 * util/i386/pc/grub-mkimage.c (compress_kernel): Move
3357 common grub_util_info() call to ...
3358 (generate_image): ... here.
3359 Fix use of uninitialized memory, comparison of signed with
3360 unsigned integers and memory leak.
3361 Remove bogus module address message.
3362
ab32d3b5 33632009-06-20 Vladimir Serbinenko <phcoder@gmail.com>
3364
3365 * disk/mdraid_linux.c (GRUB_MOD_FINI): use grub_raid_unregister and not
3366 grub_raid_register
3367 * disk/dmraid_nvidia.c (GRUB_MOD_FINI): likewise
3368
024ef597 33692009-06-19 Pavel Roskin <proski@gnu.org>
3370
3371 * configure.ac: Remove stray AC_MSG_CHECKING.
3372
3ac72b51 33732009-06-19 Vladimir Serbinenko <phcoder@gmail.com>
3374
3375 * disk/scsi.c (grub_scsi_open): use continue instead of big if
dd74360c 3376
e14cd814 33772009-06-18 Pavel Roskin <proski@gnu.org>
3378
3379 * conf/common.rmk: Add fs_file.mod.
3380 * disk/fs_file.c: New file.
3381 * include/grub/disk.h (enum grub_disk_dev_id): Add
3382 GRUB_DISK_DEVICE_FILE_ID.
3383
26586d98 33842009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
3385
3386 Fix build with Apple's toolchain. Part 2
3387
3388 * aclocal.m4 (grub_PROG_TARGET_CC): add missing prototype for main and
3389 a fake start
3390
26de2bcd 33912009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
3392
3393 Fix build with Apple's toolchain. Part 1
3394
3395 * commands/i386/pc/drivemap_int13h.S: use assembly-time constants
3396 for long calls
3397 * configure.ac: remove a leftover AC_MSG_RESULT
dd74360c 3398 (CFLAGS): don't add -Wl,--defsym,___main=0x8100 when building with
26de2bcd 3399 Apple's toolchain
3400
09b3490b 34012009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
3402
3403 Fix warnings
3404
3405 * fs/ntfscomp.c (decomp_get16): initialize c1 and c2
3406 (decomp_block): initialize ch
3407 use grub_memcpy instead of memcpy
3408
c22a006a 34092009-06-17 Pavel Roskin <proski@gnu.org>
3410
d3638678 3411 * include/grub/i386/coreboot/console.h: Don't use the i386-pc
3412 version, use declarations needed to use vga_text as the startup
3413 console.
3414
c22a006a 3415 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Remove
3416 term/i386/pc/at_keyboard.c, it doesn't need to be compiled into
3417 the kernel.
3418 * kern/i386/coreboot/init.c: Don't call grub_at_keyboard_init()
3419 and grub_at_keyboard_fini(), it's done on module load and
3420 unload.
3421
05b129e0 34222009-06-17 Felix Zielcke <fzielcke@z-51.de>
3423
3424 * loader/i386/linux.c (grub_cmd_linux): Set grub_error if the
3425 file can't be found.
3426 * loader/i386/pc/linux.c (grub_cmd_linux): Likewise.
3427
cf24ed9e 34282009-06-17 Vladimir Serbinenko <phcoder@gmail.com>
3429
3430 Fix newline handling
3431
3432 * include/grub/script_sh.h (grub_lexer_param): new field was_newline
dd74360c 3433 * script/sh/lexer.c (grub_script_lexer_init): initialize was_newline
cf24ed9e 3434 (grub_script_yylex): don't segfault on unterminated script
3435 newline terminates command and variable
3436
74aa8e4b 34372009-06-17 Vladimir Serbinenko <phcoder@gmail.com>
3438
3439 avoid double grub_adjust_range call. Bug reported by David Simner
3440
3441 * kern/disk.c (grub_disk_write): change to raw disk access before
3442 calling disk_read
3443
1bd265f3 34442009-06-17 Colin Watson <cjwatson@ubuntu.com>
3445
3446 * util/elf/grub-mkimage.c (usage): Prefix each option line with two
3447 spaces, for the benefit of help2man.
3448 * util/i386/efi/grub-mkimage.c (usage): Likewise.
3449
a2d08c06 34502009-06-16 Pavel Roskin <proski@gnu.org>
3451
3452 * kern/i386/halt.c: Include grub/machine/init.h.
3453 * kern/i386/reboot.c: Include grub/cpu/reboot.h.
3454
b97bcb19 34552009-06-16 Felix Zielcke <fzielcke@z-51.de>
3456
3457 * util/grub.d/30_os-prober.in: Use ${root} in the generated
3458 drivemap menuentry.
3459
0644f96c 34602009-06-16 James Jarvis <James.Jarvis@ed.ac.uk>
3461
3462 * commands/help.c GRUB_MOD_INIT(echo): Fix the help output of
3463 `echo' command.
3464
3ef17a2e 34652009-06-16 Pavel Roskin <proski@gnu.org>
3466
3467 * boot/i386/pc/boot.S: Remove root_drive. Assert offset of
3468 boot_drive_check by using GRUB_BOOT_MACHINE_DRIVE_CHECK. Don't
3469 save %dx, we only need %dl and we never change it.
3470 * boot/i386/pc/cdboot.S: Don't set the root drive.
3471 * boot/i386/pc/pxeboot.S: Likewise.
3472 * include/grub/i386/pc/boot.h: Remove
3473 GRUB_BOOT_MACHINE_ROOT_DRIVE, adjust
3474 GRUB_BOOT_MACHINE_DRIVE_CHECK.
3475 * include/grub/i386/pc/kernel.h: Remove grub_root_drive.
3476 * kern/i386/pc/init.c (make_install_device): Remove references
3477 to grub_root_drive.
3478 * kern/i386/pc/startup.S: Likewise.
3479 * util/i386/pc/grub-setup.c (setup): Don't set root_drive.
3480
693fe637 34812009-06-16 Vladimir Serbinenko <phcoder@gmail.com>
3482
3483 xnu_uuid command
3484
3485 * commands/xnu_uuid.c: new file
3486 * conf/common.rmk (pkglib_MODULES): add xnu_uuid.mod
3487 (xnu_uuid_mod_SOURCES): new variable
3488 (xnu_uuid_mod_CFLAGS): likewise
3489 (xnu_uuid_mod_LDFLAGS): likewise
3490 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/probe.c
3491 * conf/i386-ieee1275.rmk: likewise
3492 * conf/i386-pc.rmk: likewise
3493 * conf/powerpc-ieee1275.rmk: likewise
3494 * conf/sparc64-ieee1275.rmk: likewise
3495 * util/grub.d/30_os-prober.in: use UUID for Mac OS X/Darwin
3496
c9da87d0 34972009-06-16 Pavel Roskin <proski@gnu.org>
3498
3499 * configure.ac: Avoid '==' in test command, it's not portable.
3500
9c6f4596 35012009-06-16 Vladimir Serbinenko <phcoder@gmail.com>
3502
3503 Probe command
3504
3505 * commands/probe.c: new file
3506 * conf/common.rmk (pkglib_MODULES): add probe.mod
3507 (probe_mod_SOURCES): new variable
3508 (probe_mod_CFLAGS): likewise
3509 (probe_mod_LDFLAGS): likewise
3510 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/probe.c
3511 * conf/i386-ieee1275.rmk: likewise
3512 * conf/i386-pc.rmk: likewise
3513 * conf/powerpc-ieee1275.rmk: likewise
3514 * conf/sparc64-ieee1275.rmk: likewise
3515
70b7f9fd 35162009-06-15 Vladimir Serbinenko <phcoder@gmail.com>
3517
3518 Fix handling of string like \"hello\" and "a
3519 b"
3520
3521 * script/sh/lexer.c (check_textstate): accept GRUB_PARSER_STATE_ESC
3522 (grub_script_yylex): fix parsing of quoting, escaping and newline
3523
71c79a6b 35242009-06-13 Vladimir Serbinenko <phcoder@gmail.com>
3525
dd74360c 3526 * loader/i386/multiboot.c (grub_multiboot_get_bootdev): fix partition
71c79a6b 3527 handling
dd74360c 3528
0644f96c 35292009-06-13 Jun Inoue <jun.lambda@gmail.com>
880fc3c4 3530
3531 * util/grub-mkconfig.in: Fix parsing of --output option.
3532
e40893c3 35332009-06-12 Pavel Roskin <proski@gnu.org>
3534
3535 * Makefile.in (pkgdata_SRCDIR): Remove. genmodsrc.sh and
3536 genmk.rb don't need to be generated or installed.
3537
3a1acfe2 35382009-06-12 Vladimir Serbinenko <phcoder@gmail.com>
3539
3540 * commands/i386/pc/drivemap_int13h.S: add more comments
3541
3a4575d4 35422009-06-11 Pavel Roskin <proski@gnu.org>
3543
0658e928 3544 * Makefile.in (uninstall): Uninstall manuals.
3545
ca0388f0 3546 * Makefile.in: Rename lib_DATA to lib_SCRIPTS, move it from
3547 PKGLIB to SCRIPTS. This fixes installation of grub-mkconfig_lib
3548 and update-grub_lib in two places.
3549 * conf/common.rmk: Rename lib_DATA to lib_SCRIPTS.
3550
e3b27c39 3551 * disk/usbms.c (grub_usbms_transfer): Initialize `err' to fix
3552 a compiler warning.
3553
3a4575d4 3554 * loader/i386/bsd.c (grub_freebsd_boot): Rename `entry' to
3555 `entry_lo' to fix variable shadowing.
3556
af1f4f55 35572009-06-11 Christian Franke <franke@computer.org>
3558
3559 * kern/misc.c (__enable_execute_stack): Add missing return type
3560 to prevent gcc warning.
3561
5225e649 35622009-06-11 Felix Zielcke <fzielcke@z-51.de>
3563
3564 * conf/i386-ieee1275.rmk (COMMON_LDFLAGS): Remove `-static -lgcc'.
3565
7d83bd47 35662009-06-11 Pavel Roskin <proski@gnu.org>
3567
c1cb63ba 3568 * Makefile.in: Don't rely on any scripts being executable.
3569 Always use $(SHELL) to run shell scripts.
3570
7d83bd47 3571 * configure.ac: Always define ___main if using -nostdlib. This
3572 fixes tests on Cygwin.
3573
948f48e7 35742009-06-11 Giuseppe Caizzone <acaizzo@gmail.com>
3575
3576 UDF fix
3577
7d83bd47 3578 * fs/udf.c (grub_udf_read_block): handle the fact that ad->length
948f48e7 3579 is in bytes and not in blocks
7d83bd47 3580
8ada9bc1 35812009-06-11 Pavel Roskin <proski@gnu.org>
3582
3583 * kern/i386/halt.c (grub_halt): Make `i' unsigned to fix a
3584 warning.
3585
25ad2323 35862009-06-11 Felix Zielcke <fzielcke@z-51.de>
3587
3588 * util/grub.d/30_os-prober.in: Fix a comment. Source
3589 ${libdir}/grub/grub-mkconfig_lib. Use prepare_grub_to_access_device
3590 to set the root device. Place drivemap command in the generated
3591 chain entry.
3592
e65acb0c 35932009-06-11 Pavel Roskin <proski@gnu.org>
3594
3595 * configure.ac: Remove host_m32. Issues with 64-bit utilities
3596 have long been resolved.
3597
f285fe2d 35982009-06-11 Colin Watson <cjwatson@ubuntu.com>
3599
bd47b0b5 3600 * util/grub.d/10_linux.in: Capitalise "Linux".
3601
f285fe2d 3602 * util/grub-pe2elf.c (usage): Fix references to grub-editenv.
3603
a0c62e4e 36042009-06-11 Pavel Roskin <proski@gnu.org>
3605
b6783cb2 3606 * kern/efi/efi.c (grub_exit): Add infinite loop at the end to
3607 fix a gcc warning and ensure that the function won't ever exit.
3608
dde032e8 3609 * kern/i386/ieee1275/init.c: Add missing prototype for
3610 grub_stop_floppy().
3611
22cd079d 3612 * loader/ieee1275/multiboot2.c [__i386__]: Include
3613 grub/cpu/multiboot.h.
3614
a0c62e4e 3615 * term/i386/pc/serial.c (serial_translate_key_sequence): Avoid
3616 casts to short - they are not portable and cause warnings. Fix
3617 use of uninitialized values in input_buf. Use ARRAY_SIZE.
3618
63963d17 36192009-06-11 Vladimir Serbinenko <phcoder@gmail.com>
3620
3621 Drivemap fixes
3622
3623 * commands/i386/pc/drivemap.c (grub_get_root_biosnumber_drivemap):
3624 new function
3625 (grub_get_root_biosnumber_saved): new variable
3626 (GRUB_MOD_INIT): register grub_get_root_biosnumber_drivemap
3627 (GRUB_MOD_FINI): unregister grub_get_root_biosnumber_drivemap
775dbc4d 3628 * commands/i386/pc/drivemap_int13h.S (grub_drivemap_handler): restore
63963d17 3629 %dx after the call if necessary
3630 * conf/common.rmk (pkglib_MODULES): remove boot.mod
3631 (boot_mod_SOURCES): remove
3632 (boot_mod_CFLAGS): remove
3633 (boot_mod_LDFLAGS): remove
3634 * conf/i386-coreboot.rmk (pkglib_MODULES): add boot.mod
3635 (boot_mod_SOURCES): new variable
3636 (boot_mod_CFLAGS): likewise
3637 (boot_mod_LDFLAGS): likewise
3638 * conf/i386-efi.rmk: likewise
3639 * conf/i386-ieee1275.rmk: likewise
3640 * conf/i386-pc.rmk: likewise
3641 * conf/powerpc-ieee1275.rmk: likewise
3642 * conf/sparc64-ieee1275.rmk: likewise
3643 * conf/x86_64-efi.rmk: likewise
3644 * include/grub/i386/pc/biosnum.h: new file
3645 * lib/i386/pc/biosnum.c: likewise
3646 * loader/i386/bsd.c (grub_bsd_get_device): use grub_get_root_biosnumber
3647 * loader/i386/multiboot.c (grub_multiboot_get_bootdev): likewise
3648 * loader/i386/pc/chainloader.c (grub_chainloader_cmd): likewise
775dbc4d 3649
33abf7ae 36502009-06-10 Pavel Roskin <proski@gnu.org>
3651
5ac35b35 3652 * io/gzio.c (test_header): Don't reuse one buffer for all data.
3653 Use separate variables. Read only the file size at the end, but
3654 not the checksum that we don't use.
3655
5c5215d5 3656 * kern/file.c (grub_file_read): Use void pointer for the buffer.
3657 Adjust all callers.
3658
27d5fef7 3659 * kern/ieee1275/openfw.c: Remove libc includes.
3660 * kern/ieee1275/cmain.c: Likewise.
3661 * include/grub/ieee1275/ieee1275.h: Likewise.
3662
33abf7ae 3663 * kern/i386/coreboot/init.c: Include grub/cpu/tsc.h to fix
3664 compiler warnings.
3665
19d50c2b 36662009-06-10 Felix Zielcke <fzielcke@z-51.de>
3667
3668 * Makefile.in: Remove all trailing whitespace.
3669 * conf/i386-pc.rmk: Likewise.
3670 * conf/powerpc-ieee1275.rmk: Likewise.
3671 * conf/sparc64-ieee1275.rmk: Likewise.
3672 * docs/grub.texi: Likewise.
3673 * docs/texinfo.tex: Likewise.
3674 * disk/fs_uuid.c: Likewise.
3675 * disk/lvm.c: Likewise.
3676 * disk/scsi.c: Likewise.
3677 * disk/ata.c: Likewise.
3678 * disk/ieee1275/ofdisk.c: Likewise.
3679 * disk/i386/pc/biosdisk.c: Likewise.
3680 * disk/host.c: Likewise.
3681 * disk/raid.c: Likewise.
3682 * disk/efi/efidisk.c: Likewise.
3683 * disk/usbms.c: Likewise.
3684 * disk/memdisk.c: Likewise.
3685 * disk/loopback.c: Likewise.
3686 * kern/powerpc/dl.c: Likewise.
3687 * kern/device.c: Likewise.
3688 * kern/dl.c: Likewise.
3689 * kern/sparc64/dl.c: Likewise.
3690 * kern/ieee1275/ieee1275.c: Likewise.
3691 * kern/term.c: Likewise.
3692 * kern/fs.c: Likewise.
3693 * kern/i386/dl.c: Likewise.
3694 * kern/i386/pc/startup.S: Likewise.
3695 * kern/i386/pc/init.c: Likewise.
3696 * kern/i386/pc/mmap.c: Likewise.
3697 * kern/i386/pc/lzo1x.S: Likewise.
3698 * kern/i386/ieee1275/init.c: Likewise.
3699 * kern/i386/realmode.S: Likewise.
3700 * kern/i386/tsc.c: Likewise.
3701 * kern/partition.c: Likewise.
3702 * kern/corecmd.c: Likewise.
3703 * kern/file.c: Likewise.
3704 * kern/efi/efi.c: Likewise.
3705 * kern/efi/init.c: Likewise.
3706 * kern/efi/mm.c: Likewise.
3707 * kern/main.c: Likewise.
3708 * kern/err.c: Likewise.
3709 * kern/env.c: Likewise.
3710 * kern/disk.c: Likewise.
3711 * kern/generic/millisleep.c: Likewise.
3712 * kern/generic/rtc_get_time_ms.c: Likewise.
3713 * kern/misc.c: Likewise.
3714 * kern/parser.c: Likewise.
3715 * genmk.rb: Likewise.
3716 * configure.ac: Likewise.
3717 * boot/i386/pc/diskboot.S: Likewise.
3718 * boot/i386/pc/pxeboot.S: Likewise.
3719 * boot/i386/pc/boot.S: Likewise.
3720 * boot/i386/pc/lnxboot.S: Likewise.
3721 * boot/i386/pc/cdboot.S: Likewise.
3722 * parttool/pcpart.c: Likewise.
3723 * video/readers/tga.c: Likewise.
3724 * video/video.c: Likewise.
3725 * video/bitmap.c: Likewise.
3726 * lib/envblk.c: Likewise.
3727 * lib/i386/setjmp.S: Likewise.
3728 * fs/xfs.c: Likewise.
3729 * fs/afs.c: Likewise.
3730 * fs/fat.c: Likewise.
3731 * fs/ntfs.c: Likewise.
3732 * fs/udf.c: Likewise.
3733 * fs/affs.c: Likewise.
3734 * fs/iso9660.c: Likewise.
3735 * fs/hfs.c: Likewise.
3736 * fs/fshelp.c: Likewise.
3737 * fs/ext2.c: Likewise.
3738 * fs/jfs.c: Likewise.
3739 * fs/reiserfs.c: Likewise.
3740 * fs/hfsplus.c: Likewise.
3741 * fs/minix.c: Likewise.
3742 * fs/cpio.c: Likewise.
3743 * fs/sfs.c: Likewise.
3744 * fs/ufs.c: Likewise.
3745 * efiemu/prepare.c: Likewise.
3746 * efiemu/loadcore_common.c: Likewise.
3747 * efiemu/runtime/efiemu.sh: Likewise.
3748 * efiemu/runtime/efiemu.S: Likewise.
3749 * efiemu/runtime/efiemu.c: Likewise.
3750 * efiemu/pnvram.c: Likewise.
3751 * efiemu/main.c: Likewise.
3752 * efiemu/i386/pc/cfgtables.c: Likewise.
3753 * efiemu/i386/loadcore64.c: Likewise.
3754 * efiemu/i386/loadcore32.c: Likewise.
3755 * efiemu/loadcore.c: Likewise.
3756 * efiemu/symbols.c: Likewise.
3757 * efiemu/mm.c: Likewise.
3758 * include/grub/autoefi.h: Likewise.
3759 * include/grub/datetime.h: Likewise.
3760 * include/grub/term.h: Likewise.
3761 * include/grub/hfs.h: Likewise.
3762 * include/grub/lvm.h: Likewise.
3763 * include/grub/i386/tsc.h: Likewise.
3764 * include/grub/i386/linux.h: Likewise.
3765 * include/grub/i386/xnu.h: Likewise.
3766 * include/grub/i386/efiemu.h: Likewise.
3767 * include/grub/i386/pc/biosdisk.h: Likewise.
3768 * include/grub/i386/pc/memory.h: Likewise.
3769 * include/grub/i386/pc/vbe.h: Likewise.
3770 * include/grub/parttool.h: Likewise.
3771 * include/grub/video.h: Likewise.
3772 * include/grub/memory.h: Likewise.
3773 * include/grub/fs.h: Likewise.
3774 * include/grub/partition.h: Likewise.
3775 * include/grub/xnu.h: Likewise.
3776 * include/grub/efi/api.h: Likewise.
3777 * include/grub/efi/pe32.h: Likewise.
3778 * include/grub/efi/memory.h: Likewise.
3779 * include/grub/multiboot.h: Likewise.
3780 * include/grub/usbdesc.h: Likewise.
3781 * include/grub/multiboot2.h: Likewise.
3782 * include/grub/acpi.h: Likewise.
3783 * include/grub/efiemu/efiemu.h: Likewise.
3784 * include/grub/disk.h: Likewise.
3785 * include/grub/ieee1275/ieee1275.h: Likewise.
3786 * include/grub/net.h: Likewise.
3787 * include/grub/machoload.h: Likewise.
3788 * include/grub/macho.h: Likewise.
3789 * include/multiboot.h: Likewise.
3790 * genmoddep.awk: Likewise.
3791 * normal/main.c: Likewise.
3792 * normal/menu_entry.c: Likewise.
3793 * normal/menu_viewer.c: Likewise.
3794 * normal/completion.c: Likewise.
3795 * normal/cmdline.c: Likewise.
3796 * normal/misc.c: Likewise.
3797 * normal/datetime.c: Likewise.
3798 * bus/usb/usbtrans.c: Likewise.
3799 * bus/usb/ohci.c: Likewise.
3800 * bus/usb/uhci.c: Likewise.
3801 * bus/usb/usb.c: Likewise.
3802 * mmap/efi/mmap.c: Likewise.
3803 * mmap/i386/pc/mmap_helper.S: Likewise.
3804 * mmap/i386/pc/mmap.c: Likewise.
3805 * mmap/i386/mmap.c: Likewise.
3806 * mmap/i386/uppermem.c: Likewise.
3807 * mmap/mmap.c: Likewise.
3808 * commands/acpi.c: Likewise.
3809 * commands/echo.c: Likewise.
3810 * commands/blocklist.c: Likewise.
3811 * commands/loadenv.c: Likewise.
3812 * commands/usbtest.c: Likewise.
3813 * commands/boot.c: Likewise.
3814 * commands/parttool.c: Likewise.
3815 * commands/search.c: Likewise.
3816 * commands/cat.c: Likewise.
3817 * commands/i386/pc/play.c: Likewise.
3818 * commands/i386/pc/drivemap.c: Likewise.
3819 * commands/i386/pc/vbeinfo.c: Likewise.
3820 * commands/i386/pc/acpi.c: Likewise.
3821 * commands/i386/pc/vbetest.c: Likewise.
3822 * commands/ls.c: Likewise.
3823 * commands/cmp.c: Likewise.
3824 * commands/test.c: Likewise.
3825 * commands/efi/acpi.c: Likewise.
3826 * commands/gptsync.c: Likewise.
3827 * commands/help.c: Likewise.
3828 * partmap/amiga.c: Likewise.
3829 * partmap/apple.c: Likewise.
3830 * partmap/acorn.c: Likewise.
3831 * partmap/pc.c: Likewise.
3832 * partmap/sun.c: Likewise.
3833 * partmap/gpt.c: Likewise.
3834 * script/sh/lexer.c: Likewise.
3835 * script/sh/function.c: Likewise.
3836 * font/font.c: Likewise.
3837 * font/font_cmd.c: Likewise.
3838 * loader/powerpc/ieee1275/linux.c: Likewise.
3839 * loader/efi/chainloader.c: Likewise.
3840 * loader/multiboot_loader.c: Likewise.
3841 * loader/macho.c: Likewise.
3842 * loader/i386/multiboot.c: Likewise.
3843 * loader/i386/linux.c: Likewise.
3844 * loader/i386/pc/linux.c: Likewise.
3845 * loader/i386/pc/multiboot2.c: Likewise.
3846 * loader/i386/pc/chainloader.c: Likewise.
3847 * loader/i386/pc/xnu.c: Likewise.
3848 * loader/i386/bsd_trampoline.S: Likewise.
3849 * loader/i386/efi/linux.c: Likewise.
3850 * loader/i386/multiboot_elfxx.c: Likewise.
3851 * loader/i386/bsd_helper.S: Likewise.
3852 * loader/i386/bsd.c: Likewise.
3853 * loader/i386/linux_trampoline.S: Likewise.
3854 * loader/i386/xnu_helper.S: Likewise.
3855 * loader/i386/xnu.c: Likewise.
3856 * loader/i386/bsd_pagetable.c: Likewise.
3857 * loader/i386/multiboot_helper.S: Likewise.
3858 * loader/xnu.c: Likewise.
3859 * loader/xnu_resume.c: Likewise.
3860 * io/gzio.c: Likewise.
3861 * term/efi/console.c: Likewise.
3862 * term/terminfo.c: Likewise.
3863 * term/ieee1275/ofconsole.c: Likewise.
3864 * term/i386/pc/serial.c: Likewise.
3865 * term/i386/pc/vesafb.c: Likewise.
3866 * term/i386/pc/vga.c: Likewise.
3867 * term/usb_keyboard.c: Likewise.
3868 * term/gfxterm.c: Likewise.
3869 * aclocal.m4: Likewise.
3870 * util/lvm.c: Likewise.
3871 * util/grub.d/30_os-prober.in: Likewise.
3872 * util/grub.d/10_hurd.in: Likewise.
3873 * util/console.c: Likewise.
3874 * util/grub-macho2img.c: Likewise.
3875 * util/grub-probe.c: Likewise.
3876 * util/hostfs.c: Likewise.
3877 * util/i386/pc/grub-mkimage.c: Likewise.
3878 * util/i386/pc/grub-setup.c: Likewise.
3879 * util/i386/efi/grub-mkimage.c: Likewise.
3880 * util/grub-mkconfig.in: Likewise.
3881 * util/raid.c: Likewise.
3882 * util/resolve.c: Likewise.
3883 * util/grub-mkdevicemap.c: Likewise.
3884 * util/grub-emu.c: Likewise.
3885 * util/getroot.c: Likewise.
3886 * util/hostdisk.c: Likewise.
3887 * util/usb.c: Likewise.
3888 * util/grub-editenv.c: Likewise.
3889 * util/misc.c: Likewise.
3890
d2d49665 38912009-06-10 Felix Zielcke <fzielcke@z-51.de>
3892
3893 * gendistlist.sh (EXTRA_DISTFILES): Add `genhandlerlist.sh' and
3894 `genparttoollist.sh'.
3895 (DISTDIRS): Add `efiemu', `mmap', `parttool' and `script'.
3896 Add `*.sh' to the list find searches for and change `mdate.sh'
3897 to `mdate-sh'.
3898
fe052e37 38992009-06-10 Pavel Roskin <proski@gnu.org>
3900
2763ac18 3901 * include/grub/multiboot2.h: Provide compatibility defines for
3902 multiboot2.h.
3903 * include/multiboot2.h: Include stdint.h only if needed, using
3904 angle brackets.
3905 * loader/i386/pc/multiboot2.c: Include multiboot2.h after
3906 grub/multiboot2.h.
3907 * loader/ieee1275/multiboot2.c: Likewise.
3908 * loader/multiboot2.c: Likewise.
3909 * loader/multiboot_loader.c: Likewise.
3910
437e6adc 3911 * configure.ac: Use -nostdlib when probing for the target. It
3912 should not be required to have libc for the target.
3913
06a6836c 3914 * configure.ac: Remove checks for __bswapsi2 and __bswapdi2,
3915 they fail without libc headers for the target.
3916 * include/grub/powerpc/libgcc.h: Use weak attribute for all
3917 exports.
3918 * include/grub/sparc64/libgcc.h: Likewise. Don't use
3919 preprocessor conditionals.
3920
fe052e37 3921 * conf/common.rmk: Compile tar.mod from tar.c, not cpio.c. The
3922 build system doesn't need to be aware of the tar.c internals.
3923
afd22553 39242009-06-09 Michel Hermier <michel.hermier@gmail.com>
87b8f28c 3925
afd22553 3926 * fs/i386/pc/pxe.c (grub_pxefs_read): Fix returned values.
8ec4a6d0 3927
6b787c4f 39282009-06-09 Robert Millan <rmh.grub@aybabtu.com>
3929
3930 * util/deviceiter.c (grub_util_iterate_devices): Increase number of
3931 disk limit to 26 for IDE, Virtio, Xen and SCSI.
3932
39332009-06-09 Felix Zielcke <fzielcke@z-51.de>
3934
3935 * util/i386/pc/grub-install.in: Change the error message if UUIDs
473d1e45 3936 aren't available if ata.mod gets used.
6b787c4f 3937
473d1e45 39382009-06-09 Oliver Henshaw <oliver.henshaw@gmail.com>
e23721e8 3939
473d1e45 3940 * bus/usb/ohci.c (grub_ohci_pci_iter): Link struct only after
e23721e8 3941 initialising controller.
473d1e45 3942 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
e23721e8 3943
255a27d4 39442009-06-08 Felix Zielcke <fzielcke@z-51.de>
3945
3946 * util/i386/pc/grub-install.in: Add a parameter --disk-module
3947 to choose between ata and biosdisk module on i386-pc.
3948
473d1e45 39492009-06-08 Oliver Henshaw <oliver.henshaw@gmail.com>
69da8877 3950
d55842d8 3951 * bus/usb/ohci.c (grub_ohci_pci_iter): Define the Class,
3952 Subclass and Programming Interface fields in terms of the 3 byte
3953 Class Code register.
3954 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
3955
fa5db0b1 3956 * bus/usb/ohci.c (grub_ohci_pci_iter): Check that programming
3957 interface is OHCI. Add grub_dprintf for symmetry with
3958 bus/usb/uhci.c.
3959 * bus/usb/uhci.c (grub_uhci_pci_iter): Check that programming
3960 interface is UHCI. Add interf variable for programming
3961 interface. Print interface with class/subclass.
3962
c0947beb 3963 * bus/usb/ohci.c: Set interf with correct field.
3964
69da8877 3965 * bus/usb/uhci.c: Remove unneeded doubled lines.
3966 * bus/usb/ohci.c: Likewise. Change interf to grub_uint32_t.
3967 Remove whitespace inside comment.
3968
9e172e30 39692009-06-08 Robert Millan <rmh.grub@aybabtu.com>
3970
3971 * loader/i386/linux.c (grub_cmd_linux): When processing `vga=', use
3972 as fallback an equivalent option without depth.
3973
de65ee2b 39742009-06-08 Vladimir Serbinenko <phcoder@gmail.com>
3975
3976 Not fail if unable to retrieve C/H/S on LBA disks
3977
473d1e45 3978 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): behave gracefully
de65ee2b 3979 if unable to retrieve C/H/S on LBA disks
3980
b57ea2c9 39812009-06-08 Pavel Roskin <proski@gnu.org>
3982
3983 * fs/hfs.c (grub_hfs_find_dir): Use union to avoid a warning
3984 about aliasing.
3985
af361263 39862009-06-08 Felix Zielcke <fzielcke@z-51.de>
3987
3988 * Makefile.in (uninstall): Remove all $lib_DATA files.
3989
4c9ec6b3 39902009-06-08 Vladimir Serbinenko <phcoder@gmail.com>
3991
3992 Bugfix: install on partitionless device
3993
3994 * util/hostdisk.c (grub_util_biosdisk_get_grub_dev): check if os_dev
3995 is a whole disk
3996
e76fc924 39972009-06-08 Felix Zielcke <fzielcke@z-51.de>
3998
3999 * Makefile.in (uninstall): Remove all $include_DATA files.
4000
ba5a0d05 40012009-06-08 Felix Zielcke <fzielcke@z-51.de>
4002
4003 * commands/true.c: New file. Implement the true and false commands.
4004 * conf/common.rmk.c (pkglib_MODULES): Add `true.mod'.
4005 (true_mod_SOURCES): New variable.
4006 (true_mod_CFLAGS): Likewise.
4007 (true_mod_LDFLAGS): Likewise.
4008
c8048e32 40092009-06-05 Colin D Bennett <colin@gibibit.com>
4010
4011 Optimized font character lookup using binary search instead of linear
4012 search. Fonts now are required to have the character index ordered by
4013 code point.
4014
4015 * font/font.c (load_font_index): Verify that fonts have ordered
4016 character indices.
4017 (find_glyph): Use binary search instead of linear search to find a
4018 character in a font.
4019
408305be 40202009-06-05 Michael Scherer <misc@mandriva.org>
4021
4022 * fs/hfsplus.c (grub_hfsplus_mount): Determine if the filesystem
4023 uses case sensitive btree.
4024 (grub_hfsplus_iterate_dir): Use GRUB_FSHELP_CASE_INSENSITIVE
4025 only for case insensitive filesystems.
4026
8ee1e0d9 40272009-06-05 Vladimir Serbinenko <phcoder@gmail.com>
4028
4029 * conf/i386-pc.rmk (efiemu_mod_CFLAGS): remove -Werror -Wall
4030 * conf/common.rmk (search_mod_CFLAGS): likewise
4031
a9966eb1 40322009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4033
473d1e45 4034 * kern/i386/pc/startup.S [APPLE_CC]: block of nops to
a9966eb1 4035 compensate a compiler bug
4036
9e7100fb 40372009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4038
473d1e45 4039 * include/grub/term.h (GRUB_TERM_BACKSPACE): explicitly define as 8
9e7100fb 4040 instead of '\b'
473d1e45 4041
ede21d71 40422009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4043
4044 Definitions for creating asm symbols with Apple's CC
4045
4046 * include/grub/symbol.h [APPLE_CC] (FUNCTION): new macro
4047 [APPLE_CC] (VARIABLE): likewise
4048
9dbf7653 40492009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4050
4051 Disable lnxboot.img when compiled
4052 with Apple's CC
4053
4054 * conf/i386-pc.rmk (pkglib_IMAGES): remove lnxboot.img
4055 pkglib_IMAGES [! TARGET_APPLE_CC] (pkglib_IMAGES): add lnxboot.img
4056 * boot/i386/pc/lnxboot.S [APPLE_CC]: define an #error
4057 [! APPLE_CC] (CODE_LENG): skip
4058 [! APPLE_CC] (setup_sects): likewise
4059 [! APPLE_CC]: skip filling
473d1e45 4060
e93cdc3d 40612009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4062
4063 Address in trampolines based on 32-bit registers when compiled
4064 with Apple's CC
4065
473d1e45 4066 * loader/i386/xnu_helper.S [APPLE_CC]: use 32-bit registers
e93cdc3d 4067 for addresses
4068 * loader/i386/linux_trampoline.S [APPLE_CC]: likewise
4069
6c688477 40702009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4071
4072 Avoid aliases when compiling with Apple's CC for PCBIOS machine
4073
4074 * kern/misc.c [APPLE_CC] (memcpy): new function
4075 [APPLE_CC] (memmove): likewise
4076 [APPLE_CC && !GRUB_UTIL] (grub_err_printf): likewise
473d1e45 4077 (memcpy): define alias conditionally on !APPLE_CC
6c688477 4078 (memset): likewise
4079 (abort): likewise
4080 * include/grub/misc.h (memove): don't define when both GRUB_UTIL and
4081 APPLE_CC are defined
4082 * include/grub/list.h [APPLE_CC] (grub_assert_fail): new function
4083 (grub_assert_fail): make prototype conditional
4084
e37ffc5c 40852009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4086
4087 Use grub-macho2img when compiling with Apple's CC for PCBIOS machine
4088
473d1e45 4089 * conf/common.rmk (bin_UTILITIES): add (on false on condition)
4090 grub-macho2img
e37ffc5c 4091 (CLEANFILES): add grub-macho2img
4092 (grub_macho2img_SOURCES): new variable
4093 * kern/i386/pc/startup.S (bss_start): new variable
4094 (bss_end): likewise
4095 * genmk.rb: use grub-macho2img for *.img when compiled with Apple's CC
4096 * util/grub-macho2img.c: new file
4097
cf00df31 40982009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4099
4100 Use objconv when compiling with Apple's CC
4101
4102 * conf/i386-pc.rmk (efiemu32.o): use OBJCONV if defined
4103 (efiemu64.o): likewise
4104 (efiemu64_c.o): omit -mcmodel=large and add -DAPPLE_CC=1
4105 when compiling with Apple's CC
4106 (efiemu64_s.o): likewise
4107 * configure.ac: check for objconv when compiling with Apple's CC
4108 * genmk.rb: use objconv for modules when compiled with Apple's CC
473d1e45 4109
d119a20c 41102009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4111
4112 Define segment as well as section when compiling with
4113 Apple's CC
4114
4115 * efiemu/runtime/efiemu.c (PHYSICAL_ATTRIBUTE): new definition
4116 (efiemu_set_virtual_address_map): declare with PHYSICAL_ATTRIBUTE
4117 (efiemu_convert_pointer): likewise
4118 (efiemu_set_virtual_address_map): likewise
4119 (efiemu_convert_pointer): likewise
4120 (efiemu_getcrc32): likewise
4121 (init_crc32_table): likewise
4122 (reflect): likewise
4123 * include/grub/dl.h (GRUB_MOD_NAME): define segment with Apple's CC
4124 (GRUB_MOD_DEP): likewise
473d1e45 4125
c8600122 41262009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4127
4128 Allow a compilation without -mcmodel=large
4129
4130 * kern/efi/mm.c (grub_efi_allocate_pages): don't allocate >4GiB
4131 when compiled without -mcmodel=large
473d1e45 4132 (filter_memory_map): remove memory post 4 GiB when compiled
c8600122 4133 without -mcmodel=large
473d1e45 4134 * configure.ac: fail gracefully and add -DMCMODEL_SMALL=1 to
c8600122 4135 TARGET_CFLAGS when -mcmodel=large isn't supported
473d1e45 4136
e8df1d4e 41372009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4138
4139 Remove nested functions in efiemu core
4140
4141 * efiemu/runtime/efiemu.c (reflect): make static instead of nested
473d1e45 4142
cc6c3ac1 41432009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4144
4145 Avoid clobbering %ebx/%rbx in inline assembly with Apple's CC
4146
4147 * efiemu/runtime/efiemu.c (write_cmos): use %cl instead of %bl as
4148 temporary storage
473d1e45 4149 * include/grub/i386/tsc.h (grub_get_tsc): restore %rbx/%ebx when
4150 using Apple's CC
cc6c3ac1 4151 (grub_cpu_is_tsc_supported): likewise
4152 * loader/i386/xnu.c (guessfsb): restore %rbx/%ebx in inline assembly
473d1e45 4153
3e325901 41542009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4155
4156 Absolute addressing through constant with Apple's cc
4157
4158 * kern/i386/pc/startup.S: Define necessary constants
4159 and address through it when using ABS with Apple's CC
4160 * boot/i386/pc/diskboot.S: likewise
4161 * boot/i386/pc/boot.S: likewise
4162 * boot/i386/pc/lnxboot.S: likewise
4163 * boot/i386/pc/cdboot.S: likewise
4164 * mmap/i386/pc/mmap_helper.S: likewise
4165 * commands/i386/pc/drivemap_int13h.S: likewise
4166
2b167a72 41672009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4168
4169 Check if compiler is apple cc
4170
4171 * Makefile.in (ASFLAGS): new variable
4172 (TARGET_ASFLAGS): likewise
4173 (TARGET_MODULE_FORMAT): likewise
4174 (TARGET_APPLE_CC): likewise
4175 (OBJCONV): likewise
4176 (TARGET_IMG_CFLAGS): likewise
4177 (TARGET_CPPFLAGS): add includedir
4178 * configure.ac: call grub_apple_cc and grub_apple_target_cc
4179 (TARGET_IMG_LDFLAGS): Add -Wl,-Ttext,. All users updated
4180 Check for linker script only if compiler isn't Apple's CC
4181 (TARGET_MODULE_FORMAT): set
4182 (TARGET_APPLE_CC): likewise
4183 (TARGET_ASFLAGS): likewise
4184 (ASFLAGS): likewise
4185 Check for objcopy only if compiler isn't Apple's CC
4186 Check for BSS symbol only if compiler isn't Apple's CC
4187 * genmk.rb: adapt nm options if we use Apple's utils
4188 * aclocal.m4 (grub_apple_cc): new test
4189 (grub_apple_target_cc): likewise
473d1e45 4190
fb14123e 41912009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4192
4193 Simplify sed expressions and improve awk
4194
4195 * Makefile.in (install-local): simplify sed expression
4196 * gencmdlist.sh: likewise
4197 * genmoddep.awk: avoid adding module as a dependency of itself
4198
5b889789 41992009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4200
4201 Add missing start symbols
4202
4203 * boot/i386/pc/boot.S: add start
fb14123e 4204 * boot/i386/pc/pxeboot.S: likewise
473d1e45 4205
fd2bf2e3 42062009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4207
4208 Fix wrong assumptions with grub-mkimage on EFI
473d1e45 4209
4210 * i386/efi/grub-mkimage.c (read_kernel_module): don't write prefix here
fd2bf2e3 4211 (relocate_addresses): consider both r_addend and value at offset
4212 (make_mods_section): zerofill modinfo and header
4213 (convert_elf): write prefix here
473d1e45 4214
5389763d 42152009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4216
4217 Use .asciz instead of .string
4218
4219 * i386/pc/diskboot.S: use .asciz instead of .string
4220 * i386/pc/boot.S: likewise
4221 * include/grub/dl.h (GRUB_MOD_DEP): likewise
4222 (GRUB_MOD_NAME): likewise
473d1e45 4223
3eb5ed4e 42242009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4225
4226 gfxpayload support
4227
4228 * commands/videotest.c (grub_cmd_videotest): use grub_video_set_mode
4229 * include/grub/video.h (GRUB_VIDEO_MODE_TYPE_PURE_TEXT): new definition
4230 (grub_video_setup): remove
4231 (grub_video_set_mode): new prototype
4232 * loader/i386/linux.c (DEFAULT_VIDEO_MODE): new definition
4233 (vid_mode): remove
4234 (linux_vesafb_res): compile only on PCBIOS
4235 (grub_linux_boot): support gfxpayload
4236 * loader/i386/pc/xnu.c (video_hook): new function
4237 (grub_xnu_set_video): support gfxpayload
4238 * term/gfxterm.c (DEFAULT_VIDEO_WIDTH): removed
4239 (DEFAULT_VIDEO_HEIGHT): likewise
4240 (DEFAULT_VIDEO_FLAGS): likewise
4241 (DEFAULT_VIDEO_MODE): new definition
4242 (video_hook): new function
4243 (grub_gfxterm_init): use grub_video_set_mode
473d1e45 4244 * util/grub.d/30_os-prober.in: remove explicit modesetting before
3eb5ed4e 4245 loading xnu
4246 * video/video.c (grub_video_setup): removed
473d1e45 4247 (grub_video_set_mode): new function based on grub_gfxterm_init and
3eb5ed4e 4248 grub_video_setup
4249
4b0e1143 42502009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4251
4252 Avoid calling biosdisk in drivemap
4253
4254 * commands/i386/pc/drivemap.c (parse_biosdisk): remove
4255 (revparse_biosdisk): likewise
4256 (list_mappings): derive name from id directly
4257 (grub_cmd_drivemap): use tryparse_diskstring
473d1e45 4258
fda6cb98 42592009-06-04 Vladimir Serbinenko <phcoder@gmail.com>
4260
4261 Script fixes
4262
4263 * include/grub/script_sh.h (grub_script_cmdline): remove cmdline
4264 (grub_lexer_param): add tokenonhold
4265 (grub_script_create_cmdline): remove cmdline. All callers updated
4266 (grub_script_function_create): make functionname
4267 grub_script_arg. All callers updated
4268 (grub_script_execute_argument_to_string): new prototype
4269 * kern/parser.c (state_transitions): reorder
4270 (grub_parser_cmdline_state): fix a bug and make more compact
473d1e45 4271 * script/sh/execute.c (grub_script_execute_argument_to_string):
fda6cb98 4272 make global
4273 (grub_script_execute_cmdline): use new format
4274 * script/sh/function.c (grub_script_function_create): make functionname
4275 grub_script_arg. All callers updated
473d1e45 4276 * script/sh/lexer.c (grub_script_lexer_init): initialize tokenonhold
fda6cb98 4277 (grub_script_yylex): remove
4278 (grub_script_yylex2): renamed to ...
4279 (grub_script_yylex): ...renamed
4280 parse the expressions like a${b}c
4281 * script/sh/parser.y (GRUB_PARSER_TOKEN_ARG): new typed terminal
4282 (GRUB_PARSER_TOKEN_VAR): remove
4283 (GRUB_PARSER_TOKEN_NAME): likewise
4284 ("if"): declare as typeless
4285 ("while"): likewise
4286 ("function"): likewise
4287 ("else"): likewise
4288 ("then"): likewise
4289 ("fi"): likewise
4290 (text): remove
4291 (argument): likewise
4292 (script): accept empty scripts and make exit on error
4293 (arguments): use GRUB_PARSER_TOKEN_ARG
4294 (function): likewise
4295 (command): move error handling to script
4296 (menuentry): move grub_script_lexer_ref before
473d1e45 4297 * script/sh/script.c (grub_script_create_cmdline): remove cmdline
fda6cb98 4298 argument. All callers updated
4299
f4448a07 43002009-06-04 Robert Millan <rmh.grub@aybabtu.com>
4301
4302 Prevent GRUB from probing floppies during boot.
4303
4304 * conf/common.rmk (search_mod_CFLAGS): Use `-Werror -Wall'.
4305 * commands/search.c (options): Add --no-floppy.
4306 (search_fs, search_file, grub_cmd_search): Support --no-floppy.
4307 * util/grub-mkconfig_lib.in (prepare_grub_to_access_device): Use
4308 --no-floppy when searching for UUIDs.
4309
2bf5885a 43102009-06-04 Robert Millan <rmh.grub@aybabtu.com>
4311
4312 Simplify the code duplication in commands/search.c.
4313
4314 * commands/search.c (search_label, search_fs_uuid): Merge into ...
4315 (search_fs): ... this. Update all users.
4316
f6fd460a 43172009-06-03 Felix Zielcke <fzielcke@z-51.de>
4318
4319 * util/grub-mkconfig.in (update_grub_dir): Rename to grub_mkconfig_dir.
4320
cbb3c83e 43212009-05-28 Pavel Roskin <proski@gnu.org>
4322
57788cfd 4323 * Makefile.in: Don't use "cp -d", it doesn't work on FreeBSD.
4324 Remove the original symlink explicitly.
4325
cbb3c83e 4326 * fs/hfs.c (grub_hfs_find_dir): Skip sequences of slashes, not
4327 just one slash. That's how grub_fshelp_find_file() does it.
4328
cd0d5e30 43292009-05-26 Pavel Roskin <proski@gnu.org>
4330
f0f8bbe2 4331 * genmk.rb: Avoid shadowing variable `s', rename the outer `s'
4332 to `str'.
4333
cd0d5e30 4334 * util/getroot.c (grub_util_get_dev_abstraction): Mark os_dev as
4335 possibly unused.
4336
8c2cab51 43372009-05-25 Christian Franke <franke@computer.org>
4338
4339 * disk/ata.c (grub_ata_wait_not_busy): Add debug output of status
4340 register.
4341 (grub_atapi_identify): Add wait after drive select.
4342 (grub_ata_identify): Do more strict status register check before
4343 calling grub_atapi_identify (). Suppress error message if status
4344 register is 0x00 after command failure. Add status register
4345 check after PIO read to avoid bogus identify due to stuck DRQ.
4346 Thanks to Pavel Roskin for testing.
4347 (grub_device_initialize): Remove unsafe status register check.
4348 Thanks to 'phcoder' for problem report and patch.
4349 Prevent sign extension in debug message.
4350
230c0ad6 43512009-05-23 Colin D Bennett <colin@gibibit.com>
4352
4353 Cleaned up `include/grub/normal.h'. Grouped prototypes by
4354 definition file, and functions defined in `normal/menu.c' have had
4355 their prototypes moved to `include/grub/menu.h' for consistency.
4356
4357 * include/grub/menu.h (grub_menu_execute_callback): Added; moved
4358 from normal.h.
4359 (grub_menu_get_entry): Likewise.
4360 (grub_menu_get_timeout): Likewise.
4361 (grub_menu_set_timeout): Likewise.
4362 (grub_menu_execute_entry): Likewise.
4363 (grub_menu_execute_with_fallback): Likewise.
4364 (grub_menu_entry_run): Likewise.
4365
4366 * include/grub/normal.h: Re-ordered and grouped function
4367 prototypes by file that the function is defined in.
4368 (grub_menu_execute_callback): Removed; moved to menu.h.
4369 (grub_menu_get_entry): Likewise.
4370 (grub_menu_get_timeout): Likewise.
4371 (grub_menu_set_timeout): Likewise.
4372 (grub_menu_execute_entry): Likewise.
4373 (grub_menu_execute_with_fallback): Likewise.
4374 (grub_menu_entry_run): Likewise.
4375 (grub_menu_addentry): Renamed from this ...
4376 (grub_normal_add_menu_entry): ... to this.
4377
4378 * normal/main.c (grub_menu_addentry): Renamed from this ...
4379 (grub_normal_add_menu_entry): ... to this.
4380
4381 * script/sh/execute.c (grub_script_execute_menuentry): Update
4382 reference to renamed grub_menu_addentry function.
4383
861f03a5 43842009-05-23 Felix Zielcke <fzielcke@z-51.de>
4385
4386 * commands/i386/pc/drivemap.c (MODNAME): Remove. Update all users.
4387
96b1619a 43882009-05-22 Pavel Roskin <proski@gnu.org>
4389
bf6a5fb2 4390 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Remove.
4391 * configure.ac: Don't call grub_I386_CHECK_REGPARM_BUG. Define
4392 NESTED_FUNC_ATTR using AH_BOTTOM. Use regparm(1) only when
4393 compiling for the i386 targets, but not for the utilities.
4394
96b1619a 4395 * include/grub/i386/pc/kernel.h (grub_boot_drive): Change type
4396 to grub_uint8_t.
4397 (grub_root_drive): Likewise.
4398 * kern/i386/pc/startup.S (grub_boot_drive): Change size to byte,
4399 remove alignment.
4400 (grub_root_drive): Change size to byte.
4401 (grub_start_addr): Remove.
4402 (grub_end_addr): Likewise.
4403 (grub_apm_bios_info): Likewise.
4404
b729776b 44052009-05-21 Felix Zielcke <fzielcke@z-51.de>
4406
4407 * normal/i386: Remove.
4408 * normal/powerpc: Likewise.
4409 * normal/sparc64: Likewise.
4410 * normal/x86_64: Likewise.
4411
0a15ce80 44122009-05-19 Vladimir Serbinenko <phcoder@gmail.com>
4413
4414 * conf/x86_64-efi.rmk (linux_mod_ASFLAGS): Add missing variable
473d1e45 4415 * loader/i386/linux_trampoline.S: Fix indentation
0a15ce80 4416 * loader/i386/xnu_helper.S: Likewise
d6da58e6 4417
33db9015 44182009-05-18 Colin D Bennett <colin@gibibit.com>
4419
d6da58e6 4420 Display error messages when parsing a Lua statement fails.
4421 Previously, executing a syntactically invalid statement like
4422 ")foo" or "bar;" would silently fail.
33db9015 4423
4424 * script/lua/grub_main.c (handle_lua_error): New function.
d6da58e6 4425 (grub_lua_parse_line): Improved reporting of Lua parser and
4426 execution errors.
33db9015 4427
46422c89 44282009-05-17 Vladimir Serbinenko <phcoder@gmail.com>
4429
4430 Remove -Werror which causes build to fail on some systems
4431
4432 * conf/i386-pc.rmk (xnu_mod_CFLAGS): Remove -Werror -Wall
4433 * conf/i386-efi.rmk (xnu_mod_CFLAGS): Likewise
4434 * conf/x86_64-efi.rmk (xnu_mod_CFLAGS): Likewise
18f547ad 4435
22f53a96 44362009-05-17 Vladimir Serbinenko <phcoder@gmail.com>
4437
4438 trampoline for linux on 64-bit platform
4439
18f547ad 4440 * conf/x86_64-efi.rmk (linux_mod_SOURCES): added
4441 loader/i386/efi/linux_trampoline.S
4442 * include/grub/x86_64/efi/loader.h (grub_linux_real_boot): removed
473d1e45 4443 declaration
d6da58e6 4444 * kern/x86_64/efi/startup.S (grub_linux_real_boot): moved from
4445 here
22f53a96 4446 * loader/i386/linux_trampoline.S: moved here
d6da58e6 4447 * loader/i386/efi/linux.c (allocate_pages): reserve space for
4448 trampoline
22f53a96 4449 (jumpvector): removed
4450 (grub_linux_trampoline_start): new declaration
4451 (grub_linux_trampoline_end): likewise
4452 (grub_linux_boot): use trampoline when on 64-bit platform
4453 * loader/i386/linux.c: likewise
4454
cb5a0f40 44552009-05-16 Pavel Roskin <proski@gnu.org>
4456
4457 * script/lua/grub_lib.c (grub_lua_getenv): Make name and value
4458 const to avoid a warning.
4459 (grub_lua_setenv): Likewise.
4460 * script/lua/grub_main.c (grub_lua_parse_line): Use size_t for
4461 lmsg to fix a warning.
4462
334f2c28 44632009-05-16 Felix Zielcke <fzielcke@z-51.de>
4464
4465 * conf/i386.rmk (setjmp_mod_CFLAGS): Rename to ...
7dd10fce 4466 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
4467 * conf/x86_64-efi.rmk (setjmp_mod_CFLAGS): Rename to ...
4468 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
4469 * conf/powerpc-ieee1275.rmk (setjmp_mod_CFLAGS): Rename to ...
4470 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
4471 * conf/sparc64-ieee1275.rmk (setjmp_mod_CFLAGS): Rename to ...
4472 (setjmp_mod_ASFLAGS): ... this. Set to $(COMMON_ASFLAGS).
334f2c28 4473
59e5d3ec 44742009-05-16 Felix Zielcke <fzielcke@z-51.de>
4475
4476 * util/grub-mkconfig.in: Export GRUB_TERMINAL_INPUT.
4477
9d87a1ba 44782009-05-16 Bean <bean123ch@gmail.com>
4479
4480 * conf/common.rmk (pkglib_MODULES): Add lua.mod.
4481 (lua_mod_SOURCES): New variable.
4482 (lua_mod_CFLAGS): Likewise.
4483 (lua_mod_LDFLAGS): Likewise.
4484
4485 * conf/i386.rmk (pkglib_MODULES): Add setjmp.mod.
4486 (setjmp_mod_SOURCES): New variable.
4487 (setjmp_mod_CFLAGS): Likewise.
4488 (setjmp_LDFLAGS): Likewise.
4489
4490 * conf/x86_64-efi.rmk (pkglib_MODULES): Add setjmp.mod.
4491 (setjmp_mod_SOURCES): New variable.
4492 (setjmp_mod_CFLAGS): Likewise.
4493 (setjmp_LDFLAGS): Likewise.
4494
4495 * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add setjmp.mod.
4496 (setjmp_mod_SOURCES): New variable.
4497 (setjmp_mod_CFLAGS): Likewise.
4498 (setjmp_LDFLAGS): Likewise.
4499
4500 * conf/sparc64-ieee1275.rmk (pkglib_MODULES): Add setjmp.mod.
4501 (setjmp_mod_SOURCES): New variable.
4502 (setjmp_mod_CFLAGS): Likewise.
4503 (setjmp_LDFLAGS): Likewise.
4504
4505 * normal/i386/setjmp.S: Moved from here ...
4506 * lib/i386/setjmp.S: ... Moved here
4507 * normal/x86_64/setjmp.S: Moved from here ...
4508 * lib/x86_64/setjmp.S: ... Moved here
4509 * normal/powerpc/setjmp.S: Moved from here ...
4510 * lib/powerpc/setjmp.S: ... Moved here
4511 * normal/sparc64/setjmp.S: Moved from here ...
4512 * lib/sparc64/setjmp.S: ... Moved here
4513
4514 * include/grub/i386/setjmp.h (grub_setjmp): Don't use attribute
4515 returns_twice in mingw.
4516
4517 * script/lua/grub_lib.c: New file.
4518 * script/lua/grub_lib.h: Likewise.
4519 * script/lua/grub_lua.h: Likewise.
4520 * script/lua/grub_main.c: Likewise.
4521 * script/lua/lapi.c: Likewise.
4522 * script/lua/lapi.h: Likewise.
4523 * script/lua/lauxlib.c: Likewise.
4524 * script/lua/lauxlib.h: Likewise.
4525 * script/lua/lbaselib.c: Likewise.
4526 * script/lua/lcode.c: Likewise.
4527 * script/lua/lcode.h: Likewise.
4528 * script/lua/ldblib.c: Likewise.
4529 * script/lua/ldebug.c: Likewise.
4530 * script/lua/ldebug.h: Likewise.
4531 * script/lua/ldo.c: Likewise.
4532 * script/lua/ldo.h: Likewise.
4533 * script/lua/ldump.c: Likewise.
4534 * script/lua/lfunc.c: Likewise.
4535 * script/lua/lfunc.h: Likewise.
4536 * script/lua/lgc.c: Likewise.
4537 * script/lua/lgc.h: Likewise.
4538 * script/lua/linit.c: Likewise.
4539 * script/lua/liolib.c: Likewise.
4540 * script/lua/llex.c: Likewise.
4541 * script/lua/llex.h: Likewise.
4542 * script/lua/llimits.h: Likewise.
4543 * script/lua/lmathlib.c: Likewise.
4544 * script/lua/lmem.c: Likewise.
4545 * script/lua/lmem.h: Likewise.
4546 * script/lua/loadlib.c: Likewise.
4547 * script/lua/lobject.c: Likewise.
4548 * script/lua/lobject.h: Likewise.
4549 * script/lua/lopcodes.c: Likewise.
4550 * script/lua/lopcodes.h: Likewise.
4551 * script/lua/loslib.c: Likewise.
4552 * script/lua/lparser.c: Likewise.
4553 * script/lua/lparser.h: Likewise.
4554 * script/lua/lstate.c: Likewise.
4555 * script/lua/lstate.h: Likewise.
4556 * script/lua/lstring.c: Likewise.
4557 * script/lua/lstring.h: Likewise.
4558 * script/lua/lstrlib.c: Likewise.
4559 * script/lua/ltable.c: Likewise.
4560 * script/lua/ltable.h: Likewise.
4561 * script/lua/ltablib.c: Likewise.
4562 * script/lua/ltm.c: Likewise.
4563 * script/lua/ltm.h: Likewise.
4564 * script/lua/lua.h: Likewise.
4565 * script/lua/luaconf.h: Likewise.
4566 * script/lua/lualib.h: Likewise.
4567 * script/lua/lundump.c: Likewise.
4568 * script/lua/lundump.h: Likewise.
4569 * script/lua/lvm.c: Likewise.
4570 * script/lua/lvm.h: Likewise.
4571 * script/lua/lzio.c: Likewise.
4572 * script/lua/lzio.h: Likewise.
4573
5e898c9d 45742009-05-16 Bean <bean123ch@gmail.com>
4575
4576 * include/grub/kernel.h (grub_module_header_types): Add type
4577 OBJ_TYPE_CONFIG.
4578
4579 * kern/main.c (grub_load_config): New function.
4580 (grub_main): Call grub_load_config to read boot config.
4581
4582 * grub-mkimage (generate_image): New parameter config_path.
4583 (options): New option --config.
4584 (main): Parse --config option, and pass it to generate_image.
4585
cf353a47 45862009-05-14 Christian Franke <franke@computer.org>
4587
4588 * commands/i386/pc/drivemap_int13h.S: Add missing EXT_C for symbols.
4589 This fixes build on Cygwin.
4590
3834887f 45912009-05-14 Pavel Roskin <proski@gnu.org>
4592
4593 * commands/i386/pc/drivemap_int13h.S: Eliminate unconditional
4594 jump. This saves two bytes, so the typical case of 2 swapped
4595 drives would fit 32 bytes.
4596
8090fc01 45972009-05-13 Pavel Roskin <proski@gnu.org>
4598
ac963883 4599 * loader/i386/multiboot.c (grub_multiboot): Cast mmap_addr to
4600 grub_uint32_t to avoid a warning.
4601
8090fc01 4602 * loader/i386/linux.c (allocate_pages): When assigning
4603 real_mode_mem, cast through grub_size_t to fix a warning. The
4604 code already makes sure that the value would fit a pointer.
4605 (grub_linux_setup_video): Cast render_target->data to
4606 grub_size_t to fix a warning.
4607
18f547ad 46082009-05-13 Javier Martín <lordhabbit@gmail.com>
4246b8a9 4609
4610 * commands/i386/pc/drivemap.c: New file - implement drivemap
4611 command.
4612 * commands/i386/pc/drivemap_int13h.S: New file - int13 handler.
4613 * conf/i386-pc.rmk: Add drivemap.c and drivemap_int13h.S.
4614
6f6a8b28 46152009-05-13 Pavel Roskin <proski@gnu.org>
4616
4617 * util/i386/pc/grub-setup.c (setup): Remove unused variable
4618 embedding_area_exists.
4619
15fbf4c4 46202009-05-13 Robert Millan <rmh.grub@aybabtu.com>
4621
4622 * util/i386/pc/grub-setup.c (setup): Restructure code flow to make
4623 it easier to understand / work with.
59978c8a 4624 Improve warning messages for cases where there's no embedding area,
4625 or when it is too small (or core.img too large).
15fbf4c4 4626
238e871f 46272009-05-13 Pavel Roskin <proski@gnu.org>
4628
0ab3a9a4 4629 * loader/i386/pc/multiboot2.c: Add necessary includes for
4630 grub_multiboot2_real_boot().
4631
a2c8c5f8 4632 * fs/iso9660.c (grub_iso9660_iterate_dir): The file mode in the
4633 PX record is always little-endian. We only need the lower 2
4634 bytes of the mode.
4635
faec96af 4636 * fs/cpio.c: Use the same name "struct head" for tar and cpio to
4637 facilitate code reuse.
4638 (grub_cpio_mount): Use "struct head", not a char buffer. This
4639 fixes a warning reported by gcc 4.4.
4640
238e871f 4641 * kernel/disk.c (grub_disk_read): Use void pointer for the
4642 buffer.
4643 (grub_disk_write): Use const void pointer for the buffer.
4644 Adjust all callers. Remove unnecessary casts.
4645
901d2f0c 46462009-05-10 Robert Millan <rmh.grub@aybabtu.com>
4647
4648 * util/i386/pc/grub-install.in: Update copyright year.
4649
18f547ad 46502009-05-09 Vladimir Serbinenko <phcoder@gmail.com>
2eac4c16 4651
4652 gptsync
4653
4654 * commands/gptsync.c: new file
4655 * conf/common.rmk (pkglib_MODULES): add gptsync.mod
4656 (gptsync_mod_SOURCES): new variable
4657 (gptsync_mod_CFLAGS): likewise
4658 (gptsync_mod_LDFLAGS): likewise
18f547ad 4659 * include/grub/pc_partition.h (GRUB_PC_PARTITION_TYPE_NTFS):
2eac4c16 4660 new definition
4661 (GRUB_PC_PARTITION_TYPE_HFS): likewise
4662 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add commands/gptsync.c
4663 * conf/i386-ieee1275.rmk: likewise
4664 * conf/i386-pc.rmk: likewise
4665 * conf/powerpc-ieee1275.rmk: likewise
4666
b4ba690a 46672009-05-09 Vladimir Serbinenko <phcoder@gmail.com>
4668
4669 Fixed grub-emu
4670
4671 * kern/dl.c (grub_dl_ref): omit when compiling grub-emu
4672 (grub_dl_ref): likewise
4673
317e1a44 46742009-05-08 Robert Millan <rmh.grub@aybabtu.com>
4675
4676 * util/i386/pc/grub-setup.c (setup): Factorize find_usable_region(),
4677 split in two functions (one for msdos and one for gpt).
4678
041b8094 46792009-05-08 Pavel Roskin <proski@gnu.org>
4680
752473c2 4681 * disk/raid.c (grub_raid_block_xor): Make buf2 constant, it's
4682 not modified.
4683
041b8094 4684 * disk/raid6_recover.c (grub_raid6_recover): Fix warnings about
4685 uninitialized err[0] and err[1]. Rename them to bad1 and bad2.
4686 Initialize them with -1. Add sanity check for bad1. Eliminate
4687 nerr variable.
4688
172800ce 46892009-05-08 David S. Miller <davem@davemloft.net>
4690
4691 * util/sparc64/ieee1275/grub-ofpathname.c (main): Set progname.
4692
29aa5e81 46932009-05-06 Robert Millan <rmh.grub@aybabtu.com>
4694
4695 * util/i386/pc/grub-setup.c (setup): Fix check for embed region
473d1e45 4696 existence.
29aa5e81 4697
96613b62 46982009-05-05 Felix Zielcke <fzielcke@z-51.de>
4699
4700 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
1905c57b 4701 `kern/rescue_reader.c', `kern/rescue_parser.c' and `normal/autofs.c'.
96613b62 4702
eef73c8a 47032009-05-05 David S. Miller <davem@davemloft.net>
4704
4705 * util/sparc64/ieee1275/grub-install.in: Fix sed arg quoting.
4706
119494b5 47072009-05-05 Pavel Roskin <proski@gnu.org>
4708
4709 * include/grub/dl.h [GRUB_UTIL]: Provide inline implementations
4710 of grub_dl_ref() and grub_dl_unref().
4711 * commands/parttool.c: Remove preprocessor conditionals around
4712 grub_dl_ref() and grub_dl_unref().
4713 * fs/affs.c: Likewise.
4714 * fs/afs.c: Likewise.
4715 * fs/cpio.c: Likewise.
4716 * fs/ext2.c: Likewise.
4717 * fs/fat.c: Likewise.
4718 * fs/hfs.c: Likewise.
4719 * fs/hfsplus.c: Likewise.
4720 * fs/iso9660.c: Likewise.
4721 * fs/jfs.c: Likewise.
4722 * fs/minix.c: Likewise.
4723 * fs/ntfs.c: Likewise.
4724 * fs/reiserfs.c: Likewise.
4725 * fs/sfs.c: Likewise.
4726 * fs/udf.c: Likewise.
4727 * fs/ufs.c: Likewise.
4728 * fs/xfs.c: Likewise.
4729 * include/grub/dl.h: Likewise.
4730 * loader/xnu.c: Likewise.
4731
de5fd76e 47322009-05-04 Pavel Roskin <proski@gnu.org>
4733
4734 * commands/acpi.c: Remove unused variable my_mod.
4735 * partmap/amiga.c: Likewise.
4736 * partmap/apple.c: Likewise.
4737 * partmap/gpt.c: Likewise.
4738 * partmap/pc.c: Likewise.
4739 * partmap/sun.c: Likewise.
4740 * term/gfxterm.c: Likewise.
4741 * term/i386/pc/vesafb.c: Likewise.
4742 * term/i386/pc/vga.c: Likewise.
4743
983598ad 47442009-05-04 David S. Miller <davem@davemloft.net>
4745
4746 * kern/ieee1275/openfw.c (grub_children_iterate): Fix string
4747 pointer args to grub_ieee1275_get_property().
4748
8aadec43 4749 * conf/sparc64-ieee1275.rmk: Fix build due to missing '\'.
4750
9554b15e 4751 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Bypass cdrom
4752 devices, and do not traverse down under controller nodes.
4753
67e23c90 4754 * disk/ieee1275/ofdisk.c (compute_dev_path): New.
4755 (grub_ofdisk_open): Use it to un-escape "," characters.
4756 * kern/disk.c (find_part_sep): New.
4757 (grub_disk_open): Use it to find the first non-escaped ','
4758 character in the disk name.
4759 * util/ieee1275/devicemap.c (escape_of_path): New.
4760 (grub_util_emit_devicemap_entry): Use it.
4761 * util/sparc64/ieee1275/grub-install.in: Update script to
4762 strip partition specifiers properly by not triggering on
4763 '\' escaped ',' characters.
4764
74bfdd2f 47652009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4766
4767 * include/grub/i386/linux.h (GRUB_LINUX_VID_MODE_VESA_START): Set
4768 to 0x300.
4769 * loader/i386/linux.c (vga_modes, linux_vesafb_res): Add a few
4770 resolutions.
4771 (linux_vesafb_modes): Add a lot of additional modes to the list (based
4772 on documentation from Wikipedia).
4773
4241d2b1 47742009-05-04 Pavel Roskin <proski@gnu.org>
4775
4776 * disk/ata.c: Spelling fixes.
4777 * disk/raid.c: Likewise.
4778 * disk/usbms.c: Likewise.
4779 * disk/dmraid_nvidia.c: Likewise.
4780 * kern/ieee1275/openfw.c: Likewise.
4781 * kern/ieee1275/init.c: Likewise.
4782 * kern/ieee1275/cmain.c: Likewise.
4783 * boot/i386/pc/cdboot.S: Likewise.
4784 * video/readers/png.c: Likewise.
4785 * video/i386/pc/vbe.c: Likewise.
4786 * fs/udf.c: Likewise.
4787 * fs/hfs.c: Likewise.
4788 * fs/reiserfs.c: Likewise.
4789 * efiemu/runtime/efiemu.c: Likewise.
4790 * efiemu/main.c: Likewise.
4791 * efiemu/mm.c: Likewise.
4792 * include/grub/elf.h: Likewise.
4793 * include/grub/xnu.h: Likewise.
4794 * include/grub/usbdesc.h: Likewise.
4795 * include/grub/usb.h: Likewise.
4796 * include/grub/script_sh.h: Likewise.
4797 * include/grub/lib/LzmaEnc.h: Likewise.
4798 * include/grub/efiemu/efiemu.h: Likewise.
4799 * include/grub/command.h: Likewise.
4800 * normal/menu.c: Likewise.
4801 * normal/main.c: Likewise.
4802 * normal/datetime.c: Likewise.
4803 * bus/usb/uhci.c: Likewise.
4804 * mmap/i386/uppermem.c: Likewise.
4805 * mmap/mmap.c: Likewise.
4806 * commands/acpi.c: Likewise.
4807 * commands/test.c: Likewise.
4808 * partmap/apple.c: Likewise.
4809 * font/font.c: Likewise.
4810 * loader/sparc64/ieee1275/linux.c: Likewise.
4811 * loader/macho.c: Likewise.
4812 * loader/i386/bsd_trampoline.S: Likewise.
4813 * loader/i386/bsd.c: Likewise.
4814 * loader/xnu.c: Likewise.
4815 * term/i386/pc/vesafb.c: Likewise.
4816 * term/usb_keyboard.c: Likewise.
4817 * util/resolve.c: Likewise.
4818 * util/getroot.c: Likewise.
4819
0cfc0083 48202009-05-04 Felix Zielcke <fzielcke@z-51.de>
4821
4822 * conf/i386-pc.rmk (libpkg_DATA): Rename to pkglib_DATA.
4823
7c1d00cd 48242009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4825
4826 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS] (grub_cmd_linux): Fix
4827 build error.
4828
b01f0548 48292009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4830
4831 * loader/i386/linux.c (grub_cmd_linux): Make "vga=" compatibility
4832 parameter only available on BIOS.
4833
ecc3eb22 48342009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
4835
4836 Removed wrong semicolon in declaration
4837
4838 * grub/misc.h (grub_dprintf): remove semicolon
4839
112972a9 48402009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4841
4842 * loader/i386/linux.c (GRUB_ASSUME_LINUX_HAS_FB_SUPPORT): New macro.
4843 (grub_linux_boot): Don't check for `linux_vesafb_modes' bounds (this
4844 is done by grub_cmd_linux() now).
4845 [! GRUB_ASSUME_LINUX_HAS_FB_SUPPORT]: If "vga=" parameter wasn't set,
4846 restore video to text mode.
4847 (grub_cmd_linux): Default `vid_mode' initialization to 0, which
4848 indicates lack of "vga=" parameter. "vga=0" is mapped to
4849 `GRUB_LINUX_VID_MODE_NORMAL'.
4850
afd5c115 48512009-05-04 Felix Zielcke <fzielcke@z-51.de>
4852
4853 * conf/i386-efi.rmk (grub_emu_SOURCES): Remove `normal/execute.c',
4854 `normal/lexer.c', `kern/rescue.c', `normal/function.c', `normal/misc.c'
4855 and `normal/script.c'. Add `kern/rescue_reader.c',
18f547ad 4856 `kern/rescue_parser.c', `script/sh/main.c', `script/sh/execute.c',
afd5c115 4857 `script/sh/function.c', `script/sh/lexer.c', `script/sh/script.c' and
4858 `grub_script.tab.c'.
4859
4860 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
4861 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
4862 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
4863 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
4864 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
4865
faa517ce 4866 * Makefile.in: Remove duplicated 2008 in Copyright line.
4867
ae0c0bdc 48682009-05-04 Robert Millan <rmh.grub@aybabtu.com>
4869
473d1e45 4870 * util/misc.c (grub_util_warn): New function. Emits a warning
ae0c0bdc 4871 unconditionally.
4872 * include/grub/util/misc.h (grub_util_warn): New declaration.
4873
4874 * util/i386/pc/grub-install.in: Understand --force and pass it down
4875 to grub-setup.
4876
4877 * util/i386/pc/grub-setup.c (main): Understand --force and pass it
4878 down to setup().
4879 (setup): Improve error messages and add warnings when requested to
4880 install in odd layouts. Refuse to install using blocklists unless
4881 --force was set.
4882
18f547ad 48832009-05-04 martin f. krafft <madduck@madduck.net>
c149b500 4884
4885 * disk/raid.c (grub_raid_scan_device): Improve debug message.
4886
6d260daa 48872009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
4888
4889 Updated copyright year
4890
4891 * fs/hfsplus.c: updated copyright year
18f547ad 4892
69f853f8 48932009-05-04 Vladimir Serbinenko <phcoder@gmail.com>
4894
4895 HFS+ UUID
4896
18f547ad 4897 * fs/hfsplus.c (grub_hfsplus_volheader): added num_serial field
69f853f8 4898 in the space previously used by unused3
4899 (grub_hfsplus_uuid): new function
4900 (grub_hfsplus_fs): added uuid field
4901
4c402e73 49022009-05-03 Pavel Roskin <proski@gnu.org>
4903
4904 * disk/ata.c: Don't cast mod to void in GRUB_MOD_INIT to
4905 suppress warnings. It's no longer needed.
4906 * disk/host.c: Likewise.
4907 * disk/ata_pthru.c: Likewise.
4908 * disk/loopback.c: Likewise.
4909 * hook/datehook.c: Likewise.
4910 * parttool/pcpart.c: Likewise.
4911 * fs/i386/pc/pxe.c: Likewise.
4912 * fs/ntfscomp.c: Likewise.
4913 * efiemu/main.c: Likewise.
4914 * mmap/mmap.c: Likewise.
4915 * commands/crc.c: Likewise.
4916 * commands/hexdump.c: Likewise.
4917 * commands/hdparm.c: Likewise.
4918 * commands/acpi.c: Likewise.
4919 * commands/echo.c: Likewise.
4920 * commands/minicmd.c: Likewise.
4921 * commands/blocklist.c: Likewise.
4922 * commands/memrw.c: Likewise.
4923 * commands/loadenv.c: Likewise.
4924 * commands/usbtest.c: Likewise.
4925 * commands/lsmmap.c: Likewise.
4926 * commands/boot.c: Likewise.
4927 * commands/parttool.c: Likewise.
4928 * commands/configfile.c: Likewise.
4929 * commands/search.c: Likewise.
4930 * commands/ieee1275/suspend.c: Likewise.
4931 * commands/cat.c: Likewise.
4932 * commands/i386/pc/pxecmd.c: Likewise.
4933 * commands/i386/pc/play.c: Likewise.
4934 * commands/i386/pc/halt.c: Likewise.
4935 * commands/i386/pc/vbeinfo.c: Likewise.
4936 * commands/i386/pc/vbetest.c: Likewise.
4937 * commands/lspci.c: Likewise.
4938 * commands/date.c: Likewise.
4939 * commands/handler.c: Likewise.
4940 * commands/ls.c: Likewise.
4941 * commands/test.c: Likewise.
4942 * commands/cmp.c: Likewise.
4943 * commands/efi/loadbios.c: Likewise.
4944 * commands/efi/fixvideo.c: Likewise.
4945 * commands/halt.c: Likewise.
4946 * commands/help.c: Likewise.
4947 * commands/reboot.c: Likewise.
4948 * hello/hello.c: Likewise.
4949 * script/sh/main.c: Likewise.
4950 * loader/xnu.c: Likewise.
4951 * term/terminfo.c: Likewise.
4952 * term/i386/pc/serial.c: Likewise.
4953 * term/usb_keyboard.c: Likewise.
4954
515b5079 49552009-05-03 David S. Miller <davem@davemloft.net>
4956
4957 * normal/menu.c: Include grub/parser.h
4958
dfc31a22 49592009-05-03 Pavel Roskin <proski@gnu.org>
4960
2fee74f1 4961 * mmap/efi/mmap.c (grub_mmap_malign_and_register): Return void*,
4962 not char*.
4963 * mmap/i386/mmap.c (grub_mmap_malign_and_register): Likewise.
4964 Suggested by Javier Martín <lordhabbit@gmail.com>
4965
dfc31a22 4966 * util/i386/pc/grub-mkrescue.in: Allow for the case when
4967 efiemu??.o doesn't exist.
4968 * util/i386/pc/grub-install.in: Likewise. Use "cp -f" for
4969 copying.
4970
18f547ad 49712009-05-03 Bean <bean123ch@gmail.com> Vladimir Serbinenko <phcoder@gmail.com>
cef17233 4972
4973 FreeBSD 64-bit support
4974
18f547ad 4975 * conf/i386-pc.rmk (bsd_mod_SOURCES): add loader/i386/bsd_helper.S
cef17233 4976 and loader/i386/bsd_trampoline.S
4977 (bsd_mod_ASFLAGS): new variable
4978 * include/grub/i386/bsd.h (FREEBSD_MODINFOMD_SMAP): new definition
4979 (FREEBSD_MODTYPE_KERNEL64): likewise
4980 (grub_bsd64_trampoline_start): likewise
4981 (grub_bsd64_trampoline_end): likewise
4982 (grub_bsd64_trampoline_selfjump): likewise
4983 (grub_bsd64_trampoline_gdt): likewise
4984 * include/grub/i386/loader.h (grub_unix_real_boot): moved from here ...
4985 * include/grub/i386/bsd.h (grub_unix_real_boot): ... moved here
4986 * kern/i386/loader.S (grub_unix_real_boot): moved from here ...
4987 * loader/i386/bsd_helper.S (grub_unix_real_boot): moved here
18f547ad 4988 * include/grub/gpt_partition.h (grub_gpt_partentry): Corrected the type
cef17233 4989 of "attrib" member
4990 * loader/i386/bsd_pagetable.c: new file
4991 * loader/i386/bsd_trampoline.S: likewise
4992 * loader/i386/bsd.c (ALIGN_QWORD): new macro
4993 (ALIGN_VAR): likewise
4994 (entry_hi): new variable
4995 (kern_end_mdofs): likewise
4996 (is_64bit): likewise
4997 (grub_freebsd_add_meta): use ALIGN_VAR
4998 (grub_e820_mmap): new declaration
4999 (grub_freebsd_add_mmap): new function
5000 (grub_freebsd_add_meta_module): support 64 bit kernels
5001 (grub_freebsd_list_modules): use ALIGN_VAR
5002 (gdt_descriptor): new declaration
5003 (grub_freebsd_boot): support 64 bit kernels
5004 (grub_bsd_elf64_hook): new function
5005 (grub_bsd_load_elf): support elf64
5006
038c5720 50072009-05-03 Bean <bean123ch@gmail.com>
5008
5009 * script/sh/execute.c (grub_script_execute_cmdif): Reset grub_errno
5010 after we get the result of if statement.
5011
fc45fb58 50122009-05-03 Bean <bean123ch@gmail.com>
5013
5014 * Makefile.in (enable_efiemu): New variable.
5015
5016 * conf/i386-pc.rmk: Only compile efiemu runtimes when enable_efiemu is
5017 set.
5018 (efiemu32.o): Use macro $< for source file, add $(srcdir) to include
5019 path.
5020 (efi64_c.o): Use macro $< for source file, add $(srcdir) to include
5021 path, add -mno-red-zone option.
5022 (efiemu64_s.o): Likewise.
5023 (efiemu64.o): Use macro $^ for source file.
5024
5025 * configure.ac (--enable-efiemu): New option.
5026
bbee0f2b 50272009-05-03 Vladimir Serbinenko <phcoder@gmail.com>
5028
5029 xnu support
5030
5031 * conf/i386-efi.rmk (kernel_mod_HEADERS): added i386/pit.h
5032 (pkglib_MODULES): add xnu.mod
5033 (xnu_mod_SOURCES): new variable
5034 (xnu_mod_CFLAGS): likewise
5035 (xnu_mod_LDFLAGS): likewise
5036 (xnu_mod_ASFLAGS): likewise
5037 * conf/i386-pc.rmk: likewise
5038 * conf/x86_64-efi.rmk: likewise
7dd4a573 5039 * include/grub/efi/efi.h (grub_efi_finish_boot_services):
bbee0f2b 5040 new declaration
5041 * include/grub/i386/macho.h: new file
5042 * include/grub/i386/xnu.h: likewise
5043 * include/grub/macho.h: likewise
5044 * include/grub/machoload.h: likewise
5045 * include/grub/x86_64/macho.h: likewise
5046 * include/grub/x86_64/xnu.h: likewise
5047 * include/grub/xnu.h: likewise
5048 * kern/efi/efi.c (grub_efi_finish_boot_services): new function
5049 * kern/efi/mm.c (MAX_HEAP_SIZE): increase
5050 * loader/i386/efi/xnu.c: new file
5051 * loader/i386/pc/xnu.c: likewise
5052 * loader/i386/xnu.c: likewise
5053 * loader/i386/xnu_helper.S: likewise
5054 * loader/macho.c: likewise
5055 * loader/xnu.c: likewise
5056 * loader/xnu_resume.c: likewise
5057 * util/grub-dumpdevtree: likewise
5058 * include/grub/i386/pit.h: include grub/err.h
5059 (grub_pit_wait): export
5060 * util/grub.d/30_os-prober.in: support Darwin/Mac OS X
7dd4a573 5061
5caf964d 50622009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
5063
5064 Efiemu
7dd4a573 5065
5caf964d 5066 * conf/i386-pc.rmk: new modules efiemu, efiemu_acpi, efiemu_pnvram,
7dd4a573 5067 _linux_efi, linux_efi.
5068 new files in grub-emu
5caf964d 5069 new targets efiemu32.o and efiemu64.o
5070 * loader/linux_normal_efiemu.c: likewise
5071 * loader/i386/efi/linux.c: added preliminary efiemu support
7dd4a573 5072 * util/i386/pc/grub-install.in: add efiemu??.o to the list of
5caf964d 5073 files to copy
5074 * include/grub/autoefi.h: new file
7dd4a573 5075 * include/grub/i386/efiemu.h: likewise
5caf964d 5076 * include/grub/i386/pc/efiemu.h: likewise
5077 * include/grub/efi/api.h: add LL suffix when necessary
5078 new definitions relating to tables
5079 * include/grub/efiemu/efiemu.h: new file
5080 * include/grub/efiemu/runtime.h: likewise
5081 * efiemu/prepare.c: likewise
5082 * efiemu/loadcore_common.c: likewise
5083 * efiemu/loadcore64.c: likewise
5084 * efiemu/runtime/efiemu.sh: likewise
5085 * efiemu/runtime/efiemu.S: likewise
5086 * efiemu/runtime/efiemu.c: likewise
5087 * efiemu/runtime/config.h: likewise
5088 * efiemu/prepare32.c: likewise
5089 * efiemu/main.c: likewise
5090 * efiemu/modules/pnvram.c: likewise
5091 * efiemu/modules/i386: likewise
5092 * efiemu/modules/i386/pc: likewise
5093 * efiemu/modules/acpi.c: likewise
5094 * efiemu/i386/pc/cfgtables.c: likewise
5095 * efiemu/i386/loadcore64.c: likewise
5096 * efiemu/i386/loadcore32.c: likewise
5097 * efiemu/prepare64.c: likewise
5098 * efiemu/loadcore.c: likewise
5099 * efiemu/symbols.c: likewise
5100 * efiemu/mm.c: likewise
5101 * efiemu/loadcore32.c: likewise
7dd4a573 5102
51032009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
f8efe3ad 5104
5105 ACPI spoofing
5106
5107 * commands/acpi.c: new file
5108 * commands/i386/pc/acpi.c: likewise
5109 * commands/efi/acpi.c: likewise
5110 * include/grub/acpi.h: likewise
5111 * conf/i386-pc.rmk (pkglib_MODULES): added acpi.mod
5112 (acpi_mod_SOURCES): new variable
5113 (acpi_mod_CFLAGS): likewise
5114 (acpi_mod_LDFLAGS): likewise
5115 * conf/i386-efi.rmk: likewise
5116 * conf/x86_64-efi.rmk: likewise
5117
7dd4a573 51182009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
28a85665 5119
5120 Missing part from mmap patch
5121
5122 * mmap/efi/mmap.c (grub_machine_mmap_unregister): renamed to
5123 (grub_mmap_unregister)
5124 (grub_mmap_free_and_unregister): use grub_mmap_register
5125
7dd4a573 51262009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
09d842b9 5127
5128 Mmap services
5129
5130 * loader/i386/efi/linux.c (grub_linux_boot): use grub_mmap_iterate
5131 * loader/i386/linux.c (find_mmap_size): likewise
5132 (allocate_pages): likewise
5133 * loader/i386/multiboot.c (grub_get_multiboot_mmap_len): likewise
5134 (grub_fill_multiboot_mmap): likewise
5135 (grub_multiboot): use grub_mmap_get_lower and grub_mmap_get_upper
5136 * loader/i386/pc/linux.c (grub_cmd_linux): use grub_mmap_get_lower
5137 * include/grub/i386/bsd.h (OPENBSD_MMAP_AVAILABLE): new definition
5138 (OPENBSD_MMAP_RESERVED): likewise
5139 * include/grub/i386/pc/memory.h: include grub/memory.h
5140 (grub_lower_mem): removed
5141 (grub_upper_mem): likewise
5142 (GRUB_MACHINE_MEMORY_ACPI): new definition
5143 (GRUB_MACHINE_MEMORY_NVS): likewise
5144 (GRUB_MACHINE_MEMORY_MAX_TYPE): likewise
5145 (GRUB_MACHINE_MEMORY_HOLE): likewise
5146 (grub_machine_mmap_register): likewise
5147 (grub_machine_mmap_unregister): likewise
5148 (grub_machine_get_upper): likewise
5149 (grub_machine_get_lower): likewise
5150 (grub_machine_get_post64): likewise
5151 * include/grub/i386/efi/memory.h: new file
5152 * include/grub/x86_64/efi/memory.h: likewise
5153 * include/grub/efi/memory.h: likewise
5154 * conf/i386-pc.rmk (pkglib_MODULES): added mmap.mod
5155 (mmap_mod_SOURCES): new variable
5156 (mmap_mod_LDFLAGS): likewise
5157 (mmap_mod_ASFLAGS): likewise
5158 * conf/i386-coreboot.rmk: likewise
5159 * conf/i386-ieee1275.rmk: likewise
5160 * conf/i386-efi.rmk: likewise
5161 * conf/x86_64-efi.rmk: likewise
5162 * include/grub/types.h (UINT_TO_PTR): new macro
5163 (PTR_TO_UINT32): likewise
5164 (PTR_TO_UINT64): likewise
5165 * include/grub/memory.h: new file
5166 * mmap/i386/pc/mmap.c: likewise
5167 * mmap/i386/pc/mmap_helper.S: likewise
5168 * mmap/i386/uppermem.c: likewise
5169 * mmap/mmap.c: likewise
5170 * mmap/efi/mmap.c: likewise
7dd4a573 5171 * kern/i386/coreboot/init.c (grub_machine_init): don't use
09d842b9 5172 grub_upper_mem
5173 * kern/i386/pc/init.c (grub_lower_mem): removed variable
5174 (grub_upper_mem): likewise
5175 (grub_machine_init): don't use grub_upper_mem,
5176 make grub_lower_mem local
5177 * loader/i386/bsd.c (grub_openbsd_boot): use grub_mmap_get_lower,
5178 grub_mmap_iterate and grub_mmap_get_upper
5179 (grub_netbsd_boot): use grub_mmap_get_lower and grub_mmap_get_upper
5180
d558e6b5 51812009-05-02 Bean <bean123ch@gmail.com>
5182
5183 * conf/common.rmk (grub_script.tab.c): Change normal/parser.y to
5184 script/sh/parser.y.
5185 (pkglib_MODULES): Add normal.mod and sh.mod.
5186 (normal_SOURCES): New variable.
5187 (normal_mod_CFLAGS): Likewise.
5188 (normal_mod_LDFLAGS): Likewise.
5189 (sh_mod_SOURCES): Likewise.
5190 (sh_mod_CFLAGS): Likewise.
5191 (sh_mod_LDFLAGS): Likewise.
5192
5193 * conf/i386-pc.rmk (normal/lexer.c_DEPENDENCIES): Changed to
5194 script/sh/lexer.c_DEPENDENCIES.
5195 (kernel_img_SOURCES): Remove kern/rescue.c, and kern/reader.c,
5196 kern/rescue_reader.c and kern/rescue_parser.c.
5197 (kernel_img_HEADERS): Remove rescue.h, add reader.h.
5198 (grub_emu_SOURCES): Change source files.
5199 (pkglib_MODULES): Remove normal.mod.
5200 (normal_SOURCES): Removed.
5201 (normal_mod_CFLAGS): Likewise.
5202 (normal_mod_LDFLAGS): Likewise.
5203 * conf/i386-coreboot.rmk: Likewise.
5204 * conf/i386-efi.rmk: Likewise.
5205 * conf/i386-ieee1276.rmk: Likewise.
5206 * conf/powerpc-ieee1275.rmk: Likewise.
5207 * conf/sparc64-ieee1275.rmk: Likewise.
5208 * conf/x86_64-efi.rmk: Likewise.
5209
5210 * include/grub/command.h (grub_command_execute): New inline function.
5211
5212 * include/grub/menu.h (grub_menu_entry): Removed commands field.
5213
5214 * include/grub/normal.h: Remove <grub/setjmp.h>.
5215 (grub_fs_module_list): Moved to normal/autofs.c.
5216 (grub_exit_env): Removed.
5217 (grub_command_execute): Likewise.
5218 (grub_normal_menu_addentry): Renamed to grub_menu_addentry, removed
5219 parameter script.
5220 (read_command_list): New function declaration.
5221 (read_fs_list): Likewise.
5222
5223 * include/parser.h: Include <grub/reader.h>.
5224 (grub_parser_split_cmdline): Change type of getline parameter.
5225 (grub_parser): New structure.
5226 (grub_parser_class): New variable.
5227 (grub_parser_execute): New function declaration.
5228 (grub_register_rescue_parser): Likewise.
5229 (grub_parser_register): New inline function.
5230 (grub_parser_unregister): Likewise.
5231 (grub_parser_get_current): Likewise.
5232 (grub_parser_set_current): Likewise.
5233
5234 * include/grub/reader.h: New file.
5235 * kern/reader.c: Likewise.
5236 * kern/rescue_parser.c: Likewise.
5237 * kern/rescue_reader.c: Likewise.
5238 * normal/autofs.c: Likewise.
5239 * normal/dyncmd.c: Likewise.
5240
5241 * include/grub/rescue.h: Removed.
5242 * normal/command.h: Likewise.
5243
5244 * include/grub/script.h: Moved to ...
5245 * include/grub/script_sh.h: ... Moved here.
5246 * normal/execute.c: Moved to ...
5247 * script/sh/execute.c: ... Moved here.
5248 * normal/function.c: Moved to ...
5249 * script/sh/function.c: ... Moved here.
5250 * normal/lexer.c: Moved to ...
5251 * script/sh/lexer.c: ... Moved here.
5252 * normal/parser.y: Moved to ...
5253 * script/sh/parser.y: ... Moved here.
5254 * normal/script.c: Moved to ...
5255 * script/sh/script.c: ... Moved here.
5256
5257 * normal/main.c: Remove <grub/rescue.h> and <grub/script.h>, include
5258 <grub/reader.h>.
5259 (grub_exit_env): Removed.
5260 (fs_module_list): Moved to normal/autofs.c.
5261 (grub_file_getline): Don't handle comment here.
5262 (free_menu): Skip removed field entry->commands.
5263 (grub_normal_menu_addentry): Removed as grub_menu_entry, removed
5264 script parameter.
5265 (read_config_file): Removed nested parameter, change getline function.
5266 (grub_enter_normal_mode): Removed.
5267 (grub_dyncmd_dispatcher): Moved to normal/dyncmd.c.
5268 (read_command_list): Likewise.
5269 (autoload_fs_module): Moved to normal/autofs.c.
5270 (read_fs_list): Likewise.
5271 (reader_nested): New variable.
5272 (grub_normal_execute): Run parser.sh to switch to sh parser.
5273 (grub_cmd_rescue): Removed.
5274 (cmd_normal): Removed.
5275 (grub_cmd_normal): Unregister itself at the beginning. Don't register
5276 rescue command.
5277 (grub_cmdline_run): New function.
5278 (grub_normal_reader_init): Likewise.
5279 (grub_normal_read_line): Likewise.
5280 (grub_env_write_pager): Likewise.
5281 (cmdline): New variable.
5282 (grub_normal_reader): Likewise.
5283 (GRUB_MOD_INIT): Register normal reader and set as current, register
5284 pager hook, register normal command with grub_register_command_prio,
5285 so that it won't show up in command.lst.
5286 (GRUB_MOD_FINI): Unregister normal reader, unhook pager, clear
5287 grub_fs_autoload_hook.
5288
5289 * normal/menu.c: Remove <grub/script.h>, add <grub/command.h>.
5290 (grub_menu_execute_entry): Replace grub_script_execute with
5291 grub_parser_execute, change parameter to grub_command_execute.
5292
5293 * normal/menu_text.c: Remove <grub/script.h>.
5294
5295 * normal/menu_entry.c: Remove <grub/script.h>, add <grub/command.h>
5296 and <grub/parser.h>.
5297 (run): Change editor_getline to use new parser interface. Change
5298 parameter to grub_command_execute.
5299
5300 * kern/main.c: Remove <grub/rescue.h>, include <grub/command.h>,
5301 <grub/reader.h> and <grub/parser.h>.
5302 (grub_load_normal_mode): Execute normal command.
5303 (grub_main): Call grub_register_core_commands,
5304 grub_register_rescue_parser and grub_register_rescue_reader, use
5305 grub_reader_loop to enter input loop.
5306
7dd4a573 5307 * kern/parser.c (grub_parser_split_cmdline): Change type of
5308 getline parameter.
d558e6b5 5309 (grub_parser_class): New variable.
5310 (grub_parser_execute): New function.
5311
5312 * loader/i386/multiboot.c: Remove <grub/rescue.h>.
5313 * loader/multiboot2.c: Likewise.
5314 * loader/sparc64/ieee1275/linux.c: Likewise.
5315
5316 * util/grub-emu.c (read_command_list): New dummy function.
5317
18db813d 53182009-05-02 Robert Millan <rmh.grub@aybabtu.com>
5319
5320 * util/deviceiter.c (grub_util_iterate_devices): Increase max drive
5321 count to 16 for CCISS and IDA.
5322
6c67de15 53232009-05-02 Robert Millan <rmh.grub@aybabtu.com>
5324
5325 * normal/menu_text.c (grub_wait_after_message): Print a newline
5326 after waiting for user input.
5327
5328 * loader/i386/linux.c: Include `<grub/normal.h>'.
5329 (grub_cmd_linux): Improve the error message about `ask' mode, by
5330 waiting for user input so it's not missed (we can do this, since
5331 user requested interaction).
5332
d9dc87b0 53332009-05-02 Vladimir Serbinenko <phcoder@gmail.com>
5334
5335 Added missing lst to grub-mkrescue
5336
5337 * util/i386/pc/grub-mkrescue.in: added ${input_dir}/handler.lst
5338 and ${input_dir}/parttool.lst
5339
ac8a2baa 53402009-04-30 David S. Miller <davem@davemloft.net>
5341
ad22a610 5342 * util/hostdisk.c (device_is_wholedisk): New function.
5343 (grub_util_biosdisk_get_grub_dev): Shortcut when hdg.start is
5344 zero only if device_is_wholedisk() returns true.
5345
6966215d 5346 * util/hostdisk.c (convert_system_partition_to_system_disk):
5347 Handle virtual disk devices named /dev/vdiskX as found on sparc
5348 and powerpc.
5349
ac8a2baa 5350 * kern/sparc64/ieee1275/init.c (grub_machine_set_prefix): If
5351 lettered partition specifier is found, convert to numbered.
5352
979b4fb4 53532009-04-29 David S. Miller <davem@davemloft.net>
5354
e2bf39b2 5355 * include/grub/powerpc/ieee1275/memory.h: Include ieee1275.h.
5356 * include/grub/sparc64/ieee1275/memory.h: Likewise.
5357
3c64e104 5358 * normal/command.c: Add missing newline at end of file.
5359
979b4fb4 5360 * commands/lsmmap.c (grub_cmd_lsmmap): Add casts to avoid printf
5361 warnings.
5362 * kern/ieee1275/openfw.c (grub_claimmap): Likewise.
5363 * disk/ieee1275/ofdisk.c (grub_ofdisk_open, grub_ofdisk_close,
5364 grub_ofdisk_read): Likewise, and deal similarly with the fact that
5365 ihandles have a 32-bit type but need to be stored in a "void *".
5366
136d9f82 53672009-04-28 Pavel Roskin <proski@gnu.org>
5368
9459c306 5369 * disk/fs_uuid.c (grub_fs_uuid_open): Use parent->data for dev,
5370 not disk. Adjust all dependencies.
2e08a26a 5371 (grub_fs_uuid_close): Use grub_device_close(), not
9459c306 5372 grub_disk_close().
5373
136d9f82 5374 * disk/fs_uuid.c (grub_fs_uuid_open): Allocate memory to copy
5375 parent's partition, don't copy it by reference, as it gets freed
5376 on close.
5377
7dd4a573 53782009-04-27 Vladimir Serbinenko <phcoder@gmail.com>
75a807cf 5379
5380 Preboot hooks support
5381
5382 * commands/boot.c (struct grub_preboot_t): new declaration
5383 (preboots_head): new variable
5384 (preboots_tail): likewise
5385 (grub_loader_register_preboot_hook): new function
5386 (grub_loader_unregister_preboot_hook): likewise
5387 (grub_loader_set): launch preboot hooks
5388 * include/grub/loader.h (grub_loader_preboot_hook_prio_t): new type
5389 (grub_loader_register_preboot_hook): new declaration
5390 (grub_loader_unregister_preboot_hook): likewise
5391
5af922b5 53922009-04-27 Vladimir Serbinenko <phcoder@gmail.com>
5393
5394 Warning fix
5395
7dd4a573 5396 * disk/scsi.c (grub_scsi_open): added missing cast when
5af922b5 5397 calling grub_dprintf
5398
a5562c30 53992009-04-26 Vladimir Serbinenko <phcoder@gmail.com>
5400
5401 Bug and warning fixes
5402
7dd4a573 5403 * include/grub/i386/pc/init.h (grub_stop_floppy): added missing
a5562c30 5404 declaration
5405 * commands/test.c (test_parse): fixed bug with file tests and corrected
5406 declaration of find_file
5407
4006f85c 54082009-04-26 Pavel Roskin <proski@gnu.org>
5409
5410 * Makefile.in: Don't install empty manual pages if help2man is
5411 missing. Use help2man option for output, not shell redirection.
5412
5c77c3de 54132009-04-26 David S. Miller <davem@davemloft.net>
5414
5415 * util/grub-mkdevicemap.c (make_device_map): Add missing
5416 NESTED_FUNC_ATTR to process_device().
5417
033b10a8 54182009-04-25 Vladimir Serbinenko <phcoder@gmail.com>
5419
5420 Test command
5421
5422 * commands/test.c: rewritten to use bash-like test
5423
e4343593 54242009-04-25 Vladimir Serbinenko <phcoder@gmail.com>
5425
5426 Parttool autoloading and improvements
5427
7dd4a573 5428 * Makefile.in (pkglib_DATA): add parttool.lst
e4343593 5429 (parttool.lst): new target
5430 * genmk.rb: generate parttool-*
5431 (CLEANFILES): add #{parttool}
5432 (PARTTOOLFILES): new variable
5433 * genparttoollist.sh: new file
7dd4a573 5434 * parttool/pcpart.c (grub_pcpart_boot): more feedback
e4343593 5435 (grub_pcpart_type): likewise
5436 * commands/parttool.c (helpmsg): new variable
5437 (grub_cmd_parttool): output help if not enough arguments are supplied
5438 autoload modules
5439 (GRUB_MOD_INIT(parttool)): use helpmsg
5440
0d312500 54412009-04-24 David S. Miller <davem@davemloft.net>
5442
7dd4a573 5443 Avoiding opening same device multiple times in device iterator.
0d312500 5444
5445 * kern/device.c: (grub_device_iterate): Define struct part_ent,
7dd4a573 5446 and use it to build a list of partitions in iterate_disk() and
0d312500 5447 iterate_partition().
5448
ac20caff 5449 * disk/fs_uuid.c (grub_fs_uuid_close): Call grub_disk_close()
5450 on disk->data.
5451
0dcf7495 5452 * disk/ieee1275/nand.c (grub_nand_iterate): Return
5453 grub_devalias_iterate() result instead of unconditional 0.
5454 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Likewise.
5455 Also, capture hook return value, either directly or via
5456 grub_children_iterate(), and propagate to caller.
5457 * include/grub/ieee1275/ieee1275.h (grub_devalias_iterate,
5458 grub_children_iterate): Return value is now 'int' instead of
5459 'grub_err_t'.
5460 * kern/ieee1275/openfw.c (grub_children_iterate): Fix to behave
5461 like a proper iterator, stopping when hooks return non-zero.
5462 (grub_devalias_iterate): Likewise.
5463
c8c08833 54642009-04-23 David S. Miller <davem@davemloft.net>
5465
5466 * kern/sparc64/ieee1275/openfw.c: Unused, delete.
5467
f01005a8 54682009-04-22 David S. Miller <davem@davemloft.net>
5469
5470 * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): If size_cells
5471 is larger than address_cells, use that value for address_cells too.
5472
4e8269da 5473 * include/grub/ieee1275/ieee1275.h (IEEE1275_MAX_PROP_LEN,
5474 IEEE1275_MAX_PATH_LEN): Define.
5475 * kern/ieee1275/openfw.c (grub_children_iterate): Dynamically
5476 allocate 'childtype', 'childpath', 'childname', and 'fullname'.
5477 (grub_devalias_iterate): Dynamically allocate 'aliasname' and
5478 'devtype'. Explicitly NULL terminate devalias expansion.
5479
a1447506 5480 * util/sparc64/ieee1275/misc.c: New file.
5481 * util/sparc64/ieee1275/grub-setup.c: New file.
5482 * util/sparc64/ieee1275/grub-ofpathname.c: New file.
5483 * util/sparc64/ieee1275/grub-mkimage.c: New file.
5484 * util/sparc64/ieee1275/grub-install.in: New file.
5485 * util/ieee1275/ofpath.c: New file.
5486 * util/ieee1275/devicemap.c: New file.
5487 * util/devicemap.c: New file.
5488 * util/deviceiter.c: New file.
5489 * kern/sparc64/ieee1275/init.c: New file.
5490 * include/grub/util/ofpath.h: New file.
5491 * include/grub/util/deviceiter.h: New file.
5492 * util/grub-mkdevicemap.c: Include deviceiter.h.
5493 Implement using grub_util_emit_devicemap_entry and
5494 grub_util_iterate_devices.
5495 * conf/i386-corebook.rmk: Build util/deviceiter.c and
5496 util/devicemap.c into grub-mkdevicemap
5497 * conf/i386-efi.rmk: Likewise.
5498 * conf/i386-ieee1275.rmk: Likewise.
5499 * conf/i386-pc.rmk: Likewise.
5500 * conf/powerpc-ieee1275.rmk: Likewise.
5501 * conf/sparc64-ieee1275.rmk: Add rules to build boot block
5502 images and installation utilities. Build kernel as image
5503 instead of as elf binary. Use common rules as much as possible.
5504
7dd4a573 55052009-04-19 Vladimir Serbinenko <phcoder@gmail.com>
0aefc632 5506
5507 Correct GPT definition
5508
7dd4a573 5509 * include/grub/gpt_partition.h (grub_gpt_partentry): Corrected the type
0aefc632 5510 of "attrib" member
5511
c6c5219f 55122009-04-19 Felix Zielcke <fzielcke@z-51.de>
5513
5514 * INSTALL: Replace `autogen.sh' with `./autogen.sh'.
5515
0552ff9f 55162009-04-19 David S. Miller <davem@davemloft.net>
5517
5518 * loader/sparc64/ieee1275/linux.c: Include grub/command.h
5519 (grub_rescue_cmd_linux): Rename to...
5520 (grub_cmd_linux): and fix prototype.
5521 (grub_rescue_cmd_initrd): Rename to...
5522 (grub_cmd_initrd): and fix prototype.
5523 (cmd_linux, cmd_initrd): New.
5524 (GRUB_MOD_INIT(linux)): Use grub_register_command().
5525 (GRUB_MOD_FINI(linux): Use grub_unregister_command().
5526
d1a282fc 55272009-04-17 Pavel Roskin <proski@gnu.org>
5528
07c5039f 5529 * bus/usb/ohci.c (grub_ohci_transaction): Fix incorrect printf
5530 format.
5531 (grub_ohci_transfer): Likewise.
5532
b012002d 5533 * bus/usb/usbtrans.c (grub_usb_control_msg): Warning fix.
5534
1bc09c35 5535 * loader/multiboot_loader.c (grub_cmd_multiboot_loader): Fix
5536 return without a value. Fix inconsistent indentation.
5537
e0ff9126 5538 * fs/i386/pc/pxe.c (grub_pxefs_dir): Fix function prototype to
5539 match struct grub_fs.
5540
d1a282fc 5541 * disk/ata.c (grub_ata_pciinit): Use NESTED_FUNC_ATTR.
5542 * bus/usb/ohci.c (grub_ohci_pci_iter): Likewise.
5543 * bus/usb/uhci.c (grub_uhci_pci_iter): Likewise.
5544 * commands/lspci.c (grub_lspci_iter): Likewise.
5545
a96df3f2 55462009-04-16 Bean <bean123ch@gmail.com>
5547
5548 * commands/efi/loadbios.c (grub_cmd_fakebios): Add missing return
5549 value.
5550
41bb0fe9 55512009-04-15 Pavel Roskin <proski@gnu.org>
5552
5553 * include/grub/types.h: Rename ULONG_MAX to GRUB_ULONG_MAX and
5554 LONG_MAX to GRUB_LONG_MAX. Introduce GRUB_LONG_MIN. Update all
5555 users of ULONG_MAX, LONG_MAX and LONG_MIN to use the new
5556 definitions.
5557
596c6970 55582009-04-15 Felix Zielcke <fzielcke@z-51.de>
5559
5560 * disk/lvm.c (grub_lvm_scan_device): Add `LVM' to the error messages,
7dd4a573 5561 that no multiple data or metadata areas are supported and `Unknown
596c6970 5562 metadata header'.
5563
7dd4a573 55642009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
0d5d5653 5565
5566 Move loader out of the kernel
5567
5568 * kern/loader.c: moved to ...
5569 * commands/boot.c: ... moved here
5570 * commands/minicmd.c (grub_mini_cmd_boot): moved to ...
5571 * commands/boot.c (grub_cmd_boot): moved here. All users updated
5572 * include/grub/kernel.h (grub_machine_fini): export
5573 * include/grub/loader.h (grub_loader_is_loaded): update declaration
5574 (grub_loader_set): likewise
5575 (grub_loader_unset): likewise
5576 (grub_loader_boot): likewise
5577 * conf/common.rmk: new module boot.mod
5578 (pkglib_MODULES): add boot.mod
5579 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): remove kern/loader.c
5580 (grub_emu_SOURCES): likewise
5581 * conf/i386-efi.rmk (kernel_elf_SOURCES): likewise
5582 (grub_emu_SOURCES): likewise
5583 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): likewise
5584 (grub_emu_SOURCES): likewise
5585 * conf/i386-pc.rmk (kernel_elf_SOURCES): likewise
5586 (grub_emu_SOURCES): likewise
5587 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): likewise
5588 (grub_emu_SOURCES): likewise
7dd4a573 5589 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): likewise
5590 (grub_emu_SOURCES): likewise
0d5d5653 5591 * conf/x86_64-efi.rmk (kernel_elf_SOURCES): likewise
7dd4a573 5592 (grub_emu_SOURCES): likewise
0d5d5653 5593
7dd4a573 55942009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
5999d619 5595
5596 use grub_lltoa instead of grub_itoa and grub_ltoa for all purposes
7dd4a573 5597
5999d619 5598 * kern/misc.c (grub_itoa): Removed function
5599 (grub_ltoa): likewise
5600 (grub_vsprintf): use grub_lltoa
5601
7dd4a573 56022009-04-15 Vladimir Serbinenko <phcoder@gmail.com>
13c00781 5603
5604 Restore grub-emu
5605
5606 * conf/i386-pc.rmk (grub_emu_SOURCES): add normal/handler.c
5607 * conf/i386-coreboot.rmk: likewise
5608 * conf/i386-ieee1275.rmk: likewise
5609 * conf/powerpc-ieee1275.rmk: likewise
7dd4a573 5610
20318222 56112009-04-15 Felix Zielcke <fzielcke@z-51.de>
5612
5613 * INSTALL: Add that `./autogen.sh' needs to be run before
5614 `./configure.'.
5615
d05f0df3 56162009-04-14 Bean <bean123ch@gmail.com>
5617
5618 * Makefile.in (pkglib_DATA): Add handler.lst.
5619 (handler.lst): New rule.
5620
5621 * conf/i386-pc.rmk (normal_mod_SOURCES): Add normal/handler.c.
5622 * conf/i386-coreboot.rmk: Likewise.
5623 * conf/i386-ieee1275.rmk: Likewise.
5624 * conf/i386-efi.rmk: Likewise.
5625 * conf/x86_64-efi.rmk: Likewise.
5626 * conf/powerpc-ieee1275.rmk: Likewise.
5627 * conf/sparc64-ieee1275.rmk: Likewise.
5628
5629 * genhandlerlist.sh: New file.
5630
5631 * genmk.rb: Add rules to generate handler.lst.
5632
5633 * include/grub/normal.h (grub_file_getline): New function definition.
5634 (read_handler_list): Likewise.
5635 (free_handler_list): Likewise.
5636
5637 * include/grub/term.h (grub_term_register_input): Add name parameter
5638 for auto generation of handler.lst.
5639 (grub_term_register_output): Likewise.
5640
5641 * normal/handler.c: New file.
5642
5643 * normal/main.c (get_line): Renamed to grub_file_getline.
5644 (read_config_file): Use the newly renamed grub_file_getline.
5645 (read_command_list): Likewise.
5646 (read_fs_list): Likewise.
5647 (grub_normal_execute): Call read_handler_list to parse handler.lst.
5648 (GRUB_MOD_FINI): Call free_handler_list to free handler list.
5649
5650 * term/efi/console.c (grub_console_init): Add name parameter for auto
5651 generation of handler.lst.
5652 * term/gfxterm.c: Likewise.
5653 * term/i386/pc/at_keyboard.c: Likewise.
5654 * term/i386/pc/console.c: Likewise.
5655 * term/i386/pc/serial.c: Likewise.
5656 * term/i386/pc/vesafb.c: Likewise.
5657 * term/i386/pc/vga.c: Likewise.
5658 * term/i386/pc/vga_text.c: Likewise.
5659 * term/ieee1275/ofconsole.c: Likewise.
5660 * term/usb_keyboard.c: Likewise.
5661
33c846be 56622009-04-14 Bean <bean123ch@gmail.com>
5663
5664 * util/grub-pe2elf.c (write_symbol_table): Terminate short name symbol
5665 properly with null character.
5666
4484e01e 56672009-04-14 Felix Zielcke <fzielcke@z-51.de>
5668
5669 * configure: Remove.
5670 * config.h.in: Likewise.
f93d668e 5671 * stamp-h.in: Likewise.
4484e01e 5672 * DISTLIST: Likewise.
5673 * conf/common.mk: Likewise.
5674 * conf/i386-coreboot.mk: Likewise.
5675 * conf/i386-efi.mk: Likewise.
5676 * conf/i386-ieee1275.mk: Likewise.
5677 * conf/i386.mk: Likewise.
5678 * conf/i386-pc.mk: Likewise.
5679 * conf/powerpc-ieee1275.mk: Likewise.
5680 * conf/sparc64-ieee1275.mk: Likewise.
5681 * conf/x86_64-efi.mk: Likewise.
5682
5683 * INSTALL: Remove the sentence that Ruby and autoconf are only required if you
5684 develop on GRUB.
5685
7dd4a573 56862009-04-14 John Stanley <jpsinthemix@verizon.net>
5c5bf96a 5687 David S. Miller <davem@davemloft.net>
5688
5689 * util/hostdisk.c (make_device_name): Fix buffer length
5690 calculations.
5691
e25b5a8c 56922009-04-14 Felix Zielcke <fzielcke@z-51.de>
5693
5694 * util/hostdisk.c [__FreeBSD__ || __FreeBSD_kernel__]: Include
5695 <sys/param.h> and <sys/sysctl.h>.
5696 (open_device) [__FreeBSD__ || __FreeBSD_kernel_]: Use sysctlgetbyname()
5697 to add 0x10 to `kern.geom.debugflags' if it's not already set, before
5698 opening the device and reset them afterwards.
5699
1f1f580c 57002009-04-13 Pavel Roskin <proski@gnu.org>
5701
5702 * conf/common.rmk (grub_fstest_SOURCES): Add normal/datetime.c.
5703 Reported by John Stanley <jpsinthemix@verizon.net>
5704
7ebc2d6b 57052009-04-13 Robert Millan <rmh@aybabtu.com>
5706
5707 * util/grub.d/10_freebsd.in: Detect Debian GNU/kFreeBSD and use
7dd4a573 5708 that name for menuentries when appropriate.
7ebc2d6b 5709
d8ba3667 57102009-04-13 Felix Zielcke <fzielcke@z-51.de>
5711
5712 * util/grub.d/10_freebsd.in: Add a missing `fi'.
5713
cba416eb 57142009-04-13 Robert Millan <rmh@aybabtu.com>
5715
5716 * loader/i386/linux.c (grub_cmd_linux): Don't pass `vga=ask' parameter
5717 to Linux, simply abort telling the user it's no longer supported.
5718
a547a745 57192009-04-13 Felix Zielcke <fzielcke@z-51.de>
5720
5721 * util/grub.d/10_freebsd.in: Don't exit if /boot/devices.hints
7dd4a573 5722 doesn't exist. Check also for /boot/kernel/kernel.gz. Print
a547a745 5723 `freebsd_loadenv' only when devices.hints exist.
5724
232a769c 57252009-04-13 Pavel Roskin <proski@gnu.org>
5726
5727 * term/usb_keyboard.c (grub_usb_keyboard_getkey): Warning fixes.
5728
c3012039 57292009-04-13 Felix Zielcke <fzielcke@z-51.de>
5730
5731 * util/i386/pc/grub-install.in (install_drive): Remove the BSD
5732 partition number.
5733 (grub_drive): Likewise.
5734
234022fe 57352009-04-13 David S. Miller <davem@davemloft.net>
5736
5737 * kern/sparc64/ieee1275/ieee1275.c: New file.
5738 * include/grub/sparc64/ieee1275/ieee1275.h (IEEE1275_MAP_WRITE,
5739 IEEE1275_MAP_READ, IEEE1275_MAP_EXEC, IEEE1275_MAP_LOCKED,
5740 IEEE1275_MAP_CACHED, IEEE1275_MAP_SE, IEEE1275_MAP_GLOBAL,
5741 IEEE1275_MAP_IE, IEEE1275_MAP_DEFAULT): Define.
5742 (grub_ieee1275_map_physical, grub_ieee1275_claim_vaddr,
5743 grub_ieee1275_alloc_physmem): Declare new exported functions.
5744
d8e1836c 5745 * include/grub/sparc64/ieee1275/loader.h: New file.
5746 * include/grub/sparc64/ieee1275/memory.h: Likewise.
5747 * include/grub/sparc64/kernel.h: Likewise.
5748 * loader/sparc64/ieee1275/linux.c: Likewise.
5749
96bd81ec 5750 * conf/common.rmk (grub_probe_SOURCES): Add Sun partition module.
5751 (grub_fstest_SOURCES): Likewise.
5752
6a4737e5 5753 * util/hostdisk.c (make_device_name): Do not make any assumptions
5754 about the length of drive names.
5755
1d7a72fd 5756 * kern/dl.c (grub_dl_load_file): Close file immediately when
5757 we are done using it.
5758
56bc2471 57592009-04-12 David S. Miller <davem@davemloft.net>
5760
5761 * kern/misc.c (grub_ltoa): Fix cast when handling negative
5762 values. Noticed by Pavel Roskin.
5763
df38d0bb 5764 * configure.ac: Check for __bswapsi2 and__bswapdi2 using
5765 target compiler.
7dd4a573 5766
e382e93a 5767 * genmk.rb: Add more flexible image type specification, also
5768 pass --strip-unneeded to objcopy.
5769 * conf/i386-pc.rmk: Use *_FORMAT.
5770 * conf/i386-pc.mk: Rebuilt.
5771
f5dbbca9 5772 * disk/ieee1275/ofdisk.c (struct ofdisk_hash_ent): New struct.
5773 (OFDISK_HASH_SZ): Define.
5774 (ofdisk_hash): New hash table.
5775 (ofdisk_hash_fn, ofdisk_hash_find, ofdisk_hash_add): New functions.
5776 (grub_ofdisk_open): Use ofdisk_hash_ent address as disk->id
5777 instead of device phandle which is not unique.
5778
91c88b12 5779 * kern/sparc64/ieee1275/init.c: Delete, replace with...
5780 * kern/sparc64/ieee1275/crt0.S: assembler implementation.
5781 * include/grub/sparc64/ieee1275/kernel.h: Declare grub_prefix[].
5782 (GRUB_MOD_ALIGN, GRUB_MOD_GAP, GRUB_KERNEL_MACHINE_TOTAL_MODULE_SIZE,
5783 GRUB_KERNEL_MACHINE_KERNEL_IMAGE_SIZE,
5784 GRUB_KERNEL_MACHINE_COMPRESSED_SIZE, GRUB_KERNEL_MACHINE_PREFIX,
5785 GRUB_KERNEL_MACHINE_DATA_END): Define.
5786 (grub_kernel_image_size, grub_total_module_size): Declare.
5787
5b5d4aa5 57882009-04-12 Pavel Roskin <proski@gnu.org>
5789
7dd4a573 5790 * configure.ac: Change the logic when we check for target tools.
5791 Do it when the target is specified and it's different from the
5792 specified value of the host.
5b5d4aa5 5793
c91e1793 57942009-04-11 Felix Zielcke <fzielcke@z-51.de>
5795
5796 * util/hostdisk.c [__FreeBSD_kernel__]: Include sys/disk.h.
5797 (grub_util_biosdisk_open) [__FreeBSD_kernel__]: Add support for
5798 GNU/kFreeBSD. Check if a device is a character device. Use
5799 DIOCGMEDIASIZE to get the size.
5800 (convert_system_partition_to_system_disk) [__FreeBSD_kernel__]: Add
5801 support for GNU/kFreeBSD.
5802 (grub_util_biosdisk_get_grub_dev) [__FreeBSD_kernel__]: Check if OS_DEV
5803 is a character device instead of a block device. Add support for
5804 FreeBSD device names.
5805
5806 * util/getroot.c (find_root_device) [__FreeBSD_kernel__]: Check if ENT
5807 is a character device instead of a block device.
5808
5809 * util/grub-probe.c (probe) [__FreeBSD_kernel__]: Check if DEVICE_NAME
5810 is a character device instead of a block device.
5811
b1ac8644 58122009-04-11 Andrey Shuvikov <mr_hyro@yahoo.com>
5813
5814 * util/hostdisk.c [__FreeBSD__]: Include sys/disk.h.
5815 (grub_util_biosdisk_open) [__FreeBSD__]: Add support for
5816 FreeBSD. Check if a device is a character device. Use
5817 DIOCGMEDIASIZE to get the size.
5818 (convert_system_partition_to_system_disk) [__FreeBSD__]: Add
5819 support for FreeBSD.
5820 (grub_util_biosdisk_get_grub_dev) [__FreeBSD__]: Check if OS_DEV
5821 is a character device instead of a block device. Add support for
5822 FreeBSD device names.
5823
5824 * util/getroot.c (find_root_device) [__FreeBSD__]: Check if ENT is
5825 a character device instead of a block device.
5826 (grub_util_check_char_device): New function.
5827
5828 * util/grub-probe.c (probe) [__FreeBSD__]: Check if DEVICE_NAME is
5829 a character device instead of a block device.
5830
5831 * include/grub/util/getroot.h (grub_util_check_char_device): New
5832 prototype.
5833
a3f7515a 58342009-04-11 David S. Miller <davem@davemloft.net>
5835
5836 * conf/sparc64-ieee1275.rmk (kernel_img_LDFLAGS): Link with
5837 static libgcc.
5838 * configure.ac: Check for __bswapsi2 and __bswapdi2 presence.
5839 * include/grub/sparc64/libgcc.h (__bswapsi2): Export libgcc
5840 function, if present.
5841 (__bswapdi2): Likewise.
5842
0d44993d 5843 * include/grub/sparc64/ieee1275/boot.h: New file.
5844 * boot/sparc64/ieee1275/boot.S: Likewise.
5845 * boot/sparc64/ieee1275/diskboot.S: Likewise.
5846
ed3d2bc2 5847 * kern/misc.c (grub_ltoa): New function.
5848 (grub_vsprintf): Use it to format 'long' integers.
5849
d3bfb59c 58502009-04-10 David S. Miller <davem@davemloft.net>
5851
5852 * disk/ieee1275/nand.c (grub_nand_open): All ieee1275 call arg
5853 slots are of type grub_ieee1275_cell_t.
5854 (grub_nand_read): Likewise.
5855 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_INVALID,
5856 IEEE1275_IHANDLE_INVALID): Use grub_ieee1275_cell_t since these
5857 macros are used to compare values in arg/ret block of the call.
5858 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
5859 grub_ieee1275_next_property, grub_ieee1275_get_property_length,
5860 grub_ieee1275_instance_to_package, grub_ieee1275_package_to_path,
5861 grub_ieee1275_instance_to_path, grub_ieee1275_write,
5862 grub_ieee1275_read, grub_ieee1275_seek, grub_ieee1275_peer,
5863 grub_ieee1275_child, grub_ieee1275_parent, grub_ieee1275_open,
5864 grub_ieee1275_close, grub_ieee1275_set_property,
5865 grub_ieee1275_set_color): All ieee1275 call arg slots are of type
5866 grub_ieee1275_cell_t.
5867 * kern/ieee1275/openfw.c (grub_map): Likewise.
5868 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_ihandle_t,
5869 grub_ieee1275_phandle_t): Define as grub_unit32_t type.
5870
450e2238 5871 * kern/ieee1275/init.c (grub_machine_init): Make 'actual' grub_ssize_t.
5872 * kern/ieee1275/openfw.c (grub_children_iterate): Likewise.
5873 (grub_devalias_iterate): Likewise.
5874
7dd4a573 58752009-04-10 Vladimir Serbinenko <phcoder@gmail.com>
6df8cc76 5876
5877 UFS improvements
5878
5879 * fs/ufs.c (INODE_NBLOCKS): new definition
5880 (struct grub_ufs_dirent): added fields for non-BSD dirents
5881 (grub_ufs_get_file_block): fixed double indirect handling
5882 (grub_ufs_lookup_symlink): use more robust way to determine whether
5883 symlink is inline
5884 (grub_ufs_find_file): support for non-BSD dirents
5885 (grub_ufs_dir): support for non-BSD dirents
5886
e7e6862a 58872009-04-10 Bean <bean123ch@gnail.com>
5888
5889 * include/grub/efi/api.h (grub_efi_configuration_table): Add packed
5890 attribute, otherwise the size would be wrong for i386 platform.
5891
5892 * include/grub/pci.h (grub_pci_read_word): New inline function.
5893 (grub_pci_read_byte): Likewise.
5894 (grub_pci_write): Likewise.
5895 (grub_pci_write_word): Likewise.
5896 (grub_pci_write_byte): Likewise.
5897
5898 * include/grub/pci.h (grub_pci_iteratefunc_t): Add NESTED_FUNC_ATTR.
5899
5900 * loader/i386/efi/linux.c (fake_bios_data): Moved to loadbios module.
5901 (find_framebuf): Scan pci to locate the frame buffer address.
5902
5903 * commands/efi/fixvideo.c: New file.
5904
5905 * commands/efi/loadbios.c: Likewise.
5906
5907 * commands/memrw.c: Likewise.
5908
5909 * util/grub-dumpbios.in: Likewise.
5910
5911 * conf/common.rmk (grub-dumpbios): New utility.
5912 (pkglib_MODULES): New module memrw.mod.
5913 (memrw_mod_SOURCE): New macro.
5914 (memrw_mod_CFLAGS): Likewise.
5915 (memrw_mod_LDFLAGS): Likewise.
5916
7dd4a573 5917 * conf/i386-efi.rmk (pkglib_MODULES): New module loadbios.mod and
e7e6862a 5918 fixvideo.mod.
5919 (loadbios_mod_SOURCE): New macro.
5920 (loadbios_mod_CFLAGS): Likewise.
5921 (loadbios_mod_LDFLAGS): Likewise.
5922 (fixvideo_mod_SOURCE): Likewise.
5923 (fixvideo_mod_CFLAGS): Likewise.
5924 (fixvideo_mod_LDFLAGS): Likewise.
5925
7dd4a573 5926 * conf/x86_64.rmk (pkglib_MODULES): New module loadbios.mod and
e7e6862a 5927 fixvideo.mod.
5928 (loadbios_mod_SOURCE): New macro.
5929 (loadbios_mod_CFLAGS): Likewise.
5930 (loadbios_mod_LDFLAGS): Likewise.
5931 (fixvideo_mod_SOURCE): Likewise.
5932 (fixvideo_mod_CFLAGS): Likewise.
5933 (fixvideo_mod_LDFLAGS): Likewise.
5934
af63ada2 59352009-04-08 Felix Zielcke <fzielcke@z-51.de>
5936
5937 * disk/lvm.c (grub_lvm_scan_device): Add a missing NULL check.
5938
c2cdde70 59392009-04-07 David S. Miller <davem@davemloft.net>
5940
5941 * kern/sparc64/dl.c (grub_arch_dl_relocate_symbols): Add
5942 support for R_SPARC_OLO10 relocations. Fix compile warning for
5943 R_SPARC_WDISP30 case.
ea3f72cf 5944 * kern/sparc64/cache.S: Fix grub_arch_sync_caches implementation.
c2cdde70 5945
761319cf 59462009-04-06 Pavel Roskin <proski@gnu.org>
5947
1007d1f5 5948 * include/grub/misc.h (ARRAY_SIZE): New macro.
5949 * include/grub/i386/linux.h (GRUB_LINUX_VID_MODE_VESA_START):
5950 New macro.
5951 * loader/i386/linux.c (allocate_pages): Use free_pages().
5952 (grub_linux_unload): Don't use free_pages().
5953 (grub_linux_boot): Prevent accessing linux_vesafb_modes with a
5954 wrong index. Treat all other modes as text modes.
5955 (grub_cmd_linux): Initialize vid_mode unconditionally to
5956 GRUB_LINUX_VID_MODE_NORMAL. Recognize and support "vga=ask".
5957
761319cf 5958 * commands/help.c (print_command_help): Use cmd->prio, not
5959 cmd->flags to check for GRUB_PRIO_LIST_FLAG_ACTIVE.
5960
ea761d40 59612009-04-06 Vladimir Serbinenko <phcoder@gmail.com>
7dd4a573 5962
ea761d40 5963 Parttool
5964
5965 * parttool/pcpart.c: new file
5966 * commands/parttool.c: likewise
5967 * conf/common.rmk (pkglib_MODULES): Added parttool.mod and pcpart.mod
5968 (parttool_mod_SOURCES): new variable
5969 (parttool_mod_CFLAGS): likewise
5970 (parttool_mod_LDFLAGS): likewise
5971 (pcpart_mod_SOURCES): likewise
5972 (pcpart_mod_CFLAGS): likewise
5973 (pcpart_mod_LDFLAGS): likewise
7dd4a573 5974 * conf/i386-coreboot.rmk (grub_emu_SOURCES): added commands/parttool.c
ea761d40 5975 and parttool/pcpart.c
5976 * conf/i386-efi.rmk: likewise
5977 * conf/i386-ieee1275.rmk: likewise
5978 * conf/i386-pc.rmk: likewise
5979 * conf/powerpc-ieee1275.rmk: likewise
5980 * conf/sparc64-ieee1275.rmk: likewise
5981 * conf/x86_64-ieee1275.rmk: likewise
5982
05aaebfb 59832009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
5984
5985 Support for mtime and further expandability of dir command
5986
5987 * include/grub/lib/datetime.h: moved to ...
7dd4a573 5988 * include/grub/datetime.h: ... moved here and added
05aaebfb 5989 declaration of grub_unixtime2datetime. All users updated
7dd4a573 5990 * include/grub/fs.h: new syntax for dir and mtime functions in
5991 struct grub_fs
05aaebfb 5992 * include/grub/fshelp.h: new declarations of GRUB_FSHELP_TYPE_MASK
5993 and GRUB_FSHELP_FLAGS_MASK
5994 * commands/ls.c (grub_ls_list_files): Write mtime in long format
5995 * fs/ext2.c (grub_ext2_dir): use new dir syntax and supply mtime
5996 (grub_ext2_mtime): new function
5997 * fs/hfsplus.c (grub_hfsplus_dir): use new dir syntax and supply mtime
5998 (grub_hfsplus_mtime): new function
5999 * fs/ufs.c (GRUB_UFS_ATTR_TYPE): new definition
6000 (GRUB_UFS_ATTR_FILE): likewise
6001 (GRUB_UFS_ATTR_LNK): likewise
6002 (struct grub_ufs_sblock): new fields mtime
6003 (grub_ufs_read_inode): new parameter to read inode to a separate buffer
6004 all users updated
6005 (grub_ufs_dir): mtime support
6006 (grub_ufs_mtime): new function
6007 * fs/affs.c (grub_affs_dir): use new dir syntax
6008 * fs/afs.c (grub_afs_dir): likewise
6009 * fs/cpio.c (grub_cpio_dir): likewise
6010 * fs/fat.c (grub_fat_find_dir): likewise
6011 * fs/hfs.c (grub_hfs_dir): likewise
6012 * fs/iso9660.c (grub_iso9660_dir): likewise
6013 * fs/jfs.c (grub_jfs_dir): likewise
6014 * fs/minix.c (grub_minix_dir): likewise
6015 * fs/ntfs.c (grub_ntfs_dir): likewise
6016 * fs/reiserfs.c (grub_reiserfs_dir): likewise
6017 * fs/sfs.c (grub_sfs_dir): likewise
6018 * fs/xfs.c (grub_xfs_dir): likewise
6019 * util/hostfs.c (grub_hostfs_dir): likewise
6020 * lib/datetime.c: moved to ...
6021 * normal/datetime.c: ... moved here
6022 (grub_unixtime2datetime): new function
6023 * kern/rescue.c (grub_rescue_print_files): use new dir syntax
7dd4a573 6024 * normal/completion.c (iterate_dir): use new dir syntax
6025 * normal/misc.c (grub_normal_print_device_info): tell the
05aaebfb 6026 last modification time of a volume
7dd4a573 6027 * kern/fs.c (grub_fs_probe): updated dummy function to use new syntax
05aaebfb 6028 * conf/common.rmk: added lib/datetime.c to ls.mod
7dd4a573 6029 * conf/i386-coreboot.rmk (grub_emu_SOURCES): add normal/datetime.c
05aaebfb 6030 (normal_mod_SOURCES): likewise
6031 (datetime_mod_SOURCES): Removed lib/datetime.c
6032 * conf/i386-efi.rmk: likewise
7dd4a573 6033 * conf/i386-ieee1275.rmk: likewise
05aaebfb 6034 * conf/i386-pc.rmk: likewise
6035 * conf/powerpc-ieee1275.rmk: likewise
7dd4a573 6036 * conf/sparc64-ieee1275.rmk: likewise
6037 * conf/x86_64-efi.rmk: likewise
05aaebfb 6038
8a7e1a14 60392009-04-05 Vladimir Serbinenko <phcoder@gmail.com>
6040
6041 Trim trailing spaces in FAT label and support mtools-like labels
7dd4a573 6042
6043 * fs/fat.c (grub_fat_iterate_dir): New function based
8a7e1a14 6044 on grub_fat_find_dir
6045 (grub_fat_find_dir): use grub_fat_iterate_dir
6046 (grub_fat_label): likewise
6047
04186a9c 60482009-04-04 Vladimir Serbinenko <phcoder@gmail.com>
6049
7dd4a573 6050 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): add list.h
04186a9c 6051 and command.h
6052 remove extraneous kernel_elf_HEADERS
6053
da4c0bb6 60542009-04-04 Bean <bean123ch@gnail.com>
6055
6056 * include/grub/util/misc.h: Add dummy function fsync for mingw.
6057
6058 * util/misc.c: Likewise.
6059
54ad9555 60602009-04-04 Yoshinori K. Okuji <okuji@enbug.org>
6061
6062 * loader/i386/efi/linux.c (fake_bios_data): Use grub_dprintf
6063 instead of grub_printf.
6064
7a6bf9f2 60652009-04-03 Robert Millan <rmh@aybabtu.com>
6066
6067 * loader/i386/linux.c (grub_linux_setup_video): Fill
6068 `params->{red,green,blue,reserved}_{mask_size,field_pos}' with
6069 values from `mode info' structure instead of hardcoded
6070 values.
6071
3fcc2083 60722009-04-01 Pavel Roskin <proski@gnu.org>
6073
6074 * Makefile.in: Remove all references to MODULE_LDFLAGS, it's
6075 unused now.
6076 * genmk.rb: Likewise.
6077 * configure.ac: Likewise.
6078
5ec9740b 60792009-04-01 Manoel Abranches <mrabran@linux.vnet.ibm.com>
6080
6081 * aclocal.m4: Move --build-id=none from MODULE_LDFLAGS to
6082 TARGET_LDFLAGS. This corrects a problem with grub-mkelfimage.
6083
5270cec8 60842009-04-01 David S. Miller <davem@davemloft.net>
6085
6086 * normal/sparc64/setjmp.S: Fix setjmp implementation.
7dd4a573 6087 * include/grub/sparc64/setjmp.h (grub_jmp_buf): Update.
5270cec8 6088 (grub_setjmp): Mark with 'returns_twice' attribute.
6089 * include/grub/i386/setjmp.h (grub_setjmp): Likewise
6090 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise.
6091 * include/grub/x86_64/setjmp.h (grub_setjmp): Likewise.
6092
9c3dd854 60932009-04-01 Robert Millan <rmh@aybabtu.com>
6094
6095 Reapply fix from 2008-07-28 which was accidentally reverted; also
6096 perform the same fix to a similar check in same function.
6097
6098 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
6099 with the same number are found, just use issue a warning with
6100 grub_dprintf(), as this error has been reported to be non-fatal.
6101
0d818b7e 61022009-03-31 Pavel Roskin <proski@gnu.org>
6103
6104 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Provide safe default
6105 for cross-compilation.
6106
95646d92 61072009-03-30 Robert Millan <rmh@aybabtu.com>
6108
6109 Fix i386-ieee1275 build.
6110
6111 * include/grub/i386/ieee1275/loader.h (grub_multiboot2_real_boot):
6112 Remove declaration.
6113
6a003ed1 61142009-03-30 Pavel Roskin <proski@gnu.org>
6115
6116 * fs/hfs.c (grub_hfs_strncasecmp): Integrate into ...
6117 (grub_hfs_cmp_catkeys): ... this. Don't assume strings to be
6118 zero-terminated, rely only on the strlen value. Fix comparison
6119 of strings differing in length.
6120
92f33540 61212009-03-30 Robert Millan <rmh@aybabtu.com>
6122
6123 * loader/i386/linux.c (grub_cmd_linux): Check for zImage before
6124 checking for abi version. Improve error messages on BIOS to notify
6125 user about `linux16' command.
6126
a8c48fd5 61272009-03-29 Vladimir Serbinenko <phcoder@gmail.com>
6128
f968172e 6129 Leak fixes
a8c48fd5 6130
f968172e 6131 * kern/disk.c (grub_disk_cache_store): Invalidate previous cache
6132 in case of collision
6133 * disk/scsi.c (grub_scsi_open): free scsi in case of error
a8c48fd5 6134
9c323f09 61352009-03-29 Robert Millan <rmh@aybabtu.com>
6136
6137 * loader/i386/linux.c (grub_cmd_linux): Parse "vga=" parameter and
6138 set `vid_mode' accordingly.
6139 (grub_linux_boot): Process `vid_mode' and set video mode.
6140
ae68f423 61412009-03-29 Robert Millan <rmh@aybabtu.com>
6142
6143 * util/grub.d/10_linux.in (linux_entry): New function.
6144 Factorize generation of Linux boot entries.
6145
5709cfc4 61462009-03-29 Yoshinori K. Okuji <okuji@enbug.org>
6147
6148 Make the format of Environment Block plain text. The boot loader
6149 part is not tested well yet.
7dd4a573 6150
5709cfc4 6151 * util/grub-editenv.c (DEFAULT_ENVBLK_SIZE): New macro.
6152 (buffer): Removed.
6153 (envblk): Likewise.
6154 (usage): Remove "info" and "clear". Add "unset". Update the
6155 description of "set", as this does not delete variables any
6156 longer.
6157 (create_envblk_file): Complete rewrite.
6158 (open_envblk_file): Likewise.
6159 (cmd_info): Removed.
6160 (cmd_list): Likewise.
6161 (cmd_set): Likewise.
6162 (cmd_clear): Likewise.
6163 (list_variables): New function.
6164 (write_envblk): Likewise.
6165 (set_variables): Likewise.
6166 (unset_variables): Likewise.
6167 (main): Complete rewrite.
6168
6169 * commands/loadenv.c (buffer): Removed.
6170 (envblk): Likewise.
6171 (open_envblk_file): New function.
6172 (read_envblk_file): Complete rewrite.
6173 (grub_cmd_load_env): Likewise.
6174 (grub_cmd_list_env): Likewise.
6175 (struct blocklist): New struct.
6176 (free_blocklists): New function.
6177 (check_blocklists): Likewise.
6178 (write_blocklists): Likewise.
6179 (grub_cmd_save_env): Complete rewrite.
6180
6181 * include/grub/lib/envblk.h (GRUB_ENVBLK_SIGNATURE): Replaced with
6182 a plain text signature.
6183 (GRUB_ENVBLK_MAXLEN): Removed.
6184 (struct grub_envblk): Complete rewrite.
6185 (grub_envblk_find): Removed.
6186 (grub_envblk_insert): Likewise.
6187 (grub_envblk_open): New prototype.
6188 (grub_envblk_set): Likewise.
6189 (grub_envblk_delete): Put const to VALUE.
6190 (grub_envblk_iterate): Put const to NAME and VALUE.
6191 (grub_envblk_close): New prototype.
6192 (grub_envblk_buffer): New inline function.
6193 (grub_envblk_size): Likewise.
6194
6195 * lib/envblk.c: Include grub/mm.h.
6196 (grub_env_find): Removed.
6197 (grub_envblk_open): New function.
6198 (grub_envblk_close): Likewise.
6199 (escaped_value_len): Likewise.
6200 (find_next_line): Likewise.
6201 (grub_envblk_insert): Removed.
6202 (grub_envblk_set): New function.
6203 (grub_envblk_delete): Complete rewrite.
6204 (grub_envblk_iterate): Likewise.
6205
a9368fd3 62062009-03-28 Robert Millan <rmh@aybabtu.com>
6207
6208 * conf/i386-pc.rmk (pkglib_MODULES): Add `linux16.mod'.
6209 (linux16_mod_SOURCES, linux16_mod_CFLAGS, linux16_mod_LDFLAGS): New
6210 variables. Use 16-bit loader.
6211 (linux_mod_SOURCES, linux_mod_CFLAGS, linux_mod_LDFLAGS): Use 32-bit
6212 loader.
6213 * kern/i386/loader.S (grub_linux_boot): Rename to ...
6214 (grub_linux16_boot): ... this. Update all users.
6215 * loader/i386/linux.c (grub_linux32_boot): Rename to ...
6216 (grub_linux_boot): ... this. Update all users.
6217
6218 * loader/i386/pc/linux.c (GRUB_MOD_INIT(linux)): Rename to ...
6219 (GRUB_MOD_INIT(linux16)): ... this. Rename `linux' and `initrd'
6220 commands to `linux16' and `initrd16'.
6221 (GRUB_MOD_FINI(linux)): Rename to ...
6222 (GRUB_MOD_FINI(linux16)): ... this.
6223
e4dd5a7e 62242009-03-24 Pavel Roskin <proski@gnu.org>
6225
6226 * genmk.rb: Define ASM_FILE for *.S files for *.lst generation,
6227 not just for compilation.
6228
c04d6e05 62292009-03-22 Vladimir Serbinenko <phcoder@gmail.com>
6230
6231 Move multiboot helper out of kernel
6232
6233 * conf/i386-pc.rmk (multiboot_mod_SOURCES): Add
6234 `loader/i386/multiboot_helper.S'.
6235 * conf/i386-coreboot.rmk: Likewise
6236 * conf/i386-ieee1275.rmk: Likewise
6237
6238 * kern/i386/loader.S: Move multiboot helpers from here...
6239 * loader/i386/multiboot_helper.S: ...moved here
6240 * include/grub/i386/loader.h: Move declarations of multiboot
6241 helpers from here...
6242 * include/grub/i386/multiboot.h: ...moved here
6243 * loader/i386/multiboot.c: Added include of grub/cpu/multiboot.h
6244
42a5b3fc 62452009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
6246
6247 * kern/env.c (grub_env_context_open): Added an argument to specify
6248 whether a new context inherits exported variables from current
6249 one. This is useful when making a sandbox to interpret a config
6250 file.
6251 All callers updated.
6252
6253 * include/grub/env.h (grub_env_context_open): Updated the prototype.
6254
b28bbc4e 62552009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
6256
6257 * kern/env.c (grub_env_context_close): Fix memory leaks.
6258
f04f02e4 62592009-03-22 Yoshinori K. Okuji <okuji@enbug.org>
6260
6261 * normal/main.c (grub_normal_execute): Added an argument
6262 BATCH to specify if an interactive interface should be provided
6263 after reading a config file.
6264 All callers updated.
6265 (read_command_list): Prevent being executed twice.
6266 (read_fs_list): Likewise.
6267
42a5b3fc 6268 * include/grub/normal.h (grub_normal_execute): Updated the
6269 prototype.
f04f02e4 6270
41473ac2 62712009-03-22 Pavel Roskin <proski@gno.org>
6272
fbc00b0c 6273 * kern/powerpc/ieee1275/startup.S: Replace EXT_C(start) with
6274 _start.
6275 * kern/i386/pc/startup.S: Likewise.
6276 * kern/i386/efi/startup.S: Likewise.
6277 * kern/i386/ieee1275/startup.S: Likewise.
6278 * kern/i386/coreboot/startup.S: Likewise.
6279 * kern/x86_64/efi/startup.S: Likewise.
6280
41473ac2 6281 * aclocal.m4 (grub_CHECK_START_SYMBOL): Remove.
6282 * configure.ac: Don't call grub_CHECK_START_SYMBOL.
6283 * kern/i386/pc/startup.S: Use _start instead of START_SYMBOL.
6284
2274cc8f 62852009-03-21 Vladimir Serbinenko <phcoder@gmail.com>
6286
6287 Bugfixes in multiboot for bugs uncovered by solaris kernel.
6288
6289 * loader/i386/multiboot_elfxx.c (grub_multiboot_load_elf): Corrected
6290 limit detection.
6291 Use vaddr of correct segment for entry_point.
6292
b1b797cb 62932009-03-21 Bean <bean123ch@gmail.com>
6294
6295 * commands/blocklist.c: Add include file <grub/command.h>, remove
6296 <grub/normal.h> and <grub/arg.h>.
6297 (grub_cmd_blocklist): Use the new command interface.
6298 (GRUB_MOD_INIT): Likewise.
6299 (GRUB_MOD_FINI): Likewise.
6300 * commands/boot.c: Likewise.
6301 * commands/cat.c: Likewise.
6302 * commands/cmp.c: Likewise.
6303 * commands/configfile.c: Likewise.
6304 * commands/crc.c: Likewise.
6305 * commands/echo.c: Likewise.
6306 * commands/halt.c: Likewise.
6307 * commands/handler.c: Likewise.
6308 * commands/hdparm.c: Likewise.
6309 * commands/help.c: Likewise.
6310 * commands/hexdump.c: Likewise.
6311 * commands/loadenv.c: Likewise.
6312 * commands/ls.c: Likewise.
6313 * commands/lsmmap.c: Likewise.
6314 * commands/lspci.c: Likewise.
6315 * commands/loadenv.c: Likewise.
6316 * commands/read.c: Likewise.
6317 * commands/reboot.c: Likewise.
6318 * commands/search.c: Likewise.
6319 * commands/sleep.c: Likewise.
6320 * commands/test.c: Likewise.
6321 * commands/usbtest.c: Likewise.
6322 * commands/videotest.c: Likewise.
6323 * commands/i386/cpuid.c: Likewise.
6324 * commands/i386/pc/halt.c: Likewise.
6325 * commands/i386/pc/play.c: Likewise.
6326 * commands/i386/pc/pxecmd.c: Likewise.
6327 * commands/i386/pc/vbeinfo.c: Likewise.
6328 * commands/i386/pc/vbetest.c: Likewise.
6329 * commands/ieee1275/suspend.c: Likewise.
6330 * disk/loopback.c: Likewise.
6331 * font/font_cmd.c: Likewise.
6332 * hello/hello.c: Likewise.
6333 * loader/efi/appleloader.c: Likewise.
6334 * loader/efi/chainloader.c: Likewise.
6335 * loader/i386/bsd.c: Likewise.
6336 * loader/i386/efi/linux.c: Likewise.
6337 * loader/i386/ieee1275/linux.c: Likewise.
6338 * loader/i386/linux.c: Likewise.
6339 * loader/i386/pc/chainloader.c: Likewise.
6340 * loader/i386/pc/linux.c: Likewise.
6341 * loader/powerpc/ieee1275/linux.c: Likewise.
6342 * loader/multiboot_loader.c: Likewise.
6343 * term/gfxterm.c: Likewise.
6344 * term/i386/pc/serial.c: Likewise.
6345 * term/terminfo.c: Likewise.
6346
6347 * term/i386/pc/vesafb.c: Removed <grub/arg.h>.
6348 * term/i386/pc/vga.c: Likewise.
6349 * video/readers/jpeg.c: Likewise.
6350 * video/readers/png.c: Likewise.
6351 * video/readers/tga.c: Likewise.
6352
6353 * util/grub-fstest (cmd_loopback): Removed.
6354 (cmd_blocklist): Likewise.
6355 (cmd_ls): Likewise.
6356 (grub_register_command): Likewise.
6357 (grub_unregister_command): Likewise.
6358 (execute_command): Use grub_command_find to locate command and execute
6359 it.
6360
6361 * include/grub/efi/chainloader.h: Removed.
6362 * loader/efi/chainloader_normal.c: Likewise.
6363 * loader/i386/bsd_normal.c: Likewise.
6364 * loader/i386/pc/chainloader_normal.c: Likewise.
6365 * loader/i386/pc/multiboot_normal.c: Likewise.
6366 * loader/linux_normal.c: Likewise.
6367 * loader/multiboot_loader_normal.c: Likewise.
6368 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
6369
6370 * gencmdlist.sh: Scan new registration command grub_register_extcmd
6371 and grub_register_command_p1.
6372
6373 * conf/common.rmk (grub_fstest_SOURCES): Add kern/list.c,
6374 kern/command.c, lib/arg.c and commands/extcmd.c.
6375 (pkglib_MODULES): Remove boot.mod, and minicmd.mod and extcmd.mod.
6376 (minicmd_mod_SOURCES): New variable.
6377 (minicmd_mod_CFLAGS): Likewise.
6378 (minicmd_mod_LDFLAGS): Likewise.
6379 (extcmd_mod_SOURCES): Likewise.
6380 (extcmd_mod_CFLAGS): Likewise.
6381 (extcmd_mod_LDFLAGS): Likewise.
6382 (boot_mod_SOURCES): Removed.
6383 (boot_mod_CFLAGS): Likewise.
6384 (boot_mod_LDFLAGS): Likewise.
6385
6386 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/command.c and
6387 kern/corecmd.c.
6388 (kernel_img_HEADERS): Add command.h.
6389 (grub_emu_SOURCES): Remove commands/boot.c and normal/arg.c, add
6390 commands/minicmd.c, kern/command.c, kern/corecmd.c, commands/extcmd.c
6391 and lib/arg.c.
6392 (pkglib_MODULES): Change _linux.mod, _chain.mod, _bsd.mod and
6393 _multiboot.mod as linux.mod, chain.mod, bsd.mod and multiboot.mod,
6394 remove the corresponding normal mode command.
6395 (normal_mod_SOURCES): Remove normal/arg.c.
6396 * conf/i386-coreboot.rmk: Likewise.
6397 * conf/i386-efi.rmk: Likewise.
6398 * conf/i386-ieee1275.rmk: Likewise.
6399 * conf/powerpc-ieee1275.rmk: Likewise.
6400 * conf/x86_64-efi.rmk: Likewise.
6401
6402 * include/grub/arg.h: Move from here ...
6403 * include/grub/lib/arg.h: ... to here.
6404
6405 * normal/arg.c: Move from here ...
6406 * lib/arg.c: ... to here.
6407
6408 * commands/extcmd.c: New file.
6409 * commands/minicmd.c: Likewise.
6410 * include/grub/command.h: Likewise.
6411 * include/grub/extcmd.h: Likewise.
6412 * kern/command.c: Likewise.
6413 * kern/corecmd.c: Likewise.
6414
6415 * kern/list.c (grub_list_iterate): Return int instead of void.
6416 (grub_list_insert): New function.
6417 (grub_prio_list_insert): Likewise.
6418
6419 * kern/rescue.c (grub_rescue_command): Removed.
6420 (grub_rescue_command_list): Likewise.
6421 (grub_rescue_register_command): Likewise.
6422 (grub_rescue_unregister_command): Likewise.
6423 (grub_rescue_cmd_boot): Move to minicmd.c
6424 (grub_rescue_cmd_help): Likewise.
6425 (grub_rescue_cmd_info): Likewise.
6426 (grub_rescue_cmd_boot): Likewise.
6427 (grub_rescue_cmd_testload): Likewise.
6428 (grub_rescue_cmd_dump): Likewise.
6429 (grub_rescue_cmd_rmmod): Likewise.
6430 (grub_rescue_cmd_lsmod): Likewise.
6431 (grub_rescue_cmd_exit): Likewise.
6432 (grub_rescue_print_devices): Moved to corecmd.c.
6433 (grub_rescue_print_files): Likewise.
6434 (grub_rescue_cmd_ls): Likewise.
6435 (grub_rescue_cmd_insmod): Likewise.
6436 (grub_rescue_cmd_set): Likewise.
6437 (grub_rescue_cmd_unset): Likewise.
7d074e3c 6438 (attempt_normal_mode): Use grub_command_find to get normal module.
b1b797cb 6439 (grub_enter_rescue_mode): Use grub_register_core_commands to register
7d074e3c 6440 commands, remove grub_rescue_register_command calls.
b1b797cb 6441
7d074e3c 6442 * normal/command.c (grub_register_command): Removed.
b1b797cb 6443 (grub_unregister_command): Likewise.
6444 (grub_command_find): Likewise.
6445 (grub_iterate_commands): Likewise.
6446 (rescue_command): Likewise.
6447 (export_command): Moved to corecmd.c.
6448 (set_command): Removed.
6449 (unset_command): Likewise.
6450 (insmod_command): Likewise.
6451 (rmmod_command): Likewise.
6452 (lsmod_command): Likewise.
6453 (grub_command_init): Likewise.
6454
6455 * normal/completion.c (iterate_command): Use cmd->prio to check for
6456 active command.
6457 (complete_arguments): Use grub_extcmd_t structure to find options.
6458 (grub_normal_do_completion): Change function grub_iterate_commands to
6459 grub_command_iterate.
6460
6461 * normal/execute.c (grub_script_execute_cmd): No need to parse
6462 argument here.
6463
6464 * normal/main.c (grub_dyncmd_dispatcher): New function.
6465 (read_command_list): Register unload commands as dyncmd.
6466 (grub_cmd_normal): Use new command interface, register rescue,
6467 unregister normal at entry, register normal, unregister rescue at exit.
6468
6469 * include/grub/list.h (grub_list_test_t): New type.
6470 (grub_list_iterate): Return int instead of void.
6471 (grub_list_insert): New function.
6472 (GRUB_AS_NAMED_LIST_P): New macro.
6473 (GRUB_AS_PRIO_LIST): Likewise.
6474 (GRUB_AS_PRIO_LIST_P): Likewise.
6475 (GRUB_PRIO_LIST_PRIO_MASK): New constant.
6476 (GRUB_PRIO_LIST_FLAG_ACTIVE): Likewise.
6477 (grub_prio_list): New structure.
6478 (grub_prio_list_insert): New function.
6479 (grub_prio_list_remove): New inline function.
6480
6481 * include/grub/normal.h: Remove <grub/arg.h>, add <grub/command.h>.
6482 (GRUB_COMMAND_FLAG_CMDLINE): Moved to command.h.
6483 (GRUB_COMMAND_FLAG_MENU): Likewise.
6484 (GRUB_COMMAND_FLAG_BOTH): Likewise.
6485 (GRUB_COMMAND_FLAG_TITLE): Likewise.
6486 (GRUB_COMMAND_FLAG_NO_ECHO): Likewise.
6487 (GRUB_COMMAND_FLAG_NO_ARG_PARSE): Removed.
6488 (GRUB_COMMAND_FLAG_NOT_LOADED): Likewise.
6489 (grub_command): Likewise.
6490 (grub_register_command): Likewise.
6491 (grub_command_find): Likewise.
6492 (grub_iterate_commands): Likewise.
6493 (grub_command_init): Likewise.
6494 (grub_arg_parse): Likewise.
6495 (grub_arg_show_help): Likewise.
6496
6497 * include/grub/rescue.h (grub_rescue_register_command): Removed.
6498 (grub_rescue_unregister_command): Likewise.
6499
6500 * include/grub/i386/bsd.h: Remove grub_rescue_cmd_freebsd,
6501 grub_rescue_cmd_openbsd, grub_rescue_cmd_netbsd,
6502 grub_rescue_cmd_freebsd_loadenv and grub_rescue_cmd_freebsd_module.
6503
6504 * include/grub/i386/efi/loader.h: Remove grub_rescue_cmd_linux and
6505 grub_rescue_cmd_initrd.
6506 * include/grub/i386/loader.h: Likewise.
6507 * include/grub/x86_64/loader.h: Likewise.
6508
6509 * include/grub/i386/pc/chainloader.h: Remove grub_chainloader_cmd.
6510
1f4147aa 65112009-03-21 Bean <bean123ch@gmail.com>
6512
6513 * util/hostdisk.c (read_device_map): Use grub_util_get_disk_size
6514 instead of stat in mingw environment.
6515
6516 * util/misc.c (grub_millisleep): Use Sleep in mingw environment.
6517
6518 * aclocal.m4 (grub_CHECK_LINK_DIR): New function.
6519
6520 * configure.ac: Use grub_CHECK_LINK_DIR to determine whether to use
6521 AC_CONFIG_LINKS.
6522
2156d5ba 65232009-03-21 Bean <bean123ch@gmail.com>
6524
6525 * fs/ext2.c (grub_ext2_mount): Change errno to GRUB_ERR_BAD_FS for
6526 out of range error.
6527
177b82ca 65282009-03-18 Michel Dänzer <michel@daenzer.net>
6529
6530 * fs/ext2.c (grub_ext2_read_block): Take endianness into account when
6531 checking inode flags for EXT4_EXTENTS_FLAG.
6532
14aad807 65332009-03-18 Robert Millan <rmh@aybabtu.com>
6534
6535 * loader/i386/linux.c: Include `<grub/video.h>' and
6536 `<grub/i386/pc/vbe.h>'..
6537 (grub_linux_setup_video): New function. Loosely based on the EFI one.
6538 (grub_linux32_boot): Attempt to configure video settings with
6539 grub_linux_setup_video().
6540 (grub_rescue_cmd_linux): Set noreturn=0 in grub_loader_set, in order
6541 to avoid grub_console_fini() which would step out of graphical mode
6542 unconditionally.
6543
8cf83a27 65442009-03-14 Robert Millan <rmh@aybabtu.com>
6545
6546 Fix build on powerpc.
6547 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Add `handler.h'.
6548
40164e75 65492009-03-12 Vladimir Serbinenko <phcoder@gmail.com>
6550
6551 * term/gfxterm.c (GRUB_MOD_FINI(term_gfxterm)): Correct name of
6552 background image command.
6553
c58bc32a 65542009-03-12 Colin D Bennett <colin@gibibit.com>
6555
6556 * term/gfxterm.c (draw_cursor): Ensure character is redrawn.
6557 (grub_gfxterm_putchar): Extract pairs of identical calls to
6558 draw_cursor out of conditional blocks.
6559
5415144a 65602009-03-11 Pavel Roskin <proski@gnu.org>
6561
6562 * fs/hfs.c (grub_hfs_strncasecmp): New function.
6563 (grub_hfs_cmp_catkeys): Use HFS specific string comparison.
6564
6394042e 65652009-03-11 Robert Millan <rmh@aybabtu.com>
6566
6567 * loader/i386/multiboot_elfxx.c
6568 (CONCAT(grub_multiboot_load_elf, XX)): Do not reject ET_DYN files.
6569
b7b50e5f 65702009-03-11 Felix Zielcke <fzielcke@z-51.de>
6571
6572 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add `kern/list.c' and
6573 `kern/handler.c'.
6574
1ca7fc96 65752009-03-11 Robert Millan <rmh@aybabtu.com>
6576
6577 * loader/i386/multiboot.c (code_size): New variable.
6578 (grub_multiboot): Define offsets by adding to `code_size' rather
7d074e3c 6579 than subtracting from `grub_multiboot_payload_size'. Provide
1ca7fc96 6580 4-byte alignment to MBI and others by increasing
7d074e3c 6581 `boot_loader_name_length' appropriately.
1ca7fc96 6582
6583 * loader/i386/multiboot_elfxx.c
6584 (CONCAT(grub_multiboot_load_elf, XX)): Initialize `code_size'.
6585
a83ea1d2 65862009-03-09 Felix Zielcke <fzielcke@z-51.de>
6587
6588 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove duplicated
6589 `fs/ext2.c'.
6590
aa9f3bff 65912009-03-08 Robert Millan <rmh@aybabtu.com>
6592
6593 Make loader/i386/linux.c usable on i386-pc again.
6594
6595 * kern/i386/pc/init.c (grub_machine_init): Disable addition of low
6596 memory to heap.
6597 * loader/i386/linux.c [GRUB_MACHINE_PCBIOS] (allocate_pages): Remove
6598 `#error' stanza.
6599
d8b3b60e 66002009-03-07 Bean <bean123ch@gmail.com>
6601
6602 * loader/i386/efi/linux.c (grub_rescue_cmd_initrd): Fix a bug in initrd
6603 allocation.
6604
b362c9e9 66052009-03-06 Robert Millan <rmh@aybabtu.com>
6606
6607 Fix display issue on terminals with screen size other than 80x25
6608 (e.g. gfxterm with resolution higher than 640x480).
6609
6610 * normal/main.c (grub_normal_init_page): Display title text in a
7d074e3c 6611 position relative to the center of the terminal instead of relying
b362c9e9 6612 on a hardcoded offset.
6613
9304eef1 66142009-03-04 Robert Millan <rmh@aybabtu.com>
6615
6616 Filter /etc/grub.d/10_* so that only add-ons for native kernels are
6617 installed.
6618
6619 * Makefile.in (host_kernel): New variable.
6620 * conf/common.rmk (grub-mkconfig_SCRIPTS): Conditionalize all 10_*.in
6621 scripts instead of just the windows one.
6622 * configure.ac: Initialize and AC_SUBST `host_kernel'.
6623
eabc95fb 66242009-03-04 Felix Zielcke <fzielcke@z-51.de>
2ba60b62 6625
6626 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `kern/list.c' and
6627 `kern/handler.c'.
6628 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
6629 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
6630 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
6631 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6632 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6633 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
6634
ceb1223c 66352009-03-04 Felix Zielcke <fzielcke@z-51.de>
6636
6637 * partmap/pc.c (pc_partition_map_iterate): Skip over invalid BSD partitions
6638 or if there's no space for the disk label and print the partition number on a
6639 invalid magic.
6640
4910684a 66412009-03-04 Felix Zielcke <fzielcke@z-51.de>
6642
6643 * util/misc.c: Include <time.h>.
6644 (grub_millisleep): New function.
6645
7e9ca17a 66462009-03-04 Bean <bean123ch@gmail.com>
6647
6648 * configure.ac: Only test -mcmodel=large option in x86_64-efi, also add
6649 another option -mno-red-zone.
6650
6651 * commands/handler.c: Change module description.
6652
6653 * kern/handler.c: Add missing space at the end of description line.
6654
6655 * kern/list.c: Likewise.
6656
f501677c 66572009-03-03 Robert Millan <rmh@aybabtu.com>
6658
6659 Move more components to the relocation area, and fix mbi pointer
6660 handling to use the destination rather than the origin (thanks to
6661 Vladimir Serbinenko for spotting).
6662
6663 * loader/i386/multiboot.c (mbi_dest): New variable.
6664 (grub_multiboot_boot): Use `mbi_dest' instead of `mbi'.
6665 (grub_multiboot): Put cmdline, boot_loader_name and mbi in the
6666 relocation area.
6667
9902d047 66682009-03-01 Bean <bean123ch@gmail.com>
6669
50fb7002 6670 * include/grub/efi/api.h (GRUB_EFI_MPS_TABLE_GUID): New constant.
9902d047 6671 (GRUB_EFI_ACPI_TABLE_GUID): Likewise.
6672 (GRUB_EFI_ACPI_20_TABLE_GUID): Likewise.
6673 (GRUB_EFI_SMBIOS_TABLE_GUID): Likewise.
6674
6675 * loader/i386/efi/linux.c (acpi_guid): New variable.
6676 (acpi_guid): Likewise.
6677 (EBDA_SEG_ADDR): New constant.
6678 (LOW_MEM_ADDR): Likewise.
6679 (FAKE_EBDA_SEG): Likewise.
6680 (fake_bios_data): New function.
6681 (grub_linux_boot): Call fake_bios_data.
6682
71b9f361 66832009-03-01 Bean <bean123ch@gmail.com>
6684
6685 * commands/terminal.c: Removed.
6686
6687 * commands/handler.c: New file.
6688
6689 * include/grub/list.h: Likewise.
6690
6691 * include/grub/handler.h: Likewise.
6692
6693 * kern/list.c: Likewise.
6694
6695 * kern/handler.c: Likewise.
6696
6697 * kern/term.h: Include header file <grub/handler.h>.
6698 (grub_term_input): Move next field to the beginning.
6699 (grub_term_output): Likewise.
6700 (grub_term_input_class): New variable.
6701 (grub_term_output_class): Likewise.
6702 (grub_term_register_input): Changed to inline function.
6703 (grub_term_register_output): Likewise.
6704 (grub_term_unregister_input): Likewise.
6705 (grub_term_unregister_output): Likewise.
6706 (grub_term_set_current_input): Likewise.
6707 (grub_term_set_current_output): Likewise.
6708 (grub_term_get_current_input): Likewise.
6709 (grub_term_get_current_output): Likewise.
6710 (grub_term_iterate_input): Removed.
6711 (grub_term_iterate_output): Likewise.
6712
6713 * kern/term.c (grub_term_list_input): Removed.
6714 (grub_term_list_output): Likewise.
6715 (grub_term_input_class): New variable.
6716 (grub_term_output_class): Likewise.
50fb7002 6717 (grub_cur_term_input): Change variable as macro.
71b9f361 6718 (grub_cur_term_output): Likewise.
6719 (grub_term_register_input): Removed.
6720 (grub_term_register_output): Likewise.
6721 (grub_term_unregister_input): Likewise.
6722 (grub_term_unregister_output): Likewise.
6723 (grub_term_set_current_input): Likewise.
6724 (grub_term_set_current_output): Likewise.
6725 (grub_term_iterate_input): Likewise.
6726 (grub_term_iterate_output): Likewise.
6727 (grub_term_get_current_input): Likewise.
6728 (grub_term_get_current_output): Likewise.
6729
6730 * util/grub-editenv.c: Include header file <grub/handler.h>.
6731 (grub_term_get_current_input): Removed.
6732 (grub_term_get_current_output): Likewise.
6733 (grub_term_input_class): New variable.
50fb7002 6734 (grub_term_output_class): Likewise.
71b9f361 6735
6736 * util/grub-fstest.c (grub_term_get_current_input): Removed.
6737 (grub_term_get_current_output): Likewise.
6738 (grub_term_input_class): New variable.
50fb7002 6739 (grub_term_output_class): Likewise.
71b9f361 6740
6741 * util/grub-probe.c (grub_term_get_current_input): Removed.
6742 (grub_term_get_current_output): Likewise.
6743 (grub_term_input_class): New variable.
50fb7002 6744 (grub_term_output_class): Likewise.
71b9f361 6745
6746 * util/i386/pc/grub-setup.c (grub_term_get_current_input): Removed.
6747 (grub_term_get_current_output): Likewise.
6748 (grub_term_input_class): New variable.
50fb7002 6749 (grub_term_output_class): Likewise.
71b9f361 6750
6751 * conf/common.rmk (pkglib_MODULES): Replace terminal with handler.
6752 (terminal_mod_SOURCES): Likewise.
6753 (terminal_mod_CFLAGS): Likewise.
6754 (terminal_mod_LDFLAGS): Likewise.
6755
6756 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace terminal.c with
6757 handler.c.
6758 (kernel_img_SOURCES): Add list.c and handler.c.
6759 (kernel_img_HEADERS): Add list.h and handler.h.
6760
6761 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
6762 handler.c.
6763 (kernel_mod_SOURCES): Add list.c and handler.c.
6764 (kernel_mod_HEADERS): Add list.h and handler.h.
6765
6766 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Replace terminal.c with
6767 handler.c.
6768 (kernel_elf_SOURCES): Add list.c and handler.c.
6769 (kernel_elf_HEADERS): Add list.h and handler.h.
6770
6771 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
6772 handler.c.
6773 (kernel_elf_SOURCES): Add list.c and handler.c.
6774 (kernel_elf_HEADERS): Add list.h and handler.h.
6775
6776 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Replace terminal.c with
6777 handler.c.
6778 (kernel_mod_SOURCES): Add list.c and handler.c.
6779 (kernel_mod_HEADERS): Add list.h and handler.h.
6780
6781 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace terminal.c with
6782 handler.c.
6783 (kernel_elf_SOURCES): Add list.c and handler.c.
6784 (kernel_elf_HEADERS): Add list.h and handler.h.
6785
8a31787f 67862009-02-27 Robert Millan <rmh@aybabtu.com>
6787
6788 Factorize elf32 / elf64 code in Multiboot loader. This will
6789 prevent it from getting out of sync again.
6790
6791 * loader/i386/multiboot.c (grub_multiboot_is_elf32,
6792 grub_multiboot_load_elf32, grub_multiboot_is_elf64,
6793 grub_multiboot_load_elf64): Move from here ...
6794 * loader/i386/multiboot_elfxx.c (grub_multiboot_is_elf,
6795 grub_multiboot_load_elf): ... to here (new file).
6796
51cd3dfc 67972009-02-27 Robert Millan <rmh@aybabtu.com>
6798
6799 * util/grub.d/10_linux.in: Rename "single-user mode" to
6800 "recovery mode".
6801
6e8c9c3a 68022009-02-27 Vladimir Serbinenko <phcoder@gmail.com>
6803
6804 Don't leak in SCSI code.
6805 * disk/scsi.c (grub_scsi_close): free `scsi'.
6806
4b6bf4f9 68072009-02-27 Robert Millan <rmh@aybabtu.com>
6808
6809 * loader/i386/pc/multiboot.c: Move from here ...
6810 * loader/i386/multiboot.c: ... to here. Update all users.
6811
b9413424 68122009-02-27 Robert Millan <rmh@aybabtu.com>
6813
6814 Patch from Alexandre Bique <bique.alexandre@gmail.com>
6815 * util/i386/pc/grub-setup.c (setup): Fix directory path.
6816
50fb7002 68172009-02-27 Krzysztof Smiechowicz <deadwood@wp.pl>
34519c3f 6818
6819 * fs/sfs.c (grub_sfs_read_extent): Correction to traversing extent
6820 b-tree.
6821
8cc50345 68222009-02-27 Robert Millan <rmh@aybabtu.com>
6823
6824 * kern/misc.c (grub_strtoull): Fix bug (it mistakenly parsed the
6825 `0x' qualifier as 0 when base is specified as parameter).
6826
6e09b8b7 68272009-02-24 Bean <bean123ch@gmail.com>
6828
6829 * configure.ac: Check for -mcmodel=large in x86_64 target.
6830
6831 * include/grub/efi/api.h (efi_call_10): New macro.
6832 (efi_wrap_10): New function.
6833
6834 * include/grub/efi/pe32.h (GRUB_PE32_REL_BASE_HIGH): New macro.
6835 (GRUB_PE32_REL_BASED_HIGH): Likewise.
6836 (GRUB_PE32_REL_BASED_LOW): Likewise.
6837 (GRUB_PE32_REL_BASED_HIGHLOW): Likewise.
6838 (GRUB_PE32_REL_BASED_HIGHADJ): Likewise.
6839 (GRUB_PE32_REL_BASED_MIPS_JMPADDR): Likewise.
6840 (GRUB_PE32_REL_BASED_SECTION): Likewise.
6841 (GRUB_PE32_REL_BASED_REL): Likewise.
6842 (GRUB_PE32_REL_BASED_IA64_IMM64): Likewise.
6843 (GRUB_PE32_REL_BASED_DIR64): Likewise.
6844 (GRUB_PE32_REL_BASED_HIGH3ADJ): Likewise.
6845
6846 * kern/x86_64/dl.c (grub_arch_dl_relocate_symbols): Fixed relocation
6847 issue.
6848
6849 * kern/x86_64/efi/callwrap.S (efi_wrap_6): Bug fix.
6850 (efi_wrap_10): New function.
6851
6852 * kern/x86_64/efi/startup.S (codestart): Use relative addressing.
6853
6854 * loader/efi/appleloader.c (devpath_5): Add support for late 2008
6855 MB/MBP model (NV chipset).
6856 (devdata_devs): Add devpath_5 to the list.
6857
6858 * load/i386/efi/linux.c (video_base): Remove variable.
6859 (RGB_MASK): New macro.
6860 (RGB_MAGIC): Likewise.
6861 (LINE_MIN): Likewise.
6862 (LINE_MAX): Likewise.
6863 (FBTEST_STEP): Likewise.
6864 (FBTEST_COUNT): Likewise.
6865 (fb_list): New variable.
6866 (grub_find_video_card): Remove function.
6867 (find_framebuf): New function.
6868 (grub_linux_setup_video): Use find_framebuf to get frame buffer and
6869 line length.
6870
6871 * util/i386/efi/grub-mkimage.c (grub_reloc_section): Fix relocation
6872 problem for x86_64.
6873
74b21bee 68742009-02-22 Vesa Jääskeläinen <chaac@nic.fi>
6875
6876 Patch #25624 by Kevin Lacquement <kevin@lacqui>.
6877
6878 * util/grub-mkconfig.in: Use ${grub_mkdevicemap} instead of hard
6879 coding tool name.
6880
a455f472 68812009-02-22 Robert Millan <rmh@aybabtu.com>
6882
6883 * include/multiboot.h (MULTIBOOT_INFO_ALIGN): New macro.
6884 * loader/i386/pc/multiboot.c (grub_multiboot): Include the MBI
6885 in our relocation, instead of using it directly from heap. Also
6886 use `MULTIBOOT_INFO_ALIGN' to ensure it is aligned.
6887
6374daf3 68882009-02-21 Robert Millan <rmh@aybabtu.com>
6889
6890 Implement USB keyboard support (based on patch by Marco Gerards)
6891
6892 * conf/i386-pc.rmk (pkglib_MODULES): Add `usb_keyboard.mod'.
6893 (usb_keyboard_mod_SOURCES, usb_keyboard_mod_CFLAGS)
6894 (usb_keyboard_mod_LDFLAGS): New variables.
6895
6896 * term/usb_keyboard.c: New file.
6897
8fa4ea70 68982009-02-14 Vladimir Serbinenko <phcoder@gmail.com>
6899
6900 Corrected wrong declaration
6901
6902 * kern/disk.c: corrected declaration of grub_disk_ata_pass_through.
6903
353976ac 69042009-02-14 Christian Franke <franke@computer.org>
6905
6906 * commands/lspci.c (grub_pci_classes): Add `SATA Controller'.
6907 (grub_lspci_iter): Print class code and programming interface byte.
6908
6aa1169b 69092009-02-14 Christian Franke <franke@computer.org>
6910
6911 * gendistlist.sh: Ignore `.svn' directories.
6912
265372ca 69132009-02-14 Felix Zielcke <fzielcke@z-51.de>
6914
6915 * fs/fat.c: Add 2009 to Copyright line.
6916
9ff516f3 69172009-02-14 Christian Franke <franke@computer.org>
6918
6919 * commands/hdparm.c: New file. Provides `hdparm' command
6920 which sends ATA commands via grub_disk_ata_pass_through ().
6921
6922 * conf/i386-pc.rmk: Add ata_pthru.mod and hdparm.mod.
6923
6924 * disk/ata.c: Include <grub/ata.h>. Move <grub/misc.h>
6925 and <grub/cpu/io.h> to include/grub/ata.h.
6926 (enum grub_ata_addressing_t): Move to include/grub/ata.h.
6927 (GRUB_CDROM_SECTOR_SIZE): Remove.
6928 (GRUB_ATA_*): Move to include/grub/ata.h.
6929 (GRUB_ATAPI_*): Likewise.
6930 (enum grub_ata_commands): Likewise.
6931 (enum grub_ata_timeout_milliseconds): Likewise.
6932 (struct grub_ata_device): Likewise.
6933 (grub_ata_regset): Likewise.
6934 (grub_ata_regget): Likewise.
6935 (grub_ata_regset2): Likewise.
6936 (grub_ata_regget2): Likewise.
6937 (grub_ata_check_ready): Likewise.
6938 (grub_ata_wait_not_busy): Remove static, exported in
6939 include/grub/ata.h.
6940 (grub_ata_wait_drq): Likewise.
6941 (grub_ata_pio_read): Likewise.
6942
6943 * disk/ata_pthru.c: New file. Provides grub_ata_pass_through ()
6944 function for hdparm.mod.
6945
6946 * include/grub/ata.h: New file, contains declarations from
6947 disk/ata.c.
6948 (enum grub_ata_commands): Add new commands for commands/hdparm.c.
6949
6950 * include/grub/disk.h (grub_disk_ata_pass_through_parms): New struct.
6951 (grub_disk_ata_pass_through): New exported variable.
6952
6953 * kern/disk.c (grub_disk_ata_pass_through): New variable.
6954
772e23da 69552009-02-13 Colin D Bennett <colin@gibibit.com>
6956
6957 Support multiple fallback entries, and provide an API to support
6958 executing default+fallback menu entries. Renamed the `terminal' menu
6959 viewer to `text'.
6960
6961 * include/grub/normal.h (grub_normal_text_menu_viewer): New global
6962 variable declaration.
6963 (grub_menu_execute_callback): New structure declaration.
6964 (grub_menu_execute_callback_t): New typedef.
6965 (grub_menu_execute_with_fallback): New function declaration.
6966 (grub_menu_get_entry): Likewise.
6967 (grub_menu_get_timeout): Likewise.
6968 (grub_menu_set_timeout): Likewise.
6969
6970 * normal/main.c (GRUB_MOD_INIT(normal)): Refer to new variable name.
6971
6972 * normal/menu.c (grub_wait_after_message): Moved to
6973 `normal/menu_text.c'.
6974 (draw_border): Likewise.
6975 (print_message): Likewise.
6976 (print_entry): Likewise.
6977 (print_entries): Likewise.
6978 (grub_menu_init_page): Likewise.
6979 (get_entry_number): Likewise.
6980 (print_timeout): Likewise.
6981 (run_menu): Likewise.
6982 (grub_menu_execute_entry): Likewise.
6983 (show_text_menu): Likewise.
6984 (get_and_remove_first_entry_number): New function.
6985 (grub_menu_execute_with_fallback): Likewise.
6986 (get_entry): Renamed to ...
6987 (grub_menu_get_entry): .. this and made it global.
6988 (get_timeout): Renamed to ...
6989 (grub_menu_get_timeout): ... this and made it global.
6990 (set_timeout): Renamed to ...
6991 (grub_menu_set_timeout): ... this and made it global.
6992 (grub_normal_terminal_menu_viewer): Renamed to ...
6993 (grub_normal_text_menu_viewer): ... this.
6994
6995 * normal/menu_text.c: New file. Extracted text-menu-specific code
6996 from normal/menu.c.
6997
6998 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add `normal/menu_text.c'.
6999 (normal_mod_SOURCES): Likewise.
7000
7001 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
7002 (normal_mod_SOURCES): Likewise.
7003
7004 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7005 (normal_mod_SOURCES): Likewise.
7006
7007 * conf/i386-pc.rmk, (grub_emu_SOURCES): Likewise.
7008 (normal_mod_SOURCES): Likewise.
7009
7010 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7011 (normal_mod_SOURCES): Likewise.
7012
7013 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7014 (normal_mod_SOURCES): Likewise.
7015
7016 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
7017 (normal_mod_SOURCES): Likewise.
7018
16ac430e 70192009-02-11 Robert Millan <rmh@aybabtu.com>
7020
7021 * util/grub.d/00_header.in: Update old reference to `font' command.
7022
06ff20fc 70232009-02-10 Felix Zielcke <fzielcke@z-51.de>
7024
7025 * fs/fat.c (grub_fat_mount): Fix wrong comparison.
7026
7027 Based on patch from Javier Martín.
7028
96da9407 70292009-02-09 Felix Zielcke <fzielcke@z-51.de>
7030
7031 * conf/common.rmk (grub_probe_SOURCES): Move fs/ext2.c before fs/fat.c
50fb7002 7032 to avoid false positives with FAT.
96da9407 7033 (grub_fstest_SOURCES): Likewise.
7034 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
7035 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
7036 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7037 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
7038 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7039 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7040
6dca6fe4 70412009-02-09 Felix Zielcke <fzielcke@z-51.de>
7042
06ff20fc 7043 * fs/fat.c (grub_fat_mount): Try to avoid false positives by checking
6dca6fe4 7044 bpb.version_specific.fat12_or_fat16.fstype and
7045 bpb.version_specific.fat32.fstype.
7046
2550c62f 70472009-02-08 Robert Millan <rmh@aybabtu.com>
7048
be110b30 7049 * fs/tar.c: Replace "fs/cpio.c" with "cpio.c".
2550c62f 7050
56978920 70512009-02-08 Robert Millan <rmh@aybabtu.com>
7052
7053 * Makefile.in (host_os, host_cpu): New variables.
7054 (target_os): Remove. Update all users.
7055
d64399b5 70562009-02-08 Marco Gerards <marco@gnu.org>
7057
7058 * Makefile.in (enable_grub_emu_usb): New variable.
7059 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/scsi.c'.
7060 (grub_emu_SOURCES) [grub_emu_SOURCES]: Add `disk/usbms.c',
7061 `util/usb.c', `bus/usb/usb.c' and `commands/usbtest.c'.
7062 (grub_emu_LDFLAGS): Add `$(LIBUSB)'.
7063 (pkglib_MODULES): Add `usb.mod', `uhci.mod', `ohci.mod',
7064 `usbtest.mod' and `usbms.mod'.
7065 (usb_mod_SOURCES, usb_mod_CFLAGS, usb_mod_LDFLAGS)
7066 (usbtest_mod_SOURCES, usbtest_mod_CFLAGS, usbtest_mod_LDFLAGS)
7067 (uhci_mod_SOURCES, uhci_mod_CFLAGS, uhci_mod_LDFLAGS,
7068 (ohci_mod_SOURCES, ohci_mod_CFLAGS, ohci_mod_LDFLAGS)
7069 (usbms_mod_SOURCES, usbms_mod_CFLAGS, usbms_mod_LDFLAGS): New
7070 variables.
7071
7072 * disk/usbms.c: New file.
7073
7074 * include/grub/usb.h: Likewise.
7075
7076 * include/grub/usbtrans.h: Likewise.
7077
7078 * include/grub/usbdesc.h: Likewise.
7079
7080 * bus/usb/usbtrans.c: Likewise.
7081
7082 * bus/usb/ohci.c: Likewise.
7083
7084 * bus/usb/uhci.c: Likewise.
7085
7086 * bus/usb/usbhub.c: Likewise.
7087
7088 * bus/usb/usb.c: Likewise.
7089
7090 * commands/usbtest.c: Likewise.
7091
7092 * util/usb.c: Likewise.
50fb7002 7093
d64399b5 7094 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_IO'.
7095
7096 * configure.ac: Test for libusb presence.
50fb7002 7097
d64399b5 7098 * util/grub-emu.c (main) [HAVE_LIBUSB_H]: Call `grub_libusb_init'.
7099
2b40d6bb 71002009-02-08 Vesa Jääskeläinen <chaac@nic.fi>
7101
7102 * kern/mm.c: Add more comments.
7103
73a4ce81 71042009-02-08 Robert Millan <rmh@aybabtu.com>
7105
7106 Patch from Javier Martín.
7107 * fs/ext2.c (EXT2_DRIVER_SUPPORTED_INCOMPAT): Add
7108 `EXT4_FEATURE_INCOMPAT_FLEX_BG'.
7109
f821ce59 71102009-02-08 Robert Millan <rmh@aybabtu.com>
7111
7112 * fs/cpio.c: Split tar functionality to ...
7113 * fs/tar.c: ... here (new file). Update all users.
7114
aebfc4b0 71152009-02-07 Robert Millan <rmh@aybabtu.com>
7116
7117 * fs/ext2.c (grub_ext2_mount): Avoid mounting filesystems with
7118 backward-incompatible features.
7119
7120 Based on patch from Javier Martín, with some adjustments.
7121
50fb7002 71222009-02-07 Michael Scherer <misc@mandriva.org>
cea15bca 7123
7124 * fs/hfs.c (grub_hfsplus_iterate_dir): Treat hfs+ as case insensitive.
7125
0bb5115e 71262009-02-07 Robert Millan <rmh@aybabtu.com>
7127
7128 * conf/common.rmk (grub_probe_SOURCES, grub_fstest_SOURCES): Move
7129 position of `disk/lvm.c' to ensure grub_init_all() always picks it
7130 after the RAID stuff.
7131
38a0f8e7 71322009-02-05 Vesa Jääskeläinen <chaac@nic.fi>
7133
50fb7002 7134 Fixes problem when running vbetest command as reported by
38a0f8e7 7135 Vladimir Serbinenko <phcoder@gmail.com>.
7136
7137 * (grub_vbe_set_video_mode): Fixed problem with text modes.
7138
3143cc1c 71392009-02-04 Felix Zielcke <fzielcke@z-51.de>
7140
7141 util/getroot.c (grub_util_get_grub_dev): Add support for /dev/mdNpN and
7142 /dev/md/NpN style mdraid devices.
7143
9cba6fce 71442009-02-03 Felix Zielcke <fzielcke@z-51.de>
7145
7146 * util/unifont2pff.rb: Remove.
7147
e507a2c1 71482009-02-03 Felix Zielcke <fzielcke@z-51.de>
7149
7150 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add a missing trailing
7151 `#'.
7152
d2c2b4cd 71532009-02-03 Felix Zielcke <fzielcke@z-51.de>
7154
7155 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/menu_viewer.c'.
7156 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
7157 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
7158 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Likewise.
7159 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7160 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7161 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
7162
b4315fb0 71632009-02-02 Christian Franke <franke@computer.org>
7164
7165 * lib/hexdump.c (hexdump): Print at most 3 lines if data is identical.
7166
de3aa260 71672009-02-01 Felix Zielcke <fzielcke@z-51.de>
7168
7c3ff286 7169 * INSTALL: Note that we now require at least autoconf 2.59 and
7170 that LZO is optional.
de3aa260 7171
825a182b 71722009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
7173
7174 Base on patch on bug #24154 created by Tomas Tintera
7175 <trosos@seznam.cz>.
7176
7177 * video/i386/pc/vbe.c (grub_video_vbe_scroll): Fix downward scrolling.
7178
a69ef770 71792009-02-01 Vesa Jääskeläinen <chaac@nic.fi>
7180
7c3ff286 7181 Based on patch on bug #25318 created by Bernhard Rosenkraenzer
a69ef770 7182 <bero@arklinux.org>.
7183
7184 * normal/parser.y (script_init): Add missing semicolon.
7185
6fa42fa6 71862009-01-31 Colin D Bennett <colin@gibibit.com>
7187
7c3ff286 7188 * normal/main.c: Add include to grub/menu_viewer.h.
6fa42fa6 7189 (free_menu_entry_classes): Added.
7190 (grub_normal_menu_addentry): Added class property handling.
7191 (grub_normal_execute): Changed to use new menu viewer for menu viewing.
7192 (GRUB_MOD_INIT(normal)): Added register for text based menu viewer.
7193
7194 * normal/menu_viewer.c: New file.
7195
7196 * normal/menu.c (run_menu_entry): Renamed to ...
7197 (grub_menu_execute_entry): ... this and made it as global.
7198 (grub_menu_run): Renamed to ...
7199 (show_text_menu): ... this and made it local.
7200 (show_text_menu): Adapt to new function names.
7201 (grub_normal_terminal_menu_viewer): New global variable.
7202
7203 * include/grub/menu.h: New file.
7204
7205 * include/grub/menu_viewer.h: New file.
7206
7207 * include/grub/normal.h: Added include to grub/menu.h.
7208 (grub_menu_entry): Moved to include/grub/menu.h.
7209 (grub_menu_entry_t): Likewise.
7210 (grub_menu): Likewise.
7211 (grub_menu_t): Likewise.
7212 (grub_normal_terminal_menu_viewer): Added.
7213 (grub_menu_execute_entry): Likewise.
7214 (grub_menu_run): Removed.
7215
7216 * DISTLIST: Added include/grub/menu.h.
7217 Added include/grub/menu_viewer.h.
7218 Added normal/menu_viewer.c.
7219
72202009-01-31 Vesa Jääskeläinen <chaac@nic.fi>
7221
7222 * normal/execute.c (grub_script_execute_menuentry): Changed to use
7223 arglist for menutitle arguments.
7224
7225 * normal/main.c (grub_normal_menu_addentry): Likewise.
7226
7227 * normal/parser.y (menuentry): Likewise.
7228
7229 * normal/script.c (grub_script_create_cmdmenu): Likewise.
7230
7231 * include/grub/script.h (grub_script_cmd_menuentry): Likewise.
7232 (grub_script_create_cmdmenu): Likewise.
7233
7234 * include/grub/normal.h (grub_normal_menu_addentry): Likewise.
7235
7236 * conf/i386-pc.rmk (normal_mod_SOURCES): Adapt Colin D Bennett's
7237 changes.
7238
7239 * conf/x86_64-efi.rmk (normal_mod_SOURCES): Likewise.
7240
7241 * conf/i386-coreboot.rmk (normal_mod_SOURCES): Likewise.
7242
7243 * conf/i386-efi.rmk (normal_mod_SOURCES): Likewise.
7244
7245 * conf/i386-ieee1275.rmk (normal_mod_SOURCES): Likewise.
7246
7247 * conf/powerpc-ieee1275.rmk (normal_mod_SOURCES): Likewise.
7248
7249 * conf/sparc64-ieee1275.rmk (normal_mod_SOURCES): Likewise.
7250
56192c23 72512009-01-30 Christian Franke <franke@computer.org>
7252
7253 * normal/arg.c (grub_arg_show_help): Add indentation if '\n' appears
7254 in option help text.
7255
d72521b3 72562009-01-27 Pavel Roskin <proski@gnu.org>
7257
7258 * disk/fs_uuid.c (search_fs_uuid): Ignore case of the UUID.
7259
994b5e84 72602009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
7261
7262 * commands/lsmmap.c: Add include to grub/machine/memory.h.
7263
7264 * fs/i386/pc/pxe.c (grub_pxefs_open): Fix sign problem.
7265
7266 * term/i386/pc/at_keyboard.c (GRUB_MOD_FINI(at_keyboard)): Use proper
7267 unregister function.
7268
6a7eab2c 72692009-01-27 Vesa Jääskeläinen <chaac@nic.fi>
7270
7271 * disk/scsi.c (grub_scsi_read): Fix sign problem.
7272
7273 * term/i386/pc/vga_text.c (grub_vga_text_init_fini). Fix declaration.
7274
7275 * util/grub-mkfont.c (usage): Fix typo.
7276
7277 * util/elf/grub-mkimage.c (load_modules): Fix warning.
7278
1806b56e 72792009-01-26 Daniel Mierswa <impulze@impulze.org>
7280
3fb18f09 7281 * fs/fat.c (grub_fat_uuid): Fix shift of the first two bytes.
7282
336e1fb9 7283 * commands/search.c (search_fs_uuid): Ignore case of the UUID.
7284
1806b56e 7285 * kern/misc.c (grub_strcasecmp): New function.
7286 (grub_strcasecmp): Use grub_size_t instead of int for length.
7287 Fix return value.
7288 * include/grub/misc.h: Update function prototypes.
7289
580b2a0f 72902009-01-26 Robert Millan <rmh@aybabtu.com>
7291
7292 * configure.ac: Fix cross-compilation check.
ef257b36 7293
d31c24f1 72942009-01-22 Christian Franke <franke@computer.org>
7295
7296 * kern/misc.c (grub_vsprintf): Fix size and termination of `format2'
7297 (precision) digit string. Allow `.format2' without `format1' (width).
7298 Limit input chars for `%s' output to `format2' if specified. This is
7299 compatible with standard printf ().
7300
3138b44c 73012009-01-22 Christian Franke <franke@computer.org>
7302
7303 * disk/ata.c (grub_ata_wait_status): Replace by ...
7304 (grub_ata_wait_not_busy): ... this function. Checks only BSY bit,
7305 other status bits may be invalid while BSY is asserted.
7306 (grub_ata_check_ready): New function.
7307 (grub_ata_cmd): Removed.
7308 (grub_ata_wait_drq): New function.
7309 (grub_ata_strncpy): Remove inline.
7310 (grub_ata_pio_read): Reduce to actual block transfer. BSY wait
7311 and error check now done by grub_ata_wait_drq ().
7312 (grub_ata_pio_write): Likewise.
7313 (grub_atapi_identify): Set DEV before check for !BSY. Use
7314 grub_ata_wait_drq () to wait for data.
7315 (grub_ata_device_initialize): Add status register check to
7316 detect missing SATA slave devices. Add debug messages.
7317 (grub_atapi_wait_drq): Use grub_ata_wait_not_busy ().
7318 (grub_atapi_packet): Set DEV before check for !BSY. Replace
7319 transfer loop by grub_ata_pio_write ().
7320 (grub_ata_identify): Set DEV before check for !BSY. Use
7321 grub_ata_wait_drq () to wait for data.
ef257b36 7322 (grub_ata_setaddress): Set DEV before check for !BSY.
3138b44c 7323 (grub_ata_readwrite): Remove duplicate code, handle batch/rest and
7324 read/write in one loop. Fix invalid command on write. Fix incomplete
7325 command on (size % batch) == 0. Add missing error check after write of
7326 last block. Add debug messages.
7327 (grub_atapi_read): Replace transfer loop by grub_ata_pio_read ().
7328
59a64ef6 73292009-01-19 Christian Franke <franke@computer.org>
7330
7331 * disk/ata.c (GRUB_ATAPI_REG_*): New defines.
7332 (GRUB_ATAPI_IREASON_*): Likewise.
7333 (grub_ata_pio_write): Fix timeout error return.
7334 (grub_atapi_identify): Add grub_ata_wait () after cmd.
7335 (grub_atapi_wait_drq): New function.
7336 (grub_atapi_packet): New parameter `size'.
7337 Use grub_atapi_wait_drq () and direct write instead of
7338 grub_ata_pio_write ().
7339 (grub_atapi_read): Replace grub_ata_pio_read () by a loop which
7340 reads the number of bytes requested by the device for each DRQ
7341 assertion.
7342 (grub_atapi_write): Remove old implementation, return not
7343 implemented instead.
7344
1cfe20b3 73452009-01-19 Christian Franke <franke@computer.org>
7346
7347 * disk/scsi.c (grub_scsi_read10): Use scsi->blocksize instead
7348 of 512 to calculate data size.
7349 (grub_scsi_read12): Likewise.
7350 (grub_scsi_write10): Likewise.
7351 (grub_scsi_write12): Likewise.
7352 (grub_scsi_read): Adjust size according to blocksize.
7353 Add checks for invalid blocksize and unaligned transfer.
7354
bee5fe5d 73552009-01-19 Vesa Jääskeläinen <chaac@nic.fi>
7356
7357 * font/font.c (grub_font_loader_init): Re-position unknown glyph.
7358
ef257b36 7359 * term/gfxterm.c (write_char): Fix background rendering for wide
bee5fe5d 7360 width glyphs.
7361
3e643f8c 73622009-01-19 Robert Millan <rmh@aybabtu.com>
7363
7364 * config.guess: Update to latest version from config git.
7365 * config.sub: Likewise.
7366
4fa80998 73672009-01-17 Felix Zielcke <fzielcke@z-51.de>
7368
7369 * Makefile.in: Change font compilation to use new grub-mkfont instead
7370 of java version.
7371
7372 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: Remove.
7373 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
7374 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
7375 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
7376 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
7377 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
7378 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
7379 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
7380 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
7381
7086085b 73822009-01-16 Christian Franke <franke@computer.org>
7383
7384 * disk/ata.c (enum grub_ata_commands): Remove EXEC_DEV_DIAGNOSTICS.
7385 (enum grub_ata_timeout_milliseconds): New enum.
7386 (grub_ata_wait_status): Add parameter milliseconds.
7387 (grub_ata_cmd): Remove variable `err'. Remove wait for !DRQ to allow
7388 recovery from timed-out commands.
7389 (grub_ata_pio_read): Add parameter milliseconds. Fix error return,
7390 return grub_errno instead of REG_ERROR.
7391 (grub_ata_pio_write): Add parameter milliseconds.
7392 (grub_atapi_identify): Fix size of ATAPI IDENTIFY sector.
7393 Pass milliseconds to grub_ata_wait_status () and
7394 grub_ata_pio_read ().
7395 (grub_atapi_packet): Pass milliseconds to grub_ata_pio_write ().
7396 (grub_ata_identify): Remove variable `ataerr'. Pass milliseconds to
7397 grub_ata_wait_status (). Fix IDENTIFY timeout check.
7398 (grub_ata_device_initialize): Remove EXECUTE DEVICE DIAGNOSTICS.
7399 It is not suitable for device detection, because DEV bit is ignored,
7400 the command may run too long, and not all devices set the signature
7401 properly.
7402 (grub_ata_pciinit): Clear grub_errno before grub_ata_device_initialize ().
7403 (grub_ata_setaddress): Pass milliseconds to grub_ata_wait_status ().
7404 Fix device selection, DEV bit must be set first to address the registers
7405 of the correct device.
7406 (grub_ata_readwrite): Pass milliseconds to grub_ata_wait_status () and
7407 grub_ata_pio_read/write ().
7408 (grub_atapi_read): Pass milliseconds to grub_ata_pio_read ().
7409 (grub_atapi_write): Pass milliseconds to grub_ata_pio_write ().
7410
4a412913 74112009-01-13 Carles Pina i Estany <carles@pina.cat>
7412
7413 * util/grub-editenv.c (main): Use fseeko(), not fseek().
7414
7795c55e 74152009-01-13 Bean <bean123ch@gmail.com>
d913988c 7416
7417 * util/grub-mkfont.c (write_font): forget to remove some debug code.
7418
7795c55e 74192009-01-13 Bean <bean123ch@gmail.com>
e52db1f7 7420
7421 * Makefile.in: (enable_grub_mkfont): New variable.
7422 (freetype_cflags): Likewise.
7423 (freetype_libs): Likewise.
7424
7425 * common.rmk (bin_UTILITIES): Add `grub-mkfont' if requested.
7426 (grub_mkfont_SOURCES): New variable.
7427 (grub_mkfont_CFLAGS): Likewise.
7428 (grub_mkfont_LDFLAGS): Likewise.
7429
7430 * configure.ac (--enable-grub-mkfont): New option. Check for freetype2
7431 library if `--enable-grub-mkfont' is requested.
7432 (enable_grub_mkfont): New variable.
7433 (freetype_cflags): Likewise.
7434 (freetype_libs): Likewise.
7435
7436 * util/grub-mkfont.c: New file.
7437
093af1fe 74382009-01-12 Christian Franke <franke@computer.org>
7439
7440 * disk/ata.c (grub_ata_pciinit): Fix bit numbers of compatibility
7441 mode check. Fix setting of compat_use[].
7442
f36cc108 74432009-01-10 Robert Millan <rmh@aybabtu.com>
7444
7445 Update a few copyright years which we forgot to do in 2008 (only for
7446 files whose changes made in 2008 were copyright-significant)
7447
7448 * Makefile.in: Add 2008 to Copyright line.
7449 * disk/ieee1275/ofdisk.c: Likewise.
7450 * disk/efi/efidisk.c: Likewise.
7451 * kern/dl.c: Likewise.
7452 * kern/sparc64/ieee1275/init.c: Likewise.
7453 * kern/mm.c: Likewise.
7454 * kern/efi/mm.c: Likewise.
7455 * boot/i386/pc/boot.S: Likewise.
7456 * genfslist.sh: Likewise.
7457 * fs/iso9660.c: Likewise.
7458 * fs/hfs.c: Likewise.
7459 * fs/jfs.c: Likewise.
7460 * fs/minix.c: Likewise.
7461 * fs/ufs.c: Likewise.
7462 * gensymlist.sh.in: Likewise.
7463 * genkernsyms.sh.in: Likewise.
7464 * include/grub/misc.h: Likewise.
7465 * include/grub/types.h: Likewise.
7466 * include/grub/symbol.h: Likewise.
7467 * include/grub/elf.h: Likewise.
7468 * include/grub/kernel.h: Likewise.
7469 * include/grub/disk.h: Likewise.
7470 * include/grub/dl.h: Likewise.
7471 * include/grub/i386/linux.h: Likewise.
7472 * include/grub/i386/pc/biosdisk.h: Likewise.
7473 * include/grub/efi/api.h: Likewise.
7474 * include/grub/efi/pe32.h: Likewise.
7475 * include/grub/util/misc.h: Likewise.
7476 * normal/execute.c: Likewise.
7477 * normal/arg.c: Likewise.
7478 * normal/completion.c: Likewise.
7479 * normal/lexer.c: Likewise.
7480 * normal/parser.y: Likewise.
7481 * normal/misc.c: Likewise.
7482 * commands/i386/pc/vbeinfo.c: Likewise.
7483 * commands/hexdump.c: Likewise.
7484 * commands/terminal.c: Likewise.
7485 * commands/ls.c: Likewise.
7486 * commands/help.c: Likewise.
7487 * partmap/pc.c: Likewise.
7488 * loader/efi/chainloader.c: Likewise.
7489 * loader/multiboot_loader.c: Likewise.
7490 * loader/i386/pc/multiboot2.c: Likewise.
7491 * term/efi/console.c: Likewise.
7492 * term/i386/pc/serial.c: Likewise.
7493 * util/lvm.c: Likewise.
7494 * util/console.c: Likewise.
7495 * util/i386/efi/grub-mkimage.c: Likewise.
7496 * util/raid.c: Likewise.
7497
7f02114b 74982009-01-06 Vesa Jääskeläinen <chaac@nic.fi>
7499
7500 * commands/videotest.c: Removed include to grub/machine/memory.h.
7501
7502 * conf/i386-pc.rmk (pkglib_MODULES): Removed video.mod, gfxterm.mod,
7503 videotest.mod, bitmap.mod, tga.mod, jpeg.mod, png.mod.
7504 (video_mod_SOURCES): Removed.
7505 (video_mod_CFLAGS): Likewise.
7506 (video_mod_LDFLAGS): Likewise.
7507 (gfxterm_mod_SOURCES): Likewise.
7508 (gfxterm_mod_CFLAGS): Likewise.
7509 (gfxterm_mod_LDFLAGS): Likewise.
7510 (videotest_mod_SOURCES): Likewise.
7511 (videotest_mod_CFLAGS): Likewise.
7512 (videotest_mod_LDFLAGS): Likewise.
7513 (bitmap_mod_SOURCES): Likewise.
7514 (bitmap_mod_CFLAGS): Likewise.
7515 (bitmap_mod_LDFLAGS): Likewise.
7516 (tga_mod_SOURCES): Likewise.
7517 (tga_mod_CFLAGS): Likewise.
7518 (tga_mod_LDFLAGS): Likewise.
7519 (jpeg_mod_SOURCES): Likewise.
7520 (jpeg_mod_CFLAGS): Likewise.
7521 (jpeg_mod_LDFLAGS): Likewise.
7522 (png_mod_SOURCES): Likewise.
7523 (png_mod_CFLAGS): Likewise.
7524 (png_mod_LDFLAGS): Likewise.
7525
7526 * conf/common.rmk (pkglib_MODULES): Added video.mod, videotest.mod,
7527 bitmap.mod, tga.mod, jpeg.mod, png.mod, font.mod, gfxterm.mod
7528 (video_mod_SOURCES): Added.
7529 (video_mod_CFLAGS): Likewise.
7530 (video_mod_LDFLAGS): Likewise.
7531 (videotest_mod_SOURCES): Likewise.
7532 (videotest_mod_CFLAGS): Likewise.
7533 (videotest_mod_LDFLAGS): Likewise.
7534 (bitmap_mod_SOURCES): Likewise.
7535 (bitmap_mod_CFLAGS): Likewise.
7536 (bitmap_mod_LDFLAGS): Likewise.
7537 (tga_mod_SOURCES): Likewise.
7538 (tga_mod_CFLAGS): Likewise.
7539 (tga_mod_LDFLAGS): Likewise.
7540 (jpeg_mod_SOURCES): Likewise.
7541 (jpeg_mod_CFLAGS): Likewise.
7542 (jpeg_mod_LDFLAGS): Likewise.
7543 (png_mod_SOURCES): Likewise.
7544 (png_mod_CFLAGS): Likewise.
7545 (png_mod_LDFLAGS): Likewise.
7546 (gfxterm_mod_SOURCES): Likewise.
7547 (gfxterm_mod_CFLAGS): Likewise.
7795c55e 7548 (gfxterm_mod_LDFLAGS): Likewise.
7f02114b 7549
7550 * term/gfxterm.c: Removed include to grub/machine/memory.h,
7551 grub/machine/console.h.
7552
644fff97 75532009-01-04 Jerone Young <jerone@gmail.com>
7554
7555 Make on screen instructions clearer
7556
7557 Based on patch created by Jidanni <jidanni@jidanni.org>
7558
7559 * normal/menu.c: print clearer instructions on the screen
7560
1e901a75 75612009-01-02 Colin D Bennett <colin@gibibit.com>
7562
7563 New font engine.
34c44600 7564
1e901a75 7565 Additional changes by Vesa Jääskeläinen <chaac@nic.fi> to adapt to
7566 build system and fixed gfxterm.c to work with different sized fonts.
7567
7568 * configure.ac: Changed UNIFONT_HEX to UNIFONT_BDF.
34c44600 7569
1e901a75 7570 * configure: Re-generated.
34c44600 7571
1e901a75 7572 * DISTLIST: Removed font/manager.c.
7573 Added font/font.c.
7574 Added font/font_cmd.c.
34c44600 7575
1e901a75 7576 * Makefile.in: Changed UNIFONT_HEX to UNIFONT_BDF. Added Font tool
7577 compilation.
34c44600 7578
1e901a75 7579 * include/grub/misc.h (grub_utf8_to_ucs4): Changed prototype. Changed users.
34c44600 7580
7581 * kern/misc.c (grub_utf8_to_ucs4): Changed prototype.
1e901a75 7582
7583 * kern/term.c: Changed users of grub_utf8_to_ucs4.
34c44600 7584
1e901a75 7585 * normal/menu.c: Likewise.
34c44600 7586
1e901a75 7587 * conf/common.rmk (font_mod_SOURCES): Removed font/manager.c.
7588 (font_mod_SOURCES): Added font/font_cmd.c, font/font.c.
34c44600 7589
1e901a75 7590 * include/grub/font.h: Replaced with new file.
34c44600 7591
1e901a75 7592 * include/grub/video.h (GRUB_VIDEO_MODE_TYPE_ALPHA): Changed value.
7593 (GRUB_VIDEO_MODE_TYPE_DOUBLE_BUFFERED): Likewise.
7594 (GRUB_VIDEO_MODE_TYPE_COLOR_MASK): Likewise.
7595 (GRUB_VIDEO_MODE_TYPE_1BIT_BITMAP): Added.
7596 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_1BIT_PACKED.
34c44600 7597 (grub_video_mode_info): Added bg_red, bg_green, bg_blue, bg_alpha,
1e901a75 7598 fg_red, fg_green, fg_blue, fg_alpha.
7599 (grub_video_adapter): Removed blit_glyph.
34c44600 7600 (grub_video_blit_glyph): Removed.
7601
1e901a75 7602 * font/manager.c: Removed file.
34c44600 7603
7604 * font/font.c: New file.
7605
1e901a75 7606 * font/font_cmd.c: Likewise.
34c44600 7607
1e901a75 7608 * video/video.c (grub_video_blit_glyph): Removed.
34c44600 7609
1e901a75 7610 * video/i386/pc/vbe.c (grub_video_vbe_map_rgb): Added 1-bit support.
7611 (grub_video_vbe_map_rgba): Likewise.
7612 (grub_video_vbe_unmap_color_int): Likewise.
7613 (grub_video_vbe_blit_glyph): Removed.
7614 (grub_video_vbe_adapter): Removed blit_glyph.
34c44600 7615
1e901a75 7616 * video/i386/pc/vbeutil.c (get_data_ptr): Added 1-bit support.
7617 (get_pixel): Likewise.
34c44600 7618 (set_pixel): Likewise.
7619
1e901a75 7620 * commands/videotest.c (grub_cmd_videotest): Added more tests for fonts.
34c44600 7621
1e901a75 7622 * term/gfxterm.c: Adapted to new font engine.
34c44600 7623
1e901a75 7624 * term/i386/pc/vesafb.c: Marked as deprecated. Made it compile.
34c44600 7625
1e901a75 7626 * term/i386/pc/vga.c: Likewise.
34c44600 7627
1e901a75 7628 * util/fonttool/src/org/gnu/grub/fonttool/BDFLoader.java: New file.
34c44600 7629
1e901a75 7630 * util/fonttool/src/org/gnu/grub/fonttool/CharDefs.java: Likewise.
34c44600 7631
1e901a75 7632 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
34c44600 7633
1e901a75 7634 * util/fonttool/src/org/gnu/grub/fonttool/CharacterRange.java: Likewise.
34c44600 7635
1e901a75 7636 * util/fonttool/src/org/gnu/grub/fonttool/Converter.java: Likewise.
34c44600 7637
1e901a75 7638 * util/fonttool/src/org/gnu/grub/fonttool/Font.java: Likewise.
34c44600 7639
1e901a75 7640 * util/fonttool/src/org/gnu/grub/fonttool/Glyph.java: Likewise.
34c44600 7641
1e901a75 7642 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Sections.java: Likewise.
34c44600 7643
1e901a75 7644 * util/fonttool/src/org/gnu/grub/fonttool/PFF2Writer.java: Likewise.
7645
7646 * util/grub.d/00_header.in: Changed to use new loadfont command.
34c44600 7647
1e901a75 7648 * util/grub-mkconfig_lib.in: Changed font extension.
7649
278922e8 76502008-12-28 Felix Zielcke <fzielcke@z-51.de>
7651
7652 * util/getroot.c (grub_util_get_grub_dev): Add support for
7653 /dev/md/dNNpNN style partitionable mdraid devices.
7654
3ced05cf 76552008-12-12 Alex Smith <alex@alex-smith.me.uk>
7656
7657 * fs/i386/pc/pxe.c (grub_pxefs_open): Handle the one open connection
7658 at a time limit of the PXE TFTP API correctly.
7659 (grub_pxefs_close): Likewise.
7660
7fd0ee30 76612008-11-29 Robert Millan <rmh@aybabtu.com>
7662
34c44600 7663 * disk/ata.c (grub_ata_pciinit): Handle errors raised by
7fd0ee30 7664 grub_ata_device_initialize() calls.
7665
34c44600 76662008-11-28 Krzysztof Smiechowicz <deadwood@wp.pl>
0c5e79ab 7667
7668 * fs/affs.c (grub_affs_iterate_dir): Return failure when directory
7669 iteration failed.
7670 * fs/sfs.c (grub_sfs_iterate_dir): Likewise.
7671
89313780 76722008-11-28 Robert Millan <rmh@aybabtu.com>
7673
7674 Fix build on powerpc-ieee1275. Based on patch created by
7675 Manoel Abranches <mrabran@linux.vnet.ibm.com>.
7676 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
7677 `kern/ieee1275/mmap.c'.
7678 * include/grub/powerpc/ieee1275/memory.h: New file.
7679
15257703 7680 Provide grub-install on coreboot.
7681 * conf/i386-coreboot.rmk (sbin_SCRIPTS): Add `grub-install'.
7682 (grub_install_SOURCES): New variable.
7683 * util/i386/pc/grub-install.in: Add a few condition checks to make it
7684 usable on coreboot.
7685
9fc5388a 76862008-11-25 Felix Zielcke <fzielcke@z-51.de>
7687
7688 * util/grub-fstest.c (grub_term_get_current_input): Change return type
7689 to `grub_term_input_t'.
7690 (grub_term_get_current_output): Change return type to
7691 `grub_term_output_t'.
7692
bc3a2f31 76932008-11-22 Robert Millan <rmh@aybabtu.com>
7694
34c44600 7695 Fix breakage on coreboot due to declaration mismatch.
bc3a2f31 7696 * term/i386/pc/vga_text.c (grub_vga_text_init_fini): New function.
7697 (grub_vga_text_term): Use grub_vga_text_init_fini() instead of
7698 grub_vga_text_cls().
7699
80fc88f2 7700 * kern/i386/loader.S (grub_multiboot_backward_relocator): Improve
34c44600 7701 comments. Avoid copying one more byte than necessary (just in case).
80fc88f2 7702
cbf36fd3 7703 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Change link address
7704 to 0x200000 (avoids trouble with some OFW implementations, and matches
7705 with the one in Yaboot).
7706 Reported by Manoel Abranches
7707
73e8e268 77082008-11-20 Robert Millan <rmh@aybabtu.com>
3cf6ac19 7709
7710 * kern/i386/coreboot/init.c (grub_time_tics): Remove variable.
7711 (grub_get_rtc, grub_exit): Abort with grub_fatal() if called.
7712
73e8e268 7713 * util/grub-mkconfig_lib.in (grub_warn): New function.
7714 (convert_system_path_to_grub_path): Use grub_warn() when issuing
7715 warnings, to obtain consistent formatting.
7716 * util/grub.d/00_header.in: Likewise.
7717 * util/update-grub_lib.in: Likewise.
7718
e94045a1 7719 * loader/i386/linux.c (allocate_pages): Fix a warning.
40f9faa4 7720 Move comment text to `#error' stanza.
e94045a1 7721
79d29fd7 7722 Harmonize ieee1275's grub_available_iterate() with the generic
7723 grub_machine_mmap_iterate() interface (fixes a recently-introduced
7724 build problem on i386-ieee1275):
7725 * kern/ieee1275/openfw.c (grub_available_iterate): Moved from here ...
7726 * kern/ieee1275/mmap.c (grub_machine_mmap_iterate): ... here. Add third
7727 parameter `type'. Update all users of this function.
7728 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
7729 `kern/ieee1275/mmap.c'.
7730 * kern/ieee1275/init.c
7731 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): Replace
7732 with ...
7733 (grub_machine_mmap_iterate): ... this.
7734 * include/grub/i386/pc/memory.h (grub_machine_mmap_iterate): Change
7735 return type to `grub_err_t'. Update all implementations of this
7736 function prototype.
7737 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_iterate):
7738 Likewise.
7739
60d6b16e 7740 Add `lsmmap' command (lists firmware-provided memory map):
7741 * commands/lsmmap.c: New file.
7742 * conf/i386-pc.rmk (pkglib_MODULES): Add `lsmmap.mod'.
7743 (lsmmap_mod_SOURCES, lsmmap_mod_CFLAGS, lsmmap_mod_LDFLAGS): New
7744 variables.
7745 * conf/powerpc-ieee1275.rmk: Likewise.
7746 * conf/i386-coreboot.rmk: Likewise.
7747 * conf/i386-ieee1275.rmk: Likewise.
7748
ebaaf49b 77492008-11-19 Robert Millan <rmh@aybabtu.com>
7750
7751 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Fix a typo.
92907110 7752 * loader/i386/linux.c (grub_rescue_cmd_initrd): Implement a few needed
7753 constraints to initrd allocation (based on code from
7754 loader/i386/pc/linux.c). Without them, initrd was allocated too high
7755 for Linux to find it.
ebaaf49b 7756
dfab719f 77572008-11-14 Robert Millan <rmh@aybabtu.com>
7758
7759 * fs/cpio.c (grub_cpio_open): Compare `name' and `fn' by hand in
7760 order to cope with duplicate slashes.
7761
10fc3eb9 77622008-11-14 Robert Millan <rmh@aybabtu.com>
7763
7764 * include/grub/i386/coreboot/memory.h (GRUB_MEMORY_MACHINE_LOWER_SIZE):
7765 Redefine to match with GRUB_MEMORY_MACHINE_UPPER_START (0x100000). We
7766 don't want to mess with lower memory, because it is used in the Linux
7767 loader.
7768
7769 * loader/i386/linux.c (allocate_pages): Allocate `real_mode_mem' in
34c44600 7770 an appropriate place in lower memory, between 0x10000 and 0x90000,
10fc3eb9 7771 like loader/i386/efi/linux.c does. Linux often panics if real_mode_mem
7772 is in our heap (probably as a result of it being corrupted during
2f2a3442 7773 decompression). Add #error instance with comment to explain why this
7774 loader isn't currently usable on PC/BIOS.
10fc3eb9 7775
e2e07847 77762008-11-14 Robert Millan <rmh@aybabtu.com>
7777
7778 * term/i386/pc/serial.c [! GRUB_MACHINE_PCBIOS]
34c44600 7779 (GRUB_SERIAL_PORT_NUM): Fix miscalculation.
e2e07847 7780
fe8e8d69 77812008-11-12 Robert Millan <rmh@aybabtu.com>
7782
7783 Make loader/i386/linux.c buildable on i386-pc (although disabled).
7784
7785 * include/grub/i386/pc/init.h: Include `<grub/machine/memory.h>'.
7786 (struct grub_machine_mmap_entry, grub_machine_mmap_iterate): Move
7787 from here ...
7788 * include/grub/i386/pc/memory.h: ... to here.
7789
976b07d0 77902008-11-12 Robert Millan <rmh@aybabtu.com>
7791
7792 Fix build problems on i386-ieee1275 and *-efi (introduced by vga_text
7793 split).
7794
7795 * include/grub/i386/pc/console.h: Include `<grub/i386/vga_common.h>'.
7796 (grub_console_cur_color, grub_console_real_putchar)
7797 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
7798 (grub_console_setcolorstate, grub_console_setcolor)
7799 (grub_console_getcolor): Move from here ...
7800 * include/grub/i386/vga_common.h: ... to here (new file).
7801
7802 * term/i386/pc/vga_text.c: Replace `<grub/machine/console.h>' with
7803 `<grub/i386/vga_common.h>' and `<grub/cpu/io.h>' with
7804 `<grub/i386/io.h>'.
7805 * term/i386/vga_common.c: Replace `<grub/machine/console.h>' with
7806 `<grub/i386/vga_common.h>'.
7807
76679cd3 78082008-11-12 Robert Millan <rmh@aybabtu.com>
7809
7810 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `term/i386/vga_common.c'.
7811 * conf/i386.rmk (pkglib_MODULES): Add `vga_text.mod'.
7812 (vga_text_mod_SOURCES, vga_text_mod_CFLAGS, vga_text_mod_LDFLAGS): New
7813 variables.
7814 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
7815 `term/i386/pc/console.c' with `term/i386/vga_common.c'.
7816
7817 * kern/i386/coreboot/init.c (grub_machine_init): Replace call to
7818 grub_console_init() with call to grub_vga_text_init().
7819 (grub_machine_fini): Replace call to
7820 grub_console_fini() with call to grub_vga_text_fini() and
7821 grub_at_keyboard_fini().
7822
7823 * include/grub/i386/pc/console.h: Include `<grub/term.h>'.
7824 (grub_console_putchar, grub_console_getcharwidth, grub_console_getwh)
7825 (grub_console_setcolorstate, grub_console_setcolor)
7826 (grub_console_getcolor): New function prototypes.
7827
7828 * term/i386/pc/vga_text.c: Include `<grub/dl.h>'.
7829 (grub_vga_text_getxy, grub_vga_text_gotoxy, grub_vga_text_cls)
7830 (grub_vga_text_setcursor): Static-ize.
7831 (grub_vga_text_term): New structure.
7832 (GRUB_MOD_INIT(vga_text), GRUB_MOD_FINI(vga_text)): New functions.
7833
7834 * term/i386/pc/console.c: Remove `<grub/machine/machine.h>'.
7835 (grub_console_cur_color, grub_console_standard_color)
7836 (grub_console_normal_color, grub_console_highlight_color)
7837 (map_char, grub_console_putchar, grub_console_getcharwidth)
7838 (grub_console_getwh, grub_console_setcolorstate, grub_console_setcolor)
7839 (grub_console_getcolor): Move from here ...
7840 * term/i386/vga_common.c: ... to here (same function names).
7841
95b841d3 78422008-11-12 Robert Millan <rmh@aybabtu.com>
7843
7844 Use newly-added Multiboot support in coreboot.
7845
7846 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Replace
7847 `kern/i386/coreboot/mmap.c' with `kern/i386/multiboot_mmap.c'.
7848
7849 * kern/i386/coreboot/startup.S: Enable Multiboot header, fix its
7850 alignment, set `MULTIBOOT_MEMORY_INFO' flag.
7851 (codestart): Store the MBI in `startup_multiboot_info' when we're
7852 being loaded using Multiboot.
7853
7854 * kern/i386/coreboot/init.c (grub_machine_init): Move
7855 grub_at_keyboard_init() call to beginning of function (useful for
7856 debugging). Call grub_machine_mmap_init() before attempting to use
7857 grub_machine_mmap_iterate().
7858 (grub_lower_mem, grub_upper_mem): Move from here ...
7859 * kern/i386/multiboot_mmap.c (grub_lower_mem, grub_upper_mem): ... to
7860 here (new file).
7861
7862 * include/grub/i386/coreboot/memory.h (grub_machine_mmap_init): New
7863 function prototype.
7864
761ca975 78652008-11-12 Robert Millan <rmh@aybabtu.com>
7866
7867 Fix a regression introduced by the at_keyboard.mod split. Because
7868 some terminals are default on some platforms and non-default on
7869 others, the first terminal being registered determines which is
7870 going to be default.
7871
7872 * kern/term.c (grub_term_register_input): If this is the first
7873 terminal being registered, set it as the current one.
7874 (grub_term_register_output): Likewise.
7875
7876 * term/efi/console.c (grub_console_init): Do not call
7877 grub_term_set_current_output() or grub_term_set_current_input().
7878 * term/ieee1275/ofconsole.c (grub_console_init): Likewise.
7879 * term/i386/pc/console.c (grub_console_init): Likewise.
7880 (grub_console_fini): Do not call grub_term_set_current_input()
7881 (but leave grub_term_set_current_output() to restore text mode).
7882
6c529df7 78832008-11-10 Robert Millan <rmh@aybabtu.com>
7884
7885 * util/grub.d/00_header.in: Add backward compatibility check for
7886 versions of terminal.mod that don't understand `terminal_input' or
7887 `terminal_output'.
7888
132e4113 78892008-11-09 Robert Millan <rmh@aybabtu.com>
7890
7891 * commands/terminal.c (GRUB_MOD_FINI(terminal)): Unregister
7892 `terminal_input' / `terminal_output', not `terminal'.
7893
ac293d50 78942008-11-08 Robert Millan <rmh@aybabtu.com>
7895
7896 * Makefile.in (include_DATA): Fix srcdir=. assumption.
2a9c5940 7897 (DISTCLEANFILES): Add `build_env.mk'.
ac293d50 7898
0025933a 78992008-11-08 Robert Millan <rmh@aybabtu.com>
7900
7901 * term/i386/pc/vesafb.c (grub_vesafb_term): Change type to
dba3f844 7902 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
0025933a 7903 members. Update all users.
7904 * util/console.c (grub_ncurses_term): Split in ...
7905 (grub_ncurses_term_input): ... this, and ...
7906 (grub_ncurses_term_output): ... this. Update all users.
dcb6fa0a 7907 * term/ieee1275/ofconsole.c: Remove stale `#endif'.
0025933a 7908
37c86336 79092008-11-08 Robert Millan <rmh@aybabtu.com>
7910
7911 * Makefile.in (PKGLIB): Add $(pkglib_BUILDDIR).
7912 (PKGDATA): Add $(pkgdata_SRCDIR).
7913 (pkglib_BUILDDIR): New variable.
7914 (pkgdata_SRCDIR): New variable.
7915 (build_env.mk): New target.
7916 (include_DATA): New variable.
7917 (install-local): Install $(include_DATA) files in $(includedir).
7918
b6c15a2d 79192008-11-07 Pavel Roskin <proski@gnu.org>
7920
d99d46f1 7921 * gendistlist.sh: Use C locale for sorting to ensure consistent
7922 output on all systems.
7923
b6c15a2d 7924 * util/grub.d/00_header.in: Remove incorrect space before
7925 "serial".
7926
c32ee8c9 79272008-11-07 Robert Millan <rmh@aybabtu.com>
7928
7929 * include/multiboot2.h (struct multiboot_header): Add `flags' member as
7930 per specification.
7931 * loader/multiboot2.c (grub_multiboot2): Fix Multiboot2 header check.
7932 * loader/multiboot_loader.c (find_multi_boot2_header): New function
7933 (based on find_multi_boot1_header).
7934 (grub_rescue_cmd_multiboot_loader): Check for Multiboot2 header,
7935 using find_multi_boot2_header(), and abort if neither Multiboot or
7936 Multiboot headers were found.
7937
651c29b7 79382008-11-07 Robert Millan <rmh@aybabtu.com>
7939
7940 Modularize at_keyboard.mod:
7941
7942 * conf/i386.rmk (pkglib_MODULES): Add `at_keyboard.mod'.
7943 (at_keyboard_mod_SOURCES, at_keyboard_mod_CFLAGS)
7944 (at_keyboard_mod_LDFLAGS): New variables.
7945
7946 Actual terminal split:
7947
7948 * include/grub/term.h (struct grub_term): Split in ...
7949 (struct grub_term_input): ... this, and ...
7950 (struct grub_term_output): ... this. Update all users.
7951 (grub_term_set_current): Split in ...
7952 (grub_term_set_current_input): ... this, and ...
7953 (grub_term_set_current_output): ... this.
7954 (grub_term_get_current): Split in ...
7955 (grub_term_get_current_input): ... this, and ...
7956 (grub_term_get_current_output): ... this.
7957 (grub_term_register): Split in ...
7958 (grub_term_register_input): ... this, and ...
7959 (grub_term_register_output): ... this.
7960 (grub_term_unregister): Split in ...
7961 (grub_term_unregister_input): ... this, and ...
7962 (grub_term_unregister_output): ... this.
7963 (grub_term_iterate): Split in ...
7964 (grub_term_iterate_input): ... this, and ...
7965 (grub_term_iterate_output): ... this.
7966
7967 * kern/term.c (grub_term_list): Split in ...
7968 (grub_term_list_input): ... this, and ...
7969 (grub_term_list_output): ... this. Update all users.
7970 (grub_cur_term): Split in ...
7971 (grub_cur_term_input): ... this, and ...
7972 (grub_cur_term_output): ... this. Update all users.
7973 (grub_term_set_current): Split in ...
7974 (grub_term_set_current_input): ... this, and ...
7975 (grub_term_set_current_output): ... this.
7976 (grub_term_get_current): Split in ...
7977 (grub_term_get_current_input): ... this, and ...
7978 (grub_term_get_current_output): ... this.
7979 (grub_term_register): Split in ...
7980 (grub_term_register_input): ... this, and ...
7981 (grub_term_register_output): ... this.
7982 (grub_term_unregister): Split in ...
7983 (grub_term_unregister_input): ... this, and ...
7984 (grub_term_unregister_output): ... this.
7985 (grub_term_iterate): Split in ...
7986 (grub_term_iterate_input): ... this, and ...
7987 (grub_term_iterate_output): ... this.
7988
7989 * kern/misc.c (grub_abort): Split use of grub_term_get_current() into
7990 a check for input and one for output (and only attempt to get keys
7991 from user when input works).
7992
7993 * util/grub-probe.c (grub_term_get_current): Split in ...
7994 (grub_term_get_current_input): ... this, and ...
7995 (grub_term_get_current_output): ... this.
7996 * util/grub-fstest.c: Likewise.
7997 * util/i386/pc/grub-setup.c: Likewise.
7998 * util/grub-editenv.c: Likewise.
7999
8000 Portability adjustments:
8001
8002 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Remove
8003 `term/i386/pc/at_keyboard.c'.
8004 * kern/ieee1275/init.c [__i386__] (grub_machine_init): Remove call to
8005 grub_keyboard_controller_init() (now handled by terminal .init).
8006 * kern/i386/coreboot/init.c (grub_machine_init): Add call to
8007 grub_at_keyboard_init().
8008 * include/grub/i386/ieee1275/console.h (grub_keyboard_controller_init)
8009 (grub_console_checkkey, grub_console_getkey): Remove (now provided by
8010 at_keyboard.mod via input terminal interface).
8011 * include/grub/i386/coreboot/console.h: Convert into a stub for
8012 `<grub/i386/pc/console.h>'.
8013
8014 Migrate full terminals to new API:
8015
8016 * term/efi/console.c (grub_console_term): Split into ...
8017 (grub_console_term_input): ... this, and ...
8018 (grub_console_term_output): ... this. Update all users.
8019 * term/ieee1275/ofconsole.c: Remove __i386__ hack.
8020 (grub_ofconsole_init): Split into ...
8021 (grub_ofconsole_init_input): ... this, and ...
8022 (grub_ofconsole_init_output): ... this.
8023 (grub_ofconsole_term): Split into ...
8024 (grub_ofconsole_term_input): ... this, and ...
8025 (grub_ofconsole_term_output): ... this. Update all users.
8026 * term/i386/pc/serial.c (grub_serial_term): Split into ...
8027 (grub_serial_term_input): ... this, and ...
8028 (grub_serial_term_output): ... this. Update all users.
8029 * term/i386/pc/console.c (grub_console_term): Split into ...
8030 (grub_console_term_input): ... this, and ...
8031 (grub_console_term_output): ... this. Update all users.
8032 (grub_console_term_input): Only enable it on PC/BIOS platform.
8033 (grub_console_init): Remove grub_keyboard_controller_init() call.
8034
8035 Migrate input terminals to new API:
8036
8037 * term/i386/pc/at_keyboard.c: Replace `cpu' and `machine' with
8038 `i386' and `i386/pc' to enable build on x86_64 (this driver is
8039 i386-specific anyway).
8040 (grub_console_checkkey): Rename to ...
8041 (grub_at_keyboard_checkkey): ... this. Static-ize. Update all
8042 users.
8043 (grub_keyboard_controller_orig): New variable.
8044 (grub_console_getkey): Rename to ...
8045 (grub_at_keyboard_getkey): ... this. Static-ize. Update all
8046 users.
8047 (grub_keyboard_controller_init): Static-ize. Save original
8048 controller value so that it can be restored ...
8049 (grub_keyboard_controller_fini): ... here (new function).
8050 (grub_at_keyboard_term): New structure.
8051 (GRUB_MOD_INIT(at_keyboard), GRUB_MOD_FINI(at_keyboard)): New
8052 functions.
8053
8054 Migrate output terminals to new API:
8055
8056 * term/i386/pc/vga.c (grub_vga_term): Change type to
8057 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
8058 members. Update all users.
8059 * term/gfxterm.c (grub_video_term): Change type to
8060 `struct grub_term_output'. Remove `.checkkey' and `.getkey'
8061 members. Update all users.
8062 * include/grub/i386/pc/console.h (grub_console_checkkey)
8063 (grub_console_getkey): Do not export (no longer needed by gfxterm,
8064 etc).
8065
8066 Migrate `terminal' command and userland tools to new API:
8067
8068 * commands/terminal.c (grub_cmd_terminal): Split into ...
8069 (grub_cmd_terminal_input): ... this, and ...
8070 (grub_cmd_terminal_output): ... this.
8071 (GRUB_MOD_INIT(terminal)): Split `terminal' command in two commands:
8072 `terminal_input' and `terminal_output'.
8073 * util/grub.d/00_header.in: Adjust `terminal' calls to new
8074 `terminal_input' / `terminal_output' API.
8075 * util/grub-mkconfig.in: Export ${GRUB_TERMINAL_INPUT} and
8076 ${GRUB_TERMINAL_OUTPUT} instead of ${GRUB_TERMINAL} (and if user
8077 provided ${GRUB_TERMINAL}, convert it).
8078
96e5d876 80792008-11-04 Robert Millan <rmh@aybabtu.com>
8080
8081 * util/grub.d/10_freebsd.in: New file. Generate grub configuration
8082 for FreeBSD.
8083 * conf/common.rmk (grub-mkconfig_SCRIPTS): Add 10_freebsd.
8084
556f3775 80852008-11-03 Bean <bean123ch@gmail.com>
8086
8087 * kern/elf.c (grub_elf32_load): Revert to previous code.
8088 (grub_elf64_load): Likewise.
8089
8090 * loader/i386/bsd.c (grub_bsd_elf32_hook): Change return address.
8091
926b9823 80922008-11-01 Robert Millan <rmh@aybabtu.com>
8093
8094 * Makefile.in (CPPFLAGS): Fix builddir=. assumption.
8095 (TARGET_CPPFLAGS): Likewise.
8096 * genmk.rb (mod_src): Fix builddir=. and srcdir=. assumptions.
8097
1432e958 80982008-11-01 Carles Pina i Estany <carles@pina.cat>
8099
8100 * normal/menu.c (run_menu): Add Previous and Next Page keys in menu.
8101
dba3f844 81022008-10-29 Guillem Jover <guillem.jover@nokia.com>
de4fa71c 8103
8104 * disk/lvm.c (grub_lvm_scan_device): Fix error recovery by delaying the
8105 addition of objects until the code is not going to be able to fail.
8106
dba3f844 81072008-10-29 Guillem Jover <guillem.jover@nokia.com>
b7279447 8108
8109 * disk/lvm.c (grub_lvm_scan_device): Fix possible NULL value handling
8110 (add a missing NULL check, and correct them by moving the pointer
8111 operations after the actual check).
8112
7ab28c21 81132008-10-29 Robert Millan <rmh@aybabtu.com>
8114
8115 * util/i386/pc/grub-install.in: Handle empty string as output from
8116 make_system_path_relative_to_its_root().
8117
1b7748eb 81182008-10-05 Hans Lambermont <hans@lambermont.dyndns.org>
8119
8120 * disk/lvm.c (grub_lvm_scan_device): Allocate buffer space for the
8121 circular metadata worst case scenario. If the metadata is circular
8122 then copy the wrap in place.
8123 * include/grub/lvm.h: Add GRUB_LVM_MDA_HEADER_SIZE, from the LVM2
8124 project lib/format_text/layout.h
8125 Circular metadata bug found and patch debugged by Jan Derk Gerlings.
8126
c9618ab2 81272008-10-03 Felix Zielcke <fzielcke@z-51.de>
8128
7a36edca 8129 * util/i386/pc/grub-install.in: Source grub-mkconfig_lib instead of update-grub_lib.
c9618ab2 8130
bf981c62 81312008-10-03 Felix Zielcke <fzielcke@z-51.de>
8132
8133 * util/update-grub_lib.in: Mention filename in warning message.
8134
6d994591 81352008-09-29 Felix Zielcke <fzielcke@z-51.de>
8136
8137 * NEWS: Update for rename of update-grub to grub-mkconfig.
8138
18ade780 81392008-09-29 Felix Zielcke <fzielcke@z-51.de>
8140
8141 * util/update-grub_lib.in: Copy to ...
8142 * util/grub-mkconfig_lib.in: ... this. Update all users.
7c3ff286 8143 * util/update-grub_lib.in: Make it a stub to `grub-mkconfig_lib.in'.
18ade780 8144 * util/update-grub.in: Rename to ...
8145 * util/grub-mkconfig.in: ... this. Update all users. Remove `-y'
8146 option. Add `--output' option to allow users to specify the generated
8147 configuration file. Default to stdout.
8148 (update_grub_dir): Rename to ...
8149 (grub_mkconfig_dir): ... this.
8150 (grub_cfg): Default to an empty string.
8151 * conf/common.rmk (update-grub): Rename to ...
8152 (grub-mkconfig): ... this.
8153 (update-grub_lib): Copy to ...
8154 (grub-mkconfig_lib): ... this.
8155 (update-grub_SCRIPTS): Copy to ...
8156 (grub-mkconfig_SCRIPTS): ... this. Update all users.
8157 (update-grub_DATA): Rename to ...
8158 (grub-mkconfig_DATA): ... this.
8159
556ce6ac 81602008-09-28 Robert Millan <rmh@aybabtu.com>
8161
8162 * fs/iso9660.c (struct grub_iso9660_primary_voldesc): Rename `created'
8163 to `modified'. Add the real `created' field.
8164 (grub_iso9660_uuid): Use `modified' rather than `created' for
8165 constructing the UUID.
8166
81672008-09-28 Felix Zielcke <fzielcke@z-51.de>
eb079ba9 8168
8169 fs/jfs.c (grub_jfs_find_file): Treat multiple slashes like one.
8170 Based on code from Tomas Ebenlendr <ebik@ucw.cz>.
8171
92274e85 81722008-09-28 Bean <bean123ch@gmail.com>
8173
8174 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a bug in the previous patch.
8175 Thanks to Christian Franke for finding this bug.
8176
add6f17a 81772008-09-25 Robert Millan <rmh@aybabtu.com>
8178
8179 * util/grub-mkdevicemap.c (make_device_map): Actually replace all
8180 instances of grub_util_get_disk_name() (see previous commit).
8181
d2a367b8 81822008-09-25 Robert Millan <rmh@aybabtu.com>
8183
8184 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Remove
8185 `util/i386/get_disk_name.c'.
8186 * conf/i386-efi.rmk: Likewise.
8187 * conf/x86_64-efi.rmk: Likewise.
8188 * conf/i386-coreboot.rmk: Likewise.
8189 * conf/i386-ieee1275.rmk: Likewise.
8190 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Remove
8191 `util/ieee1275/get_disk_name.c'.
8192 * include/grub/util/misc.h (grub_util_get_disk_name): Remove.
8193 * util/ieee1275/get_disk_name.c: Remove file.
8194 * util/i386/get_disk_name.c: Remove file.
8195 * util/grub-mkdevicemap.c (make_device_map): Back to hardcoding
8196 "hd%d" for device.map entries, rather than using
8197 grub_util_get_disk_name().
8198
81a06771 81992008-09-24 Carles Pina i Estany <carles@pina.cat>
b0c301f7 8200
8201 * disk/dmraid_nvidia.c (grub_dmraid_nv_detect): Fix `unused parameter'
8202 warning.
8203 * commands/i386/pc/pxecmd.c (dmraid_nvidia): Likewise.
8204
5a004279 82052008-09-24 Carles Pina i Estany <carles@pina.cat>
8206
8207 * include/grub/i386/pc/console.h (GRUB_TERM_NPAGE):
8208 Changed to 0x5100.
8209 (GRUB_TERM_PPAGE): Changed to 0x4900.
8210
397093d3 82112008-09-24 Robert Millan <rmh@aybabtu.com>
8212
8213 * include/grub/powerpc/ieee1275/console.h (GRUB_CONSOLE_KEY_*): Remove
8214 macros (they were i386-pc specific).
8215 * include/grub/sparc64/ieee1275/console.h: Likewise.
8216 * include/grub/efi/console.h: Likewise.
8217
a91b6c7c 82182008-09-22 Bean <bean123ch@gmail.com>
8219
8220 * fs/ntfs.c (grub_ntfs_iterate_dir): Fix a rare case where $BITMAP is
8221 resident and in attribute list.
8222
8223 * include/grub/ntfs.h (BMP_LEN): Removed.
8224
c40fd116 82252008-09-22 Bean <bean123ch@gmail.com>
8226
81a06771 8227 * disk/ata.c (grub_atapi_open): Initialize devfnd, no need to set
c40fd116 8228 scsi->name and scsi->luns, as they will be set in grub_scsi_open.
8229
8230 * disk/scsi.c (grub_scsi_open): Don't call p->close (scsi) here when
8231 error occurs, as grub_disk_open will call grub_disk_close, which will
8232 call p->close (scsi).
8233
81a06771 82342008-09-21 Felix Zielcke <fzielcke@z-51.de>
eb73121d 8235
8236 * configure.ac (AC_INIT): Quote `GRUB' string and version number.
8237 (AC_PREREQ): Bumped to 2.59.
8238 (AC_TRY_COMPILE): Replace obsolete macro with ...
8239 (AC_COMPILE_IFELSE): ... this.
8240 * aclocal.m4 (AC_TRY_LINK): Replace obsolete macro with ...
8241 (AC_LINK_IFELSE): ... this.
8242
5dc43410 82432008-09-21 Felix Zielcke <fzielcke@z-51.de>
8244
8245 * autogen.sh: Add a call to `gendistlist.sh'.
8246
9035dce4 82472008-09-19 Christian Franke <franke@computer.org>
8248
8249 * aclocal.m4 (grub_CHECK_ENABLE_EXECUTE_STACK): New function.
8250 * configure.ac: Call grub_CHECK_ENABLE_EXECUTE_STACK.
8251 * include/grub/misc.h [NEED_ENABLE_EXECUTE_STACK]:
8252 Export __enable_execute_stack() to modules.
8253 * kern/misc.c [NEED_ENABLE_EXECUTE_STACK] (__enable_execute_stack):
8254 New function.
8255
7fd75377 82562008-09-09 Felix Zielcke <fzielcke@z-51.de>
8257
040030b3 8258 * Makefile.in (RMKFILES): Add `i386.rmk' and `x86_64-efi.rmk'.
8259 Sort the list.
8260
82612008-09-09 Felix Zielcke <fzielcke@z-51.de>
8262
8263 * util/hostdisk.c: Replace #include <grub/util/biosdisk.h> with
7fd75377 8264 #include <grub/util/hostdisk.h>.
8265
89d5ffcf 82662008-09-08 Robert Millan <rmh@aybabtu.com>
8267
8268 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Skip
8269 segments when their filesz is zero (grub_file_read() interprets
81a06771 8270 zero-size as "read until EOF", which results in memory corruption).
89d5ffcf 8271 Use `lowest_segment' rather than 0 for calculating the current
8272 segment load address.
8273
40da438f 82742008-09-08 Robert Millan <rmh@aybabtu.com>
8275
8276 * util/hostdisk.c (open_device): Replace a grub_util_info() call
8277 with grub_dprintf("hostdisk", ...), as it was so verbose that it
8278 clobbered useful information.
8279
ddbf5556 82802008-09-08 Robert Millan <rmh@aybabtu.com>
8281
8282 * include/grub/util/biosdisk.h: Move to ...
8283 * include/grub/util/hostdisk.h: ... here. Update all users.
8284 * util/biosdisk.c: Move to ...
8285 * util/hostdisk.c: ... here. Update all users.
8286
783d0f48 82872008-09-07 Robert Millan <rmh@aybabtu.com>
8288
8289 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): Remove
8290 variables.
8291 (grub_multiboot): Move `mbi' allocation upwards, so that mmap address
8292 and length can be stored directly in the `mbi->mmap_addr' and
8293 `mbi->mmap_length' struct fields.
8294
548e2ea5 82952008-09-07 Robert Millan <rmh@aybabtu.com>
8296
8297 * conf/i386.rmk: New file. Provides declaration for building
8298 `cpuid.mod'.
8299 * conf/i386-pc.rmk (pkglib_MODULES): Remove `cpuid.mod'.
8300 (cpuid_mod_SOURCES, cpuid_mod_CFLAGS, cpuid_mod_LDFLAGS): Remove
8301 variables.
8302 Include `conf/i386.mk'.
8303 * conf/i386-efi.rmk: Likewise.
8304 * conf/x86_64-efi.rmk: Likewise.
8305 * conf/i386-coreboot.rmk: Likewise.
8306 * conf/i386-ieee1275.rmk: Likewise.
8307
0ea85a37 83082008-09-07 Vesa Jääskeläinen <chaac@nic.fi>
8309
8310 Based on patch created by Colin D Bennett <colin@gibibit.com>.
8311 Adds optimization support for BGR based modes.
8312
8313 * include/grub/i386/pc/vbeblit.h (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8) Removed.
8314 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
8315 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
8316 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
8317 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
8318 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
8319 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
8320 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
8321 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
8322 (grub_video_i386_vbeblit_index_index): Likewise.
8323 (grub_video_i386_vbeblit_replace_directN): Added.
8324 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
8325 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
8326 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
8327 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
8328 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
8329 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
81a06771 8330 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
0ea85a37 8331 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
8332 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
8333 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
8334 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
8335 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
8336 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
8337
8338 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8) Removed.
8339 (grub_video_i386_vbefill_R8G8B8): Likewise.
8340 (grub_video_i386_vbefill_index): Likewise.
8341 (grub_video_i386_vbefill_direct32): Added.
8342 (grub_video_i386_vbefill_direct24): Likewise.
8343 (grub_video_i386_vbefill_direct16): Likewise.
8344 (grub_video_i386_vbefill_direct8): Likewise.
8345
81a06771 8346 * include/grub/video.h (grub_video_blit_format): Removed
0ea85a37 8347 GRUB_VIDEO_BLIT_FORMAT_R8G8B8A8, GRUB_VIDEO_BLIT_FORMAT_R8G8B8.
8348 (grub_video_blit_format): Added GRUB_VIDEO_BLIT_FORMAT_RGBA_8888,
8349 GRUB_VIDEO_BLIT_FORMAT_BGRA_8888, GRUB_VIDEO_BLIT_FORMAT_RGB_888,
8350 GRUB_VIDEO_BLIT_FORMAT_BGR_888, GRUB_VIDEO_BLIT_FORMAT_RGB_565,
8351 GRUB_VIDEO_BLIT_FORMAT_BGR_565.
81a06771 8352
0ea85a37 8353 * video/video.c (grub_video_get_blit_format): Updated to use new
8354 blit formats. Added handling for 16 bit color modes.
81a06771 8355
8356 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Updated to use new
0ea85a37 8357 fillers.
8358 (common_blitter): Updated to use new blitters.
8359
8360 * video/i386/pc/vbeblit.c (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8):
8361 Removed.
8362 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): Likewise.
8363 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
8364 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
8365 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
8366 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
8367 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
8368 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
8369 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
8370 (grub_video_i386_vbeblit_index_index): Likewise.
8371 (grub_video_i386_vbeblit_replace_directN): Added.
8372 (grub_video_i386_vbeblit_replace_BGRX8888_RGBX8888): Likewise.
8373 (grub_video_i386_vbeblit_replace_BGRX8888_RGB888): Likewise.
8374 (grub_video_i386_vbeblit_replace_BGR888_RGBX8888): Likewise.
8375 (grub_video_i386_vbeblit_replace_BGR888_RGB888): Likewise.
8376 (grub_video_i386_vbeblit_replace_RGBX8888_RGB888): Likewise.
8377 (grub_video_i386_vbeblit_replace_RGB888_RGBX8888): Likewise.
8378 (grub_video_i386_vbeblit_replace_index_RGBX8888): Likewise.
8379 (grub_video_i386_vbeblit_replace_index_RGB888): Likewise.
8380 (grub_video_i386_vbeblit_blend_BGRA8888_RGBA8888): Likewise.
8381 (grub_video_i386_vbeblit_blend_BGR888_RGBA8888): Likewise.
8382 (grub_video_i386_vbeblit_blend_RGBA8888_RGBA8888): Likewise.
8383 (grub_video_i386_vbeblit_blend_RGB888_RGBA8888): Likewise.
8384 (grub_video_i386_vbeblit_blend_index_RGBA8888): Likewise.
81a06771 8385
0ea85a37 8386 * video/i386/pc/vbefill.c (grub_video_i386_vbefill_R8G8B8A8): Removed.
8387 (grub_video_i386_vbefill_R8G8B8): Likewise.
8388 (grub_video_i386_vbefill_index): Likewise.
8389 (grub_video_i386_vbefill_direct32): Added.
8390 (grub_video_i386_vbefill_direct24): Likewise.
8391 (grub_video_i386_vbefill_direct16): Likewise.
8392 (grub_video_i386_vbefill_direct8): Likewise.
81a06771 8393
0ea85a37 8394 * video/readers/jpeg.c (grub_jpeg_decode_sos): Adapt to new blitter
8395 types.
81a06771 8396
0ea85a37 8397 * video/readers/tga.c (grub_video_reader_tga): Adapt to new blitter
8398 types.
81a06771 8399
0ea85a37 8400 * video/readers/png.c (grub_png_decode_image_header): Adapt to new
8401 blitter types.
81a06771 8402
0ea85a37 8403 * video/bitmap.c (grub_video_bitmap_create): Adapt to new blitter
8404 types.
8405
e8a83df6 84062008-09-06 Felix Zielcke <fzielcke@z-51.de>
8407
8408 * disk/raid.c (insert_array): Set `array->chunk_size' to 64 for
8409 RAID level 1.
8410
6bcd8ee5 84112008-09-06 Felix Zielcke <fzielcke@z-51.de>
c375ae58 8412
6bcd8ee5 8413 * fs/iso9660.c (grub_iso9660_date): New structure.
8414 (grub_iso9660_primary_voldesc): Add `grub_iso9660_date' member.
8415 (grub_iso9660_uuid): New function.
c375ae58 8416
59261157 84172008-09-05 Bean <bean123ch@gmail.com>
8418
8419 * fs/fshelp.c (grub_fshelp_find_file): Handle case insensitive names.
8420
8421 * fs/ntfs.c (list_file): Ignore names in DOS namespace, set the case
8422 insensitive bit for names in Win32 and Win32 & DOS namespace.
8423
8424 * include/grub/fshelp.h (GRUB_FSHELP_CASE_INSENSITIVE): New macro.
8425
8426 * include/grub/types.h (LONG_MAX): Likewise.
8427
58b6645a 84282008-09-04 Felix Zielcke <fzielcke@z-51.de>
8429
4ee55921 8430 * util/getroot.c: Include <config.h>.
8431 (grub_util_get_grub_dev): Rewrite to use asprintf for mdraid devices,
8432 add support for /dev/md/N devices and handle LVM double dash escaping.
8433
84342008-09-04 Felix Zielcke <fzielcke@z-51.de>
8435
8436 * config.guess: Update to latest version from config git.
8437 * config.sub: Likewise.
58b6645a 8438
9124f65d 84392008-09-03 Robert Millan <rmh@aybabtu.com>
8440
8441 * disk/scsi.c (grub_scsi_open): Remove size limit when printing
8442 `disk->total_sectors'.
8443
81a06771 84442008-09-01 Colin D Bennett <colin@gibibit.com>
a0224a4e 8445
8446 * include/grub/normal.h: Fixed incorrect comment for
8447 GRUB_COMMAND_FLAG_NO_ARG_PARSE.
8448
81a06771 84492008-09-01 Colin D Bennett <colin@gibibit.com>
f0619958 8450
8451 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Replaced constant
8452 values with defines.
8453
8454 * include/grub/i386/pc/vbe.h (GRUB_VBE_MODEATTR_SUPPORTED): Added.
8455 (GRUB_VBE_MODEATTR_RESERVED_1): Likewise.
8456 (GRUB_VBE_MODEATTR_BIOS_TTY_OUTPUT_SUPPORT): Likewise.
8457 (GRUB_VBE_MODEATTR_COLOR): Likewise.
8458 (GRUB_VBE_MODEATTR_GRAPHICS): Likewise.
8459 (GRUB_VBE_MODEATTR_VGA_COMPATIBLE): Likewise.
8460 (GRUB_VBE_MODEATTR_VGA_WINDOWED_AVAIL): Likewise.
8461 (GRUB_VBE_MODEATTR_LFB_AVAIL): Likewise.
8462 (GRUB_VBE_MODEATTR_DOUBLE_SCAN_AVAIL): Likewise.
8463 (GRUB_VBE_MODEATTR_INTERLACED_AVAIL): Likewise.
8464 (GRUB_VBE_MODEATTR_TRIPLE_BUF_AVAIL): Likewise.
8465 (GRUB_VBE_MODEATTR_STEREO_AVAIL): Likewise.
8466 (GRUB_VBE_MODEATTR_DUAL_DISPLAY_START): Likewise.
8467 (GRUB_VBE_MEMORY_MODEL_TEXT): Likewise.
8468 (GRUB_VBE_MEMORY_MODEL_CGA): Likewise.
8469 (GRUB_VBE_MEMORY_MODEL_HERCULES): Likewise.
8470 (GRUB_VBE_MEMORY_MODEL_PLANAR): Likewise.
8471 (GRUB_VBE_MEMORY_MODEL_NONCHAIN4_256): Likewise.
8472 (GRUB_VBE_MEMORY_MODEL_YUV): Likewise.
8473
93d5cbf8 84742008-08-31 Robert Millan <rmh@aybabtu.com>
8475
8476 * loader/i386/pc/multiboot.c (grub_get_multiboot_mmap_len): Fix
8477 declaration.
8478 (grub_multiboot): Fix a few warnings.
8479
21751d50 84802008-08-31 Robert Millan <rmh@aybabtu.com>
8481
8482 * loader/i386/pc/multiboot.c: Update comment not to say that
8483 boot_device support is unimplemented.
8484
e27a75c5 84852008-08-31 Robert Millan <rmh@aybabtu.com>
8486
8487 * loader/i386/pc/multiboot.c: Update comment not to say that a.out
8488 or memory map support are unimplemented.
8489
81a06771 84902008-08-31 Colin D Bennett <colin@gibibit.com>
64d2d53c 8491
8492 * util/i386/pc/grub-mkrescue.in: Support multiple overlay directories.
8493
81a06771 84942008-08-31 Colin D Bennett <colin@gibibit.com>
c08a6c18 8495
8496 * commands/i386/pc/vbeinfo.c (grub_cmd_vbeinfo): Show VBE version and
8497 total video memory in 'vbeinfo' output; show color format details for
8498 each video mode.
8499
7c5d8d95 85002008-08-30 Pavel Roskin <proski@gnu.org>
8501
8502 * util/genmoddep.c: Remove for real this time.
8503 * DISTLIST: Remove util/genmoddep.c.
8504
4cebd25a 85052008-08-30 Robert Millan <rmh@aybabtu.com>
8506
8507 * kern/i386/pc/startup.S (multiboot_header): Force 4-byte alignment
8508 as required by Multiboot spec (it was already 4-byte aligned, but
8509 only by chance).
8510
b497a269 85112008-08-29 Pavel Roskin <proski@gnu.org>
8512
e3925185 8513 * kern/powerpc/ieee1275/crt0.S: Rename to ...
8514 * kern/powerpc/ieee1275/startup.S: ... this.
8515 * conf/powerpc-ieee1275.rmk: Adjust for the above.
8516 * DISTLIST: Likewise.
8517
b497a269 8518 * kern/powerpc/ieee1275/crt0.S: Include grub/symbol.h and
8519 grub/cpu/kernel.h. Add start label for consistency with other
8520 platforms. Add grub_prefix immediately after start. Add jump
8521 to the code after grub_prefix.
8522 * include/grub/powerpc/kernel.h: Provide valid values for
8523 GRUB_KERNEL_CPU_PREFIX and GRUB_KERNEL_CPU_DATA_END.
8524
6e5a42fe 85252008-08-29 Bean <bean123ch@gmail.com>
8526
8527 * configure.ac: Change host_os to cygwin for mingw.
8528 (asprintf): New check for function.
8529
8530 * include/grub/symbol.h: Replace #ifndef __CYGWIN__ with
8531 #if ! defined (__CYGWIN__) && ! defined (__MINGW32__).
8532
8533 * include/grub/util/misc.h: #include <config.h> and <grub/types.h>,
81a06771 8534 declare asprintf if HAVE_ASPRINTF is not set, declare fseeko, ftello,
6e5a42fe 8535 sync, sleep and grub_util_get_disk_size for mingw.
8536
8537 * util/biosdisk.c (grub_util_biosdisk_open): Use grub_util_get_disk_size
8538 to get size in mingw.
8539 (open_device): Use flag O_BINARY if it's defined.
8540 (find_root_device): Add dummy code for mingw.
8541
8542 * util/grub-mkdevicemap.c (get_floppy_disk_name): Return 0 for mingw.
8543 (get_ide_disk_name): Return //./PHYSICALDRIVE%d for mingw.
8544 (get_scsi_disk_name): Return 0 for mingw.
8545
8546 * util/hostfs.c: #include <grub/util/misc.h>.
8547 (grub_hostfs_open): Use "rb" flag to open file, use
8548 grub_util_get_disk_size to get disk size for mingw.
8549
8550 * util/misc.c: #include <windows.h> and <winioctl.h> in mingw.
8551 (asprintf): New function if HAVE_ASPRINTF is not set.
8552 (sync): New function for mingw.
8553 (sleep): Likewise.
8554 (grub_util_get_disk_size): Likewise.
8555
ab3f2673 85562008-08-28 Pavel Roskin <proski@gnu.org>
8557
8558 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
8559 kern/time.c.
8560
1c282483 85612008-08-28 Robert Millan <rmh@aybabtu.com>
8562
8563 * util/biosdisk.c (find_grub_drive): Declare missing `i' variable.
8564
678e849c 85652008-08-28 Robert Millan <rmh@aybabtu.com>
8566
8567 Change find_grub_drive() syntax so it doesn't prevent it from
8568 detecting NULL names as errors.
8569
8570 * util/biosdisk.c (find_grub_drive): Move free slot search code
8571 from here ...
8572 (find_free_slot): ... to here.
8573 (read_device_map): Use find_free_slot() to search for free slots.
8574
965c75ca 85752008-08-27 Marco Gerards <marco@gnu.org>
8576
8577 * conf/common.rmk (pkglib_MODULES): Add scsi.mod.
8578 (scsi_mod_SOURCES): New variable.
8579 (scsi_mod_CFLAGS): Likewise
8580 (scsi_mod_LDFLAGS): Likewise.
8581
8582 * disk/scsi.c: New file.
8583
8584 * include/grub/scsi.h: Likewise.
8585
8586 * include/grub/scsicmd.h: Likewise.
8587
8588 * disk/ata.c: Include <grub/scsi.h>.
8589 (grub_atapi_packet): Do not use grub_ata_cmd, use registers
8590 instead.
8591 (grub_ata_iterate): Skip ATAPI devices.
8592 (grub_ata_open): Only handle ATAPI devices.
8593 (struct grub_atapi_read): Removed.
8594 (grub_atapi_readsector): Likewise.
8595 (grub_ata_read): No longer handle ATAPI devices.
8596 (grub_ata_write): Likewise.
8597 (grub_atapi_iterate): New function.
8598 (grub_atapi_read): Likewise.
8599 (grub_atapi_write): Likewise.
8600 (grub_atapi_open): Likewise.
8601 (grub_atapi_close): Likewise.
8602 (grub_atapi_dev): New variable.
8603 (GRUB_MOD_INIT(ata)): Register ATAPI as SCSI device.
8604 (GRUB_MOD_FINI(ata)): Unregister ATAPI.
8605
8606 * include/grub/disk.h (enum grub_disk_dev_id): Add
8607 `GRUB_DISK_DEVICE_SCSI_ID'.
8608
c07ae501 86092008-08-26 Robert Millan <rmh@aybabtu.com>
8610
8611 * util/biosdisk.c (grub_util_biosdisk_open, open_device)
8612 (grub_util_biosdisk_get_grub_dev): Make error messages a bit more
8613 descriptive.
8614
5ed20adc 86152008-08-23 Bean <bean123ch@gmail.com>
8616
8617 * conf/common.rmk (grub_probe_SOURCES): Add disk/mdraid_linux.c.
8618 (grub_fstest_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
8619 disk/mdraid_linux.c and disk/dmraid_nvidia.c and lib/crc.c.
8620 (pkglib_MODULES): Add raid5rec.mod, raid6rec.mod, mdraid.mod and
8621 dm_nv.mod.
8622 (raid5rec_mod_SOURCES): New macro.
8623 (raid5rec_mod_CFLAGS): Likewise.
8624 (raid5rec_mod_LDFLAGS): Likewise.
8625 (raid6rec_mod_SOURCES): Likewise.
8626 (raid6rec_mod_CFLAGS): Likewise.
8627 (raid6rec_mod_LDFLAGS): Likewise.
8628 (mdraid_mod_SOURCES): Likewise.
8629 (mdraid_mod_CFLAGS): Likewise.
8630 (mdraid_mod_LDFLAGS): Likewise.
8631 (dm_nv_mod_SOURCES): Likewise.
8632 (dm_nv_mod_CFLAGS): Likewise.
8633 (dm_nv_mod_LDFLAGS): Likewise.
8634
8635 * conf/i386-pc.rmk (grub_setup_SOURCES): Add disk/mdraid_linux.c.
8636 (grub_emu_SOURCES): Add disk/raid5_recover.c, disk/raid6_recover.c,
8637 disk/mdraid_linux.c and disk/dmraid_nvidia.c.
8638
8639 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add disk/raid5_recover.c,
8640 disk/raid6_recover.c, disk/mdraid_linux.c and disk/dmraid_nvidia.c.
8641
8642 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
8643
8644 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
8645
8646 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8647
8648 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
8649
8650 * disk/raid5_recover.c: New file.
8651
8652 * disk/raid6_recover.c: Likewise.
8653
8654 * disk/mdraid_linux.c: Likewise.
8655
8656 * disk/dmraid_nvidia.c: Likewise.
8657
8658 * disk/i386/pc/biosdisk.c: Set total_sectors of cdrom device to
8659 ULONG_MAX.
8660
8661 * disk/raid.c (grub_raid_open): Use the size of the smallest disk to
8662 calculate the size of raid device.
8663 (grub_raid_read): Simplify raid0 code. Support raid4, raid6 and four
8664 different layout of raid5.
8665 (grub_raid_scan_device): Remove code specific to mdraid.
8666 (grub_raid_list): New variable.
8667 (free_array): New function.
8668 (grub_raid_register): Likewise.
8669 (grub_raid_unregister): Likewise.
8670 (grub_raid_rescan): Likewise.
8671 (GRUB_MOD_INIT): Don't iterate device here.
8672 (GRUB_MOD_FINI): Use free_array to release resource.
8673
8674 * include/grub/raid.h: Remove macro and structure specific to mdraid.
8675 (grub_raid5_recover_func_t): New function variable type.
8676 (grub_raid6_recover_func_t): Likewise.
8677 (grub_raid5_recover_func): New variable.
8678 (grub_raid6_recover_func): Likewise.
8679 (grub_raid_register): New function.
8680 (grub_raid_unregister): Likewise.
8681 (grub_raid_rescan): Likewise.
8682 (grub_raid_block_xor): Likewise.
8683
8684 * util/grub-fstest.c: Add #include <grub/raid.h> and <grub/lib/crc.h>.
8685 (CMD_CRC): New macro.
8686 (part): Removed.
8687 (read_file): Handle device as well as file.
8688 (cmd_crc): New function.
8689 (fstest): Handle multiple disks.
8690 (options): Remove part, raw and long, add root and diskcount.
8691 (usage): Add crc, remove -p, -r, -l, add -r and -c.
dba3f844 8692 (main): Find the first non option entry and ignore subsequent options,
5ed20adc 8693 add handling for the new options, support multiple disks.
8694
8695 * util/grub-probe.c (probe): Add mdraid to abstraction_name.
8696
29c18915 86972008-08-23 Bean <bean123ch@gmail.com>
8698
8699 * normal/x86_64/setjmp.S (grub_longjmp): Return 1 when val = 0.
8700
8701 * genfslist.sh: Ignore kernel.mod.
8702
8703 * genpartmaplist.sh: Likewise.
8704
8415f261 87052008-08-23 Robert Millan <rmh@aybabtu.com>
8706
8707 * util/getroot.c (find_root_device): Skip anything that starts with
8708 a dot, not just directories. This avoids things like /dev/.tmp.md0.
8709
d5a7dc5b 87102008-08-22 Felix Zielcke <fzielcke@z-51.de>
81a06771 8711
d5a7dc5b 8712 * util/update-grub.in (GRUB_GFXMODE): Export variable.
8713 * util/grub.d/00_header.in: Allow the administrator to change default
8714 gfxmode via ${GRUB_GFXMODE}.
8715
380cfbb4 87162008-08-21 Felix Zielcke <fzielcke@z-51.de>
8717
8718 * fs/ntfs.c (grub_ntfs_mount): Fix a memory leak.
8719
c9baafe7 87202008-08-21 Robert Millan <rmh@aybabtu.com>
8721
8722 * loader/i386/linux.c: New file. Implements generic 32-bit Linux
8723 loader.
8724 * conf/i386-coreboot.rmk (_linux_mod_SOURCES): Replace
8725 `loader/i386/pc/linux.c' with `loader/i386/linux.c'.
8726
e290bef2 87272008-08-20 Carles Pina i Estany <carles@pina.cat>
8728
8729 * menu/normal.c (run_menu): Replace hardcoded numbers with macros
8730 (16 for GRUB_TERM_UP and 14 for GRUB_TERM_DOWN)
8731
f9dbfc96 87322008-08-19 Robert Millan <rmh@aybabtu.com>
8733
8734 * term/gfxterm.c (DEFAULT_CURSOR_COLOR): Remove.
8735 (struct grub_virtual_screen): Remove `cursor_color'.
8736 (grub_virtual_screen_setup): Remove `virtual_screen.cursor_color'
8737 initialization.
8738 (write_cursor): Use `virtual_screen.fg_color' to draw cursor.
8739
dd6bd6ab 87402008-08-18 Robert Millan <rmh@aybabtu.com>
8741
8742 Unify (identical) linux_normal.c files.
8743 * loader/i386/efi/linux_normal.c: Move from here ...
8744 * loader/linux_normal.c: ... to here. Update all users.
8745 * loader/i386/pc/linux_normal.c: Delete. Update all users.
8746 * loader/i386/ieee1275/linux_normal.c: Likewise.
8747
7f42f83e 87482008-08-18 Robert Millan <rmh@aybabtu.com>
8749
8750 * include/grub/i386/linux.h (LINUX_LOADER_ID_LILO)
8751 (LINUX_LOADER_ID_LOADLIN, LINUX_LOADER_ID_BOOTSECT)
8752 (LINUX_LOADER_ID_SYSLINUX, LINUX_LOADER_ID_ETHERBOOT)
8753 (LINUX_LOADER_ID_ELILO, LINUX_LOADER_ID_GRUB, LINUX_LOADER_ID_UBOOT)
8754 (LINUX_LOADER_ID_XEN, LINUX_LOADER_ID_GUJIN, LINUX_LOADER_ID_QEMU):
8755 New macros.
8756 (GRUB_LINUX_CL_OFFSET, GRUB_LINUX_CL_END_OFFSET): Move from here ...
8757 * loader/i386/pc/linux.c (GRUB_LINUX_CL_OFFSET)
8758 (GRUB_LINUX_CL_END_OFFSET): ... to here.
8759 * loader/i386/efi/linux.c (GRUB_EFI_CL_OFFSET): Rename to ...
8760 (GRUB_LINUX_CL_OFFSET): ... this. Update all users.
8761 (GRUB_EFI_CL_END_OFFSET): Rename to ...
8762 (GRUB_LINUX_CL_END_OFFSET): ... this. Update all users.
8763 (grub_rescue_cmd_linux): Macroify `type_of_loader' initialization.
8764 Initialize `params->video_cursor_x' and `params->video_cursor_y'
8765 portably using grub_getxy().
8766 Replace `-EFI' with `-bzImage' in boot message.
8767
38487ddb 87682008-08-17 Robert Millan <rmh@aybabtu.com>
8769
8770 * include/grub/x86_64/kernel.h: New file (<grub/i386/kernel.h> stub).
8771
deceb3ec 87722008-08-17 Robert Millan <rmh@aybabtu.com>
8773
8774 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pc/mmap.c'.
8775
8776 * include/grub/i386/pc/init.h (GRUB_MACHINE_MEMORY_AVAILABLE)
8777 (GRUB_MACHINE_MEMORY_RESERVED): New macros.
8778 (grub_machine_mmap_iterate): New function declaration.
8779 * include/grub/multiboot.h (struct grub_multiboot_mmap_entry): New
8780 structure.
8781 (GRUB_MMAP_MEMORY_AVAILABLE, GRUB_MMAP_MEMORY_RESERVED): New
8782 macros.
8783
8784 * kern/i386/pc/init.c (grub_machine_init): Replace hardcoded region
8785 type check value with `GRUB_MACHINE_MEMORY_AVAILABLE'.
8786 Move e820 parsing from here ...
8787 * kern/i386/pc/mmap.c: New file.
8788 (grub_machine_mmap_iterate): ... to here.
8789
8790 * include/grub/i386/coreboot/memory.h: Remove `<grub/err.h>'.
8791 (GRUB_LINUXBIOS_MEMORY_AVAILABLE): Rename (for consistency) to ...
8792 (GRUB_MACHINE_MEMORY_AVAILABLE): ... this. Update all users.
8793 (grub_available_iterate): Redeclare to return `void', and redeclare
8794 its hook to use grub_uint64_t as addr and size parameters, and rename
8795 to ...
8796 (grub_machine_mmap_iterate): ... this. Update all users.
8797
8798 * kern/i386/coreboot/mmap.c (grub_mmap_iterate): Simplify parser loop
8799 to make it more readable. Rename to ...
8800 (grub_machine_mmap_iterate): ... this.
8801
8802 * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): New variables.
8803 (grub_get_multiboot_mmap_len, grub_fill_multiboot_mmap): New functions.
8804 (grub_multiboot): Allocate an extra region after the payload, and fill
8805 it with a Multiboot memory map. Adjust a.out loader to calculate size
8806 with the extra space.
8807 (grub_multiboot_load_elf32): Adjust elf32 loader to calculate size
8808 with the extra space.
8809
f8aa0f43 88102008-08-17 Carles Pina i Estany <carles@pina.cat>
8811
9807deb9 8812 * menu/normal.c (run_menu): Add Home and End keys in grub-menu.
f8aa0f43 8813
605f5bb6 88142008-08-17 Felix Zielcke <fzielcke@z-51.de>
8815
8816 * gendistlist.sh: Add *.y, *.tex, *.texi, grub.cfg, README, *.sc,
8817 mdate-sh to the list `find' searches for.
8818 * DISTLIST: Regenerated.
8819
210db6c6 88202008-08-16 Felix Zielcke <fzielcke@z-51.de>
8821
8822 * gendistlist.sh (EXTRA_DISTFILES): Remove gensymlist.sh,
8823 genkernsyms.sh. Add geninit.sh, geninitheader.sh, genkernsyms.sh.in,
48cdbfd4 8824 genmoddep.awk, gensymlist.sh.in.
8825 (DISTDIRS): Add bus, docs, hook, lib.
210db6c6 8826 * DISTLIST: Regenerated.
48cdbfd4 8827 * NEWS: Add cygwin support and change the `os-prober' entry a bit.
210db6c6 8828
1082b929 88292008-08-16 Robert Millan <rmh@aybabtu.com>
8830
8831 * disk/raid.c (grub_raid_init): Handle/report errors set by
8832 grub_device_iterate().
8833 * disk/lvm.c (grub_lvm_init): Likewise.
8834
42ce5170 88352008-08-15 Bean <bean123ch@gmail.com>
8836
8837 * conf/i386-pc.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8838 and datehook.mod.
8839 (datetime_mod_SOURCES): New macro.
8840 (datetime_mod_CFLAGS): Likewise.
8841 (datetime_mod_LDFLAGS): Likewise.
8842 (date_mod_SOURCES): Likewise.
8843 (date_mod_CFLAGS): Likewise.
8844 (date_mod_LDFLAGS): Likewise.
8845 (datehook_mod_SOURCES): Likewise.
8846 (datehook_mod_CFLAGS): Likewise.
8847 (datehook_mod_LDFLAGS): Likewise.
8848
8849 * conf/i386-coreboot.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8850 and datehook.mod.
8851 (datetime_mod_SOURCES): New macro.
8852 (datetime_mod_CFLAGS): Likewise.
8853 (datetime_mod_LDFLAGS): Likewise.
8854 (date_mod_SOURCES): Likewise.
8855 (date_mod_CFLAGS): Likewise.
8856 (date_mod_LDFLAGS): Likewise.
8857 (datehook_mod_SOURCES): Likewise.
8858 (datehook_mod_CFLAGS): Likewise.
8859 (datehook_mod_LDFLAGS): Likewise.
8860
8861 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8862 and datehook.mod.
8863 (datetime_mod_SOURCES): New macro.
8864 (datetime_mod_CFLAGS): Likewise.
8865 (datetime_mod_LDFLAGS): Likewise.
8866 (date_mod_SOURCES): Likewise.
8867 (date_mod_CFLAGS): Likewise.
8868 (date_mod_LDFLAGS): Likewise.
8869 (datehook_mod_SOURCES): Likewise.
8870 (datehook_mod_CFLAGS): Likewise.
8871 (datehook_mod_LDFLAGS): Likewise.
8872
8873 * conf/i386-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8874 and datehook.mod.
8875 (datetime_mod_SOURCES): New macro.
8876 (datetime_mod_CFLAGS): Likewise.
8877 (datetime_mod_LDFLAGS): Likewise.
8878 (date_mod_SOURCES): Likewise.
8879 (date_mod_CFLAGS): Likewise.
8880 (date_mod_LDFLAGS): Likewise.
8881 (datehook_mod_SOURCES): Likewise.
8882 (datehook_mod_CFLAGS): Likewise.
8883 (datehook_mod_LDFLAGS): Likewise.
8884
8885 * conf/x86_64-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod
8886 and datehook.mod.
8887 (datetime_mod_SOURCES): New macro.
8888 (datetime_mod_CFLAGS): Likewise.
8889 (datetime_mod_LDFLAGS): Likewise.
8890 (date_mod_SOURCES): Likewise.
8891 (date_mod_CFLAGS): Likewise.
8892 (date_mod_LDFLAGS): Likewise.
8893 (datehook_mod_SOURCES): Likewise.
8894 (datehook_mod_CFLAGS): Likewise.
8895 (datehook_mod_LDFLAGS): Likewise.
8896
8897 * kern/env.c (grub_env_insert): Fix a bug in prevp pointer.
8898
8899 * commands/date.c: New file.
8900
8901 * hook/datehook.c: Likewise.
8902
8903 * include/grub/lib/datetime.h: Likewise.
8904
8905 * include/grub/i386/cmos.h: Likewise.
8906
8907 * lib/datetime.c: Likewise.
8908
8909 * lib/i386/datetime.c: Likewise.
8910
8911 * lib/efi/datetime.c: Likewise.
8912
0e9242da 89132008-08-14 Robert Millan <rmh@aybabtu.com>
8914
8915 * conf/common.rmk (bin_UTILITIES): Add `grub-mkelfimage'.
8916 (grub_mkelfimage_SOURCES): New variable.
8917 (util/elf/grub-mkimage.c_DEPENDENCIES): Likewise.
8918
8919 * conf/i386-coreboot.rmk (bin_UTILITIES, grub_mkimage_SOURCES)
8920 (grub_mkimage_LDFLAGS, util/elf/grub-mkimage.c_DEPENDENCIES): Remove.
8921 * conf/powerpc-ieee1275.rmk: Likewise.
8922 * conf/i386-ieee1275.rmk: Likewise.
8923
8924 * kern/ieee1275/init.c: Include `<grub/cpu/kernel.h>'.
8925 * kern/i386/coreboot/init.c: Likewise.
8926
8927 * kern/i386/ieee1275/startup.S: Replace `<grub/machine/kernel.h>'
8928 with `<grub/cpu/kernel.h>'.
8929 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Renamed
8930 to ...
8931 (GRUB_KERNEL_CPU_PREFIX, GRUB_KERNEL_CPU_DATA_END): ... this.
8932 * kern/i386/coreboot/startup.S: Likewise.
8933
8934 * include/grub/powerpc/ieee1275/kernel.h (GRUB_MOD_ALIGN)
8935 (GRUB_MOD_GAP): Remove.
8936 * include/grub/powerpc/kernel.h: New file.
8937 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX)
8938 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
8939 * include/grub/i386/kernel.h: New file.
8940 * include/grub/i386/coreboot/kernel.h (GRUB_MOD_ALIGN)
8941 (GRUB_MOD_GAP, GRUB_KERNEL_MACHINE_PREFIX)
8942 (GRUB_KERNEL_MACHINE_DATA_END): Remove.
8943
8944 * util/ieee1275/grub-install.in (grub_mkimage): Initialize to use
8945 `grub-mkelfimage'.
8946 Use --directory when invoking grub_mkimage.
8947
8948 * util/elf/grub-mkimage.c: Include `<grub/cpu/kernel.h>'.
8949 (add_segments): Replace GRUB_KERNEL_MACHINE_DATA_END and
8950 GRUB_KERNEL_MACHINE_PREFIX with GRUB_KERNEL_CPU_DATA_END
8951 and GRUB_KERNEL_CPU_PREFIX.
8952
b86408f8 89532008-08-14 Felix Zielcke <fzielcke@z-51.de>
8954
d5e619ca 8955 * include/grub/err.h (grub_err_printf): New function prototype.
8956 * util/misc.c (grub_err_printf): New function.
8957 * kern/misc.c [! GRUB_UTIL] (grub_err_printf): New alias for
8958 grub_printf.
8959 * kern/err.c (grub_print_error): Use grub_err_printf.
b86408f8 8960
7161f0e0 89612008-08-13 Robert Millan <rmh@aybabtu.com>
8962
8963 * docs/grub.cfg: Remove `/dev/' prefix in GNU/Hurd boot entry.
8964
a1967522 89652008-08-13 Robert Millan <rmh@aybabtu.com>
8966
8967 * docs/grub.cfg: Use the native device name for the example GNU/Hurd
8968 boot entry.
8969
371458b5 89702008-08-12 Robert Millan <rmh@aybabtu.com>
8971
8972 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Move part
8973 of the relocation code from here ...
8974 (grub_multiboot): ... to here.
8975 (forward_relocator, backward_relocator): Move from here ...
8976 * kern/i386/loader.S (grub_multiboot_forward_relocator)
8977 (grub_multiboot_backward_relocator): ... to here.
8978 (grub_multiboot_real_boot): Use %edx for entry offset. Put Multiboot
8979 magic in %eax. Use %ebp for jumping (so %edx is not trashed).
8980 * include/grub/i386/loader.h (grub_multiboot_forward_relocator)
8981 (grub_multiboot_forward_relocator_end)
8982 (grub_multiboot_backward_relocator)
8983 (grub_multiboot_backward_relocator_end): New variables.
8984
05f9452b 89852008-08-12 Bean <bean123ch@gmail.com>
8986
8987 * disk/raid.c (grub_raid_read): Fix a bug in raid0 code.
8988
20024ab0 89892008-08-11 Robert Millan <rmh@aybabtu.com>
8990
8991 * kern/i386/linuxbios/startup.S: Move from here ...
8992 * kern/i386/coreboot/startup.S: ... to here.
8993
8994 * kern/i386/linuxbios/init.c: Move from here ...
8995 * kern/i386/coreboot/init.c: ... to here.
8996
8997 * kern/i386/linuxbios/table.c: Move from here ...
8998 * kern/i386/coreboot/mmap.c: ... to here.
8999
9000 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Update moved files.
9001
e352e9cd 90022008-08-11 Robert Millan <rmh@aybabtu.com>
9003
9004 * kern/device.c (grub_device_open): Do not handle grub_disk_open()
9005 errors. Leave it to the upper layer to handle them.
9006
2d05bc6a 90072008-08-09 Christian Franke <franke@computer.org>
9008
9009 * Makefile.in: Add `target_os' and `enable_grub_pe2elf'.
9010 * conf/common.rmk: Install `grub-pe2elf' only if requested.
9011 Install `grub.d/10_windows' only on Cygwin.
9012 * configure.ac: Add subst of `target_os'.
9013 Check `target_os' also before setting TARGET_OBJ2ELF.
9014 Add `--enable-grub-pe2elf'.
9015
042bd419 90162008-08-08 Robert Millan <rmh@aybabtu.com>
9017
9018 * kern/disk.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
9019 (grub_last_time): Change type to grub_uint64_t.
9020 (grub_disk_open): Migrate code from to using grub_get_time_ms().
9021 (grub_disk_close): Likewise.
9022
9023 * normal/menu.c: Replace `<grub/machine/time.h>' with `<grub/time.h>'.
9024 (run_menu): Migrate code from to using grub_get_time_ms().
9025
9026 * util/misc.c (grub_get_time_ms): New function.
9027
7f280db5 90282008-08-08 Marco Gerards <marco@gnu.org>
9029
9030 * disk/ata.c (grub_ata_regget): Change return type to
9031 `grub_uint8_t'.
9032 (grub_ata_regget2): Likewise.
9033 (grub_ata_wait_status): New function.
9034 (grub_ata_wait_busy): Removed function, updated all users to use
9035 `grub_ata_wait_status'.
9036 (grub_ata_wait_drq): Likewise.
9037 (grub_ata_cmd): New function.
9038 (grub_ata_pio_read): Change return type to `grub_uint8_t'. Add
9039 error handling.
9040 (grub_ata_pio_write): Add error handling.
9041 (grub_atapi_identify): Likewise.
9042 (grub_atapi_packet): Use `grub_ata_cmd' and improve error
9043 handling.
9044 (grub_ata_identify): Use `grub_ata_cmd' and improve error
9045 handling. Actually use the detected registers. Reorder the
9046 detection logic such that it is easier to read.
9047 (grub_ata_pciinit): Do not assign the same ID to each controller.
9048 (grub_ata_setaddress): Use `grub_ata_cmd' and improve error
9049 handling.
9050 (grub_atapi_readsector): Check the result of `grub_ata_pio_read'.
9051
9052 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TIMEOUT'.
9053
1fbc5e66 90542008-08-08 Marco Gerards <marco@gnu.org>
9055
9056 * NEWS: Update.
9057
819ce6c0 90582008-08-07 Bean <bean123ch@gmail.com>
9059
9060 * include/grub/x86_64/pci.h: New file.
9061
5c41d44d 90622008-08-07 Christian Franke <franke@computer.org>
9063
9064 * kern/i386/pit.c (TIMER2_SPEAKER): New define.
9065 (TIMER2_GATE): Likewise.
9066 (grub_pit_wait): Add enable/disable of the timer2 gate
9067 bit of port 0x61. This fixes a possible infinite loop.
9068
5ebc275d 90692008-08-07 Bean <bean123ch@gmail.com>
9070
9071 * conf/x86_64-efi.rmk (kernel_mod_SOURCES): Add kern/time.c,
9072 kern/i386/tsc.c and kern/i386/pit.c.
9073
9074 * include/grub/i386/tsc.h (grub_cpu_is_cpuid_supported): Handle
9075 x86_64 platform.
9076
9077 * kern/i386/efi/init.c: Replace <grub/cpu/tsc.h> with
9078 <grub/i386/tsc.h>.
9079
9080 * kern/i386/pit.c: Replace <grub/cpu/io.h> with <grub/i386/io.h>.
9081
e383b3d0 90822008-08-07 Bean <bean123ch@gmail.com>
9083
9084 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add kern/time.c.
9085
9086 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add kern/time.c,
9087
9088 * include/grub/i386/pit.h: Use macro KERNEL_CPU_PIT_HEADER to avoid
9089 multiple inclusion. Add #include <grub/types.h>.
9090
1cbb58ac 90912008-08-06 Christian Franke <franke@computer.org>
9092
9093 * conf/common.rmk: Build and install `10_windows'.
9094 * util/grub.d/10_windows.in: New script.
9095
337f5a1e 90962008-08-06 Pavel Roskin <proski@gnu.org>
9097
9098 * kern/i386/pit.c: Include `<grub/i386/pit.h>'.
9099
057bc4ac 91002008-08-06 Robert Millan <rmh@aybabtu.com>
9101
9102 * conf/i386-coreboot.rmk (kernel_elf_ASFLAGS): New variable.
9103 * kern/i386/tsc.c: Include `<grub/i386/pit.h>'.
9104
2b99f123 91052008-08-06 Bean <bean123ch@gmail.com>
9106
9107 * fs/i386/pc/pxe.c (grub_pxe_data): New member block_size.
9108 (grub_pxefs_fs_int): Remove dummy definition.
9109 (grub_pxefs_open): Use data->block_size to store the current block
9110 size setting.
9111 (grub_pxefs_read): Use block size stored in data->block_size. As the
9112 value of grub_pxe_blksize can be changed after the file is opened.
9113
9f0234cb 91142008-08-06 Bean <bean123ch@gmail.com>
9115
9116 * fs/i386/pc/pxe.c (curr_file): new variable.
9117 (grub_pxefs_open): Simply the handling of pxe file system. Don't
9118 require the dummy internal file system anymore.
9119 (grub_pxefs_read): Removed.
9120 (grub_pxefs_close): Likewise.
9121 (grub_pxefs_fs_int): Likewise.
9122 (grub_pxefs_read_int): Renamed to grub_pxefs_read. Reinitialize tftp
9123 connection when we switch file.
9124 (grub_pxefs_close_int): Renamed to grub_pxefs_close.
9125
a55d42e0 91262008-08-06 Robert Millan <rmh@aybabtu.com>
9127
9128 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `reboot.mod' and
9129 `halt.mod'.
9130 (reboot_mod_SOURCES, reboot_mod_CFLAGS, reboot_mod_LDFLAGS)
9131 (halt_mod_SOURCES, halt_mod_CFLAGS, halt_mod_LDFLAGS): New variables.
9132
9133 * kern/i386/halt.c: New file.
9134 * kern/i386/reboot.c: Likewise.
9135 * include/grub/i386/reboot.h: Likewise.
9136 * include/grub/i386/halt.h: Likewise.
9137
9138 * commands/halt.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]:
9139 Include `<grub/cpu/halt.h>'.
9140 * commands/reboot.c [! GRUB_MACHINE_IEEE1275 ! GRUB_MACHINE_EFI]
9141 [! GRUB_MACHINE_PCBIOS]: Include `<grub/cpu/reboot.h>'.
9142
9143 * term/i386/pc/at_keyboard.c: Include `<grub/cpu/at_keyboard.h>'.
9144 (SHIFT_L, SHIFT_R, CTRL, ALT, CAPS_LOCK, KEYBOARD_REG_DATA)
9145 (KEYBOARD_REG_STATUS, KEYBOARD_COMMAND_ISREADY, KEYBOARD_COMMAND_READ)
9146 (KEYBOARD_COMMAND_WRITE, KEYBOARD_COMMAND_REBOOT)
9147 (KEYBOARD_SCANCODE_SET1, KEYBOARD_ISMAKE, KEYBOARD_ISREADY)
9148 (KEYBOARD_SCANCODE, OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): Move
9149 from here ...
9150 * include/grub/i386/at_keyboard.h: ... to here.
9151
24371d26 91522008-08-05 Robert Millan <rmh@aybabtu.com>
9153
9154 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pit.c'.
9155 * conf/i386-efi.rmk (kernel_mod_SOURCES): Likewise.
9156 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Likewise. Also add
9157 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
9158 `kern/generic/millisleep.c'.
9159
9160 * kern/i386/tsc.c (calibrate_tsc): Rewrite using grub_pit_wait()
9161 instead of grub_get_rtc().
9162 (grub_tsc_init): Initialize `tsc_boot_time'.
9163
9164 * kern/i386/linuxbios/init.c (grub_millisleep): Remove stub.
9165 (grub_machine_init): Use grub_tsc_init() rather than
9166 installing an RTC-based handler via grub_install_get_time_ms().
9167
9168 * kern/i386/pit.c: New file.
9169 * include/grub/i386/pit.h: Likewise.
9170
9e7007b3 91712008-08-05 Bean <bean123ch@gmail.com>
9172
9173 * boot/i386/pc/pxeboot.S (_start): Use drive number 0x7F for pxe.
9174
9175 * conf/i386-pc.rmk (kernel_img_HEADERS): Add machine/pxe.h.
9176 (pkglib_MODULES): Add pxe.mod and pxecmd.mod.
9177 (pxe_mod_SOURCES): New macro.
9178 (pxe_mod_CFLAGS): Likewise.
9179 (pxe_mod_LDFLAGS): Likewise.
9180 (pxecmd_mod_SOURCES): Likewise.
9181 (pxecmd_mod_CFLAGS): Likewise.
9182 (pxecmd_mod_LDFLAGS): Likewise.
9183
9184 * kern/i386/pc/startup.S (grub_pxe_scan): New function.
9185 (grub_pxe_call): Likewise.
9186
9187 * include/grub/disk.h (grub_disk_dev_id): Add GRUB_DISK_DEVICE_PXE_ID.
9188
9189 * commands/i386/pc/pxecmd.c: New file.
9190
9f0234cb 9191 * fs/i386/pc/pxe.c: Likewise.
9e7007b3 9192
9193 * include/grub/i386/pc/pxe.h: Likewise.
9194
6977d49f 91952008-08-05 Bean <bean123ch@gmail.com>
9196
9197 * util/console.c (grub_console_cur_color): New variable.
9198 (grub_console_standard_color): Likewise.
9199 (grub_console_normal_color): Likewise.
9200 (grub_console_highlight_color): Likewise.
9201 (color_map): Likewise.
9202 (use_color): Likewise.
9203 (NUM_COLORS): New macro.
9204 (grub_ncurses_setcolorstate): Handle color properly.
9205 (grub_ncurses_setcolor): Don't change color here, just remember the
9206 settings, color will be set in grub_ncurses_setcolorstate.
9207 (grub_ncurses_getcolor): New function.
9208 (grub_ncurses_init): Initialize color pairs.
9209 (grub_ncurses_term): New member grub_ncurses_getcolor.
9210
9c2ff3ee 92112008-08-05 Colin D Bennett <colin@gibibit.com>
337f5a1e 9212
9c2ff3ee 9213 High resolution timer support. Implemented for x86 CPUs using TSC.
9214 Extracted generic grub_millisleep() so it's linked in only as needed.
9215 This requires a Pentium compatible CPU; if the RDTSC instruction is
9216 not supported, then it falls back on the generic grub_get_time_ms()
9217 implementation that uses the machine's RTC.
9218
9219 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/time.c',
9220 `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and
9221 `kern/generic/millisleep.c'.
9222
9223 * conf/i386-efi.rmk (kernel_mod_SOURCES): Add `kern/i386/tsc.c',
9224 `kern/generic/rtc_get_time_ms.c' and `kern/generic/millisleep.c'.
9225
9226 * conf/x86_64-efi.rml (kernel_mod_SOURCES): Add
9227 `kern/generic/millisleep.c' and `kern/generic/rtc_get_time_ms.c'.
9228
9229 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
9230
9231 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add
9232 `kern/generic/millisleep.c'.
9233
9234 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
9235
9236 * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Add `kern/time.c'.
9237
9238 * kern/generic/rtc_get_time_ms.c: New file.
9239
9240 * kern/generic/millisleep.c: New file.
337f5a1e 9241
9c2ff3ee 9242 * kern/misc.c: Don't include
9243 <kern/time.h> anymore.
9244 (grub_millisleep_generic): Removed.
9245
9246 * commands/sleep.c (grub_interruptible_millisleep): Uses
9247 grub_get_time_ms() instead of grub_get_rtc().
9248
9249 * include/grub/i386/tsc.h (grub_get_tsc): New file. New inline
9250 function.
9251 (grub_cpu_is_cpuid_supported): New inline function.
9252 (grub_cpu_is_tsc_supported): New inline function.
9253 (grub_tsc_init): New function prototype.
9254 (grub_tsc_get_time_ms): New function prototype.
9255
9256 * kern/i386/tsc.c (grub_get_time_ms): New file.
9257
9258 * include/grub/time.h: Include <grub/types.h.
9259 (grub_millisleep_generic): Removed.
9260 (grub_get_time_ms): New prototype.
9261 (grub_install_get_time_ms): New prototype.
9262 (grub_rtc_get_time_ms): New prototype.
9263
9264 * kern/time.c (grub_get_time_ms): New function.
9265 (grub_install_get_time_ms): New function.
9266
9267 * kern/i386/efi/init.c: Include <grub/cpu/tsc.h>. Don't include
9268 <grub/time.h> anymore.
9269 (grub_millisleep): Removed.
9270 (grub_machine_init): Call grub_tsc_init.
9271
9272 * kern/i386/linuxbios/init.c (grub_machine_init): Install the RTC
9273 get_time_ms() implementation.
9274
9275 * kern/sparc64/ieee1275/init.c (grub_millisleep): Removed.
9276 (ieee1275_get_time_ms): New function.
9277 (grub_machine_init): Install get_time_ms() implementation.
9278
9279 * kern/i386/pc/init.c: Include <grub/cpu/tsc.h>.
9280 (grub_machine_init): Call grub_tsc_init().
9281 (grub_millisleep): Removed.
bf06a93f 9282
9c2ff3ee 9283 * kern/ieee1275/init.c (grub_millisleep): Removed.
9284 (grub_machine_init): Install ieee1275_get_time_ms()
9285 implementation.
9286 (ieee1275_get_time_ms): New function.
9287 (grub_get_rtc): Now calls ieee1275_get_time_ms(), which does the
9288 real work.
9289
9ec92aaf 92902008-08-05 Marco Gerards <marco@gnu.org>
9291
9292 * disk/ata.c: Include <grub/pci.h>.
9293 (enum grub_ata_commands): Add `GRUB_ATA_CMD_EXEC_DEV_DIAGNOSTICS'.
9294 (grub_ata_initialize): Rewritten.
9295 (grub_ata_device_initialize): New function.
9296
8d23f507 92972008-08-04 Pavel Roskin <proski@gnu.org>
9298
9299 * kern/main.c: Include grub/mm.h.
9300
5e15ee3d 93012008-08-04 Robert Millan <rmh@aybabtu.com>
9302
9303 * conf/i386-coreboot.rmk (COMMON_ASFLAGS, COMMON_CFLAGS)
9304 (COMMON_LDFLAGS): Harmonize with i386-pc version (fixes a code
9305 corruption problem).
9306
a9053f8f 93072008-08-04 Robert Millan <rmh@aybabtu.com>
9308
9309 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Fix misc
9310 warnings introduced in my last commit.
9311
dd19c7d7 93122008-08-03 Robert Millan <rmh@aybabtu.com>
9313
9314 Make PCI available on all i386 architectures.
9315
9316 * include/grub/i386/pc/pci.h: Move from here ...
9317 * include/grub/i386/pci.h: ... to here.
9318
9319 * include/grub/i386/pc/pci.h: Remove.
9320 * include/grub/i386/efi/pci.h: Remove.
9321 * include/grub/x86_64/efi/pci.h: Remove.
9322
9323 * include/grub/pci.h: Replace `<grub/machine/pci.h>' with
9324 `<grub/cpu/pci.h>'.
9325
9326 * conf/i386-coreboot.rmk (pkglib_MODULES): Add `pci' and `lspci'.
9327 (pci_mod_SOURCES, pci_mod_CFLAGS, pci_mod_LDFLAGS, lspci_mod_SOURCES)
9328 (lspci_mod_CFLAGS, lspci_mod_LDFLAGS): New variables.
9329
9330 * conf/i386-ieee1275.rmk: Likewise.
9331
e14a6184 93322008-08-03 Robert Millan <rmh@aybabtu.com>
9333
9334 * term/i386/pc/vga_text.c (CRTC_CURSOR_DISABLE): New macro.
9335 (grub_console_setcursor): Make it possible to set cursor off.
9336
52768e37 93372008-08-03 Robert Millan <rmh@aybabtu.com>
9338
9339 * util/grub.d/00_header.in: Be platform-agnostic. Probe for existence
9340 of modules instead of assuming which platform provides what.
9341 * util/update-grub.in: Likewise.
9342
2d52f57f 93432008-08-03 Robert Millan <rmh@aybabtu.com>
9344
9345 * kern/i386/pc/init.c (make_install_device): Check for `grub_prefix'
9346 instead of `grub_install_dos_part' to determine whether a drive needs
9347 to be prepended to prefix (`grub_install_dos_part' is not reliable,
825aa57a 9348 because it can be overridden when loading GRUB via Multiboot).
2d52f57f 9349
2a5cd121 93502008-08-02 Robert Millan <rmh@aybabtu.com>
9351
9352 * util/i386/pc/grub-install.in: Remove trailing slash from prefix.
9353
93808428 93542008-08-02 Robert Millan <rmh@aybabtu.com>
9355
9356 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Add a pair
9357 of informational grub_dprintf() calls.
9358
3bd0a12a 93592008-08-02 Robert Millan <rmh@aybabtu.com>
9360
9361 * disk/memdisk.c (memdisk_size): Don't initialize.
9362 (GRUB_MOD_INIT(memdisk)): Find memdisk using grub_module_iterate().
9363
9364 * include/grub/i386/pc/kernel.h
9365 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): Remove macro.
9366 (GRUB_KERNEL_MACHINE_PREFIX, GRUB_KERNEL_MACHINE_DATA_END): Shift.
9367 (grub_memdisk_image_size, grub_arch_memdisk_addr)
9368 (grub_arch_memdisk_size): Remove.
9369
9370 * include/grub/kernel.h (struct grub_module_header): Remove `offset'
9371 field (was only used to transfer a constant). Add `type' field to
9372 support multiple module types.
9373 (grub_module_iterate): New function.
9374
9375 * kern/device.c (grub_device_open): Do not hide error messages
9376 when grub_disk_open() fails. Use grub_print_error() instead.
9377
9378 * kern/i386/pc/init.c (grub_arch_modules_addr)
9379 (grub_arch_memdisk_size): Remove functions.
9380 (grub_arch_modules_addr): Return the module address in high memory
9381 (now that it isn't copied anymore).
9382
9383 * kern/i386/pc/startup.S (grub_memdisk_image_size): Remove variable.
9384 (codestart): Don't add grub_memdisk_image_size to %ecx in LZMA
9385 decompression routine (grub_total_module_size already includes that
9386 now). Don't copy modules back to low memory.
9387
9388 * kern/main.c: Include `<grub/mm.h>'.
9389 (grub_load_modules): Split out (and use) ...
9390 (grub_module_iterate): ... this function, which iterates through
9391 module objects and runs a hook.
9392 Comment out grub_mm_init_region() call, as it would cause non-ELF
9393 modules to be overwritten.
9394
9395 * util/i386/pc/grub-mkimage.c (generate_image): Instead of appending
9396 the memdisk image in its own region, make it part of the module list.
9397 * util/elf/grub-mkimage.c (options): Add "memdisk"|'m' option.
9398 (main): Parse --memdisk|-m option, and pass user-provided path as
9399 parameter to generate_image().
9400 (add_segments): Pass `memdisk_path' down to load_modules().
9401 (load_modules): Embed memdisk image in module section when requested.
9402 * util/i386/efi/grub-mkimage.c (make_mods_section): Initialize
9403 `header.type' instead of `header.offset'.
9404
9405 * conf/powerpc-ieee1275.rmk (pkglib_MODULES): Add `memdisk.mod'.
9406 (memdisk_mod_SOURCES, memdisk_mod_CFLAGS)
9407 (memdisk_mod_LDFLAGS): New variables.
9408 * conf/i386-coreboot.rmk: Likewise.
9409 * conf/i386-ieee1275.rmk: Likewise.
9410
a927cc73 94112008-08-02 Robert Millan <rmh@aybabtu.com>
9412
9413 * loader/i386/pc/multiboot.c (playground, forward_relocator)
9414 (backward_relocator): New variables. Used to allocate and relocate
9415 the payload, respectively.
9416 (grub_multiboot_load_elf32): Load into heap instead of requested
825aa57a 9417 address, install the appropriate relocator code in each bound of
a927cc73 9418 the payload, and set the entry point such that
9419 grub_multiboot_real_boot() will jump to one of them.
9420
9421 * kern/i386/loader.S (grub_multiboot_payload_size)
9422 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
9423 (grub_multiboot_payload_entry_offset): New variables.
9424 (grub_multiboot_real_boot): Set cpu context to what the relocator
9425 expects, and jump to the relocator instead of the payload.
9426
9427 * include/grub/i386/loader.h (grub_multiboot_payload_size)
9428 (grub_multiboot_payload_orig, grub_multiboot_payload_dest)
9429 (grub_multiboot_payload_entry_offset): Export.
9430
b15d8a0c 94312008-08-01 Bean <bean123ch@gmail.com>
9432
9433 * normal/menu_entry.c (editor_getline): Don't return the original
9434 string as result, as it will be released by lexer once it has done
9435 using it.
9436
cdfb3d22 94372008-08-01 Robert Millan <rmh@aybabtu.com>
9438
9439 * util/grub.d/10_linux.in: Use prepare_grub_to_access_device() from
9440 within menuentries, not before them.
9441 util/grub.d/10_hurd.in: Likewise.
9442
9175e93d 94432008-08-01 Bean <bean123ch@gmail.com>
9444
9445 * conf/common.rmk (pkglib_MODULES): Add bufio.mod.
9446 (bufio_mod_SOURCES): New macro.
9447 (bufio_mod_CFLAGS): Likewise.
9448 (bufio_mod_LDFLAGS): Likewise.
9449
9450 * include/grub/bufio.h: New file.
9451
9452 * io/bufio.c: Likewise.
9453
9454 * video/png.c: Replace <grub/file.h> with <grub/bufio.h>.
9455 (grub_video_reader_png): Use grub_buffile_open to open file.
9456
9457 * video/jpeg.c: Replace <grub/file.h> with <grub/bufio.h>.
9458 (grub_video_reader_jpeg): Use grub_buffile_open to open file.
9459
9460 * video/tga.c: Replace <grub/file.h> with <grub/bufio.h>.
9461 (grub_video_reader_tga): Use grub_buffile_open to open file.
9462
9463 * font/manager.c: Include <grub/bufio.h>.
9464 (add_font): Use grub_buffile_open to open file.
9465
3d8383e7 94662008-07-31 Robert Millan <rmh@aybabtu.com>
9467
9468 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): When loading
9469 ELF segments, use a macro for arbitrarily accessing any of them instead
9470 of preparing a pointer that allows access to one at a time.
9471 (grub_multiboot_load_elf64): Likewise.
9472
16e641b6 94732008-07-31 Bean <bean123ch@gmail.com>
9474
9475 * boot/i386/pc/lnxboot.S (real_code_2): Replace 0x50 with
9476 GRUB_KERNEL_MACHINE_DATA_END.
9477
59198b72 94782008-07-30 Robert Millan <rmh@aybabtu.com>
9479
9480 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_DATA_END):
9481 Increase from 0x50 to 0x60.
9482 * util/i386/pc/grub-install.in: Detect cross-disk installs, and
9483 use UUIDs to identify the root drive for them. If that's not
9484 possible, abort.
9485 * util/i386/pc/grub-setup.c (setup): Do not special-case, or even
9486 check, for cross-disk installs.
9487
ae88bca3 94882008-07-30 Robert Millan <rmh@aybabtu.com>
9489
9490 * kern/ieee1275/init.c (grub_machine_set_prefix): If `grub_prefix'
9491 is non-empty, use it to set the `prefix' environment variable instead
9492 of the usual approach.
9493 * kern/i386/linuxbios/init.c (make_install_device): Remove function.
9494 (grub_machine_set_prefix): Use `grub_prefix' to set the `prefix'
9495 environment variable instead of dummy make_install_device().
9496
9497 * kern/i386/ieee1275/startup.S: Include `<grub/machine/kernel.h>'.
9498 (start): Insert a data section, with `grub_prefix' variable.
825aa57a 9499 * kern/i386/linuxbios/startup.S: Likewise.
ae88bca3 9500
9501 * include/grub/powerpc/ieee1275/kernel.h [!ASM_FILE] (grub_prefix):
9502 New variable reference.
9503 * include/grub/i386/ieee1275/kernel.h (GRUB_KERNEL_MACHINE_PREFIX):
9504 New macro. Defines offset of `grub_prefix' within startup.S (relative
9505 to `start').
9506 (GRUB_KERNEL_MACHINE_DATA_END): New macro. Defines the end of data
9507 section within startup.S (relative to `start').
9508 * include/grub/i386/coreboot/kernel.h: Likewise.
9509
9510 * util/elf/grub-mkimage.c (add_segments): Receive `prefix' parameter.
9511 Overwrite grub_prefix with its contents, at the beginning of the
9512 first segment.
9513 (main): Understand -p|--prefix.
9514
14f41dd1 95152008-07-30 Robert Millan <rmh@aybabtu.com>
9516
9517 * util/grub.d/10_hurd.in: Source ${libdir}/grub/update-grub_lib.
9518
4ca049a3 95192008-07-30 Robert Millan <rmh@aybabtu.com>
9520
9521 * term/i386/pc/vga_text.c (grub_console_cls): Use
9522 grub_console_gotoxy() to go back to beginning of the screen.
9523 Found by Patrick Georgi <patrick.georgi@coresystems.de>
9524
2921d337 95252008-07-29 Christian Franke <franke@computer.org>
9526
9527 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
9528 Add conversion of emulated mount points on Cygwin.
9529
b609876d 95302008-07-29 Christian Franke <franke@computer.org>
9531
9532 * util/update-grub.in: Add a check for admin
9533 group on Cygwin.
9534 Remove old `grub.cfg.new' before creation.
9535 Add `-f' to `mv' to handle the different filesystem
9536 semantics of Windows.
9537
e93e4679 95382008-07-29 Bean <bean123ch@gmail.com>
9539
9540 * normal/main.c (get_line): Fix buffer overflow bug.
9541
41694fd0 95422008-07-28 Robert Millan <rmh@aybabtu.com>
9543
9544 * partmap/apple.c (GRUB_APPLE_HEADER_MAGIC): New macro.
9545 (struct grub_apple_header): New struct. Describes the layout of
9546 the partmap header.
9547 (apple_partition_map_iterate): Check the header magic as well as the
9548 partition magic (which was already being checked).
9549
cfd0b4e6 95502008-07-28 Pavel Roskin <proski@gnu.org>
9551
9552 * genmk.rb: Add a warning to the beginning of the output that
9553 it's a generated file and should not be edited.
9554
93cce016 95552008-07-28 Robert Millan <rmh@aybabtu.com>
9556
9557 * disk/raid.c (grub_raid_scan_device): Do not abort when two disks
9558 with the same number are found, just use issue a warning with
9559 grub_dprintf(), as this error has been reported to be non-fatal.
c298def0 9560
cd1df915 95612008-07-27 Robert Millan <rmh@aybabtu.com>
9562
9563 * disk/ata.c (grub_ata_dumpinfo): Use grub_dprintf() for debugging
9564 information.
9565
b70a8427 95662008-07-27 Bean <bean123ch@gmail.com>
9567
9568 * fs/fat.c (GRUB_FAT_MAXFILE): New constant.
9569 (grub_fat_find_dir): Ignore case when comparing filename.
9570
8f5e379f 95712008-07-27 Bean <bean123ch@gmail.com>
9572
9573 * fs/xfs.c (grub_xfs_dir_header): Change field i8count back to
9574 smallino, as it's more descriptive, and i8count can be confused with
9575 the other field count.
9576 (grub_xfs_iterate_dir): Adjust grub_xfs_dir_entry pointer for small
9577 inode type.
9578
a85cd5a0 95792008-07-27 Bean <bean123ch@gmail.com>
9580
9581 * commands/crc.c: New file.
9582
9583 * lib/crc.c: Likewise.
9584
9585 * include/grub/lib/crc.h: Likewise.
9586
9587 * util/grub-fstest.c: grub/hexdump.h => grub/lib/hexdump.h.
9588
9589 * commands/hexdump.c: grub/hexdump.h => grub/lib/hexdump.h.
9590 (hexdump): Move this function to ...
9591
9592 * lib/hexdump.c: ... here.
9593
9594 * include/grub/hexdump.h: Renamed to ...
9595
9596 * include/grub/lib/hexdump.h: ... this.
9597
9598 * commands/loadenv.c: grub/envblk.h => grub/lib/envblk.h
9599
9600 * util/grub-editenv.c: Likewise.
9601
9602 * include/envblk.h: Renamed to ...
9603
9604 * include/lib/envblk.h: ... this.
9605
9606 * util/envblk.c: Renamed to ...
9607
9608 * lib/envblk.c: ... this.
9609
9610 * conf/common.rmk (grub_fstest_SOURCES): commands/hexdump.c =>
9611 lib/hexdump.c.
9612 (grub_editenv_SOURCES): util/envblk.c => lib/envblk.c
9613 (pkglib_MODULES): Add crc.mod.
9614 (hexdump_mod_SOURCES): Add lib/hexdump.c.
9615 (loadenv_mod_SOURCES): util/envblk.c => lib/envblk.c.
9616 (crc_mod_SOURCES): New macro.
9617 (crc_mod_CFLAGS): Likewise.
9618 (crc_mod_LDFLAGS): Likewise.
9619
9620 * conf/i386-coreboot.rmk (grub_emu_SOURCES): Add lib/hexdump.c.
9621
9622 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
9623
9624 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
9625
9626 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
9627
9628 * conf/x86_64-efi.rmk (grub_emu_SOURCES): Likewise.
9629
c298def0 96302008-07-27 Felix Zielcke <fzielcke@z-51.de>
8749e9e5 9631
9632 * commands/help.c: Include <grub/term.h>.
9633 (TERM_WIDTH): Removed. Updated all users.
9634
cc349fb3 96352008-07-27 Pavel Roskin <proski@gnu.org>
9636
9637 * util/getroot.c (find_root_device): Rephrase a comment to avoid
9638 spurious warnings about a comment within a comment.
9639
9051607e 96402008-07-25 Robert Millan <rmh@aybabtu.com>
9641
9642 * util/getroot.c (find_root_device): Skip devices that match
9643 /dev/dm-[0-9]. This lets the real device be found for any type of
9644 abstraction (LVM, EVMS, RAID..).
9645 (grub_guess_root_device): Do not traverse /dev/mapper (for LVM)
9646 and /dev/evms (for EVMS) before traversing /dev. If a /dev/dm-[0-9]
9647 device is found first, find_root_device() will now skip it.
9648
01453bfc 96492008-07-24 Pavel Roskin <proski@gnu.org>
9650
9651 * include/grub/types.h: Use __builtin_bswap32() and
9652 __builtin_bswap64() with gcc 4.3 and newer.
9653
6af9849f 96542008-07-24 Christian Franke <franke@computer.org>
9655
3a0fa256 9656 * util/i386/pc/grub-install.in: If `--debug' is specified,
9657 pass `--verbose' to grub-setup.
9658 Abort script if make_system_path_relative_to_its_root() fails.
9659
7810e747 96602008-07-24 Bean <bean123ch@gmail.com>
9661
9662 * configure.ac: Fixed a bug caused by the previous cygwin patch,
9663 variable `target_platform' should be `platform'.
9664
42290e17 96652008-07-24 Bean <bean123ch@gmail.com>
9666
51cc5193 9667 * video/reader/png.c (DEFLATE_HLIT_MAX): Change value.
42290e17 9668 (grub_png_init_fixed_block): New function.
9669 (grub_png_decode_image_data): Handle fixed huffman code compression.
9670
2a8a80e4 96712008-07-24 Bean <bean123ch@gmail.com>
9672
9673 * common.rmk (bin_UTILITIES): Add grub-pe2elf.
9674 (grub_pe2elf_SOURCES): New macro.
9675 (CLEANFILES): Add grub-pe2elf.
9676
9677 * include/grub/efi/pe32.h (GRUB_PE32_SCN_ALIGN_1BYTES): New constant.
9678 (GRUB_PE32_SCN_ALIGN_2BYTES): Likewise.
9679 (GRUB_PE32_SCN_ALIGN_4BYTES): Likewise.
9680 (GRUB_PE32_SCN_ALIGN_8BYTES): Likewise.
9681 (GRUB_PE32_SCN_ALIGN_16BYTES): Likewise.
9682 (GRUB_PE32_SCN_ALIGN_32BYTES): Likewise.
9683 (GRUB_PE32_SCN_ALIGN_64BYTES): Likewise.
9684 (GRUB_PE32_SCN_ALIGN_SHIFT): Likewise.
9685 (GRUB_PE32_SCN_ALIGN_MASK): Likewise.
9686 (GRUB_PE32_SYM_CLASS_EXTERNAL): Likewise.
9687 (GRUB_PE32_SYM_CLASS_STATIC): Likewise.
9688 (GRUB_PE32_SYM_CLASS_FILE): Likewise.
9689 (GRUB_PE32_DT_FUNCTION): Likewise.
9690 (GRUB_PE32_REL_I386_DIR32): Likewise.
9691 (GRUB_PE32_REL_I386_REL32): Likewise.
9692 (grub_pe32_symbol): New structure.
9693 (grub_pe32_reloc): Likewise.
9694
9695 * util/grub-pe2elf.c: New file.
9696
9697 * configure.ac: Set TARGET_OBJ2ELF if host os is cygwin. Don't test for
9698 start symbol in non pc platform.
9699
9700 * genmk.rb: Use TARGET_OBJ2ELF to convert native object format to elf.
9701
9702 The following patches are from Christian Franke.
9703
9704 * include/grub/dl.h: Remove .previous, gas supports this only
9705 for ELF format.
9706
9707 * include/grub/symbol.h [__CYGWIN__] (#define FUNCTION/VARIABLE):
9708 Remove .type, gas supports this only for ELF format.
9709
9710 * kern/dl.c (grub_dl_resolve_dependencies): Add check for trailing
9711 nullbytes in symbol table. This fixes an infinite loop if table is
9712 zero filled.
9713
9714 * Makefile.in: Add autoconf replacements TARGET_IMG_LDSCRIPT,
9715 TARGET_IMG_LDFLAGS and EXEEXT.
9716
9717 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Replace -Wl,-N by
9718 TARGET_IMG_LDFLAGS_AC.
9719 (grub_CHECK_STACK_ARG_PROBE): New function.
9720
9721 * conf/i386-pc.rmk: Replace -Wl,-N by TARGET_IMG_LDFLAGS.
9722
9723 * conf/i386-pc-cygwin-ld-img.sc: New linker script.
9724
9725 * configure.ac: Add check for linker script "conf/${target}-img-ld.c"
9726 to set TARGET_IMG_LD* accordingly.
9727 Add check for Cygwin to set TARGET_MOD_OBJCOPY accordingly.
9728 Add call to grub_CHECK_STACK_ARG_PROBE.
9729 Use TARGET_IMG_LDFLAGS to check start, bss_start, end symbols.
9730
9731 * genkernsyms.sh.in: Handle HAVE_ASM_USCORE case.
9732
9733 * genmk.rb: Add EXEEXT to CLEANFILES.
9734
12ccdb75 97352008-07-23 Robert Millan <rmh@aybabtu.com>
9736
9737 * Makefile.in (UNICODE_ARROWS, UNICODE_LINES): New variables (they
9738 define the codes for arrows and lines used for the menu).
9739 (ascii.pff): Generate fonts for $(UNICODE_ARROWS) and $(UNICODE_LINES)
9740 as well.
9741
9742 * util/update-grub_lib.in (font_path): Prefer ascii.pff over complete
9743 fonts, because the latter are too slow.
9744
18eeaf04 97452008-07-21 Bean <bean123ch@gmail.com>
9746
9747 * kern/i386/pc/startup.S (gate_a20_try_bios): Change test order for
9748 a20. Run keyboard test last, as it will cause macbook to halt.
9749
b095e2ad 97502008-07-18 Pavel Roskin <proski@gnu.org>
9751
9752 * kern/dl.c: Go back to using GRUB_CPU_SIZEOF_VOID_P. We cannot
9753 load foreign architecture modules correctly anyway. Keep
9754 support for loading host architecture modules, whether we
9755 compile them or not.
9756
737feb35 97572008-07-17 Pavel Roskin <proski@gnu.org>
9758
3f4ce737 9759 * configure.ac: Use -m32 or -m64 regardless of whether we had to
9760 change target_cpu. The compiler default can mismatch target_cpu
9761 in any case.
9762
4ad2d049 9763 * disk/efi/efidisk.c: Fix format warnings on x86_64.
9764 * kern/efi/efi.c: Likewise.
9765
f6130a12 9766 * aclocal.m4 (grub_PROG_TARGET_CC): New macro. Check if the
9767 target compiler is functional.
9768 * configure.ac: Call grub_PROG_TARGET_CC once all target flags
9769 are set up.
9770
58393a2d 9771 * configure.ac: Default to efi platform for x86_64-apple. Allow
9772 powerpc64 CPU, default to ieee1275 platform for it. Split CPU
9773 adjustments from the rest, only do them if target is not
9774 explicitly given. Merge other adjustments with the final sanity
9775 check. Remove an extraneous check for supported CPU. Be
9776 specific which CPU and which platform is not supported.
9777
737feb35 9778 * configure.ac: Default to pc platform for x86_64.
9779
546f966a 97802008-07-17 Robert Millan <rmh@aybabtu.com>
9781
9782 Partial LinuxBIOS -> Coreboot rename.
9783
9784 * conf/i386-linuxbios.rmk: Renamed to ...
9785 * conf/i386-coreboot.rmk: ... this.
9786 * Makefile.in (RMKFILES): s/i386-linuxbios.rmk/i386-coreboot.rmk/g.
9787 * configure.ac: Accept "coreboot" as input platform (but maintain
9788 compatibility with "linuxbios").
9789 * include/grub/i386/linuxbios: Renamed to ...
9790 * include/grub/i386/coreboot: ... this.
9791
20011694 97922008-07-17 Bean <bean123ch@gmail.com>
9793
9794 * conf/i386/efi.rmk (pkglib_MODULES): add pci.mod and lspci.mod.
c11f6d16 9795 (appleldr_mod_SOURCE): New variable.
20011694 9796 (appleldr_mod_CFLAGS): Likewise.
9797 (appleldr_mod_LDFLAGS): Likewise.
9798 (pci_mod_SOURCES): Likewise.
9799 (pci_mod_CFLAGS): Likewise.
9800 (pci_mod_LDFLAGS): Likewise.
9801 (lspci_mod_SOURCES): Likewise.
9802 (lspci_mod_CFLAGS): Likewise.
9803 (lspci_mod_LDFLAGS): Likewise.
9804
9805 * conf/x86_64-efi.rmk: New file.
9806
9807 * disk/efi/efidisk.c (grub_efidisk_read): Wrap efi calls with efi_call_N
9808 macro.
9809 (grub_efidisk_write): Likewise.
9810
9811 * include/efi/api.h (efi_call_0): New macro.
9812 (efi_call_1): Likewise.
9813 (efi_call_2): Likewise.
9814 (efi_call_3): Likewise.
9815 (efi_call_4): Likewise.
9816 (efi_call_5): Likewise.
9817 (efi_call_6): Likewise.
9818
9819 * include/grub/efi/chainloader.h (grub_chainloader_cmd): Rename to
9820 grub_rescue_cmd_chainloader.
9821
9822 * include/grub/efi/pe32.h (GRUB_PE32_MACHINE_X86_64): New macro.
9823 (grub_pe32_optional_header): Change some fields based on i386 or
9824 x86_64 platform.
9825 (GRUB_PE32_PE32_MAGIC): Likewise.
9826
9827 * include/grub/efi/uga_draw.h: New file.
9828
9829 * include/grub/elf.h (STN_ABS): New constant.
9830 (R_X86_64_NONE): Relocation constant for x86_64.
9831 (R_X86_64_64): Likewise.
9832 (R_X86_64_PC32): Likewise.
9833 (R_X86_64_GOT32): Likewise.
9834 (R_X86_64_PLT32): Likewise.
9835 (R_X86_64_COPY): Likewise.
9836 (R_X86_64_GLOB_DAT): Likewise.
9837 (R_X86_64_JUMP_SLOT): Likewise.
9838 (R_X86_64_RELATIVE): Likewise.
9839 (R_X86_64_GOTPCREL): Likewise.
9840 (R_X86_64_32): Likewise.
9841 (R_X86_64_32S): Likewise.
9842 (R_X86_64_16): Likewise.
9843 (R_X86_64_PC16): Likewise.
9844 (R_X86_64_8): Likewise.
9845 (R_X86_64_PC8): Likewise.
9846
9847 * include/grub/i386/efi/pci.h: New file.
9848
9849 * include/grub/i386/linux.h (GRUB_LINUX_EFI_SIGNATURE):
9850 Change it value based on platform.
9851 (GRUB_LINUX_EFI_SIGNATURE_0204): New constant.
9852 (GRUB_E820_RAM): Likewise.
9853 (GRUB_E820_RESERVED): Likewise.
9854 (GRUB_E820_ACPI): Likewise.
9855 (GRUB_E820_NVS): Likewise.
9856 (GRUB_E820_EXEC_CODE): Likewise.
9857 (GRUB_E820_MAX_ENTRY): Likewise.
9858 (grub_e820_mmap): New structure.
9859 (linux_kernel_header): Change the efi field according to different
9860 kernel version, also field from linux_kernel_header.
9861
9862 * include/grub/kernel.h (grub_module_info): Add padding for x86_64.
9863
9864 * include/grub/pci.h (GRUB_PCI_ADDR_SPACE_MASK): New constant.
9865 (GRUB_PCI_ADDR_SPACE_MEMORY): Likewise.
9866 (GRUB_PCI_ADDR_SPACE_IO): Likewise.
9867 (GRUB_PCI_ADDR_MEM_TYPE_MASK): Likewise.
9868 (GRUB_PCI_ADDR_MEM_TYPE_32): Likewise.
9869 (GRUB_PCI_ADDR_MEM_TYPE_1M): Likewise.
9870 (GRUB_PCI_ADDR_MEM_TYPE_64): Likewise.
9871 (GRUB_PCI_ADDR_MEM_PREFETCH): Likewise.
9872 (GRUB_PCI_ADDR_MEM_MASK): Likewise.
9873 (GRUB_PCI_ADDR_IO_MASK): Likewise.
9874
9875 * include/grub/x86_64/efi/kernel.h: New file.
9876
9877 * include/grub/x86_64/efi/loader.h: Likewise.
9878
9879 * include/grub/x86_64/efi/machine.h: Likewise.
9880
9881 * include/grub/x86_64/efi/pci.h: Likewise.
9882
9883 * include/grub/x86_64/efi/time.h: Likewise.
9884
9885 * include/grub/x86_64/linux.h: Likewise.
9886
9887 * include/grub/x86_64/setjmp.h: Likewise.
9888
9889 * include/grub/x86_64/time.h: Likewise.
9890
9891 * include/grub/x86_64/types.h: Likewise.
9892
9893 * kern/dl.c (GRUB_CPU_SIZEOF_VOID_P): Changed to
9894 GRUB_TARGET_SIZEOF_VOID_P.
9895
9896 * kern/efi/efi.c (grub_efi_locate_protocol): Wrap efi calls.
9897 (grub_efi_locate_handle): Likewise.
9898 (grub_efi_open_protocol): Likewise.
9899 (grub_efi_set_text_mode): Likewise.
9900 (grub_efi_stall): Likewise.
9901 (grub_exit): Likewise.
9902 (grub_reboot): Likewise.
9903 (grub_halt): Likewise.
9904 (grub_efi_exit_boot_services): Likewise.
9905 (grub_get_rtc): Likewise.
9906
9907 * kern/efi/mm.c (MEMORY_MAP_SIZE): Change to 0x3000 for new models.
9908 (GRUB_CPU_SIZEOF_VOID_P): Changed to GRUB_TARGET_SIZEOF_VOID_P.
9909 (grub_efi_allocate_pages): Wrap efi calls.
9910 (grub_efi_free_pages): Wrap efi calls.
9911 (grub_efi_get_memory_map): Wrap efi calls.
9912
9913 * kern/x86_64/dl.c: New file.
9914
9915 * kern/x86_64/efi/callwrap.S: Likewise.
9916
9917 * kern/x86_64/efi/startup.S: Likewise.
9918
9919 * loader/efi/appleloader.c: Likewise.
9920
9921 * loader/efi/chainloader.c (cmdline): New variable.
9922 (grub_chainloader_unload): Wrap efi calls.
9923 (grub_chainloader_boot): Likewise.
9924 (grub_rescue_cmd_chainloader): Wrap efi calls, handle
9925 command line.
9926
9927 * loader/efi/chainloader_normal.c (chainloader_command):
9928 Change grub_chainloader_cmd to grub_rescue_cmd_chainloader, pass
9929 command line.
9930
9931 * loader/i386/efi/linux.c (allocate_pages): Change allocation
9932 method.
9933 (grub_e820_add_region): New function.
9934 (grub_linux_boot): Construct e820 map from efi map, handle x86_64
9935 booting.
9936 (grub_find_video_card): New function.
9937 (grub_linux_setup_video): New function.
9938 (grub_rescue_cmd_linux): Probe for video information.
9939
9940 * normal/x86_64/setjmp.S: New file.
9941
9942 * term/efi/console.c (map_char): New function.
9943 (grub_console_putchar): Map unicode char.
9944 (grub_console_checkkey): Wrap efi calls.
9945 (grub_console_getkey): Likewise.
9946 (grub_console_getwh): Likewise.
9947 (grub_console_gotoxy): Likewise.
9948 (grub_console_cls): Likewise.
9949 (grub_console_setcolorstate): Likewise.
9950 (grub_console_setcursor): Likewise.
9951
9952 * util/i386/efi/grub-mkimage.c: Add support for x86_64.
9953
59652a20 99542008-07-16 Pavel Roskin <proski@gnu.org>
9955
ef294055 9956 * loader/i386/efi/linux.c (allocate_pages): Fix warnings in
9957 format strings.
9958
59652a20 9959 * util/i386/efi/grub-mkimage.c (get_target_address): Return a
9960 pointer, not an integer. This fixes a warning and prevents
9961 precision loss on 64-bit systems.
9962 (relocate_addresses): Remove unneeded cast.
9963
afc3b5d7 99642008-07-15 Pavel Roskin <proski@gnu.org>
9965
506b2b3e 9966 * kern/i386/ieee1275/init.c: Include grub/cache.h.
9967
62ead89c 9968 * term/ieee1275/ofconsole.c: Disable code unused on i386.
9969
c4cd51d7 9970 * kern/ieee1275/ieee1275.c (grub_ieee1275_get_integer_property):
9971 Fix comparison between signed and unsigned.
9972
0d3d8f28 9973 * include/grub/i386/ieee1275/console.h: Declare
9974 grub_console_init() and grub_console_fini().
9975
8804b286 9976 * loader/i386/ieee1275/linux.c (grub_set_bootpath): Remove.
9977 It's empty and unused.
9978
ee01cf35 9979 * fs/ext2.c (grub_ext2_read_block): Initialize blknr in the
9980 beginning to avoid warnings with some compilers.
9981
afc3b5d7 9982 * loader/ieee1275/multiboot2.c: Include grub/machine/loader.h.
9983 [__i386__] (grub_mb2_arch_boot): Avoid unnecessary cast.
9984
e4e8eaa5 99852008-07-14 Pavel Roskin <proski@gnu.org>
9986
407aceb4 9987 * kern/env.c (grub_register_variable_hook): Don't copy empty
9988 string, it leaks memory. Pass "" to grub_env_set(), it should
9989 handle constant strings.
9990
e4e8eaa5 9991 * commands/blocklist.c (grub_cmd_blocklist): Fix format warning.
9992 * commands/cmp.c (grub_cmd_cmp): Likewise.
9993 * kern/dl.c (grub_dl_flush_cache): Likewise.
9994 (grub_dl_load_core): Likewise.
9995 * kern/elf.c (grub_elf32_load_phdrs): Likewise.
9996 (grub_elf64_load_phdrs): Likewise.
9997
d4e2dad3 99982008-07-13 Pavel Roskin <proski@gnu.org>
9999
10000 * lib/LzmaEnc.c (LzmaEnc_SetProps): Fix warning about comparison
10001 between signed and unsigned.
10002 (LzmaEnc_Finish): Fix warning about an unused parameter.
10003
aa24b516 100042008-07-13 Bean <bean123ch@gmail.com>
10005
10006 * Makefile.in (enable_lzo): New rule.
10007
10008 * conf/i386-pc.rmk (grub_mkimage_SOURCES): New test with enable_lzo.
10009
10010 * configure.ac (ENABLE_LZO): New option --enable-lzo.
10011
10012 * boot/i386/pc/lnxboot.S: #include <config.h>.
10013
10014 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE): Change
fe987087 10015 its value according to the compression algorithm used, lzo or lzma.
aa24b516 10016
10017 * util/i386/pc/grub-mkimage.c (compress_kernel): Use different
10018 compression algorithm according to configure macro.
10019
10020 * kern/i386/pc/startup.S (codestart): Likewise.
10021
10022 * kern/i386/pc/lzma_decode.S: New file.
10023
10024 * include/grub/lib/LzFind.h: Likewise.
10025
10026 * include/grub/lib/LzHash.h: Likewise.
10027
10028 * include/grub/lib/LzmaDec.h: Likewise.
10029
10030 * include/grub/lib/LzmaEnc.h: Likewise.
10031
10032 * include/grub/lib/LzmaTypes.h: Likewise.
10033
10034 * lib/LzFind.c: Likewise.
10035
10036 * lib/LzmaDec.c: Likewise.
10037
10038 * lib/LzmaEnc.c: Likewise.
10039
4ae821ac 100402008-07-13 Bean <bean123ch@gmail.com>
10041
10042 * fs/ext2.c (EXT4_EXTENTS_FLAG): New macro.
10043 (grub_ext4_extent_header): New structure.
10044 (grub_ext4_extent): Likewise.
10045 (grub_ext4_extent_idx): Likewise.
10046 (grub_ext4_find_leaf): New function.
10047 (grub_ext2_read_block): Handle extents.
10048
9a745147 100492008-07-12 Robert Millan <rmh@aybabtu.com>
10050
10051 * util/i386/pc/grub-mkrescue.in: s/grub-install/grub-mkrescue/g.
10052
d49a4cf6 100532008-07-11 Robert Millan <rmh@aybabtu.com>
10054
10055 * util/grub.d/40_custom.in: New file. Example on how to add custom
10056 entries to /etc/grub.d.
10057 * conf/common.rmk (%, update-grub_SCRIPTS, CLEANFILES): Install
10058 40_custom (implicitly, by merging all the grub.d rules).
10059
947414b4 100602008-07-11 Pavel Roskin <proski@gnu.org>
10061
0059cf6f 10062 * commands/read.c (grub_getline): Fix invalid memory access.
10063 Don't add newline to the variable value.
10064
947414b4 10065 * term/i386/pc/serial.c (GRUB_SERIAL_PORT_NUM): New constant.
10066 [!GRUB_MACHINE_PCBIOS] (serial_hw_io_addr): Add COM2 and COM3.
10067 (serial_hw_get_port): Check validity of the port number.
10068 (grub_cmd_serial): Check return value of serial_hw_get_port().
10069
62a02d00 100702008-07-07 Pavel Roskin <proski@gnu.org>
10071
10072 * boot/i386/pc/diskboot.S (notification_string): Replace
10073 "Loading kernel" with just "loading". This is shorter, less
10074 confusing and saves a few bytes for possible future changes.
10075
3e5581b0 100762008-07-05 Pavel Roskin <proski@gnu.org>
10077
ea387a48 10078 * disk/ata.c (grub_ata_dumpinfo): Don't output addressing and
10079 size for ATAPI devices, they are undefined. Output sector
10080 number in decimal form.
10081
3e5581b0 10082 * disk/ata.c: Use named constants for status bits.
10083
fdecb8fd 100842008-07-04 Pavel Roskin <proski@gnu.org>
10085
bcd35b90 10086 * kern/i386/linuxbios/init.c (grub_machine_init): Cast addr to
10087 grub_addr_t before casting it to the void pointer to fix a
10088 warning. Non-addressable regions are discarded earlier.
10089 (grub_arch_modules_addr): Cast _end to grub_addr_t.
10090 * kern/i386/linuxbios/table.c: Include grub/misc.h.
10091 (check_signature): Don't shadow table_header.
10092 (grub_linuxbios_table_iterate): Cast numeric constants to
10093 grub_linuxbios_table_header_t.
10094 * include/grub/i386/linuxbios/init.h: Add noreturn attribute to
10095 grub_stop().
10096
af58ab3d 10097 * kern/ieee1275/init.c: Cast _start and _end to grub_addr_t to
10098 prevent warnings.
10099
1759aa57 10100 * include/grub/misc.h (ALIGN_UP): Avoid unnecessary cast to a
10101 pointer, which can cause warnings. Support 64-bit addresses.
10102
fdecb8fd 10103 * util/elf/grub-mkimage.c: Use GRUB_TARGET_SIZEOF_LONG instead
10104 of sizeof(long). This fixes PowerPC image generation on x86_64.
10105
8516d2a8 101062008-07-04 Robert Millan <rmh@aybabtu.com>
10107
10108 This fixes a performance issue when pc & gpt partmap iterators
10109 didn't abort iteration even after our hook found what it was
fe987087 10110 looking for (often causing expensive probes of non-existent drives).
8516d2a8 10111
10112 Some callers relied on previous buggy behaviour, since they would
34c44600 10113 raise an error when their own hooks caused early abortion of its
8516d2a8 10114 iteration.
10115
10116 * kern/device.c (grub_device_open): Improve error message.
10117 * disk/lvm.c (grub_lvm_open): Likewise.
10118 * disk/raid.c (grub_raid_open): Likewise.
10119
10120 * partmap/pc.c (pc_partition_map_iterate): Abort parent iteration
10121 when hook requests it, independently of grub_errno.
10122 (pc_partition_map_probe): Do not fail when find_func() caused
10123 early abortion of pc_partition_map_iterate().
10124
10125 * partmap/gpt.c (gpt_partition_map_iterate): Abort parent iteration
10126 when hook requests it, independently of grub_errno.
10127 (gpt_partition_map_probe): Do not fail when find_func() caused
10128 early abortion of gpt_partition_map_iterate().
10129
10130 * kern/partition.c (grub_partition_iterate): Abort parent iteration
10131 when hook requests it, independently of grub_errno. Do not fail when
10132 part_map_iterate_hook() caused early abortion of p->iterate().
10133
10134 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Do not fail
10135 when grub_partition_iterate() returned with non-zero.
10136
277d0de9 101372008-07-03 Pavel Roskin <proski@gnu.org>
10138
10139 * disk/ata.c (grub_ata_pio_write): Check status before writing,
10140 like we do in grub_ata_pio_read().
10141 (grub_ata_readwrite): Always write individual sectors. Fix the
10142 sector count for the remainder.
10143 (grub_ata_write): Enable writing to ATA devices. Correctly
10144 report error for ATAPI devices.
10145
d4c9b428 101462008-07-02 Pavel Roskin <proski@gnu.org>
10147
e43fc690 10148 * boot/i386/pc/cdboot.S: Add _start entry to fix a linker
10149 warning.
10150
f707af42 10151 * disk/ata.c (grub_ata_readwrite): Don't increment sector number
10152 for every read sector, we already increment it for the whole
10153 batch. This fixes reading more than 256 sectors at once.
10154
11e16b15 10155 * util/grub-editenv.c (cmd_info): Cast argument to long
10156 explicitly. ptrdiff_t reduces to int on i386.
10157
cbabfdd4 10158 * util/grub-editenv.c (main): Be specific which parameter is
10159 missing.
10160
b8fbce0a 10161 * disk/memdisk.c (memdisk_addr): Make a pointer to fix warnings.
10162 (memdisk): Make memdisk_orig_addr a pointer.
10163
c9c8e606 10164 * fs/reiserfs.c (grub_reiserfs_read): Fix misuse of grub_size_t
10165 for file offsets, use grub_off_t instead. Fix printf format
10166 warnings.
10167
ca62e598 10168 * fs/reiserfs.c: Remove #warning, TODO list items don't belong
10169 there. Real unexpected warnings should not drown in the noise
10170 about known problems.
10171
ce8d1766 10172 * commands/hexdump.c (grub_cmd_hexdump): Fix misuse of
10173 grub_disk_addr_t for memory addresses.
10174
00c7a56a 10175 * loader/aout.c (grub_aout_load): Cast load_addr to pointer
10176 explicitly to fix a warning.
10177
08d3ef09 10178 * util/grub-editenv.c (cmd_info): Fix warning in printf format.
10179
cb71ba20 10180 * Makefile.in (MODULE_LDFLAGS): New variable.
10181 * aclocal.m4 (grub_PROG_LD_BUILD_ID_NONE): New macro. Check if
10182 the linker accepts --build-id=none.
10183 * configure.ac: Call grub_PROG_LD_BUILD_ID_NONE. Substitute
10184 MODULE_LDFLAGS.
10185 * genmk.rb: Use MODULE_LDFLAGS when linking modules.
10186
d4c9b428 10187 * fs/xfs.c (struct grub_xfs_dir_header): Use names similar to
10188 those in Linux XFS code. Provide a way to access 64-bit parent
10189 inode.
10190 (grub_xfs_iterate_dir): Use the new names. Avoid reading past
10191 the end of struct grub_xfs_dir_header.
10192
d4156eee 101932008-07-02 Bean <bean123ch@gmail.com>
10194
10195 * include/grub/ieee1275.h (grub_ieee1275_flag): New constant
10196 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
10197 and GRUB_IEEE1275_FLAG_NO_ANSI.
10198
10199 * kern/ieee1275/cmain.c (grub_ieee1275_find_options): Set flag
10200 GRUB_IEEE1275_FLAG_CANNOT_INTERPRET, GRUB_IEEE1275_FLAG_FORCE_CLAIM
10201 and GRUB_IEEE1275_FLAG_NO_ANSI for Open Hackware.
10202
10203 * kern/ieee1275/ieee1275.c (grub_ieee1275_interpret): Return
10204 immediately if GRUB_IEEE1275_FLAG_CANNOT_INTERPRET is set.
10205
10206 * kern/ieee1275/init.c (grub_claim_heap): Claim memory directly if
10207 GRUB_IEEE1275_FLAG_FORCE_CLAIM is set.
10208
10209 * term/ieee1275/ofconsole.c (grub_ofconsole_writeesc): Don't output
10210 esc sequence on non ANSI terminal.
10211 (grub_ofconsole_gotoxy): Emulate backspace key on non ANSI terminal.
10212
10213 * util/elf/grub-mkimage.c (add_segments): Move ELF header to the
10214 beginning of file.
10215
2270f77b 102162008-07-02 Bean <bean123ch@gmail.com>
10217
10218 * conf/common.rmk (bin_UTILITIES): Add grub-editenv.
10219 (grub_editenv_SOURCES): New variable.
10220 (pkglib_MODULES): Add loadenv.mod.
10221 (loadenv_mod_SOURCES): New variable.
10222 (loadenv_mod_CFLAGS): Likewise.
10223 (loadenv_mod_LDFLAGS): Likewise.
10224
10225 * include/grub/envblk.h: New file.
10226
10227 * util/envblk.c: New file.
10228
10229 * util/grub-editenv.c: New file.
10230
10231 * commands/loadenv.c: New file.
10232
0e9e51ec 102332008-07-01 Pavel Roskin <proski@gnu.org>
10234
d89b7634 10235 * include/multiboot2.h (struct multiboot_tag_module): Use char,
10236 not unsigned char. This fixes warnings and is consistent with
10237 other tags.
10238
bf1835b1 10239 * disk/fs_uuid.c (search_fs_uuid): Correctly increment count.
10240
8222a04b 10241 * normal/parser.y: Define YYENABLE_NLS as 0 to fix warnings.
10242
6a42d99d 10243 * term/tparm.c (analyze): Always set *popcount.
10244
10b159d1 10245 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Remove useless
10246 cast to fix a warning.
10247
b8789f6c 10248 * loader/i386/pc/multiboot2.c (grub_mb2_arch_module_alloc): Use
10249 cast to suppress a warning.
10250
29d7e38a 10251 * fs/afs.c (grub_afs_read_block): Return grub_disk_addr_t, as
10252 grub_fshelp_read_file() expects.
10253
f341f669 10254 * fs/fat.c: Fix UUID calculation on big-endian systems. We
10255 write uuid as a 32-bit value in CPU byte order, so declare and
10256 use it as such.
10257
0e9e51ec 10258 * disk/raid.c: Cast grub_dprintf() arguments to unsigned long
10259 long if the format specifier expects it.
10260 * partmap/gpt.c (gpt_partition_map_iterate): Likewise.
10261 * partmap/pc.c (pc_partition_map_iterate): Likewise.
10262 * fs/ntfs.c (grub_ntfs_uuid): Cast data->uuid to unsigned long
10263 long to fix a warning.
10264 * fs/reiserfs.c (grub_reiserfs_read): Change casts in
10265 grub_dprintf() arguments to fix warnings.
10266
3aefa857 102672008-06-30 Pavel Roskin <proski@gnu.org>
10268
56c7668b 10269 * util/i386/pc/grub-setup.c (setup): Write install_dos_part and
10270 install_bsd_part immediately before core.img is embedded or
10271 modified on disk. This fixes core.img verification if core.img
10272 cannot be embedded.
10273
3aefa857 10274 * util/i386/pc/grub-setup.c (setup): Use core_path_dev, not
10275 core_path to calculate the blocklist.
10276 Patch from Javier Martín <lordhabbit@gmail.com>
10277
5444088d 102782008-06-29 Robert Millan <rmh@aybabtu.com>
10279
10280 * fs/xfs.c (GRUB_XFS_FSB_TO_BLOCK): New macro. Maps filesystem
10281 block to disk block.
10282 (grub_xfs_read_block): Use GRUB_XFS_FSB_TO_BLOCK() on result.
10283 Patch from Niels Böhm <bitbucket@arcor.de>
10284
674835c8 102852008-06-29 Robert Millan <rmh@aybabtu.com>
10286
10287 * util/update-grub_lib.in (font_path): Search for fonts in
10288 /boot/grub first, which is more likely to be readable (we aren't
10289 deciding where fonts live, just looking for them).
10290
f527dbc8 102912008-06-26 Pavel Roskin <proski@gnu.org>
10292
6c2d8df6 10293 * util/biosdisk.c (read_device_map): Don't leave dead map
10294 entries for devices failing stat() check.
10295
f527dbc8 10296 * util/i386/pc/grub-setup.c (setup): Don't reuse core_path, use
10297 core_path_dev for the core.img path on the target device.
10298
aebe3d13 102992008-06-26 Robert Millan <rmh@aybabtu.com>
10300
10301 * disk/fs_uuid.c: New file.
10302 * conf/common.rmk (pkglib_MODULES): Add `fs_uuid.mod'.
10303 (fs_uuid_mod_SOURCES, fs_uuid_mod_CFLAGS)
10304 (fs_uuid_mod_LDFLAGS): New variables.
10305 * include/grub/disk.h (grub_disk_dev_id): Add
10306 `GRUB_DISK_DEVICE_UUID_ID'.
10307 * kern/disk.c (grub_disk_dev_iterate): Allow disk devices not to
10308 implement iterate().
10309
37aaf354 103102008-06-26 Robert Millan <rmh@aybabtu.com>
10311
10312 * util/grub.d/10_linux.in: Avoid passing UUIDs to Linux when either
10313 "/dev/disk/by-uuid/${GRUB_DEVICE_UUID}" does not exist, or when a
10314 Linux image includes no initrd.
10315
25ff262a 103162008-06-21 Javier Martín <lordhabbit@gmail.com>
10317
10318 * util/i386/pc/grub-setup.c (setup): Remove literal "core.img" in a
10319 call to resolve the core image location that effectively appended the
10320 name twice.
10321
76a2bd44 103222008-06-21 Robert Millan <rmh@aybabtu.com>
10323
10324 * util/grub.d/00_header.in: Move last prepare_grub_to_access_device()
10325 call from here ...
10326
10327 * util/grub.d/10_hurd.in: ... to here ...
10328 * util/grub.d/10_linux.in: ... and here.
10329
650e1c79 103302008-06-19 Robert Millan <rmh@aybabtu.com>
10331
fe987087 10332 * kern/main.c (grub_main): Export `prefix' variable immediately
650e1c79 10333 after it has been set by grub_machine_set_prefix().
10334
6ce63911 103352008-06-19 Robert Millan <rmh@aybabtu.com>
10336
10337 * commands/search.c (search_label, search_fs_uuid, search_file): Print
10338 search result when not saving to variable, not the other way around.
10339 When saving to variable, abort iteration as soon as a match is found.
10340
73940cec 103412008-06-19 Robert Millan <rmh@aybabtu.com>
10342
10343 * util/update-grub_lib.in (prepare_grub_to_access_device): Remove
10344 check for partition that provides /boot/grub. Its logic is flawed,
10345 as it prevents prepare_grub_to_access_device() from being called
10346 multiple times.
10347
3c62a39d 103482008-06-19 Robert Millan <rmh@aybabtu.com>
10349
10350 * util/update-grub_lib.in (prepare_grub_to_access_device): Issue
10351 "insmod" command directly when abstraction modules are needed,
fe987087 10352 instead of relying on GRUB_PRELOAD_MODULES (which had no effect
3c62a39d 10353 since it had already been processed).
10354
47395a42 103552008-06-19 Pavel Roskin <proski@gnu.org>
10356
10357 * conf/i386-efi.rmk: Recompile grub-mkimage.c if Makefile has
10358 changed. This is needed in case GRUB_LIBDIR changes.
10359 * conf/i386-ieee1275.rmk: Likewise.
10360 * conf/i386-linuxbios.rmk: Likewise.
10361 * conf/i386-pc.rmk: Likewise.
10362 * conf/powerpc-ieee1275.rmk: Likewise.
10363
a145ac2d 103642008-06-18 Pavel Roskin <proski@gnu.org>
10365
10366 * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Rename
10367 kernel_elf_symlist.c to symlist.c for consistency with other
10368 architectures. Update all users.
10369 * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise.
10370
7847c51e 103712008-06-18 Robert Millan <rmh@aybabtu.com>
10372
10373 * util/i386/pc/grub-install.in: If the drive is LVM or RAID, prepend
10374 it in prefix.
10375
10376 * util/i386/pc/grub-setup.c (main): Don't handle prefix at all. Set
10377 `must_embed' to 1 when root_dev is a RAID device. When dest_dev is
10378 a RAID device, run setup() for all members independently on whether
10379 LVM abstraction is being used.
10380 (setup): Don't handle prefix at all; let grub-mkimage take care of it.
10381 If grub-mkimage has set `*install_dos_part == -2', don't override this
10382 value.
10383 Perform *install_dos_part adjustments independently on whether
10384 we're embedding or not.
10385 Clarify error message when image is too big for embedding.
10386 Remove duplicate *install_dos_part stanza.
10387
b23e5644 103882008-06-17 Robert Millan <rmh@aybabtu.com>
10389
10390 * term/ieee1275/ofconsole.c (fgcolor, bgcolor): Remove variables.
10391 (grub_ofconsole_normal_color, grub_ofconsole_highlight_color): New
10392 variables.
10393 (grub_ofconsole_setcolor, grub_ofconsole_getcolor): Load/store
10394 values in grub_ofconsole_normal_color and
10395 grub_ofconsole_highlight_color (they're not directly related to
10396 background and foreground).
10397 (grub_ofconsole_setcolorstate): Extract background and foreground
10398 from grub_ofconsole_normal_color and grub_ofconsole_highlight_color.
10399
0aac2f79 104002008-06-17 Robert Millan <rmh@aybabtu.com>
10401
10402 * util/update-grub_lib.in (prepare_grub_to_access_device): Use
10403 /boot/grub for the check in last commit, not /boot (they could be
10404 different partitions).
10405
3cca7ef3 104062008-06-16 Robert Millan <rmh@aybabtu.com>
10407
10408 * util/update-grub_lib.in (prepare_grub_to_access_device): If we were
10409 asked to setup access for the same partition that provides /boot,
10410 don't bother using UUIDs since our root already has the value we
10411 want.
10412
347396d8 104132008-06-16 Robert Millan <rmh@aybabtu.com>
10414
10415 * util/biosdisk.c (convert_system_partition_to_system_disk): Detect
10416 I2O devices.
10417 Patch from Sven Mueller <sven@debian.org>.
10418
991477f8 104192008-06-16 Robert Millan <rmh@aybabtu.com>
10420
10421 * util/update-grub.in: Check for $EUID instead of $UID.
10422 Reported by Vincent Zweije.
10423
d31a32a1 104242008-06-16 Bean <bean123ch@gmail.com>
10425
fe987087 10426 * fs/ext2.c (grub_ext2_blockgroup): Revert to pre-journal state.
d31a32a1 10427 (grub_ext2_read_block): Likewise.
10428 (grub_ext2_read_inode): Likewise.
10429 (grub_ext2_mount): Likewise.
10430 (grub_ext2_close): Likewise.
10431 (grub_ext3_get_journal): Removed.
10432
fe987087 10433 * fs/reiserfs.c (grub_reiserfs_get_item): Revert to pre-journal state.
d31a32a1 10434 (grub_reiserfs_read_symlink): Likewise.
10435 (grub_reiserfs_mount): Likewise.
10436 (grub_reiserfs_open): Likewise.
10437 (grub_reiserfs_read): Likewise.
10438 (grub_reiserfs_close): Likewise.
10439 (grub_reiserfs_get_journal): Removed.
10440
10441 * fs/fshelp.c (grub_fshelp_read): Removed.
10442 (grub_fshelp_map_block): Likewise.
10443
10444 * include/grub/fshelp.h (grub_fshelp_journal_type): Removed.
10445 (grub_fshelp_journal): Likewise.
10446 (grub_fshelp_read): Likewise.
10447 (grub_fshelp_map_block): Likewise.
10448
3540a760 104492008-06-16 Pavel Roskin <proski@gnu.org>
10450
10451 * conf/powerpc-ieee1275.rmk: Remove -msoft-float, we don't use
10452 floating point anymore.
10453 * include/grub/powerpc/libgcc.h: Leave only necessary exports.
10454
95614c84 104552008-06-15 Pavel Roskin <proski@gnu.org>
10456
10457 * commands/ls.c (grub_ls_list_files): Use integer calculations
10458 for human readable format, avoid floating point use.
10459 * kern/misc.c (grub_ftoa): Remove.
10460 (grub_vsprintf): Remove floating point support.
10461
50465dd6 104622008-06-15 Robert Millan <rmh@aybabtu.com>
10463
fe6b695a 10464 * util/grub.d/10_linux.in: Use the underlying device for loop-AES
50465dd6 10465 devices.
10466 Reported by Max Vozeler.
10467
a9207284 104682008-06-15 Robert Millan <rmh@aybabtu.com>
10469
10470 * util/i386/pc/grub-mkimage.c (generate_image): If we included a drive
10471 in our prefix, set install_{dos,bsd}_part = -2 to indicate this can be
10472 skipped later.
10473 (main): If a memdisk was requested, add "(memdisk)" drive explicitly to
10474 the beginning of the prefix.
10475
10476 * kern/i386/pc/init.c (make_install_device): Remove memdisk check.
10477 It is assumed that if we have a memdisk, grub-mkimage has set
10478 grub_prefix to include the "(memdisk)" drive in it.
10479
a7cbd45a 104802008-06-15 Robert Millan <rmh@aybabtu.com>
10481
10482 * term/i386/pc/console.c [GRUB_MACHINE_LINUXBIOS] (grub_console_init):
10483 Initialize keyboard controller after registering the terminal, so that
10484 grub_printf() can be called from grub_keyboard_controller_init().
10485
21cf716a 104862008-06-15 Robert Millan <rmh@aybabtu.com>
10487
10488 * fs/sfs.c (grub_sfs_read_extent): Fix the count of nodes in
10489 extent-btree which is written as big endian on disk.
10490 Reported by Alain Greppin <al@chilibi.org>.
10491
23a64d8e 104922008-06-14 Robert Millan <rmh@aybabtu.com>
10493
10494 * util/i386/efi/grub-install.in (modules): Remove `_chain'.
10495 * util/i386/pc/grub-install.in (modules): Likewise.
10496
d687651c 104972008-06-13 Pavel Roskin <proski@gnu.org>
10498
10499 * commands/ls.c (grub_ls_list_files): Fix format warnings.
10500
dfe9ddd4 105012008-06-13 Bean <bean123ch@gmail.com>
10502
10503 * commands/hexdump.c (grub_cmd_hexdump): Adjust offset for partition.
10504
10505 * fs/ext2.c (grub_ext3_get_journal): Fix revoke block handling.
10506
10507 * fs/fshelp.c (grub_fshelp_map_block): Don't map block 0 as it's used
10508 to indicate sparse block.
10509
16ae7781 105102008-06-12 Pavel Roskin <proski@gnu.org>
10511
e6d1a308 10512 * fs/ext2.c (grub_ext2_read_inode): Don't normalize block
10513 number, grub_fshelp_read() does it for us.
10514
16ae7781 10515 * fs/fshelp.c (grub_fshelp_read): New function. Implement
10516 linear disk read with journal translation.
10517 * fs/ext2.c: Use grub_fshelp_read() instead of grub_disk_read().
10518 * include/grub/fshelp.h: Declare grub_fshelp_read().
10519
40fd3a2b 105202008-06-09 Pavel Roskin <proski@gnu.org>
10521
10522 * fs/minix.c (grub_minix_mount): Handle error reading
10523 superblock.
10524
f5679726 105252008-06-08 Robert Millan <rmh@aybabtu.com>
10526
10527 * util/i386/pc/grub-setup.c (main): If install drive is an LVM,
10528 don't append the RAID prefix afterwards.
10529 Reported by Clint Adams.
10530
ce525529 105312008-06-08 Robert Millan <rmh@aybabtu.com>
10532
10533 Based on description from Pavel:
10534 * kern/disk.c (grub_disk_check_range): Rename to ...
10535 (grub_disk_adjust_range): ... this. Add a comment explaining the
10536 tasks performed by this function.
10537
ad4936a0 105382008-06-08 Robert Millan <rmh@aybabtu.com>
10539
10540 * include/grub/ntfs.h (struct grub_ntfs_bpb): Rename `serial_number' to
10541 `num_serial' (for consistency with other variables).
10542 (struct grub_ntfs_data): Add `uuid' member.
10543 * fs/ntfs.c (grub_ntfs_mount): Initialize `data->uuid'.
10544 (grub_ntfs_uuid): New function.
10545 (grub_ntfs_fs): Reference grub_ntfs_uuid() in `uuid' struct member.
10546
dc20b0f9 105472008-06-07 Pavel Roskin <proski@gnu.org>
10548
10549 * util/biosdisk.c (open_device): Revert last change to the
10550 function, it broke installation. The sector needs to be
10551 different dependent on which device is opened.
10552
c5e3cfba 105532008-06-06 Robert Millan <rmh@aybabtu.com>
10554
10555 Ensure GRUB_KERNEL_MACHINE_DATA_END is always consistent with the
10556 rest of GRUB, and breakage doesn't happen if its value were modified.
10557
10558 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
10559 Redefine as an offset from `GRUB_KERNEL_MACHINE_DATA_END' instead of
10560 a constant (same value).
10561 * kern/i386/pc/startup.S: Replace hardcoded `0x50' with
10562 `GRUB_KERNEL_MACHINE_DATA_END' (same value).
10563
26a1f8c4 105642008-06-06 Robert Millan <rmh@aybabtu.com>
10565
10566 * util/biosdisk.c (open_device): Do not modify sector offset when
10567 accessing a partition. kern/disk.c already handles this for us.
10568
25d6b327 105692008-06-06 Robert Millan <rmh@aybabtu.com>
10570
10571 * util/grub-emu.c (grub_machine_init): Move code in this function from
10572 here ...
10573 (main): ... to here (before grub_util_biosdisk_init() call, to prevent
10574 segfault in case grub_printf() is called).
10575
10576 * util/i386/pc/grub-install.in: Append `--device-map=${device_map}' to
10577 grub_probe. Update all users not to explicitly add it again.
10578 (grub_device): New variable; contains corresponding device for grubdir.
10579 (fs_module, partmap_module, devabstraction_module): Pass
10580 `--device ${grub_device}' to grub_probe to avoid traversing /dev
10581 every time.
10582
9ece62fb 105832008-06-05 Robert Millan <rmh@aybabtu.com>
10584
10585 * normal/misc.c (grub_normal_print_device_info): When a filesystem UUID
10586 is found, print it (same layout as with labels).
10587
1ad36d37 105882008-06-04 Robert Millan <rmh@aybabtu.com>
10589
10590 * util/biosdisk.c (get_drive): Rename to ...
10591 (find_grub_drive): ... this. Update all users.
10592
10593 (get_os_disk): Rename to ...
10594 (convert_system_partition_to_system_disk): ... this. Update all users.
10595
10596 (find_drive): Rename to ...
10597 (find_system_device): ... this. Update all users.
10598
e6a30859 105992008-06-04 Robert Millan <rmh@aybabtu.com>
10600
10601 * util/biosdisk.c (get_os_disk): Handle IDA devices.
10602 * util/grub-mkdevicemap.c (get_mmc_disk_name)
10603 (make_device_map): Likewise.
10604
00c108a4 106052008-06-01 Robert Millan <rmh@aybabtu.com>
10606
10607 * util/biosdisk.c (get_drive): Verify that `map[i].drive' is non-NULL
10608 before dereferencing it.
10609
10610 * fs/fat.c (struct grub_fat_bpb): Move fat32-specific fields into a
10611 union with fat12/fat16-specific ones. Add some new fields, including
10612 `num_serial' for both versions.
10613 (struct grub_fat_data): Add `uuid' member.
10614 (grub_fat_mount): Refer to fat32-specific fields in `bpb' by their new
10615 names. Initialize `data->uuid' using `num_serial'.
10616 (grub_fat_uuid): New function.
10617 (grub_fat_fs): Reference grub_fat_uuid() in `uuid' struct member.
10618
10619 * fs/reiserfs.c (grub_reiserfs_superblock): Add `uuid' field.
10620 (grub_reiserfs_uuid): New function.
10621 (grub_reiserfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct
10622 member.
10623
10624 * fs/xfs.c (grub_xfs_sblock): Add `uuid' field.
10625 (grub_xfs_uuid): New function.
10626 (grub_xfs_fs): Reference grub_reiserfs_uuid() in `uuid' struct member.
10627
1385c5bb 106282008-06-01 Robert Millan <rmh@aybabtu.com>
10629
10630 * util/update-grub_lib.in (prepare_grub_to_access_device): Generate
10631 code that is backward compatible with pre-uuid search command.
10632
c682dfd7 106332008-05-31 Robert Millan <rmh@aybabtu.com>
10634
10635 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Iterate through
10636 floppies after everything else, to ensure floppy drive isn't accessed
10637 unnecessarily (patch from Bean).
10638
b7db5d47 106392008-05-31 Robert Millan <rmh@aybabtu.com>
10640
10641 * commands/search.c (search_label, search_fs_uuid, search_file): Do
10642 not print device names when we were asked to set a variable.
10643
6e037aa9 106442008-05-31 Robert Millan <rmh@aybabtu.com>
10645
10646 * term/ieee1275/ofconsole.c (grub_ofconsole_setcursor): Implement
10647 using "cursor-on" and "cursor-off" commands (understood at least by
10648 the Open Firmware flavour on OLPC).
10649
41305bc8 106502008-05-31 Michael Gorven <michael@gorven.za.net>
10651
10652 * term/terminfo.c (grub_terminfo_set_current): Correct vt100 cursor
10653 on and off sequences.
10654
69ba137e 106552008-05-31 Robert Millan <rmh@aybabtu.com>
10656
10657 * util/update-grub_lib.in: Replace `grub-probe' with `${grub_probe}'.
10658 * util/update-grub.in: Likewise.
10659
520ae21b 106602008-05-30 Pavel Roskin <proski@gnu.org>
10661
10662 * util/biosdisk.c (linux_find_partition): Simplify logic and
10663 make the code more universal. Keep special processing for
10664 devfs, but use a simple rule for all other devices. If the
10665 device ends with a number, append 'p' and the partition number.
10666 Otherwise, append only the partition number.
10667
5786569b 106682008-05-30 Robert Millan <rmh@aybabtu.com>
10669
10670 * util/update-grub.in (GRUB_DISABLE_LINUX_UUID): Export variable.
10671 * util/grub.d/10_linux.in: If GRUB_DEVICE_UUID is set, and
10672 GRUB_DISABLE_LINUX_UUID isn't true, use the filesystem UUIDs as
10673 the `root' parameter to Linux.
10674
51500452 106752008-05-30 Robert Millan <rmh@aybabtu.com>
10676
10677 * commands/search.c (options): Rename --fs_uuid to --fs-uuid.
10678 * util/update-grub_lib.in (prepare_grub_to_access_device): Replace
10679 --fs_uuid with --fs-uuid.
10680 * util/update-grub.in: Allow filesystem UUID probes to fail (since not
10681 all filesystems support them).
10682
811d3878 106832008-05-30 Robert Millan <rmh@aybabtu.com>
10684
10685 * fs/ext2.c (grub_ext2_uuid): Use `04x' instead of '02x' as
f19dbdb7 10686 grub_printf() flags, since we're printing in units of 2 bytes.
811d3878 10687
cab63c95 106882008-05-30 Robert Millan <rmh@aybabtu.com>
10689
10690 * util/grub.d/00_header.in: Remove obsolete comment referencing
10691 convert_system_path_to_grub_path().
10692 * util/update-grub.in: Likewise.
10693 * util/update-grub_lib.in (is_path_readable_by_grub): New function.
10694 (convert_system_path_to_grub_path): Add a warning message explaining
10695 that this function is deprecated. Rely on is_path_readable_by_grub()
10696 for the readability checks.
10697 (font_path): Use is_path_readable_by_grub() for the readability
10698 check rather than convert_system_path_to_grub_path().
10699
972e2f7a 107002008-05-30 Robert Millan <rmh@aybabtu.com>
10701
10702 * util/update-grub_lib.in (prepare_grub_to_access_device): New function.
10703 * util/update-grub.in: Set `GRUB_FONT_PATH' to the system path, without
10704 converting it first.
10705 * util/grub.d/00_header.in: Use prepare_grub_to_access_device() to setup
10706 grub.cfg for access to font file, and afterwards call it again to set
10707 the root device.
10708
62191274 107092008-05-30 Robert Millan <rmh@aybabtu.com>
10710
10711 * commands/search.c (options): Add --fs_uuid option.
10712 (search_fs_uuid): New function.
10713 (grub_cmd_search): Fix --set argument passing.
10714 Use search_fs_uuid() when requested via --fs_uuid.
10715 (grub_search_init): Update help message.
10716 * fs/ext2.c (struct grub_ext2_sblock): Rename `unique_id' to `uuid'
10717 and redeclare it as an array of 16-bit words.
10718 (grub_ext2_uuid): New function.
10719 (grub_ext2_fs): Reference grub_ext2_uuid() in `uuid' struct member.
10720 * include/grub/fs.h (struct grub_fs): Add `uuid' struct member.
10721 * util/update-grub.in (GRUB_DEVICE_UUID, GRUB_DEVICE_BOOT)
10722 (GRUB_DEVICE_BOOT_UUID): New variables.
10723 (GRUB_DRIVE. GRUB_DRIVE_BOOT. GRUB_DRIVE_BOOT_GRUB): Remove.
10724 * util/grub.d/00_header.in: Set root using `search --fs_uuid' command
10725 whenever possible.
10726 * util/grub.d/10_hurd.in: Avoid explicit use of root drive. Instead,
10727 just assume `root' variable has the right value.
10728 * util/grub.d/10_linux.in: Likewise.
10729 * util/grub-probe.c (probe): Probe for filesystem UUID when requested
10730 via PRINT_FS_UUID.
10731 (main): Recognise `-t fs_uuid' argument.
10732
01b73ec8 107332008-05-30 Robert Millan <rmh@aybabtu.com>
10734
10735 * util/biosdisk.c (map): Redefine structure to hold information
10736 about GRUB drive name.
fe6b695a 10737 (get_drive): Reimplement without assuming (and verifying) BIOS-like
01b73ec8 10738 drive names.
10739 (call_hook): Remove.
10740 (grub_util_biosdisk_iterate): Access drive names via `.drive' struct
10741 member. Assume drive has partitions.
10742 (grub_util_biosdisk_open): Access device names via `.device' struct
10743 member.
10744 (open_device): Likewise.
10745 (find_drive): Likewise.
10746 (read_device_map): Adjust map[] usage to match the new struct
10747 definition. Don't check for duplicates (still possible, but not cheap
10748 anymore).
10749 (grub_util_biosdisk_fini): Free malloced buffers referenced by map[].
10750 (make_device_name): Remove assumption of BIOS-like drive names.
10751
22f16596 107522008-05-30 Pavel Roskin <proski@gnu.org>
10753
10754 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Remove, as
10755 compiling execute.c doesn't need grub_script.tab.h anymore.
10756 (normal/command.c_DEPENDENCIES): Likewise.
10757 (normal/function.c_DEPENDENCIES): Likewise.
10758 * conf/i386-ieee1275.rmk: Likewise.
10759 * conf/i386-linuxbios.rmk: Likewise.
10760 * conf/i386-pc.rmk: Likewise.
10761 * conf/powerpc-ieee1275.rmk: Likewise.
10762 * conf/sparc64-ieee1275.rmk: Likewise.
10763
528ad8f2 107642008-05-29 Pavel Roskin <proski@gnu.org>
10765
d1dff95d 10766 * disk/lvm.c (grub_lvm_scan_device): Check for the buffer end
10767 when scanning metadata for volume group name.
10768
528ad8f2 10769 * include/grub/script.h: Don't include grub_script.tab.h. It's
10770 a generated file, which may only be included from the files with
10771 DEPENDENCIES rules in the makefile. Don't use typedef YYSTYPE,
10772 use union YYSTYPE, as the later allows forward declaration.
10773 * normal/lexer.c: Don't use typedef YYSTYPE, use union YYSTYPE.
10774
47248e08 107752008-05-29 Robert Millan <rmh@aybabtu.com>
10776
10777 * term/i386/pc/at_keyboard.c: Include `grub/machine/machine.h'.
10778 (OLPC_UP, OLPC_DOWN, OLPC_LEFT, OLPC_RIGHT): New macros.
10779 [GRUB_MACHINE_IEEE1275] (keyboard_map): Add OLPC scan codes
10780 (grub_console_checkkey): Add grub_dprintf() call to report unknown
10781 scan codes.
10782
ee632529 107832008-05-29 Robert Millan <rmh@aybabtu.com>
10784
10785 * term/i386/pc/at_keyboard.c (grub_console_checkkey): Add support for
10786 control key combinations.
10787
eee96e08 107882008-05-29 Robert Millan <rmh@aybabtu.com>
10789
10790 * util/powerpc/ieee1275/grub-install.in: Move from here ...
10791 * util/ieee1275/grub-install.in: ... to here.
10792 * powerpc-ieee1275.rmk (grub_install_SOURCES): Update location.
10793 * i386-ieee1275.rmk (sbin_SCRIPTS): New variable.
10794 (grub_install_SOURCES): Likewise.
10795
da9a6a94 107962008-05-29 Robert Millan <rmh@aybabtu.com>
10797
10798 * fs/affs.c: Update copyright year.
10799 * fs/ext2.c: Likewise.
10800 * fs/fshelp.c: Likewise.
10801 * fs/hfsplus.c: Likewise.
10802 * fs/ntfs.c: Likewise.
10803 * fs/xfs.c: Likewise.
10804 * include/grub/fshelp.h: Likewise.
10805 * util/grub-mkdevicemap.c: Likewise.
10806
12e65f3a 108072008-05-28 Robert Millan <rmh@aybabtu.com>
10808
10809 * util/update-grub.in: Allow chmod call to fail, since /boot/grub/
10810 might need to be fatfs to support some firmware implementations
10811 (e.g. OFW or EFI).
10812
23023641 108132008-05-28 Robert Millan <rmh@aybabtu.com>
10814
10815 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle MMC
10816 devices.
10817 * util/grub-mkdevicemap.c (get_mmc_disk_name)
10818 (make_device_map): Likewise.
10819
887d2619 108202008-05-20 Bean <bean123ch@gmail.com>
10821
10822 * fs/fshelp.c (grub_fshelp_map_block): New function.
10823 (grub_fshelp_find_file): Use 64-bit type for pos and block address.
10824 Use `>>' and `&' operator to avoid 64-bit divide and modulo.
10825
10826 * include/grub/fshelp.h (grub_fshelp_journal_type): New enum.
10827 (GRUB_FSHELP_JOURNAL_UNUSED_MAPPING): New macro.
10828 (grub_fshelp_journal): New structure.
10829 (grub_fshelp_map_block): New function prototype.
10830 (grub_fshelp_read_file): Use grub_disk_addr_t as block type.
10831 (grub_fshelp_map_block): Likewise.
10832
10833 * fs/ext2.c (EXT3_FEATURE_COMPAT_HAS_JOURNAL): New macro.
10834 (EXT3_JOURNAL_MAGIC_NUMBER): Likewise.
10835 (EXT3_JOURNAL_DESCRIPTOR_BLOCK): Likewise.
10836 (EXT3_JOURNAL_COMMIT_BLOCK): Likewise.
10837 (EXT3_JOURNAL_SUPERBLOCK_V1): Likewise.
10838 (EXT3_JOURNAL_SUPERBLOCK_V2): Likewise.
10839 (EXT3_JOURNAL_REVOKE_BLOCK): Likewise.
10840 (EXT3_JOURNAL_FLAG_ESCAPE): Likewise.
10841 (EXT3_JOURNAL_FLAG_SAME_UUID): Likewise.
10842 (EXT3_JOURNAL_FLAG_DELETED): Likewise.
10843 (EXT3_JOURNAL_FLAG_LAST_TAG): Likewise.
10844 (grub_ext2_sblock): New members for journal support.
10845 (grub_ext3_journal_header): New structure.
10846 (grub_ext3_journal_revoke_header): Likewise.
10847 (grub_ext3_journal_block_tag): Likewise.
10848 (grub_ext3_journal_sblock): Likewise.
10849 (grub_fshelp_node): New members logfile and journal.
10850 (grub_ext2_read_block): Change block type to grub_disk_addr_t. Use
10851 grub_fshelp_map_block to get real block number.
10852 (grub_ext2_blockgroup): Use grub_fshelp_map_block to get real block
10853 number.
10854 (grub_ext2_read_inode): Likewise.
10855 (grub_ext3_get_journal): New function.
10856 (grub_read_inode): Initialize journal using grub_ext3_get_journal.
10857 (grub_ext2_close): Release memory used by journal.
10858
10859 * fs/reiserfs.c (REISERFS_MAGIC_STRING): Changed to "ReIsEr".
10860 (REISERFS_MAGIC_DESC_BLOCK): New macro.
10861 (grub_reiserfs_transaction_header): Renamed to
10862 grub_reiserfs_description_block, replace field data with real_blocks.
10863 (grub_reiserfs_commit_block): New structure.
10864 (grub_reiserfs_data): New member journal.
10865 (grub_reiserfs_get_item): Use grub_fshelp_map_block to get real block
10866 number.
10867 (grub_reiserfs_read_symlink): Likewise.
10868 (grub_reiserfs_iterate_dir): Likewise.
10869 (grub_reiserfs_open): Likewise.
10870 (grub_reiserfs_read): Likewise.
10871 (grub_reiserfs_get_journal): New function.
10872 (grub_reiserfs_mount): Use "ReIsEr" as super block magic, as there are
10873 three varieties ReIsErFs, ReIsEr2Fs and ReIsEr3Fs. Initialize journal
10874 using grub_reiserfs_get_journal.
10875 (grub_reiserfs_close): Release memory used by journal.
10876
10877 * fs/affs.c (grub_affs_read_block): Change block type to
10878 grub_disk_addr_t. Use grub_divmod64 to do 64-bit division.
10879
10880 * fs/afs.c (grub_afs_read_block): Change block type to grub_disk_addr_t.
10881
10882 * fs/hfsplus.c (grub_hfsplus_read_block): Likewise.
10883
10884 * fs/ntfs.c (grub_ntfs_read_block): Likewise.
10885
10886 * fs/udf.c (grub_udf_read_block): Change block type to
10887 grub_disk_addr_t. Use type cast to avoid warning.
10888
10889 * fs/xfs.c (grub_xfs_read_block): Likewise.
10890
b7c6bed5 108912008-05-16 Christian Franke <franke@computer.org>
10892
10893 * commands/cat.c (grub_cmd_cat): Remove non-ESC keys from keyboard queue
10894 to ensure that break with ESC will always work.
10895 * commands/sleep.c (grub_interruptible_millisleep): Likewise.
10896 Remove ESC from keyboard queue.
10897
eedf167f 108982008-05-16 Christian Franke <franke@computer.org>
10899
10900 * util/biosdisk.c: [__CYGWIN__] Add includes.
10901 (grub_util_biosdisk_open): Use Linux code also for Cygwin.
10902 (get_os_disk): Move variable declarations to OS specific
10903 parts to avoid warning.
10904 [__GNU__] (get_os_disk): Fix /dev/sdXsN case.
10905 [__CYGWIN__] (get_os_disk): Add Cygwin /dev/sdXN device names.
10906 (grub_util_biosdisk_get_grub_dev): Use Linux code also for
10907 Cygwin.
10908 * util/getroot.c: [__CYGWIN__] Add includes.
10909 (strip_extra_slashes): Fix "/" case.
10910 [__CYGWIN__] (get_win32_path): New function.
10911 [__CYGWIN__] (grub_get_prefix): Add conversion to win32 path.
10912 [__CYGWIN__] (find_root_device): Disable.
10913 [__CYGWIN__] (get_bootsec_serial): New function.
10914 [__CYGWIN__] (find_cygwin_root_device): Likewise.
10915 [__linux__] (grub_guess_root_device): Add early returns to simplify
10916 structure.
10917 [__CYGWIN__] (grub_guess_root_device): Call find_cygwin_root_device.
10918 [__linux__] (grub_util_get_dev_abstraction): Enable LVM and RAID
10919 check for Linux only.
10920
a079699e 109212008-05-15 Bean <bean123ch@gmail.com>
10922
10923 * kern/i386/pc/startup.S (grub_console_getkey): Workaround for the
10924 keyboard hang problem in apple's intel mac.
10925
1cf4059a 109262008-05-09 Robert Millan <rmh@aybabtu.com>
10927
10928 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle Virtio
10929 devices.
10930 * util/grub-mkdevicemap.c (get_virtio_disk_name)
10931 (make_device_map): Likewise.
10932 Reported by Aurelien Jarno <aurel32@debian.org>
10933
ed759390 109342008-05-07 Ian Campbell <ijc@hellion.org.uk>
10935
10936 * util/biosdisk.c (get_os_disk): Recognise xvd type disks.
10937 * util/grub-mkdevicemap.c (get_xvd_disk_name): New function.
10938 (make_device_map): Output entries for xvd type disks.
10939
b56c4eaa 109402008-05-07 Robert Millan <rmh@aybabtu.com>
10941
10942 * util/biosdisk.c (linux_find_partition, get_os_disk): Handle CCISS
10943 devices.
10944 * util/grub-mkdevicemap.c (get_cciss_disk_name)
10945 (make_device_map): Likewise.
10946 Reported by Roland Dreier <rdreier@cisco.com>
10947
7f8866ed 109482008-05-07 Robert Millan <rmh@aybabtu.com>
10949
10950 * disk/lvm.c (grub_lvm_scan_device): Detect errors in an additional
10951 grub_strstr() call. Correct a few mistakes in failure path handling.
10952
b0346e0f 109532008-05-06 Robert Millan <rmh@aybabtu.com>
10954
10955 * util/update-grub_lib.in (make_system_path_relative_to_its_root):
10956 Do not print a trailing slash (therefore, the root directory is an
10957 empty string).
10958 (convert_system_path_to_grub_path): Do not remove trailing slash
10959 from make_system_path_relative_to_its_root() output.
10960
10961 * util/i386/pc/grub-install.in: Add trailing slash to output from
10962 make_system_path_relative_to_its_root().
10963
6cf12cbd 109642008-05-06 Robert Millan <rmh@aybabtu.com>
10965
10966 * util/grub-fstest.c (grub_refresh): Call `fflush (stdout)'. This
10967 ensures that output lines aren't intermangled with those sent to
10968 stderr (via grub_util_info()).
10969 * util/grub-probe.c (grub_refresh): Likewise.
10970 * util/i386/pc/grub-setup.c (grub_refresh): Likewise.
10971
0fbb3117 109722008-05-05 Christian Franke <franke@computer.org>
10973
10974 * util/grub-mkdevicemap.c (get_floppy_disk_name) [__CYGWIN__]:
10975 Add Cygwin device names.
10976 (get_ide_disk_name) [__CYGWIN__]: Likewise.
10977 (get_scsi_disk_name) [__CYGWIN__]: Likewise.
10978 (check_device): Return error instead of success on empty name.
10979 (make_device_map): Move label inside linux specific code to
10980 prevent compiler warning.
10981
8124cdb7 109822008-04-30 Robert Millan <rmh@aybabtu.com>
10983
10984 Based on patch from Fabian Greffrath <greffrath@leat.rub.de>
10985 * util/grub.d/10_linux.in: Add ${GRUB_CMDLINE_LINUX_DEFAULT} to the
10986 first boot option.
10987 * util/update-grub.in: Export GRUB_CMDLINE_LINUX_DEFAULT.
10988
094c01d0 109892008-04-29 Robert Millan <rmh@aybabtu.com>
10990
10991 * docs/grub.cfg: New file (example GRUB configuration).
10992
f4b1fc02 109932008-04-26 Robert Millan <rmh@aybabtu.com>
10994
329ce2a5 10995 * DISTLIST: Sort (sort -u < DISTLIST | sponge DISTLIST). Add
10996 `loader/i386/ieee1275/linux.c', `loader/i386/ieee1275/linux_normal.c'
10997 and `disk/ieee1275/nand.c'.
f4b1fc02 10998
25f16ec1 109992008-04-25 Bean <bean123ch@gmail.com>
f19dbdb7 11000
25f16ec1 11001 * Makefile.in (RMKFILES): Add missing arch i386-ieee1275 and
11002 i386-linuxbios.
11003
11004 * commands/hexdump.c (grub_cmd_hexdump): Support dumping of device,
11005 change the buffer size to 4096 for cdrom device.
11006
11007 * conf/i386-ieee1275.rmk (pkglib_MODULES): Add _linux.mod, linux.mod
11008 and nand.mod.
11009 (_linux_mod_SOURCES): New variable.
11010 (_linux_mod_CFLAGS): Likewise.
11011 (_linux_mod_LDFLAGS): Likewise.
11012 (linux_mod_SOURCES): Likewise.
11013 (linux_mod_CFLAGS): Likewise.
11014 (linux_mod_LDFLAGS): Likewise.
11015 (nand_mod_SOURCES): Likewise.
11016 (nand_mod_CFLAGS): Likewise.
11017 (nand_mod_LDFLAGS): Likewise.
11018
11019 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Return
11020 GRUB_ERR_UNKNOWN_DEVICE instead of GRUB_ERR_BAD_DEVICE if no device
11021 type property. (nand device in olpc don't have this property)
11022
11023 * include/grub/disk.h (grub_disk_dev_id): New macro
11024 GRUB_DISK_DEVICE_NAND_ID.
11025
11026 * include/grub/i386/ieee1275/loader.h (grub_rescue_cmd_linux): New
11027 function prototype.
11028 (grub_rescue_cmd_initrd): Likewise.
11029
11030 * include/grub/i386/linux.h (GRUB_LINUX_OFW_SIGNATURE): New macro.
11031 (linux_kernel_params): Add new member ofw_signature, ofw_num_items,
11032 ofw_cif_handler and ofw_idt, adjust padding number.
f19dbdb7 11033
25f16ec1 11034 * include/grub/i386/pc/memory.h (grub_upper_mem): Export it if
11035 GRUB_MACHINE_IEEE1275 is defined.
11036
11037 * include/grub/ieee1275/ieee1275.h (grub_available_iterate):
11038 Use NESTED_FUNC_ATTR attribute on the hook parameter.
11039
11040 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Use NESTED_FUNC_ATTR
11041 on nested function heap_init.
11042 (grub_upper_mem): New variable for i386-ieee1275.
11043 (grub_get_extended_memory): New function for i386-ieee1275.
11044 (grub_machine_init): Call grub_get_extended_memory for i386-ieee1275.
11045
11046 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Use
11047 NESTED_FUNC_ATTR on the hook parameter. Don't quit if no device type
11048 property.
f19dbdb7 11049
25f16ec1 11050 * loader/i386/ieee1275/linux.c: New file.
11051
11052 * loader/i386/ieee1275/linux_normal.c: New file.
11053
11054 * disk/ieee1275/nand.c: New file.
11055
e89d61e9 110562008-04-18 Thomas Schwinge <tschwinge@gnu.org>
11057
11058 * util/i386/pc/grub-mkrescue.in (grub_mkimage): Don't overwrite correct
11059 value.
11060 * util/powerpc/ieee1275/grub-mkrescue.in (grub_mkimage): Likewise.
11061
602566f6 110622008-04-18 Robert Millan <rmh@aybabtu.com>
11063
11064 Restructures early code path on ieee1275 to unify grub_main() as
11065 the first C function that is executed in every platform.
11066
11067 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_init): New prototype.
11068 * kern/i386/ieee1275/startup.S (_start): Jump to grub_main() instead of
11069 cmain().
11070 * kern/powerpc/ieee1275/crt0.S (_start): Likewise.
11071 * kern/ieee1275/cmain.c (cmain): Rename to ...
11072 * kern/ieee1275/cmain.c (grub_ieee1275_init): ... this.
11073 * kern/ieee1275/init.c (grub_machine_init): Call grub_ieee1275_init()
11074 at the beginning.
11075
57490c2b 110762008-04-18 Robert Millan <rmh@aybabtu.com>
11077
11078 * util/update-grub.in: Fix syntax error when setting
11079 `GRUB_PRELOAD_MODULES'.
11080 Reported by Stephane Chazelas <stephane@artesyncp.com>
11081
1977517d 110822008-04-17 Lubomir Kundrak <lkundrak@redhat.com>
11083
11084 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): take only .text
11085 section into account, newer toolchains generate unique build ids
11086 * configure.ac: remove the test for --build-id=none acceptance,
e0c5dacb 11087 we want build ids to be preserved
1977517d 11088 * genmk.rb: add -R .note.gnu.build-id to objcopy, so build id
11089 far from other sections don't cause the raw binary images grow
11090 size
11091
bfb1f1a2 110922008-04-15 Robert Millan <rmh@aybabtu.com>
11093
11094 * disk/lvm.c: Update copyright year.
11095 * kern/misc.c: Likewise.
11096
01979850 110972008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
11098
11099 * disk/lvm.c (grub_lvm_scan_device): Add forgotten failure path when
f19dbdb7 11100 there is no memory left for physical volume name.
01979850 11101
0a1150e2 111022008-04-14 Vesa Jaaskelainen <chaac@nic.fi>
11103
11104 * disk/lvm.c (grub_lvm_scan_device): Fix logical volume's physical
11105 volume name mapping to support bigger than 9 character names properly.
11106
82ead3fe 111072008-04-13 Robert Millan <rmh@aybabtu.com>
11108
11109 * disk/i386/pc/biosdisk.c (grub_biosdisk_rw): Fix CHS limit check,
11110 as per http://www.allensmith.net/Storage/HDDlimit/Int13h.htm
11111
e54a72f5 111122008-04-13 Christian Franke <franke@computer.org>
11113
11114 * util/i386/pc/grub-mkrescue.in: Add --emulation=floppy
11115 to create a floppy emulation boot CD when non emulation mode
11116 does not work.
11117 Enable Joliet CD filesystem extension.
11118
9fe86034 111192008-04-13 Robert Millan <rmh@aybabtu.com>
11120
11121 * kern/misc.c (grub_strncat): Fix off-by-one error.
11122 Reported by Zhang Huan <zhanghuan@nrchpc.ac.cn>
11123
11124 * kern/env.c (grub_env_context_close): Clear current context, not
11125 previous one.
11126 Patch from Zhang Huan <zhanghuan@nrchpc.ac.cn>
11127
11128 * kern/misc.c (grub_strcat): Minor speed optimization (same code size).
11129
7ceeee39 111302008-04-13 Robert Millan <rmh@aybabtu.com>
11131
11132 Improve robustness when handling LVM.
11133
11134 * disk/lvm.c (grub_lvm_getvalue): Return 0 when `*p' is NULL
f19dbdb7 11135 (and leave `*p' unmodified).
7ceeee39 11136 (grub_lvm_iterate): Don't assume `vg->lvs != NULL' when iterating
11137 through it.
11138 (grub_lvm_memberlist): Don't assume `lv->vg->pvs != NULL' when
11139 iterating through it.
11140 (grub_lvm_open): Don't assume `vg->lvs != NULL' when iterating
11141 through it.
fe6b695a 11142 (grub_lvm_scan_device): Check the return value (and fail gracefully
7ceeee39 11143 when due) on each grub_lvm_getvalue() or grub_strstr() call.
11144 Don't assume `vg->pvs != NULL' when iterating through it.
11145
58cd3d85 111462008-04-13 Robert Millan <rmh@aybabtu.com>
11147
11148 * gendistlist.sh (EXTRA_DISTFILES): Add `genpartmaplist.sh'.
11149 * genmk.rb (partmap): New variable.
11150 (CLEANFILES, PARTMAPFILES): Add #{partmap}.
11151 (#{partmap}): New target rule.
11152 * genpartmaplist.sh: New file.
11153 * Makefile.in (pkglib_DATA): Add partmap.lst.
11154 (partmap.lst): New target rule.
11155 * util/i386/pc/grub-mkrescue.in: Generate grub.cfg that loads needed
11156 modules (including all partition maps), instead of preloading them.
11157
78b51059 111582007-04-13 Fabian Greffrath <fabian.greffrath@web.de>
11159
11160 * util/grub.d/30_os-prober.in: New script. Use `os-prober' and
11161 `linux-boot-prober' (if installed) to detect other operating
11162 systems which are installed on the computer and add them to
11163 the boot menu.
11164 * conf/common.rmk: Build and install 30_os-prober.
11165
a91627b4 111662008-04-12 Robert Millan <rmh@aybabtu.com>
11167
11168 * kern/powerpc/ieee1275/init.c: Move from here ...
11169 * kern/ieee1275/init.c: ... to here. Update all users.
11170
11171 * kern/powerpc/ieee1275/cmain.c: Move from here ...
11172 * kern/ieee1275/cmain.c: ... to here. Update all users.
11173
11174 * kern/powerpc/ieee1275/openfw.c: Move from here ...
11175 * kern/ieee1275/openfw.c: ... to here. Update all users.
11176
11177 * loader/powerpc/ieee1275/multiboot2.c: Move from here ...
11178 * loader/ieee1275/multiboot2.c: ... to here. Update all users.
11179
322562ea 111802008-04-10 Pavel Roskin <proski@gnu.org>
11181
11182 * configure.ac: Always use "_cv_" in cache variables for
11183 compatibility with Autoconf 2.62.
11184
a02a73c5 111852008-04-07 Robert Millan <rmh@aybabtu.com>
11186
11187 Revert grub/machine/init.h addition by Pavel (since it breaks on
11188 i386-ieee1275 and others):
11189 * util/i386/pc/misc.c: Remove grub/machine/init.h.
11190 * util/powerpc/ieee1275/misc.c: Likewise.
11191
25c024b1 111922008-04-07 Robert Millan <rmh@aybabtu.com>
11193
11194 * util/grub-probe.c (probe): Improve error message.
11195
3cbd2f98 111962008-04-07 Robert Millan <rmh@aybabtu.com>
11197
11198 * util/biosdisk.c (read_device_map): Skip devices that don't exist
11199 (this prevents the presence of a bogus entry from ruining the whole
11200 thing).
11201
87a297bf 112022008-04-06 Pavel Roskin <proski@gnu.org>
11203
36747a62 11204 * util/biosdisk.c: Include grub/util/biosdisk.h.
11205 * util/grub-fstest.c (execute_command): Make static.
11206 * util/grub-mkdevicemap.c (check_device): Likewise.
11207 * util/i386/pc/misc.c: Include grub/machine/init.h.
11208 * util/powerpc/ieee1275/misc.c: Likewise.
11209 * util/lvm.c: Include grub/util/lvm.h.
11210 * util/misc.c: Include grub/kernel.h, grub/misc.h and
11211 grub/cache.h.
11212 * util/raid.c: Include grub/util/raid.h.
11213 (grub_util_getdiskname): Make static.
11214
87a297bf 11215 * util/grub-emu.c (main): Remove calls to grub_hostfs_init() and
11216 grub_hostfs_fini(), as they are called from grub_init_all() and
11217 grub_fini_all() respectively. This fixes an infinite loop in
11218 grub-fstest due to double registration of hostfs.
11219 Reported by Christian Franke <Christian.Franke@t-online.de>
11220
f6ce7629 112212008-04-05 Pavel Roskin <proski@gnu.org>
11222
11223 * bus/pci.c (grub_pci_iterate): For multifunction devices, probe
11224 all 8 functions. Otherwise, probe function 0 only.
11225
070e49e4 112262008-04-04 Pavel Roskin <proski@gnu.org>
11227
8b088a4c 11228 * commands/lspci.c (grub_lspci_iter): Print the bus number
11229 correctly.
11230
4f657021 11231 * commands/lspci.c (grub_pci_classes): Fix typos.
11232 (grub_lspci_iter): Don't print func twice. Print vendor ID
11233 before device ID, as it's normally done.
11234
070e49e4 11235 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
11236 Fix signedness warnings.
11237 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate):
11238 Likewise.
11239 * util/ieee1275/get_disk_name.c: Include config.h so that
11240 _GNU_SOURCE is defined and getline() is declared. Mark an
11241 unused argument as such. Fix a signedness warning.
11242
ba7328dc 112432008-04-02 Pavel Roskin <proski@gnu.org>
11244
26887f22 11245 * genkernsyms.sh.in: Use more robust assignments for CC and
11246 srcdir. Quote srcdir.
11247 * gensymlist.sh.in: Likewise. Assert at the compile time that
11248 the symbol table is not empty.
11249
ba7328dc 11250 * disk/raid.c (grub_raid_memberlist): Fix a signedness warning.
11251 * fs/cpio.c (grub_cpio_read): Likewise.
11252
0f582c6b 112532008-04-01 Pavel Roskin <proski@gnu.org>
11254
4b6e1995 11255 * disk/ata.c (grub_ata_open): Don't lose precision in disk->id.
11256 * disk/host.c (grub_host_open): Likewise.
11257 * disk/loopback.c (grub_loopback_open): Likewise.
11258 * disk/memdisk.c (grub_memdisk_open): Use a string pointer for
11259 disk->id as in disk/host.c, not a multi-character constant.
11260
828a2768 11261 * util/grub-fstest.c (cmd_cmp): Use fseeko(), not fseek(). The
11262 later is obsolete, potentially dangerous and sets a bad example.
11263 * util/i386/efi/grub-mkimage.c (make_header): Likewise.
11264 * util/misc.c (grub_util_get_image_size): Likewise.
11265
2bb4fb47 11266 * disk/loopback.c (options): Improve help for "--partitions".
11267
0f582c6b 11268 * normal/arg.c (grub_arg_show_help): Fix spacing of the long
11269 options to align them with the short options, e.g. "echo -e".
11270
a33224e0 112712008-03-31 Bean <bean123ch@gmail.com>
11272
11273 * video/reader/png.c (grub_png_data): New member is_16bit and
11274 image_data.
11275 (grub_png_decode_image_header): Detect 16 bit png image.
11276 (grub_png_convert_image): New function to convert 16 bit image to 8 bit.
11277 (grub_png_decode_png): Call grub_png_convert_image for 16 bit image.
11278 (grub_video_reader_png): Release memory occupied by image_data.
11279
11280 * fs/ntfs.c (find_attr): Handle non-resident attribute list larger than
11281 4096 bytes.
11282 (grub_nfs_mount): Skip the test for sector per cluster.
11283
11284 * include/grub/ntfs.h (MAX_SPC): Removed.
11285
86cb4f54 112862008-03-31 Bean <bean123ch@gmail.com>
11287
11288 * conf/common.rmk (pkgdata_MODULES): Add afs.mod.
11289 (grub_probe_SOURCES): Add fs/afs.c.
11290 (grub_fstest_SOURCES): Likewise.
11291 (afs_mod_SOURCES): New variable.
11292 (afs_mod_CFLAGS): Likewise.
11293 (afs_mod_LDFLAGS): Likewise.
11294
11295 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/afs.c.
11296 (grub_emu_SOURCES): Likewise.
11297
11298 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
11299
11300 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11301
11302 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
11303
11304 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11305
11306 * fs/afs.c: New file.
11307
17c74c21 113082008-03-30 Pavel Roskin <proski@gnu.org>
11309
4cb68e89 11310 * disk/host.c: Include grub/misc.h to fix a warning.
11311 * util/hostfs.c: Use GRUB_MOD_INIT and GRUB_MOD_FINI to fix
11312 warnings about implicit declarations.
11313
8790bb04 11314 * fs/udf.c (grub_udf_mount): Fix warning about a shadowing a
11315 variable.
11316 * include/grub/i386/loader.h: Change declaration of
11317 grub_linux_boot() to match what grub_loader_set() expects.
11318 * util/getroot.c (grub_guess_root_device): Return const char* to
11319 fix a warning.
11320 * util/grub-probe.c (probe): Fix a warning about uninitialized
11321 abstraction_name variable.
11322 * util/i386/get_disk_name.c (grub_util_get_disk_name): Mark
11323 second argument as unused to fix a warning.
11324
9a3f3296 11325 * loader/i386/pc/multiboot2.c (grub_mb2_arch_elf64_hook): Add
11326 missing grub_error() call.
11327
0ecef90d 11328 * util/update-grub_lib.in: Define datarootdir, since Autoconf
11329 2.60 and newer uses it to define datadir.
11330
0bf6d401 11331 * commands/sleep.c: Fix warning about implicit declaration.
11332 * disk/memdisk.c: Likewise.
11333 * loader/aout.c: Likewise.
11334 * loader/i386/bsd_normal.c: Likewise.
11335 * util/grub-probe.c: Likewise.
11336
7cdacf97 11337 * commands/i386/cpuid.c (has_longmode): Make static.
11338 * disk/i386/pc/biosdisk.c (cd_drive): Likewise.
11339 * include/grub/i386/bsd.h (bios_memmap_t): Remove, it's unused.
11340
17c74c21 11341 * kern/i386/pc/startup.S (real_to_prot): Use %cs prefix to load
11342 GDT. This is more robust, as %ds can change.
11343 (grub_biosdisk_rw_int13_extensions): Don't clear %ds before
11344 calling real_to_prot().
11345 (grub_biosdisk_get_diskinfo_int13_extensions): Likewise.
11346
80a3e68b 113472008-03-28 Pavel Roskin <proski@gnu.org>
11348
11349 * kern/i386/pc/startup.S: Assert that uncompressed functions
11350 don't spill beyond GRUB_KERNEL_MACHINE_RAW_SIZE.
11351 * kern/i386/pc/lzo1x.S: Remove all .align directives in the
11352 code, as they push parts of the code (error handlers) beyond
11353 GRUB_KERNEL_MACHINE_RAW_SIZE. Speed is not as important in this
11354 code as correctness and size.
11355
77bcd272 113562008-03-28 Pavel Roskin <proski@gnu.org>
11357
11358 * kern/i386/pc/startup.S
11359 (grub_biosdisk_get_diskinfo_int13_extensions): When converting
11360 data block address to the real mode, keep offset minimal. This
11361 works around a bug in AWARD BIOS on old Athlon systems, which
11362 makes CD detection hang.
11363
c5dfd43b 113642008-03-26 Pavel Roskin <proski@gnu.org>
11365
11366 * normal/color.c (grub_parse_color_name_pair): Make `name' a
11367 const.
11368 * include/grub/normal.h: Add grub_parse_color_name_pair()
11369 declaration.
11370
bf962df2 113712008-03-24 Bean <bean123ch@gmail.com>
11372
11373 * disk/i386/pc/biosdisk.c (cd_start): Removed.
11374 (cd_count): Removed.
11375 (cd_drive): New variable.
11376 (grub_biosdisk_get_drive): Don't check for (cdN) device.
11377 (grub_biosdisk_call_hook): Likewise.
11378 (grub_biosdisk_iterate): Change cdrom detection method.
11379 (grub_biosdisk_open): Replace cd_start with cd_drive.
11380 (GRUB_MOD_INIT): Use grub_biosdisk_get_cdinfo_int13_extension to
11381 detect cdrom device.
11382
11383 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_MACHINE_CDROM_START):
11384 Removed.
11385 (GRUB_BIOSDISK_MACHINE_CDROM_END): Removed.
11386 (GRUB_BIOSDISK_CDTYPE_NO_EMUL): New macro.
11387 (GRUB_BIOSDISK_CDTYPE_1_2_M): Likewise.
11388 (GRUB_BIOSDISK_CDTYPE_1_44_M): Likewise.
11389 (GRUB_BIOSDISK_CDTYPE_2_88_M): Likewise.
11390 (GRUB_BIOSDISK_CDTYPE_HARDDISK): Likewise.
11391 (GRUB_BIOSDISK_CDTYPE_MASK): Likewise.
11392 (grub_biosdisk_cdrp): New structure.
11393 (grub_biosdisk_get_cdinfo_int13_extensions): New function.
11394
11395 * include/grub/i386/pc/kernel.h (grub_boot_drive): Export this variable.
11396
11397 * kern/i386/pc/init.c (make_install_device): Don't use (cdN) as root
11398 device.
11399
11400 * kern/i386/pc/startup.S (grub_biosdisk_get_cdinfo_int13_extensions):
11401 New function.
11402
68e7fc7a 114032008-03-20 Robert Millan <rmh@aybabtu.com>
11404
11405 Remove 2 TiB limit in ata.mod.
11406 * disk/ata.c (grub_ata_device): Promote `size' to grub_uint64_t.
11407 (grub_ata_dumpinfo): Print sector count with 0x%llx.
11408 (grub_ata_identify): Interpret `&info16[100]' as a pointer to
11409 grub_uint64_t instead of grub_uint32_t.
11410
38ad2cf5 114112008-03-05 Bean <bean123ch@gmail.com>
11412
11413 * loader/i386/pc/multiboot.c (grub_multiboot_get_bootdev): New function.
11414 (grub_multiboot): Set boot device.
11415
11416 * boot/i386/pc/lnxboot.S (real_code_2): Set %dh to 0xFF.
11417
2b89344e 114182008-03-02 Bean <bean123ch@gmail.com>
11419
11420 * fs/reiserfs.c (grub_reiserfs_read_symlink): Add 0 at the end of
11421 symlink_buffer.
11422
87a95d1f 114232008-03-01 Yoshinori K. Okuji <okuji@enbug.org>
11424
11425 * DISTLIST: Added docs/fdl.texi, docs/grub.texi, docs/mdate-sh and
11426 texinfo.tex.
11427
11428 * docs/grub.texi: New file. Copied from GRUB Legacy, and slightly
11429 modified.
11430
11431 * docs/fdl.texi: New file.
f19dbdb7 11432
87a95d1f 11433 * docs/mdate-sh: New file. Copied from gnulib.
11434 * docs/texinfo.tex: Likewise.
11435
11436 * config.guess: Updated from gnulib.
11437 * install-sh: Likewise.
11438
7dc15d8e 114392008-02-28 Robert Millan <rmh@aybabtu.com>
11440
11441 * conf/i386-linuxbios.rmk (pkglib_MODULES): Add aout.mod.
11442 (aout_mod_SOURCES): New variable.
11443 (aout_mod_CFLAGS): Likewise.
11444 (aout_mod_LDFLAGS): Likewise.
11445
11446 * conf/i386-ieee1275.rmk: Likewise.
11447
b00ab696 114482008-02-28 Robert Millan <rmh@aybabtu.com>
11449
11450 * util/update-grub.in: Reorganise terminal validity check. Accept
11451 `ieee1275:console' (OLPC) and `*:gfxterm' as valid too.
11452 Based on suggestion by Franklin PIAT.
11453
79ca2d78 114542008-02-28 Fabian Greffrath <greffrath@leat.rub.de>
11455
11456 * include/grub/util/getroot.h (grub_util_check_block_device): Export new
11457 function.
11458 * util/getroot.c (grub_util_check_block_device): New function that
11459 returns the given argument if it is a block device and returns NULL else.
11460 * util/grub-probe.c (argument_is_device): New variable.
11461 (probe): Promote device_name from a variable to an argument. Receive
11462 device_name from grub_util_check_block_device() if path is NULL and from
11463 grub_guess_root_device() else. Do not free() device_name anymore.
f19dbdb7 11464 (options): Introduce new parameter '-d, --device'.
79ca2d78 11465 (main): Add description of the new parameter to the help screen.
11466 Rename path variable to argument. Set argument_is_device if the '-d'
11467 option is given. Pass argument to probe() depending on
11468 argument_is_device.
11469
0d16e571 114702008-02-24 Bean <bean123ch@gmail.com>
11471
11472 * fs/iso9660.c (GRUB_ISO9660_VOLDESC_BOOT): New macro.
11473 (GRUB_ISO9660_VOLDESC_PRIMARY): Likewise.
11474 (GRUB_ISO9660_VOLDESC_SUPP): Likewise.
11475 (GRUB_ISO9660_VOLDESC_PART): Likewise.
11476 (GRUB_ISO9660_VOLDESC_END): Likewise.
11477 (grub_iso9660_primary_voldesc): New member escape.
11478 (grub_iso9660_data): New member joliet.
11479 (grub_iso9660_convert_string): New function.
11480 (grub_iso9660_mount): Detect joliet extension.
11481 (grub_iso9660_iterate_dir): Convert filename when joliet is detected.
11482 (grub_iso9660_iso9660_label): Likewise.
11483
11484 * conf/common.rmk (pkgdata_MODULES): Add udf.mod.
11485 (grub_setup_SOURCES): Add fs/udf.c.
11486 (grub_fstest_SOURCES): Likewise.
11487 (udf_mod_SOURCES): New variable.
11488 (udf_mod_CFLAGS): Likewise.
11489 (udf_mod_LDFLAGS): Likewise.
11490
11491 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/udf.c.
11492 (grub_emu_SOURCES): Likewise.
11493
11494 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
11495
11496 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11497
11498 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
11499
11500 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11501
11502 * fs/udf.c: New file.
11503
8a594a17 115042008-02-24 Robert Millan <rmh@aybabtu.com>
11505
11506 * conf/i386-efi.rmk (normal/function.c_DEPENDENCIES)
11507 (normal/lexer.c_DEPENDENCIES): New variables.
11508 * conf/i386-ieee1275.rmk (normal/function.c_DEPENDENCIES)
11509 (normal/lexer.c_DEPENDENCIES): Likewise.
11510 * conf/i386-linuxbios.rmk (normal/function.c_DEPENDENCIES)
11511 (normal/lexer.c_DEPENDENCIES): Likewise.
11512 * conf/i386-pc.rmk (normal/function.c_DEPENDENCIES)
11513 (normal/lexer.c_DEPENDENCIES): Likewise.
11514 * conf/powerpc-ieee1275.rmk (normal/function.c_DEPENDENCIES)
11515 (normal/lexer.c_DEPENDENCIES): Likewise.
11516 * conf/sparc64-ieee1275.rmk (normal/function.c_DEPENDENCIES)
11517 (normal/lexer.c_DEPENDENCIES): Likewise.
11518
2dc33c03 115192008-02-23 Robert Millan <rmh@aybabtu.com>
11520
11521 * partmap/gpt.c (grub_gpt_magic): Add `0x' qualifier to each member,
11522 since they were intended to be in hex. This didn't break previously
11523 because of a bug in gpt_partition_map_iterate() (see below).
11524
11525 (gpt_partition_map_iterate): Replace `grub_memcmp' with `! grub_memcmp'
11526 when checking the validity of GPT header.
11527 Remove `partno', since it always provides the same information as `i'.
11528
f6f4cfb0 115292008-02-21 Yoshinori K. Okuji <okuji@enbug.org>
11530
11531 * include/grub/efi/time.h: Fix a wrong comment.
11532
79ff665f 115332008-02-19 Pavel Roskin <proski@gnu.org>
11534
11535 * kern/rescue.c (grub_enter_rescue_mode): Improve initial
11536 message.
11537
d38e24c2 115382008-02-19 Bean <bean123ch@gmail.com>
11539
11540 * conf/i386-pc.rmk (pkglib_MODULES): Add aout.mod _bsd.mod and bsd.mod.
11541 (aout_mod_SOURCES): New variable.
11542 (aout_mod_CFLAGS): Likewise.
11543 (aout_mod_LDFLAGS): Likewise.
11544 (_bsd_mod_SOURCES): New variable.
11545 (_bsd_mod_CFLAGS): Likewise.
11546 (_bsd_mod_LDFLAGS): Likewise.
11547 (bsd_mod_SOURCES): New variable.
11548 (bsd_mod_CFLAGS): Likewise.
11549 (bsd_mod_LDFLAGS): Likewise.
11550
11551 * include/grub/aout.h: New file.
11552
11553 * include/grub/i386/loader.h (grub_unix_real_boot): New function.
11554
11555 * include/grub/i386/bsd.h: New file.
11556
11557 * include/grub/i386/pc/init.h (grub_get_mmap_entry): Use EXPORT_FUNC
11558 to make it public.
11559
11560 * kern/elf.c (grub_elf32_load): Get the physical address after the hook
11561 function is called, so that it's possible to change it inside the hook.
11562 (grub_elf64_load): Likewise.
11563 (grub_elf_file): Don't close the file if elf header is not found.
11564 (grub_elf_close): Close the file if grub_elf_file fails (The new
11565 grub_elf_file won't close it).
11566 (grub_elf32_size): Use NESTED_FUNC_ATTR for nested function calcsize.
11567 (grub_elf64_size): Likewise.
11568
11569 * kern/i386/loader.S (grub_unix_real_boot): New function.
11570
11571 * loader/aout.c: New file.
11572
11573 * loader/i386/bsd.c: New file.
11574
11575 * loader/i386/bsd_normal.c: New file.
11576
11577 * loader/i386/pc/multiboot.c (grub_multiboot): Handle a.out format.
11578
11579 * loader/multiboot2.c (grub_multiboot2): Reset grub_errno so that it
fe987087 11580 can test other formats.
d38e24c2 11581
b93bdb0f 115822008-02-19 Robert Millan <rmh@aybabtu.com>
11583
11584 * partmap/gpt.c: Include `<grub/gpt_partition.h>'.
11585 (grub_gpt_partition_type_empty): Redefine with macro from
11586 `<grub/gpt_partition.h>'.
11587 (gpt_partition_map_iterate): Adjust partition type comparison.
11588
11589 Export `entry' as partmap-specific `part.data' struct.
11590 (grub_gpt_header, grub_gpt_partentry): Move from here ...
11591
11592 * include/grub/gpt_partition.h (grub_gpt_header)
11593 (grub_gpt_partentry): ... to here (new file).
11594
11595 * util/i386/pc/grub-setup.c: Include `<grub/gpt_partition.h>'.
11596
11597 (grub_gpt_partition_type_bios_boot): New const variable, defined
11598 with macro from `<grub/gpt_partition.h>'.
11599
11600 (setup): Replace `first_start' with `embed_region', which keeps
11601 track of the embed region (and is partmap-agnostic).
11602
11603 Replace find_first_partition_start() with find_usable_region(),
11604 which finds a usable region for embedding using partmap-specific
11605 knowledge (supports PC/MSDOS and GPT).
11606
11607 Fix all assumptions that the embed region start at sector 1, using
11608 `embed_region.start' from now on. Similarly, use `embed_region.end'
11609 rather than `first_start' to calculate available size.
11610
11611 In grub_util_info() message, replace "into after the MBR" with an
11612 indication of the specific sector our embed region starts at.
11613
66cb40f6 116142008-02-19 Robert Millan <rmh@aybabtu.com>
11615
11616 * DISTLIST: Replace `commands/ieee1275/halt.c' and
11617 `commands/ieee1275/reboot.c' with `commands/halt.c' and
11618 `commands/reboot.c'.
11619 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
11620 (halt_mod_SOURCES): Likewise.
11621 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES, reboot_mod_SOURCES)
11622 (halt_mod_SOURCES): Likewise.
11623
b7202015 116242008-02-17 Christian Franke <franke@computer.org>
11625
11626 * commands/cat.c (grub_cmd_cat): Add break on GRUB_TERM_ESC key.
11627
32b0fc49 116282008-02-17 Robert Millan <rmh@aybabtu.com>
11629
11630 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
11631 set `first_start' to 0 for non-PC/MSDOS partition maps.
11632
aca63502 116332008-02-16 Robert Millan <rmh@aybabtu.com>
11634
11635 * util/i386/pc/grub-setup.c (setup): In find_first_partition_start(),
11636 do not assume partition map is PC/MSDOS before performing checks that
11637 are specific to that layout.
11638
0de8be86 116392008-02-13 Robert Millan <rmh@aybabtu.com>
11640
11641 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Remove
11642 `commands/i386/pc/halt.c' and `commands/i386/pc/reboot.c'.
11643 * kern/i386/linuxbios/init.c (grub_halt, grub_reboot): Remove stubs.
11644
c3db8364 116452008-02-13 Yoshinori K. Okuji <okuji@enbug.org>
11646
11647 * configure.ac: Only a cosmetic change on the handling of
11648 -fno-stack-protector.
11649
f714229e 116502008-02-12 Alexandre Boeglin <alex@boeglin.org>
11651
c3db8364 11652 * conf/i386-efi.rmk (grub_emu_SOURCES): Replace
11653 commands/i386/pc/halt.c and reboot.c by commands/halt.c and
11654 reboot.c.
f714229e 11655 (grub_install_SOURCES): Add halt.mod and reboot.mod.
11656 (halt_mod_SOURCES): New variable.
11657 (halt_mod_CFLAGS): Likewise.
11658 (halt_mod_LDFLAGS): Likewise.
11659 (reboot_mod_SOURCES): Likewise.
11660 (reboot_mod_CFLAGS): Likewise.
11661 (reboot_mod_LDFLAGS): Likewise.
11662
c3db8364 11663 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Replace
11664 commands/ieee1275/halt.c and reboot.c by commands/halt.c and
11665 reboot.c.
f714229e 11666 (halt_mod_SOURCES): Likewise.
11667 (reboot_mod_SOURCES): Likewise.
11668
c3db8364 11669 * conf/i386-pc.rmk (grub_emu_SOURCES): Replace
11670 commands/i386/pc/reboot.c by commands/reboot.c.
f714229e 11671 (reboot_mod_SOURCES): Likewise.
11672
11673 * commands/i386/pc/reboot.c: merge this file ...
11674
11675 * commands/ieee1275/reboot.c: ... and this file ...
11676
11677 * commands/reboot.c: ... to this file.
c3db8364 11678 Add some precompiler directive to include the correct header for
11679 each machine.
f714229e 11680
11681 * commands/ieee1275/halt.c: move this file ...
11682
11683 * commands/halt.c: ... to here.
c3db8364 11684 Add some precompiler directive to include the correct header for
11685 each machine.
f714229e 11686
11687 * include/grub/efi/efi.h (grub_reboot): New function declaration.
11688 (grub_halt): Likewise.
11689
11690 * kern/efi/efi.c (grub_reboot): New function.
11691 (grub_halt): Likewise.
11692
c74493e0 116932008-02-12 Robert Millan <rmh@aybabtu.com>
11694
11695 * util/getroot.c (grub_guess_root_device): Inspect /dev/evms before
11696 /dev (like it is done for /dev/mapper). This doesn't provide support
11697 for EVMS, but at least it is now easy to identify the problem when it
11698 arises.
11699
d0db4b04 117002008-02-11 Robert Millan <rmh@aybabtu.com>
11701
11702 * util/biosdisk.c (grub_util_biosdisk_open, linux_find_partition)
11703 (grub_util_biosdisk_get_grub_dev): Check open() exit status by
11704 comparing it with -1, not 0.
11705
bf748642 117062008-02-10 Robert Millan <rmh@aybabtu.com>
11707
11708 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `disk/raid.c' and
11709 `disk/lvm.c'.
11710 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
11711 * conf/i386-pc.rmk (grub_setup_SOURCES): Likewise.
11712
11713 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Move `disk/raid.c' and
11714 `disk/lvm.c' to the end of the list.
11715 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
11716 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
11717
b5db202a 117182008-02-10 Robert Millan <rmh@aybabtu.com>
11719
11720 * kern/main.c (grub_load_normal_mode): Do not reset `grub_errno'. Call
11721 grub_print_error() instead. This will let user know why we're entering
11722 rescue mode.
11723 Based on suggestions from Sam Morris.
11724
83abee31 117252008-02-10 Alexandre Boeglin <alex@boeglin.org>
11726
11727 * normal/arg.c (grub_arg_parse): If one of the args is "--", call add_arg()
11728 on remaining N args, instead of "--" arg N times.
11729
78d5a08b 117302008-02-09 Vesa Jaaskelainen <chaac@nic.fi>
11731
11732 * font/manager.c (unknown_glyph): Added variable for unknown glyph.
11733 (fill_with_default_glyph): Changed to use unknown_glyph for fill
11734 pattern for unknown glyphs.
11735
68807e5f 117362008-02-09 Robert Millan <rmh@aybabtu.com>
11737
11738 * configure.ac: Probe for `help2man'.
11739 * Makefile.in (builddir): New variable.
11740 (HELP2MAN): Likewise. Set to `true' when @HELP2MAN@ doesn't provide it,
11741 or otherwise add a few flags/options to it.
11742 (install-local): For every executable utility or script that is
11743 installed, invoke $(HELP2MAN) to install a manpage based on --help
11744 output.
11745
11746 * util/i386/pc/grub-install.in: Move down `update-grub_lib' sourcing, so
11747 that it doesn't prevent --help from working in build tree.
11748
11749 * util/i386/pc/grub-mkrescue.in (usage): Replace `grub-devel@gnu.org'
11750 with `bug-grub@gnu.org'.
11751 * util/powerpc/ieee1275/grub-mkrescue.in (usage): Likewise.
11752 * util/update-grub.in (usage): New function.
11753 Implement proper argument check, with support for --help and --version
11754 (as well as existing -y).
11755
117562008-02-09 Christian Franke <franke@computer.org>
0d9ff7f0 11757
11758 * commands/cat.c (grub_cmd_cat): Print '\r' as hex to
11759 avoid overwriting previous output.
11760 * kern/rescue.c (grub_rescue_cmd_cat): Likewise.
11761
c1962162 117622008-02-09 Robert Millan <rmh@aybabtu.com>
11763
11764 * normal/menu.c (run_menu): If timeout is set to zero, don't bother
11765 drawing the menu.
11766
3dac2e3f 117672008-02-09 Robert Millan <rmh@aybabtu.com>
11768
11769 * commands/sleep.c: New file.
11770 * conf/common.rmk (pkglib_MODULES): Add `commands/sleep.c'.
11771 (sleep_mod_SOURCES): New variable.
11772 (sleep_mod_CFLAGS): Likewise.
11773 (sleep_mod_LDFLAGS): Likewise.
11774
7a634e08 117752008-02-09 Robert Millan <rmh@aybabtu.com>
11776
11777 * disk/raid.c (grub_raid_scan_device): Add a pair of sanity checks for
11778 situations in which we can deduce the RAID size and the superblock
11779 doesn't match it.
11780
b92f0c18 117812008-02-09 Robert Millan <rmh@aybabtu.com>
11782
11783 * disk/lvm.c [GRUB_UTIL] (grub_lvm_memberlist): New function. Construct
11784 and return a grub_diskmemberlist_t composed of LVM physical volumes.
11785 [GRUB_UTIL] (grub_lvm_dev): Add `memberlist' member.
11786
11787 * disk/raid.c [GRUB_UTIL] (grub_raid_memberlist): New function. Construct
11788 and return a grub_diskmemberlist_t composed of physical array members.
11789 [GRUB_UTIL] (grub_raid_dev): Add `memberlist' member.
11790
11791 * include/grub/disk.h [GRUB_UTIL] (grub_disk_memberlist): New struct
11792 prototype.
11793 [GRUB_UTIL] (struct grub_disk_dev): Add `memberlist' function pointer.
11794 [GRUB_UTIL] (struct grub_disk_memberlist): New struct declaration.
11795 [GRUB_UTIL] (grub_disk_memberlist_t): New typedef.
11796
11797 * util/grub-probe.c (probe): Move partmap probing code from here ...
11798 (probe_partmap): ... to here.
11799 (probe): Use probe_partmap() once for the disk we're probing, and
11800 additionally, when such disk contains a memberlist() struct member,
11801 once for each disk that is contained in the structure returned by
11802 memberlist().
11803
91a4bf68 118042008-02-09 Robert Millan <rmh@aybabtu.com>
11805
11806 * util/grub-probe.c (main): When `verbosity > 1', set `debug'
11807 environment variable to 'all' in order to obtain debug output from
11808 non-util/ code.
11809 * util/i386/pc/grub-setup.c (main): Likewise.
11810
a96f9caa 118112008-02-08 Robert Millan <rmh@aybabtu.com>
11812
11813 * disk/raid.c (grub_raid_scan_device): Check for
11814 `array->device[sb.this_disk.number]' rather than for
11815 `array->device[sb.this_disk.number]->name', since the latter is not
fe6b695a 11816 guaranteed to be accessible.
a96f9caa 11817
b37a9222 118182008-02-08 Robert Millan <rmh@aybabtu.com>
11819
11820 * disk/raid.c: Update copyright.
11821 * fs/cpio.c: Likewise.
11822 * include/grub/raid.h: Likewise.
11823 * loader/i386/pc/multiboot.c: Likewise.
11824 * util/hostfs.c: Likewise.
11825
5626aee1 118262008-02-08 Robert Millan <rmh@aybabtu.com>
11827
11828 * include/grub/raid.h (struct grub_raid_array): Change type of `device'
11829 to a grub_disk_t array.
11830 * disk/raid.c (grub_raid_read): Replace `device[x].disk' accesses with
11831 `device[x]'.
11832 (grub_raid_scan_device): Replace `device[x].name' accesses with
11833 `device[x]->name'. Simplify initialization of `array->device[x]'.
11834
554f0187 118352008-02-08 Robert Millan <rmh@aybabtu.com>
11836
11837 * disk/raid.c (grub_raid_open, grub_raid_scan_device): Add a few
11838 grub_dprintf() calls.
11839 * kern/disk.c (grub_disk_read): Include grub_errmsg in out of range
11840 error message.
11841
1ec8425d 118422008-02-07 Christian Franke <franke@computer.org>
11843
11844 * util/hostfs.c (grub_hostfs_open): Use fseeko and ftello
11845 instead of fseek and ftell to support large files.
11846 (grub_hostfs_read): Likewise.
11847
f2156fda 118482008-02-07 Robert Millan <rmh@aybabtu.com>
11849
11850 Patch from Jeroen Dekkers.
11851 * disk/raid.c (grub_raid_scan_device): Reset `grub_errno' on disk
fe6b695a 11852 failure, since successfully reading all array members might not be
f2156fda 11853 required.
11854
9216e0e7 118552008-02-06 Robert Millan <rmh@aybabtu.com>
11856
11857 * util/grub-probe.c (probe): Simplify partmap probing (with the
11858 assumption that the first word up to the underscore equals to
11859 the module name).
11860
b0dfd29a 118612008-02-06 Christian Franke <franke@computer.org>
11862
11863 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_NONE
11864 (and set *ofs = 0) instead of GRUB_ERR_FILE_NOT_FOUND on
11865 last block of a cpio or tar stream.
11866 Check for "TRAILER!!!" instead of any empty data
11867 block to detect last block of a cpio stream.
11868 (grub_cpio_dir): Fix constness of variable np.
11869 (grub_cpio_open): Return GRUB_ERR_FILE_NOT_FOUND if
11870 cpio or tar trailer is detected. This fixes a crash
11871 on open of a non existing file.
11872
c32865bf 118732008-02-05 Bean <bean123ch@gmail.com>
11874
11875 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Get physical
11876 address of entry.
11877 (grub_multiboot_load_elf64): Likewise.
11878 (grub_multiboot): Initialize mbi structure.
11879
11880 * util/grub-fstest.c: Don't include unused header file script.h.
11881
fe6b695a 11882 * conf/common.rmk (grub-fstest.c_DEPENDENCIES): Move to the beginning
c32865bf 11883 of file.
11884 (grub_fstest_SOURCES): Likewise.
11885
409480b7 118862008-02-05 Robert Millan <rmh@aybabtu.com>
11887
11888 * include/grub/term.h (GRUB_TERM_LEFT, GRUB_TERM_RIGHT)
11889 (GRUB_TERM_UP, GRUB_TERM_DOWN, GRUB_TERM_HOME, GRUB_TERM_END)
11890 (GRUB_TERM_DC, GRUB_TERM_PPAGE, GRUB_TERM_NPAGE, GRUB_TERM_ESC)
11891 (GRUB_TERM_TAB, GRUB_TERM_BACKSPACE): New macros.
11892
11893 * kern/i386/pc/startup.S: Include `<grub/term.h>'.
11894 (translation_table): Replace hardcoded values with macros
11895 provided by `<grub/term.h>'.
11896
11897 * term/i386/pc/at_keyboard.c: Include `<grub/term.h>'.
11898 (keyboard_map): Correct/add a few values, with macros provided
11899 by `<grub/term.h>'.
11900 (keyboard_map_shift): Zero values that don't differ from their
11901 `keyboard_map' equivalents.
11902 (grub_console_checkkey): Optimize KEYBOARD_STATUS_CAPS_LOCK toggling.
11903 Discard the second scan code that is always sent by Caps lock.
11904 Only use `keyboard_map_shift' when it provides a non-zero value,
11905 otherwise fallback to `keyboard_map'.
11906
99fadbaa 119072008-02-04 Bean <bean123ch@gmail.com>
11908
11909 * Makefile.in (enable_grub_fstest): New variable.
11910
11911 * conf/common.rmk (grub_fstest_init.lst): New rule.
11912 (grub_fstest_init.h): Likewise.
11913 (grub_fstest_init.c): Likewise.
11914 (util/grub-fstest.c_DEPENDENCIES): New variable.
11915 (grub_fstest_SOURCES): Likewise.
11916
11917 * configure.ac (enable_grub_fstest): Check for --enable-grub-fstest.
11918
11919 * util/grub-fstest.c: New file.
11920
bf567c50 119212008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
11922
11923 Make grub-setup handle a separate root device.
f19dbdb7 11924
bf567c50 11925 * util/i386/pc/grub-setup.c (setup): Always open the root device,
11926 so that the root device can be compared with the destination
11927 device.
11928 When embedding the core image, if the root and destination devices
11929 are different, set ROOT_DRIVE to ROOT_DEV->DISK->ID. Otherwise, to
11930 0xFF.
11931 When not embedding, set ROOT_DRIVE to 0xFF.
f19dbdb7 11932
9be6b98b 119332008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
11934
11935 Add support for having a grub directory in a different drive. This
11936 is still only the data handling part.
f19dbdb7 11937
9be6b98b 11938 * kern/i386/pc/startup.S (multiboot_trampoline): Set %dh to 0xFF.
11939 (codestart): Save %dh in GRUB_ROOT_DRIVE.
11940 (grub_root_drive): New variable.
11941
11942 * kern/i386/pc/init.c (make_install_device): Use GRUB_ROOT_DRIVE
11943 instead of GRUB_BOOT_DRIVE to construct a device name. Set
11944 GRUB_ROOT_DRIVE to GRUB_BOOT_DRIVE if it is 0xFF, otherwise use it
11945 as it was.
11946
11947 * include/grub/i386/pc/kernel.h (grub_root_drive): New prototype.
11948
11949 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_ROOT_DRIVE): New
11950 macro.
11951 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Set to 0x4f.
11952
11953 * boot/i386/pc/pxeboot.S (_start): Set %dh to 0xFF. For now, this
11954 is bogus, because PXE booting does not specify any drive
11955 correctly.
11956
11957 * boot/i386/pc/lnxboot.S (reg_edx): Set the second byte to 0xFF. I
11958 am not sure if this is really correct.
11959
11960 * boot/i386/pc/cdboot.S: Set %dh to 0xFF, because the root drive
11961 is always identical to the boot drive when booting from a CD.
11962
11963 * boot/i386/pc/boot.S (MOV_MEM_TO_AL): Removed. Not needed any
11964 longer.
11965 (root_drive): New variable.
11966 (real_start): Unconditionally set %dh to ROOT_DRIVE.
11967 (setup_sectors): Push %dx right after popping it, because %dh will
11968 be modified later.
11969 (copy_buffer): Restore %dx.
11970
e0ca0677 119712008-02-03 Robert Millan <rmh@aybabtu.com>
11972
11973 * util/i386/pc/grub-mkrescue.in: Rewrite most of image generation to
11974 use `cdboot.img' for cdrom images.
11975
3b3f6629 119762008-02-03 Robert Millan <rmh@aybabtu.com>
11977
11978 * util/grub.d/00_header.in: Issue scripting commands for GRUB to
11979 only setup gfxterm when `font' command has succeeded.
11980
d42b3672 119812008-02-03 Robert Millan <rmh@aybabtu.com>
11982
11983 * loader/multiboot_loader.c [GRUB_MACHINE_LINUXBIOS]
11984 (grub_rescue_cmd_multiboot_loader)
11985 (grub_rescue_cmd_module_loader): Enable multiboot1 calls.
11986
fa370ea6 119872008-02-03 Pavel Roskin <proski@gnu.org>
11988
e0c5dacb 11989 * kern/i386/pc/startup.S (grub_chainloader_real_boot): Pop
fa370ea6 11990 %edx and %esi from stack only after grub_gate_a20() is called.
11991 grub_gate_a20() clobbers %edx.
11992
f2a76e1d 119932008-02-03 Yoshinori K. Okuji <okuji@enbug.org>
11994
11995 * configure.ac (AC_INIT): Bumped to 1.96.
11996
11997 * DISTLIST: Added boot/i386/pc/cdboot.S, bus/pci.c,
11998 commands/lspci.c,disk/memdisk.c, include/grub/pci.h,
11999 include/grub/i386/pc/pci.h, video/readers/jpeg.c, and
12000 video/readers/png.c.
12001
90fd32d1 120022008-02-03 Bean <bean123ch@gmail.com>
9be665dd 12003
12004 * conf/i386-pc.rmk (pkglib_IMAGES): Add cdboot.img.
12005 (cdboot_img_SOURCES): New variable.
12006 (cdboot_img_ASFLAGS): New variable.
12007 (cdboot_img_LDFLAGS): New variable.
12008
12009 * boot/i386/pc/cdboot.S: New file.
12010
12011 * disk/i386/pc/biosdisk.c (cd_start): New variable.
12012 (cd_count): Likewise.
12013 (grub_biosdisk_get_drive): Add support for cd device.
12014 (grub_biosdisk_call_hook): Likewise.
12015 (grub_biosdisk_iterate): Likewise.
12016 (grub_biosdisk_open): Likewise.
12017 (GRUB_BIOSDISK_CDROM_RETRY_COUNT): New macro.
12018 (grub_biosdisk_rw): Support reading from cd device.
12019 (GRUB_MOD_INIT): Iterate cd devices.
12020
12021 * include/grub/i386/pc/biosdisk.h (GRUB_BIOSDISK_FLAG_CDROM): New macro.
12022 (GRUB_BIOSDISK_MACHINE_CDROM_START): Likewise.
12023 (GRUB_BIOSDISK_MACHINE_CDROM_END): Likewise.
12024
12025 * kern/i386/pc/init.c (make_install_device): Check for cd device.
12026
4020aa53 120272008-02-02 Robert Millan <rmh@aybabtu.com>
12028
12029 * commands/read.c: New file.
12030 * conf/common.rmk (pkglib_MODULES): Add `commands/read.c'.
12031 (read_mod_SOURCES): New variable.
12032 (read_mod_CFLAGS): Likewise.
12033 (read_mod_LDFLAGS): Likewise.
12034
e03a1132 120352008-02-02 Robert Millan <rmh@aybabtu.com>
12036
12037 * normal/main.c (grub_normal_execute): Check for `menu->size' when
12038 determining whether menu has to be displayed.
12039
58c69220 120402008-02-02 Marco Gerards <marco@gnu.org>
12041
12042 * bus/pci.c: New file.
12043
12044 * include/grub/pci.h: Likewise.
12045
12046 * include/grub/i386/pc/pci.h: Likewise.
12047
12048 * commands/lspci.c: Likewise.
12049
12050 * conf/i386-pc.rmk (pkglib_MODULES): Add `pci.mod' and
12051 `lspci.mod'.
12052 (pci_mod_SOURCES): New variable.
12053 (pci_mod_CFLAGS): Likewise.
12054 (pci_mod_LDFLAGS): Likewise.
12055 (lspci_mod_SOURCES): Likewise.
12056 (lspci_mod_CFLAGS): Likewise.
f19dbdb7 12057 (lspci_mod_LDFLAGS): Likewise.
58c69220 12058
c004e1b4 120592008-02-02 Bean <bean123ch@gmail.com>
12060
12061 * fs/ufs.c (INODE_BLKSZ): Fix incorrect value.
12062 (grub_ufs_get_file_block): Fix indirect block calculation problem.
12063
12064 * fs/xfs.c (grub_xfs_sblock): New member log2_dirblk.
12065 (grub_xfs_btree_node): New structure.
12066 (grub_xfs_btree_root): New structure.
12067 (grub_xfs_inode): New members nblocks, extsize, nextents and btree.
12068 (GRUB_XFS_EXTENT_OFFSET): Use exts instead of inode->data.extents.
12069 (GRUB_XFS_EXTENT_BLOCK): Likewise.
12070 (GRUB_XFS_EXTENT_SIZE): Likewise.
12071 (grub_xfs_read_block): Support btree format type.
12072 (grub_xfs_iterate_dir): Use NESTED_FUNC_ATTR in call_hook.
12073 Use directory block as basic unit.
12074
12075 * fs/fshelp.c (grub_fshelp_read_file): Bug fix for sparse block.
12076
12077 * aclocal.m4 (grub_i386_CHECK_REGPARM_BUG): Define NESTED_FUNC_ATTR as
12078 __attribute__ ((__regparm__ (1))).
12079
f95562bf 120802008-02-01 Robert Millan <rmh@aybabtu.com>
12081
12082 Correct a mistake in previous commit.
12083
12084 * conf/i386-pc.rmk (normal/execute.c_DEPENDENCIES): Move to the
12085 top.
12086 (normal/command.c_DEPENDENCIES): New variable.
12087
7d31f41f 120882008-02-01 Robert Millan <rmh@aybabtu.com>
12089
12090 * conf/i386-efi.rmk (normal/execute.c_DEPENDENCIES): Move to the
12091 top.
12092 (normal/command.c_DEPENDENCIES): New variable.
12093 (grub-emu_DEPENDENCIES, normal_mod_DEPENDENCIES): Remove variables.
12094 * conf/i386-ieee1275.rmk: Likewise.
12095 * conf/i386-linuxbios.rmk: Likewise.
12096 * conf/i386-pc.rmk: Likewise.
12097 * conf/sparc64-ieee1275.rmk: Likewise.
12098 * conf/powerpc-ieee1275.rmk: Likewise.
12099 (grub_emu_SOURCES): Add `fs/fshelp.c'.
12100
12101 * genmk.rb: Add `$(#{src}_DEPENDENCIES)' in targets that require it.
12102
60b6be74 121032008-02-01 Robert Millan <rmh@aybabtu.com>
12104
12105 * kern/disk.c (grub_disk_read, grub_disk_write): Add grub_dprintf()
12106 call at beginning of function.
12107
078522ab 121082008-01-31 Pavel Roskin <proski@gnu.org>
12109
12110 * util/powerpc/ieee1275/grub-mkrescue.in: New file.
d2c11005 12111 * conf/powerpc-ieee1275.rmk (bin_SCRIPTS): New variable.
12112 (grub_mkrescue_SOURCES): Likewise.
078522ab 12113 * DISTLIST: Add util/powerpc/ieee1275/grub-mkrescue.in.
12114
ccaa8a5f 121152008-01-30 Robert Millan <rmh@aybabtu.com>
12116
12117 * conf/i386-pc.rmk (sbin_UTILITIES): Remove `grub-probe'.
12118 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Moved from here ...
12119 * conf/common.rmk (util/grub-probe.c_DEPENDENCIES)
12120 (grub_probe_SOURCES): ... to here.
12121
12122 * conf/i386-efi.rmk (sbin_UTILITIES): Remove `grub-probe'.
12123 (util/grub-probe.c_DEPENDENCIES, grub_probe_SOURCES): Remove.
12124 * conf/i386-ieee1275.rmk: Likewise.
12125 * conf/i386-linuxbios.rmk: Likewise.
12126 * conf/powerpc-ieee1275.rmk: Likewise.
12127
ae5a9cd7 121282008-01-30 Tristan Gingold <gingold@free.fr>
12129
12130 * kern/rescue.c: Silently accept empty lines.
12131
70bc2ef2 121322008-01-29 Bean <bean123ch@gmail.com>
12133
12134 * boot/i386/pc/lnxboot.S (data_start): Code cleanup.
12135 (real_code_2): Code cleanup and change comment style.
12136 (move_memory): Avoid using 32-bit address mode.
12137
6a4d50ea 121382008-01-29 Bean <bean123ch@gmail.com>
12139
12140 * conf/i386-pc.rmk (pkglib_MODULES): Add `png.mod'.
12141 (png_mod_SOURCES): New variable.
12142 (png_mod_CFLAGS): Likewise.
12143 (png_mod_LDFLAGS): Likewise.
12144
12145 * video/readers/png.c: New file.
12146
11cc30ac 121472008-01-28 Robert Millan <rmh@aybabtu.com>
12148
12149 * include/grub/i386/linuxbios/kernel.h (GRUB_MOD_GAP): New macro.
12150 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Remove
12151 `ifndef GRUB_MOD_GAP' hack.
12152 * util/elf/grub-mkimage.c (add_segments): Likewise.
12153
3abc589f 121542008-01-27 Robert Millan <rmh@aybabtu.com>
12155
12156 * kern/powerpc/ieee1275/init.c (grub_arch_modules_addr): Skip
12157 `GRUB_MOD_GAP' for platforms in which it's not defined.
962ca133 12158 * util/elf/grub-mkimage.c (add_segments): Likewise.
3abc589f 12159
e1907778 121602008-01-27 Robert Millan <rmh@aybabtu.com>
12161
12162 Get grub-emu to build again (including parallel builds).
12163
12164 * conf/i386-pc.rmk (util/grub-emu.c_DEPENDENCIES): Remove variable.
12165 Split into ...
12166 (util/grub-emu.c_DEPENDENCIES): ... this, ...
12167 (normal/execute.c_DEPENDENCIES): ... this, ...
12168 (grub-emu_DEPENDENCIES): ... and this.
12169
12170 * conf/i386-efi.rmk: Likewise.
12171 * conf/i386-linuxbios.rmk: Likewise.
12172 * conf/i386-ieee1275.rmk: Likewise.
12173 * conf/powerpc-ieee1275.rmk: Likewise.
12174 (grub_emu_SOURCES): Remove duplicated `kern/file.c'.
12175
2216b101 121762008-01-27 Robert Millan <rmh@aybabtu.com>
12177
12178 * NEWS: Add a few items.
12179
f75172d9 121802008-01-27 Robert Millan <rmh@aybabtu.com>
12181
12182 Fix parallel builds with grub-emu. Based on earlier commit for
12183 grub-probe and grub-setup.
12184
12185 * conf/i386-pc.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12186 (util/grub-emu.c_DEPENDENCIES): ... this.
12187 * conf/i386-efi.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12188 (util/grub-emu.c_DEPENDENCIES): ... this.
12189 * conf/i386-linuxbios.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12190 (util/grub-emu.c_DEPENDENCIES): ... this.
12191 * conf/i386-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12192 (util/grub-emu.c_DEPENDENCIES): ... this.
12193 * conf/powerpc-ieee1275.rmk (grub-emu_DEPENDENCIES): Renamed to ...
12194 (util/grub-emu.c_DEPENDENCIES): ... this.
12195
3f51de77 121962008-01-27 Pavel Roskin <proski@gnu.org>
12197
12198 * include/grub/powerpc/ieee1275/kernel.h: Introduce GRUB_MOD_GAP
12199 to create a gap between _end and the modules added to the image
12200 with grub-mkrescue. That fixes "CLAIM failed" on PowerMAC.
12201 * kern/powerpc/ieee1275/init.c: Use GRUB_MOD_GAP.
12202 * util/elf/grub-mkimage.c (add_segments): Likewise.
12203
2033f53e 122042008-01-26 Pavel Roskin <proski@gnu.org>
12205
12206 * kern/dl.c (grub_dl_load): Don't abort if prefix is not set,
12207 just return an error.
12208
22da1f6f 122092008-01-26 Bean <bean123ch@gmail.com>
12210
12211 * fs/reiserfs.c (grub_fshelp_node): New member next_offset.
12212 (grub_reiserfs_get_item): Save offset of the next item.
12213 (grub_reiserfs_iterate_dir): Use next_offset to find next item.
12214
2a9525e6 122152008-01-25 Robert Millan <rmh@aybabtu.com>
12216
12217 * conf/i386-pc.rmk (grub_setup_SOURCES, grub_emu_SOURCES): Regroup to
12218 make all filesystem sources appear together (possibly fixing omissions
12219 while at it).
12220 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
12221 * conf/i386-ieee1275.rmk (grub_emu_SOURCES): Likewise.
12222 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
12223 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
12224
12225 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise. Additionally,
12226 add `kern/file.c'.
12227 * conf/i386-efi.rmk (grub_probe_SOURCES): Likewise.
12228 * conf/i386-ieee1275.rmk (grub_probe_SOURCES): Likewise.
12229 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Likewise.
12230 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Likewise.
12231
12232 * util/grub-probe.c: Include `<grub/file.h>' and `<sys/stat.h>'.
12233 (probe): Add a sanity check to make sure of our ability to read
12234 requested files when probing for filesystem type.
12235
12236 * genmk.rb: Update copyright year (2007).
12237
12238 * include/grub/fs.h (grub_fat_init, grub_fat_fini, grub_ext2_init)
12239 (grub_ext2_fini, grub_ufs_init, grub_ufs_fini, grub_minix_init)
12240 (grub_minix_fini, grub_hfs_init, grub_hfs_fini, grub_jfs_init)
12241 (grub_jfs_fini, grub_xfs_init, grub_xfs_fini, grub_affs_init)
12242 (grub_affs_fini, grub_sfs_init, grub_sfs_fini, grub_iso9660_init)
12243 : Remove function prototypes.
12244
b95f71b5 122452008-01-25 Robert Millan <rmh@aybabtu.com>
12246
12247 Revert my previous commits (based on wrong assumption of how grub_errno
12248 works).
12249
fe6b695a 12250 * kern/disk.c (grub_disk_open): Stop resetting grub_errno.
b95f71b5 12251 * kern/file.c (grub_file_open): Likewise.
12252
d08bbb49 122532008-01-24 Pavel Roskin <proski@gnu.org>
12254
12255 * include/grub/ieee1275/ieee1275.h: Introduce flag for firmwares
12256 that hang if GRUB tries to setup colors.
12257 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Don't set
12258 colors for firmwares that don't support it.
12259 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag):
12260 Recognize Open Hack'Ware, set flags to work around its
12261 limitations.
12262
605e36ed 122632008-01-24 Robert Millan <rmh@aybabtu.com>
12264
12265 * kern/file.c (grub_file_open): Do not account previous failures of
12266 unrelated functions when grub_errno is checked for.
12267 Reported by Oleg Strikov.
12268
bac332a1 122692008-01-24 Bean <bean123ch@gmail.com>
12270
12271 * fs/ufs.c (GRUB_UFS_VOLNAME_LEN): New macro.
12272 (grub_ufs_sblock): New member volume name.
12273 (grub_ufs_find_file): Fix string copy bug.
12274 (grub_ufs_label): Implement this function properly.
12275
12276 * fs/hfs.c (grub_hfs_cnid_type): New enum.
12277 (grub_hfs_iterate_records): Use the correct file number for extents
12278 and catalog file. Fix problem in next index calculation.
12279 (grub_hfs_find_node): Replace recursive function call with loop.
12280 (grub_hfs_iterate_dir): Replace recursive function call with loop.
12281
15c80c09 122822008-01-23 Robert Millan <rmh@aybabtu.com>
12283
12284 * include/grub/i386/ieee1275/loader.h: Include `<grub/types.h>',
12285 `<grub/symbol.h>' and `<grub/multiboot.h>'.
12286 (grub_multiboot2_real_boot): New function prototype.
12287
12288 * include/grub/i386/pc/memory.h: Include `<grub/machine/machine.h>'.
12289 [!GRUB_MACHINE_IEEE1275] (grub_lower_mem, grub_upper_mem): Disable.
12290
12291 * kern/i386/ieee1275/init.c (grub_os_area_addr)
12292 (grub_os_area_size, grub_lower_mem, grub_upper_mem): Remove variables.
12293
305338fd 122942008-01-23 Robert Millan <rmh@aybabtu.com>
12295
12296 * kern/mm.c (grub_mm_init_region): Replace grub_dprintf() call with
12297 #ifdef'ed out grub_printf().
12298
3ea52685 122992008-01-23 Robert Millan <rmh@aybabtu.com>
12300
12301 * term/i386/pc/at_keyboard.c (grub_keyboard_isr): #ifdef out
12302 grub_dprintf calls, since they make "debug=all" mode unusable.
12303 (grub_console_checkkey): Likewise.
12304
5882ae4b 123052008-01-23 Robert Millan <rmh@aybabtu.com>
12306
12307 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add
12308 `term/i386/pc/at_keyboard.c'.
12309 (pkglib_MODULES): Add `serial.mod'.
12310 (serial_mod_SOURCES): New variable.
12311 (serial_mod_CFLAGS): Likewise.
12312 (serial_mod_LDFLAGS): Likewise.
12313
12314 * include/grub/i386/ieee1275/console.h: Add `<grub/symbol.h>'. Remove
12315 `<grub/powerpc/ieee1275/console.h>'.
12316 (grub_keyboard_controller_init): New function prototype.
12317 (grub_console_checkkey): Likewise.
12318 (grub_console_getkey): Likewise.
12319
12320 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize AT
12321 keyboard on i386.
12322
12323 * term/ieee1275/ofconsole.c (grub_ofconsole_term): On i386, use
12324 grub_ofconsole_checkkey() and grub_ofconsole_getkey() for input.
12325
06ab5303 123262008-01-23 Robert Millan <rmh@aybabtu.com>
12327
12328 * kern/i386/pc/init.c (make_install_device): When memdisk image is
12329 present, "(memdisk)/boot/grub" becomes the default prefix.
12330
12331 * util/i386/pc/grub-mkrescue.in: Switch to a minimal core.img plus
12332 a memdisk tarball with all the modules. Add --overlay=DIR option that
12333 allows users to overlay additional files into the image.
12334
dbb475a4 123352008-01-23 Robert Millan <rmh@aybabtu.com>
12336
12337 * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Add `machine/loader.h'
12338 and `machine/memory.h'.
12339 (pkglib_MODULES): Add `multiboot.mod' and `_multiboot.mod'.
12340 (_multiboot_mod_SOURCES): New variable.
12341 (_multiboot_mod_CFLAGS): Likewise.
12342 (_multiboot_mod_LDFLAGS): Likewise.
12343 (multiboot_mod_SOURCES): Likewise.
12344 (multiboot_mod_CFLAGS): Likewise.
12345 (multiboot_mod_LDFLAGS): Likewise.
12346
12347 * include/grub/i386/ieee1275/loader.h: New file.
12348
12349 * include/grub/i386/ieee1275/machine.h: Likewise.
12350
12351 * include/grub/i386/ieee1275/memory.h: Likewise.
12352
12353 * include/grub/i386/pc/init.h (grub_os_area_addr): Remove (redundant)
12354 variable declaration.
12355 (grub_os_area_size): Likewise.
12356
12357 * kern/i386/ieee1275/init.c (grub_os_area_addr, grub_os_area_size)
12358 (grub_lower_mem, grub_upper_mem): New variables.
12359 (grub_stop_floppy): New function (just to make
12360 grub_multiboot2_real_boot() happy).
12361
12362 * kern/i386/ieee1275/startup.S: Include `<grub/machine/memory.h>',
12363 `<grub/cpu/linux.h>', `<multiboot.h>' and `<multiboot2.h>'.
12364 (grub_stop): New function.
12365 Include `"../realmode.S"' and `"../loader.S"'.
12366
12367 * loader/multiboot_loader.c: Include `<grub/machine/machine.h>'.
12368 Replace `__i386__' #ifdefs with `GRUB_MACHINE_PCBIOS'.
12369
12370 * loader/powerpc/ieee1275/multiboot2.c (grub_mb2_arch_boot): On i386,
12371 rely on grub_multiboot2_real_boot() for final boot.
12372
25638629 123732008-01-22 Robert Millan <rmh@aybabtu.com>
12374
12375 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): When
12376 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag is set, skip any
12377 device that doesn't look like an SD card.
12378 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
12379 `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' flag.
12380 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_set_flag): Detect
12381 OLPC laptop, and set `GRUB_IEEE1275_FLAG_OFDISK_SDCARD_ONLY' when
12382 found.
12383
9dad816d 123842008-01-22 Robert Millan <rmh@aybabtu.com>
12385
12386 * kern/powerpc/ieee1275/init.c (grub_claim_heap): Add sanity check to
12387 avoid claiming over our own code.
12388
34842f2d 123892008-01-22 Bean <bean123ch@gmail.com>
12390
12391 * conf/i386-pc.rmk (pkglib_MODULES): Add `jpeg.mod'.
12392 (jpeg_mod_SOURCES): New variable.
12393 (jpeg_mod_CFLAGS): Likewise.
12394 (jpeg_mod_LDFLAGS): Likewise.
12395
12396 * video/readers/jpeg.c : New file.
12397
44023a28 123982008-01-22 Bean <bean123ch@gmail.com>
12399
12400 * fs/cpio.c (grub_cpio_find_file): Return GRUB_ERR_FILE_NOT_FOUND when
12401 there are no more items.
12402
bc2d8ac6 124032008-01-21 Robert Millan <rmh@aybabtu.com>
12404
12405 * kern/mm.c (grub_mm_init_region): Improve debug message.
12406
261bd4bc 124072008-01-21 Robert Millan <rmh@aybabtu.com>
12408
12409 * conf/i386-pc.rmk (GRUB_MEMORY_MACHINE_LINK_ADDR): New variable.
12410 (kernel_img_LDFLAGS): Use `GRUB_MEMORY_MACHINE_LINK_ADDR' as link
12411 address.
12412 (grub_mkimage_CFLAGS): Propagate `GRUB_MEMORY_MACHINE_LINK_ADDR' as
12413 a C macro.
12414 * include/grub/i386/pc/memory.h (GRUB_MEMORY_MACHINE_UPPER): New macro.
12415 Indicates start of upper memory.
12416 * util/i386/pc/grub-mkimage.c: Include `<grub/machine/memory.h>'.
12417 (generate_image): Abort when image size is big enough to corrupt
12418 upper memory.
12419
12420 * include/grub/i386/pc/vga.h: Include `<grub/machine/memory.h>'.
12421 (GRUB_MEMORY_MACHINE_VGA_ADDR): Alias for `GRUB_MEMORY_MACHINE_UPPER'.
12422 * term/i386/pc/vga.c (VGA_MEM): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
12423 instead of hardcoding 0xA0000.
12424 * video/i386/pc/vbe.c: Include `<grub/machine/vga.h>'.
12425 (grub_vbe_set_video_mode): Use `GRUB_MEMORY_MACHINE_VGA_ADDR'
12426 instead of hardcoding 0xA0000.
12427
f970b55e 124282008-01-21 Robert Millan <rmh@aybabtu.com>
12429
12430 * disk/memdisk.c (memdisk_size): New variable.
12431 (grub_memdisk_open): Replace grub_arch_memdisk_size() call with
12432 `memdisk_size'.
12433 (grub_memdisk_init): Initialize `memdisk_size'. Reallocate memdisk
12434 image to dynamic memory.
12435 (grub_memdisk_fini): Replace grub_arch_memdisk_size() call with
12436 `memdisk_size'. Free memdisk block.
12437
1a8b0526 124382008-01-21 Robert Millan <rmh@aybabtu.com>
12439
12440 Fix detection of very small filesystems (like tar).
12441
12442 * fs/reiserfs.c (grub_reiserfs_mount): When disk is too small to
12443 contain a ReiserFS, abort with GRUB_ERR_BAD_FS rather than
12444 GRUB_ERR_OUT_OF_RANGE (which made the upper layer think there's
12445 a problem with this disk).
12446
6e9b4aab 124472008-01-21 Robert Millan <rmh@aybabtu.com>
12448
12449 * disk/i386/pc/biosdisk.c (grub_biosdisk_iterate): Add debug message
12450 on grub_biosdisk_rw_standard() error.
12451
0d8837b2 124522008-01-21 Robert Millan <rmh@aybabtu.com>
12453
12454 * include/grub/ieee1275/ieee1275.h: Add 2008 to Copyright line for
12455 recent changes.
12456 * kern/elf.c: Likewise.
12457 * kern/ieee1275/ieee1275.c: Likewise.
12458 * kern/powerpc/ieee1275/openfw.c: Likewise.
12459 * term/ieee1275/ofconsole.c: Likewise.
12460
ffd36e34 124612008-01-21 Robert Millan <rmh@aybabtu.com>
12462
12463 * include/grub/i386/pc/kernel.h: Include `<grub/symbol.h>'.
12464
3f0093d0 12465 * include/grub/kernel.h (grub_arch_memdisk_addr)
12466 (grub_arch_memdisk_size): Moved from here ...
ffd36e34 12467
3f0093d0 12468 * include/grub/i386/pc/kernel.h (grub_arch_memdisk_addr)
12469 (grub_arch_memdisk_size): ... to here.
ffd36e34 12470
6c391b21 124712008-01-21 Robert Millan <rmh@aybabtu.com>
12472
12473 Mostly based on bugfix from Bean.
12474
12475 * kern/elf.c (grub_elf32_phdr_iterate): Use `NESTED_FUNC_ATTR'
12476 attribute with hook() parameter.
12477 (grub_elf32_load): Use `NESTED_FUNC_ATTR' with grub_elf32_load_segment()
12478 declaration.
12479 (grub_elf64_phdr_iterate): Use `NESTED_FUNC_ATTR'
12480 attribute with hook() parameter.
12481 (grub_elf64_load): Use `NESTED_FUNC_ATTR' with grub_elf64_load_segment()
12482 declaration.
12483
55a581dc 124842008-01-21 Robert Millan <rmh@aybabtu.com>
12485
12486 * conf/i386-pc.rmk (kernel_img_HEADERS): Add `machine/kernel.h'.
12487 (pkglib_MODULES): Add `memdisk.mod'.
12488 (memdisk_mod_SOURCES): New variable.
12489 (memdisk_mod_CFLAGS): Likewise.
12490 (memdisk_mod_LDFLAGS): Likewise.
12491
12492 * disk/memdisk.c: New file.
12493
12494 * include/grub/disk.h (grub_disk_dev_id): Add
12495 `GRUB_DISK_DEVICE_MEMDISK_ID'.
12496
12497 * include/grub/i386/pc/kernel.h
12498 (GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE): New macro.
12499 (GRUB_KERNEL_MACHINE_PREFIX): Increment by 4.
12500 (grub_kernel_image_size): New variable declaration.
12501 (grub_total_module_size): Likewise.
12502 (grub_memdisk_image_size): Likewise.
12503
12504 * include/grub/i386/pc/memory.h
12505 (GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR): New macro.
12506
12507 * include/grub/kernel.h: Include `<grub/symbol.h>'.
12508 (grub_arch_memdisk_addr): New variable declaration.
12509 (grub_arch_memdisk_size): Likewise.
12510
12511 * kern/i386/pc/init.c (grub_arch_memdisk_addr): New function.
12512 (grub_arch_memdisk_size): Likewise.
12513
12514 * kern/i386/pc/startup.S (grub_memdisk_image_size): New variable.
12515 (codestart): Replace hardcoded `0x100000' with
12516 `GRUB_MEMORY_MACHINE_DECOMPRESSION_ADDR' macro.
12517
12518 * util/i386/pc/grub-mkimage.c: Include `<grub/misc.h>'.
12519 (generate_image): Add `memdisk_path' parameter. When `memdisk_path' is
12520 not NULL, append the contents of the file it refers to, at the end of
12521 the compressed kernel image. Initialize `grub_memdisk_image_size'
12522 variable (at `GRUB_KERNEL_MACHINE_MEMDISK_IMAGE_SIZE' offset).
12523 (options): Add "memdisk"|'m' option.
12524 (main): Parse --memdisk|-m option, and pass user-provided path as
12525 parameter to generate_image().
12526
3d7f54c9 125272008-01-20 Robert Millan <rmh@aybabtu.com>
12528
12529 * kern/sparc64/ieee1275/openfw.c (grub_devalias_iterate): Copy debug
12530 grub_dprintf() calls from here ...
12531 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): ... to here.
12532
0bf74728 125332008-01-20 Robert Millan <rmh@aybabtu.com>
12534
12535 Fix detection of "real mode" when /options/real-mode? doesn't exist.
12536
12537 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_mmu): New variable
12538 declaration.
12539 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_mmu): New variable.
12540 (grub_ieee1275_find_options): If `grub_ieee1275_mmu' is 0, set
12541 `GRUB_IEEE1275_FLAG_REAL_MODE'.
fe6b695a 12542 (cmain): Initialize `grub_ieee1275_mmu' (using /chosen/mmu integer
0bf74728 12543 property).
12544 * kern/powerpc/ieee1275/openfw.c (grub_map): Rely on pre-initialized
12545 `grub_ieee1275_mmu' rather than obtaining a handler on every call.
12546
33bf70a7 125472008-01-19 Robert Millan <rmh@aybabtu.com>
12548
fe6b695a 12549 Get rid of confusing function (superseded by
33bf70a7 12550 `grub_ieee1275_get_integer_property')
12551 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_decode_int_4): Remove
12552 prototype.
12553 * kern/ieee1275/ieee1275.c (grub_ieee1275_decode_int_4): Remove
12554 function.
12555 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid use of
12556 grub_ieee1275_decode_int_4(), by obtaining integer properties directly
fe987087 12557 in native endianness from grub_ieee1275_get_integer_property().
33bf70a7 12558
e2da7d26 125592008-01-19 Robert Millan <rmh@aybabtu.com>
12560
12561 * kern/powerpc/ieee1275/openfw.c (grub_halt): Issue "power-off"
12562 command after "shut-down", since implementations differ on which
12563 the command for halt is.
12564
59f1fd8d 125652008-01-19 Robert Millan <rmh@aybabtu.com>
12566
12567 * include/grub/i386/linuxbios/console.h: Add header protection.
12568 (grub_keyboard_controller_init): New function prototype.
12569 * term/i386/pc/at_keyboard.c (KEYBOARD_COMMAND_ISREADY): New macro.
12570 (KEYBOARD_COMMAND_READ): Likewise.
12571 (KEYBOARD_COMMAND_WRITE): Likewise.
12572 (KEYBOARD_SCANCODE_SET1): Likewise.
12573 (grub_keyboard_controller_write): New function.
12574 (grub_keyboard_controller_read): Likewise.
12575 (grub_keyboard_controller_init): Likewise.
12576
12577 * term/i386/pc/console.c: Include `<grub/machine/machine.h>'.
12578 (grub_console_init): On coreboot/LinuxBIOS, call
12579 grub_keyboard_controller_init().
12580
5f5a7c15 125812008-01-19 Robert Millan <rmh@aybabtu.com>
12582
12583 PowerPC changes provided by Pavel Roskin.
12584
12585 * kern/powerpc/ieee1275/cmain.c (cmain): Don't take any arguments.
12586 * kern/powerpc/ieee1275/crt0.S: Store r5 in grub_ieee1275_entry_fn,
12587 don't rely on cmain() doing it.
12588 * kern/i386/ieee1275/startup.S (_start): Store %eax in
12589 grub_ieee1275_entry_fn, don't rely on cmain() doing it.
12590
1210e168 125912008-01-16 Robert Millan <rmh@aybabtu.com>
12592
12593 * include/grub/i386/linuxbios/memory.h
12594 (GRUB_MEMORY_MACHINE_LINUXBIOS_TABLE_ADDR): Remove macro.
12595 * kern/i386/linuxbios/table.c (grub_linuxbios_table_iterate): Do not
12596 receive `table_header' as argument. Instead, probe for it in the
12597 known memory ranges where it can be present.
12598 (grub_available_iterate): Do not pass a fixed `table_header' address
12599 to grub_linuxbios_table_iterate().
12600
3d04eab8 126012008-01-15 Robert Millan <rmh@aybabtu.com>
12602
12603 * configure.ac: Add `i386-ieee1275' to the list of supported targets.
12604 * conf/i386-ieee1275.rmk: New file.
12605 * include/grub/i386/ieee1275/console.h: Likewise.
12606 * include/grub/i386/ieee1275/ieee1275.h: Likewise.
12607 * include/grub/i386/ieee1275/kernel.h: Likewise.
12608 * include/grub/i386/ieee1275/time.h: Likewise.
12609 * kern/i386/ieee1275/init.c: Likewise.
12610 * kern/i386/ieee1275/startup.S: Likewise.
12611
d1bc1b73 126122008-01-15 Robert Millan <rmh@aybabtu.com>
12613
12614 * kern/misc.c (grub_vsprintf): Do not reset `longlongfmt' to zero
12615 when pointers are 32-bit (but still do set it to one when they are
12616 64-bit).
12617
66a65807 126182008-01-15 Robert Millan <rmh@aybabtu.com>
12619
12620 * include/grub/ieee1275/ieee1275.h
12621 (grub_ieee1275_get_integer_property): New function prototype.
12622
12623 * kern/ieee1275/ieee1275.c: Include `<grub/types.h>'.
12624 (grub_ieee1275_get_integer_property): New function. Wraps around
fe987087 12625 grub_ieee1275_get_property() to handle endianness.
66a65807 12626
12627 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Replace
12628 grub_ieee1275_get_property() with grub_ieee1275_get_integer_property()
fe6b695a 12629 where appropriate.
66a65807 12630 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Likewise.
12631 (grub_map): Likewise.
12632 * kern/sparc64/ieee1275/openfw.c (grub_map): Likewise.
12633
a83ccafd 126342008-01-15 Bean <bean123ch@gmail.com>
12635
12636 * normal/execute.c (grub_script_exec_argument_to_string): Check for undefined variable.
12637 (grub_script_execute_cmdline): Reset grub_errno.
12638
12639 * normal/main.c (read_config_file): Reset grub_errno.
12640
12641 * normal/parse.y (script_init): New.
12642 (script): Move function and menuentry here.
12643 (delimiter): New.
12644 (command): Add delimiter at the end of command.
12645 (commands): Adjust to match the new command.
12646 (commandblock): Remove grub_script_lexer_record_start.
f19dbdb7 12647 (menuentry): Add grub_script_lexer_record_start, use the new commands.
a83ccafd 12648 (if): Use the new commands.
12649
12650 * conf/common.rmk (pkgdata_MODULES): Add echo.mod.
12651
df6ecfc6 126522008-01-15 Robert Millan <rmh@aybabtu.com>
12653
12654 * normal/menu.c (run_menu): Move timeout message from here ...
12655 (print_timeout): ... to here.
12656 (run_menu): Use print_timeout() once during initial draw to print
12657 the whole message, and again in every clock tick to update only
12658 the number of seconds.
12659
87ae25eb 126602008-01-15 Robert Millan <rmh@aybabtu.com>
12661
12662 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Obtain
12663 actual size of `available' from grub_ieee1275_get_property(), and
12664 restrict parsing to that bound.
12665
47bf09a4 126662008-01-15 Christian Franke <franke@computer.org>
12667
12668 * util/grub-emu.c: Replace <argp.h> by <getopt.h>.
12669 (argp_program_version): Remove variable.
12670 (argp_program_bug_address): Likewise.
12671 (options): Convert from struct argp_option to struct option.
12672 (struct arguments): Remove.
12673 (parse_opt): Remove.
12674 (usage): New function.
12675 (main): Replace struct args members by simple variables.
12676 Replace argp_parse() by getopt_long().
12677 Add switch to evaluate options.
12678 Add missing "(...)" around root_dev in prefix string.
12679
c86f1469 126802008-01-14 Robert Millan <rmh@aybabtu.com>
12681
12682 * kern/powerpc/ieee1275/init.c (grub_exit): Reimplement as a wrapper
12683 for grub_ieee1275_exit(), in order to improve portability.
12684
e622c559 126852008-01-14 Robert Millan <rmh@aybabtu.com>
12686
12687 * util/grub.d/10_linux.in (prefix): Define.
12688 (exec_prefix): Likewise. Both definitions are later used by `libdir'.
12689
44cb1ec8 126902008-01-13 Pavel Roskin <proski@gnu.org>
12691
12692 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Don't use
12693 grub_errno if no errors have been detected.
12694
1eb8c802 126952008-01-12 Robert Millan <rmh@aybabtu.com>
12696
12697 * include/grub/util/getroot.h (grub_dev_abstraction_types): New enum.
12698 (grub_util_get_dev_abstraction): New function prototype.
12699
12700 * util/getroot.c: Include `<grub/util/getroot.h>'
12701 (grub_util_get_grub_dev): Move detection of abstraction type to ...
12702 (grub_util_get_dev_abstraction): ... here (new function).
12703
12704 * util/grub-probe.c: Convert PRINT_* to an enum. Add
12705 `PRINT_ABSTRACTION'.
12706 (probe): Probe for abstraction type when requested.
12707 (main): Understand `--target=abstraction'.
12708
12709 * util/i386/efi/grub-install.in: Add abstraction module to core
12710 image when it is found to be necessary.
12711 * util/i386/pc/grub-install.in: Likewise.
12712 * util/powerpc/ieee1275/grub-install.in: Likewise.
12713
12714 * util/update-grub_lib.in (font_path): Return system path without
12715 converting to GRUB path.
12716 * util/update-grub.in: Convert system path returned by font_path()
12717 to a GRUB path. Use `grub-probe -t abstraction' to determine what
12718 abstraction module is needed for loading fonts (if any). Export
12719 that as `GRUB_PRELOAD_MODULES'.
12720 * util/grub.d/00_header.in: Process `GRUB_PRELOAD_MODULES' (print
12721 insmod commands).
12722
52bd3de9 127232008-01-12 Yoshinori K. Okuji <okuji@enbug.org>
12724
12725 Remove some unused code from reiserfs.
f19dbdb7 12726
52bd3de9 12727 * fs/reiserfs.c (struct grub_reiserfs_key)
12728 [GRUB_REISERFS_KEYV2_BITFIELD]: Removed offset and type.
12729 (struct grub_reiserfs_node_body): Removed.
12730 (grub_reiserfs_get_key_v2_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
12731 Likewise.
12732 (grub_reiserfs_get_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
12733 Likewise.
12734 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
12735 Likewise.
12736 (grub_reiserfs_set_key_offset) [GRUB_REISERFS_KEYV2_BITFIELD]:
12737 Likewise.
12738 (grub_reiserfs_set_key_type) [GRUB_REISERFS_KEYV2_BITFIELD]:
12739 Likewise.
12740 (grub_reiserfs_iterate_dir) [GRUB_REISERFS_KEYV2_BITFIELD]:
12741 Likewise.
12742 (grub_reiserfs_open) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
12743 (grub_reiserfs_read) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
12744 (grub_reiserfs_dir) [GRUB_REISERFS_KEYV2_BITFIELD]: Likewise.
12745
2f80039d 127462008-01-10 Robert Millan <rmh@aybabtu.com>
12747
12748 * util/update-grub_lib.in (grub_file_is_not_garbage): New function.
12749 Determines if a file is garbage left by packaging systems, etc.
12750 * util/update-grub.in: Use grub_file_is_not_garbage() as a condition
12751 for processing /etc/grub.d scripts.
12752 * util/grub.d/10_hurd.in: Fix `GRUB_DISTRIBUTOR' comparison.
12753 * util/grub.d/10_linux.in: Likewise. Use grub_file_is_not_garbage()
12754 as a condition for processing Linux images.
12755
87888032 127562008-01-10 Pavel Roskin <proski@gnu.org>
12757
12758 * include/grub/powerpc/libgcc.h (__ucmpdi2): New export. Needed
12759 to compile reiserfs.c on PowerPC.
12760
7e54fced 127612008-01-10 Robert Millan <rmh@aybabtu.com>
de9993e0 12762
12763 * kern/device.c (grub_device_iterate): Do not abort device iteration
12764 when one of the devices cannot be opened.
12765 * kern/disk.c (grub_disk_open): Do not account previous failures of
12766 unrelated functions when grub_errno is checked for.
12767
5aa541e6 127682008-01-08 Robert Millan <rmh@aybabtu.com>
12769
12770 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): For
12771 `! grub_linux_is_bzimage', change order of address comparison to make
12772 it more intuitive, and improve "too big zImage" error message.
12773
7076340d 127742008-01-08 Robert Millan <rmh@aybabtu.com>
12775
12776 * Makefile.in (uninstall): Handle `$(update-grub_SCRIPTS)' and
12777 `$(update-grub_DATA)'.
12778 (distcheck): Fix race condition when invoking `$(MAKE)' on multiple
12779 targets.
12780
9ca70333 127812008-01-07 Robert Millan <rmh@aybabtu.com>
12782
12783 * boot/i386/pc/boot.S (boot_drive_check): Add a comment indicating
12784 which instruction is modified by grub-setup during installation
12785 (since it wasn't obvious by only looking at this file).
12786
38ccf575 127872008-01-07 Robert Millan <rmh@aybabtu.com>
12788
12789 * TODO: Rewrite. Just refer to the wiki and the BTS instead of
12790 listing actual TODO items.
12791
f5db4291 127922008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
12793
868967cf 12794 * fs/reiserfs.c (grub_reiserfs_get_key_v2_type): Handle endianness
12795 correctly.
12796 (grub_reiserfs_get_key_offset): Likewise.
12797 (grub_reiserfs_set_key_offset): Likewise.
12798 (grub_reiserfs_set_key_type): Likewise.
fe6b695a 12799 (grub_reiserfs_iterate_dir): Return 1 if found, otherwise 0.
868967cf 12800
12801 (GRUB_REISERFS_KEYV2_BITFIELD): Undefined. Probably it would be
12802 better to remove the bitfield version completely.
f19dbdb7 12803
868967cf 128042008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
f19dbdb7 12805
f5db4291 12806 * fs/reiserfs.c (grub_reiserfs_iterate_dir): ENTRY_ITEM must be
12807 allocated from the heap, due to the fshelp implementation.
12808 (grub_reiserfs_dir): Free NODE, due to the same reason.
12809
492e6d9d 128102008-01-06 Yoshinori K. Okuji <okuji@enbug.org>
12811
12812 Mostly from Vincent Pelletier:
f19dbdb7 12813
492e6d9d 12814 * fs/reiserfs.c: New file.
f19dbdb7 12815
492e6d9d 12816 * conf/common.rmk (pkglib_MODULES): Added reiserfs.mod.
12817 (reiserfs_mod_SOURCES): New variable.
12818 (reiserfs_mod_CFLAGS): Likewise.
12819 (reiserfs_mod_LDFLAGS): Likewise.
12820
12821 * DISTLIST: Added boot/i386/pc/lnxboot.S, commands/hexdump.c,
12822 disk/ata.c, fs/cpio.c, fs/ntfscomp.c, fs/reiserfs.c,
12823 include/grub/ntfs.h, include/grub/i386/pc/machine.h, and
12824 normal/color.c.
12825
9ce3e7c1 128262008-01-06 Robert Millan <rmh@aybabtu.com>
12827
12828 * normal/color.c: Remove `<grub/env.h>'.
12829
f3b58148 128302008-01-05 Jeroen Dekkers <jeroen@dekkers.cx>
12831
12832 * include/grub/normal.h: Include <grub/env.h>.
12833
7ac3bcfa 128342008-01-05 Robert Millan <rmh@aybabtu.com>
12835
12836 * util/i386/pc/grub-setup.c (usage): Replace obsolete `(hd0,0)' in
12837 usage example with `(hd0,1)'.
fb358190 12838 Reported by Samuel Thibault.
7ac3bcfa 12839
c8ee99d7 128402008-01-05 Robert Millan <rmh@aybabtu.com>
12841
12842 * kern/i386/loader.S (grub_linux_is_bzimage): New variable.
12843 (grub_linux_boot_zimage): Rename to ...
12844 (grub_linux_boot): ... this.
12845 (grub_linux_boot_bzimage): Merge with `grub_linux_boot_zimage'.
12846 (grub_linux_boot_zimage): Conditionalize zImage copy.
12847
12848 * include/grub/i386/loader.h (grub_linux_is_bzimage): Add prototype.
12849 (grub_linux_boot_bzimage): Remove prototype.
12850 (grub_linux_boot_zimage): Rename to ...
12851 (grub_linux_boot): ... this.
12852
12853 * loader/i386/pc/linux.c (big_linux): Replace with `grub_linux_is_bzimage'.
12854 (grub_linux_boot): Remove function.
12855
0ece25b1 128562008-01-05 Robert Millan <rmh@aybabtu.com>
12857
12858 * include/grub/normal.h (grub_env_write_color_normal): New prototype.
12859 (grub_env_write_color_highlight): Likewise.
12860 (grub_wait_after_message): Likewise.
12861
12862 * normal/color.c: New file.
12863
12864 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `normal/color.c'.
12865 (normal_mod_DEPENDENCIES): Likewise.
12866
12867 * conf/i386-efi.rmk (grub_emu_SOURCES): Add `normal/color.c'.
12868 (normal_mod_DEPENDENCIES): Likewise.
12869
12870 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add `normal/color.c'.
12871 (normal_mod_DEPENDENCIES): Likewise.
12872
12873 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `normal/color.c'.
12874 (normal_mod_DEPENDENCIES): Likewise.
12875
12876 * normal/menu_entry.c (run): Rely on grub_wait_after_message()
12877 for waiting after a message is printed.
12878 * normal/main.c (read_config_file): Likewise.
12879 (grub_normal_init): Register grub_env_write_color_normal() and
12880 grub_env_write_color_highlight() hooks. Mark `color_normal' and
12881 `color_highlight' variables as global.
12882
12883 * normal/menu.c (grub_wait_after_message): New function.
12884 (grub_color_menu_normal): New variable. Replaces ...
12885 (GRUB_COLOR_MENU_NORMAL): ... this macro.
12886 (grub_color_menu_highlight): New variable. Replaces ...
12887 (GRUB_COLOR_MENU_HIGHLIGHT): ... this macro.
12888 (draw_border): Set color state to `GRUB_TERM_COLOR_NORMAL' instead of
12889 `GRUB_TERM_COLOR_STANDARD'.
12890 (print_message): Use `grub_setcolorstate' to reload colors. Rename
12891 `normal_code' and `highlight_code' to `old_color_normal' and
12892 `old_color_highlight', respectively.
12893 (grub_menu_init_page): Update colors when drawing the menu, based on
12894 `menu_color_normal' and `menu_color_highlight' variables.
12895 (grub_menu_run): Rely on grub_wait_after_message() for waiting after
12896 a message is printed.
12897
182dd4e5 128982008-01-05 Robert Millan <rmh@aybabtu.com>
12899
12900 * kern/env.c (grub_env_context_open): Propagate hooks for global
12901 variables to new context.
12902
12903 * kern/main.c (grub_set_root_dev): Export `root' variable.
12904
ddf8f6ad 129052008-01-05 Robert Millan <rmh@aybabtu.com>
12906
12907 * util/biosdisk.c (get_os_disk): Check for devfs-style IDE and SCSI
fe6b695a 12908 discs unconditionally, since udev and others have options to provide
ddf8f6ad 12909 them.
12910
d8b43d9b 129112008-01-05 Robert Millan <rmh@aybabtu.com>
12912
12913 * normal/completion.c (iterate_dir): Skip `.' and `..' directories.
12914
2bff2de3 129152008-01-04 Christian Franke <franke@computer.org>
12916
12917 * kern/i386/pc/init.c (grub_machine_init): Fix evaluation
12918 of eisa_mmap.
12919
97eab917 129202008-01-03 Pavel Roskin <proski@gnu.org>
12921
12922 * kern/i386/linuxbios/init.c: Put "void" to all function
12923 declarations with no arguments.
12924 * kern/powerpc/ieee1275/init.c: Likewise.
12925 * term/i386/pc/at_keyboard.c: Likewise.
12926 * term/i386/pc/vga_text.c: Likewise.
12927 * util/grub-mkdevicemap.c: Likewise.
12928
b9416d00 129292008-01-02 Robert Millan <rmh@aybabtu.com>
12930
12931 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf32): Improve error
12932 message when loaded image is out of bounds.
12933 (grub_multiboot_load_elf64): Likewise.
12934
92695df9 129352008-01-02 Pavel Roskin <proski@gnu.org>
12936
12937 * util/grub.d/10_linux.in: Try version without ".old" when
12938 looking for initrd. It's better to use initrd from the newer
12939 kernel of the same version than no initrd at all.
12940
d98d9cad 129412008-01-01 Robert Millan <rmh@aybabtu.com>
12942
12943 * util/biosdisk.c (get_os_disk): Fix check for IDE or SCSI discs.
12944
dbfdce36 129452008-01-01 Vesa Jaaskelainen <chaac@nic.fi>
12946
f19dbdb7 12947 * include/grub/video.h: Added grub_video_unmap_color and
dbfdce36 12948 grub_video_get_active_render_target.
12949 (grub_video_adapter): Added unmap_color and get_active_render_target.
12950
f19dbdb7 12951 * video/video.c: Added grub_video_unmap_color and
dbfdce36 12952 grub_video_get_active_render_target.
12953 (grub_video_get_info): Changed method to accept NULL pointer as an
12954 argument to allow detection of active video adapter.
12955
12956 * video/i386/pc/vbe.c: Renamed grub_video_vbe_unmap_color as
12957 grub_video_vbe_unmap_color_int.
12958 Added grub_video_vbe_unmap_color and
12959 grub_video_vbe_get_active_render_target.
12960 (grub_video_vbe_adapter): Added unmap_color and
12961 get_active_render_target.
12962
f19dbdb7 12963 * video/i386/pc/vbeblit.c: Replaced grub_video_vbe_unmap_color usage
dbfdce36 12964 with grub_video_vbe_unmap_color_int.
12965
12966 * term/gfxterm.c (DEFAULT_STANDARD_COLOR): Added.
12967 (DEFAULT_NORMAL_COLOR): Likewise.
12968 (DEFAULT_HIGHLIGHT_COLOR) Likewise.
12969 (DEFAULT_FG_COLOR): Removed.
12970 (DEFAULT_BG_COLOR): Likewise.
12971 (DEFAULT_CURSOR_COLOR): Changed value.
12972 (grub_virtual_screen): Added standard_color_setting,
12973 normal_color_setting, highlight_color_setting and term_color.
12974 (grub_virtual_screen): Removed fg_color_setting and bg_color_setting.
12975 (bitmap_width): Added.
12976 (bitmap_height): Likewise.
12977 (bitmap): Likewise.
12978 (set_term_color): Likewise.
12979 (grub_virtual_screen_setup): Changed to use new terminal coloring
12980 settings.
12981 (grub_gfxterm_init): Added init for bitmap.
12982 (grub_gfxterm_fini): Added destroy for bitmap.
12983 (redraw_screen_rect): Updated to use background bitmap and new
12984 terminal coloring.
12985 (scroll_up): Added optimization for case when there is no bitmap.
12986 (grub_gfxterm_cls): Fixed to use correct background color.
12987 (grub_virtual_screen_setcolorstate): Changed to use new terminal
12988 coloring.
12989 (grub_virtual_screen_setcolor): Likewise.
12990 (grub_virtual_screen_getcolor): Added.
12991 (grub_gfxterm_background_image_cmd): Likewise.
12992 (grub_video_term): Added setcolor and getcolor.
12993 (MOD_INIT): Added registration of background_image command.
12994 (MOD_TERM): Added unregistration for background_image command.
12995
c3c20931 129962007-12-30 Pavel Roskin <proski@gnu.org>
12997
12998 * loader/multiboot_loader.c: Fix multiboot command
12999 unregistration. Fix all typos in the word "multiboot".
13000
df266716 130012007-12-29 Pavel Roskin <proski@gnu.org>
94239199 13002
13003 * util/grub.d/10_linux.in: Refactor search for initrd. Add
13004 support for initrd names used in Fedora.
13005
fc6e896c 130062007-12-26 Bean <bean123ch@gmail.com>
13007
13008 * conf/common.rmk (pkgdata_MODULES): Add cpio.mod.
13009 (cpio_mod_SOURCES): New variable.
13010 (cpio_mod_CFLAGS): Likewise.
13011 (cpio_mod_LDFLAGS): Likewise.
13012
13013 * fs/cpio.c: New file.
13014
13015 * conf/i386-pc.rmk (grub_emu_SOURCES): Add cpio.c.
13016
13017 * conf/i386-efi.rmk (grub_emu_SOURCES): Likewise.
13018
13019 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Likewise.
13020
13021 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
13022
533110ad 130232007-12-25 Robert Millan <rmh@aybabtu.com>
13024
13025 * include/grub/term.h (struct grub_term): Add `getcolor' function.
13026 (grub_getcolor): New function.
13027
13028 * kern/term.c (grub_getcolor): New function.
13029 * normal/menu.c (GRUB_COLOR_MENU_NORMAL): New macro.
13030 (GRUB_COLOR_MENU_HIGHLIGHT): New macro.
13031 (print_entry): Set normal and highlight colors to
13032 `GRUB_COLOR_MENU_NORMAL' and `GRUB_COLOR_MENU_HIGHLIGHT',
13033 respectively, before printing and restore them to old
13034 values afterwards.
13035 (grub_menu_init_page): Likewise. Fill an additional colored space
13036 that would otherwise be left blank.
13037
13038 * term/efi/console.c (grub_console_getcolor): New function.
13039 (struct grub_console_term.getcolor): New variable.
13040 * term/i386/pc/console.c (grub_console_getcolor): New function.
13041 (struct grub_console_term.getcolor): New variable.
13042 * term/ieee1275/ofconsole.c (grub_ofconsole_getcolor): New function.
13043 (struct grub_console_term.getcolor): New variable.
13044
13045 * term/i386/pc/serial.c (grub_serial_setcolor): Remove function.
13046 (struct grub_console_term.setcolor): Remove variable.
13047 * term/i386/pc/vesafb.c (grub_virtual_screen_setcolor): Remove function.
13048 (struct grub_console_term.setcolor): Remove variable.
13049 * term/i386/pc/vga.c (grub_vga_setcolor): Remove function.
13050 (struct grub_console_term.setcolor): Remove variable.
13051 * term/gfxterm.c (grub_virtual_screen_setcolor): Remove function.
13052 (struct grub_console_term.setcolor): Remove variable.
13053
4931827f 130542007-12-25 Robert Millan <rmh@aybabtu.com>
13055
13056 * configure.ac: Search for possible unifont.hex locations, and
13057 define UNIFONT_HEX if found.
13058
13059 * Makefile.in (UNIFONT_HEX): Define variable.
13060 (DATA): Rename to ...
13061 (PKGLIB): ... this. Update all users.
13062 (PKGDATA): New variable.
13063 (pkgdata_IMAGES): Rename to ...
13064 (pkglib_IMAGES): ... this. Update all users.
13065 (pkgdata_MODULES): Rename to ...
13066 (pkglib_MODULES): ... this. Update all users.
13067 (pkgdata_PROGRAMS): Rename to ...
13068 (pkglib_PROGRAMS): ... this. Update all users.
13069 (pkgdata_DATA): Rename to ...
13070 (pkglib_DATA): ... this. Update all users.
13071 (CLEANFILES): Redefine to `$(pkglib_DATA) $(pkgdata_DATA)'.
13072 (unicode.pff, ascii.pff): New rules.
13073 (all-local): Add `$(PKGDATA)' dependency.
13074 (install-local): Process `$(PKGDATA)'.
13075
13076 * util/update-grub_lib.in (font_path): Search for *.pff files in
13077 a few more locations, including `${pkgdata}'.
13078
57e57e31 130792007-12-23 Robert Millan <rmh@aybabtu.com>
13080
13081 Patch from Bean <bean123ch@gmail.com>:
13082 * disk/loopback.c (grub_loopback_read): Add missing bit shift to
13083 `size'.
13084
4bc72aa9 130852007-12-21 Bean <bean123ch@gmail.com>
13086
13087 * conf/common.rmk (pkgdata_MODULES): Add ntfscomp.mod.
13088 (ntfscomp_mod_SOURCES): New variable.
13089 (ntfscomp_mod_CFLAGS): Likewise.
13090 (ntfscomp_mod_LDFLAGS): Likewise.
13091
13092 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfscomp.c.
13093 (grub_probe_SOURCES): Likewise.
13094 (grub_emu_SOURCES): Likewise.
13095
13096 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
13097 (grub_emu_SOURCES): Likewise.
13098
13099 * conf/i386-linuxbios.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
13100 (grub_emu_SOURCES): Likewise.
13101
13102 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfscomp.c.
13103 (grub_emu_SOURCES): Likewise.
13104
13105 * fs/ntfs.c (grub_ntfscomp_func): New variable.
13106 (read_run_list): Renamed to grub_ntfs_read_run_list.
13107 (decomp_nextvcn): Moved to ntfscomp.c.
13108 (decomp_getch): Likewise.
13109 (decomp_get16): Likewise.
13110 (decomp_block): Likewise.
13111 (read_block): Likewise.
13112 (read_data): Partially moved to ntfscomp.c.
13113 (fixup): Change unsigned to grub_uint16_t.
13114 (read_mft): Change unsigned long to grub_uint32_t.
13115 (read_attr): Likewise.
13116 (read_data): Likewise.
13117 (read_run_data): Likewise.
13118 (read_run_list): Likewise.
13119 (read_mft): Likewise.
13120
13121 * fs/ntfscomp.c: New file.
13122
13123 * include/grub/ntfs.h: New file.
13124
af680a87 131252007-12-16 Robert Millan <rmh@aybabtu.com>
13126
13127 * util/grub-mkdevicemap.c (make_device_map): Iterate up to 20 for
13128 IDE disk check, since Linux is known to support 20 IDE disks.
13129 Reported by Colin Watson.
13130
84be7599 131312007-12-15 Bean <bean123ch@gmail.com>
13132
13133 * conf/i386-pc.rmk (pkgdata_IMAGES): Add lnxboot.img.
13134 (lnxboot_img_SOURCES): New variable.
13135 (lnxboot_img_ASFLAGS): Likewise.
13136 (lnxboot_img_LDFLAGS): Likewise.
13137
13138 * boot/i386/pc/lnxboot.S: New file.
13139
6af9db01 131402007-11-24 Pavel Roskin <proski@gnu.org>
13141
13142 * configure.ac: Test if '--build-id=none' is supported by the
13143 linker. If yes, add it to TARGET_LDFLAGS. Build ID causes
13144 objcopy to generate incorrect binary files (binutils
13145 2.17.50.0.18-1 as shipped by Fedora 8).
13146 * aclocal.m4 (grub_PROG_OBJCOPY_ABSOLUTE): Use LDFLAGS when
13147 linking, so that build ID doesn't break the test.
13148
7361cfe6 131492007-11-24 Pavel Roskin <proski@gnu.org>
13150
13151 * include/grub/i386/time.h: use "void" in the argument list
13152 of grub_cpu_idle().
13153 * include/grub/powerpc/time.h: Likewise.
13154 * include/grub/sparc64/time.h: Likewise.
13155
1593e10c 131562007-11-18 Christian Franke <franke@computer.org>
13157
13158 * util/console.c (grub_ncurses_getkey): Change curses KEY_* mapping,
13159 now return control chars instead of GRUB_CONSOLE_KEY_* constants.
13160 This fixes the problem that function keys did not work in grub-emu.
13161
3b8db1a8 131622007-11-18 Christian Franke <franke@computer.org>
13163
13164 * disk/host.c (grub_host_open): Remove attribute unused from
13165 name parameter. Add check for "host". This fixes the problem
13166 that grub-emu does not find partitions.
13167
2e29408d 131682007-11-18 Christian Franke <franke@computer.org>
13169
13170 * util/hostfs.c (is_dir): New function.
13171 (grub_hostfs_dir): Handle missing dirent.d_type case.
13172 (grub_hostfs_read): Add missing fseek().
13173 (grub_hostfs_label): Clear label pointer. This fixes a crash
13174 of grub-emu on "ls (host)".
13175
398cd047 131762007-11-18 Christian Franke <franke@computer.org>
13177
13178 * include/grub/i386/pc/init.h (struct grub_machine_mmap_entry):
13179 Add attribute packed, gcc 3.4.4 on Cygwin aligns this
13180 to 64 bit boundary by default.
13181
c405c391 131822007-11-18 Bean <bean123ch@gmail.com>
13183
13184 * conf/common.rmk (pkgdata_MODULES): Add hexdump.mod.
13185 (hexdump_mod_SOURCES): New variable.
13186 (hexdump_mod_CFLAGS): Likewise.
13187 (hexdump_mod_LDFLAGS): Likewise.
f19dbdb7 13188
c405c391 13189 * conf/i386-pc.rmk (grub_emu_SOURCES): Add command/hexdump.c.
13190
13191 * conf/i386-efi.rmk (grub_emu_SOURCES): Add command/hexdump.c.
13192
13193 * conf/i386-linuxbios.rmk (grub_emu_SOURCES): Add command/hexdump.c.
13194
13195 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add command/hexdump.c.
13196
13197 * include/grub/hexdump.h: New file.
13198
13199 * commands/hexdump.c: New file.
13200
5cced7fd 132012007-11-10 Robert Millan <rmh@aybabtu.com>
13202
13203 * commands/i386/pc/play.c (beep_off): Switch order of arguments
13204 in grub_outb() calls.
13205 (beep_on): Likewise.
13206
8b714eb0 132072007-11-10 Christian Franke <franke@computer.org>
13208
13209 * normal/menu.c (run_menu): Check for empty menu to avoid crash.
13210 (grub_menu_run): Likewise.
13211
ce0f1839 132122007-11-10 Robert Millan <rmh@aybabtu.com>
13213
13214 * include/grub/i386/efi/machine.h: New file.
13215 * include/grub/i386/linuxbios/machine.h: Likewise.
13216 * include/grub/i386/pc/machine.h: Likewise.
13217 * include/grub/powerpc/ieee1275/machine.h: Likewise.
13218 * include/grub/sparc64/ieee1275/machine.h: Likewise.
13219
13220 * term/i386/pc/serial.c: Include <grub/machine/machine.h>.
13221 (serial_hw_io_addr): New variable.
13222 (serial_hw_get_port): Obtain port address from `serial_hw_io_addr'
13223 instead of `(unsigned short *) 0x400'.
13224
270c237d 132252007-11-10 Bean <bean123ch@gmail.com>
13226
13227 * fs/ntfs.c (read_block): Fix a bug caused by adjacent blocks.
13228
a87783bf 132292007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
13230
13231 * conf/i386-pc.rmk (pkgdata_MODULES): Added vga.mod.
13232 (vga_mod_SOURCES): Added.
13233 (vga_mod_CFLAGS): Likewise.
13234 (vga_mod_LDFLAGS): Likewise.
13235
13236 * term/i386/pc/vga.c (get_map_mask): Switch order of arguments in
13237 grub_outb() calls.
13238 (set_map_mask): Likewise.
13239 (set_read_map): Likewise.
13240 (set_read_address): Likewise.
13241 (vga_font): Removed variable.
13242 (get_vga_glyph): Removed function.
13243 (invalidate_char): Likewise.
13244 (write_char): Changed to use grub_font_get_glyph() for font
13245 information.
13246 (grub_vga_putchar): Likewise.
13247 (grub_vga_getcharwidth): Likewise.
13248
6433b448 132492007-11-10 Vesa Jaaskelainen <chaac@nic.fi>
13250
13251 * conf/i386-pc.rmk (boot_img_LDFLAGS): Use COMMON_LDFLAGS for target
13252 flags.
13253 (pxeboot_img_LDFLAGS): Likewise.
13254 (diskboot_img_LDFLAGS): Likewise.
13255 (kernel_img_LDFLAGS): Likewise.
13256
49178511 132572007-11-06 Robert Millan <rmh@aybabtu.com>
13258
13259 * term/i386/pc/serial.c (serial_hw_put): Switch order of arguments
13260 in grub_outb() calls.
13261 (serial_hw_init): Likewise.
13262
53b052de 132632007-11-05 Robert Millan <rmh@aybabtu.com>
13264
13265 * util/update-grub.in: Allow files in ${update_grub_dir} to contain
13266 spaces. Skip non-regular files.
13267
5ab33bba 132682007-11-05 Robert Millan <rmh@aybabtu.com>
13269
13270 * kern/disk.c (grub_disk_firmware_fini)
13271 (grub_disk_firmware_is_tainted): New variables.
13272
13273 * include/grub/disk.h (grub_disk_firmware_fini)
13274 (grub_disk_firmware_is_tainted): Likewise.
13275
13276 * disk/i386/pc/biosdisk.c (GRUB_MOD_FINI(biosdisk)): Moved from here ...
13277 (grub_disk_biosdisk_fini): ... to here.
13278 (GRUB_MOD_FINI(biosdisk)): Implement using grub_disk_biosdisk_fini().
13279 (GRUB_MOD_INIT(biosdisk)): Abort when `grub_disk_firmware_is_tainted'
13280 is set. Register grub_disk_biosdisk_fini() in
13281 `grub_disk_firmware_fini'.
13282
13283 * disk/ata.c: Remove `<grub/machine/biosdisk.h>'.
13284 (GRUB_MOD_INIT(ata)): Remove grub_biosdisk_fini() call.
13285 Use `grub_disk_firmware_is_tainted' and `grub_disk_firmware_fini'
13286 to finish existing firmware disk interface.
13287
13288 * conf/i386-linuxbios.rmk (pkgdata_MODULES): Add `ata.mod'.
13289 (ata_mod_SOURCES): New variable.
13290 (ata_mod_CFLAGS): Likewise.
13291 (ata_mod_LDFLAGS): Likewise.
13292
0149ab7c 132932007-11-05 Robert Millan <rmh@aybabtu.com>
13294
13295 * disk/ata.c: Remove `<grub/machine/time.h>'. Include `<grub/time.h>'.
13296 (grub_ata_wait): Reimplement using grub_millisleep().
13297
13298 * include/grub/misc.h (grub_div_roundup): Fix parenthesization.
13299 * include/grub/i386/time.h (grub_cpu_idle): Disable `hlt' instruction.
13300
be7ac41e 133012007-11-03 Marco Gerards <marco@gnu.org>
13302
13303 * term/i386/pc/vga_text.c: Include <grub/cpu/io.h>.
13304 (CRTC_ADDR_PORT): New macro.
13305 (CRTC_DATA_PORT): Likewise.
13306 (CRTC_CURSOR): Likewise.
13307 (CRTC_CURSOR_ADDR_HIGH): Likewise.
13308 (CRTC_CURSOR_ADDR_LOW): Likewise.
13309 (update_cursor): New function.
13310 (grub_console_real_putchar): Call `update_cursor'.
13311 (grub_console_gotoxy): Likewise.
13312 (grub_console_cls): Set the default color when clearing the
13313 screen.
13314 (grub_console_setcursor): Implemented.
13315
bb06ab2e 133162007-11-03 Marco Gerards <marco@gnu.org>
13317
13318 * disk/ata.c (grub_ata_pio_read): Don't wait for the command to
13319 become activate.
13320 (grub_ata_pio_write): Likewise.
13321
13322 (grub_atapi_identify): Wait after issuing an ATA command.
13323 (grub_atapi_packet): Likewise.
13324 (grub_ata_identify): Likewise.
13325 (grub_ata_readwrite): Likewise.
13326
cf8f780b 133272007-11-03 Marco Gerards <marco@gnu.org>
13328
13329 * disk/ata.c (grub_ata_pio_read): Detect and return the error code.
13330 (grub_ata_pio_write): Likewise.
13331 (grub_ata_readwrite): Use `grub_error', instead of
13332 returning `grub_errno'.
13333
ed649e54 133342007-11-03 Marco Gerards <marco@gnu.org>
13335
13336 * disk/ata.c (grub_ata_readwrite): Call grub_ata_pio_read and
13337 grub_ata_pio_write once for every single sector, instead of for
13338 multiple sectors.
13339
ca25d8f0 133402007-10-31 Robert Millan <rmh@aybabtu.com>
13341
13342 * configure.ac: Add `i386-linuxbios' to the list of supported targets.
13343
13344 * conf/i386-linuxbios.rmk: New file.
13345
13346 * kern/i386/pc/hardware.c: Likewise.
13347 * term/i386/pc/at_keyboard.c: Likewise.
13348 * term/i386/pc/vga_text.c: Likewise.
13349
13350 * include/grub/i386/linuxbios/boot.h: Likewise.
13351 * include/grub/i386/linuxbios/console.h: Likewise.
13352 * include/grub/i386/linuxbios/init.h: Likewise.
13353 * include/grub/i386/linuxbios/kernel.h: Likewise.
13354 * include/grub/i386/linuxbios/loader.h: Likewise.
13355 * include/grub/i386/linuxbios/memory.h: Likewise.
13356 * include/grub/i386/linuxbios/serial.h: Likewise.
13357 * include/grub/i386/linuxbios/time.h: Likewise.
13358
13359 * kern/i386/linuxbios/init.c: Likewise.
13360 * kern/i386/linuxbios/startup.S: Likewise.
13361 * kern/i386/linuxbios/table.c: Likewise.
13362
e911ecc1 133632007-10-31 Marco Gerards <marco@gnu.org>
13364
13365 * conf/i386-pc.rmk (pkgdata_MODULES): Add `ata.mod'.
13366 (ata_mod_SOURCES): New variable.
13367 (ata_mod_CFLAGS): Likewise.
13368 (ata_mod_LDFLAGS): Likewise.
13369
13370 * disk/ata.c: New file.
13371
13372 * include/grub/disk.h (grub_disk_dev_id): Add
13373 `GRUB_DISK_DEV_ATA_ID'.
f19dbdb7 13374
7f66d0e0 133752007-10-31 Robert Millan <rmh@aybabtu.com>
13376
13377 * include/grub/i386/pc/init.h (grub_lower_mem): Moved from here ...
13378 * include/grub/i386/pc/memory.h (grub_lower_mem): ... to here.
13379
13380 * include/grub/i386/pc/init.h (grub_upper_mem): Moved from here ...
13381 * include/grub/i386/pc/memory.h (grub_upper_mem): ... to here.
13382
13383 * include/grub/i386/pc/memory.h: Include `<grub/symbol.h>' and
13384 `<grub/types.h>'.
13385
13386 * loader/i386/pc/multiboot.c: Include `<grub/machine/memory.h>'.
13387
5cd7dd46 133882007-10-27 Robert Millan <rmh@aybabtu.com>
13389
3236ca65 13390 * include/grub/types.h (ULONG_MAX): Define macro.
5cd7dd46 13391
2ebfc90f 133922007-10-22 Robert Millan <rmh@aybabtu.com>
13393
13394 * kern/i386/pc/startup.S: Remove `"kern/i386/realmode.S"'. Include
13395 `"../realmode.S"'.
13396 Remove `"kern/i386/loader.S"'. Include `"../loader.S"'.
13397
73fcb0f3 133982007-10-22 Robert Millan <rmh@aybabtu.com>
13399
13400 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove `disk/i386/pc/biosdisk.c'.
13401 (pkgdata_MODULES): Add `biosdisk.mod'.
13402 (biosdisk_mod_SOURCES, biosdisk_mod_CFLAGS, biosdisk_mod_LDFLAGS): New
13403 variables.
13404
13405 * disk/i386/pc/biosdisk.c: Include `<grub/dl.h>'.
13406 (grub_biosdisk_init): Replace with ...
13407 (GRUB_MOD_INIT(biosdisk)): ... this.
13408 (grub_biosdisk_fini): Replace with ...
13409 (GRUB_MOD_FINI(biosdisk)): ... this.
13410
13411 * kern/i386/pc/init.c: Remove `<grub/machine/biosdisk.h>'.
13412 (grub_machine_init): Remove call to grub_biosdisk_init().
13413 (grub_machine_fini): Remove call to grub_machine_fini().
13414
13415 * util/i386/pc/grub-install.in (modules): Add `biosdisk'.
13416
3381d274 134172007-10-22 Robert Millan <rmh@aybabtu.com>
13418
13419 * include/grub/time.h: New file.
13420 * include/grub/i386/time.h: Likewise.
13421 * include/grub/powerpc/time.h: Likewise.
13422 * include/grub/sparc64/time.h: Likewise.
13423
13424 * include/grub/i386/pc/time.h (KERNEL_TIME_HEADER): Rename all
13425 instances to ...
13426 (KERNEL_MACHINE_TIME_HEADER): ... this.
13427 * include/grub/powerpc/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
13428 instances to ...
13429 (KERNEL_MACHINE_TIME_HEADER): ... this.
13430 * include/grub/sparc64/ieee1275/time.h (KERNEL_TIME_HEADER): Rename all
13431 instances to ...
13432 (KERNEL_MACHINE_TIME_HEADER): ... this.
13433
13434 * kern/i386/efi/init.c: Include `<grub/time.h>'.
13435 (grub_millisleep): New function.
13436 * kern/i386/pc/init.c: Include `<grub/time.h>'.
13437 (grub_millisleep): New function.
13438 * kern/powerpc/ieee1275/init.c: Include `<grub/time.h>'.
13439 Remove `grub/machine/time.h' include.
13440 (grub_millisleep): New function.
13441 * kern/sparc64/ieee1275/init.c: Include `<grub/time.h>'.
13442 Remove `grub/machine/time.h' include.
13443 (grub_millisleep): New function.
13444
13445 * include/grub/misc.h (grub_div_roundup): New function.
13446
13447 * kern/misc.c: Include `<grub/time.h>'.
13448 (grub_millisleep_generic): New function.
13449
13450 * conf/i386-efi.rmk (kernel_mod_HEADERS): Remove `i386/efi/time.h'.
13451 Add `time.h'.
13452 * conf/i386-pc.rmk (kernel_img_HEADERS): Remove `machine/time.h'.
13453 Add `time.h'.
13454 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Remove
13455 `machine/time.h'. Add `time.h'.
13456 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
13457
a39a0312 134582007-10-21 Robert Millan <rmh@aybabtu.com>
13459
13460 * include/grub/misc.h (grub_max): New function.
13461
2aad70e2 134622007-10-21 Robert Millan <rmh@aybabtu.com>
13463
13464 * util/misc.c (grub_util_info): Call fflush() before returning.
13465
54b71c4b 134662007-10-20 Robert Millan <rmh@aybabtu.com>
13467
13468 * genmk.rb (Image): Copy `extra_flags' from here ...
13469 (PModule): ... to here. Use it in `#{obj}: #{src}' rule.
13470
13471 * commands/i386/cpuid.c (grub_cmd_cpuid): Add __attribute__ ((unused))
13472 to `argc' and `args' arguments.
13473
a979f513 134742007-10-17 Robert Millan <rmh@aybabtu.com>
13475
13476 * kern/i386/loader.S: New file.
13477
13478 * kern/i386/pc/startup.S (grub_linux_prot_size): Moved from here ...
13479 * kern/i386/loader.S (grub_linux_prot_size)... to here.
13480 * kern/i386/pc/startup.S (grub_linux_tmp_addr): Moved from here ...
13481 * kern/i386/loader.S (grub_linux_tmp_addr)... to here.
13482 * kern/i386/pc/startup.S (grub_linux_real_addr): Moved from here ...
13483 * kern/i386/loader.S (grub_linux_real_addr)... to here.
13484 * kern/i386/pc/startup.S (grub_linux_boot_zimage): Moved from here ...
13485 * kern/i386/loader.S (grub_linux_boot_zimage)... to here.
13486 * kern/i386/pc/startup.S (grub_linux_boot_bzimage): Moved from here ...
13487 * kern/i386/loader.S (grub_linux_boot_bzimage)... to here.
13488 * kern/i386/pc/startup.S (grub_multiboot_real_boot): Moved from here ...
13489 * kern/i386/loader.S (grub_multiboot_real_boot)... to here.
13490 * kern/i386/pc/startup.S (grub_multiboot2_real_boot): Moved from here ...
13491 * kern/i386/loader.S (grub_multiboot2_real_boot)... to here.
13492
13493 * kern/i386/realmode.S: New file.
13494
13495 * kern/i386/pc/startup.S (protstack): Moved from here ...
13496 * kern/i386/realmode.S (protstack)... to here.
13497 * kern/i386/pc/startup.S (gdt): Moved from here ...
13498 * kern/i386/realmode.S (gdt)... to here.
13499 * kern/i386/pc/startup.S (prot_to_real): Moved from here ...
13500 * kern/i386/realmode.S (prot_to_real)... to here.
13501
13502 * kern/i386/pc/startup.S: Include `kern/i386/loader.S' and
13503 `kern/i386/realmode.S'.
13504
825fc8fd 135052007-10-17 Robert Millan <rmh@aybabtu.com>
13506
13507 * include/grub/i386/loader.h: New file.
13508
13509 * include/grub/i386/pc/loader.h (grub_linux_prot_size)
13510 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
13511 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
13512 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
13513 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): Moved from here ...
13514 * include/grub/i386/loader.h (grub_linux_prot_size)
13515 (grub_linux_tmp_addr, grub_linux_real_addr, grub_os_area_addr)
13516 (grub_os_area_size, grub_linux_boot_zimage, grub_linux_boot_bzimage)
13517 (grub_multiboot_real_boot, grub_multiboot2_real_boot)
13518 (grub_rescue_cmd_linux, grub_rescue_cmd_initrd): ... to here.
13519
13520 * include/grub/i386/pc/loader.h: Include `grub/cpu/loader.h'.
13521
e179b2f4 135222007-10-15 Robert Millan <rmh@aybabtu.com>
13523
13524 * normal/misc.c (grub_normal_print_device_info): Do not probe for
13525 filesystem when dev->disk is unset.
13526 Do probe for filesystem even when dev->disk->has_partitions is set.
13527 In case a filesystem is found, always report it.
13528 In case it isn't, if dev->disk->has_partitions is set, report that
13529 a partition table was found instead of reporting that no filesystem
13530 could be identified.
13531
5db82af6 135322007-10-12 Robert Millan <rmh@aybabtu.com>
13533
13534 * conf/powerpc-ieee1275.rmk (grub_mkimage_SOURCES): Replace reference
13535 to util/powerpc/ieee1275/grub-mkimage.c with util/elf/grub-mkimage.c.
13536
68f6ac74 13537 * include/grub/types.h (grub_host_to_target16): New macro.
13538 (grub_host_to_target32): Likewise.
13539 (grub_host_to_target64): Likewise.
13540 (grub_target_to_host16): Likewise.
13541 (grub_target_to_host32): Likewise.
13542 (grub_target_to_host64): Likewise.
5db82af6 13543
13544 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
13545 Renamed from to ...
13546 (GRUB_MOD_ALIGN): ...this. Update all users.
13547
68f6ac74 13548 * util/elf/grub-mkimage.c (load_note): Replace grub_cpu_to_be32 with
13549 grub_host_to_target32.
13550 Replace grub_be_to_cpu32 with grub_target_to_host32.
13551 (load_modules): Likewise.
13552 (add_segments): Replace grub_be_to_cpu16 with grub_target_to_host16.
13553 Replace grub_be_to_cpu32 with grub_target_to_host32.
13554 Replace grub_cpu_to_be16 with grub_host_to_target16.
13555 Replace grub_cpu_to_be32 grub_host_to_target32.
5db82af6 13556
3cf497cc 135572007-10-12 Robert Millan <rmh@aybabtu.com>
13558
13559 * util/powerpc/ieee1275/grub-mkimage.c: Moved to ...
13560 * util/elf/grub-mkimage.c: ... here.
13561
13562 * DISTLIST: Add `util/elf/grub-mkimage.c'. Remove
13563 `util/powerpc/ieee1275/grub-mkimage.c'.
13564
c8cc3692 135652007-10-07 Robert Millan <rmh@aybabtu.com>
adbc4c9d 13566
c8cc3692 13567 * kern/powerpc/ieee1275/init.c: Rename HEAP_LIMIT to HEAP_MAX_ADDR,
13568 and make it easier to figure out.
13569 Add HEAP_MIN_SIZE and HEAP_MAX_ADDR definitions.
13570 (grub_claim_heap): Use HEAP_MAX_ADDR rather than taking a parameter.
13571 Do not avoid claiming a region above HEAP_MAX_ADDR if that would
13572 leave us with less than HEAP_MIN_SIZE total heap.
13573 Avoid our total amount of heap to surpass HEAP_MAX_SIZE.
adbc4c9d 13574
5c58b791 135752007-10-03 Robert Millan <rmh@aybabtu.com>
13576
13577 * include/grub/i386/io.h: New file.
13578 * commands/i386/pc/play.c (inb): Removed.
13579 (outb): Removed.
13580 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
13581 with grub_outb().
afcd2ef8 13582 * term/i386/pc/serial.c (inb): Removed.
13583 (outb): Removed.
13584 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
13585 with grub_outb().
13586 * term/i386/pc/vga.c (inb): Removed.
13587 (outb): Removed.
13588 Include grub/cpu/io.h. Replace inb() with grub_inb() and outb()
13589 with grub_outb().
5c58b791 13590
1a477ed6 135912007-10-02 Robert Millan <rmh@aybabtu.com>
13592
13593 * conf/i386-efi.rmk (grub_emu_SOURCES): Add util/hostfs.c.
13594 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
13595 Reported by Marcin Kurek.
13596
6b5d80fa 135972007-09-07 Robert Millan <rmh@aybabtu.com>
13598
13599 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_test_flag): Detect
13600 SmartFirmware version updates (as released by Sven Luther), and avoid
13601 setting GRUB_IEEE1275_FLAG_NO_PARTITION_0 or
13602 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS unless the running version is
13603 known broken.
13604
5618afbf 136052007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
13606
13607 From Hitoshi Ozeki:
13608 * kern/i386/pc/init.c (compact_mem_regions): Decrease NUM_REGIONS
13609 when merging two regions.
13610
6139dcd9 136112007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
13612
508e39ee 13613 * kern/rescue.c (grub_enter_rescue_mode): Free ARGS.
13614 * normal/completion.c (grub_normal_do_completion): Likewise.
13615 Reported by Hitoshi Ozeki.
13616
136172007-09-03 Yoshinori K. Okuji <okuji@enbug.org>
f19dbdb7 13618
6139dcd9 13619 Do not use devices at boot in chainloading.
f19dbdb7 13620
6139dcd9 13621 * loader/i386/pc/chainloader.c (boot_drive): New variable.
13622 (boot_part_addr): Likewise.
13623 (grub_chainloader_boot): Simply call grub_chainloader_real_boot
13624 with BOOT_DRIVE and BOOT_PART_ADDR.
13625 (grub_chainloader_cmd): Set BOOT_DRIVE and BOOT_PART_ADDR.
13626 Reported by Hitoshi Ozeki <h-ozeki@ck2.so-net.ne.jp>.
13627
38da6516 136282007-08-29 Robert Millan <rmh@aybabtu.com>
13629
13630 Patch from Simon Peter <dn.tlp@gmx.net>:
13631 * genmk.rb (Utility): Append $(#{src}_DEPENDENCIES) to #{obj} targets.
13632 * conf/i386-pc.rmk: Replace grub-probe_DEPENDENCIES with
13633 util/grub-probe.c_DEPENDENCIES. Replace grub-setup_DEPENDENCIES with
13634 util/i386/pc/grub-setup.c_DEPENDENCIES.
13635 * conf/i386-efi.rmk: Replace grub-probe_DEPENDENCIES with
13636 util/grub-probe.c_DEPENDENCIES.
13637 * conf/powerpc-ieee1275.rmk: Likewise.
13638
29d0928c 136392007-08-28 Robert Millan <rmh@aybabtu.com>
13640
13641 * util/i386/get_disk_name.c: New. Implement grub_util_get_disk_name()
13642 to tell grub-mkdevicemap how to name devices.
13643 * util/ieee1275/get_disk_name.c: Likewise (using "ofpathname -a"
13644 feature).
13645
13646 * conf/i386-efi.rmk (grub_mkdevicemap_SOURCES): Add
13647 util/i386/get_disk_name.c.
13648 * conf/i386-pc.rmk (grub_mkdevicemap_SOURCES): Likewise.
13649 * conf/powerpc-ieee1275.rmk (grub_mkdevicemap_SOURCES): Add
13650 util/ieee1275/get_disk_name.c.
13651
13652 * include/grub/util/misc.h: grub_util_get_disk_name() declaration.
13653
13654 * DISTLIST: Add util/i386/get_disk_name.c and
13655 util/ieee1275/get_disk_name.c.
13656
13657 * util/grub-mkdevicemap.c: Replace device naming logic with
13658 grub_util_get_disk_name() calls.
13659
5a0d3cca 136602007-08-20 Robert Millan <rmh@aybabtu.com>
13661
13662 * normal/menu.c (run_menu): Refer to seconds as "s" not "seconds"
13663 (so that it works for both plural and singular quantities).
13664
8b72db2f 136652007-08-05 Robert Millan <rmh@aybabtu.com>
13666
13667 * util/grub.d/10_linux.in (test_gt): Strip out vmlinu[xz]- prefix
13668 so that [xz] isn't taken into account when determining order.
13669
352466bf 136702007-08-02 Marco Gerards <marco@gnu.org>
13671
13672 * DISTLIST: Add `disk/host.c', `fs/ntfs.c', `include/multiboot.h',
13673 `include/multiboot2.h', `include/grub/elfload.h',
13674 `include/multiboot.h', `include/grub/multiboot.h',
13675 `include/grub/multiboot_loader.h', `include/grub/multiboot2.h',
13676 `include/grub/i386/pc/biosdisk.h', `include/grub/util/biosdisk.h',
13677 `kern/elf.c', `loader/multiboot_loader.c',
13678 `loader/multiboot_loader_normal.c', `loader/multiboot2.c',
13679 `loader/i386/pc/multiboot2.c',
13680 `loader/powerpc/ieee1275/multiboot2.c', `util/hostfs.c' and
13681 `util/i386/pc/grub-mkrescue.in'. Remove
13682 `include/grub/biosdisk.h', `include/grub/i386/pc/multiboot.h',
13683 `include/grub/i386/pc/util/biosdisk.h' and
13684 `include/grub/powerpc/ieee1275/multiboot.h'.
13685
8f096014 136862007-08-02 Bean <bean123ch@gmail.com>
13687
13688 * conf/common.rmk (pkgdata_MODULES): Add ntfs.mod.
13689 (ntfs_mod_SOURCES): New variable.
13690 (ntfs_mod_CFLAGS): Likewise.
13691 (ntfs_mod_LDFLAGS): Likewise.
13692
13693 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ntfs.c.
13694 (grub_probe_SOURCES): Likewise.
13695 (grub_emu_SOURCES): Likewise.
13696
13697 * conf/i386-efi.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
13698 (grub_emu_SOURCES): Likewise.
13699
13700 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add fs/ntfs.c.
13701 (grub_emu_SOURCES): Likewise.
f19dbdb7 13702
8f096014 13703 * conf/misc.c (grub_utf16_to_utf8): Fix unicode conversion bug.
13704
13705 * fs/ntfs.c: New file.
13706
9959f7db 137072007-08-02 Bean <bean123ch@gmail.com>
13708
13709 * disk.h (grub_disk): Use NESTED_FUNC_ATTR.
13710
13711 * file.h (grub_file): Likewise.
13712
13713 * fshelp.h (grub_fshelp_read_file): Likewise.
13714
13715 * util/i386/pc/grub-setup.c (setup): Likewise.
13716 (save_first_sector): Likewise.
13717 (save_blocklists): Likewise.
f19dbdb7 13718
9959f7db 13719 * fs/affs.c (grub_affs_read_file): Likewise.
13720
13721 * fs/ext2.c (grub_ext2_read_file): Likewise.
13722
13723 * fs/fat.c (grub_fat_read_data): Likewise.
13724
13725 * fs/fshelp.c (grub_fshelp_read_file): Likewise.
13726
13727 * fs/hfs.c (grub_hfs_read_file): Likewise.
13728
13729 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
13730
13731 * fs/jfs.c (grub_jfs_read_file): Likewise.
13732
13733 * fs/minix.c (grub_minix_read_file): Likewise.
13734
13735 * fs/sfs.c (grub_sfs_read_file): Likewise.
13736
13737 * fs/ufs.c (grub_ufs_read_file): Likewise.
f19dbdb7 13738
9959f7db 13739 * fs/xfs.c (grub_xfs_read_file): Likewise.
13740
13741 * command/blocklist.c (read_blocklist): Likewise.
13742 (print_blocklist): Likewise.
13743
0a203f83 137442007-08-02 Marco Gerards <marco@gnu.org>
13745
13746 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/host.c' and
13747 `util/hostfs.c'.
13748
13749 * disk/host.c: New file.
13750
13751 * util/hostfs.c: Likewise.
13752
13753 * fs/hfsplus.c (grub_hfsplus_mount): When reading out of disk,
13754 return `GRUB_ERR_BAD_FS'.
13755 * fs/sfs.c (grub_sfs_mount): Likewise.
13756 * fs/xfs.c (grub_xfs_mount): Likewise.
13757
13758 * include/grub/disk.h (enum grub_disk_dev_id): Add
13759 `GRUB_DISK_DEVICE_HOST_ID'.
13760
13761 * util/grub-emu.c (main): Initialize and de-initialize hostfs.
13762
e5dfe777 137632007-07-24 Jerone Young <jerone@gmail.com>
13764
f19dbdb7 13765 * conf/i386-pc.rmk: Add Multiboot loader and multiboot 2 to multiboot
e5dfe777 13766 modules for compilation.
13767 * conf/powerpc-ieee1275.rmk: Likewise.
13768
13769 * include/multiboot.h: Move multiboot definitions to one file. Rename
13770 many definitions to not get grub specific.
13771 * include/multiboot2.h: Create header with multiboot 2 definitions.
13772 * include/grub/multiboot.h: Header for grub specific function
13773 prototypes and definitions.
13774 * include/grub/multiboot2.h: Likewise.
13775 * include/grub/multiboot_loader.h: Likewise.
13776 * include/grub/i386/pc/multiboot.h: Removed.
13777 * include/grub/powerpc/ieee1275/multiboot.h: Removed.
13778
13779 * loader/multiboot_loader.c: Created to act as a proxy for multiboot 1
13780 and 2 to allow for one multiboot and module commands.
13781 * loader/multiboot2.c: Add multiboot2 functionality.
13782 * loader/i386/pc/multiboot.c: Modify for new multiboot header location
13783 and definition names.
13784 * loader/i386/pc/multiboot2.c: Created to add i386 specific multiboot
13785 2 functions.
13786 * loader/powerpc/ieee1275/multiboot2.c: Created to add powerpc
13787 ieee1275 specific multiboot2 code.
13788
13789 * kern/i386/pc/startup.S: Change headers and definition names for
13790 multiboot. Add function grub_multiboot2_real_boot for multiboot 2.
13791
daf0f0ba 137922007-07-22 Robert Millan <rmh@aybabtu.com>
13793
13794 * geninitheader.sh: Process file specified in first parameter rather
13795 than hardcoding grub_modules_init.lst.
fe6b695a 13796 * geninit.sh: Likewise. Also, construct header name dynamically rather
daf0f0ba 13797 than hardcoding grub_modules_init.h.
13798
13799 * conf/common.rmk: Rename grub_modules_init.[ch] files associated with
13800 grub-emu to grub_emu_init.[ch]. Add rules to build analogous
13801 grub_probe_init.[ch] and grub_setup_init.[ch].
13802
13803 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Replace
13804 grub_modules_init.h with grub_emu_init.h.
13805 (grub_probe_DEPENDENCIES, grub_probe_SOURCES): Add new
13806 grub_probe_init.[ch] files.
13807 * conf/i386-efi.rmk: Likewise.
13808 * conf/i386-pc.rmk: Likewise.
13809 (grub_setup_DEPENDENCIES, grub_setup_SOURCES): Add new
13810 grub_setup_init.[ch] files.
13811
13812 * util/grub-emu.c: Replace grub_modules_init.h with grub_emu_init.h.
13813 * util/grub-probe.c: Include grub_probe_init.h. Use grub_init_all()
13814 to initialize modules rather than a list of hardcoded functions.
13815 * util/i386/pc/grub-setup.c: Include grub_setup_init.h. Use
13816 grub_init_all() to initialize modules rather than a list of hardcoded
13817 functions.
13818
54cdc1cc 138192007-07-22 Robert Millan <rmh@aybabtu.com>
13820
13821 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set
13822 GRUB_IEEE1275_FLAG_NO_PARTITION_0 flag when running on SmartFirmware.
13823
ad0686cc 138242007-07-22 Robert Millan <rmh@aybabtu.com>
13825
13826 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_flag): Add
13827 GRUB_IEEE1275_FLAG_BROKEN_OUTPUT flag.
13828 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options): Set this
13829 flag when running on SmartFirmware.
13830 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Avoid running
13831 "output-device output" command when GRUB_IEEE1275_FLAG_BROKEN_OUTPUT
13832 was set.
13833
13834 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
13835 Increase partno when GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS flag is set,
13836 rather than decreasing it.
13837
13838 * util/i386/pc/grub-setup.c (setup): When embedding is required, but
13839 there's not enough space to do it, fail in the same way as when it
13840 can't be done because there are no partitions.
13841
13842 * util/powerpc/ieee1275/grub-install.in: Improve error message shown
13843 when nvsetenv failed.
13844
969c02ec 138452007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
13846
13847 * conf/i386-pc.rmk (CLEANFILES): Removed for grub-mkrescue,
13848 because this rule is automatically generated.
13849 (grub-mkrescue): Removed for the same reason as above.
13850
5a79f472 138512007-07-22 Yoshinori K. Okuji <okuji@enbug.org>
13852
13853 Migrate to GNU General Public License Version 3.
f19dbdb7 13854
5a79f472 13855 * COPYING: Replaced with the plain text version of GPLv3.
13856
13857 * config.guess: Updated from gnulib.
13858 * config.sub: Likewise.
13859
13860 * geninit.sh: Output a GPLv3 copyright notice.
13861 * geninitheader.sh: Likewise.
13862 * genmodsrc.sh: Likewise.
13863 * gensymlist.sh.in: Likewise.
13864
13865 * boot/i386/pc/boot.S: Upgraded to GPLv3.
13866 * boot/i386/pc/diskboot.S: Likewise.
13867 * boot/i386/pc/pxeboot.S: Likewise.
13868 * commands/blocklist.c: Likewise.
13869 * commands/boot.c: Likewise.
13870 * commands/cat.c: Likewise.
13871 * commands/cmp.c: Likewise.
13872 * commands/configfile.c: Likewise.
13873 * commands/echo.c: Likewise.
13874 * commands/help.c: Likewise.
13875 * commands/ls.c: Likewise.
13876 * commands/search.c: Likewise.
13877 * commands/terminal.c: Likewise.
13878 * commands/test.c: Likewise.
13879 * commands/videotest.c: Likewise.
13880 * commands/i386/cpuid.c: Likewise.
13881 * commands/i386/pc/halt.c: Likewise.
13882 * commands/i386/pc/play.c: Likewise.
13883 * commands/i386/pc/reboot.c: Likewise.
13884 * commands/i386/pc/vbeinfo.c: Likewise.
13885 * commands/i386/pc/vbetest.c: Likewise.
13886 * commands/ieee1275/halt.c: Likewise.
13887 * commands/ieee1275/reboot.c: Likewise.
13888 * commands/ieee1275/suspend.c: Likewise.
13889 * disk/loopback.c: Likewise.
13890 * disk/lvm.c: Likewise.
13891 * disk/raid.c: Likewise.
13892 * disk/efi/efidisk.c: Likewise.
13893 * disk/i386/pc/biosdisk.c: Likewise.
13894 * disk/ieee1275/ofdisk.c: Likewise.
13895 * font/manager.c: Likewise.
13896 * fs/affs.c: Likewise.
13897 * fs/ext2.c: Likewise.
13898 * fs/fat.c: Likewise.
13899 * fs/fshelp.c: Likewise.
13900 * fs/hfs.c: Likewise.
13901 * fs/hfsplus.c: Likewise.
13902 * fs/iso9660.c: Likewise.
13903 * fs/jfs.c: Likewise.
13904 * fs/minix.c: Likewise.
13905 * fs/sfs.c: Likewise.
13906 * fs/ufs.c: Likewise.
13907 * fs/xfs.c: Likewise.
13908 * hello/hello.c: Likewise.
13909 * include/grub/acorn_filecore.h: Likewise.
13910 * include/grub/arg.h: Likewise.
13911 * include/grub/bitmap.h: Likewise.
13912 * include/grub/boot.h: Likewise.
13913 * include/grub/cache.h: Likewise.
13914 * include/grub/device.h: Likewise.
13915 * include/grub/disk.h: Likewise.
13916 * include/grub/dl.h: Likewise.
13917 * include/grub/elfload.h: Likewise.
13918 * include/grub/env.h: Likewise.
13919 * include/grub/err.h: Likewise.
13920 * include/grub/file.h: Likewise.
13921 * include/grub/font.h: Likewise.
13922 * include/grub/fs.h: Likewise.
13923 * include/grub/fshelp.h: Likewise.
13924 * include/grub/gzio.h: Likewise.
13925 * include/grub/hfs.h: Likewise.
13926 * include/grub/kernel.h: Likewise.
13927 * include/grub/loader.h: Likewise.
13928 * include/grub/lvm.h: Likewise.
13929 * include/grub/misc.h: Likewise.
13930 * include/grub/mm.h: Likewise.
13931 * include/grub/net.h: Likewise.
13932 * include/grub/normal.h: Likewise.
13933 * include/grub/parser.h: Likewise.
13934 * include/grub/partition.h: Likewise.
13935 * include/grub/pc_partition.h: Likewise.
13936 * include/grub/raid.h: Likewise.
13937 * include/grub/rescue.h: Likewise.
13938 * include/grub/script.h: Likewise.
13939 * include/grub/setjmp.h: Likewise.
13940 * include/grub/symbol.h: Likewise.
13941 * include/grub/term.h: Likewise.
13942 * include/grub/terminfo.h: Likewise.
13943 * include/grub/tparm.h: Likewise.
13944 * include/grub/types.h: Likewise.
13945 * include/grub/video.h: Likewise.
13946 * include/grub/efi/api.h: Likewise.
13947 * include/grub/efi/chainloader.h: Likewise.
13948 * include/grub/efi/console.h: Likewise.
13949 * include/grub/efi/console_control.h: Likewise.
13950 * include/grub/efi/disk.h: Likewise.
13951 * include/grub/efi/efi.h: Likewise.
13952 * include/grub/efi/pe32.h: Likewise.
13953 * include/grub/efi/time.h: Likewise.
13954 * include/grub/i386/linux.h: Likewise.
13955 * include/grub/i386/setjmp.h: Likewise.
13956 * include/grub/i386/types.h: Likewise.
13957 * include/grub/i386/efi/kernel.h: Likewise.
13958 * include/grub/i386/efi/loader.h: Likewise.
13959 * include/grub/i386/efi/time.h: Likewise.
13960 * include/grub/i386/pc/biosdisk.h: Likewise.
13961 * include/grub/i386/pc/boot.h: Likewise.
13962 * include/grub/i386/pc/chainloader.h: Likewise.
13963 * include/grub/i386/pc/console.h: Likewise.
13964 * include/grub/i386/pc/init.h: Likewise.
13965 * include/grub/i386/pc/kernel.h: Likewise.
13966 * include/grub/i386/pc/loader.h: Likewise.
13967 * include/grub/i386/pc/memory.h: Likewise.
13968 * include/grub/i386/pc/multiboot.h: Likewise.
13969 * include/grub/i386/pc/serial.h: Likewise.
13970 * include/grub/i386/pc/time.h: Likewise.
13971 * include/grub/i386/pc/vbe.h: Likewise.
13972 * include/grub/i386/pc/vbeblit.h: Likewise.
13973 * include/grub/i386/pc/vbefill.h: Likewise.
13974 * include/grub/i386/pc/vbeutil.h: Likewise.
13975 * include/grub/i386/pc/vga.h: Likewise.
13976 * include/grub/ieee1275/ieee1275.h: Likewise.
13977 * include/grub/ieee1275/ofdisk.h: Likewise.
13978 * include/grub/powerpc/libgcc.h: Likewise.
13979 * include/grub/powerpc/setjmp.h: Likewise.
13980 * include/grub/powerpc/types.h: Likewise.
13981 * include/grub/powerpc/ieee1275/biosdisk.h: Likewise.
13982 * include/grub/powerpc/ieee1275/console.h: Likewise.
13983 * include/grub/powerpc/ieee1275/ieee1275.h: Likewise.
13984 * include/grub/powerpc/ieee1275/kernel.h: Likewise.
13985 * include/grub/powerpc/ieee1275/loader.h: Likewise.
13986 * include/grub/powerpc/ieee1275/multiboot.h: Likewise.
13987 * include/grub/powerpc/ieee1275/time.h: Likewise.
13988 * include/grub/powerpc/ieee1275/util/biosdisk.h: Likewise.
13989 * include/grub/sparc64/libgcc.h: Likewise.
13990 * include/grub/sparc64/setjmp.h: Likewise.
13991 * include/grub/sparc64/types.h: Likewise.
13992 * include/grub/sparc64/ieee1275/console.h: Likewise.
13993 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
13994 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
13995 * include/grub/sparc64/ieee1275/time.h: Likewise.
13996 * include/grub/util/biosdisk.h: Likewise.
13997 * include/grub/util/getroot.h: Likewise.
13998 * include/grub/util/lvm.h: Likewise.
13999 * include/grub/util/misc.h: Likewise.
14000 * include/grub/util/raid.h: Likewise.
14001 * include/grub/util/resolve.h: Likewise.
14002 * io/gzio.c: Likewise.
14003 * kern/device.c: Likewise.
14004 * kern/disk.c: Likewise.
14005 * kern/dl.c: Likewise.
14006 * kern/elf.c: Likewise.
14007 * kern/env.c: Likewise.
14008 * kern/err.c: Likewise.
14009 * kern/file.c: Likewise.
14010 * kern/fs.c: Likewise.
14011 * kern/loader.c: Likewise.
14012 * kern/main.c: Likewise.
14013 * kern/misc.c: Likewise.
14014 * kern/mm.c: Likewise.
14015 * kern/parser.c: Likewise.
14016 * kern/partition.c: Likewise.
14017 * kern/rescue.c: Likewise.
14018 * kern/term.c: Likewise.
14019 * kern/efi/efi.c: Likewise.
14020 * kern/efi/init.c: Likewise.
14021 * kern/efi/mm.c: Likewise.
14022 * kern/i386/dl.c: Likewise.
14023 * kern/i386/efi/init.c: Likewise.
14024 * kern/i386/efi/startup.S: Likewise.
14025 * kern/i386/pc/init.c: Likewise.
14026 * kern/i386/pc/lzo1x.S: Likewise.
14027 * kern/i386/pc/startup.S: Likewise.
14028 * kern/ieee1275/ieee1275.c: Likewise.
14029 * kern/powerpc/cache.S: Likewise.
14030 * kern/powerpc/dl.c: Likewise.
14031 * kern/powerpc/ieee1275/cmain.c: Likewise.
14032 * kern/powerpc/ieee1275/crt0.S: Likewise.
14033 * kern/powerpc/ieee1275/init.c: Likewise.
14034 * kern/powerpc/ieee1275/openfw.c: Likewise.
14035 * kern/sparc64/cache.S: Likewise.
14036 * kern/sparc64/dl.c: Likewise.
14037 * kern/sparc64/ieee1275/init.c: Likewise.
14038 * kern/sparc64/ieee1275/openfw.c: Likewise.
14039 * loader/efi/chainloader.c: Likewise.
14040 * loader/efi/chainloader_normal.c: Likewise.
14041 * loader/i386/efi/linux.c: Likewise.
14042 * loader/i386/efi/linux_normal.c: Likewise.
14043 * loader/i386/pc/chainloader.c: Likewise.
14044 * loader/i386/pc/chainloader_normal.c: Likewise.
14045 * loader/i386/pc/linux.c: Likewise.
14046 * loader/i386/pc/linux_normal.c: Likewise.
14047 * loader/i386/pc/multiboot.c: Likewise.
14048 * loader/i386/pc/multiboot_normal.c: Likewise.
14049 * loader/powerpc/ieee1275/linux.c: Likewise.
14050 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
14051 * normal/arg.c: Likewise.
14052 * normal/cmdline.c: Likewise.
14053 * normal/command.c: Likewise.
14054 * normal/completion.c: Likewise.
14055 * normal/execute.c: Likewise.
14056 * normal/function.c: Likewise.
14057 * normal/lexer.c: Likewise.
14058 * normal/main.c: Likewise.
14059 * normal/menu.c: Likewise.
14060 * normal/menu_entry.c: Likewise.
14061 * normal/misc.c: Likewise.
14062 * normal/parser.y: Likewise.
14063 * normal/script.c: Likewise.
14064 * normal/i386/setjmp.S: Likewise.
14065 * normal/powerpc/setjmp.S: Likewise.
14066 * normal/sparc64/setjmp.S: Likewise.
14067 * partmap/acorn.c: Likewise.
14068 * partmap/amiga.c: Likewise.
14069 * partmap/apple.c: Likewise.
14070 * partmap/gpt.c: Likewise.
14071 * partmap/pc.c: Likewise.
14072 * partmap/sun.c: Likewise.
14073 * term/gfxterm.c: Likewise.
14074 * term/terminfo.c: Likewise.
14075 * term/efi/console.c: Likewise.
14076 * term/i386/pc/console.c: Likewise.
14077 * term/i386/pc/serial.c: Likewise.
14078 * term/i386/pc/vesafb.c: Likewise.
14079 * term/i386/pc/vga.c: Likewise.
14080 * term/ieee1275/ofconsole.c: Likewise.
14081 * util/biosdisk.c: Likewise.
14082 * util/console.c: Likewise.
14083 * util/genmoddep.c: Likewise.
14084 * util/getroot.c: Likewise.
14085 * util/grub-emu.c: Likewise.
14086 * util/grub-mkdevicemap.c: Likewise.
14087 * util/grub-probe.c: Likewise.
14088 * util/lvm.c: Likewise.
14089 * util/misc.c: Likewise.
14090 * util/raid.c: Likewise.
14091 * util/resolve.c: Likewise.
14092 * util/update-grub.in: Likewise.
14093 * util/update-grub_lib.in: Likewise.
14094 * util/grub.d/00_header.in: Likewise.
14095 * util/grub.d/10_hurd.in: Likewise.
14096 * util/grub.d/10_linux.in: Likewise.
14097 * util/i386/efi/grub-install.in: Likewise.
14098 * util/i386/efi/grub-mkimage.c: Likewise.
14099 * util/i386/pc/grub-install.in: Likewise.
14100 * util/i386/pc/grub-mkimage.c: Likewise.
14101 * util/i386/pc/grub-mkrescue.in: Likewise.
14102 * util/i386/pc/grub-setup.c: Likewise.
14103 * util/i386/pc/misc.c: Likewise.
14104 * util/powerpc/ieee1275/grub-install.in: Likewise.
14105 * util/powerpc/ieee1275/grub-mkimage.c: Likewise.
14106 * util/powerpc/ieee1275/misc.c: Likewise.
14107 * video/bitmap.c: Likewise.
14108 * video/video.c: Likewise.
14109 * video/i386/pc/vbe.c: Likewise.
14110 * video/i386/pc/vbeblit.c: Likewise.
14111 * video/i386/pc/vbefill.c: Likewise.
14112 * video/i386/pc/vbeutil.c: Likewise.
14113 * video/readers/tga.c: Likewise.
14114
3572d015 141152007-07-02 Robert Millan <rmh@aybabtu.com>
14116
14117 * conf/i386-efi.rmk: Replace obsolete reference to
14118 util/i386/pc/biosdisk.c with util/biosdisk.c, and util/i386/pc/getroot.c
14119 with util/getroot.c.
14120 * conf/powerpc-ieee1275.rmk: Likewise.
14121 * conf/sparc64-ieee1275.rmk: Likewise.
14122
14123 * util/grub-emu.c (main): Fix unchecked pointer handling.
14124
2c2a681b 141252007-07-02 Robert Millan <rmh@aybabtu.com>
14126
14127 * util/i386/efi/grub-install.in: Allow `grub_probe --target=partmap'
14128 invocation to fail, in order to support partition-less media.
14129
14130 * util/i386/pc/grub-install.in: Likewise.
14131
14132 * util/powerpc/ieee1275/grub-install.in: Use grub-probe to determine
14133 which fs or partmap modules are needed (akin to its sister scripts).
14134
14135 Also use grub-probe to get rid of unportable /proc/mounts check.
14136
14137 Print the same informational message that the other scripts do, before
fe6b695a 14138 exiting.
2c2a681b 14139
6193defe 141402007-06-23 Robert Millan <rmh@aybabtu.com>
14141
fe6b695a 14142 * util/update-grub_lib.in (font_path): New function. Determine whether
6193defe 14143 a font file can be found and, if so, echo the GRUB path to it.
14144
14145 * util/update-grub.in: Handle multiple terminals depending on user
14146 input, platform availability and font file presence. Propagate
14147 variables of our findings to /etc/grub.d/ children.
14148
14149 * util/grub.d/00_header.in: Handle multiple terminals, based on
14150 environment setup by update-grub.
14151
eface1dc 141522007-06-23 Robert Millan <rmh@aybabtu.com>
14153
ba50d28f 14154 * conf/i386-pc.rmk (pkgdata_MODULES): Add serial.mod.
eface1dc 14155
bf697e28 141562007-06-21 Robert Millan <rmh@aybabtu.com>
14157
14158 * include/grub/i386/pc/kernel.h: Define GRUB_KERNEL_MACHINE_DATA_END to
14159 indicate end of data section in kernel image.
14160 * include/grub/i386/efi/kernel.h: Define GRUB_KERNEL_MACHINE_PREFIX and
14161 GRUB_KERNEL_MACHINE_DATA_END.
14162
14163 * kern/i386/pc/startup.S: Do not initialize grub_prefix, only reserve
14164 space for it.
14165 * kern/i386/efi/startup.S: Likewise.
14166
14167 * util/i386/pc/grub-mkimage.c: Initialize grub_prefix to /boot/grub
14168 during image generation. Implement --prefix option to override this
14169 patch.
14170 * util/i386/efi/grub-mkimage.c: Likewise.
14171
14172 * util/update-grub_lib.in (convert_system_path_to_grub_path): Split
14173 code to make path relative to its root into a separate function.
14174
14175 * util/i386/pc/grub-install.in: Use newly provided
14176 make_system_path_relative_to_its_root() to convert ${grubdir}, then
14177 pass the result to grub-install --prefix.
14178
baa574b4 141792007-06-13 Robert Millan <rmh@aybabtu.com>
14180
14181 * include/grub/util/misc.h: Define DEFAULT_DIRECTORY and
14182 DEFAULT_DEVICE_MAP.
14183 * util/grub-emu.c: Use above definitions from misc.h instead of
14184 defining them.
14185 * util/grub-mkdevicemap.c: Likewise.
14186 * util/i386/pc/grub-setup.c: Likewise.
14187 * util/grub-probe.c: Likewise.
14188 (probe): Abort with grub_util_error() when either
14189 grub_guess_root_device or grub_util_get_grub_dev fails.
14190
0215dcbf 141912007-06-12 Robert Millan <rmh@aybabtu.com>
14192
14193 * normal/command.c (grub_command_execute): Use NULL rather than 0 for
14194 "pager" assignment.
14195 * util/biosdisk.c (grub_util_biosdisk_get_grub_dev): Likewise for
14196 "pcdata".
14197 * util/grub-probe.c (probe): Likewise for "drive_name".
14198
8af2ab7b 141992007-06-11 Robert Millan <rmh@aybabtu.com>
14200
14201 * util/i386/pc/grub-mkrescue.in: Pad both floppy images with zeroes,
14202 not just the cdrom one.
14203
59d31694 142042007-06-11 Robert Millan <rmh@aybabtu.com>
14205
14206 * util/i386/pc/grub-mkrescue.in: Add "set -e".
14207 Add --pkglibdir=DIR option to override pkglibdir.
14208 Mention --image-type=TYPE in help output.
14209 Fix --grub-mkimage (it was a no-op).
fe6b695a 14210 Abort gracefully when no parameter is given.
59d31694 14211
7ee367e4 142122007-06-11 Robert Millan <rmh@aybabtu.com>
14213
14214 * util/i386/pc/grub-mkrescue.in: New file.
14215 * conf/i386-pc.rmk: Add its build declarations. Put it in bin_SCRIPTS.
14216 * Makefile.in: Handle bin_SCRIPTS.
14217
29b0ed46 142182007-06-10 Vesa Jaaskelainen <chaac@nic.fi>
14219
14220 * term/gfxterm.c (grub_gfxterm_init): Added support for specifying
14221 list of video modes.
14222
c0f90770 142232007-06-06 Robert Millan <rmh@aybabtu.com>
14224
14225 * util/update-grub_lib.in (convert_system_path_to_grub_path): Abort if
14226 file doesn't exist, or if it is in a filesystem grub can't read.
14227
14228 * util/update-grub.in: Set fallback for GRUB_FS check to "unknown". Do
14229 not abort if GRUB_DRIVE could not be defined. Rearrange generated
14230 header comment to fit in 80 columns when the variables are resolved.
14231
14232 * util/grub.d/00_header.in: Only set root variable when GRUB_DRIVE
14233 could be identified by update-grub. Remove redundant check for
fe6b695a 14234 unifont.pff existence (since convert_system_path_to_grub_path now
c0f90770 14235 handles that).
14236
fb36dc26 142372007-06-04 Robert Millan <rmh@aybabtu.com>
14238
14239 * conf/i386-efi.rmk (grub_probe_SOURCES): Add partmap/apple.c.
14240
14241 * conf/i386-pc.rmk (grub_probe_SOURCES): Likewise.
14242
14243 * conf/powerpc-ieee1275.rmk (grub_probe_SOURCES): Add partmap/pc.c.
14244
0c68c93e 142452007-06-04 Robert Millan <rmh@aybabtu.com>
14246
14247 * conf/powerpc-ieee1275.rmk: Enable grub-mkdevicemap and grub-probe.
14248
14249 * include/grub/partition.h: Declare grub_apple_partition_map_init and
14250 grub_apple_partition_map_fini.
14251
14252 * util/biosdisk.c
14253 (grub_util_biosdisk_open): Replace BLKGETSIZE with BLKGETSIZE64 (needed
14254 to access >2 TiB disks).
14255
14256 Print disk->total_sectors with %llu instead of %lu, since this
14257 variable is always 64-bit (prevents wrong disk size from being displayed
14258 on either >2 TiB disk or big-endian CPU).
14259
14260 (grub_util_biosdisk_get_grub_dev): Convert gpt_partition_map handling
14261 into a generic case that supports all (sane) partition maps.
14262
14263 Stop using grub_cpu_to_le32() on dos_part / bsd_part since it actually
14264 breaks big-endian.
14265
14266 * util/grub-probe.c: Call grub_apple_partition_map_init() before probe()
14267 and grub_apple_partition_map_fini() after that.
14268
0f23eb74 142692007-06-01 Robert Millan <rmh@aybabtu.com>
14270
14271 * util/update-grub.in: Export GRUB_CMDLINE_LINUX.
14272
14273 * util/grub.d/00_header.in: Only enable gfxterm when
14274 convert_system_path_to_grub_path() succeeds.
14275
42c71976 142762007-05-20 Robert Millan <rmh@aybabtu.com>
14277
14278 * util/update-grub_lib.in: New file.
14279 * DISTLIST: Add update-grub_lib.in.
14280 * conf/common.rmk: Generate update-grub_lib and install it in
14281 $(lib_DATA).
14282 * Makefile.in: Add install routine for $(lib_DATA).
14283
14284 * util/grub.d/00_header.in: Use convert_system_path_to_grub_path()
14285 function provided by update-grub_lib to support arbitrary paths of
14286 unifont.pff.
14287 * util/update-grub.in: Use convert_system_path_to_grub_path() to
14288 initialize GRUB_DRIVE_BOOT and GRUB_DRIVE_BOOT_GRUB variables.
14289
5beb2291 142902007-05-19 Robert Millan <rmh@aybabtu.com>
14291
14292 * commands/i386/cpuid.c: New module.
14293 * DISTLIST: Add it.
14294 * conf/i386-efi.rmk: Enable cpuid.mod.
14295 * conf/i386-pc.rmk: Likewise.
14296
7262eca1 142972007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
14298
14299 * kern/disk.c (grub_disk_read): Check return value of
14300 grub_realloc().
14301
260ba823 143022007-05-18 Jeroen Dekkers <jeroen@dekkers.cx>
14303
14304 * util/getroot.c (grub_util_get_grub_dev): Support partitionable
14305 arrays.
14306 * disk/raid.c (grub_raid_open): Likewise.
14307
1ecb6cf2 143082007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
14309
14310 * util/biosdisk.c (linux_find_partition): Allocate real_dev on the
14311 stack instead of on the heap.
14312
14313 * kern/disk.c (grub_disk_read): Make sure tmp_buf is big enough
14314 before doing a read on it.
14315
14316 * configure.ac: Only use -fno-stack-protector for the target
14317 environment.
f19dbdb7 14318
21c8cbb1 143192007-05-17 Jeroen Dekkers <jeroen@dekkers.cx>
14320
14321 * video/i386/pc/vbe.c (grub_video_vbe_create_render_target): Add
14322 __attribute_ ((unused)) to mode_type argument.
14323
14324 * util/getroot.c (grub_guess_root_device): Fix #endif.
f19dbdb7 14325
21c8cbb1 14326 * kern/misc.c (memcmp): Fix prototype.
14327
14328 * include/grub/partition.h [GRUB_UTIL]
14329 (grub_gpt_partition_map_init): Add prototype.
14330 (grub_gpt_partition_map_fini): Likewise.
14331
14332 * fs/jfs.c (struct grub_jfs_inode): Put __attribute__ ((packed)
14333 at the right place.
14334
14335 * fs/fat.c (grub_fat_mount): Replace ~0UL with ~0U.
14336 (grub_fat_read_data): Likewise.
14337 (grub_fat_find_dir): Likewise.
14338
14339 * font/manager.c (find_glyph): Make table a const.
14340 (grub_font_get_glyph): Remove bitmap from if statement.
f19dbdb7 14341
849d55d3 143422007-05-16 Jeroen Dekkers <jeroen@dekkers.cx>
14343
14344 * util/getroot.c (grub_guess_root_device): Remove RAID and LVM
14345 code, first search for device in /dev/mapper, then in /dev.
14346 (grub_util_get_grub_dev): New function.
14347 * include/grub/util/getroot.h (grub_util_get_grub_dev): Add
14348 prototype.
14349 * util/grub-probe.c (probe): Remove check for RAID, call
14350 grub_util_get_grub_dev() instead of
14351 grub_util_biosdisk_get_grub_dev().
14352 * util/grub-emu.c (main): Call grub_util_get_grub_dev() instead of
14353 grub_util_biosdisk_get_grub_dev().
14354 * util/i386/pc/grub-setup.c (main): Likewise.
14355
8fff7c2f 143562007-05-16 Robert Millan <rmh@aybabtu.com>
14357
14358 * DISTLIST: Update for the latest changes.
14359 * conf/i386-pc.rmk: Use the new paths for util/getroot.c,
14360 util/grub-mkdevicemap.c, util/grub-probe.c and util/biosdisk.c.
14361 * util/grub-emu.c: Replace grub/i386/pc/util/biosdisk.h with
14362 grub/util/biosdisk.h.
14363 * util/i386/pc/grub-setup.c: Replace grub/machine/util/biosdisk.h with
14364 grub/util/biosdisk.h.
14365
48e12b52 143662007-05-16 Robert Millan <rmh@aybabtu.com>
14367
14368 * util/grub.d/00_header.in: Set default gfxmode to `640x480'.
14369
46b9d128 143702007-05-16 Robert Millan <rmh@aybabtu.com>
14371
14372 * util/i386/efi/grub-install.in: New.
14373 * conf/i386-efi.rmk: Enable grub-mkdevicemap, grub-probe and the
14374 newly added grub-install.
14375 * util/biosdisk.c: Remove unnecessary grub/machine/biosdisk.h
14376 include.
14377 * util/getroot.c: Replace grub/i386/pc/util/biosdisk.h with
14378 grub/util/biosdisk.h.
14379 * util/grub-probe.c: Replace grub/machine/util/biosdisk.h with
14380 grub/util/biosdisk.h.
14381
2d1a40a9 143822007-05-16 Robert Millan <rmh@aybabtu.com>
14383
14384 * include/grub/i386/pc/util/biosdisk.h: Moved to ...
14385 * include/grub/util/biosdisk.h: ... here.
14386 * util/i386/pc/biosdisk.c: Moved to ...
14387 * util/biosdisk.c: ... here.
14388 * util/i386/pc/getroot.c: Moved to ...
14389 * util/getroot.c: ... here.
14390 * util/i386/pc/grub-mkdevicemap.c: Moved to ...
14391 * util/grub-mkdevicemap.c: ... here.
14392 * util/i386/pc/grub-probe.c: Moved to ...
14393 * util/grub-probe.c: ... here.
14394
9e26e3bc 143952007-05-15 Robert Millan <rmh@aybabtu.com>
14396
14397 * util/update-grub.in: Remove duplicated line in grub.cfg header
14398 message.
14399
57f96397 144002007-05-13 Robert Millan <rmh@aybabtu.com>
14401
14402 * util/update-grub.in: Fix a few assumptions about the devices holding
14403 /, /boot and /boot/grub being the same.
14404 * util/grub.d/00_header.in: Likewise.
14405 * util/grub.d/10_hurd.in: Likewise.
14406 * util/grub.d/10_linux.in: Likewise.
14407
14408 * util/grub.d/10_linux.in: Implement Linux image sorting with arbitrary
14409 patterns. Use that to define the `.old' suffix as older than `'.
14410
14411 * util/grub.d/00_header.in: Set default gfxmode to `800x600x16'.
14412
14413 * util/update-grub.in: Add a reference to ${sysconfdir}/default/grub in
14414 the grub.cfg header message.
14415
2e610d62 144162007-05-11 Robert Millan <rmh@aybabtu.com>
14417
14418 * util/update-grub.in: Create device.map if it doesn't already exist,
14419 before attempting to run grub-probe.
14420 Check for grub-probe and grub-mkdevicemap with the same code
14421 grub-install is using.
14422 Remove test mode.
14423
3f6a10ef 144242007-05-09 Jeroen Dekkers <jeroen@dekkers.cx>
14425
14426 * Makefile.in: Add the datarootdir autoconf variable.
14427
02e7b75e 144282007-05-09 Robert Millan <rmh@aybabtu.com>
14429
14430 * util/i386/pc/grub-probe.c (probe): When detecting partition map,
f19dbdb7 14431 fail gracefully if dev->disk->partition == NULL.
02e7b75e 14432
75f396cc 144332007-05-07 Robert Millan <rmh@aybabtu.com>
14434
14435 * util/i386/pc/grub-probe.c: Add `grub-probe -t partmap' parameter to
14436 determine partition map module.
14437 * util/i386/pc/grub-install.in: Use this feature to decide which
14438 partition module to load, instead of hardcoding pc and gpt.
14439
da65cb36 144402007-05-07 Robert Millan <rmh@aybabtu.com>
14441
14442 * Makefile.in: Fix assumption that $(srcdir) has a trailing slash when
14443 source directory differs from build directory.
14444
b57d6a91 144452007-05-05 Robert Millan <rmh@aybabtu.com>
14446
14447 * util/powerpc/ieee1275/grub-install.in: Fix syntax error in pkglibdir
14448 initialisation.
14449
509d00f1 144502007-05-05 Robert Millan <rmh@aybabtu.com>
14451
14452 * util/update-grub.in: Create ${grub_prefix} if it doesn't exist.
14453
c48f23ef 144542007-05-05 Robert Millan <rmh@aybabtu.com>
14455
14456 * util/grub.d/10_linux.in: Allow the administrator to insert Linux
14457 command-line arguments via ${GRUB_CMDLINE_LINUX}.
14458
20b97658 144592007-05-05 Robert Millan <rmh@aybabtu.com>
14460
14461 * conf/i386-pc.rmk (grub_setup_SOURCES): Add partmap/gpt.c.
14462 (grub_probe_SOURCES): Likewise.
14463 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): Detect
14464 GPT and initialize dos_part and bsd_part accordingly.
14465 * util/i386/pc/grub-setup.c (setup): Ditto for install_dos_part and
14466 install_bsd_part.
14467 (main): Activate gpt module for use during partition identification,
14468 and deactivate it afterwards.
14469 * util/i386/pc/grub-install.in: Add gpt module to core.img.
14470 * util/i386/pc/grub-probe.c (main): Activate gpt module for use during
14471 partition identification, and deactivate it afterwards.
14472
99123174 144732007-05-05 Robert Millan <rmh@aybabtu.com>
14474
14475 * term/i386/pc/console.c (grub_console_fini): Call
14476 grub_term_set_current() before grub_term_unregister().
14477
ebd97f6e 144782007-05-04 Robert Millan <rmh@aybabtu.com>
14479
14480 * DISTLIST: Add util/update-grub.in, util/grub.d/00_header.in,
14481 util/grub.d/10_hurd.in, util/grub.d/10_linux.in and util/grub.d/README.
14482 * Makefile.in: Build update-grub_SCRIPTS. Install update-grub_SCRIPTS
14483 and update-grub_DATA.
14484 * conf/common.rmk: Build and install update-grub components.
14485 * conf/common.mk: Regenerate.
14486 * util/update-grub.in: New. Core of update-grub.
14487 * util/grub.d/00_header.in: New. Generates grub.cfg header.
14488 * util/grub.d/10_hurd.in: New. Generates boot entries for the Hurd.
14489 * util/grub.d/10_linux.in: New. Generates boot entries for Linux.
14490 * util/grub.d/README: New. Document grub.d directory layout.
14491
b06a264d 144922007-05-01 Robert Millan <rmh@aybabtu.com>
14493
14494 * util/grub-emu.c: Move initialization functions
14495 grub_util_biosdisk_init() and grub_init_all() before
14496 grub_util_biosdisk_get_grub_dev(), which relies on them.
14497
41f0050e 144982007-04-19 Robert Millan <rmh@aybabtu.com>
14499
14500 * util/powerpc/ieee1275/grub-install.in: Initialize ${bindir}, since
14501 it is used later.
14502
04582bb3 145032007-04-18 Jerone Young <jerone@gmail.com>
14504
f19dbdb7 14505 * kernel/elf.c: Add missing parenthesis for conditional statement
04582bb3 14506 stanza.
14507
08db4632 145082007-04-10 Jerone Young <jerone@gmail.com>
49892fdf 14509
08db4632 14510 * util/i386/pc/getroot.c: Update so that if root device is /dev/root ,
14511 continue on and look for device node with real device name.
14512
801b76be 145132007-04-10 Jerone Young <jerone@gmail.com>
f19dbdb7 14514
fe6b695a 14515 * configure.ac: Add argument for autoconf to use transformation
1d543c3e 14516 ability.
14517 * Makefile.in: Add autoconf package transformation code.
14518 * util/i386/pc/grub-install.in: Likewise.
14519 * util/powerpc/ieee1275/grub-install.in: Likewise.
14520
6795c4e1 145212007-03-19 Yoshinori K. Okuji <okuji@enbug.org>
14522
14523 * fs/ext2.c (EXT2_GOOD_OLD_REVISION): New macro.
14524 (EXT2_GOOD_OLD_INODE_SIZE): Likewise.
14525 (EXT2_REVISION): Likewise.
14526 (EXT2_INODE_SIZE): Likewise.
14527 (struct grub_ext2_block_group): Added a missing member
14528 "used_dirs".
14529 (grub_ext2_read_inode): Divide by the inode size in a superblock
14530 instead of 128 to obtain INODES_PER_BLOCK.
14531 Use the macro EXT2_INODE_SIZE instead of directly using
14532 SBLOCK->INODE_SIZE.
14533
d70af616 145342007-03-18 Yoshinori K. Okuji <okuji@enbug.org>
14535
14536 * fs/ext2.c (grub_ext2_read_inode): Use the inode size in a
14537 superblock instead of the structure size to compute an
14538 offset. This fixes the problem that GRUB could not read a
14539 filesystem when inode size is different from 128-byte.
14540
3b801603 145412007-03-05 Marco Gerards <marco@gnu.org>
14542
14543 * normal/main.c (read_config_file): When "menu" is not set, create
14544 an initial context.
14545
4785bfe4 145462007-02-21 Hollis Blanchard <hollis@penguinppc.org>
14547
14548 * kern/powerpc/ieee1275/init.c (HEAP_SIZE): Removed.
14549 (HEAP_LIMIT): New macro.
14550 (grub_claim_heap): Claim memory up to `heaplimit'.
14551
a0cbb023 145522007-02-21 Hollis Blanchard <hollis@penguinppc.org>
14553
14554 * conf/powerpc-ieee1275.rmk (kernel_elf_LDFLAGS): Link at 64KB.
14555 * kern/powerpc/ieee1275/init.c (_end): Add declaration.
14556 (_start): Likewise.
14557 (grub_arch_modules_addr): Return address after `_end'.
14558 * util/powerpc/ieee1275/grub-mkimage.c: Include grub/misc.h.
14559 (load_modules): Use new parameter as `p_paddr' and `p_vaddr'.
14560 (add_segments): Calculate `_end' from phdr size and location.
14561 (ALIGN_UP): Moved to ...
14562 * include/grub/misc.h: here.
14563 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MOD_ALIGN):
14564 New macro.
14565 (GRUB_IEEE1275_MODULE_BASE): Removed.
14566
fd7d8eba 145672007-02-20 Hollis Blanchard <hollis@penguinppc.org>
14568
14569 * kern/powerpc/ieee1275/openfw.c (grub_available_iterate): Correct
14570 loop boundary.
14571
9b09e6fc 145722007-02-20 Hollis Blanchard <hollis@penguinppc.org>
14573
14574 * include/grub/elfload.h (grub_elf32_load_hook_t): Return grub_err_t.
14575 All users updated.
14576 (grub_elf64_load_hook_t): Likewise.
14577 * kern/elf.c: Call `grub_error_push' before `grub_error'. Improve
14578 debug output.
14579
3ce27299 145802007-02-20 Hollis Blanchard <hollis@penguinppc.org>
14581
14582 * kern/mm.c: Update copyright.
14583 (grub_mm_debug): Correct syntax error.
14584 (grub_mm_dump_free): New function.
14585 (grub_debug_free): Call `grub_free'.
14586 * include/grub/mm.h: Update copyright.
14587 (grub_mm_dump_free): Add declaration.
14588
077d5fee 145892007-02-12 Hollis Blanchard <hollis@penguinppc.org>
14590
14591 * include/grub/ieee1275/ieee1275.h: Update copyright.
14592 * kern/powerpc/ieee1275/init.c: Likewise.
14593 * kern/powerpc/ieee1275/openfw.c: Likewise.
14594
14595 * loader/powerpc/ieee1275/linux.c: Likewise.
14596 * include/grub/elfload.h: Likewise.
14597 * kern/elf.c: Likewise.
14598 (grub_elf32_load): Pass `base' and `size' parameters. Update all
14599 callers.
14600 (grub_elf64_load): Likewise.
14601 (grub_elf32_load_segment): Move to a nested function.
14602 (grub_elf64_load_segment): Likewise.
14603
dc946850 146042007-02-12 Hollis Blanchard <hollis@penguinppc.org>
14605
14606 * include/grub/ieee1275/ieee1275.h (grub_available_iterate): New
14607 prototype.
14608 * kern/powerpc/ieee1275/init.c (grub_heap_start): Removed.
14609 (grub_heap_len): Likewise.
14610 (HEAP_SIZE): New macro.
14611 (grub_claim_heap): New function.
14612 (grub_machine_init): Don't claim heap directly. Call
14613 `grub_claim_heap'.
14614 * kern/powerpc/ieee1275/openfw.c: Include alloca.h.
14615 (grub_available_iterate): New function.
14616
baa2a121 146172007-02-03 Thomas Schwinge <tschwinge@gnu.org>
14618
14619 * aclocal.m4 (grub_CHECK_STACK_PROTECTOR): New definition.
14620 * configure.ac: Use it for testing the HOST and TARGET compilers.
14621
4fe9862e 146222006-12-13 Thomas Schwinge <tschwinge@gnu.org>
14623
14624 * Makefile.in (enable_grub_emu): New variable.
14625 * configure.ac (--enable-grub-emu): New option.
14626 Do the checks for (n)curses only if `--enable-grub-emu' is requested.
14627 * conf/i386-efi.rmk (sbin_UTILITIES): Add `grub-emu' only if requested.
14628 * conf/i386-pc.rmk: Likewise.
14629 * conf/powerpc-ieee1275.rmk: Likewise.
14630 * conf/sparc64-ieee1275.rmk (bin_UTILITIES): Likewise.
14631
a8aa5762 146322006-12-12 Marco Gerards <marco@gnu.org>
14633
14634 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_MENU'.
14635
14636 * kern/env.c (grub_env_unset): Don't free the member `value' when
14637 the type is GRUB_ENV_VAR_DATA, in this case it's a user defined
14638 pointer.
14639
14640 * normal/main.c (current_menu): Removed.
14641 (free_menu): Unset the `menu' environment variable.
14642 (grub_normal_menu_addentry): Make use of the environment variable
14643 `menu', instead of using the global `current_menu'. Allocate
14644 memory for the sourcecode of this entry.
14645 (read_config_file): New argument `nested', changed all callers.
14646 Only in the case of a new context, initialize a new menu. Set the
14647 `menu' environment variable.
14648 (grub_normal_execute): Don't set and unset the environment
14649 variable `menu' here anymore. Only free the menu when leaving the
14650 context.
14651
14652 * util/i386/pc/biosdisk.c (linux_find_partition): Fixed a memory
14653 leak.
14654
957b3a3e 146552006-12-11 Marco Gerards <marco@gnu.org>
14656
14657 * normal/menu_entry.c (run): Fix off by one bug so the last line
14658 is executed. Move the loader check to outside the loop.
14659
ef875714 146602006-12-08 Hollis Blanchard <hollis@penguinppc.org>
14661
14662 * kern/powerpc/ieee1275/cmain.c (cmain): Mark r3 and r4 as `UNUSED'.
14663
4e739985 146642006-11-25 Yoshinori K. Okuji <okuji@enbug.org>
14665
14666 * util/i386/pc/grub-mkimage.c (generate_image): Fix the offset of
14667 the number of sectors. Reported by Andrey Shuvikov
14668 <mr_hyro@yahoo.com>.
f19dbdb7 14669
790707f2 146702006-11-11 Jeroen Dekkers <jeroen@dekkers.cx>
14671
14672 * kern/disk.c (grub_disk_read): When there is a read error, always
14673 try to read only the necessary data.
f19dbdb7 14674
790707f2 14675 * conf/i386-pc.rmk (grub_probe_SOURCES): Add disk/lvm.c and
14676 disk/raid.c.
14677 * include/grub/disk.h [GRUB_UTIL] (grub_raid_init): New
14678 prototype.
14679 [GRUB_UTIL] (grub_raid_fini): Likewise.
14680 [GRUB_UTIL] (grub_lvm_init): Likewise.
f19dbdb7 14681 [GRUB_UTIL] (grub_lvm_fini): Likewise.
790707f2 14682 * util/i386/pc/grub-probe.c (probe): Check whether DEVICE_NAME is
14683 RAID device and copy DEVICE_NAME to DRIVE_NAME in that case.
14684 (main): Call grub_raid_init(), grub_lvm_init(), grub_lvm_fini()
14685 and grub_raid_fini().
f19dbdb7 14686
03e58196 146872006-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
14688
14689 * include/grub/types.h (__unused): Rename to UNUSED.
14690 * kern/elf.c (grub_elf32_size): Use UNUSED instead of __unused.
14691 (grub_elf64_size): Likewise.
f19dbdb7 14692
ae4f23bf 146932006-11-03 Hollis Blanchard <hollis@penguinppc.org>
14694
14695 * kern/elf.c (grub_elf_file): Call grub_file_seek. Call
14696 grub_error_push and grub_error_pop in the error-handling path.
14697 (grub_elf32_load_segment): Only call grub_file_read with non-zero
14698 length.
14699
2166cc83 147002006-11-03 Hollis Blanchard <hollis@penguinppc.org>
14701
14702 * conf/i386-efi.rmk (grub_emu_SOURCES): Add kern/elf.c.
14703 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
14704 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
14705 (kernel_elf_SOURCES): Likewise.
14706 * conf/i386-efi.rmk (kernel_mod_HEADERS): Add elfload.h and cache.h.
14707 * conf/i386-pc.rmk (kernel_mod_HEADERS): Likewise.
14708 * conf/powerpc-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
14709 * conf/sparc64-ieee1275.rmk (kernel_elf_HEADERS): Likewise.
14710 * conf/common.rmk (pkgdata_MODULES): Add elf.mod.
14711 (elf_mod_SOURCES): New variable.
14712 (elf_mod_CFLAGS): Likewise.
14713 (elf_mod_LDFLAGS): Likewise.
14714 * include/grub/types.h (__unused): New macro.
14715 * include/grub/elfload.h: New file.
14716 * kern/elf.c: Likewise.
14717 * loader/powerpc/ieee1275/linux.c: Include elfload.h.
14718 (ELF32_LOADMASK): New macro.
14719 (ELF64_LOADMASK): Likewise.
14720 (vmlinux): Removed.
14721 (grub_linux_load32): New function.
14722 (grub_linux_load64): Likewise.
14723 (grub_rescue_cmd_linux): Call grub_linux_load32 or grub_linux_load64.
14724 Use grub_elf_t instead of grub_file_t.
14725
a09d5aa5 147262006-11-02 Hollis Blanchard <hollis@penguinppc.org>
14727
14728 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): Add
14729 `catch_result' to struct set_color_args.
14730
d976fc51 147312006-10-28 Yoshinori K. Okuji <okuji@enbug.org>
14732
14733 * normal/menu.c: Include grub/script.h.
14734 * normal/menu_entry.c: Likewise.
14735 * include/grub/normal.h: Do not include grub/script.h.
14736
67507549 147372006-10-27 Hollis Blanchard <hollis@penguinppc.org>
14738
14739 * kern/disk.c (grub_disk_read): Correct debug printf formatting.
14740
69203a99 147412006-10-27 Hollis Blanchard <hollis@penguinppc.org>
14742
14743 * kern/disk.c (grub_disk_open): Print debug messages when opening a
14744 disk.
14745 (grub_disk_close): Print debug messages when closing a disk.
14746 (grub_disk_read): Print debug messages when disk read fails.
14747 * kern/fs.c (grub_fs_probe): Print debug messages when detecting
14748 filesystem type.
14749 * kern/partition.c: Include misc.h.
14750 (grub_partition_iterate): Print debug messages when detecting
14751 partition type.
14752
e2b8278c 147532006-10-27 Hollis Blanchard <hollis@penguinppc.org>
14754
14755 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Return error if `status'
14756 is negative.
14757 * kern/ieee1275/ieee1275.c (IEEE1275_IHANDLE_INVALID): Change to 0.
14758
97b2f2ff 147592006-10-26 Hollis Blanchard <hollis@penguinppc.org>
14760
14761 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_encode_devname):
14762 Reverse GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS test.
14763
6555d655 147642006-10-25 Jeroen Dekkers <jeroen@dekkers.cx>
14765
14766 * disk/lvm.c (grub_lvm_scan_device): Malloc sizeof(*lv) bytes
14767 instead of sizeof(lv). Patch by Michael Guntsche.
14768
4d42b77f 147692006-10-18 Jeroen Dekkers <jeroen@dekkers.cx>
14770
14771 * disk/lvm.c: Rename VGS to VG_LIST.
14772 (grub_lvm_iterate): Change VGS->LV to VG-LV.
14773 (grub_lvm_open): Likewise.
14774 Thanks to Michael Guntsche for finding this bug.
14775
5d74d927 147762006-10-15 Yoshinori K. Okuji <okuji@enbug.org>
14777
14778 * configure.ac (AC_INIT): Bumped to 1.95.
14779
a1bb27e4 147802006-10-14 Robert Millan <rmh@aybabtu.com>
14781
14782 * util/i386/pc/getroot.c (grub_guess_root_device): Don't compare os_dev
14783 with "/dev/.static/dev/md".
14784
e0994b8b 147852006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
14786
14787 * util/i386/pc/grub-probe.c (probe): Print DEVICE_NAME instead of
14788 DRIVE_NAME when grub_util_biosdisk_get_grub_dev fails. Open
14789 DRIVE_NAME instead of DEVICE_NAME. Make sure that DEVICE_NAME and
14790 DRIVE_NAME are always freed.
14791
14792 * util/i386/pc/biosdisk.c (make_device_name): Add one into
14793 DOS_PART, as a DOS partition is counted from one instead of zero
14794 now. Reported by Robert Millan.
14795
ddd5cee9 147962006-10-14 Robert Millan <rmh@aybabtu.com>
14797
14798 * util/i386/pc/getroot.c (grub_guess_root_device): Stop using
14799 grub_util_biosdisk_get_grub_dev to convert system device to GRUB device.
14800 * util/grub-emu.c (main): Use grub_util_biosdisk_get_grub_dev with the
14801 string returned by grub_guess_root_device.
14802 * util/i386/pc/grub-setup.c: Likewise.
14803 * util/i386/pc/grub-probefs.c: Likewise.
14804
14805 * util/i386/pc/grub-probefs.c: Rename to ...
14806 * util/i386/pc/grub-probe.c: ... this.
14807 * DISTLIST: Remove grub-probefs, add grub-probe.
14808 * conf/i386-efi.rmk: Likewise.
14809 * conf/i386-pc.rmk: Likewise.
14810 * util/i386/pc/grub-install.in: Likewise.
14811
14812 * util/i386/pc/grub-probe.c: Add --target=(fs|device|drive) option to
14813 choose which information we want to print.
14814
2b002173 148152006-10-14 Yoshinori K. Okuji <okuji@enbug.org>
14816
14817 * DISTLIST: Added commands/echo.c, disk/lvm.c, disk/raid.c,
14818 include/grub/bitmap.h, include/grub/lvm.h, include/grub/raid.h,
14819 include/grub/i386/pc/vbeutil.h, include/grub/util/lvm.h,
14820 include/grub/util/raid.h, util/lvm.c, util/raid.c, video/bitmap.c,
14821 video/readers/tga.c and video/i386/pc/vbeutil.c.
14822
148232006-10-14 Jeroen Dekkers <jeroen@dekkers.cx>
14824
14825 Added support for RAID and LVM.
f19dbdb7 14826
2b002173 14827 * disk/lvm.c: New file.
14828 * disk/raid.c: Likewise.
14829 * include/grub/lvm.h: Likewise.
f19dbdb7 14830 * include/grub/raid.h: Likewise.
2b002173 14831 * include/grub/util/lvm.h: Likewise.
14832 * include/grub/util/raid.h: Likewise.
14833 * util/lvm.c: Likewise.
14834 * util/raid.c: Likewise.
14835
14836 * include/grub/disk.h (grub_disk_dev_id): Add
14837 GRUB_DISK_DEVICE_RAID_ID and GRUB_DISK_DEVICE_LVM_ID.
14838 (grub_disk_get_size): New prototype.
14839 * kern/disk.c (grub_disk_open): Check whether grub_partition_probe()
14840 returns a partition.
14841 (grub_disk_get_size): New function.
f19dbdb7 14842
2b002173 14843 * kern/i386/pc/init.c (make_install_device): Copy the prefix
14844 verbatim if grub_install_dos_part is -2.
14845
14846 * util/i386/pc/getroot.c (grub_guess_root_device): Support RAID
14847 and LVM devices.
14848
14849 * util/i386/pc/grub-setup.c (setup): New argument
14850 MUST_EMBED. Force embedding of GRUB when the argument is
14851 true. Close FILE before returning.
14852 (main): Add support for RAID and LVM.
f19dbdb7 14853
2b002173 14854 * conf/common.rmk: Add RAID and LVM modules.
14855 * conf/i386-pc.rmk (grub_setup_SOURCES): Add util/raid.c and
14856 util/lvm.c.
14857 (grub_emu_SOURCES): Add disk/raid.c and disk/lvm.c.
14858
14859 * kern/misc.c (grub_strstr): New function.
14860 * include/grub/misc.h (grub_strstr): New prototype.
14861
050548d0 148622006-10-10 Tristan Gingold <tristan.gingold@bull.net>
14863
14864 * include/grub/efi/api.h (GRUB_EFI_ERROR_CODE): Long constant.
14865
da849d2d 148662006-10-05 Tristan Gingold <tristan.gingold@bull.net>
14867
14868 * kern/misc.c (grub_strtoull): Guess the base only if not
14869 specified.
14870
97b2f2ff 148712006-10-01 Hollis Blanchard <hollis@penguinppc.org>
4f0acd39 14872
14873 * kern/powerpc/ieee1275/cmain.c (cmain): Remove incomplete Old World
14874 PowerMac support.
14875
97b2f2ff 148762006-10-01 Hollis Blanchard <hollis@penguinppc.org>
fba51f48 14877
14878 * disk/ieee1275/ofdisk.c (grub_ofdisk_iterate): Cast `size' to long.
14879
14880 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_next_property):
14881 Remove `flags' argument. All callers changed.
14882 * kern/ieee1275/ieee1275.c (IEEE1275_PHANDLE_ROOT): Removed.
14883 (IEEE1275_IHANDLE_INVALID): New variable.
14884 (IEEE1275_CELL_INVALID): New variable.
14885 (grub_ieee1275_finddevice, grub_ieee1275_get_property,
14886 grub_ieee1275_get_property_length, grub_ieee1275_instance_to_package,
14887 grub_ieee1275_package_to_path, grub_ieee1275_instance_to_path,
14888 grub_ieee1275_peer, grub_ieee1275_child, grub_ieee1275_open,
14889 grub_ieee1275_claim, grub_ieee1275_set_property): Error-check return
14890 codes from Open Firmware. All callers updated.
14891 (grub_ieee1275_next_property): Directly return Open Firmware return
14892 code.
14893 * kern/powerpc/ieee1275/cmain.c (grub_ieee1275_find_options):
14894 Standardize error checking from `grub_ieee1275_get_property'.
14895 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Rename
14896 `devalias' to `aliases'. Correct comments. Consolidate error paths.
14897
97b2f2ff 148982006-10-01 Hollis Blanchard <hollis@penguinppc.org>
cc6d3df3 14899
14900 * kern/ieee1275/ieee1275.c (grub_ieee1275_instance_to_path): Rename
14901 `instance_to_package_args' to `instance_to_path_args'.
14902
14903 * kern/powerpc/ieee1275/init.c (grub_machine_init): Use
14904 `grub_ieee1275_chosen'.
14905
14906 * term/ieee1275/ofconsole.c (grub_ofconsole_init): Call
14907 `grub_ieee1275_interpret'.
14908
97b2f2ff 149092006-09-25 Hollis Blanchard <hollis@penguinppc.org>
02bb8acc 14910
14911 * util/powerpc/ieee1275/grub-mkimage.c: Include config.h.
14912
97b2f2ff 149132006-09-25 Hollis Blanchard <hollis@penguinppc.org>
663b72f0 14914
14915 * include/grub/powerpc/libgcc.h (__floatdisf): New prototype.
14916 (__cmpdi): Likewise.
14917
14918 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Pass 0 as
14919 `flags' to `grub_ieee1275_next_property'. Change `pathlen' to type
14920 `grub_ssize_t'.
14921
02bb8acc 14922 * kern/powerpc/ieee1275/cmain.c: Include grub/misc.h.
663b72f0 14923
14924 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Change `actual'
14925 to type `grub_ssize_t'.
14926 (grub_rescue_cmd_linux): Cast -1 to `grub_off_t'.
14927
7f9a8531 149282006-09-22 Marco Gerards <marco@gnu.org>
14929
14930 * normal/script.c (grub_script_create_cmdmenu): Skip leading
14931 newlines.
14932
b5ef1102 149332006-09-22 Marco Gerards <marco@gnu.org>
14934
14935 * commands/echo.c: New file.
14936
14937 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/echo.c'.
14938
14939 * conf/common.rmk (echo_mod_SOURCES): New variable.
14940 (echo_mod_CFLAGS): Likewise.
14941 (echo_mod_LDFLAGS): Likewise.
14942
2cff3677 149432006-09-22 Marco Gerards <marco@gnu.org>
14944
14945 * normal/main.c (get_line): Malloc memory instead of using
14946 preallocated memory. Removed the arguments `cmdline' and
14947 `max_len'. Updated all callers.
14948
6ba4688b 149492006-09-22 Marco Gerards <marco@gnu.org>
14950
14951 * conf/i386-efi.rmk (grub_emu_DEPENDENCIES): New variable.
14952 (normal_mod_DEPENDENCIES): Likewise.
14953
14954 * conf/powerpc-ieee1275.rmk (grub_emu_DEPENDENCIES): Likewise.
14955 (normal_mod_DEPENDENCIES): Likewise.
14956
14957 * conf/sparc64-ieee1275.rmk (normal_mod_DEPENDENCIES): Likewise.
14958
e02ac02c 149592006-09-22 Johan Rydberg <jrydberg@gnu.org>
14960
14961 * genmk.rb: Add DEPENDENCIES variables to modules, utilities, and
14962 programs.
14963 * conf/i386-pc.rmk (grub_emu_DEPENDENCIES): Declare.
14964 (normal_mod_DEPENDENCIES): Likewise.
14965 * conf/i386-pc.mk: Regenerate.
14966 * conf/i386-efi.mk: Likewise
14967 * conf/common.mk: Likewise.
14968 * conf/powerpc-ieee1275.mk: Likewise.
14969 * conf/sparc64-ieee1275.mk: Likewise.
f19dbdb7 14970
8d252e44 149712006-09-22 Robert Millan <rmh@aybabtu.com>
14972
14973 Sync with i386 version.
14974 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Remove grub-emu, add grub-mkimage.
14975 * conf/powerpc-ieee1275.rmk (sbin_UTILITIES): Remove grub-mkimage, add grub-emu.
14976
209bf7ac 149772006-09-21 Robert Millan <rmh@aybabtu.com>
14978
14979 Import from GRUB Legacy (lib/device.c):
14980 * util/i386/pc/grub-mkdevicemap.c (get_i2o_disk_name): New function.
14981 (init_device_map) [__linux__]: Add support for I2O devices.
14982
6b146090 149832006-09-14 Marco Gerards <marco@gnu.org>
14984
14985 * conf/i386-pc.rmk (COMMON_LDFLAGS): Use `-m32' instead of
14986 `-melf_i386'.
14987
e38600a8 149882006-09-14 Robert Millan <rmh@aybabtu.com>
2952da5d 14989
14990 * util/i386/pc/grub-install.in: Skip menu.lst when removing
14991 /boot/grub/*.lst.
78fa1790 14992
2952da5d 14993 * util/i386/pc/getroot.c: Don't recurse into dotdirs (e.g. ".static").
6b146090 14994
2952da5d 14995 * util/i386/pc/grub-mkdevicemap.c: Make sure the floppy device exists
14996 before adding it to device.map.
14997
01b82a64 149982006-08-15 Johan Rydberg <jrydberg@gnu.org>
14999
fe6b695a 15000 * genmk.rb: Let GCC generate dependencies the first time it
01b82a64 15001 compiles a file; using the -MD option.
15002 * conf/common.mk: Regenerate.
15003 * conf/i386-pc.mk: Likewise.
15004 * conf/i386-efi.mk: Likewise.
15005 * conf/powerpc-ieee1275.mk: Likewise.
15006 * conf/sparc64-ieee1275.mk: Likewise.
f19dbdb7 15007
1064790d 150082006-08-04 Yoshinori K. Okuji <okuji@enbug.org>
15009
15010 Move the prototypes of grub_setjmp and grub_longjmp to
15011 cpu/setjmp.h, so that each architecture may specify different
15012 attributes.
f19dbdb7 15013
1064790d 15014 * include/grub/i386/setjmp.h (grub_setjmp): New prototype.
15015 (grub_longjmp): Likewise.
15016 * include/grub/powerpc/setjmp.h (grub_setjmp): Likewise..
15017 (grub_longjmp): Likewise.
15018 * include/grub/sparc64/setjmp.h (grub_setjmp): Likewise..
15019 (grub_longjmp): Likewise.
15020
15021 * include/grub/setjmp.h [!GRUB_UTIL] (grub_setjmp): Removed.
15022 [!GRUB_UTIL] (grub_longjmp): Removed.
15023
29dda3ed 150242006-08-01 Pelletier Vincent <subdino2004@yahoo.fr>
15025
15026 * kern/ieee1275/ieee1275.c (grub_ieee1275_set_color): IEEE1275
15027 "color!" method does not return any value.
15028
ad2a06ed 150292006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
15030
15031 * include/grub/bitmap.h: New file.
15032
15033 * include/grub/i386/pc/vbeutil.h: Likewise.
15034
15035 * video/bitmap.c: Likewise.
15036
15037 * video/readers/tga.c: Likewise.
15038
15039 * video/i386/pc/vbeutil.c: Likewise.
15040
15041 * commands/videotest.c: Code cleanup and updated to reflect to new
15042 video API.
15043
15044 * term/gfxterm.c: Likewise.
15045
15046 * video/video.c: Likewise.
15047
15048 * conf/i386-pc.rmk (pkgdata_MODULES): Added tga.mod and bitmap.mod.
15049 (vbe_mod_SOURCES): Added video/i386/pc/vbeutil.c.
15050 (bitmap_mod_SOURCES): New entry.
15051 (bitmap_mod_CFLAGS): Likewise.
15052 (bitmap_mod_LDFLAGS): Likewise.
15053 (tga_mod_SOURCES): Likewise.
15054 (tga_mod_CFLAGS): Likewise.
15055 (tga_mod_LDFLAGS): Likewise.
15056
15057 * include/grub/video.h (grub_video_blit_operators): New enum type.
15058 (grub_video_render_target): Changed as forward declaration and moved
15059 actual definition to be video driver specific.
15060 (grub_video_adapter.blit_bitmap): Added blitting operator.
15061 (grub_video_adapter.blit_render_target): Likewise.
15062 (grub_video_blit_bitmap): Likewise.
15063 (grub_video_blit_render_target): Likewise.
15064
15065 * include/grub/i386/pc/vbe.h (grub_video_render_target): Added
15066 driver specific render target definition.
15067 (grub_video_vbe_map_rgba): Added driver internal helper.
15068 (grub_video_vbe_unmap_color): Updated to use
15069 grub_video_i386_vbeblit_info.
15070 (grub_video_vbe_get_video_ptr): Likewise.
15071
15072 * include/grub/i386/pc/vbeblit.h
15073 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8A8): Updated to use
15074 grub_video_i386_vbeblit_info.
15075 (grub_video_i386_vbeblit_R8G8B8_R8G8B8A8): Likewise.
15076 (grub_video_i386_vbeblit_index_R8G8B8A8): Likewise.
15077 (grub_video_i386_vbeblit_R8G8B8A8_R8G8B8): Likewise.
15078 (grub_video_i386_vbeblit_R8G8B8_R8G8B8): Likewise.
15079 (grub_video_i386_vbeblit_index_R8G8B8): Likewise.
15080 (grub_video_i386_vbeblit_index_index): Likewise.
15081 (grub_video_i386_vbeblit_R8G8B8X8_R8G8B8X8): New blitter function.
15082 (grub_video_i386_vbeblit_R8G8B8_R8G8B8X8): Likewise.
15083 (grub_video_i386_vbeblit_index_R8G8B8X8): Likewise.
15084 (grub_video_i386_vbeblit_blend): Added generic blitter for blend
15085 operator.
15086 (grub_video_i386_vbeblit_replace): Added generic blitter for replace
15087 operator.
15088
15089 * video/i386/pc/vbeblit.c: Updated to reflect changes on
15090 include/grub/i386/pc/vbeblit.h.
15091
15092 * include/grub/i386/pc/vbefill.h (grub_video_i386_vbefill_R8G8B8A8):
15093 Updated to use grub_video_i386_vbeblit_info.
15094 (grub_video_i386_vbefill_R8G8B8): Likewise.
15095 (grub_video_i386_vbefill_index): Likewise.
15096 (grub_video_i386_vbefill): Added generic filler.
15097
15098 * video/i386/pc/vbefill.c: Updated to reflect changes on
15099 include/grub/i386/pc/vbefill.h.
15100
15101 * video/i386/pc/vbe.c (grub_video_vbe_get_video_ptr): Updated to use
15102 grub_video_i386_vbeblit_info.
15103 (grub_video_vbe_unmap_color): Likewise.
15104 (grub_video_vbe_blit_glyph): Likewise.
15105 (grub_video_vbe_scroll): Likewise.
15106 (grub_video_vbe_draw_pixel): Removed function.
15107 (grub_video_vbe_get_pixel): Likewise.
15108 (grub_video_vbe_fill_rect): Moved all blitters to vbefill.c and
15109 updated code to use it.
15110 (common_blitter): Added common blitter for render target and bitmap.
15111 (grub_video_vbe_blit_bitmap): Updated to use common_blitter.
15112 (grub_video_vbe_blit_render_target): Likewise.
15113
bc8c036d 151142006-07-30 Johan Rydberg <jrydberg@gnu.org>
15115
15116 * kern/efi/efi.c (grub_efi_set_text_mode): Assume console already
15117 is in text mode if there is no console control protocol instance
15118 available.
15119
684a8eff 151202006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
15121
15122 * include/grub/video.h: Code cleanup.
15123
15124 * include/grub/i386/pc/vbe.h: Likewise.
15125
15126 * video/i386/pc/vbe.c: Likewise.
15127
15128 * video/i386/pc/vbeblit.c: Likewise.
15129
15130 * video/i386/pc/vbefill.c: Likewise.
15131
15132 * video/video.c: Likewise. Also added more comments.
15133
5915059b 151342006-07-29 Vesa Jaaskelainen <chaac@nic.fi>
15135
15136 * disk/i386/pc/biosdisk.c (struct grub_biosdisk_drp): Moved to ...
15137 (struct grub_biosdisk_dap): Likewise.
15138
15139 * include/grub/i386/pc/biosdisk.h: ... to here. Also corrected
15140 linkage settings for all functions.
15141
90ce5d56 151422006-07-12 Marco Gerards <marco@gnu.org>
15143
15144 * configure.ac (--enable-mm-debug): Fix typo.
15145
15146 * genkernsyms.sh.in: Use proper quoting for `CC'.
15147
43e7f879 151482006-07-02 Jeroen Dekkers <jeroen@dekkers.cx>
15149
15150 * conf/i386-pc.rmk (COMMON_ASFLAGS): Add "-m32".
15151 (normal_mod_ASFLAGS): Remove "-m32".
15152
4889bdec 151532006-06-14 Yoshinori K. Okuji <okuji@enbug.org>
15154
15155 * util/misc.c: Include config.h.
15156 [!HAVE_MEMALIGN]: Do not include malloc.h.
15157 (grub_memalign): Use posix_memalign, if present. Then, use
15158 memalign, if present. Otherwise, emit an error.
15159
15160 * util/grub-emu.c: Do not include malloc.h.
15161
15162 * include/grub/util/misc.h: Include unistd.h. This is required for
15163 FreeBSD, because off_t is defined in unistd.h. Reported by Harley
15164 D. Eades III <hde@foobar-qux.org>.
15165
15166 * configure.ac (AC_GNU_SOURCE): Added.
15167 (AC_CHECK_FUNCS): Check posix_memalign and memalign for the host
15168 type.
15169
fd39d4da 151702006-06-09 Yoshinori K. Okuji <okuji@enbug.org>
15171
15172 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Make sure that
15173 ADDR_MAX does not exceed GRUB_LINUX_INITRD_MAX_ADDRESS.
15174
b786f3b5 151752006-06-07 Jeroen Dekkers <jeroen@dekkers.cx>
15176
15177 * include/grub/types.h (grub_host_addr_t): Rename to
15178 grub_target_addr_t.
15179 (grub_host_off_t): Rename to grub_target_off_t.
15180 (grub_host_size_t): Rename to grub_target_size_t.
15181 (grub_host_ssize_t): Rename to grub_target_ssize_t.
15182 Refer to GRUB_TARGET_SIZEOF_VOID_P to define those variables.
15183
15184 * include/grub/kernel.h (struct grub_module_header): Change type
15185 of OFFSET to grub_target_off_t and type of SIZE to grub_target_size_t.
15186 (grub_module_info): Likewise.
f19dbdb7 15187
051988bb 151882006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
15189
15190 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): The conditional
15191 of checking LINUX_MEM_SIZE was reverse. Reported by Jesus
15192 Velazquez <jesus.velazquez@gmail.com>.
15193
deae281b 151942006-06-05 Yoshinori K. Okuji <okuji@enbug.org>
15195
15196 Count partitions from 1 instead of 0 in the string representation
15197 of partitions. Still use 0-based internally.
f19dbdb7 15198
deae281b 15199 * partmap/sun.c (grub_sun_is_valid): A cosmetic change.
15200 (sun_partition_map_iterate): Use grub_partition_t instead of
15201 struct grub_partition *. Cast DESC->START_CYLINDER to
15202 grub_uint64_t after converting the endian.
15203 (sun_partition_map_probe): Subtract 1 for PARTNUM.
15204 (sun_partition_map_get_name): Add 1 to P->INDEX.
15205
15206 * partmap/pc.c (grub_partition_parse): Subtract 1 for
15207 PCDATA->DOS_PART.
15208 (pc_partition_map_get_name): Add 1 into PCDATA->DOS_PART.
15209
15210 * partmap/gpt.c (gpt_partition_map_iterate): Initialize PARTNO to
15211 zero instead of one.
15212 (gpt_partition_map_probe): Subtract 1 for PARTNUM.
15213 (gpt_partition_map_get_name): Add 1 into P->INDEX.
15214
15215 * partmap/apple.c (apple_partition_map_iterate): Change the type
15216 of POS to unsigned.
15217 (apple_partition_map_probe): Subtract 1 for PARTNUM.
15218 (apple_partition_map_get_name): Add 1 into P->INDEX.
15219
15220 * partmap/amiga.c (amiga_partition_map_iterate): Change the type
15221 of POS to unsigned.
15222 (amiga_partition_map_iterate): Cast NEXT to grub_off_t to
15223 calculate the offset of a partition.
15224 (amiga_partition_map_probe): Subtract 1 for PARTNUM.
15225 (amiga_partition_map_get_name): Add 1 into P->INDEX.
15226
15227 * partmap/acorn.c (acorn_partition_map_find): Change the type of
15228 SECTOR to grub_disk_addr_t.
15229 (acorn_partition_map_iterate): Likewise.
15230 (acorn_partition_map_probe): Subtract 1 for PARTNUM.
15231 Change the type of SECTOR to grub_disk_addr_t. Declare P on the
15232 top.
15233 (acorn_partition_map_get_name): Add 1 into P->INDEX.
15234
15235 * kern/i386/pc/init.c (make_install_device): Add 1 into
15236 GRUB_INSTALL_DOS_PART.
15237
15238 * fs/iso9660.c (grub_iso9660_mount): Fixed a reversed
15239 conditional.
15240
524a1e6a 152412006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
15242
15243 Clean up the code to support 64-bit addressing in disks and
15244 files. This change is not enough for filesystems yet.
f19dbdb7 15245
524a1e6a 15246 * util/i386/pc/grub-setup.c (struct boot_blocklist): Change the
15247 type of "start" to grub_uint64_t.
15248 (setup): Change the types of KERNEL_SECTOR and FIRST_SECTOR to
15249 grub_disk_addr_t * and grub_disk_addr_t. Fix the format string in
15250 save_first_sector and save_blocklists. Use grub_le_to_cpu64 to
15251 convert addresses.
15252
15253 * util/i386/pc/biosdisk.c (open_device): Change the type of SECTOR
15254 to grub_disk_addr_t.
15255
15256 * partmap/gpt.c (gpt_partition_map_iterate): Fix the format
15257 string.
15258
15259 * partmap/pc.c (pc_partition_map_iterate): Likewise.
15260
15261 * partmap/amiga.c (amiga_partition_map_iterate): Cast RDSK.MAGIC
15262 to char *.
15263
15264 * normal/script.c (grub_script_parse): Remove unused MEMFREE.
15265
15266 * normal/parser.y (YYLTYPE_IS_TRIVIAL): New macro.
15267
15268 * normal/lexer.c (grub_script_yyerror): Specify unused to LEX.
15269
15270 * loader/i386/pc/multiboot.c (grub_multiboot_load_elf64): Cast -1
15271 to grub_off_t, to detect an error from grub_file_seek.
15272 (grub_multiboot_load_elf32): Likewise.
15273
15274 * kern/misc.c (grub_strtoul): Use grub_strtoull. Return the
15275 maximum unsigned long value when an overflow is detected.
15276 (grub_strtoull): New function.
15277 (grub_divmod64): Likewise.
15278 (grub_lltoa): use grub_divmod64.
15279
15280 * kern/fs.c (struct grub_fs_block): Change the type of "offset" to
15281 grub_disk_addr_t.
15282 (grub_fs_blocklist_open): Increase P if P is not NULL to advance
15283 the pointer to next character. Use grub_strtoull instead of
15284 grub_strtoul.
15285 (grub_fs_blocklist_read): Change the types of SECTOR, OFFSET and
15286 SIZE to grub_disk_addr_t, grub_off_t and grub_size_t,
15287 respectively.
15288
fe6b695a 15289 * kern/file.c (grub_file_read): Prevent an overflow of LEN, as the
524a1e6a 15290 return value is signed.
15291 (grub_file_seek): Change the type of OLD to grub_off_t. Do not
15292 test if OFFSET is less than zero, as OFFSET is unsigned now.
15293
15294 * kern/disk.c (struct grub_disk_cache): Change the type of
15295 "sector" to grub_disk_addr_t.
15296 (grub_disk_cache_get_index): Change the type of SECTOR to
15297 grub_disk_addr_t. Calculate the hash with SECTOR casted to
15298 unsigned after shifting.
15299 (grub_disk_cache_invalidate): Change the type of SECTOR to
15300 grub_disk_addr_t.
15301 (grub_disk_cache_unlock): Likewise.
15302 (grub_disk_cache_store): Likewise.
15303 (grub_disk_check_range): Change the types of SECTOR, OFFSET, SIZE,
15304 START and LEN to grub_disk_addr_t *, grub_off_t *, grub_size_t,
15305 grub_disk_addr_t and grub_uint64_t, respectively.
15306 (grub_disk_read): Use an unsigned variable REAL_OFFSET for the
15307 body, as the value of OFFSET is tweaked by
15308 grub_disk_check_range. Change the types of START_SECTOR, LEN and
15309 POS to grub_disk_addr_t, grub_size_t and grub_size_t,
15310 respectively.
15311 (grub_disk_write): Use an unsigned variable REAL_OFFSET for the
15312 body, as the value of OFFSET is tweaked by
15313 grub_disk_check_range. Change the types of LEN and N to
15314 grub_size_t.
15315
15316 * io/gzio.c (struct grub_gzio): Change the types of "data_offset"
15317 and "saved_offset" to grub_off_t.
15318 (test_header): Cast BUF to char *.
15319 (get_byte): Cast GZIO->DATA_OFFSET to grub_off_t. Cast GZIO->INBUF
15320 to char *.
15321 (grub_gzio_read): Change the types of OFFSET and SIZE to
15322 grub_off_t and grub_size_t, respectively.
15323
15324 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_FORCE_LBA):
15325 Removed.
15326 (GRUB_BOOT_MACHINE_BOOT_DRIVE): Changed to 0x4c.
15327 (GRUB_BOOT_MACHINE_KERNEL_ADDRESS): Changed to 0x40.
15328 (GRUB_BOOT_MACHINE_KERNEL_SEGMENT): Changed to 0x42.
15329 (GRUB_BOOT_MACHINE_DRIVE_CHECK): Changed to 0x4e.
15330 (GRUB_BOOT_MACHINE_LIST_SIZE): Increased to 12.
15331
15332 * include/grub/types.h (grub_off_t): Unconditionally set to
15333 grub_uint64_t.
15334 (grub_disk_addr_t): Changed to grub_uint64_t.
15335
15336 * include/grub/partition.h (struct grub_partition): Change the
15337 types of "start", "len" and "offset" to grub_disk_addr_t,
15338 grub_uint64_t and grub_disk_addr_t, respectively.
15339 (grub_partition_get_start): Return grub_disk_addr_t.
15340 (grub_partition_get_len): Return grub_uint64_t.
15341
15342 * include/grub/misc.h (grub_strtoull): New prototype.
15343 (grub_divmod64): Likewise.
15344
15345 * include/grub/fshelp.h (grub_fshelp_read_file): Change the types
15346 of SECTOR, LEN and FILESIZE to grub_disk_addr_t, grub_size_t and
15347 grub_off_t, respectively.
15348 All callers and references changed.
15349
15350 * include/grub/fs.h (struct grub_fs): Change the type of LEN to
15351 grub_size_t in "read".
15352 All callers and references changed.
15353
15354 * include/grub/file.h (struct grub_file): Change the types of
15355 "offset" and "size" to grub_off_t and grub_off_t,
15356 respectively. Change the type of SECTOR to grub_disk_addr_t in
15357 "read_hook".
15358 (grub_file_read): Change the type of LEN to grub_size_t.
15359 (grub_file_seek): Return grub_off_t. Change the type of OFFSET to
15360 grub_off_t.
15361 (grub_file_size): Return grub_off_t.
15362 (grub_file_tell): Likewise.
15363 All callers and references changed.
15364
15365 * include/grub/disk.h (struct grub_disk_dev): Change the types of
15366 SECTOR and SIZE to grub_disk_addr_t and grub_size_t in "read" and
15367 "write".
15368 (struct grub_disk): Change the type of "total_sectors" to
15369 grub_uint64_t. Change the type of SECTOR to grub_disk_addr_t in
f19dbdb7 15370 "read_hook".
524a1e6a 15371 (grub_disk_read): Change the types of SECTOR, OFFSET and SIZE to
15372 grub_disk_addr_t, grub_off_t and grub_size_t, respectively.
15373 (grub_disk_write): Likewise.
15374 All callers and references changed.
15375
15376 * fs/iso9660.c (grub_iso9660_susp_iterate): Cast parameters to
15377 char * for grub_strncmp to silence gcc.
15378 (grub_iso9660_mount): Likewise.
15379 (grub_iso9660_mount): Likewise.
15380 (grub_iso9660_read_symlink): Likewise. Also, remove the nonsense
15381 return statement.
15382 (grub_iso9660_iterate_dir): Likewise.
15383 (grub_iso9660_label): Cast DATA->VOLDESC.VOLNAME to char *.
15384
15385 * fs/hfs.c (grub_hfs_read_file): Change the types of SECTOR and
15386 LEN to grub_disk_addr_t and grub_size_t, respectively.
15387
15388 * fs/hfsplus.c (grub_hfsplus_read_file): Likewise.
15389
15390 * fs/jfs.c (grub_jfs_read_file): Likewise.
15391
15392 * fs/minix.c (grub_jfs_read_file): Likewise.
15393
15394 * fs/sfs.c (grub_jfs_read_file): Likewise.
15395
15396 * fs/ufs.c (grub_jfs_read_file): Likewise.
15397
15398 * fs/xfs.c (grub_jfs_read_file): Likewise.
15399
15400 * fs/fat.c (grub_fat_read_data): Change the types of SECTOR, LEN
15401 and SIZE to grub_disk_addr_t, grub_size_t and grub_size_t,
15402 respectively.
15403
15404 * fs/ext2.c (grub_ext2_read_block): When an error happens, set
15405 BLKNR to -1 instead of returning GRUB_ERRNO.
15406 (grub_ext2_read_file): Change the types of SECTOR and
15407 LEN to grub_disk_addr_t and grub_size_t, respectively.
15408
15409 * fs/affs.c (grub_affs_read_file): Change the types of SECTOR and
15410 LEN to grub_disk_addr_t and grub_size_t, respectively.
15411
15412 * font/manager.c (grub_font_get_glyph): Cast BITMAP to char * for
15413 grub_file_read.
15414
15415 * disk/ieee1275/ofdisk.c (grub_ofdisk_read): Fix the format
15416 string. Do not cast SECTOR explicitly.
15417
15418 * disk/i386/pc/biosdisk.c (grub_biosdisk_open): Change the type of
15419 TOTAL_SECTORS to grub_uint64_t. Do not mask DRP->TOTAL_SECTORS.
15420 (grub_biosdisk_rw): Change the types of SECTOR and SIZE to
15421 grub_disk_addr_t and grub_size_t, respectively. If the sector is
15422 over 2TB and LBA mode is not supported, raise an error.
15423 (get_safe_sectors): New function.
15424 (grub_biosdisk_read): Use get_safe_sectors.
15425 (grub_biosdisk_write): Likewise.
15426
15427 * disk/efi/efidisk.c (grub_efidisk_read): Fix the format string.
15428 (grub_efidisk_write): Likewise.
15429
15430 * disk/loopback.c (delete_loopback): Cosmetic changes.
15431 (grub_cmd_loopback): Likewise. Also, test NEWDEV->FILENAME
15432 correctly.
15433 (grub_loopback_open): Likewise.
15434 (grub_loopback_read): Likewise. Also, change the type of POS to
15435 grub_off_t, and fix the usage of grub_memset.
15436
15437 * commands/i386/pc/play.c: Include grub/machine/time.h.
15438
15439 * commands/ls.c (grub_ls_list_files): Use "llu" instead of "d" to
15440 print FILE->SIZE.
15441
15442 * commands/configfile.c: Include grub/env.h.
15443
15444 * commands/cmp.c (grub_cmd_cmp): Do not use ERR, but use
15445 GRUB_ERRNO directly instead. Change the type of POS to
15446 grub_off_t. Follow the coding standard.
15447
15448 * commands/blocklist.c: Include grub/partition.h.
15449 (grub_cmd_blocklist): Return an error if the underlying device is
15450 not a disk. Take the starting sector of a partition into account,
15451 if a partition is used.
15452
15453 * boot/i386/pc/diskboot.S (bootloop): Adapted to the new offset of
15454 a length field.
15455 (lba_mode): Support 64-bit addresses.
15456 (chs_mode): Likewise.
15457 (copy_buffer): Adapted to the new offsets of a length field and a
15458 segment field.
15459 (blocklist_default_start): Allocate 64-bit space.
15460
15461 * boot/i386/pc/boot.S (force_lba): Removed.
15462 (boot_drive): Moved to under KERNEL_SECTOR.
fe987087 15463 (kernel_sector): Moved to under KERNEL_SEGMENT. Allocate 64-bit
524a1e6a 15464 space.
15465 (real_start): Set %si earlier. Remove code for FORCE_LBA, since it
15466 is useless.
15467 (lba_mode): Refactored to support a 64-bit address. More size
15468 optimization.
15469 (setup_sectors): Likewise.
15470
53af98ad 154712006-06-04 Yoshinori K. Okuji <okuji@enbug.org>
15472
15473 * DISTLIST: Added include/grub/i386/linux.h. Removed
15474 include/grub/i386/pc/linux.h
15475
15476 * configure.ac (AC_INIT): Bumped to 1.94.
15477
15478 * config.guess: Updated from gnulib.
15479 * config.sub: Likewise.
15480 * install-sh: Likewise.
15481 * mkinstalldirs: Likewise.
15482
b4c1940a 154832006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
15484
15485 * conf/common.rmk (grub_modules_init.lst): Depended on
15486 grub_emu_SOURCES, excluding grub_emu_init.c, instead of
15487 MODSRCFILES.
15488
15489 * genmk.rb (PModule::rule): Reverted the previous change.
15490
cfca1cfd 154912006-06-02 Yoshinori K. Okuji <okuji@enbug.org>
15492
15493 * conf/common.rmk (grub_modules_init.lst): Depends on
15494 $(MODSRCFILES). Grep only the files in $(MODSRCFILES). Make sure
15495 that the target does not exist before producing.
15496 (grub_modules_init.h): Remove the target before generating.
15497 (grub_emu_init.c): Likewise.
15498
15499 * genmk.rb (PModule::rule): Add source files into MODSRCFILES.
15500
aa6d7826 155012006-05-31 Jeroen Dekkers <jeroen@dekkers.cx>
15502
15503 * configure.ac: Don't set host_m32 for x86_64. Also reset LIBS
15504 for the target-specific tests. Make sure that we also have the
15505 up-to-date target variables for those tests.
15506
26c607b9 155072006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
15508
15509 * genmk.rb (Image::rule): Prefix CFLAGS or ASFLAGS with TARGET_.
15510 (PModule::rule): Likewise.
15511
0162321a 155122006-05-31 Yoshinori K. Okuji <okuji@enbug.org>
15513
15514 * genmk.rb (Image::rule): Set FLAG to CFLAGS or ASFLAGS instead of
15515 TARGET_CFLAGS or TARGET_ASFLAGS. There is no reason why
15516 target-specific flags should be prefixed.
15517 (PModule::rule): Likewise.
15518
6c826348 155192006-05-30 Yoshinori K. Okuji <okuji@enbug.org>
15520
15521 * configure.ac (CMP): Check if cmp is available explicitly.
15522
b977bf01 155232006-05-29 Yoshinori K. Okuji <okuji@enbug.org>
15524
15525 * util/powerpc/ieee1275/grub-install.in (host_cpu): Removed.
15526 (target_cpu): New variable.
15527 (pkglibdir): Use target_cpu instead of host_cpu.
f19dbdb7 15528
b977bf01 15529 * util/i386/pc/grub-install.in (host_cpu): Removed.
15530 (target_cpu): New variable.
15531 (pkglibdir): Use target_cpu instead of host_cpu.
15532
15533 * util/genmoddep.c: Removed.
f19dbdb7 15534
b977bf01 15535 * kern/efi/mm.c (filter_memory_map): Use GRUB_CPU_SIZEOF_VOID_P
15536 instead of GRUB_HOST_SIZEOF_VOID_P.
15537 * kern/dl.c: Likewise.
15538
15539 * include/grub/i386/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed to
15540 ...
15541 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
15542 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
15543 (GRUB_TARGET_SIZEOF_LONG): ... this.
15544 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
15545 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
15546 * include/grub/powerpc/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
15547 to ...
15548 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
15549 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
15550 (GRUB_TARGET_SIZEOF_LONG): ... this.
15551 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
15552 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
15553 * include/grub/sparc64/types.h (GRUB_HOST_SIZEOF_VOID_P): Renamed
15554 to ...
15555 (GRUB_TARGET_SIZEOF_VOID_P): ... this.
15556 (GRUB_HOST_SIZEOF_LONG): Renamed to ...
15557 (GRUB_TARGET_SIZEOF_LONG): ... this.
15558 (GRUB_HOST_WORDS_BIGENDIAN): Renamed to ...
15559 (GRUB_TARGET_WORDS_BIGENDIAN): ... this.
15560
15561 * include/grub/types.h [!GRUB_UTIL] (GRUB_CPU_SIZEOF_VOID_P): Use
15562 GRUB_TARGET_SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P.
15563 [!GRUB_UTIL] (GRUB_CPU_SIZEOF_LONG): Use GRUB_TARGET_SIZEOF_LONG
15564 instead of GRUB_HOST_SIZEOF_LONG.
15565 [!GRUB_UTIL]: Refer to GRUB_TARGET_WORDS_BIGENDIAN instead of
15566 GRUB_HOST_WORDS_BIGENDIAN to define or undefine
15567 GRUB_CPU_WORDS_BIGENDIAN.
15568 Refer to SIZEOF_VOID_P instead of GRUB_HOST_SIZEOF_VOID_P to
15569 define grub_host_addr_t, grub_host_off_t, grub_host_size_t and
15570 grub_host_ssize_t.
15571
15572 * conf/i386-efi.rmk (noinst_UTILITIES): Removed.
15573 (genmoddep_SOURCES): Likewise.
15574 * conf/i386-pc.rmk (noinst_UTILITIES): Likewise.
15575 (genmoddep_SOURCES): Likewise.
15576 * conf/conf/powerpc-ieee1275.rmk (noinst_UTILITIES): Likewise.
15577 (genmoddep_SOURCES): Likewise.
15578 * conf/conf/conf/sparc64-ieee1275.rmk (noinst_UTILITIES):
15579 Likewise.
15580 (genmoddep_SOURCES): Likewise.
15581
15582 * genmoddep.awk: New file.
15583
15584 * genmk.rb (Image::rule): Use TARGET_CC, TARGET_CPPFLAGS,
15585 TARGET_CFLAGS, TARGET_ASFLAGS and TARGET_LDFLAGS instead of CC,
15586 CPPFLAGS, CFLAGS, ASFLAGS and LDFLAGS, respectively.
15587 (PModule::rule): Likewise.
15588 (Program::rule): Likewise.
15589 (Utility::rule): Use CC, CPPFLAGS, CFLAGS and LDFLAGS instead of
15590 BUILD_CC, BUILD_CPPFLAGS, BUILD_CFLAGS and BUILD_LDFLAGS,
15591 respectively.
15592
15593 * configure.ac: Rewritten intensively to use host and target
15594 instead of build and host, respectively.
15595
15596 * Makefile.in (pkglibdir): Use target_cpu instead of host_cpu.
15597 (host_cpu): Removed.
15598 (target_cpu): New variable.
15599 (CPPFLAGS): Added @CPPFLAGS@ and -DGRUB_LIBDIR=\"$(pkglibdir)\".
15600 (BUILD_CC): Removed.
15601 (BUILD_CFLAGS): Likewise.
15602 (BUILD_CPPFLAGS): Likewise.
15603 (TARGET_CC): New variable.
15604 (TARGET_CFLAGS): Likewise.
15605 (TARGET_CPPFLAGS): Likewise.
15606 (TARGET_LDFLAGS): Likewise.
15607 (AWK): Likewise.
15608 (include): Use target_cpu instead of host_cpu.
15609 (moddep.lst:): Use genmoddep.awk instead of genmoddep.
f19dbdb7 15610
b977bf01 15611 * DISTLIST: Added genmoddep.awk. Removed util/genmoddep.c.
15612
f09771a1 156132006-05-29 Vesa Jaaskelainen <chaac@nic.fi>
15614
15615 * include/grub/script.h (grub_script_cmdif): Renamed field 'bool' to
15616 'exec_to_evaluate'. Renamed field 'true' to 'exec_on_true'. Renamed
15617 field 'false' to 'exec_on_false'.
15618 (grub_script_create_cmdif): Renamed argument names to reflect above
15619 changes.
15620
15621 * normal/execute.c (grub_script_execute_cmdif): Likewise.
15622
15623 * normal/script.c (grub_script_create_cmdif): Likewise.
15624
118f4fb3 156252006-05-28 Yoshinori K. Okuji <okuji@enbug.org>
15626
15627 * fs/hfsplus.c (grub_hfsplus_btree_recoffset): Moved to near the
15628 top.
15629 (grub_hfsplus_btree_recptr): Likewise.
15630 (grub_hfsplus_find_block): Do not take RETRY any longer. Use
15631 FILEBLOCK both to pass a block number and store next block
15632 number.
15633 (grub_hfsplus_read_block): Rewritten heavily to support an extent
15634 overflow file correctly. Specify errors appropriately, because
15635 fshelp expects that GRUB_ERRNO is set when fails. Reuse
15636 grub_hfsplus_btree_recptr to get the pointer to a found key.
15637 (grub_hfsplus_btree_search): Return 1 instead of 0 when no match
15638 is found.
15639
15640 * conf/i386-efi.rmk (pkgdata_MODULES): Added _linux.mod and
15641 linux.mod.
15642 (_linux_mod_SOURCES): New variable.
15643 (_linux_mod_CFLAGS): Likewise.
15644 (_linux_mod_LDFLAGS): Likewise.
15645 (linux_mod_SOURCES): Likewise.
15646 (linux_mod_CFLAGS): Likewise.
15647 (linux_mod_LDFLAGS): Likewise.
15648
15649 * DISTLIST: Added loader/i386/efi/linux.c,
15650 loader/i386/efi/linux_normal.c and
15651 include/grub/i386/efi/loader.h.
15652
15653 * loader/i386/efi/linux.c: New file.
15654 * loader/i386/efi/linux_normal.c: Likewise.
15655 * include/grub/i386/efi/loader.h: Likewise.
15656
89a7d726 156572006-05-27 Yoshinori K. Okuji <okuji@enbug.org>
15658
15659 * commands/blocklist.c: New file.
15660
15661 * DISTLIST: Added commands/blocklist.c.
15662
15663 * term/efi/console.c (grub_console_highlight_color): Use a lighter
43b553ad 15664 color for the background, and a darker color for the foreground.
89a7d726 15665 (grub_console_checkkey): Return READ_KEY.
15666 (grub_console_cls): Set the background to
15667 GRUB_EFI_BACKGROUND_BLACK temporarily to clean out the screen.
15668
15669 * kern/efi/efi.c (grub_efi_exit_boot_services): New function.
15670
15671 * include/grub/i386/linux.h (struct linux_kernel_params): Fixed
15672 the size of "padding5", "hd0_drive_info" and "hd1_drive_info".
15673
15674 * include/grub/efi/efi.h (grub_efi_exit_boot_services): New
15675 prototype.
15676
15677 * include/grub/efi/api.h (GRUB_EFI_TEXT_ATTR): Do not shift
15678 BG. The spec is wrong again.
15679
15680 * include/grub/normal.h [GRUB_UTIL] (grub_blocklist_init): New
15681 prototype.
15682 [GRUB_UTIL] (grub_blocklist_fini): Likewise.
15683
15684 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
15685 commands/blocklist.c.
15686 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
f19dbdb7 15687
89a7d726 15688 * conf/common.rmk (pkgdata_MODULES): Added blocklist.mod.
15689 (blocklist_mod_SOURCES): New variable.
15690 (blocklist_mod_CFLAGS): Likewise.
15691 (blocklist_mod_LDFLAGS): Likewise.
15692
75c8f258 156932006-05-20 Yoshinori K. Okuji <okuji@enbug.org>
15694
15695 * boot/i386/pc/boot.S (real_start): Set %si earlier to eliminate
15696 duplication.
15697 (lba_mode): Use %eax more intensively to reduce the code size.
15698
da2eb181 156992006-05-20 Marco Gerards <marco@gnu.org>
15700
15701 * normal/lexer.c (grub_script_yylex): Don't filter out newlines.
15702
15703 * normal/parser.y (commandblock): Defined as <cmd>. A subroutine
15704 for `menuentry'.
15705 (script): Accept leading newlines.
15706 (newlines): New rule to describe 0 or more newlines.
15707 (commands): Accept `command' with trailing newline. Fixed the
15708 order in which arguments were passed to `grub_script_add_cmd'.
15709 Accept commands separated by newlines.
15710 (function): Changed to accept newlines.
15711 (menuentry) Rewritten.
15712
15713 * normal/script.c (grub_script_create_cmdmenu): Add new entries in
15714 front of the list, instead of to the end.
15715
577b4050 157162006-05-19 Yoshinori K. Okuji <okuji@enbug.org>
15717
15718 * util/i386/pc/grub-install.in (bindir): New variable.
15719 (grub_mkimage): Use BINDIR instead of SBINDIR. Reported by Lee
15720 Shaver <lbgwjl@gmail.com>.
15721
0d6e1189 157222006-05-14 Yoshinori K. Okuji <okuji@enbug.org>
15723
15724 * kern/i386/pc/startup.S: Include grub/cpu/linux.h instead of
15725 grub/machine/linux.h
15726 * loader/i386/pc/linux.c: Likewise.
15727
15728 * include/grub/i386/pc/linux.h: Moved to ...
15729 * include/grub/i386/linux.h: ... here.
15730
15731 * include/grub/i386/linux.h (struct linux_kernel_params): New
15732 struct.
f19dbdb7 15733
31b86e9f 157342006-05-09 Vesa Jaaskelainen <chaac@nic.fi>
15735
15736 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Corrected bounds
15737 checking.
15738 (grub_video_vbe_blit_glyph): Likewise.
15739 (grub_video_vbe_blit_bitmap): Likewise.
15740 (grub_video_vbe_blit_render_target): Likewise.
15741
83b984de 157422006-05-09 Yoshinori K. Okuji <okuji@enbug.org>
15743
15744 * configure.ac (--with-platform): Properly quote the square
15745 brackets.
15746
5f0413bd 157472006-05-08 Marco Gerards <marco@gnu.org>
15748
15749 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Renamed from
15750 this...
15751 (kernel_elf_HEADERS): ...to this. Updated all users.
15752 (grubof_symlist.c): Renamed from this...
15753 (kernel_elf_symlist.c): ...to this. Updated all users.
15754 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
15755 (grubof_SOURCES): Renamed from this...
15756 (kernel_elf_SOURCES): ...to this.
15757 (grubof_HEADERS): Renamed from this...
15758 (kernel_elf_HEADERS): ...to this.
15759 (grubof_CFLAGS): Renamed from this...
15760 (kernel_elf_CFLAGS): ...to this.
15761 (grubof_ASFLAGS): Renamed from this...
15762 (kernel_elf_ASFLAGS): ...to this.
15763 (grubof_LDFLAGS): Renamed from this...
15764 (kernel_elf_LDFLAGS): ...to this.
15765
15766 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Renamed from
15767 this...
15768 (kernel_elf_HEADERS): ...to this. Updated all users.
15769 (grubof_symlist.c): Renamed from this...
15770 (kernel_elf_symlist.c): ...to this. Updated all users.
15771 (pkgdata_PROGRAMS): Changed `grubof' to `kernel.elf'.
15772 (grubof_SOURCES): Renamed from this...
15773 (kernel_elf_SOURCES): ...to this.
15774 (grubof_HEADERS): Renamed from this...
15775 (kernel_elf_HEADERS): ...to this.
15776 (grubof_CFLAGS): Renamed from this...
15777 (kernel_elf_CFLAGS): ...to this.
15778 (grubof_ASFLAGS): Renamed from this...
15779 (kernel_elf_ASFLAGS): ...to this.
15780 (grubof_LDFLAGS): Renamed from this...
15781 (kernel_elf_LDFLAGS): ...to this.
15782
15783 * util/powerpc/ieee1275/grub-mkimage.c (add_segments): Use
15784 `kernel.elf' instead of `grubof'.
15785
05568c2e 157862006-05-08 Yoshinori K. Okuji <okuji@enbug.org>
15787
15788 Add --with-platform to configure. Use pkglibdir instead of
15789 pkgdatadir. This is reported by Roger Leigh.
15790
15791 * util/powerpc/ieee1275/grub-install.in (datadir): Removed.
15792 (host_vendor): Likewise.
15793 (host_os): Likewise.
15794 (pkgdatadir): Likewise.
15795 (platform): New variable.
15796 (pkglibdir): Likewise.
15797 Use PKGLIBDIR instead of PKGDATADIR.
f19dbdb7 15798
05568c2e 15799 * util/i386/pc/grub-install.in (datadir): Removed.
15800 (host_vendor): Likewise.
15801 (host_os): Likewise.
15802 (pkgdatadir): Likewise.
15803 (platform): New variable.
15804 (pkglibdir): Likewise.
15805 Use PKGLIBDIR instead of PKGDATADIR.
15806
15807 * util/powerpc/ieee1275/grub-mkimage.c (usage): Use GRUB_LIBDIR
15808 instead of GRUB_DATADIR.
15809 (main): Likewise.
15810 * util/i386/pc/grub-mkimage.c (usage): Likewise.
15811 (main): Likewise.
15812 * util/i386/efi/grub-mkimage.c (usage): Likewise.
15813 (main): Likewise.
15814
15815 * configure.ac (--with-platform): New option.
15816 Use PLATFORM instead of HOST_VENDOR to specify a platform.
15817
15818 * Makefile.in: Include a makefile based on PLATFORM instead of
15819 HOST_VENDOR.
15820 (pkgdatadir): Not appended by the machine type.
15821 (pkglibdir): Appended by the machine type.
15822 (host_vendor): Removed.
15823 (platform): New variable.
15824 (BUILD_CPPFLAGS): Specify GRUB_LIBDIR instead of GRUB_DATADIR.
15825 (install-local): Use PKGLIBDIR instead of PKGDATADIR.
15826 (uninstall): Likewise.
15827
4e93851c 158282006-05-07 Yoshinori K. Okuji <okuji@enbug.org>
15829
15830 Use the environment context in the menu. Remove the commands
15831 "default" and "timeout", and use variables instead.
f19dbdb7 15832
4e93851c 15833 * normal/menu.c: Include grub/env.h.
15834 (print_entry): Cast TITLE to silence gcc.
15835 (get_timeout): New function.
15836 (set_timeout): Likewise.
15837 (get_entry_number): Likewise.
15838 (run_menu): Use a default entry, a fallback entry and a timeout
15839 in the environment variables "default", "fallback" and
15840 "timeout". Also, tweak the default entry if it is not within the
15841 current menu entries.
15842 (grub_menu_run): Use a fallback entry in the environment variable
15843 "fallback".
15844
15845 * normal/main.c (read_config_file): Do not initialize
15846 NEWMENU->DEFAULT_ENTRY, NEWMENU->FALLBACK_ENTRY or
15847 NEWMENU->TIMEOUT.
15848 (grub_normal_execute): Use a data slot to store the menu.
15849
15850 * include/grub/normal.h (struct grub_menu): Removed default_entry,
15851 fallback_entry and timeout.
15852 (struct grub_menu_list): Removed.
15853 (grub_menu_list_t): Likewise.
15854 (struct grub_context): Likewise.
15855 (grub_context_t): Likewise.
15856 (grub_context_get): Likewise.
15857 (grub_context_get_current_menu): Likewise.
15858 (grub_context_push_menu): Likewise.
15859 (grub_context_pop_menu): Likewise.
15860 (grub_default_init): Likewise.
15861 (grub_default_fini): Likewise.
15862 (grub_timeout_init): Likewise.
15863 (grub_timeout_fini): Likewise.
15864
15865 * conf/sparc64-ieee1275.rmk (pkgdata_MODULES): Removed default.mod
15866 and timeout.mod.
15867 (normal_mod_SOURCES): Removed normal/context.c.
15868
15869 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Removed
15870 commands/default.c, commands/timeout.c and normal/context.c.
15871 (normal_mod_SOURCES): Removed normal/context.c.
15872
15873 * conf/i386-pc.rmk (grub_emu_SOURCES): Removed commands/default.c,
15874 commands/timeout.c and normal/context.c.
15875 (normal_mod_SOURCES): Removed normal/context.c.
15876
15877 * conf/i386-efi.rmk (grub_emu_SOURCES): Removed
15878 commands/default.c, commands/timeout.c and normal/context.c.
15879 (normal_mod_SOURCES): Removed normal/context.c.
15880
15881 * conf/common.rmk (pkgdata_MODULES): Removed default.mod and
15882 timeout.mod.
15883 (default_mod_SOURCES): Removed.
15884 (default_mod_CFLAGS): Likewise.
15885 (default_mod_LDFLAGS): Likewise.
15886 (timeout_mod_SOURCES): Removed.
15887 (timeout_mod_CFLAGS): Likewise.
15888 (timeout_mod_LDFLAGS): Likewise.
15889
15890 * DISTLIST: Removed commands/default.c, commands/timeout.c and
15891 normal/context.c.
15892
15893 * commands/default.c: Removed.
15894 * commands/timeout.c: Likewise.
15895 * normal/context.c: Likewise.
15896
1eb9cc1d 158972006-05-07 Vesa Jaaskelainen <chaac@nic.fi>
15898
15899 * kern/i386/pc/startup.S (grub_exit): Added missing .code32 tag.
15900
385bd9c1 159012006-05-02 Yoshinori K. Okuji <okuji@enbug.org>
15902
15903 * kern/env.c (struct grub_env_context): Removed "sorted". Renamed
15904 "next" to "prev" for readability.
15905 (struct grub_env_sorted_var): New struct.
15906 (grub_env_context): Renamed to ...
15907 (initial_context): ... this.
15908 (grub_env_var_context): Renamed to ...
15909 (current_context): ... this.
15910 (grub_env_find): Look only at CURRENT_CONTEXT.
15911 (grub_env_context_open): Rewritten to copy exported variables from
15912 previous context.
15913 (grub_env_context_close): Rewritten according to the new
15914 scheme. Also, add an assertion to prevent the initial context from
15915 removed.
15916 (grub_env_insert): Removed the code for the sorted list.
15917 (grub_env_remove): Likewise.
15918 (grub_env_export): Simply mark the variable with
15919 GRUB_ENV_VAR_GLOBAL.
15920 (grub_env_set): A cosmetic change for naming consistency.
15921 (grub_env_get): Likewise.
15922 (grub_env_unset): Likewise.
15923 (grub_env_iterate): Rewritten to sort variables within this
15924 function.
15925 (grub_register_variable_hook): Fixed for naming consistency. Call
15926 grub_env_find again, only if NAME is not found at the first time.
15927 (mangle_data_slot_name): New function.
15928 (grub_env_set_data_slot): Likewise.
15929 (grub_env_get_data_slot): Likewise.
15930 (grub_env_unset_data_slot): Likewise.
15931
15932 * include/grub/env.h (grub_env_var_type): New enum.
15933 (GRUB_ENV_VAR_LOCAL): New constant.
15934 (GRUB_ENV_VAR_GLOBAL): Likewise.
15935 (GRUB_ENV_VAR_DATA): Likewise.
15936 (struct grub_env_var): Removed "sort_next" and "sort_prevp". Added
15937 "type".
15938 (grub_env_set): Replace VAR with NAME for consistency.
15939 (grub_register_variable_hook): Likewise.
15940 (grub_env_export): Specify the name of the argument.
15941 (grub_env_set_data_slot): New prototype.
15942 (grub_env_get_data_slot): Likewise.
15943 (grub_env_unset_data_slot): Likewise.
15944
7f362539 159452006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
15946
15947 Extend the loader so that GRUB can accept a loader which comes
15948 back to GRUB when a loaded image exits. Also, this change adds
15949 support for a chainloader on EFI.
f19dbdb7 15950
7f362539 15951 * term/efi/console.c: Include grub/misc.h.
15952 (grub_console_checkkey): Display a scan code on the top for
15953 debugging. This will be removed once the EFI port gets stable.
15954 Correct the scan code mapping.
15955
15956 * kern/efi/mm.c (sort_memory_map): Sort in a descending order to
15957 allocate memory from larger regions, in order to reduce the number
15958 of allocated regions. Otherwise, the MacOSX loader panics.
15959 (filter_memory_map): Avoid less than 1MB for compatibility with
15960 other loaders.
15961 (add_memory_regions): Allocate from the tail of a region, if
15962 possible, to avoid allocating a region near to 1MB, for the MacOSX
15963 loader.
15964
15965 * kern/efi/init.c (grub_efi_set_prefix): Specify
15966 GRUB_EFI_IMAGE_HANDLE to grub_efi_get_loaded_image.
15967
15968 * kern/efi/efi.c (grub_efi_get_loaded_image): Accept a new
15969 argument IMAGE_HANDLE and specify it to get a loaded image.
15970 (grub_arch_modules_addr): Specify GRUB_EFI_IMAGE_HANDLE to
15971 grub_efi_get_loaded_image.
fe6b695a 15972 (grub_efi_get_filename): Divide the length by the size of
7f362539 15973 grub_efi_char16_t.
15974 (grub_efi_get_device_path): New function.
15975 (grub_efi_print_device_path): Print End Device Path nodes. Divide
15976 the length by the size of grub_efi_char16_t for a file path device
15977 path node.
15978
15979 * kern/loader.c (grub_loader_noreturn): New variable.
15980 (grub_loader_set): Accept a new argument NORETURN. Set
15981 GRUB_LOADER_NORETURN to NORETURN.
15982 All callers changed.
15983 (grub_loader_boot): If GRUB_LOADER_NORETURN is false, do not call
15984 grub_machine_fini.
15985
15986 * include/grub/efi/efi.h (grub_efi_get_device_path): New
15987 prototype.
15988 (grub_efi_get_loaded_image): Take an argument to specify an image
15989 handle.
15990
15991 * include/grub/loader.h (grub_loader_set): Added one more argument
15992 NORETURN.
15993
15994 * disk/efi/efidisk.c (make_devices): Use grub_efi_get_device_path
15995 instead of grub_efi_open_protocol.
15996 (grub_efidisk_get_device_name): Likewise.
15997 (grub_efidisk_close): Print a newline.
15998 (grub_efidisk_get_device_handle): Fixed to use
15999 GRUB_EFI_DEVICE_PATH_SUBTYPE instead of
16000 GRUB_EFI_DEVICE_PATH_TYPE.
16001
16002 * disk/efi/efidisk.c (device_path_guid): Moved to ...
16003 * kern/efi/efi.c (device_path_guid): ... here.
16004
16005 * conf/i386-efi.rmk (pkgdata_MODULES): Added _chain.mod and
16006 chain.mod.
16007 (kernel_mod_HEADERS): Added efi/disk.h.
16008 (_chain_mod_SOURCES): New variable.
16009 (_chain_mod_CFLAGS): Likewise.
16010 (_chain_mod_LDFLAGS): Likewise.
16011 (chain_mod_SOURCES): Likewise.
16012 (chain_mod_CFLAGS): Likewise.
16013 (chain_mod_LDFLAGS): Likewise.
16014
16015 * DISTLIST: Added include/grub/efi/chainloader.h,
16016 loader/efi/chainloader.c and loader/efi/chainloader_normal.c.
16017
16018 * include/grub/efi/chainloader.h: New file.
16019 * loader/efi/chainloader.c: Likewise.
16020 * loader/efi/chainloader_normal.c: Likewise.
16021
c0111d6e 160222006-04-30 Marco Gerards <marco@gnu.org>
16023
16024 * commands/configfile.c (grub_cmd_source): New function.
16025 (GRUB_MOD_INIT): Register the commands `source' and `.'.
16026 (GRUB_MOD_FINI): De-register the commands `source' and `.'.
16027
df5341da 160282006-04-30 Marco Gerards <marco@gnu.org>
16029
16030 * normal/execute.c (grub_script_execute_cmd): Change the return
16031 type to `grub_err_t'. Correctly return the error.
16032 (grub_script_execute_cmdline): In case a command line is not a
16033 command or a function, try to interpret it as an assignment.
16034
f85934bd 160352006-04-30 Yoshinori K. Okuji <okuji@enbug.org>
16036
16037 * fs/hfsplus.c (grub_hfsplus_read_block): Fixed a memory leak.
16038 (grub_hfsplus_iterate_dir): Reordered to skip unknown nodes. Also,
16039 skip a node whose name is obviously invalid as UTF-16,
16040 i.e. contains a NUL character. Stop the iteration when the last
16041 directory entry is found. Instead of using the return value of
16042 grub_hfsplus_btree_iterate_node, store the value in RET and use
16043 it, because the iterator can be stopped by the last directory
16044 entry.
16045
8f8a2cf8 160462006-04-30 Marco Gerards <marco@gnu.org>
16047
16048 * include/grub/env.h (grub_env_export): New prototype. Reported
16049 by Jan C. Kleinsorge <jan.kleinsorge@udo.edu>.
16050
a27e84ce 160512006-04-30 Marco Gerards <marco@gnu.org>
16052
16053 * fs/hfsplus.c (grub_hfsplus_iterate_dir): Correctly calculate the
16054 size of the extents in a catalog file record.
16055
eaef0553 160562006-04-29 Marco Gerards <marco@gnu.org>
16057
16058 * commands/configfile.c (grub_cmd_configfile): Execute the
16059 configfile within its own context.
16060
16061 * include/grub/env.h (grub_env_context_open): New prototype.
16062 (grub_env_context_close): Likewise.
16063
16064 * kern/env.c (grub_env): Removed.
16065 (grub_env_sorted): Likewise.
16066 (grub_env_context): New variable.
16067 (grub_env_var_context): Likewise.
16068 (grub_env_find): Search both the active context and the global
16069 context.
16070 (grub_env_context_open): New function.
16071 (grub_env_context_close): Likewise.
16072 (grub_env_insert): Likewise.
16073 (grub_env_remove): Likewise.
16074 (grub_env_export): Likewise.
16075 (grub_env_set): Changed to use helper functions to avoid code
16076 duplication.
16077 (grub_env_iterate): Rewritten so both the current context and the
16078 global context are being used.
16079
16080 * normal/command.c (export_command): New function.
16081 (grub_command_init): Register the `export' function.
16082
7b455f4d 160832006-04-26 Yoshinori K. Okuji <okuji@enbug.org>
16084
16085 * util/i386/pc/grub-mkimage.c (compress_kernel): Cast arguments
16086 explicitly to suppress gcc's warnings.
16087 * fs/fat.c (grub_fat_find_dir): Likewise.
16088 (grub_fat_label): Likewise.
16089 * fs/xfs.c (grub_xfs_read_inode): Likewise.
16090 (grub_xfs_mount): Likewise.
16091 (grub_xfs_label): Likewise.
16092 * fs/affs.c (grub_affs_mount): Likewise.
16093 (grub_affs_label): Likewise.
16094 (grub_affs_iterate_dir): Likewise.
16095 * fs/sfs.c (grub_sfs_mount): Likewise.
16096 (grub_sfs_iterate_dir): Likewise.
16097 * fs/ufs.c (grub_ufs_lookup_symlink): Likewise.
16098 * fs/hfs.c (grub_hfs_mount): Likewise.
16099 (grub_hfs_cmp_catkeys): Likewise.
16100 (grub_hfs_find_dir): Likewise.
16101 (grub_hfs_dir): Likewise.
16102 (grub_hfs_label): Likewise.
16103 * fs/jfs.c (grub_jfs_mount): Likewise.
16104 (grub_jfs_opendir): Likewise.
16105 (grub_jfs_getent): Likewise.
16106 (grub_jfs_lookup_symlink): Likewise.
16107 (grub_jfs_label): Likewise.
16108 * fs/hfsplus.c (grub_hfsplus_cmp_catkey): Likewise.
16109 (grub_hfsplus_iterate_dir): Likewise.
16110 (grub_hfsplus_btree_iterate_node): Made static.
16111
16112 * util/grub-emu.c (prefix): New variable.
16113 (grub_machine_set_prefix): New function.
16114 (main): Do not set the environment variable "prefix" here. Only
16115 set PREFIX, which is used later by grub_machine_set_prefix.
16116
16117 * include/grub/video.h: Do not include grub/symbol.h.
16118 (grub_video_register): Not exported. This symbol is not defined in
16119 the kernel.
16120 (grub_video_unregister): Likewise.
16121 (grub_video_iterate): Likewise.
16122 (grub_video_setup): Likewise.
16123 (grub_video_restore): Likewise.
16124 (grub_video_get_info): Likewise.
16125 (grub_video_get_blit_format): Likewise.
16126 (grub_video_set_palette): Likewise.
16127 (grub_video_get_palette): Likewise.
16128 (grub_video_set_viewport): Likewise.
16129 (grub_video_get_viewport): Likewise.
16130 (grub_video_map_color): Likewise.
16131 (grub_video_map_rgb): Likewise.
16132 (grub_video_map_rgba): Likewise.
16133 (grub_video_fill_rect): Likewise.
16134 (grub_video_blit_glyph): Likewise.
16135 (grub_video_blit_bitmap): Likewise.
16136 (grub_video_blit_render_target): Likewise.
16137 (grub_video_scroll): Likewise.
16138 (grub_video_swap_buffers): Likewise.
16139 (grub_video_create_render_target): Likewise.
16140 (grub_video_delete_render_target): Likewise.
16141 (grub_video_set_active_render_target): Likewise.
16142
16143 * include/grub/symbol.h [GRUB_SYMBOL_GENERATOR] (EXPORT_FUNC):
16144 Undefined.
16145 [GRUB_SYMBOL_GENERATOR] (EXPORT_VAR): Likewise.
16146
16147 * conf/sparc64-ieee1275.rmk (grubof_symlist.c): Depended on
16148 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
16149 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
16150 instead of $(srcdir)/genkernsyms.sh.
16151
16152 * conf/powerpc-ieee1275.rmk (grubof_symlist.c): Depended on
16153 config.h. Use gensymlist.sh instead of $(srcdir)/gensymlist.sh.
16154 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
16155 instead of $(srcdir)/genkernsyms.sh.
16156
16157 * conf/i386-pc.rmk (symlist.c): Depended on config.h. Use
16158 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
16159 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
16160 instead of $(srcdir)/genkernsyms.sh.
16161
16162 * conf/i386-efi.rmk (symlist.c): Depended on config.h. Use
16163 gensymlist.sh instead of $(srcdir)/gensymlist.sh.
16164 (kernel_syms.lst): Depended on config.h. Use genkernsyms.sh
16165 instead of $(srcdir)/genkernsyms.sh.
16166
16167 * configure.ac (AC_CONFIG_FILES): Added gensymlist.sh and
16168 genkernsyms.sh.
16169
16170 * Makefile.in (DISTCLEANFILES): Added gensymlist.sh and
16171 genkernsyms.sh.
16172 (gensymlist.sh): New target.
16173 (genkernsyms.sh): Likewise.
16174
16175 * DISTLIST: Removed genkernsyms.sh and gensymlist.sh. Added
16176 genkernsyms.sh.in and gensymlist.sh.in.
16177
16178 * genkernsyms.sh: Removed.
16179 * gensymlist.sh: Likewise.
f19dbdb7 16180
7b455f4d 16181 * genkernsyms.sh.in: New file.
16182 * gensymlist.sh.in: Likewise.
16183
1885bb27 161842006-04-25 Hollis Blanchard <hollis@penguinppc.org>
16185
16186 * kern/powerpc/ieee1275/init.c (grub_machine_set_prefix): Do not
16187 clobber "prefix", since we may have already set it manually.
16188
71538dff 161892006-04-25 Hollis Blanchard <hollis@penguinppc.org>
16190
16191 * kern/misc.c (abort): New alias for grub_abort.
16192
2965c7cc 161932006-04-25 Yoshinori K. Okuji <okuji@enbug.org>
16194
16195 A new machine-specific function "grub_machine_set_prefix" is
16196 defined. This is called after loading modules, so that a prefix
16197 initialization can use modules. Also, this change adds an
16198 intensive debugging feature for the memory manager via the
16199 configure option "--enable-mm-debug".
f19dbdb7 16200
2965c7cc 16201 * partmap/gpt.c (gpt_partition_map_iterate): Add one more into
16202 PART.LEN.
16203
16204 * kern/sparc64/ieee1275/init.c (abort): Removed.
16205 (grub_stop): Likewise.
16206 (grub_exit): New function.
16207 (grub_set_prefix): Renamed to ...
16208 (grub_machine_set_prefix): ... this.
16209 (grub_machine_init): Do not call grub_set_prefix.
16210
16211 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Renamed to ...
16212 (grub_machine_set_prefix): ... this.
16213 (grub_machine_init): Do not call grub_set_prefix.
16214
16215 * kern/i386/pc/init.c (grub_machine_set_prefix): New function.
16216 (grub_machine_init): Do not set the prefix here.
16217
16218 * kern/i386/efi/init.c (grub_machine_set_prefix): New function.
16219
16220 * kern/efi/init.c: Include grub/mm.h.
16221 (grub_efi_set_prefix): New function.
16222
16223 * kern/efi/efi.c (grub_exit): Call grub_efi_fini.
16224 (grub_efi_get_filename): New function.
16225 (grub_print_device_path): Renamed to ...
16226 (grub_efi_print_device_path): ... this.
16227
16228 * kern/mm.c [MM_DEBUG] (grub_malloc): Undefined.
16229 [MM_DEBUG] (grub_realloc): Likewise.
16230 [MM_DEBUG] (grub_free): Likewise.
16231 [MM_DEBUG] (grub_memalign): Likewise.
16232 [MM_DEBUG] (grub_mm_debug): New variable.
16233 [MM_DEBUG] (grub_debug_malloc): New function.
16234 [MM_DEBUG] (grub_debug_free): New function.
16235 [MM_DEBUG] (grub_debug_realloc): New function.
16236 [MM_DEBUG] (grub_debug_memalign): New function.
16237
16238 * kern/misc.c (grub_abort): Print a newline to distinguish
16239 the message.
16240
16241 * kern/main.c (grub_main): Call grub_machine_set_prefix and
16242 grub_set_root_dev after loading modules. This is necessary when
16243 setting a prefix depends on modules.
16244
16245 * include/grub/efi/efi.h (grub_print_device_path): Renamed to ...
16246 (grub_efi_print_device_path): ... this.
16247 (grub_efi_get_filename): New prototype.
16248 (grub_efi_set_prefix): Likewise.
16249
16250 * include/grub/efi/disk.h: Include grub/efi/api.h, grub/symbol.h
16251 and grub/disk.h.
16252 (grub_efidisk_get_device_handle): New prototype.
16253 (grub_efidisk_get_device_name): Likewise.
16254
16255 * include/grub/mm.h: Include config.h.
16256 (MM_DEBUG): Removed.
16257 [MM_DEBUG && !GRUB_UTIL] (grub_mm_debug): New prototype.
16258 [MM_DEBUG && !GRUB_UTIL] (grub_malloc): New macro.
16259 [MM_DEBUG && !GRUB_UTIL] (grub_realloc): Likewise.
16260 [MM_DEBUG && !GRUB_UTIL] (grub_memalign): Likewise.
16261 [MM_DEBUG && !GRUB_UTIL] (grub_free): Likewise.
16262 [MM_DEBUG && !GRUB_UTIL] (grub_debug_malloc): New prototype.
16263 [MM_DEBUG && !GRUB_UTIL] (grub_debug_realloc): New prototype.
16264 [MM_DEBUG && !GRUB_UTIL] (grub_debug_memalign): New prototype.
16265 [MM_DEBUG && !GRUB_UTIL] (grub_debug_free): New prototype.
16266
16267 * include/grub/kernel.h (grub_machine_set_prefix): New prototype.
16268
16269 * disk/efi/efidisk.c: Include grub/partition.h.
16270 (iterate_child_devices): New function.
16271 (add_device): First, compare only last device path nodes, so that
16272 devices are sorted by the types.
16273 (grub_efidisk_get_device_handle): New function.
16274 (grub_efidisk_get_device_name): Likewise.
16275
16276 * configure.ac (--enable-mm-debug): New option to enable the
16277 memory manager debugging feature. This makes the binary much
16278 bigger, so is disabled by default.
16279
9cacaa17 162802006-04-23 Yoshinori K. Okuji <okuji@enbug.org>
16281
16282 Use grub_abort instead of grub_stop, and grub_exit must be
16283 define in each architecture now. Also, this change adds support
16284 for EFI disks.
f19dbdb7 16285
9cacaa17 16286 * util/i386/pc/grub-probefs.c: Include grub/term.h.
16287 (grub_getkey): New function.
16288 (grub_term_get_current): Likewise.
16289
16290 * util/i386/pc/grub-setup.c: Include grub/term.h.
16291 (grub_getkey): New function.
16292 (grub_term_get_current): Likewise.
16293
16294 * util/misc.c (grub_stop): Renamed to ...
16295 (grub_exit): ... this.
16296
16297 * kern/powerpc/ieee1275/init.c (abort): Renamed to ...
16298 (grub_exit): ... this.
16299 (grub_machine_init): Use grub_abort instead of abort.
16300 (grub_stop): Removed.
16301
16302 * kern/powerpc/ieee1275/cmain.c (cmain): Use grub_abort instead of
16303 abort.
16304
16305 * kern/i386/pc/startup.S (grub_exit): New function.
16306 (cold_reboot): New label.
16307
16308 * kern/efi/init.c: Include grub/efi/disk.h and grub/env.h.
16309 (grub_efi_init): Call grub_efidisk_init.
16310 (grub_efi_fini): Call grub_efidisk_fini.
16311
16312 * kern/efi/efi.c: Include grub/mm.h.
16313 (grub_efi_console_control_guid): Renamed to ...
16314 (console_control_guid): ... this.
16315 (grub_efi_loaded_image_guid): Renamed to ...
16316 (loaded_image_guid): ... this.
16317 (grub_efi_locate_handle): New function.
16318 (grub_efi_open_protocol): Likewise.
16319 (grub_efi_set_text_mode): Use CONSOLE_CONTROL_GUID instead of
16320 GRUB_EFI_CONSOLE_CONTROL_GUID.
16321 (grub_efi_exit): Removed.
16322 (grub_stop): Likewise.
16323 (grub_efi_get_loaded_image): Use grub_efi_open_protocol.
16324 (grub_exit): New function.
16325 (grub_print_device_path): Likewise.
16326
16327 * kern/rescue.c (grub_rescue_cmd_exit): New function.
16328 (grub_enter_rescue_mode): Register "exit".
16329
16330 * kern/misc.c (grub_real_dprintf): A cosmetic change.
16331 (grub_abort): New function.
16332
16333 * kern/err.c (grub_fatal): Use grub_abort instead of grub_stop.
16334
16335 * include/grub/sparc64/ieee1275/kernel.h (abort): Removed.
16336
16337 * include/grub/powerpc/ieee1275/kernel.h (abort): Removed.
16338
16339 * include/grub/efi/efi.h (grub_efi_exit): Removed.
16340 (grub_print_device_path): New prototype.
16341 (grub_efi_locate_handle): Likewise.
16342 (grub_efi_open_protocol): Likewise.
16343
16344 * include/grub/efi/disk.h (grub_efidisk_fini): New file.
16345 * disk/efi/efidisk.c: Likewise.
16346
16347 * DISTLIST: Added disk/efi/efidisk.c and include/grub/efi/disk.h.
16348
16349 * include/grub/efi/console_control.h
16350 (GRUB_EFI_CONSOLE_CONTROL_GUID): Use an array for the last 8 bytes.
16351
16352 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): Specify the
16353 last 8 bytes as an array.
16354 (GRUB_EFI_DISK_IO_GUID): New macro.
16355 (GRUB_EFI_BLOCK_IO_GUID): Likewise.
16356 (GRUB_EFI_DEVICE_PATH_GUID): Likewise.
16357 (grub_efi_ipv6_address_t): Change the type to grub_uint16_t from
16358 grub_uint8_t.
16359 (struct grub_efi_guid): Use an array to specify the last 8 bytes.
16360 (struct grub_efi_device_path): Rename the member "sub_type" to
16361 "subtype".
16362 (GRUB_EFI_DEVICE_PATH_TYPE): New macro.
16363 (GRUB_EFI_DEVICE_PATH_SUBTYPE): Likewise.
16364 (GRUB_EFI_DEVICE_PATH_LENGTH): Likewise.
16365 (GRUB_EFI_END_DEVICE_PATH_TYPE): Likewise.
16366 (GRUB_EFI_END_ENTIRE_DEVICE_PATH_SUBTYPE): Likewise.
16367 (GRUB_EFI_END_THIS_DEVICE_PATH_SUBTYPE): Likewise.
16368 (GRUB_EFI_END_ENTIRE_DEVICE_PATH): Likewise.
16369 (GRUB_EFI_NEXT_DEVICE_PATH): Likewise.
16370 (GRUB_EFI_HARDWARE_DEVICE_PATH_TYPE): Likewise.
16371 (GRUB_EFI_PCI_DEVICE_PATH_SUBTYPE): Likewise.
16372 (struct grub_efi_pci_device_path): New structure.
16373 (grub_efi_pci_device_path_t): New type.
16374 (GRUB_EFI_PCCARD_DEVICE_PATH_SUBTYPE): New macro.
16375 (struct grub_efi_pccard_device_path): New structure.
16376 (grub_efi_pccard_device_path_t): New type.
16377 (GRUB_EFI_MEMORY_MAPPED_DEVICE_PATH_SUBTYPE): New macro.
16378 (struct grub_efi_memory_mapped_device_path): New structure.
16379 (grub_efi_memory_mapped_device_path_t): New type.
16380 (GRUB_EFI_VENDOR_DEVICE_PATH_SUBTYPE): New macro.
16381 (struct grub_efi_vendor_device_path): New structure.
16382 (grub_efi_vendor_device_path_t): New type.
16383 (GRUB_EFI_CONTROLLER_DEVICE_PATH_SUBTYPE): New macro.
16384 (struct grub_efi_controller_device_path): New structure.
16385 (grub_efi_controller_device_path_t): New type.
16386 (GRUB_EFI_ACPI_DEVICE_PATH_TYPE): New macro.
16387 (GRUB_EFI_ACPI_DEVICE_PATH_SUBTYPE): Likewise.
16388 (struct grub_efi_acpi_device_path): New structure.
16389 (grub_efi_acpi_device_path_t): New type.
16390 (GRUB_EFI_EXPANDED_ACPI_DEVICE_PATH_SUBTYPE): New macro.
16391 (struct grub_efi_expanded_acpi_device_path): New structure.
16392 (grub_efi_expanded_acpi_device_path_t): New type.
16393 (GRUB_EFI_EXPANDED_ACPI_HIDSTR): New macro.
16394 (GRUB_EFI_EXPANDED_ACPI_UIDSTR): Likewise.
16395 (GRUB_EFI_EXPANDED_ACPI_CIDSTR): Likewise.
16396 (GRUB_EFI_MESSAGING_DEVICE_PATH_TYPE): Likewise.
16397 (GRUB_EFI_ATAPI_DEVICE_PATH_SUBTYPE): Likewise.
16398 (struct grub_efi_atapi_device_path): New structure.
16399 (grub_efi_atapi_device_path_t): New type.
16400 (GRUB_EFI_FIBRE_CHANNEL_DEVICE_PATH_SUBTYPE): New macro.
16401 (struct grub_efi_fibre_channel_device_path): New structure.
16402 (grub_efi_fibre_channel_device_path_t): New type.
16403 (GRUB_EFI_1394_DEVICE_PATH_SUBTYPE): New macro.
16404 (struct grub_efi_1394_device_path): New structure.
16405 (grub_efi_1394_device_path_t): New type.
16406 (GRUB_EFI_USB_DEVICE_PATH_SUBTYPE): New macro.
16407 (struct grub_efi_usb_device_path): New structure.
16408 (grub_efi_usb_device_path_t): New type.
16409 (GRUB_EFI_USB_CLASS_DEVICE_PATH_SUBTYPE): New macro.
16410 (struct grub_efi_usb_class_device_path): New structure.
16411 (grub_efi_usb_class_device_path_t): New type.
16412 (GRUB_EFI_I2O_DEVICE_PATH_SUBTYPE): New macro.
16413 (struct grub_efi_i2o_device_path): New structure.
16414 (grub_efi_i2o_device_path_t): New type.
16415 (GRUB_EFI_MAC_ADDRESS_DEVICE_PATH_SUBTYPE): New macro.
16416 (struct grub_efi_mac_address_device_path): New structure.
16417 (grub_efi_mac_address_device_path_t): New type.
16418 (GRUB_EFI_IPV4_DEVICE_PATH_SUBTYPE): New macro.
16419 (struct grub_efi_ipv4_device_path): New structure.
16420 (grub_efi_ipv4_device_path_t): New type.
16421 (GRUB_EFI_IPV6_DEVICE_PATH_SUBTYPE): New macro.
16422 (struct grub_efi_ipv6_device_path): New structure.
16423 (grub_efi_ipv6_device_path_t): New type.
16424 (GRUB_EFI_INFINIBAND_DEVICE_PATH_SUBTYPE): New macro.
16425 (struct grub_efi_infiniband_device_path): New structure.
16426 (grub_efi_infiniband_device_path_t): New type.
16427 (GRUB_EFI_UART_DEVICE_PATH_SUBTYPE): New macro.
16428 (struct grub_efi_uart_device_path): New structure.
16429 (grub_efi_uart_device_path_t): New type.
16430 (GRUB_EFI_VENDOR_MESSAGING_DEVICE_PATH_SUBTYPE): New macro.
16431 (struct grub_efi_vendor_messaging_device_path): New structure.
16432 (grub_efi_vendor_messaging_device_path_t): New type.
16433 (GRUB_EFI_MEDIA_DEVICE_PATH_TYPE): New macro.
16434 (GRUB_EFI_HARD_DRIVE_DEVICE_PATH_SUBTYPE): Likewise.
16435 (struct grub_efi_hard_drive_device_path): New structure.
16436 (grub_efi_hard_drive_device_path_t): New type.
16437 (GRUB_EFI_CDROM_DEVICE_PATH_SUBTYPE): New macro.
16438 (struct grub_efi_cdrom_device_path): New structure.
16439 (grub_efi_cdrom_device_path_t): New type.
16440 (GRUB_EFI_VENDOR_MEDIA_DEVICE_PATH_SUBTYPE): New macro.
16441 (struct grub_efi_vendor_media_device_path): New structure.
16442 (grub_efi_vendor_media_device_path_t): New type.
16443 (GRUB_EFI_FILE_PATH_DEVICE_PATH_SUBTYPE): New macro.
16444 (struct grub_efi_file_path_device_path): New structure.
16445 (grub_efi_file_path_device_path_t): New type.
16446 (GRUB_EFI_PROTOCOL_DEVICE_PATH_SUBTYPE): New macro.
16447 (struct grub_efi_protocol_device_path): New structure.
16448 (grub_efi_protocol_device_path_t): New type.
16449 (GRUB_EFI_BIOS_DEVICE_PATH_TYPE): New macro.
16450 (GRUB_EFI_BIOS_DEVICE_PATH_SUBTYPE): Likewise.
16451 (struct grub_efi_bios_device_path): New structure.
16452 (grub_efi_bios_device_path_t): New type.
16453 (struct grub_efi_disk_io): New structure.
16454 (grub_efi_disk_io_t): New type.
16455 (struct grub_efi_block_io_media): New structure.
16456 (grub_efi_block_io_media_t): New type.
16457 (struct grub_efi_block_io): New structure.
16458 (grub_efi_block_io_t): New type.
16459
16460 * include/grub/misc.h (grub_stop): Removed.
16461 (grub_exit): New prototype.
16462 (grub_abort): Likewise.
16463
16464 * include/grub/disk.h (enum grub_disk_dev_id): Added
16465 GRUB_DISK_DEVICE_EFIDISK_ID.
16466
16467 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added
16468 disk/efi/efidisk.c.
16469 (kernel_syms.lst): Remove the target if an error occurs.
16470
49986a9f 164712006-04-22 Yoshinori K. Okuji <okuji@enbug.org>
16472
16473 * kern/misc.c (grub_lltoa): Rewritten the decimal conversion part,
16474 as it was simply too buggy.
16475
970d3b8a 164762006-04-21 Yoshinori K. Okuji <okuji@enbug.org>
16477
16478 * kern/misc.c (grub_lltoa): New function.
16479 (grub_vsprintf): Added support for the long long suffix,
16480 i.e. "ll".
16481
ff04ec24 164822006-04-20 Hollis Blanchard <hollis@penguinppc.org>
16483
16484 * Makefile.in (LDFLAGS): Add variable.
16485 (LD): Remove variable.
16486 * configure.ac: Add -m32 to LDFLAGS.
16487 * genmk.rb (PModule#rule): Use $(CC) instead of $(LD).
16488 * conf/powerpc-ieee1275.rmk (COMMON_LDFLAGS): Add variable.
16489 (grubof_LDFLAGS): Use $(COMMON_LDFLAGS).
16490 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS, normal_mod_LDFLAGS,
16491 suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS): New
16492 variables.
16493 * conf/sparc64-ieee1275.rmk (COMMON_LDFLAGS): Add -nostdlib.
16494 * conf/i386-pc.rmk (COMMON_LDFLAGS): Add -nostdlib.
16495 * conf/i386-efi.rmk (COMMON_LDFLAGS): Add -nostdlib.
16496
37e5e1a4 164972006-04-20 Vesa Jaaskelainen <chaac@nic.fi>
16498
16499 * term/gfxterm.c (grub_gfxterm_getcharwidth): Fixed character
16500 length for unknown glyph.
16501
c352d8dd 165022006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
16503
2eab1c0d 16504 Add support for pre-loaded modules into the EFI port.
f19dbdb7 16505
2eab1c0d 16506 * util/i386/efi/grub-mkimage.c (make_mods_section): Rewritten
16507 completely. Accept one more argument DIR. The caller has changed.
16508
16509 * kern/i386/efi/init.c (grub_arch_modules_addr): Removed.
16510
16511 * kern/efi/efi.c: Include grub/efi/pe32.h and grub/kernel.h.
16512 (grub_efi_loaded_image_guid): New variable.
16513 (grub_efi_get_loaded_image): New function.
16514 (grub_arch_modules_addr): Likewise.
16515
16516 * include/grub/efi/efi.h (grub_efi_get_loaded_image): New
16517 prototype.
16518
16519 * include/grub/efi/api.h (GRUB_EFI_LOADED_IMAGE_GUID): New macro.
16520 (struct grub_efi_loaded_image): New structure.
16521 (grub_efi_loaded_image_t): New type.
16522
165232006-04-20 Yoshinori K. Okuji <okuji@enbug.org>
f19dbdb7 16524
c352d8dd 16525 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Compare the file
16526 size with GRUB_OS_AREA_SIZE as grub_size_t instead of
16527 grub_ssize_t. Reported by Jeff Chua <jeff84@silk.corp.fedex.com>.
16528
6d01d6b4 165292006-04-19 Roger Leigh <rleigh@whinlatter.ukfsn.org>
16530
16531 * DISTLIST: Added `util/powerpc/ieee1275/grub-install.in'.
16532
976a4ea0 165332006-04-19 Yoshinori K. Okuji <okuji@enbug.org>
16534
16535 * DISTLIST: Added include/grub/efi/console.h,
16536 include/grub/efi/time.h, include/grub/i386/efi/kernel.h,
16537 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
16538
16539 * include/grub/efi/console.h: New file.
16540 * include/grub/efi/time.h: Likewise.
16541 * include/grub/i386/efi/kernel.h: Likewise.
16542 * kern/efi/init.c: Likewise.
16543 * kern/efi/mm.c: Likewise.
16544 * term/efi/console.c: Likewise.
f19dbdb7 16545
976a4ea0 16546 * kern/i386/efi/init.c: Do not include grub/machine/time.h.
16547 (grub_stop): Removed.
16548 (grub_get_rtc): Likewise.
16549 (grub_machine_init): Simply call grub_efi_init.
16550 (grub_machine_fini): Call grub_efi_fini.
16551
16552 * kern/efi/efi.c: Include grub/machine/time.h and grub/term.h.
16553 (grub_efi_output_string): Removed.
16554 (grub_efi_stall): New function.
16555 (grub_stop): Likewise.
16556 (grub_get_rtc): Likewise.
16557
16558 * include/grub/efi/efi.h (grub_efi_output_string): Removed.
16559 (grub_efi_stall): New prototype.
16560 (grub_efi_allocate_pages): Likewise.
16561 (grub_efi_free_pages): Likewise.
16562 (grub_efi_get_memory_map): Likewise.
16563 (grub_efi_mm_init): Likewise.
16564 (grub_efi_mm_fini): Likewise.
16565 (grub_efi_init): Likewise.
16566 (grub_efi_fini): Likewise.
16567
16568 * include/grub/i386/efi/time.h: Do not include
16569 grub/symbol.h. Include grub/efi/time.h.
16570 (GRUB_TICKS_PER_SECOND): Removed.
16571 (grub_get_rtc): Likewise.
16572
16573 * include/grub/efi/api.h (struct grub_efi_memory_descriptor):
16574 Added padding. The EFI spec is buggy.
16575 (GRUB_EFI_BLACK): New macro.
16576 (GRUB_EFI_BLUE): Likewise.
16577 (GRUB_EFI_GREEN): Likewise.
16578 (GRUB_EFI_CYAN): Likewise.
16579 (GRUB_EFI_RED): Likewise.
16580 (GRUB_EFI_MAGENTA): Likewise.
16581 (GRUB_EFI_BROWN): Likewise.
16582 (GRUB_EFI_LIGHTGRAY): Likewise.
16583 (GRUB_EFI_BRIGHT): Likewise.
16584 (GRUB_EFI_DARKGRAY): Likewise.
16585 (GRUB_EFI_LIGHTBLUE): Likewise.
16586 (GRUB_EFI_LIGHTGREEN): Likewise.
16587 (GRUB_EFI_LIGHTCYAN): Likewise.
16588 (GRUB_EFI_LIGHTRED): Likewise.
16589 (GRUB_EFI_LIGHTMAGENTA): Likewise.
16590 (GRUB_EFI_YELLOW): Likewise.
16591 (GRUB_EFI_WHITE): Likewise.
16592 (GRUB_EFI_BACKGROUND_BLACK): Likewise.
16593 (GRUB_EFI_BACKGROUND_BLUE): Likewise.
16594 (GRUB_EFI_BACKGROUND_GREEN): Likewise.
16595 (GRUB_EFI_BACKGROUND_CYAN): Likewise.
16596 (GRUB_EFI_BACKGROUND_RED): Likewise.
16597 (GRUB_EFI_BACKGROUND_MAGENTA): Likewise.
16598 (GRUB_EFI_BACKGROUND_BROWN): Likewise.
16599 (GRUB_EFI_BACKGROUND_LIGHTGRAY): Likewise.
16600 (GRUB_EFI_TEXT_ATTR): Likewise.
16601
16602 * conf/i386-efi.rmk (kernel_mod_SOURCES): Added kern/efi/efi.c,
16603 kern/efi/init.c, kern/efi/mm.c, and term/efi/console.c.
16604 (kernel_mod_HEADERS): Added efi/time.h.
16605
83709125 166062006-04-18 Yoshinori K. Okuji <okuji@enbug.org>
16607
16608 * DISTLIST: Added conf/i386-efi.mk, conf/i386-efi.rmk,
16609 include/grub/efi/api.h, include/grub/efi/console_control.h,
16610 include/grub/efi/efi.h, include/grub/efi/pe32.h,
16611 include/grub/i386/efi/time.h, kern/efi/efi.c,
16612 kern/i386/efi/init.c, kern/i386/efi/startup.S,
16613 and util/i386/efi/grub-mkimage.c.
16614
16615 * Makefile.in (RMKFILES): Added i386-efi.rmk.
16616
16617 * genmk.rb (PModule#rule): Do not export symbols if
16618 #{prefix}_EXPORTS is set to "no".
16619
16620 * conf/i386-efi.mk: New file.
16621 * conf/i386-efi.rmk: Likewise.
16622 * include/grub/efi/api.h: Likewise.
16623 * include/grub/efi/console_control.h: Likewise.
16624 * include/grub/efi/efi.h: Likewise.
16625 * include/grub/efi/pe32.h: Likewise.
16626 * include/grub/i386/efi/time.h: Likewise.
16627 * kern/efi/efi.c: Likewise.
16628 * kern/i386/efi/init.c: Likewise.
16629 * kern/i386/efi/startup.S: Likewise.
16630 * util/i386/efi/grub-mkimage.c: Likewise.
16631
166322006-04-17 Marco Gerards <marco@gnu.org>
bfa2bd9e 16633
16634 * include/grub/script.h: Include <grub/parser.h> and
16635 "grub_script.tab.h".
16636 (struct grub_lexer_param): New struct.
16637 (struct grub_parser_param): Likewise.
16638 (grub_script_create_arglist): Pass the state in an argument.
16639 (grub_script_add_arglist): Likewise.
16640 (grub_script_create_cmdline): Likewise.
16641 (grub_script_create_cmdblock): Likewise.
16642 (grub_script_create_cmdif): Likewise.
16643 (grub_script_create_cmdmenu): Likewise.
16644 (grub_script_add_cmd): Likewise.
16645 (grub_script_arg_add): Likewise.
16646 (grub_script_lexer_ref): Likewise.
16647 (grub_script_lexer_deref): Likewise.
16648 (grub_script_lexer_record_start): Likewise.
16649 (grub_script_lexer_record_stop): Likewise.
16650 (grub_script_mem_record): Likewise.
16651 (grub_script_mem_record_stop): Likewise.
16652 (grub_script_malloc): Likewise.
16653 (grub_script_yylex): Likewise.
16654 (grub_script_yyparse): Likewise.
16655 (grub_script_yyerror): Likewise.
16656 (grub_script_yylex): Likewise.
16657 (grub_script_lexer_init): Return the state.
16658
16659 * normal/lexer.c (grub_script_lexer_state): Removed variable.
16660 (grub_script_lexer_done): Likewise.
16661 (grub_script_lexer_getline): Likewise.
16662 (grub_script_lexer_refs): Likewise.
16663 (script): Likewise.
16664 (newscript): Likewise.
16665 (record): Likewise.
16666 (recording): Likewise.
16667 (recordpos): Likewise.
16668 (recordlen): Likewise.
16669 (grub_script_lexer_init): Return the state instead of setting
16670 global variables.
16671 (grub_script_lexer_ref): Use the newly added argument for state
16672 instead of globals.
16673 (grub_script_lexer_deref): Likewise.
16674 (grub_script_lexer_record_start): Likewise.
16675 (grub_script_lexer_record_stop): Likewise.
16676 (recordchar): Likewise.
16677 (nextchar): Likewise.
16678 (grub_script_yylex2): Likewise.
16679 (grub_script_yylex): Likewise.
16680 (grub_script_yyerror): Likewise.
16681
16682 * normal/parser.y (func_mem): Removed variable.
16683 (menu_entry): Likewise.
16684 (err): Likewise.
16685 (%lex-param): New parser option.
16686 (%parse-param): Likewise.
16687 (script): Always return the AST.
16688 (argument): Pass the state around.
16689 (arguments): Likewise.
16690 (grubcmd): Likewise.
16691 (commands): Likewise.
16692 (function): Likewise.
16693 (menuentry): Likewise.
16694 (if_statement): Likewise.
16695 (if): Likewise.
16696
16697 * normal/script.c (grub_script_memused): Removed variable.
16698 (grub_script_parsed): Likewise.
16699 (grub_script_malloc): Added a state argument. Use that instead of
16700 global variables.
16701 (grub_script_mem_record): Likewise.
16702 (grub_script_mem_record_stop): Likewise.
16703 (grub_script_arg_add): Likewise.
16704 (grub_script_add_arglist): Likewise.
16705 (grub_script_create_cmdline): Likewise.
16706 (grub_script_create_cmdif): Likewise.
16707 (grub_script_create_cmdmenu): Likewise.
16708 (grub_script_add_cmd): Likewise.
16709 (grub_script_parse): Setup the state before calling the parser.
f19dbdb7 16710
e2a8c904 167112006-04-16 Marco Gerards <marco@gnu.org>
6de2ee99 16712
16713 * normal/command.c (grub_command_init): Remove the title command.
16714
16715 * normal/lexer.c (grub_script_yylex): Renamed from this...
16716 (grub_script_yylex2): ... to this.
16717 (grub_script_yylex): New function. Temporary
16718 introduced to filter some tokens.
16719 (grub_script_yyerror): Print a newline.
16720
16721 * normal/main.c (read_config_file): Output information about the
16722 lines that contain errors. Wait for a key after all lines have
16723 been processed. Don't return an empty menu.
16724
16725 * normal/parser.y (func_mem): Don't initialize.
16726 (menu_entry): Likewise.
16727 (err): New variable.
16728 (script): Don't return anything when an error was encountered.
16729 (ws, returns): Removed rules.
16730 (argument): Disabled concatenated variable support.
16731 (arguments): Remove explicit separators.
16732 (grubcmd): Likewise.
16733 (function): Likewise.
16734 (menuentry): Likewise.
16735 (if): Likewise.
16736 (commands): Likewise. Add error handling.
16737
16738 * normal/script.c (grub_script_create_cmdline): If
16739 `grub_script_parsed' is 0, assume the parser encountered an error.
16740
c9a86192 167412006-04-02 Yoshinori K. Okuji <okuji@enbug.org>
16742
16743 * configure.ac: Add support for EFI. Fix the typo
16744 BUILD_LDDFLAGS. Restore the LDFLAGS after testing.
16745
70f3b243 167462006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
16747
16748 * util/unifont2pff.rb: Removed unnecessary byte ordering. Now
16749 foreign multibyte characters should be shown correctly.
16750
65f201ad 167512006-04-01 Vesa Jaaskelainen <chaac@nic.fi>
16752
16753 * normal/main.c (grub_normal_menu_addentry): Fixed menu size
16754 calculation.
16755 (read_config_file): Made it to close file before returning.
16756
b4b93674 167572006-03-31 Vesa Jaaskelainen <chaac@nic.fi>
16758
16759 * DISTLIST: Added include/grub/i386/pc/vbeblit.h,
16760 include/grub/i386/pc/vbefill.h, video/i386/pc/vbeblit.c,
16761 video/i386/pc/vbefill.c.
16762
16763 * conf/i386-pc.rmk (vbe_mod_SOURCES): Added video/i386/pc/vbeblit.c,
16764 video/i386/pc/vbefill.c.
16765
16766 * include/grub/video.h (grub_video_blit_format): New enum.
16767 (grub_video_mode_info): Added new member blit_format.
16768 (grub_video_get_blit_format): New function prototype.
16769
16770 * include/grub/i386/pc/vbe.h (grub_video_vbe_get_video_ptr): New
16771 function prototype.
16772 (grub_video_vbe_map_rgb): Likewise.
16773 (grub_video_vbe_unmap_color): Likewise.
16774
16775 * include/grub/i386/pc/vbeblit.h: New file.
16776
16777 * include/grub/i386/pc/vbefill.h: New file.
16778
16779 * video/video.c (grub_video_get_blit_format): New function.
16780 (grub_video_vbe_get_video_ptr): Re-declared as non-static.
16781 (grub_video_vbe_map_rgb): Likewise.
16782 (grub_video_vbe_unmap_color): Likewise.
16783
16784 * video/i386/pc/vbe.c (grub_video_vbe_fill_rect): Changed to use more
16785 optimized fills.
16786 (grub_video_vbe_blit_render_target): Changed to use more optimized
16787 blits.
16788 (grub_video_vbe_setup): Added detection for optimized settings.
16789 (grub_video_vbe_create_render_target): Likewise.
16790
16791 * video/i386/pc/vbeblit.c: New file.
16792
16793 * video/i386/pc/vbefill.c: New file.
16794
c2379b9c 167952006-03-30 Vesa Jaaskelainen <chaac@nic.fi>
16796
16797 * font/manager.c (grub_font_get_glyph): Removed font fixup from
16798 here...
16799
16800 * util/unifont2pff.rb: ... and moved it to here. Improved argument
16801 parsing to support both hex and dec ranges. If filename was missing
16802 show usage information.
16803
bd0d7896 168042006-03-14 Vesa Jaaskelainen <chaac@nic.fi>
16805
16806 * DISTLIST: Added include/grub/video.h, term/gfxterm.c,
16807 video/video.c, commands/videotest.c. Removed term/i386/pc/vesafb.c.
16808
16809 * conf/i386-pc.rmk (pkgdata_MODULES): Added video.mod,
16810 gfxterm.mod, videotest.mod. Removed vga.mod, vesafb.mod.
16811 (video_mod_SOURCES): Added.
16812 (video_mod_CFLAGS): Likewise.
16813 (video_mod_LDFLAGS): Likewise.
16814 (gfxterm_mod_SOURCES): Likewise.
16815 (gfxterm_mod_CFLAGS): Likewise.
16816 (gfxterm_mod_LDFLAGS): Likewise.
16817 (videotest_mod_SOURCES): Likewise.
16818 (videotest_mod_CFLAGS): Likewise.
16819 (videotest_mod_LDFLAGS): Likewise.
16820 (vesafb_mod_SOURCES): Removed.
16821 (vesafb_mod_CFLAGS): Likewise.
16822 (vesafb_mod_LDFLAGS): Likewise.
16823 (vga_mod_SOURCES): Likewise.
16824 (vga_mod_CFLAGS): Likewise.
16825 (vga_mod_LDFLAGS): Likewise.
16826
16827 * commands/videotest.c: New file.
16828
16829 * font/manager.c (fill_with_default_glyph): Modified to use
16830 grub_font_glyph.
16831 (grub_font_get_glyph): Likewise.
16832 (fontmanager): Renamed from this...
16833 (font_manager): ... to this.
16834
16835 * include/grub/font.h (grub_font_glyph): Added new structure.
16836 (grub_font_get_glyph): Modified to use grub_font_glyph.
16837
16838 * include/grub/misc.h (grub_abs): Added as inline function.
16839
16840 * include/grub/video.h: New file.
16841
16842 * include/grub/i386/pc/vbe.h (GRUB_VBE_STATUS_OK): New macro.
16843 (GRUB_VBE_MEMORY_MODEL_PACKED_PIXEL): Likewise.
16844 (GRUB_VBE_MEMORY_MODEL_DIRECT_COLOR): Likewise.
16845 (grub_vbe_get_controller_info): Renamed from this...
16846 (grub_vbe_bios_get_controller_info): ... to this.
16847 (grub_vbe_get_mode_info): Renamed from this...
16848 (grub_vbe_bios_get_mode_info): ... to this.
16849 (grub_vbe_set_mode): Renamed from this...
16850 (grub_vbe_bios_set_mode): ... to this.
16851 (grub_vbe_get_mode): Renamed from this...
16852 (grub_vbe_bios_get_mode): ... to this.
16853 (grub_vbe_set_memory_window): Renamed from this...
16854 (grub_vbe_bios_set_memory_window): ... to this.
16855 (grub_vbe_get_memory_window): Renamed from this...
16856 (grub_vbe_bios_get_memory_window): ... to this.
16857 (grub_vbe_set_scanline_length): Renamed from this...
16858 (grub_vbe_set_scanline_length): ... to this.
16859 (grub_vbe_get_scanline_length): Renamed from this...
16860 (grub_vbe_bios_get_scanline_length): ... to this.
16861 (grub_vbe_set_display_start): Renamed from this...
16862 (grub_vbe_bios_set_display_start): ... to this.
16863 (grub_vbe_get_display_start): Renamed from this...
16864 (grub_vbe_bios_get_display_start): ... to this.
16865 (grub_vbe_set_palette_data): Renamed from this...
16866 (grub_vbe_bios_set_palette_data): ... to this.
16867 (grub_vbe_set_pixel_rgb): Removed.
16868 (grub_vbe_set_pixel_index): Likewise.
16869
16870 * kern/i386/pc/startup.S (grub_vbe_get_controller_info): Renamed
16871 from this...
16872 (grub_vbe_bios_get_controller_info): ... to this.
16873 (grub_vbe_get_mode_info): Renamed from this...
16874 (grub_vbe_bios_get_mode_info): ... to this.
16875 (grub_vbe_set_mode): Renamed from this...
16876 (grub_vbe_bios_set_mode): ... to this.
16877 (grub_vbe_get_mode): Renamed from this...
16878 (grub_vbe_bios_get_mode): ... to this.
16879 (grub_vbe_set_memory_window): Renamed from this...
16880 (grub_vbe_bios_set_memory_window): ... to this.
16881 (grub_vbe_get_memory_window): Renamed from this...
16882 (grub_vbe_bios_get_memory_window): ... to this.
16883 (grub_vbe_set_scanline_length): Renamed from this...
16884 (grub_vbe_set_scanline_length): ... to this.
16885 (grub_vbe_get_scanline_length): Renamed from this...
16886 (grub_vbe_bios_get_scanline_length): ... to this.
16887 (grub_vbe_set_display_start): Renamed from this...
16888 (grub_vbe_bios_set_display_start): ... to this.
16889 (grub_vbe_get_display_start): Renamed from this...
16890 (grub_vbe_bios_get_display_start): ... to this.
16891 (grub_vbe_set_palette_data): Renamed from this...
16892 (grub_vbe_bios_set_palette_data): ... to this.
16893 (grub_vbe_bios_get_controller_info): Fixed problem with registers
16894 getting corrupted after calling it. Added more pushes and pops.
16895 (grub_vbe_bios_set_mode): Likewise.
16896 (grub_vbe_bios_get_mode): Likewise.
16897 (grub_vbe_bios_get_memory_window): Likewise.
16898 (grub_vbe_bios_set_scanline_length): Likewise.
16899 (grub_vbe_bios_get_scanline_length): Likewise.
16900 (grub_vbe_bios_get_display_start): Likewise.
16901 (grub_vbe_bios_set_palette_data): Likewise.
16902
16903 * normal/cmdline.c (cl_set_pos): Refresh the screen.
16904 (cl_insert): Likewise.
16905 (cl_delete): Likewise.
16906
16907 * term/gfxterm.c: New file.
16908
16909 * term/i386/pc/vesafb.c: Removed file.
16910
16911 * video/video.c: New file.
16912
16913 * video/i386/pc/vbe.c (real2pm): Added new function.
16914 (grub_video_vbe_draw_pixel): Likewise.
16915 (grub_video_vbe_get_video_ptr): Likewise.
16916 (grub_video_vbe_get_pixel): Likewise
16917 (grub_video_vbe_init): Likewise.
16918 (grub_video_vbe_fini): Likewise.
16919 (grub_video_vbe_setup): Likewise.
16920 (grub_video_vbe_get_info): Likewise.
16921 (grub_video_vbe_set_palette): Likewise.
16922 (grub_video_vbe_get_palette): Likewise.
16923 (grub_video_vbe_set_viewport): Likewise.
16924 (grub_video_vbe_get_viewport): Likewise.
16925 (grub_video_vbe_map_color): Likewise.
16926 (grub_video_vbe_map_rgb): Likewise.
16927 (grub_video_vbe_map_rgba): Likewise.
16928 (grub_video_vbe_unmap_color): Likewise.
16929 (grub_video_vbe_fill_rect): Likewise.
16930 (grub_video_vbe_blit_glyph): Likewise.
16931 (grub_video_vbe_blit_bitmap): Likewise.
16932 (grub_video_vbe_blit_render_target): Likewise.
16933 (grub_video_vbe_scroll): Likewise.
16934 (grub_video_vbe_swap_buffers): Likewise.
16935 (grub_video_vbe_create_render_target): Likewise.
16936 (grub_video_vbe_delete_render_target): Likewise.
16937 (grub_video_vbe_set_active_render_target): Likewise.
16938 (grub_vbe_set_pixel_rgb): Remove function.
16939 (grub_vbe_set_pixel_index): Likewise.
16940 (index_color_mode): Remove static variable.
16941 (active_mode): Likewise.
16942 (framebuffer): Likewise.
16943 (bytes_per_scan_line): Likewise.
16944 (grub_video_vbe_adapter): Added new static variable.
16945 (framebuffer): Likewise.
16946 (render_target): Likewise.
16947 (initial_mode): Likewise.
16948 (mode_in_use): Likewise.
16949 (mode_list): Likewise.
16950
5f97350b 169512006-03-10 Marco Gerards <marco@gnu.org>
16952
16953 * configure.ac (AC_INIT): Bumped to 1.93.
16954
16955 * DISTLIST: Added `include/grub/hfs.h'.
16956
a3c5c6f8 169572006-02-01 Yoshinori K. Okuji <okuji@enbug.org>
16958
16959 * boot/i386/pc/boot.S (general_error): Before looping, try INT
16960 18H, which might help the BIOS falling back to next boot media.
16961
6de53d26 169622006-01-25 Yoshinori K. Okuji <okuji@enbug.org>
16963
16964 * util/i386/pc/grub-install.in: Escape a backslash. Reported by
16965 Poe Chen <poe.poechen@gmail.com>.
16966
77c4a393 169672006-01-17 Marco Gerards <marco@gnu.org>
16968
16969 * include/grub/normal.h: Include <grub/script.h>.
16970 (grub_command_list): Removed struct.
16971 (grub_command_list_t): Removed type.
16972 (grub_menu_entry): Remove members `num' and `command_list'. Add
16973 members `commands' and `sourcecode'.
16974 * include/grub/script.h: Add inclusion guards.
16975 (grub_script_cmd_menuentry): New struct.
16976 (grub_script_execute_menuentry): New prototype.
16977 (grub_script_lexer_record_start): Likewise.
16978 (grub_script_lexer_record_stop): Likewise.
16979 * normal/execute.c (grub_script_execute_menuentry): New function.
16980 * normal/lexer.c (record, recording, recordpos, recordlen): New
16981 variables.
16982 (grub_script_lexer_record_start): New function.
16983 (grub_script_lexer_record_stop): Likewise.
16984 (recordchar): Likewise.
16985 (nextchar): Likewise.
16986 (grub_script_yylex): Use `nextchar' to fetch new characters. Use
16987 2048 as the buffer size. Add the tokens `menuentry' and `@'.
16988 * normal/main.c: Include <grub/parser.h> and <grub/script.h>
16989 (current_menu): New variable.
16990 (free_menu): Mainly rewritten.
16991 (grub_normal_menu_addentry): New function.
16992 (read_config_file): Rewritten.
16993 * normal/menu.c (run_menu_entry): Mainly rewritten.
fe987087 16994 * normal/menu_entry.c (make_screen): Rewritten the code to insert
77c4a393 16995 the menu entry.
16996 (run): Mainly rewritten.
16997 * normal/parser.y (menu_entry): New variable.
16998 (GRUB_PARSER_TOKEN_MENUENTRY): New token.
16999 (menuentry): New rule.
17000 (command): Add `menuentry'.
17001 (if_statement): Allow additional returns before `fi'.
17002 * normal/script.c (grub_script_create_cmdmenu): New function.
17003
144f1f98 170042006-01-03 Marco Gerards <marco@gnu.org>
17005
17006 * INSTALL: GNU Bison is required.
17007 * configure.ac: Rewritten the test to detect Bison.
17008 * Makefile.in (YACC): New variable. Reported by Xun Sun
17009 <xun.sun.cn@gmail.com>.
17010
af4b2d89 170112006-01-03 Marco Gerards <marco@gnu.org>
17012
17013 * fs/hfsplus.c (grub_hfsplus_read_block): Convert the offset of
17014 the HFS+ filesystem to filesystem blocks.
17015 (grub_hfsplus_iterate_dir): Cast the `fileinfo' assignment so a
17016 GCC warning is silenced.
17017
15643b71 170182006-01-03 Marco Gerards <marco@gnu.org>
17019
17020 * partmap/apple.c (apple_partition_map_iterate): Convert the data
17021 read from disk from big endian to host byte order.
17022
00905879 170232006-01-03 Hollis Blanchard <hollis@penguinppc.org>
17024
17025 * fs/hfs.c: Include <grub/hfs.h>. Added reference to the official
17026 documentation.
17027 (GRUB_HFS_EMBED_HFSPLUS_SIG): New macro.
17028 (grub_hfs_mount): Grammar fix in error. Make sure this is not an
17029 embedded HFS+ filesystem.
17030 (GRUB_HFS_MAGIC, grub_hfs_extent, grub_hfs_datarecord_t)
17031 (grub_hfs_sblock): Move from here...
17032 * include/grub/hfs.h: To here... New file.
17033 * fs/hfsplus.c: Include <grub/hfs.h>. Added reference to the official
17034 documentation.
17035 (GRUB_HFSPLUS_MAGIC, GRUB_HFSPLUSX_MAGIC, GRUB_HFSPLUS_SBLOCK):
17036 New macros.
17037 (grub_hfsplus_volheader): Change type of member `magic' to
17038 `grub_uint16_t'.
17039 (grub_hfsplus_data): Add new member `embedded_offset'.
17040 (grub_hfsplus_read_block): Add the HFS+ wrapper offset to the
17041 returned block.
17042 (grub_hfsplus_mount): Read the HFS+ wrapper if it exists.
17043 Calculate the offset.
17044
8899bc3e 170452005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
17046
17047 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRP_ADDR):
17048 Removed.
17049 (GRUB_BOOT_MACHINE_DRP_SIZE): Likewise.
17050
ae8c0277 170512005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
17052
17053 * kern/env.c (grub_env_set): Check if ENV->VALUE instead of
17054 ENV->NAME is NULL after allocating ENV->VALUE.
17055
07084456 170562005-12-25 Marco Gerards <marco@gnu.org>
17057
17058 * kern/env.c (grub_env_set): Rewritten the error handling code.
17059
4750f5f1 170602005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
17061
17062 * geninit.sh: Made more robust, and more portable.
17063
50214199 170642005-12-25 Marco Gerards <marco@gnu.org>
17065
17066 Add support for Apple HFS+ filesystems.
f19dbdb7 17067
50214199 17068 * fs/hfsplus.c: New file.
17069
17070 * DISTLIST: Added `fs/hfsplus.c'.
17071
17072 * conf/common.rmk (pkgdata_MODULES): Add `hfsplus.mod'.
17073 (hfsplus_mod_SOURCES): New variable.
17074 (hfsplus_mod_CFLAGS): Likewise.
17075 (hfsplus_mod_LDFLAGS): Likewise.
17076 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/hfsplus.c'.
17077 (grub_setup_SOURCES): Likewise.
17078 (grub_mkdevicemap_SOURCES): Likewise.
17079 (grub_emu_SOURCES): Likewise.
17080 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
17081
17082 * fs/fshelp.c (grub_fshelp_log2blksize): New function.
17083
17084 * include/grub/fshelp.h (grub_fshelp_log2blksize): new prototype.
17085
befaed6c 170862005-12-25 Yoshinori K. Okuji <okuji@enbug.org>
17087
17088 * DISTLIST: Added geninitheader.sh, geninit.sh, commands/test.c,
17089 commands/i386/pc/play.c, conf/common.mk, conf/common.rmk,
17090 include/grub/parser.h, include/grub/script.h, kern/parser.c,
17091 kern/sparc64/cache.S, normal/execute.c, normal/function.c,
17092 normal/lexer.c, normal/parser.y, normal/script.c, and
17093 partmap/gpt.c.
17094 Removed kern/sparc64/cache.c.
17095
17096 * conf/common.rmk (DISTCLEANFILES): Added grub_script.tab.c,
17097 grub_script.tab.h, grub_modules_init.lst, grub_modules_init.h,
17098 grub_emu_init.c.
17099
17100 * configure.ac (AC_INIT): Bumped to 1.92.
17101
6a124103 171022005-12-24 Vesa Jaaskelainen <chaac@nic.fi>
17103
17104 * kern/err.c (grub_error_push): Added new function to support error
17105 stacks.
17106 (grub_error_pop): Likewise.
17107 (grub_error_stack_items): New local variable to support error stacks.
17108 (grub_error_stack_pos): Likewise.
17109 (grub_error_stack_assert): Likewise.
17110 (GRUB_ERROR_STACK_SIZE): Added new define to configure maximum error
17111 stack depth.
17112 (grub_print_error): Added support to print errors from error stack.
17113
17114 * include/grub/err.h (grub_error_push): Added function prototype.
17115 (grub_error_pop): Likewise.
17116
be973c1b 171172005-12-09 Hollis Blanchard <hollis@penguinppc.org>
17118
17119 * configure.ac: Accept `powerpc64' as host_cpu.
17120 (amd64): Rename to `biarch32'.
17121
17122 * kern/powerpc/cache.S (grub_arch_sync_caches): Handle
17123 non-cacheline-aligned addresses.
17124
17125 * kern/dl.c (grub_dl_load_core): Add grub_dprintf messages.
17126 (grub_dl_flush_cache): Likewise. Only call `grub_arch_sync_caches'
17127 if `size' is non-zero.
17128
b04216ab 171292005-12-03 Marco Gerards <mgerards@xs4all.nl>
17130
17131 * conf/common.rmk (grub_modules_init.lst): Use `-printf "%P\n"'
17132 and `cd' to make sure the filename is not prefixed with a
17133 directory name.
17134 (pkgdata_MODULES): Add `gpt.mod'.
17135 (gpt_mod_SOURCES): New variable.
17136 (gpt_mod_CFLAGS): Likewise.
17137 (gpt_mod_LDFLAGS): Likewise.
17138
17139 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/gpt.c'.
17140
17141 * include/grub/pc_partition.h (GRUB_PC_PARTITION_TYPE_GPT_DISK):
17142 New macro.
17143
17144 * partmap/gpt.c: New file.
17145
17146 * partmap/pc.c (pc_partition_map_iterate): Don't continue when a
17147 GPT partition map is detected.
17148
41730ed9 171492005-12-03 Vincent Pelletier <subdino2004@yahoo.fr>
17150
17151 * commands/i386/pc/play.c: New file.
17152 * conf/i386-pc.rmk (pkgdata_MODULES): Added play.mod.
17153 (play_mod_SOURCES, play_mod_CFLAGS, play_mod_LDFLAGS): New
17154 macros.
f19dbdb7 17155
95dc3643 171562005-11-27 Marco Gerards <mgerards@xs4all.nl>
17157
17158 * include/grub/dl.h (GRUB_MOD_INIT): Use `__attribute__
17159 ((unused))' to silence gcc warning.
17160
1569ec51 171612005-11-26 Hollis Blanchard <hollis@penguinppc.org>
17162
17163 * configure.ac: Correct `AC_PROG_YACC' test.
17164
9abde152 171652005-11-22 Hollis Blanchard <hollis@penguinppc.org>
17166
17167 * util/powerpc/ieee1275/grub-install.in: Run the mount point
17168 check before installing files.
17169
44b83271 171702005-11-22 Mike Small <smallm@panix.com>
17171
17172 * util/powerpc/ieee1275/grub-install.in (grubdir): Fixed partition
17173 number regex so multidigit numbers are recognized correctly.
17174
171752005-11-22 Mike Small <smallm@panix.com>
17176
17177 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Add a
17178 debugging message before attempting to claim memory.
17179 (grub_rescue_cmd_initrd): Add a claim debugging message and try
17180 multiple addresses in case of failure.
17181
9c12956b 171822005-11-22 Hollis Blanchard <hollis@penguinppc.org>
17183
17184 * term/tparm.c (get_space): Remove empty `if' statement.
17185
17186 * fs/ufs.c (grub_ufs_find_file): Remove `grub_le_to_cpu32'.
17187
17188 * kern/parser.c (check_varstate): Rename `state' to 's'.
17189
aeaf81d9 171902005-11-22 Hollis Blanchard <hollis@penguinppc.org>
17191
17192 * partmap/acorn.c: Change `unsigned' to `unsigned int'. Move all
17193 variable definitions to the beginning of each function. Sort stack
17194 variables by size.
17195 (find): Rename to `acorn_partition_map_find'. Cast `grub_disk_read'
17196 `buf' argument to `char *'.
17197
79bbb63f 171982005-11-22 Hollis Blanchard <hollis@penguinppc.org>
17199
17200 * conf/powerpc-ieee1275.rmk: Include conf/common.mk.
17201 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
fe6b695a 17202 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
79bbb63f 17203 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
17204 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
17205 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
17206 configfile.mod, search.mod, gzio.mod and test.mod.
17207 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
17208 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
17209 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
17210 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
17211 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
17212 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
17213 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
17214 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
17215 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
17216 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
17217 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
17218 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
17219 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
17220 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
17221 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
17222 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
17223 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
17224 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
17225 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
17226 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
17227 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
17228 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
17229 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Removed.
17230
17231 * conf/common.mk (grub_modules_init.lst): Use `find' instead of
17232 `grep --include'.
17233 (pkgdata_MODULES): Add test.mod.
17234
233b1628 172352005-11-18 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17236
17237 * genmk.rb: Fixed list rules moved to Makefile.in. Recognise
17238 appending to variables with "+=".
17239 (PModule): Use full pathname to generate *.lst filenames.
17240
17241 * Makefile.in: Fixed list rules moved from genmk.rb.
17242 (.DELETE_ON_ERROR): New special target.
17243 (RMKFILES): Add common.rmk and sparc64-ieee1275.rmk.
17244
17245 * conf/i386-pc.rmk: Include conf/common.mk.
17246 (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod,
fe6b695a 17247 minix.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod,
233b1628 17248 hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod,
17249 help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod,
17250 sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod,
17251 configfile.mod, search.mod, gzio.mod and test.mod.
17252 (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst)
17253 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c)
17254 (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS)
17255 (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS)
17256 (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS)
17257 (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS)
17258 (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS)
17259 (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES)
17260 (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES)
17261 (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES)
17262 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
17263 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
17264 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES)
17265 (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES)
17266 (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES)
17267 (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES)
17268 (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
17269 (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS)
17270 (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS)
17271 (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS)
17272 (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS)
17273 (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS)
17274 (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Move from
17275 here...
17276 * conf/common.rmk: ... to here. New file.
17277
17278 * conf/common.mk: New file.
17279
16f820c8 172802005-11-18 Yoshinori K. Okuji <okuji@enbug.org>
17281
17282 * conf/powerpc-ieee1275.rmk (grub_script.tab.h): Unified to ...
17283 (grub_script.tab.c): ... here.
17284
17285 * conf/sparc64-ieee1275.rmk (grub_script.tab.h): Unified to ...
17286 (grub_script.tab.c): ... here.
17287
17288 * conf/i386-pc.rmk (grub_script.tab.h): Unified to ...
17289 (grub_script.tab.c): ... here.
17290
17291 * normal/command.c (grub_command_find): Fixed a memory leak of
17292 MODULE_NAME. Reported by Mike Small <smallm@panix.com>.
17293
63ba1554 172942005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17295
17296 * include/grub/symbol.h: (FUNCTION): Use double quotes instead of
17297 "@" which marks the start of a comment on ARM.
17298 (VARIABLE): Likewise.
17299
7f67dc13 173002005-11-13 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17301
79bbb63f 17302 Add support for Linux/ADFS partition tables.
7f67dc13 17303
17304 * partmap/acorn.c: New file.
17305
17306 * include/grub/acorn_filecore.h: Likewise.
17307
17308 * DISTLIST: Added `partmap/acorn.c' and
17309 `include/grub/acorn_filecore.h'.
f19dbdb7 17310
7f67dc13 17311 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
17312 `partmap/acorn.c'.
17313 (pkgdata_MODULES): Add `acorn.mod'.
17314 (acorn_mod_SOURCES): New variable.
17315 (acorn_mod_CFLAGS): Likewise.
17316
17317 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
17318 `partmap/acorn.c'.
17319 (pkgdata_MODULES): Add `acorn.mod'.
17320 (acorn_mod_SOURCES): New variable.
17321 (acorn_mod_CFLAGS): Likewise.
17322
17323 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `partmap/acorn.c'.
17324 (pkgdata_MODULES): Add `acorn.mod'.
17325 (acorn_mod_SOURCES): New variable.
17326 (acorn_mod_CFLAGS): Likewise.
17327 (acorn_mod_LDFLAGS): Likewise.
17328
17329 * include/types.h (grub_disk_addr_t): New typedef.
17330
6d099807 173312005-11-13 Marco Gerards <mgerards@xs4all.nl>
17332
17333 * geninit.sh: New file.
17334
17335 * geninitheader.sh: Likewise.
17336
17337 * commands/boot.c (grub_boot_init, grub_boot_fini): Removed.
17338 * commands/cat.c (grub_cat_init, grub_cat_fini): Likewise.
17339 * commands/cmp.c (grub_cmp_init, grub_cmp_fini): Likewise.
17340 * commands/configfile.c (grub_configfile_init)
17341 (grub_configfile_fini): Likewise.
17342 * commands/default.c (grub_default_init, grub_default_fini):
17343 Likewise.
17344 * commands/help.c (grub_help_init, grub_help_fini): Likewise.
17345 * commands/ls.c (grub_ls_init, grub_ls_fini): Likewise.
17346 * commands/search.c (grub_search_init, grub_search_fini): Likewise.
17347 * commands/terminal.c (grub_terminal_init, grub_terminal_fini):
17348 Likewise.
17349 * commands/test.c (grub_test_init, grub_test_fini): Likewise.
17350 * commands/timeout.c (grub_timeout_init, grub_timeout_fini):
17351 Likewise.
17352 * commands/i386/pc/halt.c (grub_halt_init, grub_halt_fini): Likewise.
fe6b695a 17353 * commands/ieee1275/halt.c (grub_halt_init, grub_halt_fini):
6d099807 17354 Likewise.
17355 * commands/i386/pc/reboot.c (grub_reboot_init, grub_reboot_fini):
17356 Likewise.
fe6b695a 17357 * commands/ieee1275/reboot.c (grub_reboot_init, grub_reboot_fini):
6d099807 17358 Likewise.
17359 * disk/loopback.c (grub_loop_init, grub_loop_fini): Likewise.
17360 * fs/affs.c (grub_affs_init, grub_affs_fini): Likewise.
17361 * fs/ext2.c (grub_ext2_init, grub_ext2_fini): Likewise.
17362 * fs/fat.c (grub_fat_init, grub_fat_fini): Likewise.
17363 * fs/hfs.c (grub_hfs_init, grub_hfs_fini): Likewise.
17364 * fs/iso9660.c (grub_iso9660_init, grub_iso9660_fini): Likewise.
17365 * fs/jfs.c (grub_jfs_init, grub_jfs_fini): Likewise.
17366 * fs/minix.c (grub_minix_init, grub_minix_fini): Likewise.
17367 * fs/sfs.c (grub_sfs_init, grub_sfs_fini): Likewise.
17368 * fs/ufs.c (grub_ufs_init, grub_ufs_fini): Likewise.
17369 * fs/xfs.c (grub_xfs_init, grub_xfs_fini): Likewise.
17370 * normal/main.c (grub_normal_init, grub_normal_fini): Likewise.
17371 * partmap/amiga.c (grub_amiga_partition_map_init)
17372 (grub_amiga_partition_map_fini): Likewise.
17373 * partmap/apple.c (grub_apple_partition_map_init)
17374 (grub_apple_partition_map_fini): Likewise.
17375 * partmap/pc.c (grub_pc_partition_map_init)
17376 (grub_pc_partition_map_fini): Likewise.
17377 * partmap/sun.c (grub_sun_partition_map_init,
17378 grub_sun_partition_map_fini): Likewise.
17379 * term/terminfo.c (grub_terminal_init, grub_terminal_fini):
17380 Likewise.
17381
17382 * util/grub-emu.c: Include <grub_modules_init.h>.
17383 (main): Don't initialize and de-initialize any modules directly,
17384 use `grub_init_all' and `grub_fini_all' instead.
17385
17386 * term/i386/pc/vesafb.c (grub_vesafb_init): Renamed to
17387 `grub_vesafb_mod_init'.
17388 (grub_vesafb_fini): Renamed to `grub_vesafb_mod_fini'. Updated
17389 all users.
17390 * term/i386/pc/vga.c (grub_vga_init): Renamed to
17391 `grub_vga_mod_init'. Updated all users.
17392 (grub_vga_fini): Renamed to `grub_vga_mod_fini'.
f19dbdb7 17393
6d099807 17394 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `grub_emu_init.c'.
17395 (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c): New
17396 rules.
17397
17398 * include/grub/dl.h (GRUB_MOD_INIT): Add argument `name'.
17399 Generate a function to initialize the module in utilities.
17400 Updated all callers.
17401 (GRUB_MOD_FINI): Add argument `name'. Generate a function to
17402 initialize the module in utilities. Updated all callers.
17403
9046bcf0 174042005-11-09 Hollis Blanchard <hollis@penguinppc.org>
17405
17406 * term/ieee1275/ofconsole.c (grub_ofconsole_cls): Use both the ANSI
17407 escape sequence and a literal ^L to clear the screen.
17408
17409 * commands/ieee1275/suspend.c (grub_cmd_suspend): Clear the screen
17410 when returning from Open Firmware.
17411
d13ea639 174122005-11-09 Hollis Blanchard <hollis@penguinppc.org>
17413
17414 * term/ieee1275/ofconsole.c (grub_ofconsole_width): New variable.
17415 (grub_ofconsole_height): Likewise.
17416 (grub_ofconsole_putchar): If `grub_curr_x' exceeds console width,
17417 manually insert a '\n'.
17418 (grub_ofconsole_getwh): Set and return `grub_ofconsole_width' and
17419 `grub_ofconsole_height'. Return early if these are already set.
17420
a8fcf206 174212005-11-07 Vincent Pelletier <subdino2004@yahoo.fr>
17422
17423 * conf/sparc64-ieee1275.rmk (grub_emu_SOURCES): Add
17424 `commands/test.c', `fs/affs.c', `fs/sfs.c', `fs/xfs.c',
17425 `normal/execute.c', `normal/lexer.c', `io/gzio.c',
17426 `kern/parser.c', `grub_script.tab.c', `normal/function.c'
17427 and `normal/script.c'.
17428 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
17429 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
17430 (test_mod_SOURCES): New variable.
17431 (test_mod_CFLAGS): Likewise.
17432 (test_mod_LDFLAGS): Likewise.
17433 (pkgdata_MODULES): Add `test.mod'.
17434 (grub_script.tab.c): New rule.
17435 (grub_script.tab.h): Likewise.
17436
b6b32745 174372005-11-07 Marco Gerards <mgerards@xs4all.nl>
17438
17439 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
17440 `commands/test.c', `normal/execute.c', `normal/lexer.c',
17441 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
17442 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
17443 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
17444 (test_mod_SOURCES): New variable.
17445 (test_mod_CFLAGS): Likewise.
17446 (pkgdata_MODULES): Add `test.mod'.
17447 (grub_script.tab.c): New rule.
17448 (grub_script.tab.h): Likewise.
17449
daac212a 174502005-11-06 Marco Gerards <mgerards@xs4all.nl>
17451
17452 Add initial scripting support.
17453
17454 * commands/test.c: New file.
17455 * include/grub/script.h: Likewise.
17456 * normal/execute.c: Likewise.
17457 * normal/function.c: Likewise.
17458 * normal/lexer.c: Likewise.
17459 * normal/parser.y: Likewise.
17460 * normal/script.c: Likewise.
17461
17462 * configure.ac: Add `AC_PROG_YACC' test.
f19dbdb7 17463
daac212a 17464 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/test.c',
17465 `normal/execute.c', `normal/lexer.c', `grub_script.tab.c',
17466 `normal/function.c' and `normal/script.c'.
17467 (normal_mod_SOURCES): `normal/execute.c', `normal/lexer.c',
17468 `grub_script.tab.c', `normal/function.c' and `normal/script.c'.
b6b32745 17469 (test_mod_SOURCES, test_mod_CFLAGS, test_mod_LDFLAGS): New
17470 variables.
daac212a 17471 (pkgdata_MODULES): Add `test.mod'.
17472 (grub_script.tab.c): New rule.
17473 (grub_script.tab.h): Likewise.
17474
17475 * include/grub/err.h (grub_err_t): Add `GRUB_ERR_TEST_FAILURE'.
17476
17477 * include/grub/normal.h (grub_test_init): New prototype.
17478 (grub_test_fini): Likewise.
f19dbdb7 17479
daac212a 17480 * normal/command.c: Include <grub/script.h>.
17481 (grub_command_execute): Rewritten.
f19dbdb7 17482
daac212a 17483 * util/grub-emu.c (main): Call `grub_test_init' and
17484 `grub_test_fini'.
17485
77500b2b 174862005-11-03 Hollis Blanchard <hollis@penguinppc.org>
17487
17488 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Initialize `msecs'
17489 to 0.
17490 * term/ieee1275/ofconsole.c (grub_ofconsole_checkkey): Return -1 if
17491 there are no pending characters.
17492
e45deb9e 174932005-11-03 Hollis Blanchard <hollis@penguinppc.org>
17494
17495 * kern/powerpc/ieee1275/openfw.c (grub_ieee1275_get_devname): Use
17496 `grub_strndup' to drop device arguments. Replace unnecessary
17497 `grub_strndup' with `grub_strdup'.
17498
4ce32619 174992005-11-03 Hollis Blanchard <hollis@penguinppc.org>
17500
17501 * kern/term.c (grub_cls): Do not call grub_cur_term->cls() if the
17502 `debug' environment variable has been set.
17503
175042005-11-02 Hollis Blanchard <hollis@penguinppc.org>
f19dbdb7 17505
4ce32619 17506 * Makefile.in (install-local): Use $(DATA).
17507 (uninstall): Likewise.
17508 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Move grub-mkimage...
17509 (sbin_UTILITIES): ... to here.
17510 (sbin_SCRIPTS): New variable.
17511 (grub_install_SOURCES): New variable.
17512 * util/powerpc/ieee1275/grub-install.in: New file.
17513 * util/powerpc/ieee1275/grub-mkimage.c (kernel_path): Remove
17514 variable.
17515 (add_segments): Call `grub_util_get_path'.
17516
25fe6f03 175172005-10-28 Yoshinori K. Okuji <okuji@enbug.org>
17518
17519 From Timothy Baldwin:
17520 * commands/ls.c (grub_ls_list_files): Close FILE with
17521 grub_file_close.
17522 * kern/misc.c (grub_vsprintf): Terminate the string S with NUL.
17523
04ccf3ec 175242005-10-24 Marco Gerards <mgerards@xs4all.nl>
17525
17526 * include/grub/parser.h: New file.
17527
17528 * kern/parser.c: Likewise.
17529
17530 * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/parser.c'.
17531 (grub_setup_SOURCES): Likewise.
17532 (grub_probefs_SOURCES): Likewise.
17533 (grub_emu_SOURCES): Likewise.
17534 (kernel_img_HEADERS): Add `parser.h'.
17535
17536 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
17537 (grub_emu_SOURCES): Add `kern/parser.c'.
17538 (grubof_SOURCES): Likewise.
17539
17540 * conf/sparc64-ieee1275.rmk (grubof_HEADERS): Add `parser.h'.
17541 (grubof_SOURCES): Add `kern/parser.c'.
17542
17543 * include/grub/misc.h (grub_split_cmdline): Removed prototype.
17544
17545 * kern/misc.c (grub_split_cmdline): Removed function.
17546
17547 * kern/rescue.c: Include <grub/parser.h>.
17548 (grub_enter_rescue_mode): Use `grub_parser_split_cmdline' instead
17549 of `grub_split_cmdline'.
17550
17551 * normal/command.c: Include <grub/parser.h>.
17552 (grub_command_execute): Use `grub_parser_split_cmdline' instead
17553 of `grub_split_cmdline'.
17554
17555 * normal/completion.c: Include <grub/parser.h>.
17556 (cmdline_state): New variable.
17557 (iterate_dir): End the filename with a quote depending on the
17558 command line state.
17559 (get_state): new function.
17560 (grub_normal_do_completion): Use `grub_parser_split_cmdline' to
17561 split the arguments and determine the current argument. When the
17562 argument string is not quoted, escape all spaces.
17563
6d8f4b0e 175642005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
17565
17566 * normal/sparc64/setjmp.S: New file.
17567
15cf03ed 175682005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
17569
17570 * include/grub/sparc64/libgcc.h: New file.
17571 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Remove -Av9.
17572 (normal_mod_SOURCES): Use normal/sparc64/setjmp.S instead of
17573 normal/sparc64/setjmp.c.
17574
03e8661a 175752005-10-23 Vincent Pelletier <subdino2004@yahoo.fr>
17576
17577 * kern/sparc64/dl.c: Rewritten for SPARCV9 ELF.
17578 * kern/sparc64/cache.S: New file.
17579 * kern/sparc64/cache.c: Removed.
17580 * conf/sparc64-ieee1275.rmk (COMMON_ASFLAGS): Add -Av9.
17581 (COMMON_CFLAGS): Add -mno-app-regs. Remove -mcpu=v9 and
17582 -mtune=ultrasparc.
17583 (COMMON_LDFLAGS): Add -melf64_sparc.
17584 (grubof_HEADERS): Add sparc64/libgcc.h and machine/kernel.h.
17585 (grubof_SOURCES): Use cache.S instead of cache.c.
17586 (grubof_LDFLAGS): Add -mno-app-regs. Replace "-Xlinker
17587 --oformat -Xlinker elf64-sparc" by "-Bstatic,-melf64_sparc".
17588 (pkgdata_MODULES): Uncomment. Leave linux.mod and _linux.mod
17589 commented though.
17590 (normal_mod_SOURCES): Add normal/completion.c and normal/misc.c.
17591 (_linux_mod_SOURCES, _linux_mod_CFLAGS, linux_mod_SOURCES)
17592 (linux_mod_CFLAGS): Commented out.
17593 (_linux_mod_LDFLAGS, linux_mod_LDFLAGS): New macro, commented
17594 out because module isn't built.
17595 (fshelp_mod_LDFLAGS, fat_mod_LDFLAGS, ext2_mod_LDFLAGS)
17596 (ufs_mod_LDFLAGS, minix_mod_LDFLAGS, hfs_mod_LDFLAGS)
17597 (jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS, normal_mod_LDFLAGS)
17598 (hello_mod_LDFLAGS, boot_mod_LDFLAGS, terminal_mod_LDFLAGS)
17599 (ls_mod_LDFLAGS, cmp_mod_LDFLAGS, cat_mod_LDFLAGS)
17600 (font_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
17601 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
17602 (suspend_mod_LDFLAGS, reboot_mod_LDFLAGS, halt_mod_LDFLAGS)
17603 (help_mod_LDFLAGS, default_mod_LDFLAGS, timeout_mod_LDFLAGS)
17604 (configfile_mod_LDFLAGS, search_mod_LDFLAGS, xfs_mod_SOURCES)
17605 (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES)
17606 (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES)
17607 (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, gzio_mod_SOURCES)
17608 (gzio_mod_CFLAGS, gzio_mod_LDFLAGS): New macro.
17609
34eeec8a 176102005-10-20 Yoshinori K. Okuji <okuji@enbug.org>
17611
17612 * util/i386/pc/grub-probefs.c (main): Call grub_xfs_init and
17613 grub_xfs_fini. Do not call grub_hfs_init or grub_hfs_fini any
17614 longer, because HFS should not be used on PC.
17615
708367a3 176162005-10-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
17617
17618 * io/gzio.c (grub_gzio_read): Use OFFSET instead of FILE->OFFSET
17619 consistently within the loop.
17620
6fa1251a 176212005-10-15 Marco Gerards <mgerards@xs4all.nl>
17622
17623 * fs/xfs.c (grub_xfs_iterate_dir): Detect an error if part of a
17624 directory can not be read.
17625
4801580b 176262005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
17627
17628 * configure.ac (AC_INIT): Increase the version number to 1.91.
17629
17630 * DISTLIST: Added include/grub/terminfo.h, include/grub/tparm.h,
17631 include/grub/i386/pc/serial.h, term/terminfo.c, term/tparm.c and
17632 term/i386/pc/serial.c.
17633
219ad426 176342005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
17635
17636 * kern/file.c (grub_file_seek): Seeking to an offset equal to a
17637 file size must be permitted.
17638
17639 * kern/i386/pc/startup.S (multiboot_trampoline): Fix a mistake
17640 between %ah and %al.
17641
688e5699 176422005-10-15 Yoshinori K. Okuji <okuji@enbug.org>
17643
17644 * fs/xfs.c (grub_xfs_iterate_dir): Change the type of BLK to
17645 grub_uint64_t.
17646 Call the hook with a NUL-terminated filename.
17647 (grub_xfs_mount): Use grub_be_to_cpu32 instead of
17648 grub_cpu_to_be32.
17649
17650 * kern/term.c (cursor_state): New variable.
17651 (grub_term_set_current): Reset the cursor state on a new
17652 terminal.
17653 (grub_setcursor): Rewritten to use CURSOR_STATE.
17654 (grub_getcursor): New function.
17655
17656 * include/grub/term.h (grub_getcursor): New prototype.
17657
17658 * io/gzio.c (test_header): Align BUF for accessing it as 32-bit
17659 integers on ARM. Reported by Timothy Baldwin
17660 <T.E.Baldwin99@members.leeds.ac.uk>.
17661
bb34586c 176622005-10-11 Marco Gerards <mgerards@xs4all.nl>
17663
17664 * fs/sfs.c (grub_sfs_open): Don't free `data->label' if it is not
17665 allocated.
17666 (grub_sfs_dir): Likewise.
17667
9a909877 176682005-10-09 Marco Gerards <mgerards@xs4all.nl>
17669
17670 Add support for the SFS filesystem.
17671
17672 * fs/sfs.c: New file.
17673
17674 * DISTLIST: Added `fs/sfs.c'.
17675
17676 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/sfs.c'.
17677 (grub_probefs_SOURCES): Likewise.
17678 (grub_emu_SOURCES): Likewise.
17679 (pkgdata_MODULES): Add `sfs.mod'.
17680 (sfs_mod_SOURCES): New variable.
17681 (sfs_mod_CFLAGS): Likewise.
17682 (sfs_mod_LDFLAGS): Likewise.
17683
17684 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/sfs.c'.
17685 (pkgdata_MODULES): Add `sfs.mod'.
17686 (sfs_mod_SOURCES): New variable.
17687 (sfs_mod_CFLAGS): Likewise.
17688
17689 * util/grub-emu.c (main): Call `grub_sfs_init' and
17690 `grub_sfs_fini'.
17691
17692 * include/grub/fs.h (grub_sfs_init): New prototype.
17693 (grub_sfs_fini): Likewise.
17694
57bdbde3 176952005-10-07 Marco Gerards <mgerards@xs4all.nl>
17696
17697 Add support for the AFFS filesystem.
17698
17699 * fs/affs.c: New file.
17700
17701 * DISTLIST: Added `fs/affs.c'.
17702
17703 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/affs.c'.
17704 (grub_probefs_SOURCES): Likewise.
17705 (grub_emu_SOURCES): Likewise.
17706 (pkgdata_MODULES): Add `affs.mod'.
17707 (affs_mod_SOURCES): New variable.
17708 (affs_mod_CFLAGS): Likewise.
17709 (affs_mod_LDFLAGS): Likewise.
17710
17711 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/affs.c'.
17712 (pkgdata_MODULES): Add `affs.mod'.
17713 (affs_mod_SOURCES): New variable.
17714 (affs_mod_CFLAGS): Likewise.
17715
17716 * util/grub-emu.c (main): Call `grub_affs_init' and
17717 `grub_affs_fini'.
17718
17719 * include/grub/fs.h (grub_affs_init): New prototype.
17720 (grub_affs_fini): Likewise.
17721
047b67e0 177222005-10-01 Marco Gerards <mgerards@xs4all.nl>
17723
17724 * fs/xfs.c (grub_xfs_iterate_dir): Add parentheses.
17725
59b8208a 177262005-10-01 Marco Gerards <mgerards@xs4all.nl>
17727
17728 * configure.ac: Accept `x86_64' as host_cpu. In that case add
17729 `-m32' to CFLAGS.
17730
17731 * genmk.rb (class PModule): Always use `$(#{prefix}_LDFLAGS)' when
17732 linking.
f19dbdb7 17733
59b8208a 17734 * conf/i386-pc.rmk (COMMON_CFLAGS): Add `-m32'.
17735 (COMMON_LDFLAGS): New variable.
17736 (kernel_img_LDFLAGS): Include `COMMON_FLAGS'.
17737 (_chain_mod_LDFLAGS, fshelp_mod_LDFLAGS, fat_mod_LDFLAGS)
17738 (ext2_mod_LDFLAGS, ufs_mod_LDFLAGS, minix_mod_LDFLAGS)
17739 (hfs_mod_LDFLAGS, jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS)
17740 (xfs_mod_LDFLAGS, _linux_mod_LDFLAGS, linux_mod_LDFLAGS)
17741 (normal_mod_LDFLAGS, hello_mod_LDFLAGS, boot_mod_LDFLAGS)
17742 (terminal_mod_LDFLAGS, ls_mod_LDFLAGS, cmp_mod_LDFLAGS)
17743 (cat_mod_LDFLAGS, help_mod_LDFLAGS, reboot_mod_LDFLAGS)
17744 (halt_mod_LDFLAGS, vga_mod_LDFLAGS, font_mod_LDFLAGS)
17745 (terminfo_mod_LDFLAGS, serial_mod_LDFLAGS, _multiboot_mod_LDFLAGS)
17746 (multiboot_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS)
17747 (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS)
17748 (default_mod_LDFLAGS, timeout_mod_LDFLAGS, configfile_mod_LDFLAGS)
17749 (vbe_mod_LDFLAGS, vesafb_mod_LDFLAGS, vbeinfo_mod_LDFLAGS)
17750 (vbetest_mod_LDFLAGS, search_mod_LDFLAGS, gzio_mod_LDFLAGS): New
17751 variables.
17752 (normal_mod_ASFLAGS): Add `-m32'.
17753
17754 * include/grub/types.h (grub_host_addr_t, grub_host_off_t)
17755 (grub_host_size_t, grub_host_ssize_t): New types.
17756 (grub_addr_t, grub_off_t, grub_size_t, grub_ssize_t): Make type
fe6b695a 17757 dependent of `GRUB_CPU_SIZEOF_VOID_P' instead on
59b8208a 17758 `GRUB_HOST_SIZEOF_VOID_P'.
17759
17760 * include/grub/kernel.h (struct grub_module_header): Type of
17761 member offset changed to `grub_host_off_t'. Type of member size
17762 changed to `grub_host_size_t'.
17763 (struct grub_module_info): Type of member offset changed to
17764 `grub_host_off_t'. Type of member size changed to
17765 `grub_host_size_t'.
17766
b4093103 177672005-09-29 Yoshinori K. Okuji <okuji@enbug.org>
17768
17769 Make GRUB's kernel compliant to Multiboot Specification.
f19dbdb7 17770
b4093103 17771 * kern/i386/pc/startup.S (multiboot_header): New label.
17772 (multiboot_entry): Likewise.
17773 (multiboot_trampoline): Likewise.
17774
17775 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
17776 Increased to 0x4A0.
17777
17778 * fs/xfs.c (grub_xfs_iterate_dir): Fix a syntax error. You may not
17779 put parentheses after a question mark.
17780 [!GRUB_UTIL] (my_mod): New variable.
17781
17782 * util/grub-emu.c (main): Call grub_xfs_init and grub_xfs_fini.
17783
b2499b29 177842005-09-28 Marco Gerards <mgerards@xs4all.nl>
17785
17786 Adds support for the XFS filesystem. Btrees are not supported
17787 yet.
17788
17789 * fs/xfs.c: New file.
17790
17791 * DISTLIST: Added `fs/xfs.c'.
17792
17793 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `fs/xfs.c'.
17794 (grub_probefs_SOURCES): Likewise.
17795 (grub_emu_SOURCES): Likewise.
17796 (pkgdata_MODULES): Add `xfs.mod'.
17797 (xfs_mod_SOURCES): New variable.
17798 (xfs_mod_CFLAGS): Likewise.
17799
17800 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add `fs/xfs.c'.
17801 (pkgdata_MODULES): Add `xfs.mod'.
17802 (xfs_mod_SOURCES): New variable.
17803 (xfs_mod_CFLAGS): Likewise.
17804
17805 * util/grub-emu.c (main): Call `grub_xfs_init' and
17806 `grub_xfs_fini'.
17807
17808 * include/grub/fs.h (grub_xfs_init): New prototype.
17809 (grub_xfs_fini): Likewise.
17810
f19dbdb7 17811
83d37a62 178122005-09-18 Vesa Jaaskelainen <chaac@nic.fi>
17813
17814 * video/i386/pc/vbe.c (grub_vbe_set_video_mode): In indexed
17815 color modes, allow greater than 16 colors to be configured as
17816 a default palette.
17817
47d2d65e 178182005-09-03 Yoshinori K. Okuji <okuji@enbug.org>
17819
17820 * normal/completion.c (complete_arguments): Add the qualifier
17821 const into OPTIONS.
17822
17823 From Omniflux <omniflux+lists@omniflux.com>:
17824 * include/grub/terminfo.h: New file.
17825 * include/grub/tparm.h: Likewise.
17826 * include/grub/i386/pc/serial.h: Likewise.
17827 * term/terminfo.c: Likewise.
17828 * term/tparm.c: Likewise.
17829 * term/i386/pc/serial.c: Likewise.
17830 * conf/i386-pc.rmk (pkgdata_MODULES): Added terminfo.mod and
17831 serial.mod.
17832 (terminfo_mod_SOURCES): New variable.
17833 (terminfo_mod_CFLAGS): Likewise.
17834 (serial_mod_SOURCES): Likewise.
17835 (serial_mod_CFLAGS): Likewise.
17836
48b671ff 178372005-08-31 Yoshinori K. Okuji <okuji@enbug.org>
17838
17839 * DISTLIST: Replaced boot/powerpc/ieee1275/crt0.S and
17840 boot/powerpc/ieee1275/cmain.c with kern/powerpc/ieee1275/crt0.S
17841 and kern/powerpc/ieee1275/cmain.c, respectively.
17842
17843 * boot/powerpc/ieee1275/crt0.S: Moved to ...
17844 * kern/powerpc/ieee1275/crt0.S: ... here.
17845
17846 * boot/powerpc/ieee1275/cmain.c: Moved to ...
17847 * kern/powerpc/ieee1275/cmain.c: ... here.
f19dbdb7 17848
48b671ff 17849 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Use
17850 kern/powerpc/ieee1275/crt0.S and kern/powerpc/ieee1275/cmain.c
17851 instead of boot/powerpc/ieee1275/crt0.S and
17852 boot/powerpc/ieee1275/cmain.c, respectively.
17853
17854 * boot/i386/pc/boot.S (lba_mode): Do not store the total number of
17855 sectors. It was not used anyway.
17856
09fc77a7 178572005-08-30 Hollis Blanchard <hollis@penguinppc.org>
17858
17859 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): Fix
17860 `unused parameter' warning.
17861
003789c7 178622005-08-30 Hollis Blanchard <hollis@penguinppc.org>
17863
17864 * term/ieee1275/ofconsole.c (grub_ofconsole_getcharwidth): New
17865 function.
17866 (grub_ofconsole_term): Specify grub_ofconsole_getcharwidth as
17867 getcharwidth.
17868
67f44c86 178692005-08-28 Marco Gerards <metgerards@student.han.nl>
17870
17871 * include/grub/normal.h (enum grub_completion_type): Added
17872 `GRUB_COMPLETION_TYPE_ARGUMENT'.
17873
17874 * normal/cmdline.c (print_completion): Handle
17875 the `GRUB_COMPLETION_TYPE_ARGUMENT' type.
17876 * normal/menu_entry.c (store_completion): Likewise.
17877
17878 * normal/completion.c (complete_arguments): New function.
17879 (grub_normal_do_completion): Call `complete_arguments' when the
17880 current words start with a dash.
17881
0b5abe02 178822005-08-27 Marco Gerards <metgerards@student.han.nl>
17883
17884 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Fix typo (use
17885 `gzio.mod' instead of `io.mod').
17886
d9864ee1 178872005-08-22 Yoshinori K. Okuji <okuji@enbug.org>
17888
17889 * gendistlist.sh (EXTRA_DISTFILES): Added genfslist.sh.
17890 (DISTDIRS): Added io and video.
17891 Rewrite the search routine to make an output consistently.
17892
17893 * DISTLIST: Added conf/sparc64-ieee1275.mk,
17894 conf/sparc64-ieee1275.rmk, include/grub/gzio.h,
17895 include/grub/ieee1275/ieee1275.h, include/grub/ieee1275/ofdisk.h,
17896 io/gzio.c, kern/sparc64/cache.c, kern/sparc64/dl.c,
17897 kern/sparc64/ieee1275/init.c, kern/sparc64/ieee1275/openfw.c and
17898 util/powerpc/ieee1275/misc.c.
f19dbdb7 17899
d9864ee1 17900 * include/grub/gzio.h: New file.
17901 * io/gzio.c: Likewise.
f19dbdb7 17902
d9864ee1 17903 * kern/file.c (grub_file_close): Call grub_device_close only if
17904 FILE->DEVICE is not NULL.
17905
17906 * include/grub/mm.h [!NULL] (NULL): New macro.
17907
17908 * include/grub/err.h (GRUB_ERR_BAD_GZIP_DATA): New constant.
17909
17910 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added io/gzip.c.
17911 (pkgdata_MODULES): Added gzio.mod.
17912 (gzio_mod_SOURCES): New variable.
17913 (gzio_mod_CFLAGS): Likewise.
17914
17915 * conf/i386-pc.rmk (grub_emu_SOURCES): Added io/gzip.c.
17916 (pkgdata_MODULES): Added gzio.mod.
17917 (gzio_mod_SOURCES): New variable.
17918 (gzio_mod_CFLAGS): Likewise.
17919
17920 * commands/cat.c: Include grub/gzio.h.
17921 (grub_cmd_cat): Use grub_gzfile_open instead of
17922 grub_file_open.
f19dbdb7 17923
d9864ee1 17924 * commands/cmp.c: Include grub/gzio.h.
17925 (grub_cmd_cmp): Use grub_gzfile_open instead of
17926 grub_file_open.
17927
17928 * loader/i386/pc/multiboot.c: Include grub/gzio.h.
17929 (grub_rescue_cmd_multiboot): Use grub_gzfile_open instead of
17930 grub_file_open.
17931 (grub_rescue_cmd_module): Likewise.
17932
fa46f4b5 179332005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
17934
17935 * conf/sparc64-ieee1275.rmk (grubof_SOURCES): The first file must be
17936 kern/sparc64/ieee1275/init.c because it contains _start.
17937 * conf/sparc64-ieee1275.mk: Generated from conf/sparc64-ieee1275.rmk.
17938
e9211b5d 179392005-08-21 Vincent Pelletier <subdino2004@yahoo.fr>
17940
17941 * configure.ac: Add support for sparc64 host with ieee1275
17942 firmware.
17943 * configure: Generated from configure.ac.
17944 * disk/ieee1275/ofdisk.c (grub_ofdisk_open): Use grub_ssize_t
17945 instead of int.
17946 (grub_ofdisk_read): Likewise.
17947 (grub_ofdisk_open): Use %p to print pointer values, and cast the
17948 pointers as (void *) to remove a warning.
17949 (grub_ofdisk_close): Likewise.
17950 (grub_ofdisk_read): Likewise.
17951 * kern/ieee1275/ieee1275.c (grub_ieee1275_exit): This never
17952 returns, so make it return void to remove a warning.
17953 * include/grub/ieee1275/ieee1275.h (grub_ieee1275_exit):
17954 Corresponding prototype change.
17955 * kern/mm.c (grub_mm_init_region): Use %p to print pointer
17956 values, and cast the pointers as (void *) to remove a warning.
17957 (grub_mm_dump): Likewise.
17958 * conf/sparc64-ieee1275.mk: New file.
17959 * conf/sparc64-ieee1275.rmk: Likewise.
17960 * include/grub/sparc64/setjmp.h: Likewise.
17961 * include/grub/sparc64/types.h: Likewise.
17962 * include/grub/sparc64/ieee1275/console.h: Likewise.
17963 * include/grub/sparc64/ieee1275/ieee1275.h: Likewise.
17964 * include/grub/sparc64/ieee1275/kernel.h: Likewise.
17965 * include/grub/sparc64/ieee1275/time.h: Likewise.
17966 * kern/sparc64/cache.c: Likewise.
17967 * kern/sparc64/dl.c: Likewise.
17968 * kern/sparc64/ieee1275/init.c: Likewise.
17969 * kern/sparc64/ieee1275/openfw.c: Likewise.
17970
385c6a92 179712005-08-21 Yoshinori K. Okuji <okuji@enbug.org>
17972
17973 * util/console.c (grub_ncurses_putchar): If C is greater than
17974 0x7f, set C to a question mark.
17975 (grub_ncurses_getcharwidth): New function.
17976 (grub_ncurses_term): Specify grub_ncurses_getcharwidth as
17977 getcharwidth.
17978
17979 * normal/menu.c (print_entry): Made aware of Unicode. First,
17980 convert TITLE to UCS-4, and predict the cursor position by
17981 grub_getcharwidth.
17982
17983 * include/grub/misc.h (grub_utf8_to_ucs4): Specify the qualifier
17984 const to SRC.
17985 * kern/misc.c (grub_utf16_to_utf8): Likewise.
17986
16ccb8b1 179872005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
17988
17989 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Specify
17990 the boot file by the option BOOT_IMAGE. Use grub_stpcpy instead of
17991 grub_strcat.
17992
17993 * loader/i386/pc/linux.c (grub_rescue_cmd_linux): Specify the boot
17994 file by the option BOOT_IMAGE. Use grub_stpcpy instead of
17995 grub_strcpy and grub_strlen. Take it into account that a space
17996 character is inserted as a delimiter.
17997
6a85ce79 179982005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
17999
18000 * partmap/pc.c (pc_partition_map_iterate): Include the value of an
fe6b695a 18001 invalid magic in the error.
6a85ce79 18002
18003 * commands/search.c: New file.
f19dbdb7 18004
6a85ce79 18005 * util/grub-emu.c (main): Call grub_search_init and
18006 grub_search_fini.
18007
18008 * kern/rescue.c (grub_rescue_print_disks): Removed.
18009 (grub_rescue_print_devices): New function.
18010 (grub_rescue_cmd_ls): Use grub_device_iterate with
18011 grub_rescue_print_devices instead of grub_disk_dev_iterate with
18012 grub_rescue_print_disks.
18013
18014 * kern/partition.c (grub_partition_iterate): Return the result of
18015 PARTMAP->ITERATE instead of GRUB_ERRNO.
18016
18017 * kern/device.c: Include grub/partition.h.
18018 (grub_device_iterate): New function.
18019
18020 * include/grub/partition.h (grub_partition_iterate): Return int
18021 instead of grub_err_t.
18022
18023 * include/grub/normal.h [GRUB_UTIL] (grub_search_init): New
18024 prototype.
18025 [GRUB_UTIL] (grub_search_fini): Likewise.
18026
18027 * include/grub/device.h (grub_device_iterate): New prototype.
18028
18029 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
18030 commands/search.c.
18031 (pkgdata_MODULES): Added search.mod.
18032 (search_mod_SOURCES): New variable.
18033 (search_mod_CFLAGS): Likewise.
18034
18035 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/search.c.
18036 (pkgdata_MODULES): Added search.mod.
18037 (search_mod_SOURCES): New variable.
18038 (search_mod_CFLAGS): Likewise.
18039
18040 * commands/ls.c (grub_ls_list_disks): Renamed to ...
18041 (grub_ls_list_devices): ... this, and use grub_device_iterate.
18042 All callers changed.
18043
18044 * DISTLIST: Added commands/search.c.
18045
ef095434 180462005-08-20 Yoshinori K. Okuji <okuji@enbug.org>
18047
18048 * kern/term.c (grub_putchar): Use grub_utf8_to_ucs4 for the
18049 conversion.
18050 (grub_getcharwidth): New function.
18051
18052 * kern/misc.c (grub_utf8_to_ucs4): New function.
18053
18054 * include/grub/term.h (struct grub_term): Added a new member
18055 "getcharwidth".
18056 (grub_getcharwidth): New prototype.
18057
18058 * include/grub/misc.h (grub_utf8_to_ucs4): New prototype.
18059
18060 * term/i386/pc/console.c (map_char): New function. Segregated from
18061 grub_console_putchar.
18062 (grub_console_putchar): Use map_char.
18063 (grub_console_getcharwidth): New function.
18064 (grub_console_term): Specified grub_console_getcharwidth as
18065 getcharwidth.
18066
18067 * term/i386/pc/vga.c (grub_vga_getcharwidth): New function.
18068 (grub_vga_term): Specified grub_vga_getcharwidth as getcharwidth.
18069
18070 * term/i386/pc/vesafb.c (grub_virtual_screen_setup): Return
18071 GRUB_ERRNO.
18072 (grub_vesafb_init): Do not use RC. Instead, use GRUB_ERRNO. Rely
18073 on grub_strtoul completely.
18074 (write_char): Declare local variables in the beginning of the
18075 function.
18076 (grub_vesafb_getcharwidth): New function.
18077 (grub_vesafb_term): Specified grub_vesafb_getcharwidth as
18078 getcharwidth.
18079
1f0a95e4 180802005-08-19 Yoshinori K. Okuji <okuji@enbug.org>
18081
18082 * DISTLIST: Replace commands/i386/pc/vbe_list_modes.c and
18083 commands/i386/pc/vbe_test.c with commands/i386/pc/vbeinfo.c and
18084 commands/i386/pc/vbetest.c.
18085
18086 * video/i386/pc/vbe.c (grub_vbe_probe): If INFOBLOCK is not NULL,
18087 call grub_vbe_get_controller_info again, because the returned
18088 information is volatile.
18089 (grub_vbe_set_video_mode): Mostly rewritten.
18090 (grub_vbe_get_video_mode): Use grub_vbe_probe and use
18091 grub_vbe_status_t correctly.
18092 (grub_vbe_get_video_mode_info): Likewise.
18093 (grub_vbe_set_pixel_rgb): Use a switch statement rather than
18094 several if statements.
18095
18096 * commands/i386/pc/vbe_list_modes.c: Renamed to ...
18097 * commands/i386/pc/vbeinfo.c: ... this.
18098
18099 * commands/i386/pc/vbe_test.c: Renamed to ...
18100 * commands/i386/pc/vbetest.c: ... this.
18101
18102 * commands/i386/pc/vbeinfo.c (grub_cmd_vbe_list_modes): Renamed to
18103 ...
18104 (grub_cmd_vbeinfo): ... this. Save video modes before
18105 iterating. Skip a video mode, if it is not available, not enough
18106 information is given or it is monochrome. Show the memory
18107 model. Leave the interpretation of MODEVAR to grub_strtoul
18108 completely.
18109 (GRUB_MOD_INIT): Rename vbe_list_modes to vbeinfo.
18110 (GRUB_MOD_FINI): Likewise.
18111
18112 * commands/i386/pc/vbetest.c (grub_cmd_vbe_test): Renamed to ...
18113 (grub_cmd_vbetest): ... this. Don't print unnecessarily. Use
18114 grub_err_t instead of grub_uint32_t. Don't use SPTR. Remove a
18115 duplicated grub_env_get. Leave the interpretation of MODEVAR to
18116 grub_strtoul completely.
18117 (real2pm): Removed.
18118 (GRUB_MOD_INIT): Rename vbe_test to vbetest.
18119 (GRUB_MOD_FINI): Likewise.
18120
18121 * normal/misc.c: Include grub/mm.h.
18122
18123 * conf/i386-pc.rmk (pkgdata_MODULES): Replaced vbe_test.mod and
18124 vbe_list_modes with vbetest.mod and vbeinfo.mod.
18125 (vbe_list_modes_mod_SOURCES): Removed.
18126 (vbe_list_modes_mod_CFLAGS): Likewise.
18127 (vbe_test_mod_SOURCES): Likewise.
18128 (vbe_test_mod_CFLAGS): Likewise.
18129 (vbeinfo_mod_SOURCES): New variable.
18130 (vbeinfo_mod_CFLAGS): Likewise.
18131 (vbetest_mod_SOURCES): Likewise.
18132 (vbetest_mod_CFLAGS): Likewise.
18133
992ffbbe 181342005-08-18 Yoshinori K. Okuji <okuji@enbug.org>
18135
18136 * normal/misc.c: New file.
18137
18138 * DISTLIST: Added normal/misc.c.
f19dbdb7 18139
992ffbbe 18140 * partmap/amiga.c (amiga_partition_map_iterate): Add an argument
18141 DISK to HOOK. Call HOOK with DISK.
18142 * partmap/apple.c (apple_partition_map_iterate): Likewise.
18143 * partmap/pc.c (pc_partition_map_iterate): Likewise.
18144 * partmap/sun.c (sun_partition_map_iterate): Likewise.
18145
18146 * normal/menu_entry.c (struct screen): Added a new member
18147 "completion_shown".
18148 (completion_buffer): New global variable.
18149 (make_screen): Set SCREEN->COMPLETION_SHOWN to zero.
18150 (store_completion): New function.
18151 (complete): Likewise.
18152 (clear_completions): Likewise.
18153 (grub_menu_entry_run): If SCREEN->COMPLETION_SHOWN is non-zero,
18154 call clear_completions and reset SCREEN->COMPLETION_SHOWN. If C is
18155 a tab, call complete.
18156
18157 * normal/completion.c (disk_dev): Removed.
18158 (print_simple_completion): Likewise.
18159 (print_partition_completion): Likewise.
18160 (print_func): New global variable.
18161 (add_completion): Do not take the arguments WHAT or PRINT any
18162 longer. Added a new argument TYPE. Instead of printing directly,
18163 call PRINT_FUNC if not NULL.
18164 All callers changed.
18165 (complete_device): Use a local variable DEV instead of
18166 DISK_DEV. Do not move CURRENT_WORD to the end of a device name.
18167 (grub_normal_do_completion): Take a new argument HOOK. Do not
18168 initialize DISK_DEV. Initialize PRINT_FUNC to HOOK. If RET is an
18169 empty string, return NULL instead.
18170 All callers changed.
18171
18172 * normal/cmdline.c (print_completion): New function.
18173
18174 * kern/partition.c (grub_partition_iterate): Add an argument DISK
18175 to HOOK.
18176 All callers changed.
18177
18178 * kern/disk.c (grub_print_partinfo): Removed.
18179
18180 * include/grub/partition.h (struct grub_partition_map): Add a new
18181 argument DISK into HOOK of ITERATE.
18182 (grub_partition_iterate): Add a new argument DISK to HOOK.
18183
18184 * include/grub/normal.h (enum grub_completion_type): New enum.
18185 (grub_completion_type_t): New type.
18186 (GRUB_COMPLETION_TYPE_COMMAND): New constant.
18187 (GRUB_COMPLETION_TYPE_DEVICE): Likewise.
18188 (GRUB_COMPLETION_TYPE_PARTITION): Likewise.
18189 (GRUB_COMPLETION_TYPE_FILE): Likewise.
18190 (grub_normal_do_completion): Added a new argument HOOK.
18191 (grub_normal_print_device_info): New prototype.
18192
18193 * include/grub/disk.h (grub_print_partinfo): Removed.
18194
18195 * conf/i386-pc.rmk (grub_emu_SOURCES): Added normal/misc.c.
18196 (normal_mod_SOURCES): Likewise.
18197 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
18198 (normal_mod_SOURCES): Likewise.
18199
18200 * commands/ls.c (grub_ls_list_disks): Use
18201 grub_normal_print_device_info instead of grub_print_partinfo. Free
18202 PNAME.
18203 (grub_ls_list_files): Use grub_normal_print_device_info instead of
18204 duplicating the code.
18205
0bd41162 182062005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
18207
18208 * commands/i386/pc/vbe_list_modes.c: Update source formatting to
f19dbdb7 18209 follow GCS more precisely.
18210 * commands/i386/pc/vbe_test.c: Likewise.
18211 * include/grub/i386/pc/vbe.h: Likewise.
18212 * term/i386/pc/vesafb.c: Likewise.
18213 * video/i386/pc/vbe.c: Likewise.
0bd41162 18214
6323696a 182152005-08-16 Vesa Jaaskelainen <chaac@nic.fi>
18216
18217 * DISTLIST: Added term/i386/pc/vesafb.c
18218 DISTLIST: Added video/i386/pc/vbe.c
18219 DISTLIST: Added commands/i386/pc/vbe_list_modes.c.
18220 DISTLIST: Added commands/i386/pc/vbe_test.c.
18221 * commands/i386/pc/vbe_list_modes.c: New file.
18222 * commands/i386/pc/vbe_test.c: Likewise.
18223 * term/i386/pc/vesafb.c: Likewise.
18224 * video/i386/pc/vbe.c: Likewise.
18225 * include/grub/i386/pc/vbe.h (GRUB_VBE_DEFAULT_VIDEO_MODE): Added define.
18226 (grub_vbe_probe) Added prototype.
18227 (grub_vbe_set_video_mode) Likewise.
18228 (grub_vbe_get_video_mode) Likewise.
18229 (grub_vbe_get_video_mode_info) Likewise.
18230 (grub_vbe_set_pixel_rgb) Likewise.
18231 (grub_vbe_set_pixel_index) Likewise.
18232 * conf/i386-pc.rmk (pkgdata_MODULES): Added vbe.mod.
18233 (pkgdata_MODULES): Added vesafb.mod.
18234 (pkgdata_MODULES): Added vbe_list_modes.mod.
18235 (pkgdata_MODULES): Added vbe_test.mod.
18236 (vbe_mod_SOURCES): Added.
18237 (vbe_mod_CFLAGS): Likewise.
18238 (vesafb_mod_SOURCES): Likewise.
18239 (vesafb_mod_CFLAGS): Likewise.
18240 (vbe_list_modes_mod_SOURCES): Likewise.
18241 (vbe_list_modes_mod_CFLAGS): Likewise.
18242 (vbe_test_mod_SOURCES): Likewise.
18243 (vbe_test_mod_CFLAGS): Likewise.
18244
0a74e62f 182452005-08-14 Yoshinori K. Okuji <okuji@enbug.org>
18246
0a74e62f 18247 * normal/command.c (grub_command_execute): If INTERACTIVE is
18248 false and GRUB_COMMAND_FLAG_NO_ECHO is not specified, print
18249 CMDLINE. Disable the pager if INTERACTIVE is true.
18250 All callers are changed.
18251
18252 * normal/main.c (grub_normal_execute): Read command.lst and fs.lst
18253 before reading a config file.
18254 * normal/main.c (read_config_file): Even if a command is not
18255 found, register it if it is within an entry.
18256
18257 * util/grub-emu.c: Include sys/types.h and unistd.h.
18258 (options): Added --hold.
18259 (struct arguments): Added a new member "hold".
18260 (parse_opt): If KEY is 'H', set ARGS->HOLD to ARG or -1 if ARG is
18261 missing.
18262 (main): Initialize ARGS.HOLD to zero. Wait until ARGS.HOLD is
18263 cleared by a debugger, if it is not zero.
18264
18265 * include/grub/normal.h (grub_command_execute): Add an argument
18266 INTERACTIVE.
18267
e51f85ae 182682005-08-14 Vesa Jaaskelainen <chaac@nic.fi>
18269
18270 * DISTLIST: Added include/grub/i386/pc/vbe.h.
18271
e9c6f39b 182722005-08-13 Yoshinori K. Okuji <okuji@enbug.org>
18273
18274 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): Replace the test
18275 program with another one, because the old one didn't detect a bug
18276 in gcc-3.4. Always use regparm 2, because the new test is still
18277 not enough for gcc-4.0. Someone must investigate a simple test
18278 case which detects a bug in gcc-4.0.
18279
8de3495c 182802005-08-12 Yoshinori K. Okuji <okuji@enbug.org>
18281
18282 * DISTLIST: Added normal/completion.c.
18283
18284 * normal/completion.c: New file.
f19dbdb7 18285
8de3495c 18286 * term/i386/pc/console.c (grub_console_getwh): New function.
18287 (grub_console_term): Assign grub_console_getwh to getwh.
18288
18289 * normal/cmdline.c (grub_tab_complete): Removed. Now the same
18290 function is defined in normal/completion.c as
18291 grub_normal_do_completion.
18292 (grub_cmdline_get): Use grub_normal_do_completion instead of
18293 grub_tab_complete.
18294
18295 * kern/partition.c (grub_partition_map_iterate): Return 1 if HOOK
18296 returns non-zero, otherwise return 0.
18297 (grub_partition_iterate): First, probe the partition map. Then,
18298 call ITERATE only for this partition map.
18299
18300 * kern/misc.c (grub_strncmp): Rewritten.
18301
18302 * kern/disk.c (grub_disk_dev_iterate): Return 1 if P->ITERATE
18303 returns non-zero. Otherwise return 0.
18304
18305 * include/grub/partition.h (grub_partition_map_iterate): Return
18306 int instead of void.
18307
18308 * include/grub/normal.h (grub_normal_do_completion): New prototype.
18309
18310 * include/grub/misc.h (grub_strncmp): Change the type of N to
18311 grub_size_t.
18312
18313 * include/grub/disk.h (grub_disk_dev_iterate): Return int instead
18314 of void.
18315
18316 * normal/menu.c (draw_border): Cast GRUB_TERM_BORDER_WIDTH to
fe6b695a 18317 unsigned explicitly before comparing it with I.
8de3495c 18318
18319 * kern/main.c (grub_env_write_root): Add the attribute unused into
18320 VAR.
18321
18322 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
18323 normal/completion.c.
18324 (normal_mod_SOURCES): Likewise.
18325 * conf/i386-pc.rmk (grub_emu_SOURCES): Likewise.
18326 (normal_mod_SOURCES): Likewise.
18327
18328 * normal/command.c (grub_iterate_commands): If ITERATE returns
18329 non-zero, return one immediately.
18330
e85e144b 183312005-08-09 Vesa Jaaskelainen <chaac@nic.fi>
18332
18333 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vbe.h.
18334 * kern/i386/pc/startup.S: Updated Global Descriptor table's
18335 descriptions.
18336 (grub_vbe_get_controller_info): New function.
18337 (grub_vbe_get_mode_info): Likewise.
18338 (grub_vbe_set_mode): Likewise.
18339 (grub_vbe_get_mode): Likewise.
18340 (grub_vbe_set_memory_window): Likewise.
18341 (grub_vbe_get_memory_window): Likewise.
18342 (grub_vbe_set_scanline_length): Likewise.
18343 (grub_vbe_get_scanline_length): Likewise.
18344 (grub_vbe_set_display_start): Likewise.
18345 (grub_vbe_get_display_start): Likewise.
18346 (grub_vbe_set_palette_data): Likewise.
18347 * include/grub/i386/pc/vbe.h: New file.
18348
c46153d2 183492005-08-08 Hollis Blanchard <hollis@penguinppc.org>
18350
18351 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
18352 kern/ieee1275/of.c with kern/ieee1275/ieee1275.c.
18353 * DISTLIST: Likewise.
18354 * kern/ieee1275/of.c: Moved to ...
18355 * kern/ieee1275/ieee1275.c: ... here.
18356
0cb90c45 183572005-08-08 Hollis Blanchard <hollis@penguinppc.org>
18358
18359 * term/ieee1275/ofconsole.c: Include <grub/mm.h>.
18360 (grub_ofconsole_getwh): Cast -1 to type grub_ieee1275_ihandle_t.
18361 Pass 0 as `end' parameter to grub_strtoul().
18362
a19fb360 183632005-08-08 Hollis Blanchard <hollis@penguinppc.org>
18364
18365 * include/grub/powerpc/ieee1275/console.h: Do not include
18366 <grub/types.h>. Do not include <grub/symbol.h>. Remove ASM_FILE
18367 ifdef.
18368 (grub_console_cur_color): Remove i386-specific prototype.
18369 (grub_console_real_putchar): Likewise.
18370 (grub_console_checkkey): Likewise.
18371 (grub_console_getkey): Likewise.
18372 (grub_console_getxy): Likewise.
18373 (grub_console_gotoxy): Likewise.
18374 (grub_console_cls): Likewise.
18375 (grub_console_setcursor): Likewise.
18376 * kern/powerpc/ieee1275/init.c: Don't include <grub/console.h>.
18377 Include <grub/machine/console.h>.
18378 * term/ieee1275/ofconsole.c: Likewise.
18379
4ac9bd04 183802005-08-08 Yoshinori K. Okuji <okuji@enbug.org>
18381
18382 * Makefile.in (LIBLZO): New variable.
18383
18384 * configure.ac: Check for LZO version 2.
18385
18386 * util/i386/pc/grub-mkimage.c [HAVE_LZO_LZO1X_H]: Include
18387 lzo/lzo1x.h instead of lzo1x.h.
18388
18389 * conf/i386-pc.rmk (grub_mkimage_LDFLAGS): Use $(LIBLZO) instead
18390 of -llzo.
18391
18392 * util/i386/pc/grub-setup.c (main): Do not free PREFIX
18393 twice. Reported by Vladimir Serbinenko <phcoder@gmail.com>.
18394
18395 * partmap/pc.c (pc_partition_map_probe): Restore P->DATA after
18396 copying the data from PARTITION to P.
18397
f4917dfd 183982005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
18399
18400 * kern/rescue.c (grub_rescue_cmd_rmmod): If the reference count is
18401 negative, unload the module.
18402
18403 * util/i386/pc/grub-setup.c (setup): The name of the PC partition
18404 map is "pc_partition_map" but not "pc".
18405 (usage): Fix the description. The options are --boot-image and
18406 --core-image but not --boot-file or --core-file.
18407 (main): If not specified explicitly, make BOOT_FILE and CORE_FILE
18408 based on DEFAULT_BOOT_FILE and DEFAULT_CORE_FILE with DIR or
18409 DEFAULT_DIRECTORY.
18410
18411 * util/i386/pc/grub-install.in: Do not specify --boot-file or
18412 --core-file. Specify INSTALL_DEVICE as an argument.
18413
18414 * util/console.c: Include config.h.
18415 [HAVE_NCURSeS_CURSES_H]: Include ncurses/curses.h.
18416 [HAVE_NCURSES_H]: Include ncurses.h.
18417 [HAVE_CURSES_H]: Include curses.h.
18418 [!A_NORMAL] (A_NORMAL): Defined as zero.
18419 [!A_STANDOUT] (A_STANDOUT): Likewise.
18420
18421 * conf/i386-pc.rmk (grub_emu_LDFLAGS): Use $(LIBCURSES) instead of
18422 -lncurses.
18423 * conf/powerpc-ieee1275.rmk (grub_emu_LDFLAGS): Likewise.
18424
18425 * configure.ac: Check for curses libraries and headers.
18426
18427 * Makefile.in (LIBCURSES): New variable.
18428
18429 * genmk.rb (Script::rule): Set the executable bits.
18430
18431 * util/i386/pc/biosdisk.c (grub_util_biosdisk_get_grub_dev): The
18432 name of the PC partition map is "pc_partition_map" but not "pc".
18433
0e143073 184342005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
18435
18436 * util/i386/pc/grub-install.in (grub_probefs): New variable.
18437 (modules): Likewise.
18438 (usage): Added descriptions for --modules and --grub-probefs.
18439 Handle --modules and --grub-probefs. Save the arguments in MODULES
18440 and GRUB_PROBEFS, respectively.
18441 Auto-detect a filesystem module against GRUBDIR. If the result is
18442 empty and modules are not specified explicitly, abort the
18443 installation. Add the result to MODULES.
18444
18445 * DISTLIST: Removed boot/powerpc/ieee1275/ieee1275.c,
18446 disk/powerpc/ieee1275/ofdisk.c,
18447 include/grub/powerpc/ieee1275/init.h and
18448 term/powerpc/ieee1275/ofconsole.c.
18449 Added disk/ieee1275/ofdisk.c, kern/ieee1275/of.c and
18450 term/ieee1275/ofconsole.c.
18451
18452 * include/grub/powerpc/ieee1275/console.h: Resurrected.
18453
18454 * COPYING: Upgraded to the latest version. Only the address of the
18455 FSF office has changed.
f19dbdb7 18456
efd6e6d5 184572005-08-07 Yoshinori K. Okuji <okuji@enbug.org>
18458
18459 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Replaced
18460 kern/ieee1275.c with kern/ieee1275/of.c.
18461
18462 * kern/ieee1275.c: Moved to ...
18463 * kern/ieee1275/of.c: ... here.
18464
8ceafda2 184652005-08-06 Yoshinori K. Okuji <okuji@enbug.org>
18466
18467 * conf/i386-pc.rmk (kernel_img_HEADERS): Reordered for
fe6b695a 18468 readability.
8ceafda2 18469
18470 * config.guess: Updated to the latest version from gnulib.
18471 * config.sub: Likewise.
18472 * install.sh: Likewise.
18473 * mkinstalldirs: Likewise.
18474
18475 * include/grub/console.h: Removed. This file is arch-specific. Do
18476 not put this in include/grub.
18477
18478 * include/grub/i386/pc/console.h: Resurrected.
18479
18480 * util/console.c: Include grub/machine/console.h instead of
18481 grub/console.h.
18482 * util/grub-emu.c: Likewise.
18483
267f6cd9 184842005-08-04 Marco Gerards <metgerards@student.han.nl>
18485
18486 * kern/term.c (grub_putcode): Use `grub_getwh' instead of
18487 hardcoded value.
f19dbdb7 18488
267f6cd9 18489 From Vincent Pelletier <subdino2004@yahoo.fr>
18490 * include/grub/term.h (GRUB_TERM_WIDTH, GRUB_TERM_HEIGHT):
18491 Redefined to use grub_getwh.
18492 (grub_term): New member named getwh.
18493 (grub_getwh): New prototype.
18494 * kern/term.c (grub_getwh): New function.
18495 * term/i386/pc/console.c (grub_console_getwh): New function.
18496 (grub_console_term): New member `getwh'.
18497 * term/i386/pc/vga.c (grub_vga_getwh): New function.
18498 (grub_vga_term): New member `getwh'.
0b5abe02 18499 * term/ieee1275/ofconsole.c (grub_ofconsole_readkey): Use
267f6cd9 18500 grub_ssize_t.
18501 (grub_ofconsole_getw): New function.
18502 (grub_ofconsole_init): Use grub_ssize_t and unsigned char.
18503 (grub_ofconsole_term): New field named getwh and new initial
18504 value.
18505
3be7266d 185062005-08-03 Hollis Blanchard <hollis@penguinppc.org>
18507
18508 * include/grub/powerpc/ieee1275/ieee1275.h: Move ...
18509 * include/grub/ieee1275/ieee1275.h: ... to here. All users updated.
18510 Move `abort', `grub_reboot', and `grub_halt' prototypes ...
18511 * include/grub/powerpc/ieee1275/kernel.h: ... to here.
18512 * commands/ieee1275/halt.c: Include <grub/machine/kernel.h> instead
18513 of <grub/machine/ieee1275.h>.
18514 * commands/ieee1275/reboot.c: Likewise.
18515 * boot/powerpc/ieee1275/ieee1275.c: Move ...
18516 * kern/ieee1275.c: ... to here. All users updated. Change all
18517 parameter structs to use new type `grub_ieee1275_cell_t'.
18518 * term/powerpc/ieee1275/ofconsole.c: Move ...
18519 * term/ieee1275/ofconsole.c: ... to here. All users updated.
18520 * disk/powerpc/ieee1275/ofdisk.c: Move ...
18521 * disk/ieee1275/ofdisk.c: ... to here. All users updated.
18522 * boot/powerpc/ieee1275/cmain.c: Change `grub_ieee1275_entry_fn' type
18523 to return int.
18524 * include/grub/i386/pc/console.h: Move to include/grub/console.h.
18525 Remove unused prototypes. All users updated.
18526 * include/grub/powerpc/ieee1275/console.h: Removed.
18527 * include/grub/powerpc/ieee1275/ieee1275.h: Define
18528 `grub_ieee1275_cell_t'.
18529 * kern/powerpc/ieee1275/openfw.c: Include <grub/machine/kernel.h>.
18530 Cast comparisons with -1 to the correct type.
18531 * loader/powerpc/ieee1275/linux.c (kernel_entry_t): Change parameter
18532 type to match `grub_ieee1275_entry_fn'.
18533
8b5f3938 185342005-08-01 Yoshinori K. Okuji <okuji@enbug.org>
18535
18536 * DISTLIST: Added util/i386/pc/grub-probefs.c.
18537
18538 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-probefs.
18539 (grub_setup_SOURCES): Removed partmap/amiga.c, partmap/apple.c and
18540 partmap/sun.c.
18541 (grub_probefs_SOURCES): New variable.
18542
18543 * util/i386/pc/grub-probefs.c: New file.
18544
18545 * util/i386/pc/grub-setup.c (main): Call
18546 grub_pc_partition_map_init, grub_ufs_init, grub_minix_init,
18547 grub_hfs_init and grub_jfs_init to initialize the system. Call
18548 grub_ufs_fini, grub_minix_fini, grub_hfs_fini, grub_jfs_init and
18549 grub_pc_partition_map_fini to finish the system.
18550
ea409713 185512005-07-31 Yoshinori K. Okuji <okuji@enbug.org>
18552
18553 * loader/i386/pc/multiboot.c (grub_multiboot_is_elf32): New
18554 function.
18555 (grub_multiboot_load_elf32): Likewise.
18556 (grub_multiboot_is_elf64): Likewise.
18557 (grub_multiboot_load_elf64): Likewise.
18558 (grub_multiboot_load_elf): Likewise.
18559 (grub_rescue_cmd_multiboot): Call grub_multiboot_load_elf to load
18560 an ELF32 or ELF64 file.
18561 This is based on a patch from Ruslan Nikolaev <nruslan@mail.com>.
18562
18563 From Serbinenko Vladimir <serbinenko.vova@list.ru>:
18564 * kern/disk.c (grub_print_partinfo): Check if FS->LABEL is not
18565 NULL before calling FS->LABEL.
18566 * fs/fat.c (grub_fat_dir): Initialize DIRNAME to NULL.
18567 * commands/ls.c (grub_ls_list_files): Show labels, if possible.
18568 (grub_ls_list_disks): Check if FS and FS->LABEL are not NULL
18569 before calling FS->LABEL.
18570
141a288b 185712005-07-26 Yoshinori K. Okuji <okuji@enbug.org>
18572
18573 * util/i386/pc/grub-install.in (datadir): New variable.
18574 (libdir): Removed.
18575 (pkgdatadir): New variable.
18576 (pkglibdir): Removed.
18577
0d5f8a54 185782005-07-24 Yoshinori K. Okuji <okuji@enbug.org>
18579
18580 * DISTLIST: Added util/i386/pc/grub-install.in.
18581
18582 * util/i386/pc/grub-install.in: New file.
18583
18584 * conf/i386-pc.rmk (sbin_SCRIPTS): New variable.
18585 (grub_install_SOURCES): Likewise.
18586
18587 * genmk.rb: Added support for scripts.
18588 (Script): New class.
18589 (scripts): New variable.
18590
18591 * Makefile.in (install-local): Install sbin_SCRIPTS by
18592 INSTALL_SCRIPT.
18593 (uninstall): Remove sbin_SCRIPTS.
18594
18595 * util/i386/pc/grub-setup.c (main): If the argument is not a GRUB
18596 device, try to get a GRUB device by
18597 grub_util_biosdisk_get_grub_dev.
18598 Free DEST_DEV.
18599
18600 * util/i386/pc/grub-mkdevicemap.c (usage): Remove a duplicated
18601 description for --device-map.
18602
5f968e1e 186032005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
18604
18605 Change the semantics of variable hooks. They now return strings
18606 instead of error values.
f19dbdb7 18607
5f968e1e 18608 * util/i386/pc/grub-setup.c: Include grub/env.h.
18609 (setup): Use grub_device_set_root instead of grub_env_set.
18610
18611 * kern/rescue.c (grub_rescue_cmd_root): Use grub_env_set and
18612 grub_env_get instead of grub_device_set_root and
18613 grub_device_get_root, respectively.
18614
18615 * kern/main.c (grub_env_write_root): New function.
18616 (grub_set_root_dev): Register grub_env_write_hook for "root". Use
18617 grub_env_set instead of grub_device_set_root.
18618
18619 * kern/env.c (HASHSZ): Reduced to 13, because GRUB does not need
18620 many variables.
18621 (grub_env_set): Set ENV->VALUE to the result of ENV->WRITE_HOOK
18622 rather than calling ENV->WRITE_HOOK afterwards.
18623 (grub_env_get): Return the result of ENV->READ_HOOK rather than
18624 passing a pointer of a pointer.
18625 (grub_register_variable_hook): Change the types of "read_hook" and
18626 "write_hook" to grub_env_read_hook_t and grub_env_write_hook_t,
18627 respectively.
18628 Allocate the default empty string on the heap, because this string
18629 may be freed later.
18630
18631 * kern/device.c: Include grub/env.h.
18632 (grub_device_set_root): Removed.
18633 (grub_device_get_root): Likewise.
18634 (grub_device_open): Use grub_env_get instead of
18635 grub_device_get_root.
18636
18637 * include/grub/env.h (grub_env_read_hook_t): New type.
18638 (grub_env_write_hook_t): Likewise.
18639 (grub_env_var): Change the types of "read_hook" and "write_hook"
18640 to grub_env_read_hook_t and grub_env_write_hook_t, respectively.
18641 (grub_register_variable_hook): Likewise.
18642
18643 * include/grub/device.h (grub_device_set_root): Removed.
18644 (grub_device_set_root): Likewise.
18645
18646 * fs/fat.c (grub_fat_dir): Make a copy of PATH in DIRNAME, and
18647 make sure that DIRNAME terminates with '/', so that
18648 grub_fat_find_dir will fail if PATH is not a directory.
18649
18650 * commands/ls.c (grub_ls_list_files): Remove the qualifier const
18651 from DIRNAME.
18652 Use the qualifier auto for print_files and print_files_long.
18653 If FS->DIR sets GRUB_ERRNO to GRUB_ERR_BAD_FILE_TYPE, try DIRNAME
18654 as a regular file.
18655 Put a newline only if there is no error.
18656 (grub_cmd_ls): Remove grub_ls_print_files, because this is not
18657 used.
18658
896f0afd 186592005-07-20 Yoshinori K. Okuji <okuji@enbug.org>
18660
18661 * kern/partition.c (grub_partition_probe): Initialize PART to
18662 NULL. Otherwise, when no partition map is registered, this returns
18663 a garbage.
18664
b28b81b2 186652005-07-19 Yoshinori K. Okuji <okuji@enbug.org>
18666
18667 * partmap/apple.c (apple_partition_map_iterate): Check if POS
18668 equals GRUB_DISK_SECTOR_SIZE to see if the partition table is
18669 valid.
18670
5f3607e0 186712005-07-18 Yoshinori K. Okuji <okuji@enbug.org>
18672
18673 * commands/ls.c (grub_ls_list_disks): Print the filesystem
18674 information on each device, if it does not have partitions. Print
18675 "Device" instead of "Disk", because this function is not specific
18676 to disk devices.
18677
18678 * normal/main.c (grub_rescue_cmd_normal): Make the variable CONFIG
18679 static to ensure that it is put on the memory rather than a
18680 register.
18681
502c87e8 186822005-07-17 Yoshinori Okuji <okuji@enbug.org>
18683
18684 * commands/cat.c (GRUB_MOD_INIT): Use better documentation.
18685 (grub_cat_init): Likewise.
18686 * loader/i386/pc/chainloader_normal.c (GRUB_MOD_INIT): Likewise.
18687 (options): Likewise.
18688 * commands/configfile.c (GRUB_MOD_INIT): Likewise.
18689 (grub_configfile_init): Likewise.
18690 * font/manager.c (GRUB_MOD_INIT): Likewise.
18691 * commands/help.c (GRUB_MOD_INIT): Likewise.
18692 (grub_help_init): Likewise.
18693 * normal/command.c (grub_command_init): Likewise.
18694 * loader/i386/pc/linux_normal.c (GRUB_MOD_INIT): Likewise.
18695 * disk/loopback.c (grub_loop_init): Likewise.
18696 (GRUB_MOD_INIT): Likewise.
18697 * commands/ls.c (grub_ls_init): Likewise.
18698 (GRUB_MOD_INIT): Likewise.
18699 (options): Likewise.
18700 * commands/boot.c (grub_boot_init): Likewise.
18701 (GRUB_MOD_INIT): Likewise.
18702 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Likewise.
18703 * commands/i386/pc/reboot.c (grub_reboot_init): Likewise.
18704 (GRUB_MOD_INIT): Likewise.
18705 * commands/cmp.c (grub_cmp_init): Likewise.
18706 (GRUB_MOD_INIT): Likewise.
18707
18708 * normal/arg.c: Use <> instead of "" to include header files.
18709 (SHORT_ARG_HELP): New macro.
18710 (SHORT_ARG_USAGE): Likewise.
18711 (help_options): Specify SHORT_ARG_HELP and SHORT_ARG_USAGE instead
18712 of 'h' and 'u' for help and usage, respectively. Use more GNU-like
18713 descriptions.
18714 (find_short): Check if C is 'h' or 'u' explicitly.
18715 (grub_arg_show_help): Use space characters instead of tabs. Treat
18716 SHORT_ARG_HELP and SHORT_ARG_USAGE exceptionally so that -h and -u
18717 are shown with --help and --usage only if they are not used for
18718 the command itself.
18719 (parse_option): Use SHORT_ARG_HELP and SHORT_ARG_USAGE instead of
18720 'h' and 'u'.
18721
18722 * include/grub/arg.h (struct grub_arg_option): Add the qualifier
18723 const into "longarg". Change the type of "shortarg" to int.
18724
f806d18e 187252005-07-17 Yoshinori Okuji <okuji@enbug.org>
18726
18727 * boot/i386/pc/boot.S (boot_drive_check): New label.
18728
18729 * include/grub/i386/pc/boot.h (GRUB_BOOT_MACHINE_DRIVE_CHECK): New
18730 macro.
18731
18732 * util/i386/pc/grub-setup.c (setup): Added a workaround for BIOSes
18733 which do not pass a boot drive correctly. Copied from GRUB Legacy.
18734
e293232b 187352005-07-17 Yoshinori Okuji <okuji@enbug.org>
18736
18737 * kern/i386/pc/startup.S (gate_a20_try_system_control_port_a):
18738 When turning off Gate A20, skip the check and return immediately,
18739 because this is not fatal usually.
18740
ebedfd00 187412005-07-17 Yoshinori Okuji <okuji@enbug.org>
18742
18743 * conf/i386-pc.rmk (pxeboot_img_LDFLAGS): The text address should
18744 be 0x7C00 instead of 0x8000.
18745
18746 * boot/i386/pc/pxeboot.S: Rewritten.
18747
18748 * kern/i386/pc/startup.S (gate_a20_try_bios): No need to specify
18749 EXT_C.
18750 (gate_a20_check_state): Read a byte from 0x108000. Invert the
18751 result.
18752
654fc59f 187532005-07-16 Yoshinori K. Okuji <okuji@enbug.org>
18754
18755 * kern/i386/pc/startup.S (grub_gate_a20): Rewritten for
18756 robustness. This routine now supports a BIOS call and System
18757 Control Port A to modify the gate A20.
18758
18759 * include/grub/i386/pc/kernel.h (GRUB_KERNEL_MACHINE_RAW_SIZE):
18760 Increased to 0x440.
18761
09f9923f 187622005-07-12 Hollis Blanchard <hollis@penguinppc.org>
18763
18764 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): dprintf the
18765 device path and resulting ihandle.
18766 (grub_ofdisk_close): dprintf the ihandle being closed.
18767 (grub_ofdisk_read): dprintf function parameters.
18768 * kern/mm.c (grub_mm_init_region): Likewise.
18769 * loader/powerpc/ieee1275/linux.c: Remove extra whitespace.
18770 (grub_linux_boot): dprintf the Linux entry point, initrd address and
18771 size, and boot arguments.
18772 (grub_rescue_cmd_linux): dprintf each ELF segment's address and size
18773 before loading into memory.
18774 (grub_rescue_cmd_initrd): dprintf the initrd's address and size
18775 before loading into memory.
18776
7ef504d8 187772005-07-12 Yoshinori K. Okuji <okuji@enbug.org>
18778
18779 * kern/mm.c: Added much documentation.
18780 (GRUB_MM_ALIGN_LOG2): When GRUB_CPU_SIZEOF_VOID_P is
18781 8, set to 5 instead of 8.
18782
e0f050c2 187832005-07-10 Yoshinori Okuji <okuji@enbug.org>
18784
18785 * DISTLIST: Added util/i386/pc/grub-mkimage.c.
18786
18787 * conf/i386-pc.rmk (sbin_UTILITIES): Added grub-mkdevicemap.
18788 (grub_mkdevicemap_SOURCES): New variable.
18789
18790 * util/i386/pc/grub-mkdevicemap.c: New file. Mostly copied from
18791 lib/device.c of GRUB Legacy.
18792
7224189a 187932005-07-10 Yoshinori Okuji <okuji@enbug.org>
18794
18795 * commands/ls.c (grub_ls_list_files): Check if *PATH is NUL
18796 instead of PATH is NULL.
18797
68c864eb 187982005-07-09 Vincent Pelletier <subdino2004@yahoo.fr>
18799
18800 * commands/cmp.c (BUFFER_SIZE): New macro.
18801 (grub_cmd_cmp): Close the right file at the right time. Compare
18802 only data just read. Don't report files of different size as
18803 identical. Dynamically allocate buffers. Move variable
18804 declarations at the beginning of function.
18805
e6f3e614 188062005-07-09 Yoshinori Okuji <okuji@enbug.org>
18807
18808 * aclocal.m4 (grub_I386_CHECK_REGPARM_BUG): The return value was
18809 reverse.
18810
f8f1559a 188112004-07-04 Vincent Pelletier <subdino2004@yahoo.fr>
18812
18813 * normal/cmdline.c (grub_cmdline_get): Don't fallback on ctrl-d
18814 when backspace is pressed at beginning of line.
18815
39c9d41d 188162005-07-03 Yoshinori Okuji <okuji@enbug.org>
18817
18818 * DISTLIST: Added genfslist.sh.
18819
18820 * normal/main.c (fs_module_list): New variable.
18821 (autoload_fs_module): New function.
18822 (read_fs_list): Likewise.
18823 (grub_normal_execute): Call read_fs_list.
18824
18825 * kern/fs.c (grub_fs_autoload_hook): New variable.
18826 (grub_fs_probe): Added support for auto-loading.
18827
18828 * include/grub/normal.h (struct grub_fs_module_list): New struct.
18829 (grub_fs_module_list_t): New type.
18830
18831 * include/grub/fs.h (grub_fs_autoload_hook_t): New type.
18832 (grub_fs_autoload_hook): New prototype.
18833
18834 * genfslist.sh: New file.
f19dbdb7 18835
39c9d41d 18836 * genmk.rb: Added a rule to generate a filesystem list.
18837
121c1d83 188382005-06-30 Marco Gerards <metgerards@student.han.nl>
18839
18840 * configure.ac: Fix the test for cross-compiling.
18841
18842 * genmk.rb (Program): Use `$(CC)' instead of `$(BUILD_CC)'. Don't
18843 define GRUB_UTIL anymore.
18844
18845 * util/powerpc/ieee1275/grub-mkimage.c (load_note): Endian fixes
18846 so this function works on other systems than just big endian.
18847 (load_modules): Likewise.
18848 (add_segments): Likewise.
18849
e75d76e1 188502005-06-23 Hollis Blanchard <hollis@penguinppc.org>
18851
18852 * kern/misc.c (grub_vsprintf): Add `longfmt'. If format string
18853 contains `l' modifier, get a long from va_arg().
18854
50b5a0a7 188552005-06-23 Yoshinori K. Okuji <okuji@enbug.org>
18856
18857 * kern/mm.c (grub_free): If the next free block which is being
18858 merged is the first free block, set the first block to the block
18859 being freed.
18860 Reported by Vincent Guffens <guffens@inma.ucl.ac.be>.
18861
89371b20 188622005-05-08 Hollis Blanchard <hollis@penguinppc.org>
18863
18864 * boot/powerpc/ieee1275/cmain.c (cmain): Initialize
18865 `grub_ieee1275_chosen'.
18866
168d6e58 188672005-05-08 Hollis Blanchard <hollis@penguinppc.org>
18868
18869 * boot/powerpc/ieee1275/cmain.c (module_info): Remove definition.
18870 (grub_ieee1275_chosen): New variable.
18871 (cmain): Initialize and use `grub_ieee1275_chosen' instead of
18872 `chosen'.
18873 * boot/powerpc/ieee1275/crt0.S (init_stack): Remove stack space.
18874 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
18875 Rename first argument to `phandle' for consistency.
18876 (grub_ieee1275_get_property_length): Likewise.
18877 (grub_ieee1275_next_property): Likewise. Change type of first argument
18878 to grub_ieee1275_phandle_t.
18879 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_entry_fn):
18880 Move export next to declaration.
18881 (grub_ieee1275_chosen): New variable.
18882 * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MODULE_BASE):
18883 Correct cosmetic typo.
18884 * kern/powerpc/ieee1275/init.c (grub_set_prefix): Use
18885 `grub_ieee1275_chosen'.
18886 * kern/powerpc/ieee1275/openfw.c (grub_map): Likewise.
18887 * loader/powerpc/ieee1275/linux.c (grub_linux_boot): Likewise.
18888 (grub_rescue_cmd_linux): Set `initrd_addr' to 0.
18889 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_refresh): Use
18890 `grub_ieee1275_chosen'.
18891
ca5baa3f 188922005-05-10 Hollis Blanchard <hollis@penguinppc.org>
18893
18894 * boot/powerpc/ieee1275/cmain.c (cmain): Remove code to parse
18895 /chosen/bootargs.
18896 * kern/powerpc/ieee1275/init.c (grub_machine_init): Parse
18897 /chosen/bootargs as "variable=value" pairs.
18898
708b345f 188992005-05-08 Vincent Pelletier <subdino2004@yahoo.fr>
18900
18901 * include/grub/misc.h (grub_dprintf): New macro.
18902 (grub_real_dprintf): New prototype.
18903 (grub_strword): Likewise.
18904 (grub_iswordseparator): Likewise.
18905 * kern/misc.c (grub_real_dprintf): New function.
18906 (grub_strword): Likewise.
18907 (grub_iswordseparator): Likewise.
18908
f4c5e67c 189092005-04-30 Hollis Blanchard <hollis@penguinppc.org>
18910
18911 * boot/powerpc/ieee1275/cmain.c: Don't include grub/machine/init.h.
18912 (roundup): Remove macro.
18913 (grub_ieee1275_flags): Make static.
18914 (grub_ieee1275_realmode): Remove.
18915 (grub_ieee1275_test_flag): New function.
18916 (grub_ieee1275_set_flag): Likewise.
18917 (find_options): Rename to `grub_ieee1275_find_options'; update
18918 callers. Set GRUB_IEEE1275_FLAG_REAL_MODE and
18919 GRUB_IEEE1275_FLAG_0_BASED_PARTITIONS.
18920 (cmain): New prototype.
18921 (cmain): Use `grub_ieee1275_set_flag' instead of accessing
18922 `grub_ieee1275_flags' directly.
18923 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Remove
18924 machine/biosdisk.h.
18925 * disk/powerpc/ieee1275/ofdisk.c: Include grub/machine/ofdisk.h.
18926 Don't include grub/machine/init.h.
18927 (grub_ofdisk_open): Call `grub_ieee1275_test_flag'.
18928 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
18929 Remove prototype.
18930 (grub_ieee1275_realmode): Likewise.
18931 (grub_ieee1275_flag): New enum.
18932 (grub_ieee1275_test_flag): New prototype.
18933 (grub_ieee1275_set_flag): New prototype.
18934 * include/grub/powerpc/ieee1275/init.h: Remove file.
18935 * include/grub/powerpc/ieee1275/ofdisk.h: New file.
18936 * kern/powerpc/ieee1275/init.c: Don't include grub/machine/init.h.
18937 Include grub/machine/console.h. Include grub/machine/ofdisk.h.
18938 (grub_machine_fini): Don't call `grub_ieee1275_release'. Remove
18939 comment.
18940 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Call
18941 `grub_ieee1275_test_flag'.
18942 (grub_ieee1275_encode_devname): Likewise.
18943
ed16607e 189442005-04-21 Hollis Blanchard <hollis@penguinppc.org>
18945
18946 * include/grub/powerpc/ieee1275/ieee1275.h
18947 (grub_ieee1275_encode_devname): New prototype.
18948 (grub_ieee1275_get_filename): Likewise.
18949 * kern/powerpc/ieee1275/init.c (grub_translate_ieee175_path): New
18950 function.
18951 (grub_set_prefix): Likewise.
18952 (grub_machine_init): Call grub_set_prefix.
18953 * kern/powerpc/ieee1275/openfw.c: Fix typos.
18954 (grub_parse_type): New enum.
18955 (grub_ieee1275_get_devargs): New function.
18956 (grub_ieee1275_get_devname): Likewise.
18957 (grub_ieee1275_parse_args): Likewise.
18958 (grub_ieee1275_get_filename): Likewise.
18959 (grub_ieee1275_encode_devname): Likewise.
18960
be369920 189612005-03-30 Marco Gerards <metgerards@student.han.nl>
18962
18963 * kern/powerpc/ieee1275/init.c (grub_machine_fini): Don't call
18964 `grub_loader_unset'.
18965
a5ce3a4a 189662005-03-26 Hollis Blanchard <hollis@penguinppc.org>
18967
18968 * commands/ieee1275/halt.c (grub_cmd_halt): Call grub_halt
18969 instead of grub_ieee1275_interpret.
18970 (grub_halt_init): New function.
18971 (grub_halt_fini): Likewise.
18972 (GRUB_MOD_INIT): Correct message grammar.
18973 * commands/ieee1275/reboot.c (grub_cmd_reboot): Call grub_reboot
18974 instead of grub_ieee1275_interpret.
18975 (grub_reboot_init): New function.
18976 (grub_reboot_fini): Likewise.
18977 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Replace
18978 commands/i386/pc/halt.c, commands/i386/pc/reboot.c, and
18979 util/i386/pc/misc.c with commands/ieee1275/halt.c,
18980 commands/ieee1275/reboot.c, and util/powerpc/ieee1275/misc.c.
18981 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_fini): New
18982 function.
18983 * include/grub/powerpc/ieee1275/console.h (grub_console_fini):
18984 Add prototype.
18985 * include/grub/powerpc/ieee1275/ieee1275.h (grub_reboot): Add
18986 prototype.
18987 (grub_halt): Likewise.
18988 * include/grub/powerpc/ieee1275/init.h: Remove inaccurate comment.
18989 (cmain): Remove __attribute__((unused)).
18990 * kern/powerpc/ieee1275/init.c (grub_heap_start): New variable.
18991 (grub_heap_len): Likewise.
18992 (grub_machine_fini): New function.
18993 * kern/powerpc/ieee1275/openfw.c (grub_reboot): New function.
18994 (grub_halt): Likewise.
18995 * term/powerpc/ieee1275/ofconsole.c (grub_console_fini): New
18996 function.
18997 * util/powerpc/ieee1275/misc.c: New file.
18998
0058f771 189992005-03-19 Yoshinori K. Okuji <okuji@enbug.org>
19000
19001 * DISTLIST: New file.
19002 * gendistlist.sh: Likewise.
f19dbdb7 19003
0058f771 19004 * Makefile.in (COMMON_DISTFILES): Removed.
19005 (BOOT_DISTFILES): Likewise.
19006 (CONF_DISTFILES): Likewise.
19007 (DISK_DISTFILES): Likewise.
19008 (FS_DISTFILES): Likewise.
19009 (INCLUDE_DISTFILES): Likewise.
19010 (KERN_DISTFILES): Likewise.
19011 (LOADER_DISTFILES): Likewise.
19012 (TERM_DISTFILES): Likewise.
19013 (UTIL_DISTFILES): Likewise.
19014 (DISTFILES): Likewise.
19015 (uninstall): Uninstall files in $(pkgdata_DATA).
19016 (DISTLIST): New target.
19017 (distdir): Use the contents of the file DISTLIST to get a list of
19018 distributed files.
19019
46b3b8a5 190202005-03-18 Yoshinori K. Okuji <okuji@enbug.org>
19021
19022 * fs/fat.c (grub_fat_mount): Ignore the 3rd bit of a media
19023 descriptor. This is ported from GRUB Legacy.
19024
19025 * gencmdlist.sh: Added an extra semicolon to make it work with
19026 old sed versions. Reported by Robert Bihlmeyer
19027 <robbe@orcus.priv.at>.
19028
5822ff87 190292005-03-08 Yoshinori Okuji <okuji@enbug.org>
19030
19031 Automatic loading of commands is supported.
f19dbdb7 19032
5822ff87 19033 * normal/main.c (read_command_list): New function.
19034 (grub_normal_execute): Call read_command_list.
19035
19036 * normal/command.c (grub_register_command): Return zero or CMD.
19037 Allocate CMD->NAME from the heap.
19038 Initialize CMD->MODULE_NAME to zero.
19039 Find the same name as well. If the same command is found and it is
19040 a dummy command, overwrite members. If it is not a dummy command,
19041 return zero.
19042 (grub_unregister_command): Free Q->NAME and Q->MODULE_NAME.
19043 (grub_command_find): If a dummy command is found, load a module
19044 and retry to find a command only once.
19045
19046 * normal/cmdline.c (grub_tab_complete): Call grub_command_find to
19047 make sure that each command is loaded.
19048
19049 * include/grub/normal.h (GRUB_COMMAND_FLAG_NOT_LOADED): New
19050 macro.
19051 (struct grub_command): Remove const from the member `name'.
19052 Add a new member `module_name'.
19053 (grub_register_command): Return grub_command_t.
19054
19055 * commands/help.c (grub_cmd_help): Call grub_command_find to make
19056 sure that each command is loaded.
19057
19058 * genmk.rb (PModule::rule): Specify a module name without the
19059 suffix ".mod" to gencmdlist.sh.
19060
7b1f4b57 190612005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
19062
19063 * gencmdlist.sh: New file.
f19dbdb7 19064
7b1f4b57 19065 * genmk.rb (PModule::rule): Generate a rule for a command list.
19066 Clean command.lst.
19067 Generate command.lst from $(COMMANDFILES).
19068
19069 * Makefile.in (COMMON_DISTFILES): Added gencmdlist.sh.
19070 (DATA): Added $(pkgdata_DATA).
19071 (install-local): Install files in $(pkgdata_DATA).
19072
062aaf39 190732005-03-02 Yoshinori K. Okuji <okuji@enbug.org>
19074
19075 * term/i386/pc/vga.c (debug_command): Removed.
19076 (GRUB_MOD_INIT): Do not register the command "debug".
19077
19078 From Hollis Blanchard:
19079 * commands/configfile.c: New file.
19080 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
19081 commands/configfile.c.
19082 (pkgdata_MODULES): Added configfile.mod.
19083 (configfile_mod_SOURCES): New variable.
19084 (configfile_mod_CFLAGS): Likewise.
19085 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Added
19086 commands/configfile.c.
19087 (pkgdata_MODULES): Added configfile.mod.
19088 (configfile_mod_SOURCES): New variable.
19089 (configfile_mod_CFLAGS): Likewise.
19090 * util/grub-emu.c (main): Call grub_configfile_init and
19091 grub_configfile_fini.
19092 * include/grub/normal.h [GRUB_UTIL] (grub_configfile_init): New
19093 prototype.
19094 [GRUB_UTIL] (grub_configfile_fini): Likewise.
f19dbdb7 19095
cee01aa6 190962005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
19097
19098 * normal/arg.c (grub_arg_show_help): Do not show the bug report
19099 address.
19100
19101 * commands/help.c (grub_cmd_help): Do not print newlines after
19102 the last command in print_command_help.
19103
93f3a1d8 191042005-02-27 Yoshinori K. Okuji <okuji@enbug.org>
19105
19106 * commands/default.h: New file.
19107 * commands/timeout.h: Likewise.
19108 * normal/context.c: Likewise.
f19dbdb7 19109
93f3a1d8 19110 * util/misc.c: Do not include sys/times.h.
19111 Include sys/time.h and grub/machine/time.h.
19112 (grub_get_rtc): Rewritten with gettimeofday.
19113
19114 * util/grub-emu.c (main): Call grub_default_init and
19115 grub_timeout_init before grub_normal_init, and call
19116 grub_timeout_fini and grub_default_fini after grub_main.
19117
19118 * util/console.c (grub_ncurses_checkkey): Return the read
19119 character or -1.
19120
19121 * normal/menu.c (run_menu): Set MENU->TIMEOUT to -1 once it
19122 timeouts.
19123
19124 * normal/main.c (read_config_file): Push MENU. If this fails,
19125 print an error and wait for a user input.
19126 Print an error only if GRUB_ERRNO is not GRUB_ERR_NONE.
19127 If a menu is empty or an error occurs, pop MENU.
19128 (grub_normal_execute): Pop and free MENU after grub_menu_run
19129 returns.
19130
19131 * kern/loader.c (grub_loader_boot): Call grub_machine_fini.
19132
19133 * include/grub/powerpc/ieee1275/time.h [GRUB_UTIL]: Do not
19134 include time.h.
19135 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
19136 without GRUB_UTIL.
19137 * include/grub/i386/pc/time.h [GRUB_UTIL]: Do not include
19138 time.h.
19139 [GRUB_UTIL] (GRUB_TICKS_PER_SECOND): Use the same definition as
19140 without GRUB_UTIL.
19141
19142 * include/grub/normal.h (struct grub_menu_list): New struct.
19143 (grub_menu_list_t): New type.
19144 (struct grub_context): New struct.
19145 (grub_context_t): New type.
19146 (grub_register_command): Got rid of EXPORT_FUNC.
19147 (grub_unregister_command): Likewise.
19148 (grub_context_get): New prototype.
19149 (grub_context_get_current_menu): Likewise.
19150 (grub_context_push_menu): Likewise.
19151 (grub_context_pop_menu): Likewise.
19152 [GRUB_UTIL] (grub_default_init): Likewise.
19153 [GRUB_UTIL] (grub_default_fini): Likewise.
19154 [GRUB_UTIL] (grub_timeout_init): Likewise.
19155 [GRUB_UTIL] (grub_timeout_fini): Likewise.
19156
19157 * conf/i386-pc.rmk (grub_emu_SOURCES): Added commands/default.c,
19158 commands/timeout.c and normal/context.c.
19159 (pkgdata_MODULES): Added default.mod and timeout.mod.
19160 (normal_mod_SOURCES): Added normal/context.c.
19161 (default_mod_SOURCES): New variable.
19162 (default_mod_CFLAGS): Likewise.
19163 (timeout_mod_SOURCES): Likewise.
19164 (timeout_mod_CFLAGS): Likewise.
19165 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Copied from
19166 conf/i386-pc.rmk.
19167 (pkgdata_MODULES): Added default.mod and timeout.mod.
19168 (normal_mod_SOURCES): Added normal/context.c.
19169 (default_mod_SOURCES): New variable.
19170 (default_mod_CFLAGS): Likewise.
19171 (timeout_mod_SOURCES): Likewise.
19172 (timeout_mod_CFLAGS): Likewise.
19173
19174 * Makefile.in (all-local): Added $(MKFILES).
19175
4ed2e1dd 191762005-02-21 Vincent Pelletier <subdino2004@yahoo.fr>
19177
19178 * conf/i386-pc.rmk (grub_setup_SOURCES): Add `partmap/sun.c'.
19179 (grub_emu_SOURCES): Likewise.
19180 (pkgdata_MODULES): Add `sun.mod'.
19181 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
19182 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
19183 `partmap/sun.c'.
19184 (pkgdata_MODULES): Add `sun.mod'.
19185 (sun_mod_SOURCES, sun_mod_CFLAGS): New variables.
19186 * include/grub/partition.h (grub_sun_partition_map_init): New
19187 prototype.
19188 (grub_sun_partition_map_fini): Likewise.
19189 * partmap/sun.c: New file.
19190 * util/grub-emu.c (main): Initialize and de-initialize the sun
19191 partitionmap support.
19192
4d4e372e 191932005-02-19 Yoshinori K. Okuji <okuji@enbug.org>
19194
19195 This implements an Emacs-like menu entry editor.
f19dbdb7 19196
4d4e372e 19197 * normal/menu_entry.c: New file.
f19dbdb7 19198
4d4e372e 19199 * util/console.c (grub_ncurses_putchar): Translate some Unicode
19200 characters to ASCII.
19201 (saved_char): New variable.
19202 (grub_ncurses_checkkey): Rewritten completely.
19203 (grub_ncurses_getkey): Likewise.
19204 (grub_ncurses_init): Call raw instead of cbreak.
19205
19206 * normal/menu.c (print_entry): Do not put a space.
19207 (init_page): Renamed to ...
19208 (grub_menu_init_page): ... this. All callers changed.
19209 (edit_menu_entry): Removed.
19210 (run_menu): Call grub_menu_entry_run instead of edit_menu_entry.
19211
19212 * normal/cmdline.c (grub_cmdline_run): Call grub_setcursor.
19213
19214 * kern/misc.c (grub_vprintf): Call grub_refresh.
19215
19216 * normal/menu.c (DISP_LEFT): Renamed to ...
19217 * include/grub/term.h (GRUB_TERM_DISP_LEFT): ... this.
19218 * normal/menu.c (DISP_UP): Renamed to ...
19219 * include/grub/term.h (GRUB_TERM_DISP_UP): ... this.
19220 * normal/menu.c (DISP_RIGHT): Renamed to ...
19221 * include/grub/term.h (GRUB_TERM_DISP_RIGHT): ... this.
19222 * normal/menu.c (DISP_DOWN): Renamed to ...
19223 * include/grub/term.h (GRUB_TERM_DISP_DOWN): ... this.
19224 * normal/menu.c (DISP_HLINE): Renamed to ...
19225 * include/grub/term.h (GRUB_TERM_DISP_HLINE): ... this.
19226 * normal/menu.c (DISP_VLINE): Renamed to ...
19227 * include/grub/term.h (GRUB_TERM_DISP_VLINE): ... this.
19228 * normal/menu.c (DISP_UL): Renamed to ...
19229 * include/grub/term.h (GRUB_TERM_DISP_UL): ... this.
19230 * normal/menu.c (DISP_UR): Renamed to ...
19231 * include/grub/term.h (GRUB_TERM_DISP_UR): ... this.
19232 * normal/menu.c (DISP_LL): Renamed to ...
19233 * include/grub/term.h (GRUB_TERM_DISP_LL): ... this.
19234 * normal/menu.c (DISP_LR): Renamed to ...
19235 * include/grub/term.h (GRUB_TERM_DISP_LR): ... this.
19236 * normal/menu.c (TERM_WIDTH): Renamed to ...
19237 * include/grub/term.h (GRUB_TERM_WIDTH): ... this.
19238 * normal/menu.c (TERM_HEIGHT): Renamed to ...
19239 * include/grub/term.h (GRUB_TERM_HEIGHT): ... this.
19240 * normal/menu.c (TERM_INFO_HEIGHT): Renamed to ...
19241 * include/grub/term.h (GRUB_TERM_INFO_HEIGHT): ... this.
19242 * normal/menu.c (TERM_MARGIN): Renamed to ...
19243 * include/grub/term.h (GRUB_TERM_MARGIN): ... this.
19244 * normal/menu.c (TERM_SCROLL_WIDTH): Renamed to ...
19245 * include/grub/term.h (GRUB_TERM_SCROLL_WIDTH): ... this.
19246 * normal/menu.c (TERM_TOP_BORDER_Y): Renamed to ...
19247 * include/grub/term.h (GRUB_TERM_TOP_BORDER_Y): ... this.
19248 * normal/menu.c (TERM_LEFT_BORDER_X): Renamed to ...
19249 * include/grub/term.h (GRUB_TERM_LEFT_BORDER_X): ... this.
19250 * normal/menu.c (TERM_BORDER_WIDTH): Renamed to ...
19251 * include/grub/term.h (GRUB_TERM_BORDER_WIDTH): ... this.
19252 * normal/menu.c (TERM_MESSAGE_HEIGHT): Renamed to ...
19253 * include/grub/term.h (GRUB_TERM_MESSAGE_HEIGHT): ... this.
19254 * normal/menu.c (TERM_BORDER_HEIGHT): Renamed to ...
19255 * include/grub/term.h (GRUB_TERM_BORDER_HEIGHT): ... this.
19256 * normal/menu.c (TERM_NUM_ENTRIES): Renamed to ...
19257 * include/grub/term.h (GRUB_TERM_NUM_ENTRIES): ... this.
19258 * normal/menu.c (TERM_FIRST_ENTRY_Y): Renamed to ...
19259 * include/grub/term.h (GRUB_TERM_FIRST_ENTRY_Y): ... this.
19260 * normal/menu.c (TERM_ENTRY_WIDTH): Renamed to ...
19261 * include/grub/term.h (GRUB_TERM_ENTRY_WIDTH): ... this.
19262 * normal/menu.c (TERM_CURSOR_X): Renamed to ...
19263 * include/grub/term.h (GRUB_TERM_CURSOR_X): ... this.
19264 All callers changed.
19265
19266 * include/grub/normal.h: New prototype.
19267
19268 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
19269 normal/menu_entry.c.
19270 (normal_mod_SOURCES): Likewise.
19271 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Likewise.
19272 (normal_mod_SOURCES): Likewise.
19273
e6b92c8a 192742005-02-15 Yoshinori K. Okuji <okuji@enbug.org>
19275
19276 * include/grub/normal.h (grub_halt_init): New prototype.
19277 (grub_halt_fini): Likewise.
19278 (grub_reboot_init): Likewise.
19279 (grub_reboot_fini): Likewise.
19280
19281 * util/grub-emu.c: Include signal.h.
19282 (main_env): New global variable.
19283 (grub_machine_init): Ignore SIGINT. Otherwise grub-emu cannot
19284 catch C-c.
19285 (grub_machine_fini): New function.
19286 (main): Call grub_halt_init and grub_reboot_init before
19287 grub_main, and grub_reboot_fini and grub_halt_fini after it.
19288 Call setjmp with MAIN_ENV to go back afterwards.
19289 Call grub_machine_fini right before return.
19290
19291 * include/grub/util/misc.h: Include setjmp.h.
19292 (main_env): New prototype.
19293
19294 * include/grub/kernel.h (grub_machine_fini): New prototype.
19295 * include/grub/i386/pc/biosdisk.h (grub_biosdisk_fini): Likewise.
19296 * include/grub/i386/pc/console.h (grub_console_fini): Likewise.
19297
19298 * disk/i386/pc/biosdisk.c (grub_biosdisk_fini): New function.
19299 * kern/i386/pc/init.c (grub_machine_fini): Likewise.
19300 * term/i386/pc/console.c (grub_console_fini): Likewise.
f19dbdb7 19301
e6b92c8a 19302 * util/i386/pc/misc.c: New file.
f19dbdb7 19303
e6b92c8a 19304 * conf/i386-pc.rmk (grub_emu_SOURCES): Added
19305 util/i386/pc/misc.c, commands/i386/pc/halt.c and
19306 commands/i386/pc/reboot.c.
19307
c642636f 193082005-02-14 Guillem Jover <guillem@hadrons.org>
19309
19310 * include/grub/dl.h (grub_dl_check_header): New prototype.
19311 (grub_arch_dl_check_header): Change return type to grub_err_t,
19312 remove size parameter and export function. Update all callers.
19313 * kern/dl.c (grub_dl_check_header): New function.
19314 (grub_dl_load_core): Use `grub_dl_check_header' instead of
19315 `grub_arch_dl_check_header'. Check ELF type. Check if sections
19316 are inside the core.
19317 * kern/i386/dl.c (grub_arch_dl_check_header): Remove arch
19318 independent ELF header checks.
19319 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
19320 * loader/i386/pc/multiboot.c (grub_rescue_cmd_multiboot): Use
19321 `grub_dl_check_header' instead of explicit checks. Check for the
19322 ELF type.
19323 * loader/powerpc/ieee1275/linux.c (grub_rescue_cmd_linux): Use
19324 `grub_dl_check_header' instead of explicit checks. Remove arch
19325 specific ELF header checks.
19326
e6b92c8a 19327 * util/grub-emu.c (grub_arch_dl_check_header): Remove the
19328 argument SIZE.
19329
5eabe94b 193302005-02-13 Hollis Blanchard <hollis@penguinppc.org>
19331
19332 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add ls.mod.
19333 * include/grub/powerpc/libgcc.h (__mulsf3): New prototype.
19334
1b14a681 193352005-02-12 Hollis Blanchard <hollis@penguinppc.org>
19336
19337 * kern/partition.c (grub_partition_probe): Clear `grub_errno' and
f19dbdb7 19338 return 0 if `grub_errno' is GRUB_ERR_BAD_PART_TABLE.
1b14a681 19339 (part_map_iterate): Clear `grub_errno' and return 0 if
f19dbdb7 19340 `partmap->iterate' returns GRUB_ERR_BAD_PART_TABLE.
1b14a681 19341 * partmap/amiga.c (amiga_partition_map_iterate): Return
19342 GRUB_ERR_BAD_PART_TABLE if no partition map magic is found.
19343 * partmap/apple.c (apple_partition_map_iterate): Likewise.
19344
aca108aa 193452005-02-01 Guillem Jover <guillem@hadrons.org>
19346
19347 * loader/i386/pc/multiboot_normal.c (GRUB_MOD_INIT): Fix module
19348 help info.
19349
c9f9c556 193502005-01-31 Marco Gerards <metgerards@student.han.nl>
19351
19352 * include/grub/powerpc/ieee1275/loader.h (grub_load_linux):
19353 Removed prototype.
19354 (grub_rescue_cmd_linux): New prototype.
19355 (grub_rescue_cmd_initrd): Likewise.
19356 * powerpc/ieee1275/linux.c (grub_linux_boot): Remove struct
19357 `bi_rec'.
19358 (grub_linux_release_mem): Release the memory for the initrd.
19359 (grub_load_linux): Renamed from this...
19360 (grub_rescue_cmd_linux): ...To this. Changed all callers.
19361 Changed `entry' not to be static. Loop over memory regions to
19362 find another one when the default fails.
19363 (grub_rescue_cmd_initrd): New function.
19364 (grub_linux_init): Remove function.
19365 (grub_linux_fini): Likewise.
19366 (GRUB_MOD_INIT): Register `initrd'.
19367 (GRUB_MOD_FINI): Unregister `initrd'.
19368 * powerpc/ieee1275/linux_normal.c (grub_linux_normal_init):
19369 Function removed.
19370 (grub_linux_normal_fini): Likewise.
19371 (GRUB_MOD_INIT): Register `initrd'.
19372 (GRUB_MOD_FINI): Unregister `initrd'.
19373
990cf3aa 193742005-01-31 Marco Gerards <metgerards@student.han.nl>
19375
19376 * commands/help.c: New file.
19377 * normal/arg.c (show_help): Renamed to...
19378 (grub_arg_show_help): ... this.
19379 * commands/i386/pc/halt.c: New file.
19380 * commands/i386/pc/reboot.c: Likewise.
19381 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `commands/help.c'.
19382 (pkgdata_MODULES): Add `reboot.mod', `halt.mod' and `help.mod'.
19383 (help_mod_SOURCES, help_mod_CFLAGS, reboot_mod_SOURCES)
19384 (reboot_mod_CFLAGS, halt_mod_SOURCES, halt_mod_CFLAGS): New
19385 variables.
19386 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
19387 `commands/help.c'.
19388 (pkgdata_MODULES): Add `help.mod'.
19389 (help_mod_SOURCES, help_mod_CFLAGS): New variables.
19390 * grub/i386/pc/init.h (grub_reboot): New prototype.
19391 (grub_halt): Likewise.
19392 * include/grub/normal.h (grub_arg_show_help): New prototype.
19393 (grub_help_init): Likewise.
19394 (grub_help_fini): Likewise.
19395 * util/grub-emu.c (main): Initialize and deinitialize the help
19396 command.
19397
19398 * normal/cmdline.c (grub_cmdline_get): Doc fix.
19399
19400 * normal/command.c (grub_command_init): Fixed the description of
19401 the `set' and `unset' commands.
19402
194032005-01-31 Marco Gerards <metgerards@student.han.nl>
0f79cdc1 19404
19405 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_interpret): New
19406 function.
19407 * commands/ieee1275/halt.c: New file.
19408 * commands/ieee1275/reboot.c: Likewise.
19409 * commands/ieee1275/suspend.c (grub_cmd_suspend): Use
19410 `__attribute__ ((unused))'. Some GCS related fixed.
19411 (grub_suspend_init) [GRUB_UTIL]: Function removed.
19412 (grub_suspend_fini): Likewise.
19413 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add `reboot.mod'
19414 and `halt.mod'.
19415 (reboot_mod_SOURCES, reboot_mod_CFLAGS, halt_mod_SOURCES)
19416 (halt_mod_CFLAGS): New variables.
19417 * include/grub/powerpc/ieee1275/ieee1275.h
19418 (grub_ieee1275_interpret): New prototype.
19419
1ab09cc7 194202005-01-29 Yoshinori K. Okuji <okuji@enbug.org>
19421
19422 * include/grub/misc.h (memmove): New prototype.
19423 (memcpy): Likewise.
19424
8b8cbdb2 194252005-01-22 Hollis Blanchard <hollis@penguinppc.org>
19426
19427 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Don't initialize
19428 `devpath' to 0. Use `name' instead of `devpath' with `grub_strndup'.
19429
e3741a27 194302005-01-22 Marco Gerards <metgerards@student.han.nl>
19431
19432 * kern/misc.c (grub_strndup): Function rewritten.
19433
776bd780 194342005-01-22 Vincent Pelletier <subdino2004@yahoo.fr>
19435
19436 * normal/menu.c (TERM_WIDTH): Macro redefined.
19437 (TERM_TOP_BORDER_Y): Likewise.
19438 (draw_border): Replaced while-loop by a for-loop. Make the number
19439 of lines consistent with the number of lines displayed in
19440 print_entries. Added a margin below the rectangle.
19441 (print_entry): Make the entry fit in the rectangle.
19442 (print_entries): Display the scroll arrows next to the right
19443 border.
19444
78026bce 194452005-01-21 Marco Gerards <metgerards@student.han.nl>
19446
19447 * fs/minix.c (grub_minix_find_file): Reserve more space for
19448 `fpath' so the \0 can be stored. Use `grub_strcpy' instead of
19449 `grub_strncpy' to copy `path' into it.
19450
67bbaf0f 194512005-01-21 Marco Gerards <metgerards@student.han.nl>
19452
19453 Add the loopback device, a device via which files can be accessed
19454 as devices.
f19dbdb7 19455
67bbaf0f 19456 * conf/i386-pc.rmk (grub_emu_SOURCES): Add `disk/loopback.c'.
19457 (pkgdata_MODULES): Add loopback.mod.
19458 (loopback_mod_SOURCES): New variable.
19459 (loopback_mod_CFLAGS): Likewise.
19460 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add
19461 `disk/loopback.c'.
19462 (pkgdata_MODULES): Add loopback.mod.
19463 (loopback_mod_SOURCES): New variable.
19464 (loopback_mod_CFLAGS): Likewise.
19465 * disk/loopback.c: new file.
19466 * include/grub/normal.h (grub_loop_init): New prototype.
19467 (grub_loop_fini): New prototype.
19468 * util/grub-emu.c (main): Initialize and de-initialize loopback
19469 support.
19470 * include/grub/disk.h (grub_disk_dev_id): Add
19471 `GRUB_DISK_DEVICE_LOOPBACK_ID'.
19472
6f1c18bd 194732005-01-20 Hollis Blanchard <hollis@penguinppc.org>
19474
19475 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_enter): New
19476 function.
19477 * conf/powerpc-ieee1275.rmk (pkgdata_MODULES): Add suspend.mod.
19478 (suspend_mod_SOURCES): New variable.
19479 (suspend_mod_CFLAGS): Likewise.
19480 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_enter):
19481 New prototype.
19482 * commands/ieee1275/suspend.c: New file.
19483
b38551da 194842005-01-20 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk>
19485
19486 * include/grub/dl.h (GRUB_MOD_INIT): Changed `__attribute__
f19dbdb7 19487 ((unused))' to `__attribute__ ((used))'.
b38551da 19488 (GRUB_MOD_FINI): Likewise.
19489 * kern/dl.c (grub_dl_load_file): Fix null pointer dereference.
19490 * genmk.rb (PModule): Assign space to common symbols when linking
19491 modules.
19492
777aff39 194932005-01-20 Marco Gerards <metgerards@student.han.nl>
19494
19495 * include/grub/mm.h (grub_mm_init_region): Change the type of the
19496 `unsigned' arguments to `grub_size_t'.
19497 (grub_malloc): Likewise.
19498 (grub_realloc): Likewise.
19499 (grub_memalign): Likewise.
19500 * kern/i386/dl.c (grub_arch_dl_check_header): Likewise.
19501 * kern/powerpc/dl.c (grub_arch_dl_check_header): Likewise.
19502 * util/misc.c (grub_malloc): Likewise.
19503 (grub_realloc): Likewise.
19504 * kern/mm.c (get_header_from_pointer): Change the casts to
19505 `unsigned' into a cast to `grub_size_t'.
19506
19507 * fs/fshelp.c (grub_fshelp_find_file): The `oldnode' should always
19508 point to `currnode' when `currnode' is changed.
19509
19510 * util/grub-emu.c (main): Initialize `progname'. Reported by Nico
19511 Schottelius <nico-linux@schottelius.org>.
19512
d0ff18e1 195132005-01-09 Hollis Blanchard <hollis@penguinppc.org>
19514
19515 * util/powerpc/ieee1275/grub-mkimage.c: Include <string.h>.
19516 (note_path): Remove variable.
19517 (GRUB_IEEE1275_NOTE_NAME): New macro.
19518 (GRUB_IEEE1275_NOTE_TYPE): Likewise.
19519 (grub_ieee1275_note_hdr): New structure.
19520 (grub_ieee1275_note_desc): Likewise.
19521 (grub_ieee1275_note): Likewise.
19522 (load_note): Remove `dir' argument. All callers updated. Remove
19523 `note_img' and `path'. Do not load a file from `note_path'.
19524 Initialize a struct grub_ieee1275_note and write that to `out'.
19525 Use GRUB_IEEE1275_MODULE_BASE instead of MODULE_BASE.
19526
4ca7004c 195272005-01-05 Marco Gerards <metgerards@student.han.nl>
19528
19529 * util/misc.c (grub_util_read_image): Revert last change. It
19530 called `grub_util_read_at', which seeks from the beginning of the
19531 file.
19532
0b412211 195332005-01-04 Hollis Blanchard <hollis@penguinppc.org>
19534
19535 * TODO: Add note about endianness in grub-mkimage.
19536 * boot/powerpc/ieee1275/crt0.S (note): Remove unused .note
19537 section.
19538 * conf/powerpc-ieee1275.rmk (bin_UTILITIES): Add grub-mkimage.
19539 (grub_mkimage_SOURCES): New target.
19540 * include/grub/kernel.h (grub_start_addr): Remove variable.
19541 (grub_end_addr): Likewise.
19542 (grub_total_module_size): Likewise.
19543 (grub_kernel_image_size): Likewise.
19544 (GRUB_MODULE_MAGIC): New constant.
19545 (grub_module_info): New structure.
19546 (grub_arch_modules_addr): New prototype.
19547 (grub_get_end_addr): Remove prototype.
19548 * include/grub/i386/pc/kernel.h (grub_end_addr): New prototype.
19549 * include/grub/powerpc/ieee1275/kernel.h: New file.
19550 * include/grub/util/misc.h (grub_util_get_fp_size): New
19551 prototype.
19552 (grub_util_read_at): Likewise.
19553 (grub_util_write_image_at): Likewise.
19554 * kern/main.c (grub_get_end_addr): Remove function.
19555 (grub_load_modules): Call grub_arch_modules_addr instead of using
19556 grub_end_addr. Look for a grub_module_info struct in memory. Use
19557 the grub_module_info fields instead of calling grub_get_end_addr
19558 as loop conditions. Move grub_add_unused_region code here.
19559 (grub_add_unused_region): Remove function.
19560 * kern/i386/pc/init.c: Include grub/cache.h.
19561 (grub_machine_init): Remove call to grub_get_end_addr. Remove
19562 one call to add_mem_region.
19563 (grub_arch_modules_addr): New function.
19564 * kern/powerpc/ieee1275/init.c (grub_end_addr): Remove variable.
19565 (grub_total_module_size): Likewise.
19566 Include grub/machine/kernel.h.
19567 (grub_arch_modules_addr): New function.
19568 * util/grub-emu.c (grub_end_addr): Remove variable.
19569 (grub_total_module_size): Likewise.
19570 (grub_arch_modules_addr): New function.
19571 * util/misc.c: Include unistd.h.
19572 (grub_util_get_fp_size): New function.
19573 (grub_util_read_at): Likewise.
19574 (grub_util_write_image_at): Likewise.
19575 (grub_util_read_image): Call grub_util_read_at.
19576 (grub_util_write_image): Call grub_util_write_image_at.
19577 * util/i386/pc/grub-mkimage.c (generate_image): Allocate
19578 additional memory in kernel_img for a struct grub_module_info.
19579 Fill in that grub_module_info.
19580 * util/powerpc/ieee1275/grub-mkimage.c: New file.
19581
458786f8 195822005-01-03 Hollis Blanchard <hollis@penguinppc.org>
19583
19584 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_milliseconds):
19585 New function.
19586 * include/grub/powerpc/ieee1275/ieee1275.h
19587 (grub_ieee1275_milliseconds): New prototype.
19588 * include/grub/powerpc/ieee1275/time.h (GRUB_TICKS_PER_SECOND):
19589 Change to 1000.
19590 * kern/powerpc/ieee1275/init.c (grub_get_rtc): Call
19591 grub_ieee1275_milliseconds.
19592
ac507d1b 195932005-01-03 Hollis Blanchard <hollis@penguinppc.org>
19594
19595 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_realmode): New
19596 variable.
19597 (find_options): New function.
19598 (cmain): Call find_options.
19599 * include/grub/powerpc/ieee1275/ieee1275.h
19600 (grub_ieee1275_realmode): New extern variable.
19601 * kern/powerpc/ieee1275/openfw.c (grub_claimmap): Only call
19602 grub_map if grub_ieee1275_realmode is false.
19603
6b8fd1c4 196042004-12-29 Marco Gerards <metgerards@student.han.nl>
19605
19606 * normal/cmdline.c (grub_cmdline_get): Redone logic so no empty
19607 lines are inserted and make it work like readline. Reported by
19608 Vincent Pelletier <subdino2004@yahoo.fr>.
19609
8514a1e0 196102004-12-28 Marco Gerards <metgerards@student.han.nl>
19611
19612 * boot/powerpc/ieee1275/crt0.S (_start): Don't set up the stack.
19613
19614 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCE): Remove
19615 `kern/powerpc/cache.S'.
19616
924b6140 196172004-12-27 Marco Gerards <metgerards@student.han.nl>
19618
19619 * genmk.rb: Handle the `Program' class in the main loop. Written
19620 by Johan Rydberg <jrydberg@gnu.org>.
19621 (Program): New class.
19622 (programs): New variable.
19623 * boot/powerpc/ieee1275/cmain.c: Include <grub/machine/ieee1275.h>
19624 instead of "grub/machine/ieee1275.h". Include <grub/kernel.h>
19625 instead of "grub/kernel.h". Include <grub/machine/init.h>.
19626 (help_arch): Function removed.
19627 * conf/powerpc-ieee1275.rmk (grubof_HEADERS): Add
19628 `powerpc/libgcc.h' and `loader.h'.
19629 (pkgdata_PROGRAMS): New variable.
19630 (sbin_UTILITIES): Variable removed.
19631 (grub_emu_SOURCES): Added kern/powerpc/cache.S.
19632 (grubof_SOURCES): Variable re-defined so it only includes the
19633 core functionality.
19634 (grubof_CFLAGS): Remove `-DGRUBOF'.
19635 (pkgdata_MODULES, fshelp_mod_SOURCES, fshelp_mod_CFLAGS,
19636 (fat_mod_SOURCES, fat_mod_CFLAGS, ext2_mod_SOURCES)
19637 (ext2_mod_CFLAGS, ufs_mod_SOURCES, ufs_mod_CFLAGS)
19638 (minix_mod_SOURCES, minix_mod_CFLAGS, hfs_mod_SOURCES)
19639 (hfs_mod_CFLAGS, jfs_mod_SOURCES, jfs_mod_CFLAGS)
19640 (iso9660_mod_SOURCES, iso9660_mod_CFLAGS, _linux_mod_SOURCES)
19641 (_linux_mod_CFLAGS, linux_mod_SOURCES, linux_mod_CFLAGS)
19642 (normal_mod_SOURCES, normal_mod_CFLAGS, normal_mod_ASFLAGS)
19643 (hello_mod_SOURCES, hello_mod_CFLAGS, boot_mod_SOURCES)
19644 (boot_mod_CFLAGS, terminal_mod_SOURCES, terminal_mod_CFLAGS)
19645 (ls_mod_SOURCES, ls_mod_CFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS)
19646 (cat_mod_SOURCES, cat_mod_CFLAGS, font_mod_SOURCES)
19647 (font_mod_CFLAGS, amiga_mod_SOURCES, amiga_mod_CFLAGS)
19648 (apple_mod_SOURCES, apple_mod_CFLAGS, pc_mod_SOURCES)
19649 (pc_mod_CFLAGS): New variables.
19650 * disk/powerpc/ieee1275/ofdisk.c: Include <grub/machine/init.h>.
19651 (grub_ofdisk_iterate): Add a prototype for `dev_iterate'.
19652 * include/grub/dl.h (grub_arch_dl_sync_caches): New prototype.
19653 * include/grub/loader.h (grub_os_area_addr, grub_os_area_size):
19654 Moved from here...
19655 * include/grub/i386/pc/init.h (grub_os_area_addr)
19656 (rub_os_area_size): ... to here.
19657 * include/grub/powerpc/ieee1275/ieee1275.h
19658 (grub_ieee1275_entry_fn): Export symbol.
19659 * include/grub/powerpc/ieee1275/init.h: New file.
19660 * include/grub/powerpc/libgcc.h: Likewise.
19661 * include/grub/cache.h: Likewise.
19662 * kern/powerpc/cache.S: Likewise. Written by Hollis Blanchard
19663 <hollis@penguinppc.org>.
19664 * kern/dl.c: Include <grub/cache.h>.
19665 (grub_dl_flush_cache): New function.
19666 (grub_dl_load_core): Call `grub_dl_flush_cache' to flush the cache
19667 for this module.
19668 * kern/powerpc/ieee1275/init.c (grub_ofdisk_init)
19669 (grub_console_init): Removed prototypes.
19670 (grub_machine_init): Don't initialize the modules anymore.
19671 * kern/powerpc/ieee1275/openfw.c (grub_map): Make the function
19672 static.
19673 * include/grub/powerpc/types.h (GRUB_HOST_WORDS_LITTLEENDIAN):
19674 Macro undef removed.
19675 (GRUB_HOST_WORDS_BIGENDIAN): New macro.
19676 * kern/powerpc/dl.c (grub_arch_dl_relocate_symbols): Add
19677 relocation `R_PPC_REL32'. Return an error when the relocation is
19678 unknown.
19679 * Makefile.in (DATA): Add `$(pkgdata_PROGRAMS)'.
19680 * kern/i386/pc/init.c (grub_arch_sync_caches): New function.
19681 * util/misc.c (grub_arch_sync_caches): Likewise.
19682
e4b47e0c 196832004-12-19 Marco Gerards <metgerards@student.han.nl>
19684
19685 * conf/powerpc-ieee1275.rmk (MOSTLYCLEANFILES): Remove
19686 `symlist.c', add `grubof_symlist.c'.
19687 (symlist.c): Variable removed.
19688 (grubof_HEADERS): Variable added.
19689 (grubof_symlist.c): New target.
19690 (kernel_syms.lst): Use `grubof_HEADERS' instead of
19691 `kernel_img_HEADERS'.
19692 (grubof_SOURCES): Add `kern/powerpc/dl.c' and `grubof_symlist.c'.
19693 * kern/powerpc/dl.c: New file.
19694 * kern/powerpc/ieee1275/init.c (grub_arch_dl_check_header):
19695 Function removed.
19696 (grub_arch_dl_relocate_symbols): Likewise.
19697 (grub_register_exported_symbols): Likewise.
19698
4ceb3636 196992004-12-13 Marco Gerards <metgerards@student.han.nl>
19700
19701 * fs/ext2.c (grub_ext2_open): Don't use data after freeing it.
19702 (grub_ext2_dir): Likewise. Don't return in case of an error, jump
19703 to fail instead. Reported by Vincent Pelletier
19704 <subdino2004@yahoo.fr>.
19705
19706 * fs/fshelp.c (grub_fshelp_find_file): Don't free `oldnode' when
19707 it is not allocated. Reported by Vincent Pelletier
19708 <subdino2004@yahoo.fr>.
19709
19710 * normal/cmdline.c (grub_tab_complete): Add a blank line to the
19711 output so the output looks better.
f19dbdb7 19712
3f1578fe 197132004-12-04 Marco Gerards <metgerards@student.han.nl>
19714
19715 Modulize the partition map support and add support for the amiga
19716 partition map.
f19dbdb7 19717
3f1578fe 19718 * commands/ls.c: Include <grub/partition.h> instead of
19719 <grub/machine/partition.h>.
19720 * kern/disk.c: Likewise.
19721 * kern/rescue.c: Likewise.
19722 * loader/i386/pc/chainloader.c: Likewise.
19723 * normal/cmdline.c: Likewise.
19724 * kern/powerpc/ieee1275/init.c: Likewise.
19725 (grub_machine_init): Call `grub_pc_partition_map_init',
19726 `grub_amiga_partition_map_init' and
19727 `grub_apple_partition_map_init'.
19728 * conf/i386-pc.rmk (kernel_img_SOURCES): Remove
19729 `disk/i386/pc/partition.c'. Add `kern/partition.c'.
19730 (kernel_img_HEADERS): Remove `machine/partition.h'. Add
19731 `partition.h' and `pc_partition.h'.
19732 (grub_setup_SOURCES): Remove
19733 `disk/i386/pc/partition.c'. Add `kern/partition.c',
19734 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
19735 (grub_emu_SOURCES): Likewise.
19736 (pkgdata_MODULES): Add `amiga.mod', `apple.mod' and `pc.mod'.
19737 (amiga_mod_SOURCES, amiga_mod_CFLAGS, apple_mod_SOURCES)
19738 (apple_mod_CFLAGS, pc_mod_SOURCES, pc_mod_CFLAGS): New variables.
19739 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
19740 `disk/powerpc/ieee1275/partition.c'. Add `kern/partition.c',
19741 `partmap/amiga.c', `partmap/apple.c' and `partmap/pc.c'.
19742 (grubof_SOURCES): Likewise.
19743 * disk/i386/pc/partition.c: File removed.
19744 * disk/powerpc/ieee1275/partition.c: Likewise.
19745 * include/grub/powerpc/ieee1275/partition.h: Likewise.
19746 * include/grub/i386/pc/partition.h: Likewise.
19747 * kern/partition.c: New file.
19748 * partmap/amiga.c: Likewise.
19749 * partmap/apple.c: Likewise.
19750 * partmap/pc.c: Likewise.
19751 * include/grub/partition.h: Likewise..
19752 * include/grub/pc_partition.h: Likewise.
19753 * util/grub-emu.c: Include <grub/partition.h> instead of
19754 <grub/machine/partition.h>.
19755 (main): Call `grub_pc_partition_map_init',
19756 `grub_amiga_partition_map_init' and
19757 `grub_apple_partition_map_init' and deinitialize afterwards.
19758 * util/i386/pc/biosdisk.c: Include `#include
19759 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
19760 `<grub/machine/partition.h>'.
19761 * util/i386/pc/grub-setup.c: Likewise.
19762 * util/i386/pc/biosdisk.c: Likewise.
19763 (grub_util_biosdisk_get_grub_dev): Only access the PC specific
19764 partition information in case of a PC partition.
19765 * util/i386/pc/grub-setup.c: Include `#include
19766 <grub/partition.h>' and `include <grub/pc_partition.h>' instead of
19767 `<grub/machine/partition.h>'.
19768 (setup): Only access the PC specific partition information in case
19769 of a PC partition.
19770
0ef4ced9 197712004-11-17 Hollis Blanchard <hollis@penguinppc.org>
f19dbdb7 19772
0ef4ced9 19773 * kern/powerpc/ieee1275/init.c (grub_setjmp): Remove function.
19774 (grub_longjmp): Likewise.
19775 * include/grub/powerpc/setjmp.h (grub_jmp_buf): Set array size to
19776 20.
19777 * normal/powerpc/setjmp.S: New file.
19778 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
19779 `normal/powerpc/setjmp.S'.
19780 (grubof_CFLAGS): Add `-DGRUBOF'.
19781 * include/grub/setjmp.h [GRUB_UTIL]: Changed condition to
19782 [GRUB_UTIL && !GRUBOF].
f19dbdb7 19783
19950e29 197842004-11-16 Marco Gerards <metgerards@student.han.nl>
19785
19786 * kern/powerpc/ieee1275/openfw.c (grub_devalias_iterate): Skip any
19787 property named `name'. Correctly handle the error returned by
19788 `grub_ieee1275_finddevice' if a device can not be opened.
19789
a2fea427 197902004-11-02 Hollis Blanchard <hollis@penguinppc.org>
19791
19792 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_readkey): Test
19793 `actual' for negativity.
19794 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Remove
19795 kern/fshelp.c.
19796
41ea0ea3 197972004-11-01 Marco Gerards <metgerards@student.han.nl>
19798
19799 * term/i386/pc/vga.c (VGA_HEIGHT): Changed to 350.
19800 (PAGE_OFFSET): New macro.
19801 (CRTC_ADDR_PORT): Likewise.
19802 (CRTC_DATA_PORT): Likewise.
19803 (START_ADDR_HIGH_REGISTER): Likewise.
19804 (START_ADDR_LOW_REGISTER): Likewise.
19805 (GRAPHICS_ADDR_PORT): Likewise.
19806 (GRAPHICS_DATA_PORT): Likewise.
19807 (READ_MAP_REGISTER): Likewise.
19808 (INPUT_STATUS1_REGISTER): Likewise.
19809 (INPUT_STATUS1_VERTR_BIT): Likewise.
19810 (page): New variable.
19811 (wait_vretrace): New function.
19812 (set_read_map): Likewise.
19813 (set_start_address): Likewise.
19814 (grub_vga_init): Use mode 0x10 instead of mode 0x12. Switch to
19815 the right page.
19816 (check_vga_mem): Take the page into account.
19817 (write_char): Likewise.
19818 (write_cursor): Likewise.
19819 (scroll_up): Likewise. Copy the page to the page that is not
19820 shown and switch between both pages.
19821 (grub_vga_putchar): Fix off by one error.
19822 (grub_vga_cls): Wait for the vertical retrace. Take the page into
19823 account.
19824
ad0bd20b 198252004-11-01 Marco Gerards <metgerards@student.han.nl>
19826
19827 Add support for iso9660 (including rockridge).
f19dbdb7 19828
ad0bd20b 19829 * conf/i386-pc.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
19830 (iso9660_mod_SOURCES): New variable.
19831 (iso9660_mod_CFLAGS): Likewise.
19832 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/iso9660.c.
19833 * include/grub/fs.h (grub_iso9660_init): New prototype.
19834 * util/grub-emu.c (main): Call `grub_iso9660_init'.
19835 * fs/iso9660.c: New file.
19836
19837 * include/grub/misc.h (grub_strncat): New prototype.
19838 * kern/misc.c (grub_strncat): New function.
f19dbdb7 19839
ad0bd20b 19840 * fs/hfs.c (grub_hfs_mount): Translate the error
19841 `GRUB_ERR_OUT_OF_RANGE' to `GRUB_ERR_BAD_FS'.
19842 * fs/jfs.c (grub_jfs_mount): Likewise.
19843 * fs/ufs.c (grub_ufs_mount): Likewise.
19844
a5477a59 198452004-10-28 Hollis Blanchard <hollis@penguinppc.org>
19846
19847 * boot/powerpc/ieee1275/cmain.c (cmain): Remove asm statements
19848 which initialized BAT registers.
19849 * boot/powerpc/ieee1275/ieee1275.c (IEEE1275_CALL_ENTRY_FN,
19850 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
19851 Move from here...
19852 * include/grub/powerpc/ieee1275/ieee1275.h (IEEE1275_CALL_ENTRY_FN,
19853 grub_ieee1275_common_hdr, INIT_IEEE1275_COMMON):
19854 ... to here.
19855 * kern/powerpc/ieee1275/openfw.c (grub_map): New function.
19856 (grub_mapclaim): Likewise.
19857 * loader/powerpc/ieee1275/linux.c (grub_load_linux): Use
19858 grub_mapclaim instead of grub_ieee1275_claim. Assign linux_addr by
19859 hand.
19860
9304c1f8 198612004-10-19 Hollis Blanchard <hollis@penguinppc.org>
19862
19863 * conf/powerpc-ieee1275.rmk (COMMON_ASFLAGS): Remove -fno-builtin.
19864 (COMMON_CFLAGS): Remove -fno-builtin and -D__ASSEMBLY__. Add
19865 -ffreestanding and -msoft-float.
19866
86f4ae25 198672004-10-15 Hollis Blanchard <hollis@penguinppc.org>
19868
19869 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_open): Do not
19870 append ":0" to devpath if the GRUB_IEEE1275_NO_PARTITION_0 flag is
19871 set in grub_ieee1275_flags.
19872
38912228 198732004-10-14 Hollis Blanchard <hollis@penguinppc.org>
19874
19875 * include/grub/powerpc/ieee1275/ieee1275.h (abort): Add function
19876 prototype.
19877 * kern/powerpc/ieee1275/init.c (grub_machine_init): Call
19878 grub_console_init first.
19879 Change the memory range used for grub_ieee1275_claim and
19880 grub_mm_init_region.
19881 Print an error message if the claim fails.
19882 Include <grub/misc.h>.
19883
d1923dc8 198842004-10-13 Hollis Blanchard <hollis@penguinppc.org>
19885
19886 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_iterate):
19887 Call grub_children_iterate for device nodes of type `scsi',
19888 `ide', or `ata'.
19889 (grub_ofdisk_open): Remove manual device alias resolution.
19890 Fix memory leak when device cannot be opened.
f19dbdb7 19891 * include/grub/powerpc/ieee1275/ieee1275.h
d1923dc8 19892 (grub_children_iterate): New prototype.
19893 * kern/powerpc/ieee1275/openfw.c (grub_children_iterate):
19894 New function.
19895 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
19896 Return -1 if args.size was -1.
19897
4512e4f3 198982004-10-11 Hollis Blanchard <hollis@penguinppc.org>
19899
19900 * boot/powerpc/ieee1275/cmain.c (grub_ieee1275_flags): New global.
19901 (cmain): Accept 3 parameters. Test for 0xdeadbeef, indicating Old
19902 World Macintosh. If Old Wold, set flag in grub_ieee1275_flags; claim
19903 Open Firmware's memory for it; claim memory from _start to _end.
19904 * boot/powerpc/ieee1275/crt0.S (__bss_start): New extern.
19905 (_end): New extern.
19906 (_start): Zero BSS from __bss_start to _end.
19907 * include/grub/powerpc/ieee1275/ieee1275.h (grub_ieee1275_flags):
19908 New extern.
19909 (GRUB_IEEE1275_NO_PARTITION_0): New #define.
19910
4d61feb0 199112004-10-11 Hollis Blanchard <hollis@penguinppc.org>
19912
ad0bd20b 19913 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): Return
19914 -1 if args.base was -1.
4d61feb0 19915
026fa2f9 199162004-10-08 Hollis Blanchard <hollis@penguinppc.org>
19917
19918 * term/powerpc/ieee1275/ieee1275.c (grub_ofconsole_cls): Use an ANSI
19919 escape sequence instead of a literal ^L. Also call
19920 grub_ofconsole_gotoxy.
19921
9f2220ef 199222004-10-03 Hollis Blanchard <hollis@penguinppc.org>
19923
19924 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_claim): change
19925 void * arguments to grub_addr_t. All callers updated. Also make
19926 the `result' argument optional.
19927 (grub_ieee1275_release): change void * arguments to grub_addr_t.
19928 All callers updated.
19929
8a572cd7 199302004-09-22 Hollis Blanchard <hollis@penguinppc.org>
19931
19932 * commands/ls.c (grub_ls_list_files): Use the string following the
19933 initial ')', if present, as the filesystem path.
19934 * kern/rescue.c (grub_rescue_cmd_ls): Likewise.
19935
19936 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): List crt0.S first.
19937
18aa81f2 199382004-09-18 Yoshinori K. Okuji <okuji@enbug.org>
19939
19940 Make the source code of the menu interface more readable.
f19dbdb7 19941
18aa81f2 19942 * normal/menu.c: Include grub/mm.h.
19943 (TERM_WIDTH): New macro.
19944 (TERM_HEIGHT): Likewise.
19945 (TERM_INFO_HEIGHT): Likewise.
19946 (TERM_MARGIN): Likewise.
19947 (TERM_SCROLL_WIDTH): Likewise.
19948 (TERM_TOP_BORDER_Y): Likewise.
19949 (TERM_LEFT_BORDER_X): Likewise.
19950 (TERM_BORDER_WIDTH): Likewise.
19951 (TERM_MESSAGE_HEIGHT): Likewise.
19952 (TERM_BORDER_HEIGHT): Likewise.
19953 (TERM_NUM_ENTRIES): Likewise.
19954 (TERM_FIRST_ENTRY_Y): Likewise.
19955 (TERM_ENTRY_WIDTH): Likewise.
19956 (TERM_CURSOR_X): Likewise.
19957 (draw_border): Use macros instead of magic numbers.
19958 (print_entry): Likewise.
19959 (print_entries): Likewise.
19960 (run_menu): Likewise. Also, handle the key 'e'.
19961 (run_menu_entry): Ignore empty command lines.
19962 (print_message): Added a new argument EDIT. If EDIT is true,
19963 print a different message.
19964 (init_page): Likewise.
19965 (edit_menu_entry): New function. Not implemented yet.
19966
b47efe30 199672004-09-17 Marco Gerards <metgerards@student.han.nl>
19968
19969 Add `linux.mod' and `multiboot.mod' so linux and multiboot kernels
19970 can be loaded from normal mode.
f19dbdb7 19971
b47efe30 19972 * conf/i386-pc.rmk (pkgdata_MODULES): Add `linux.mod' and
19973 `multiboot.mod'.
19974 (linux_mod_SOURCES, linux_mod_CFLAGS, multiboot_mod_SOURCES)
19975 (multiboot_mod_CFLAGS): New variables.
19976 * loader/i386/pc/linux_normal.c: New file.
f19dbdb7 19977 * loader/i386/pc/multiboot_normal.c: Likewise.
19978
b47efe30 19979 * loader/i386/pc/linux.c (grub_rescue_cmd_initrd): Don't use the
19980 attribute `unused'.
f19dbdb7 19981
b47efe30 19982 * fs/ext2.c (grub_ext2_iterate_dir): Fix typos in inode type. Use
19983 `fdiro' to read the mode information from instead of `diro'.
19984
19985 * fs/fshelp.c (grub_fshelp_find_file): Set type to foundtype after
19986 looking up a symlink.
19987
19988 * include/grub/normal.h (GRUB_COMMAND_FLAG_NO_ARG_PARSE): New
19989 macro.
19990 * normal/command.c (grub_command_execute): Don't parse the
19991 arguments when `GRUB_COMMAND_FLAG_NO_ARG_PARSE' is set in the
19992 flags of the command.
19993
19994 * normal/menu.c (grub_menu_run): Fix typo.
19995
da75ac71 199962004-09-14 Hollis Blanchard <hollis@penguinppc.org>
19997
19998 * kern/powerpc/ieee1275/init.c (abort): Trap into Open Firmware.
19999
20000 * term/powerpc/ieee1275/ofconsole.c (grub_ofconsole_gotoxy): Use
20001 `y + 1' instead of `y - 1'.
20002
20003 * conf/powerpc-ieee1275.rmk (grubof_LDFLAGS): Add `-N' and `-S'.
f19dbdb7 20004
062b24c2 200052004-09-14 Yoshinori K. Okuji <okuji@enbug.org>
20006
20007 From Hollis Blanchard <hollis@penguinppc.org>:
20008 * kern/misc.c (memmove): New alias for grub_memmove.
20009 (memcmp): New alias for grub_memcmp.
20010 (memset): New alias for grub_memset.
f19dbdb7 20011 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_get_property):
062b24c2 20012 Change "int handle" to "grub_ieee1275_phandle_t handle".
f19dbdb7 20013 * include/grub/powerpc/ieee1275/ieee1275.h
062b24c2 20014 (grub_ieee1275_get_property): Likewise.
f19dbdb7 20015
8ddad845 200162004-09-12 Tomas Ebenlendr <ebik@ucw.cz>
20017
20018 Added normal mode command `chainloader' as module chain.mod, which
20019 depends on normal.mod and _chain.mod.
f19dbdb7 20020
8ddad845 20021 * conf/i386-pc.rmk (pkgdata_MODULES): Add `chain.mod'.
20022 (chain_mod_SOURCES, chain_mod_CFLAGS): Variables added.
20023 * include/grub/i386/pc/loader.h (grub_rescue_cmd_chainloader):
20024 Deleted prototype.
20025 * loader/i386/pc/chainloader.c (grub_rescue_cmd_chainloader): All
20026 but arguments parsing moved to ...
20027 (grub_chainloader_cmd): ... here. New function.
20028 * include/grub/i386/pc/chainloader.h: New file.
20029 * loader/i386/pc/chainloader_normal.c: Likewise.
20030
2c1f4ce3 200312004-09-11 Marco Gerards <metgerards@student.han.nl>
20032
20033 * conf/i386-pc.rmk (kernel_img_SOURCES): Added kern/fshelp.c.
20034 (grub_mkimage_LDFLAGS): Likewise.
20035 (grub_emu_SOURCES): Likewise.
20036 (kernel_img_HEADERS): Added fshelp.h.
20037 * fs/ext2.c: Include <grub/fshelp.h>.
20038 (FILETYPE_REG): New macro.
20039 (FILETYPE_INO_REG): Likewise.
20040 (grub_ext_sblock): Renamed to `grub_ext2_sblock'.
20041 Changed all users.
20042 (ext2_block_group): Renamed to `grub_ext2_block_group'. Changed
20043 all users.
20044 (grub_fshelp_node): New struct.
20045 (grub_ext2_data): Added member `diropen'. Changed member `inode'
20046 to a pointer.
20047 (grub_ext2_get_file_block): Removed function.
20048 (grub_ext2_read_block): New function.
20049 (grub_ext2_read_file): Replaced parameter `data' by `node'.
20050 This function was written.
20051 (grub_ext2_mount): Read the root inode. Create a diropen struct.
20052 (grub_ext2_find_file): Removed function.
20053 (grub_ext2_read_symlink): New function.
20054 (grub_ext2_iterate_dir): Likewise.
20055 (grub_ext2_open): Rewritten.
20056 (grub_ext2_dir): Rewritten.
20057 * include/grub/fshelp.h: New file.
20058 * fs/fshelp.c: Likewise.
20059
3c52136a 200602004-09-10 Yoshinori K. Okuji <okuji@enbug.org>
20061
20062 * normal/menu.c: Include grub/loader.h and grub/machine/time.h.
20063 (print_message): Add a missing newline.
20064 (run_menu): Added timeout support.
20065 (run_menu_entry): New local function.
20066 (grub_menu_run): Added support for booting.
20067
20068 * kern/loader.c (grub_loader_is_loaded): New function.
20069
20070 * include/grub/powerpc/ieee1275/time.h: Include grub/symbol.h.
20071 (grub_get_rtc): Exported.
20072
20073 * include/grub/i386/pc/time.h: Include grub/symbol.h.
20074 (grub_get_rtc): Exported.
20075
20076 * include/grub/normal.h (struct grub_command_list): Remove
20077 constant from the member `command'.
20078
20079 * include/grub/loader.h (grub_loader_is_loaded): Declared.
20080
20081 * include/grub/err.h (GRUB_ERR_INVALID_COMMAND): New constant.
20082
20083 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/time.h.
20084
aa033560 200852004-08-28 Marco Gerards <metgerards@student.han.nl>
20086
20087 Add support for the JFS filesystem.
20088
20089 * fs/jfs.c: New file.
20090 * include/grub/fs.h (grub_jfs_init): New prototype.
20091 (grub_jfs_fini): New prototype.
20092 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/jfs.c.
20093 (grub_emu_SOURCES): Likewise.
20094 (pkgdata_MODULES): Add jfs.mod.
20095 (jfs_mod_SOURCES): New variable.
20096 (jfs_mod_CFLAGS): Likewise.
20097 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs.jfs.c.
20098 (grubof_SOURCES): Likewise.
20099 * util/grub-emu.c (main): Initialize and deinitialize JFS support.
20100
20101 * fs/fat.c (grub_fat_find_dir): Convert the filename little
20102 endian to the host endian.
20103 (grub_fat_utf16_to_utf8): Move function from there...
20104 * kern/misc.c (grub_utf16_to_utf8): ...to here. Do not convert
fe987087 20105 the endianness of the source string anymore.
aa033560 20106 * include/grub/misc.h (grub_utf16_to_utf8): New prototype.
20107
94bc45af 201082004-08-24 Marco Gerards <metgerards@student.han.nl>
20109
20110 * commands/boot.c (grub_boot_init) [GRUB_UTIL]: Make conditional.
20111 (grub_boot_fini) [GRUB_UTIL]: Likewise.
20112 (GRUB_MOD_INIT) [!GRUB_UTIL]: Likewise.
20113 (GRUB_MOD_FINI) [!GRUB_UTIL]: Likewise.
f19dbdb7 20114
94bc45af 20115 * fs/hfs.c (grub_hfs_find_node): Add a prototype for `node_found'.
20116 (grub_hfs_iterate_dir): Make the function static. Add prototypes
20117 for `node_found' and `it_dir'.
20118 (grub_hfs_dir): Add prototype for `dir_hook'.
20119
20120 * fs/minix.c (grub_minix_get_file_block): Add prototype for
20121 `grub_get_indir'. Rename `indir' in two blocks to `indir16'
20122 and `indir32' to silence a gcc warning.
20123
20124 * include/grub/fs.h (grub_hfs_init): New prototype.
20125 (grub_hfs_fini): Likewise.
f19dbdb7 20126
20127
97543f08 201282004-08-21 Yoshinori K. Okuji <okuji@enbug.org>
20129
20130 Each disk device has its own id now. This is useful to make use
20131 of multiple disk devices.
f19dbdb7 20132
97543f08 20133 * include/grub/disk.h (grub_disk_dev_id): New enum.
20134 (GRUB_DISK_DEVICE_BIOSDISK_ID): New constant.
20135 (GRUB_DISK_DEVICE_OFDISK_ID): Likewise.
20136
20137 * disk/i386/pc/biosdisk.c (grub_biosdisk_dev): Specify
20138 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
20139
20140 * disk/powerpc/ieee1275/ofdisk.c (grub_ofdisk_dev): Specify
20141 GRUB_DISK_DEVICE_OFDISK_ID as an id.
20142
20143 * util/i386/pc/biosdisk.c (grub_util_biosdisk_dev): Specify
20144 GRUB_DISK_DEVICE_BIOSDISK_ID as an id.
20145
20146 * include/grub/disk.h (struct grub_disk_dev): Added a new member
20147 "id" which is used by the cache manager.
20148
20149 * normal/main.c (grub_normal_init_page): Use "GNU GRUB" instead
20150 of just "GRUB".
20151
64372eb4 201522004-08-18 Marco Gerards <metgerards@student.han.nl>
20153
20154 * fs/hfs.c: New file.
20155 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/hfs.c.
20156 (grub_emu_SOURCES): Likewise.
20157 (pkgdata_MODULES): Add hfs.mod.
20158 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/hfs.c.
20159 (grubof_SOURCES): Likewise.
20160 * util/grub-emu.c (main): Initialize and deinitialize HFS support.
20161
20162 * include/grub/misc.h (grub_strncasecmp): Add prototype.
20163 * kern/misc.c (grub_strncasecmp): Add function.
20164
cc61b58f 201652004-08-14 Marco Gerards <metgerards@student.han.nl>
20166
20167 * include/grub/arg.h (GRUB_ARG_OPTION_OPTIONAL): Surround macro
20168 with parentheses.
20169
20170 * fs/ext2.c (FILETYPE_UNKNOWN): New macro.
20171 (grub_ext2_dir): In case the directory entry type is unknown, read
20172 it from the inode.
20173
0ef123f6 201742004-08-02 Peter Bruin <pjbruin@dds.nl>
20175
20176 * loader/powerpc/ieee1275/linux.c (grub_linux_init): Pass
20177 grub_load_linux instead of grub_rescue_cmd_linux as second
20178 argument of grub_rescue_register_command.
20179
20180 * Makefile.in (RMKFILES): Add conf/powerpc-ieee1275.rmk.
20181
a447c5df 201822004-07-27 Marco Gerards <metgerards@student.han.nl>
20183
20184 * boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_release): New
20185 function.
20186 * commands/boot.c: Remove the check for `GRUB_UTIL'.
20187 * conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
20188 `loader/powerpc/ieee1275/linux.c',
20189 `loader/powerpc/ieee1275/linux_normal.c' and `commands/boot.c'.
20190 * include/grub/powerpc/ieee1275/ieee1275.h
20191 (grub_ieee1275_release): New prototype.
20192 * include/grub/powerpc/ieee1275/loader.h: Rewritten.
20193 * kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize
20194 normal, boot, linux and linux_normal.
20195 * loader/powerpc/ieee1275/linux.c: New file.
20196 * loader/powerpc/ieee1275/linux_normal.c: Likewise.
20197
5a9e3546 201982004-07-12 Marco Gerards <metgerards@student.han.nl>
20199
20200 * normal/arg.c (grub_arg_parse): Correct error handling after
20201 reallocating the argumentlist (check if `argl' is not null instead
20202 of checking if `args' is not null).
20203 * kern/mm.c (grub_realloc): Return the same pointer when using the
20204 same region, instead of returning the header address.
20205
e15199cb 202062004-07-11 Marco Gerards <metgerards@student.han.nl>
20207
20208 * disk/powerpc/ieee1275/partition.c (grub_partition_iterate): Skip
20209 one block instead of two when looking for the initial partition.
20210 (grub_partition_probe): Initialize the local variable `p' with 0.
20211 Use base 10 for the grub_strtoul call.
20212 * kern/misc.c (grub_strncpy): Fix off by one bug. Eliminated the
20213 need for one local variable.
20214 (grub_strtoul): Don't add the new value to `num', instead of that
20215 just assign it.
20216
020616c2 202172004-07-11 Marco Gerards <metgerards@student.han.nl>
20218
20219 * conf/i386-pc.rmk (pkgdata_IMAGE): Add pxeboot.img.
20220 (pxeboot_img_SOURCES): New variable.
20221 (pxeboot_img_ASFLAGS): Likewise.
20222 (pxeboot_img_LDFLAGS): Likewise.
20223 * boot/i386/pc/pxeboot.S: New file. Based on pxeloader.S from
20224 GRUB Legacy and boot.S. Adopted for GRUB 2 by lode leroy
20225 <lode_leroy@hotmail.com>.
20226
6c51eb64 202272004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
20228
20229 * kern/rescue.c (grub_enter_rescue_mode): Don't continue when
20230 there was no input.
20231
cfb12aff 202322004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
20233
20234 * normal/cmdline.c (grub_set_history): Fix off by one bug. Fixed
20235 the history buffer logic.
20236
6eabba74 202372004-06-27 Tomas Ebenlendr <ebik@ucw.cz>
20238
20239 * fs/ext2.c (FILETYPE_INO_MASK, FILETYPE_INO_DIRECTORY)
20240 (FILETYPE_INO_SYMLINK): New macros.
20241 (grub_ext2_find_file): Check if the node is a directory using the
20242 inode stat information instead of using the filetype in the
20243 dirent. Exclude the first character of an absolute symlink.
20244 (grub_ext2_dir): Mask out the filetype part of the mode member of
20245 the inode.
20246
66e19ef8 202472004-05-24 Marco Gerards <metgerards@student.han.nl>
20248
20249 Add support for UFS version 1 and 2. Add support for the minix
20250 filesystem version 1 and 2, both the variants with 14 and 30 long
20251 filenames.
f19dbdb7 20252
66e19ef8 20253 * conf/i386-pc.rmk (grub_setup_SOURCES): Add fs/ufs.c and
20254 fs/minix.c.
20255 (grub_emu_SOURCES): Likewise.
20256 (pkgdata_MODULES): Add ufs.mod and minix.mod.
20257 (ufs_mod_SOURCES): New variable.
20258 (ufs_mod_CFLAGS): Likewise.
20259 (minix_mod_SOURCES): Likewise.
20260 (minix_mod_CFLAGS): Likewise.
20261 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add fs/ufs.c and
20262 fs/minix.c.
20263 (grubof_SOURCES): Likewise.
20264 * fs/ufs.c: New file.
20265 * fs/minix.c: New file.
20266 * include/grub/fs.h (grub_ufs_init): New prototype.
20267 (grub_ufs_fini): Likewise.
20268 (grub_minix_init): Likewise.
20269 (grub_minix_fini): Likewise.
20270 * util/grub-emu.c (main): Initialize and deinitialize UFS and
20271 minix fs.
20272
cc2e748a 202732004-04-30 Jeroen Dekkers <jeroen@dekkers.cx>
20274
20275 * conf/powerpc-ieee1275.rmk (grub_emu_SOURCES): Add normal/arg.c,
20276 commands/ls.c, commands/terminal.c, commands/boot.c,
20277 commands/cmp.c and commands/cat.c.
20278 (grubof_LDFLAGS): Add -nostdlib -static-libgcc -lgcc.
20279
20280 * kern/powerpc/ieee1275/init.c: Include "grub/env.h" instead of
20281 "env.h"
20282
4b13b216 202832004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
20284
20285 All symbols prefixed with PUPA_ and pupa_ are renamed to GRUB_
20286 and grub_, respectively. Because the conversion is trivial and
20287 mechanical, I omit the details here. Please refer to the CVS
20288 if you need more information.
20289
6a142551 202902004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
20291
20292 * include/pupa: Renamed to ...
20293 * include/grub: ... this.
20294 * util/i386/pc/pupa-mkimage.c: Renamed to ...
20295 * util/i386/pc/grub-mkimage.c: ... this.
20296 * util/i386/pc/pupa-setup.c: Renamed to ...
20297 * util/i386/pc/grub-setup.c: ... this.
20298 * util/pupa-emu.c: Renamed to ...
20299 * util/grub-emu.c: ... this.
20300
e56cdf21 203012004-03-29 Marco Gerards <metgerards@student.han.nl>
20302
20303 Add support for the newworld apple macintosh (PPC). This has been
20304 tested on the powerbook 2000 only. It only adds support for
20305 generic ieee1275 functions, console and disk support. This should
20306 be easy to port to other architectures with support for Open
20307 Firmware.
f19dbdb7 20308
e56cdf21 20309 * configure.ac: Accept the powerpc as host_cpu. In the case of
20310 the powerpc cpu set the host_vendor to ieee1275. Make sure the i386
20311 specific tests are only executed while building for the i386.
20312 Inverse test for crosscompile.
20313 * genmk.rb (Utility): Allow assembler files.
20314 * normal/cmdline.c (pupa_tab_complete): Reset pupa_errno.
20315 * conf/powerpc-ieee1275.rmk: New file.
20316 * disk/powerpc/ieee1275/ofdisk.c: Likewise.
20317 * disk/powerpc/ieee1275/partition.c: Likewise.
20318 * include/pupa/powerpc/ieee1275/biosdisk.h: Likewise.
20319 * include/pupa/powerpc/ieee1275/console.h: Likewise.
20320 * include/pupa/powerpc/ieee1275/partition.h: Likewise.
20321 * include/pupa/powerpc/ieee1275/time.h: Likewise.
20322 * include/pupa/powerpc/ieee1275/util/biosdisk.h: Likewise.
20323 * include/pupa/powerpc/ieee1275/multiboot.h: Likewise.
20324 * include/pupa/powerpc/ieee1275/loader.h
20325 * include/pupa/powerpc/setjmp.h: Likewise.
20326 * include/pupa/powerpc/types.h: Likewise.
20327 * kern/powerpc/ieee1275/init.c: Likewise.
20328 * kern/powerpc/ieee1275/openfw.c: Likewise.
20329 * term/powerpc/ieee1275/ofconsole.c: Likewise.
20330
20331 These files were written by Johan Rydberg
20332 (jrydberg@night.trouble.net) and I only modified them slightly.
f19dbdb7 20333
e56cdf21 20334 * boot/powerpc/ieee1275/cmain.c: New file.
20335 * boot/powerpc/ieee1275/crt0.S: Likewise.
20336 * boot/powerpc/ieee1275/ieee1275.c: Likewise.
20337 * include/pupa/powerpc/ieee1275/ieee1275.h: Likewise.
20338
8c8cc205 203392004-03-14 Jeroen Dekkers <jeroen@dekkers.cx>
20340
20341 * Makefile.in: Update copyright.
20342 * genmodsrc.sh: Likewise.
20343 * gensymlist.sh: Likewise.
20344 * term/i386/pc/vga.c: Indent correctly.
20345
20346 * util/i386/pc/pupa-mkimage.c (usage): Use PACKAGE_BUGREPORT as
20347 bugreporting address.
20348 * util/i386/pc/pupa-setup.c (usage): Likewise,
20349 (main): Call pupa_ext2_init and pupa_ext2_fini.
20350
f19dbdb7 20351 * fs/fat.c (log2): Renamed to ...
8c8cc205 20352 (fat_log2): ... this.
20353 All callers changed.
20354 * kern/misc.c (memcpy): Alias to pupa_memmove.
20355 * loader/i386/pc/multiboot.c (pupa_rescue_cmd_multiboot): Fix
20356 lvalue cast.
20357 * util/console.c (pupa_ncurses_fini): Return 0.
20358
20359 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open)[__linux__]:
20360 Move fail label here.
20361 [__GNU__]: Don't warn when using stat.
20362 (open_device)[!__linux__]: Check if FD < 0 instead of !FD.
20363 (pupa_util_biosdisk_get_pupa_dev)[__GNU__]: Change type of N to
20364 long int. Use strtol instead of strtoul.
f19dbdb7 20365
db1771cf 203662004-03-14 Marco Gerards <metgerards@student.han.nl>
20367
20368 * commands/boot.c: New file.
20369 * commands/cat.c: Likewise.
20370 * commands/cmp.c: Likewise.
20371 * commands/ls.c: Likewise.
20372 * commands/terminal.c: Likewise.
20373 * normal/command.c: Include <pupa/env.h> and <pupa/dl.h>.
20374 (pupa_register_command): Changed interface to match the new
20375 argument parser.
20376 (pupa_command_execute): Changed (almost rewritten) so it uses
20377 pupa_split_command. Added support for setting variables using the
20378 syntax `foo=bar'.
20379 (rescue_command): Changed to work with the new argument parser.
20380 (terminal_command): Moved from here to commands/terminal.c.
20381 (set_command): New function.
20382 (unset_command): New function.
20383 (insmod_command): New function.
20384 (rmmod_command): New function.
20385 (lsmod_command): New function.
20386 (pupa_command_init): Don't initialize the command terminal
20387 anymore. Initialize the commands set, unset, insmod, rmmod and
20388 lsmod.
20389 * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/env.c.
20390 (kernel_img_HEADERS): Add arg.h and env.h.
20391 (pupa_mkimage_LDFLAGS): Add kern/env.c.
20392 (pupa_emu_SOURCES): Add kern/env.c, commands/ls.c,
20393 commands/terminal.c commands/boot.c commands/cmp.c commands/cat.c,
20394 normal/arg.c.
20395 (pkgdata_MODULES): Add ls.mod, boot.mod, cmp.mod, cat.mod and
20396 terminal.mod.
20397 (normal_mod_SOURCES): Add normal/arg.c and normal/arg.c.
20398 (boot_mod_SOURCES): New variable.
20399 (terminal_mod_SOURCES): Likewise.
20400 (ls_mod_SOURCES): Likewise.
20401 (cmp_mod_SOURCES): Likewise.
20402 (cat_mod_SOURCES): Likewise.
20403
20404 * normal/arg.c: New file.
20405 * kern/env.c: Likewise.
20406 * include/pupa/arg.h: Likewise.
20407 * include/pupa/env.h: Likewise.
20408 * font/manager.c (font_command): Changed to match argument parsing
20409 interface changes.
20410 (PUPA_MOD_INIT): Likewise.
20411 * hello/hello.c (pupa_cmd_hello): Likewise.
20412 (PUPA_MOD_INIT): Likewise.
20413 * include/pupa/disk.h: Include <pupa/device.h>.
20414 (pupa_print_partinfo): New prototype.
20415 * include/pupa/dl.h (pupa_dl_set_prefix): Prototype removed.
20416 (pupa_dl_get_prefix): Likewise.
20417 * include/pupa/misc.h: Include <pupa/err.h>.
20418 (pupa_isgraph): New prototype.
20419 (pupa_isdigit): Likewise.
20420 (pupa_split_cmdline): Likewise.
20421 * include/pupa/normal.h: Include <pupa/arg.h>.
20422 (pupa_command): Changed the prototype of the member `func' to
20423 match the argument parsing interface. Added member `options'.
20424 (pupa_register_command): Updated to match function.
20425 (pupa_arg_parse): New prototype.
20426 (pupa_hello_init) [PUPA_UTIL]: New prototype.
20427 (pupa_hello_fini) [PUPA_UTIL]: Likewise.
20428 (pupa_ls_init) [PUPA_UTIL]: Likewise.
20429 (pupa_ls_fini) [PUPA_UTIL]: Likewise.
20430 (pupa_cat_init) [PUPA_UTIL]: Likewise.
20431 (pupa_cat_fini) [PUPA_UTIL]: Likewise.
20432 (pupa_boot_init) [PUPA_UTIL]: Likewise.
20433 (pupa_boot_fini) [PUPA_UTIL]: Likewise.
20434 (pupa_cmp_init) [PUPA_UTIL]: Likewise.
20435 (pupa_cmp_fini) [PUPA_UTIL]: Likewise.
20436 (pupa_terminal_init) [PUPA_UTIL]: Likewise.
20437 (pupa_terminal_fini) [PUPA_UTIL]: Likewise.
20438 * kern/disk.c: Include <pupa/file.h>.
20439 (pupa_print_partinfo): New function.
20440 * kern/dl.c: Include <pupa/env.h>.
20441 (pupa_dl_dir): Variable removed.
20442 (pupa_dl_load): Use the environment variable `prefix' instead of
20443 the variable pupa_dl_dir.
20444 (pupa_dl_set_prefix): Function removed.
20445 (pupa_dl_get_prefix): Likewise.
20446 * kern/i386/pc/init.c: Include <pupa/env.h>.
20447 (pupa_machine_init): Use the environment variable `prefix' instead of
20448 using pupa_dl_set_prefix to set the prefix.
20449 * kern/main.c: Include <pupa/env.h>.
20450 (pupa_set_root_dev): Use the environment variable `prefix' instead of
20451 using pupa_dl_get_prefix to get the prefix.
20452 * kern/misc.c: Include <pupa/env.h>.
20453 (pupa_isdigit): New function.
20454 (pupa_isgraph): Likewise.
20455 (pupa_ftoa): Likewise.
20456 (pupa_vsprintf): Added support for printing values of the type
20457 `double'. Make it possible to format variable output when using
20458 formatting like `%1.2%f'.
20459 (pupa_split_cmdline): New function.
20460 * kern/rescue.c: Include <pupa/env.h>.
20461 (next_word): Removed function.
20462 (pupa_rescue_cmd_prefix): Likewise.
20463 (pupa_rescue_cmd_set): New function.
20464 (pupa_rescue_cmd_unset): New function.
20465 (pupa_enter_rescue_mode): Use the `pupa_split_cmdline' function to
20466 split the command line instead of splitting it here. Added
20467 support for setting variables using the syntax `foo=bar'. Don't
20468 initialize the prefix command anymore. Initialized the set and
20469 unset commands.
20470 * normal/cmdline.c: Include <pupa/env.h>.
20471 (pupa_tab_complete): Added prototypes for print_simple_completion,
20472 print_partition_completion, add_completion, iterate_commands,
20473 iterate_dev, iterate_part and iterate_dir. Moved code to print
20474 partition information from here to kern/disk.c.
fe6b695a 20475 (pupa_cmdline_run): Don't check if the function exists anymore.
db1771cf 20476 * normal/main.c: Include <pupa/env.h>.
20477 (pupa_rescue_cmd_normal): Use the environment variable `prefix'
20478 instead of using pupa_dl_get_prefix to get the prefix.
20479 * term/i386/pc/vga.c: Include <pupa/arg.h>.
20480 (check_vga_mem): Cast pointers to `void *' to silence a gcc
20481 warning.
20482 (pupa_vga_putchar) [! DEBUG_VGA]: Removed for this case.
20483 (pupa_vga_setcolor): Declare unused variables with `__attribute__
20484 ((unused))' to silence a gcc warning.
20485 (pupa_vga_setcolor): Likewise.
20486 (debug_command): Changed to match argument parsing
20487 interface changes.
20488 * util/pupa-emu.c: Include <pupa/env.h>.
20489 (options): Added 0's for unused fields to silence a gcc warning.
20490 (argp): Likewise.
20491 (main): Use the environment variable `prefix' instead of using
20492 pupa_dl_set_prefix to set the prefix. Initialize the commands ls,
20493 boot, cmp, cat and terminal. Finish the commands boot, cmp, cat
20494 and terminal.
20495
20496 * util/i386/pc/getroot.c: Include <pupa/i386/pc/util/biosdisk.h>.
20497 * util/misc.c: Include <malloc.h>.
20498 (pupa_malloc): Rewritten so errors are correctly reported.
20499 (pupa_realloc): Likewise.
20500 (pupa_memalign): Likewise.
20501 (pupa_mm_init_region): Declare unused variables with
20502 `__attribute__ ((unused))' to silence a gcc warning.
20503 * normal/i386/setjmp.S: Remove tab at the end of the file to
20504 silence a gcc warning.
20505 * loader/i386/pc/linux.c (pupa_rescue_cmd_initrd): Declare unused
20506 variables with `__attribute__ ((unused))' to silence a gcc
20507 warning.
20508 * loader/i386/pc/multiboot.c (pupa_multiboot_unload): Make the
20509 local variable i unsigned to silence a gcc warning.
20510
20511 * kern/term.c: Include <pupa/misc.h>.
20512 (pupa_more_lines): New variable.
20513 (pupa_more): Likewise.
20514 (pupa_putcode): When the pager is active pause at the end of every
20515 screen.
20516 (pupa_set_more): New function.
20517 * include/pupa/term.h (pupa_set_more): New prototype.
20518
20519
3b1139cb 205202004-03-07 Yoshinori K. Okuji <okuji@enbug.org>
20521
20522 Now this project is GRUB 2 rather than PUPA. The location of
20523 the CVS repository was moved to GRUB's.
f19dbdb7 20524
3b1139cb 20525 * configure.ac: Use bug-grub as the reporting address.
20526 Use GRUB instead of PUPA.
20527 Change the version number to 1.90.
20528
8367695c 205292004-02-24 Yoshinori K. Okuji <okuji@enbug.org>
20530
20531 * genkernsyms.sh: Updated copyright information.
20532 * genmk.rb: Likewise.
20533 * genmodsrc.sh: Likewise.
20534 * gensymlist.sh: Likewise.
20535 * boot/i386/pc/boot.S: Likewise.
20536 * boot/i386/pc/diskboot.S: Likewise.
20537 * disk/i386/pc/biosdisk.c: Likewise.
20538 * disk/i386/pc/partition.c: Likewise.
20539 * font/manager.c: Likewise.
20540 * fs/ext2.c: Likewise.
20541 * fs/fat.c: Likewise.
20542 * include/pupa/boot.h: Likewise.
20543 * include/pupa/device.h: Likewise.
20544 * include/pupa/disk.h: Likewise.
20545 * include/pupa/dl.h: Likewise.
20546 * include/pupa/elf.h: Likewise.
20547 * include/pupa/err.h: Likewise.
20548 * include/pupa/file.h: Likewise.
20549 * include/pupa/font.h: Likewise.
20550 * include/pupa/fs.h: Likewise.
20551 * include/pupa/kernel.h: Likewise.
20552 * include/pupa/loader.h: Likewise.
20553 * include/pupa/misc.h: Likewise.
20554 * include/pupa/mm.h: Likewise.
20555 * include/pupa/net.h: Likewise.
20556 * include/pupa/normal.h: Likewise.
20557 * include/pupa/rescue.h: Likewise.
20558 * include/pupa/setjmp.h: Likewise.
20559 * include/pupa/symbol.h: Likewise.
20560 * include/pupa/term.h: Likewise.
20561 * include/pupa/types.h: Likewise.
20562 * include/pupa/i386/setjmp.h: Likewise.
20563 * include/pupa/i386/types.h: Likewise.
20564 * include/pupa/i386/pc/biosdisk.h: Likewise.
20565 * include/pupa/i386/pc/boot.h: Likewise.
20566 * include/pupa/i386/pc/console.h: Likewise.
20567 * include/pupa/i386/pc/init.h: Likewise.
20568 * include/pupa/i386/pc/kernel.h: Likewise.
20569 * include/pupa/i386/pc/linux.h: Likewise.
20570 * include/pupa/i386/pc/loader.h: Likewise.
20571 * include/pupa/i386/pc/memory.h: Likewise.
20572 * include/pupa/i386/pc/multiboot.h: Likewise.
20573 * include/pupa/i386/pc/partition.h: Likewise.
20574 * include/pupa/i386/pc/time.h: Likewise.
20575 * include/pupa/i386/pc/vga.h: Likewise.
20576 * include/pupa/i386/pc/util/biosdisk.h: Likewise.
20577 * include/pupa/util/getroot.h: Likewise.
20578 * include/pupa/util/misc.h: Likewise.
20579 * include/pupa/util/resolve.h: Likewise.
20580 * kern/device.c: Likewise.
20581 * kern/disk.c: Likewise.
20582 * kern/dl.c: Likewise.
20583 * kern/err.c: Likewise.
20584 * kern/file.c: Likewise.
20585 * kern/fs.c: Likewise.
20586 * kern/loader.c: Likewise.
20587 * kern/main.c: Likewise.
20588 * kern/misc.c: Likewise.
20589 * kern/mm.c: Likewise.
20590 * kern/rescue.c: Likewise.
20591 * kern/term.c: Likewise.
20592 * kern/i386/dl.c: Likewise.
20593 * kern/i386/pc/init.c: Likewise.
20594 * kern/i386/pc/lzo1x.S: Likewise.
20595 * kern/i386/pc/startup.S: Likewise.
20596 * loader/i386/pc/chainloader.c: Likewise.
20597 * loader/i386/pc/linux.c: Likewise.
20598 * loader/i386/pc/multiboot.c: Likewise.
20599 * normal/cmdline.c: Likewise.
20600 * normal/command.c: Likewise.
20601 * normal/main.c: Likewise.
20602 * normal/menu.c: Likewise.
20603 * normal/i386/setjmp.S: Likewise.
20604 * term/i386/pc/console.c: Likewise.
20605 * term/i386/pc/vga.c: Likewise.
20606 * util/console.c: Likewise.
20607 * util/genmoddep.c: Likewise.
20608 * util/misc.c: Likewise.
20609 * util/pupa-emu.c: Likewise.
20610 * util/resolve.c: Likewise.
20611 * util/unifont2pff.rb: Likewise.
20612 * util/i386/pc/biosdisk.c: Likewise.
20613 * util/i386/pc/getroot.c: Likewise.
20614 * util/i386/pc/pupa-mkimage.c: Likewise.
20615 * util/i386/pc/pupa-setup.c: Likewise.
20616
e6eced71 206172004-02-15 Jeroen Dekkers <jeroen@dekkers.cx>
20618
20619 * fs/ext2.c (pupa_ext2_read_file): Correct the value of BLOCKEND
20620 when it is EXT2_BLOCK_SIZE (data). New argument READ_HOOK, all
20621 callers changed. Set DATA->DISK->READ_HOOK to READ_HOOK before
20622 reading and reset it after reading.
20623 (pupa_ext2_close): Return PUPA_ERR_NONE.
20624
20625 * include/pupa/i386/pc/linux.h (PUPA_LINUX_INITRD_MAX_ADDRESS):
20626 Correct value.
20627 (struct linux_kernel_header): Add kernel_version and
20628 initrd_addr_max.
20629 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Check whether
20630 pupa_file_read succeeds.
20631 (pupa_rescue_cmd_initrd): Implement.
20632
5aded270 206332003-12-03 Marco Gerards <metgerards@student.han.nl>
20634
20635 * fs/ext2.c (pupa_ext2_label): New function.
20636 (pupa_ext2_fs): Added label.
20637 * fs/fat.c (pupa_fat_label): New function.
20638 (pupa_fat_fs): Added label.
20639 * include/pupa/fs.h (struct pupa_fs): Added prototype label.
20640
20641 * kern/misc.c (pupa_strndup): New function.
20642 * include/pupa/misc.h (pupa_strndup): New prototype.
20643
20644 * include/pupa/normal.h: Include <pupa/err.h>.
20645 (pupa_set_history): New prototype.
20646 (pupa_iterate_commands): New prototype.
20647 * normal/cmdline.c: Include <pupa/machine/partition.h>,
20648 <pupa/disk.h>, <pupa/file.h>.
20649 (hist_size): New variable.
20650 (hist_lines): Likewise.
20651 (hist_end): Likewise.
20652 (hist_used): Likewise.
20653 (pupa_set_history): New function.
20654 (pupa_history_get): Likewise.
20655 (pupa_history_add): Likewise.
20656 (pupa_history_replace): Likewise.
20657 (pupa_tab_complete): Likewise.
20658 (pupa_cmdline_run): Added tab completion and history buffer. Tab
20659 completion shows partitionnames while completing partitions, this
20660 feature was suggested by Jeff Bailey.
20661 * normal/command.c (pupa_iterate_commands): New function.
20662 * normal/main.c (PUPA_DEFAULT_HISTORY_SIZE): New macro.
20663 (pupa_normal_init): Initialize history buffer.
20664 (PUPA_MOD_INIT): Likewise.
20665 (pupa_normal_fini): Free the history buffer.
20666 (PUPA_MOD_FINI): Likewise.
20667
20668 * util/console.c (pupa_ncurses_getkey): Accept 127 as backspace
20669 key.
20670
20671 * aclocal.m4 (pupa_I386_CHECK_REGPARM_BUG): New DEFUN.
20672 * configure.ac [i386]: Check for regparam bug.
20673 (NESTED_FUNC_ATTR) [! i386]: Defined.
20674
1f7315a3 206752003-11-17 Marco Gerards <metgerards@student.han.nl>
20676
20677 * conf/i386-pc.rmk (sbin_UTILITIES): Added pupa-emu.
20678 (pupa_setup_SOURCES): Added util/i386/pc/getroot.c.
20679 (pupa_emu_SOURCES): New variable.
20680 (pupa_emu_LDFLAGS): Likewise.
20681 * include/pupa/fs.h (pupa_ext2_init) [PUPA_UTIL]: New prototype.
20682 (pupa_ext2_fini) [PUPA_UTIL]: Likewise.
20683 * include/pupa/normal.h (pupa_normal_init) [PUPA_UTIL]: Likewise.
20684 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
20685 * include/pupa/setjmp.h [PUPA_UTIL]: Include <setjmp.h>.
20686 (pupa_jmp_buf): New typedef.
20687 (pupa_setjmp) [PUPA_UTIL]: New macro.
20688 (pupa_longjmp) [PUPA_UTIL]: Likewise.
20689 * include/pupa/term.h (struct pupa_term): New member `refresh'.
20690 (pupa_refresh): New prototype.
20691 * include/pupa/util/getroot.h: New file.
20692 * kern/misc.c (pupa_vsprintf): Refresh the screen after updating
20693 it.
20694 * kern/rescue.c (pupa_rescue_get_command_line): Likewise.
20695 (pupa_rescue_cmd_cat): Likewise.
20696 (pupa_rescue_cmd_ls): Likewise.
20697 (pupa_rescue_cmd_testload): Likewise.
20698 (pupa_rescue_cmd_lsmod): Likewise.
20699 * normal/cmdline.c (pupa_cmdline_get): Likewise.
20700 * normal/menu.c (run_menu): Likewise.
20701 * kern/term.c (pupa_cls): Likewise.
20702 (pupa_refresh): New function.
20703 * normal/normal.c (pupa_normal_init) [PUPA_UTIL]: New function.
20704 (pupa_normal_fini) [PUPA_UTIL]: Likewise.
20705 * util/console.c: New file.
f19dbdb7 20706
1f7315a3 20707 * util/i386/pc/getroot.c: New file.
20708 * util/i386/pc/pupa-setup.c: Include <pupa/util/getroot.h>.
20709 (pupa_putchar): New function.
20710 (pupa_refresh): Likewise.
20711 (xgetcwd): Function moved to ...
20712 (strip_extra_slashes): Likewise.
20713 (get_prefix): Likewise.
f19dbdb7 20714 * util/i386/pc/getroot.c: ... here.
1f7315a3 20715 (find_root_device): Function moved and renamed to...
20716 * util/i386/pc/getroot.c (pupa_find_root_device): ... here.
20717 Changed all callers.
20718 * util/i386/pc/pupa-setup.c (guess_root_device): Function moved
20719 and renamed to...
20720 * util/i386/pc/getroot.c (pupa_guess_root_device): ... here.
20721 Changed all callers.
20722 * util/misc.c (pupa_memalign): New function.
20723 (pupa_mm_init_region): Likewise.
20724 (pupa_register_exported_symbols): Likewise.
20725 (pupa_putchar): Function removed.
20726 * util/pupa-emu.c: New file.
20727
9a5c1ade 207282003-11-16 Jeroen Dekkers <jeroen@dekkers.cx>
20729
20730 * conf/i386-pc.rmk (pkgdata_MODULES): Add _multiboot.mod.
20731 (_multiboot_mod_SOURCES): New variable.
20732 (_multiboot_mod_CFLAGS): Likewise.
20733 * loader/i386/pc/multiboot.c: New file.
20734 * include/pupa/i386/pc/multiboot.h: Likewise.
20735 * kern/i386/pc/startup.S: Include pupa/machine/multiboot.h.
20736 (pupa_multiboot_real_boot): New function.
20737 * include/pupa/i386/pc/loader.h: Include pupa/machine/multiboot.h.
20738 (pupa_multiboot_real_boot): New prototype.
20739 (pupa_rescue_cmd_multiboot): Likewise
20740 (pupa_rescue_cmd_module): Likewise.
20741
20742 * kern/loader.c (pupa_loader_set): Continue when
20743 pupa_loader_unload_func() fails.
20744 (pupa_loader_unset): New function.
20745 * include/pupa/loader.h (pupa_loader_unset): New prototype.
20746
20747 * kern/misc.c (pupa_stpcpy): New function.
20748 * include/pupa/misc.h (pupa_stpcpy): New prototype.
20749
8e72a9c0 207502003-11-12 Marco Gerards <metgerards@student.han.nl>
20751
20752 * disk/i386/pc/biosdisk.c (pupa_biosdisk_open): Correctly check
20753 for available extensions.
20754
20755 * include/pupa/i386/pc/time.h: New file.
20756 * kern/disk.c: Include <pupa/machine/time.h>.
20757 (PUPA_CACHE_TIMEOUT): New macro.
20758 (pupa_last_time): New variable.
20759 (pupa_disk_open): Flush the cache when there was a timeout.
20760 (pupa_disk_close): Reset the timer.
20761 * kern/i386/pc/startup.S (pupa_get_rtc): Renamed from
20762 pupa_currticks.
20763 * util/misc.c: Include <sys/times.h>
20764 (pupa_get_rtc): New function.
20765
c4adbd32 207662003-11-09 Jeroen Dekkers <jeroen@dekkers.cx>
20767
20768 * fs/ext2.c (struct pupa_ext2_inode): Declare struct datablocks
20769 as blocks.
20770 (pupa_ext2_get_file_block): Use blocks member.
20771
20772 * fs/ext2.c (pupa_ext2_read_file): Only set skipfirst for the
20773 first block. Return -1 instead of pupa_errno on error.
20774
bfd30f06 207752003-10-27 Marco Gerards <metgerards@student.han.nl>
20776
20777 * README: In the pupa-mkimage example use _chain instead of chain
20778 and ext2 instead of fat.
20779 * TODO: Replace ext2fs with jfs as an example. Add an item for
20780 adding journal playback for ext2fs.
20781 * conf/i386-pc.rmk (pupa_setup_SOURCES): Added fs/ext2.c.
20782 (pkgdata_MODULES): Added ext2.mod.
20783 (ext2_mod_SOURCES): New variable.
20784 (ext2_mod_CFLAGS): Likewise.
20785 * include/pupa/err.h (pupa_err_t): Added PUPA_ERR_SYMLINK_LOOP.
20786 * include/pupa/misc.h (pupa_strncpy): New prototype.
20787 (pupa_strcat): Likewise.
20788 (pupa_strncmp): Likewise.
20789 * kern/misc.c (pupa_strcat): Enable function.
20790 (pupa_strncpy): New function.
20791 (pupa_strncmp): Likewise.
20792 * fs/ext2.c: New file.
f19dbdb7 20793
bfd30f06 20794 * kern/disk.c (pupa_disk_read): Set pupa_errno to PUPA_ERR_NONE
20795 when the read failed before retrying.
20796 * util/i386/pc/biosdisk.c (_LARGEFILE_SOURCE): Removed.
20797 (_FILE_OFFSET_BITS): Likewise.
20798 * configure.ac: Added AC_SYS_LARGEFILE.
20799
98d15063 208002003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
20801
20802 * genmk.rb (PModule#rule): Make sure to get only symbol names
20803 from the output of nm.
20804 Reported by Robert Millan <zeratul2@wanadoo.es>.
20805
18d9c7cd 208062003-09-25 Yoshinori K. Okuji <okuji@enbug.org>
20807
20808 I forgot to check in these changes for a long time. This adds
20809 incomplete support for VGA console, and this is still very
20810 buggy. Also, a lot of consideration is required for I18N,
20811 UNICODE, and VGA font issues. Therefore, assume that this is
20812 such that "better than nothing".
f19dbdb7 20813
18d9c7cd 20814 * font/manager.c: New file.
20815 * include/pupa/font.h: Likewise.
20816 * include/pupa/i386/pc/vga.h: Likewise.
20817 * term/i386/pc/vga.c: Likewise.
20818 * util/unifont2pff.rb: Likewise.
20819
20820 * conf/i386-pc.rmk (kernel_img_HEADERS): Added machine/vga.h.
20821 (pkgdata_MODULES): Added vga.mod and font.mod.
20822 (vga_mod_SOURCES): New variables.
20823 (vga_mod_CFLAGS): Likewise.
20824 (font_mod_SOURCES): Likewise.
20825 (font_mod_CFLAGS): Likewise.
20826
20827 * include/pupa/err.h (PUPA_ERR_BAD_FONT): New constant.
20828
20829 * include/pupa/term.h: Include pupa/err.h.
f19dbdb7 20830 (struct pupa_term): Added init and fini.
18d9c7cd 20831 Changed the argument of putchar to pupa_uint32_t.
20832
20833 * include/pupa/i386/pc/console.h: Include pupa/symbol.h.
20834 (pupa_console_real_putchar): New prototype.
20835 (pupa_console_putchar): Removed.
20836 (pupa_console_checkkey): Exported.
20837 (pupa_console_getkey): Likewise.
20838
20839 * kern/misc.c (pupa_vsprintf): Add support for UNICODE
20840 characters.
20841
20842 * kern/term.c (pupa_term_set_current): Rewritten.
20843 (pupa_putchar): Likewise.
20844 (pupa_putcode): New function.
20845
20846 * kern/i386/pc/startup.S (pupa_console_putchar): Renamed to ...
20847 (pupa_console_real_putchar): ... this.
20848 (pupa_vga_set_mode): New function.
20849 (pupa_vga_get_font): Likewise.
20850
20851 * normal/command.c: Include pupa/term.h.
20852 (terminal_command): New function.
20853 (pupa_command_init): Register the command "terminal".
20854
20855 * normal/menu.c (DISP_LEFT): Changed to a UNICODE value.
20856 (DISP_UP): Likewise.
20857 (DISP_RIGHT): Likewise.
20858 (DISP_DOWN): Likewise.
20859 (DISP_HLINE): Likewise.
20860 (DISP_VLINE): Likewise.
20861 (DISP_UL): Likewise.
20862 (DISP_UR): Likewise.
20863 (DISP_LL): Likewise.
20864 (DISP_LR): Likewise.
20865
20866 * term/i386/pc/console.c (pupa_console_putchar): New function.
f19dbdb7 20867
977329f5 208682003-02-08 NIIBE Yutaka <gniibe@m17n.org>
20869
20870 * util/resolve.c (pupa_util_resolve_dependencies): BUG
20871 FIX. Reverse the path_list.
20872
20873 * include/pupa/normal.h: Export pupa_register_command and
20874 pupa_unregister_command.
20875
20876 * hello/hello.c (pupa_cmd_hello): New module.
20877 * conf/i386-pc.rmk: Added hello.mod.
20878
1f5ab428 208792003-01-31 Yoshinori K. Okuji <okuji@enbug.org>
20880
20881 * kern/i386/pc/lzo1x.S: New file.
f19dbdb7 20882
1f5ab428 20883 * util/i386/pc/pupa-mkimage.c: Include lzo1x.h.
20884 (compress_kernel): New variable.
20885 (generate_image): Heavily modified to support compressing a
20886 large part of the core image.
20887
20888 * util/misc.c (pupa_util_read_image): Fix a file descriptor
20889 leak.
20890 (pupa_util_load_image): New function.
20891
20892 * kern/i386/pc/startup.S: Include pupa/machine/kernel.h.
20893 (pupa_compressed_size): New variable.
20894 (codestart): Enable Gate A20 here.
20895 Decompress the compressed part of the core image.
20896 Rearrange the code to put functions and variables which are
20897 required for initialization in the non-compressed part.
20898 Include lzo1x.S.
20899
20900 * kern/i386/pc/init.c (pupa_machine_init): Don't enable Gate A20
20901 here.
20902
20903 * include/pupa/util/misc.h (pupa_util_write_image): Declared.
20904
f19dbdb7 20905 * include/pupa/i386/pc/kernel.h
1f5ab428 20906 (PUPA_KERNEL_MACHINE_COMPRESSED_SIZE): New macro.
20907 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): Increased by 4.
20908 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
20909 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
20910 (PUPA_KERNEL_MACHINE_RAW_SIZE): New macro.
20911
20912 * conf/i386-pc.rmk (pupa_mkimage_LDFLAGS): New variable.
20913
20914 * genmk.rb (Image#rule): Put LDFLAGS at the end of a line.
20915 (Utility#rule): Likewise.
20916
20917 * configure.ac: Check if LZO is available.
20918
ce5bf700 209192003-01-20 Yoshinori K. Okuji <okuji@enbug.org>
20920
20921 * include/pupa/normal.h: New file.
20922 * include/pupa/setjmp.h: Likewise.
20923 * include/pupa/i386/setjmp.h: Likewise.
20924 * normal/cmdline.c: Likewise.
20925 * normal/command.c: Likewise.
20926 * normal/main.c: Likewise.
20927 * normal/menu.c: Likewise.
20928 * normal/i386/setjmp.S: Likewise.
f19dbdb7 20929
ce5bf700 20930 * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Made global.
20931 (pupa_rescue_cmd_initrd): Likewise.
20932
20933 * loader/i386/pc/chainloader.c (pupa_rescue_cmd_chainloader):
20934 Likewise.
20935
20936 * kern/i386/pc/startup.S (translation_table): New variable.
20937 (translate_keycode): New function.
20938 (pupa_console_getkey): Call translate_keycode.
20939
20940 * kern/rescue.c (attempt_normal_mode): New function.
20941 (pupa_enter_rescue_mode): Attempt to execute the normal mode. If
20942 it failed, print a message.
20943
20944 * kern/mm.c (pupa_real_malloc): Print more information when a
20945 free magic is broken.
20946 (pupa_free): If the first free header is not free actually, set
20947 it to P.
20948
20949 * kern/main.c (pupa_load_normal_mode): Just load the module
20950 "normal".
20951 (pupa_main): Don't print the message
20952 "Entering into rescue mode..." here.
20953
20954 * include/pupa/i386/pc/loader.h (pupa_rescue_cmd_initrd):
20955 Declared.
20956 (pupa_rescue_cmd_initrd): Likewise.
20957 (pupa_rescue_cmd_initrd): Likewise.
20958
20959 * include/pupa/symbol.h (FUNCTION): Specify the type.
20960 (VARIABLE): Likewise.
20961
20962 * include/pupa/err.h (pupa_err_t): Added
20963 PUPA_ERR_UNKNOWN_COMMAND.
20964
20965 * include/pupa/dl.h (pupa_dl_set_prefix): Exported.
20966 (pupa_dl_get_prefix): Likewise.
20967
20968 * conf/i386-pc.rmk (pkgdata_MODULES): Added normal.mod.
20969 Added _chain.mod and _linux.mod instead of chain.mod and
20970 linux.mod.
20971 (chain_mod_SOURCES): Renamed to ...
20972 (_chain_mod_SOURCES): ... this.
20973 (chain_mod_CFLAGS): Renamed to ...
20974 (_chain_mod_CFLAGS): ... this.
20975 (linux_mod_SOURCES): Renamed to ...
20976 (_linux_mod_SOURCES): ... this.
20977 (linux_mod_CFLAGS): Renamed to ...
20978 (_linux_mod_CFLAGS): ... this.
20979 (normal_mod_SOURCES): New variable.
20980 (normal_mod_CFLAGS): Likewise.
20981 (normal_mod_ASFLAGS): Likewise.
20982
209832003-01-18 Yoshinori K. Okuji <okuji@enbug.org>
20984
20985 * kern/rescue.c (pupa_rescue_cmd_rmmod): Call pupa_dl_unload, if
20986 possible.
20987
fe6b695a 20988 * kern/dl.c (pupa_dl_ref): Refer depending modules
ce5bf700 20989 recursively.
20990 (pupa_dl_unref): Unrefer depending modules recursively.
20991 Don't call pupa_dl_unload implicitly, because PUPA can crash if
20992 a module is unloaded before one depending on that module is
20993 unloaded.
20994 (pupa_dl_unload): Unload depending modules explicitly,
20995 if possible.
20996
c04da074 209972003-01-17 Yoshinori K. Okuji <okuji@enbug.org>
20998
20999 * include/pupa/i386/pc/linux.h: New file.
21000 * loader/i386/pc/linux.c: Likewise.
f19dbdb7 21001
c04da074 21002 * loader/i386/pc/chainloader.c (pupa_chainloader_boot_sector):
21003 Removed.
21004 (pupa_chainloader_unload): Return PUPA_ERR_NONE.
21005 (pupa_rescue_cmd_chainloader): Read the image to 0x7C00 instead
21006 of PUPA_CHAINLOADER_BOOT_SECTOR.
21007
21008 * kern/i386/pc/startup.S: Include pupa/machine/linux.h.
21009 (pupa_linux_prot_size): New variable.
21010 (pupa_linux_tmp_addr): Likewise.
21011 (pupa_linux_real_addr): Likewise.
21012 (pupa_linux_boot_zimage): New function.
21013 (pupa_linux_boot_bzimage): Likewise.
21014
21015 * kern/i386/pc/init.c (struct mem_region): New structure.
21016 (MAX_REGIONS): New macro.
21017 (mem_regions): New variable.
21018 (num_regions): Likewise.
21019 (pupa_os_area_addr): Likewise.
21020 (pupa_os_area_size): Likewise.
21021 (pupa_lower_mem): Likewise.
21022 (pupa_upper_mem): Likewise.
21023 (add_mem_region): New function.
21024 (compact_mem_regions): Likewise.
21025 (pupa_machine_init): Set PUPA_LOWER_MEM and PUPA_UPPER_MEM to
21026 the size of the conventional memory and that of so-called upper
21027 memory (before the first memory hole).
21028 Instead of adding each found region to free memory, use
21029 add_mem_region and add them after removing overlaps.
21030 Also, add only 1/4 of the upper memory to free memory. The rest
21031 is used for loading OS images. Maybe this is ad hoc, but this
21032 makes it much easier to relocate OS images when booting.
21033
21034 * kern/rescue.c (pupa_rescue_cmd_module): Removed.
21035 (pupa_enter_rescue_mode): Don't register initrd and module.
21036
21037 * kern/mm.c: Include pupa/dl.h.
21038
21039 * kern/main.c: Include pupa/file.h and pupa/device.h.
21040
21041 * kern/loader.c (pupa_loader_load_module_func): Removed.
21042 (pupa_loader_load_module): Likewise.
21043
21044 * kern/dl.c (pupa_dl_load): Use the suffix ``.mod'' instead of
21045 ``.o''.
21046
21047 * include/pupa/i386/pc/loader.h (pupa_linux_prot_size): Declared.
21048 (pupa_linux_tmp_addr): Likewise.
21049 (pupa_linux_real_addr): Likewise.
21050 (pupa_linux_boot_zimage): Likewise.
21051 (pupa_linux_boot_bzimage): Likewise.
21052
21053 * include/pupa/i386/pc/init.h (pupa_lower_mem): Declared.
21054 (pupa_upper_mem): Likewise.
21055 (pupa_gate_a20): Don't export, because turning off Gate A20 in a
21056 module is too dangerous.
21057
21058 * include/pupa/loader.h (pupa_os_area_addr): Declared.
21059 (pupa_os_area_size): Likewise.
21060 (pupa_loader_set): Remove the first argument. Loader doesn't
21061 manage modules or initrd any longer.
21062 (pupa_loader_load_module): Removed.
21063
21064 * conf/i386-pc.rmk (pkgdata_MODULES): Added linux.mod.
21065 (linux_mod_SOURCES): New variable.
21066 (linux_mod_CFLAGS): Likewise.
21067
a13f9237 210682003-01-07 Yoshinori K. Okuji <okuji@enbug.org>
21069
21070 * util/i386/pc/pupa-setup.c (setup): Convert the endianness of
21071 the length of a blocklist correctly.
21072
21073 * util/i386/pc/biosdisk.c (pupa_util_biosdisk_open) [__linux__]:
21074 Use ioctl only if the OS file is a block device.
21075 (pupa_util_biosdisk_open): Don't use ST.ST_BLOCKS, because it is
21076 not very useful for normal files.
21077
21078 * kern/main.c (pupa_set_root_dev): New function.
21079 (pupa_load_normal_mode): Likewise.
21080 (pupa_main): Call those above.
21081
21082 * include/pupa/types.h (pupa_swap_bytes16): Cast the result to
21083 pupa_uint16_t.
21084
21085 * include/pupa/kernel.h (pupa_enter_normal_mode): Removed.
21086
a5ffe966 210872003-01-06 Yoshinori K. Okuji <okuji@enbug.org>
21088
21089 * util/i386/pc/pupa-setup.c: Include pupa/machine/kernel.h.
21090 (setup): Configure the installed partition information and the
21091 dl prefix.
21092
21093 * loader/i386/pc/chainloader.c (my_mod): New variable.
21094 (pupa_chainloader_unload): New function.
21095 (pupa_rescue_cmd_chainloader): Refer itself.
21096 (PUPA_MOD_INIT): Save its own module in MY_MOD.
21097
21098 * kern/i386/pc/startup.S (install_partition): Removed.
21099 (version_string): Likewise.
21100 (config_file): Likewise.
21101 (pupa_install_dos_part): New variable.
21102 (pupa_install_bsd_part): Likewise.
21103 (pupa_prefix): Likewise.
21104 (pupa_chainloader_real_boot): Call pupa_dl_unload_all.
21105
21106 * kern/i386/pc/init.c: Include pupa/machine/kernel.h, pupa/dl.h
21107 and pupa/misc.h.
21108 (make_install_device): New function.
21109 (pupa_machine_init): Set the dl prefix.
21110
21111 * kern/rescue.c: Include pupa/rescue.h and pupa/dl.h.
21112 (buf): Renamed to ...
21113 (linebuf): ... this.
21114 (pupa_rescue_cmd_prefix): New function.
21115 (pupa_rescue_cmd_insmod): Likewise.
21116 (pupa_rescue_cmd_rmmod): Likewise.
21117 (pupa_rescue_cmd_lsmod): Likewise.
21118 (pupa_enter_rescue_mode): Register new commands: prefix, insmod,
21119 rmmod and lsmod.
21120
21121 * kern/mm.c (pupa_memalign): If failed even after invalidating
21122 disk caches, unload unneeded modules and retry.
21123
21124 * kern/misc.c (pupa_memmove): New function.
21125 (pupa_memcpy): Removed.
21126 (pupa_strcpy): New function.
21127 (pupa_itoa): Made static.
21128
21129 * kern/dl.c (pupa_dl_iterate): New function.
21130 (pupa_dl_ref): Likewise.
21131 (pupa_dl_unref): Likewise.
21132 (pupa_dl_unload): Return if succeeded or not.
21133 (pupa_dl_unload_unneeded): New function.
21134 (pupa_dl_unload_all): Likewise.
21135 (pupa_dl_init): Renamed to ...
21136 (pupa_dl_set_prefix): ... this.
21137 (pupa_dl_get_prefix): New function.
21138
21139 * include/pupa/i386/pc/kernel.h: Include pupa/types.h.
21140 (PUPA_KERNEL_MACHINE_INSTALL_DOS_PART): New macro.
21141 (PUPA_KERNEL_MACHINE_INSTALL_BSD_PART): Likewise.
21142 (PUPA_KERNEL_MACHINE_PREFIX): Likewise.
21143 (pupa_install_dos_part): Declared.
21144 (pupa_install_bsd_part): Likewise.
21145 (pupa_prefix): Likewise.
21146 (pupa_boot_drive): Likewise.
21147
21148 * include/pupa/types.h: Fix a typo.
21149
21150 * include/pupa/misc.h (pupa_memcpy): New macro. Just an alias to
21151 pupa_memmove.
21152 (pupa_memmove): Declared.
21153 (pupa_strcpy): Likewise.
21154
21155 * include/pupa/dl.h (PUPA_MOD_INIT): Change the prototype. Now
21156 pupa_mod_init takes one argument, its own module.
21157 (pupa_dl_unload_unneeded): Declared.
21158 (pupa_dl_unload_all): Likewise.
21159 (pupa_dl_ref): Likewise.
21160 (pupa_dl_unref): Likewise.
21161 (pupa_dl_iterate): Likewise.
21162 (pupa_dl_init): Renamed to ...
21163 (pupa_dl_set_prefix): ... this.
21164 (pupa_dl_get_prefix): Declared.
21165
21166 * fs/fat.c [!PUPA_UTIL] (my_mod): New variable.
f19dbdb7 21167 (pupa_fat_dir) [!PUPA_UTIL]: Prevent the fat module from being
a5ffe966 21168 unloaded.
21169 (pupa_fat_open) [!PUPA_UTIL]: Refer itself if succeeded.
21170 (pupa_fat_close) [!PUPA_UTIL]: Unrefer itself.
21171
21172 * configure.ac (tmp_CFLAGS): Added -Wshadow, -Wpointer-arith,
21173 -Wmissing-prototypes, -Wundef and -Wstrict-prototypes.
21174
012d7999 211752003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
21176
21177 * util/i386/pc/pupa-setup.c (setup): Define the internal
21178 function find_first_partition_start at the top level, because GCC
21179 3.0.x cannot compile internal functions in deeper scopes
21180 correctly.
21181 (find_root_device): Use lstat instead of stat.
21182 Don't follow symbolic links.
21183 Fix the path-constructing code.
21184
21185 * util/i386/pc/biosdisk.c [__linux__] (BLKFLSBUF): New macro.
21186 (pupa_util_biosdisk_open) [__linux__]: Get the size of a device
21187 by a BLKGETSIZE ioctl first, because block devices don't fill
21188 the member st_mode of the structure stat on Linux.
21189 [__linux__] (linux_find_partition): Use a temporary buffer
21190 REAL_DEV for the working space. Copy it to DEV before returning.
21191 (open_device) [__linux__]: Call ioctl with BLKFLSBUF to make the
21192 buffer cache consistent.
21193 (get_os_disk) [__linux__]: Use the length 5 instead of 4 for
21194 strncmp. The previous value was merely wrong.
21195 (pupa_util_biosdisk_get_pupa_dev): Use stat instead of lstat.
21196
21197 * fs/fat.c (pupa_fat_read_data): Shift 4 instead of 12 when the
21198 FAT size is 12. The previous value was merely wrong.
21199
21200 * kern/main.c (pupa_main): Don't split the starting message from
21201 newlines.
21202
21203 * kern/term.c (pupa_putchar): Put CR after LF instead of before
21204 LF, because BIOS goes crazy about character attributes in this
21205 case.
21206
1cc73a62 212072003-01-03 Yoshinori K. Okuji <okuji@enbug.org>
21208
21209 * include/i386/pc/util/biosdisk.h: New file.
21210 * util/i386/pc/biosdisk.c: Likewise.
21211 * util/i386/pc/pupa-setup.c: Likewise.
f19dbdb7 21212
1cc73a62 21213 * Makefile.in (INCLUDE_DISTFILES): Added
21214 include/pupa/i386/pc/util/biosdisk.h.
21215 (UTIL_DISTFILES): Added biosdisk.c and pupa-setup.c under the
21216 directory util/i386/pc.
21217 (install-local): Added a rule for sbin_UTILITIES.
21218 (uninstall): Likewise.
21219
21220 * util/i386/pc/pupa-mkimage.c (usage): Fix a typo in the doc.
21221
21222 * util/misc.c (xrealloc): New function.
21223 (pupa_malloc): Likewise.
21224 (pupa_free): Likewise.
21225 (pupa_realloc): Likewise.
21226 (pupa_stop): Likewise.
21227 (pupa_putchar): Likewise.
21228
21229 * kern/disk.c (pupa_disk_read): Prevent L from underflowing.
21230
21231 * include/pupa/util/misc.h (xrealloc): Declared.
21232
21233 * include/pupa/i386/pc/boot.h (PUPA_BOOT_MACHINE_BPB_START): New
21234 macro.
21235 (PUPA_BOOT_MACHINE_BPBEND): Renamed to ...
21236 (PUPA_BOOT_MACHINE_BPB_END): ... this.
21237
21238 * include/pupa/fs.h [PUPA_UTIL] (pupa_fat_init): Declared.
21239 [PUPA_UTIL] (pupa_fat_fini): Likewise.
21240
21241 * fs/fat.c [PUPA_UTIL] (pupa_fat_init): Defined. Maybe a better
21242 way should be implemented.
21243 [PUPA_UTIL] (pupa_fat_fini): Likewise.
21244
21245 * disk/i386/pc/biosdisk.c (pupa_biosdisk_call_hook): Increase
21246 the size of NAME for safety.
21247 (pupa_biosdisk_iterate): Search hard disks to 0x90 instead of
21248 0x88.
21249
21250 * conf/i386-pc.rmk (sbin_UTILITIES): New variable.
21251 (pupa_setup_SOURCES): Likewise.
21252
21253 * genmk.rb (Utility#rule): Add $(BUILD_CFLAGS) into the rules.
21254
08b70fe8 212552002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
21256
21257 * kern/i386/pc/startup.S (push_get_mmap_entry): Revert to a
21258 bunch of pushl's from pusha, because this destroys the return
21259 value.
21260
62ddcc8f 212612002-12-28 Yoshinori K. Okuji <okuji@enbug.org>
21262
21263 Use -mrtd and -mregparm=3 to reduce the generated code sizes.
21264 This means that any missing prototypes could be fatal. Also, you
21265 must take care when writing assembly code. See the comments at
21266 the beginning of startup.S, for more details.
f19dbdb7 21267
62ddcc8f 21268 * kern/i386/pc/startup.S (pupa_halt): Modified for the new
21269 compilation mechanism.
21270 (pupa_chainloader_real_boot): Likewise.
21271 (pupa_biosdisk_rw_int13_extensions): Likewise.
21272 (pupa_biosdisk_rw_standard): Likewise.
21273 (pupa_biosdisk_check_int13_extensions): Likewise.
21274 (pupa_biosdisk_get_diskinfo_int13_extensions): Likewise.
21275 (pupa_biosdisk_get_diskinfo_standard): Likewise.
21276 (pupa_get_memsize): Likewise.
21277 (pupa_get_mmap_entry): Likewise.
21278 (pupa_console_putchar): Likewise.
21279 (pupa_console_setcursor): Likewise.
21280 (pupa_getrtsecs): Use pushl instead of push.
21281
21282 * kern/i386/pc/init.c (pupa_machine_init): Use the scratch
21283 memory instead of the stack for a mmap entry, because some
21284 BIOSes may ignore the maximum size and overflow.
21285
21286 * conf/i386-pc.rmk (COMMON_CFLAGS): Added -mrtd and -mregparm=3.
21287
21288 * genmk.rb (PModule#rule): Compile automatically generated
21289 sources with module-specific CFLAGS as well as other sources.
21290
9962ed99 212912002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
21292
21293 * configure.ac: Check ld.
21294 Replace CFLAGS and CPPFLAGS with BUILD_CFLAGS and BUILD_CPPFLAGS
21295 respectively, before checking endianness and sizes.
21296
21297 * Makefile.in (LD): New variable.
f19dbdb7 21298
abdfc3c5 212992002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
21300
21301 * Makefile.in (BUILD_CC): CC -> BUILD_CC.
21302
6a161fa9 213032002-12-27 Yoshinori K. Okuji <okuji@enbug.org>
21304
21305 * Changelog: New file.
21306